Detection queries Reported campaignLinux

CL-UNK-1211 AI-assisted campaign on government Linux servers

Espionage-style intrusions on government Linux servers used web shells, privilege escalation, SysGoRAT and tunnels. The code looks LLM-generated, but a live AI operator is not confirmed.

What happened

Espionage-style ops on government Linux (Oct 2025–Apr 2026): web shells with PHP auto_prepend_file persistence, sudo password alias in .bashrc, PwnKit/LinPEAS privesc, SysGoRAT, GSocket/revsocks/pysoxy tunnels, mailbox/social-media targeting, fake red-team markers.

LLM-assisted or AI-generated payloads (conversational reasoning comments, section headers); not confirmed as interactive agent C2

Read the original source

How it happened

Select a stage to explore its defenses
Detect this stage
Detect this stage
Detect this stage
Select a stage · Drag to explore · + / − to zoom · Dashed edges are loopsSelect a stage · Arrows show reported connectionsResearch / qualified account
Read the flow as text & sources

A catalog reconstruction of the supplied source account. AI role is payload generation / LLM-style comments in scripts, not confirmed live agent operator. Unit 42 says code consistent with LLM generation or automated AI agent.

  1. 01 · Web shells land on Linux servers

    The campaign targets government and state-affiliated infrastructure.

    Hunt: A PHP or web-server worker launches a shell, interpreter, or reconnaissance utility outside its normal baseline.

    Legitimate CGI, maintenance, and deployment scripts can match. The query is a process-tree starter, not a complete web-shell detector.

    Source for step 1
  2. 02 · Persistence and privilege tooling

    Reported steps include PHP persistence, sudo credential capture and privilege-escalation tools.

    Hunt: A task, Run key, cron entry, shell profile, or startup file is changed and later launches the same unexpected program.

    Windows and Unix persistence require different collectors. A configuration change without a subsequent launch is not proof that persistence ran.

    Source for step 2
  3. 03 · Scripts show signs of AI assistance

    Conversational code comments support an inference of AI-assisted generation, not confirmed live agent control.

    Source for step 3
  4. 04 · Remote access and collection

    SysGoRAT and tunneling tools support espionage-style operations.

    Hunt: Sensitive reads are followed by outbound transfer, a public artifact, or a tool call to a destination outside the approved workflow.

    An outbound connection or high byte count alone is not exfiltration. Encrypted traffic may hide content, and bulk legitimate exports are common.

    Source for step 4

Why it matters

Reported entry point: Web shell deployment on Linux servers (custom and GitHub open-source shells). Reported impact: SysGoRAT and tunneling tools support espionage-style operations; reported targets include Government entities and state-affiliated infrastructure.

Check these source-linked conditions against your setup.

Linux

The reported victim environment is Linux servers, including government targets.

Conditions to check
  • Source-specific initial access and host activity must be present.
  • The source supports AI-assisted code generation, not a confirmed live AI operator.

Source-linked applicability guidance. Confirm current scope in the original report.

Read the original report

What you can do

Protection & prevention

Start here

Review exposed web applications, web-worker child processes, persistence and tunnels.

Detect auto_prepend_file changes, *.gsocket.io traffic, binaries from /dev/shm; Jose take: AI made old Linux tradecraft cheaper

Catalog defensive guidance based on the reported behavior. Confirm scope and current mitigations in the original source.

Review the original guidance GTFOBins
Investigate each phase

Detection queries

Draft query starters grouped by the attack stages where they apply.

Download stage pack

Start with the logs you collect. Each hunt identifies its required visibility, field mapping and limits. Queries are catalog-authored drafts using reusable behavior profiles; test with known activity and your normal baseline before alerting.

01Web shells land on Linux serversLinux web worker → shell / interpreterNative logs · Draft

The campaign targets government and state-affiliated infrastructure.

What to look for

A PHP or web-server worker launches a shell, interpreter, or reconnaissance utility outside its normal baseline.

Visibility: Defender-side logs where collected

Required logs

  • Linux process creation (EDR / auditd normalized to process fields)
  • PHP / web access logs
  • File changes to web roots and PHP configuration

Coverage limit. Legitimate CGI, maintenance, and deployment scripts can match. The query is a process-tree starter, not a complete web-shell detector.

linux process candidates. Sigma needs normalized process events; KQL needs Defender coverage for that OS; SPL uses a custom openattacks:process sourcetype with Sysmon-style Image / ParentImage / CommandLine fields. Map raw auditd or Endpoint Security data first.

Sigma
Draft SigmaDownload Sigma
title: Hunt - Linux web worker → shell / interpreter
id: 068e005a-876e-4ba3-a414-791f9a1c2330
status: experimental
description: A PHP or web-server worker launches a shell, interpreter, or
  reconnaissance utility outside its normal baseline.
author: MagicSword OpenAttacks catalog
date: 2026-10-23
falsepositives:
  - Authorized activity matching this broad hunt; baseline and investigate
    before alerting.
level: low
logsource:
  category: process_creation
  product: linux
detection:
  selection:
    Image|endswith:
      - /sh
      - /bash
      - /python
      - /python3
      - /curl
      - /wget
    ParentImage|endswith:
      - /php-fpm
      - /php-fpm8.2
      - /apache2
      - /httpd
      - /nginx
  condition: selection
KQL
Draft KQLDownload KQL
// Draft hunt; requires Defender for Endpoint process telemetry for this OS.
DeviceProcessEvents
| where Timestamp > ago(7d)
| where FileName in~ ("sh", "bash", "python", "python3", "curl", "wget")
| where InitiatingProcessFileName in~ ("php-fpm", "php-fpm8.2", "apache2", "httpd", "nginx")
| project Timestamp, DeviceName, AccountName, FileName, ProcessCommandLine, InitiatingProcessFileName, InitiatingProcessCommandLine, SHA1
| order by Timestamp desc
SPL
Draft SPLDownload SPL
sourcetype="openattacks:process"
Image IN ("*/sh", "*/bash", "*/python", "*/python3", "*/curl", "*/wget")
ParentImage IN ("*/php-fpm", "*/php-fpm8.2", "*/apache2", "*/httpd", "*/nginx")
| table _time host User Image CommandLine ParentImage ParentCommandLine
| sort - _time
Investigation steps
  1. Trace the worker's children and correlate them with inbound requests.
  2. Review auto_prepend_file, .bashrc changes, /dev/shm execution, and outbound tunnels where the report describes them.
02Persistence and privilege toolingNew persistence → recurring executionCustom schema · Draft

Reported steps include PHP persistence, sudo credential capture and privilege-escalation tools.

What to look for

A task, Run key, cron entry, shell profile, or startup file is changed and later launches the same unexpected program.

Visibility: Defender-side logs where collected

Required logs

  • Platform-specific registry, scheduled-task, cron and startup-file changes
  • Process creation and file provenance
  • User / administrative change records

Coverage limit. Windows and Unix persistence require different collectors. A configuration change without a subsequent launch is not proof that persistence ran.

Custom-schema candidates, not out-of-box detectors. Map your application / cloud / platform logs to EventType, Actor, Asset, Action, Target and CorrelationId. KQL uses a custom OpenAttacksAudit_CL table; SPL uses openattacks:audit. EventType values are proposed normalization names, not native vendor event names. Correlation and environment-specific alert logic remain to be built.

Sigma
Draft SigmaDownload Sigma
title: Hunt - New persistence → recurring execution
id: 6154ff56-2978-45fa-aecd-86d91557f32e
status: experimental
description: A task, Run key, cron entry, shell profile, or startup file is
  changed and later launches the same unexpected program.
author: MagicSword OpenAttacks catalog
date: 2026-10-23
falsepositives:
  - Authorized activity matching this broad hunt; baseline and investigate
    before alerting.
level: low
logsource:
  category: application
  product: openattacks_audit
  definition: Custom normalized audit schema; map EventType, Actor, Asset, Action,
    Target and CorrelationId from the required source logs first.
detection:
  selection:
    EventType:
      - persistence.create
      - persistence.modify
  condition: selection
KQL
Draft KQLDownload KQL
// SCHEMA TEMPLATE: create/map this custom table before use; not a built-in Sentinel table.
// OpenAttacksAudit_CL: TimeGenerated(datetime), EventType/Actor/Asset/Action/Target/CorrelationId(string).
// Selects candidates only. Apply the stage hypothesis and correlation steps before alerting.
OpenAttacksAudit_CL
| where TimeGenerated > ago(7d)
| where EventType in ("persistence.create", "persistence.modify")
| project TimeGenerated, EventType, Actor, Asset, Action, Target, CorrelationId
| order by TimeGenerated desc
SPL
Draft SPLDownload SPL
sourcetype="openattacks:audit"
EventType IN ("persistence.create", "persistence.modify")
| table _time EventType Actor Asset Action Target CorrelationId
| sort - _time
Investigation steps
  1. Diff the persistence artifact and identify the creating process / principal.
  2. Correlate the subsequent launch and network behavior; baseline deployment and management agents.
04Remote access and collectionSensitive data → unusual destinationCustom schema · Draft

SysGoRAT and tunneling tools support espionage-style operations.

What to look for

Sensitive reads are followed by outbound transfer, a public artifact, or a tool call to a destination outside the approved workflow.

Visibility: Defender-side logs where collected

Required logs

  • Sensitive resource access / DLP records
  • Proxy, egress and cloud upload events
  • Agent / SaaS audit with correlation IDs

Coverage limit. An outbound connection or high byte count alone is not exfiltration. Encrypted traffic may hide content, and bulk legitimate exports are common.

Custom-schema candidates, not out-of-box detectors. Map your application / cloud / platform logs to EventType, Actor, Asset, Action, Target and CorrelationId. KQL uses a custom OpenAttacksAudit_CL table; SPL uses openattacks:audit. EventType values are proposed normalization names, not native vendor event names. Correlation and environment-specific alert logic remain to be built.

Sigma
Draft SigmaDownload Sigma
title: Hunt - Sensitive data → unusual destination
id: 04b60968-3179-4b1f-ae13-6f57c2446077
status: experimental
description: Sensitive reads are followed by outbound transfer, a public
  artifact, or a tool call to a destination outside the approved workflow.
author: MagicSword OpenAttacks catalog
date: 2026-10-23
falsepositives:
  - Authorized activity matching this broad hunt; baseline and investigate
    before alerting.
level: low
logsource:
  category: application
  product: openattacks_audit
  definition: Custom normalized audit schema; map EventType, Actor, Asset, Action,
    Target and CorrelationId from the required source logs first.
detection:
  selection:
    EventType:
      - data.export
      - agent.external.send
  condition: selection
KQL
Draft KQLDownload KQL
// SCHEMA TEMPLATE: create/map this custom table before use; not a built-in Sentinel table.
// OpenAttacksAudit_CL: TimeGenerated(datetime), EventType/Actor/Asset/Action/Target/CorrelationId(string).
// Selects candidates only. Apply the stage hypothesis and correlation steps before alerting.
OpenAttacksAudit_CL
| where TimeGenerated > ago(7d)
| where EventType in ("data.export", "agent.external.send")
| project TimeGenerated, EventType, Actor, Asset, Action, Target, CorrelationId
| order by TimeGenerated desc
SPL
Draft SPLDownload SPL
sourcetype="openattacks:audit"
EventType IN ("data.export", "agent.external.send")
| table _time EventType Actor Asset Action Target CorrelationId
| sort - _time
Investigation steps
  1. Join the resource read and outbound action by session, identity or process, preserving a bounded time window.
  2. Inspect destination ownership, payload classification and the user's intended action; baseline sanctioned sharing.
Technical detailsTooling, impact

Attack context

AI's role
LLM-generated malware
Initial access
Web shell deployment on Linux servers (custom and GitHub open-source shells)

Tooling as reported

AI products, models and artifacts

  • LLM-assisted script generation (inferred from code artifacts)

Other tooling

Targets and reported impact

Targets / sectors
Government entities and state-affiliated infrastructure
Reported scale / exposure
Activity window Oct 2025–Apr 2026; multiple C2 IPs listed in report

Reported attribution

CL-UNK-1211

Structured attribution

Actor
CL-UNK-1211

Detection rules

  • Review attack-specific indicatorsGUIDANCE

    Monitor for the techniques described in CL-UNK-1211 AI-assisted Linux government campaign. Refer to sources for specific IOCs and TTPs.

Source defensive notes

Detect auto_prepend_file changes, *.gsocket.io traffic, binaries from /dev/shm; Jose take: AI made old Linux tradecraft cheaper

Sources & research credit

1 source

Research by Roey Porat, Tom Fakterman · Unit 42 (Palo Alto Networks)

  1. unit42.paloaltonetworks.com
Record & downloads
Source record name
CL-UNK-1211 AI-assisted Linux government campaign
Entry ID
cl-unk-1211-unit42-2026-10
Catalog review
October 20, 2026
Category
adversary-use-of-ai
AI involvement confidence
unverified