Detection rules · Sigma, Cortex XQL, YARA

All rules, every day

The catalogue of Threat Brief rules since day one: filter by format, period, level or ATT&CK technique, open a rule to read its code, and download the selection as one file.

6 rules over 6 days · 1 repeat hidden (show) · technique T1195.002 (remove) Most recent first
DateFormatRule and topicLevelATT&CK
18/11 YARA agent-framework 1.26.1 and 1.26.2 credential stealer and .pth hookPyPI: Microsoft's official agent-framework package ships two poisoned versions (1.26.1, 1.26.2) stealing Azure, GitHub and CI credentials high T1195.002 T1552.001
tb-2026-11-18-voleur-d-identifiants-et-hook-pth-d-agent-framework-1-26-1-e.yarDownload YARA rule
rule TB_20261118_agent_framework_pth_stealer
{
    meta:
        author = "Threat Brief (tlpclear.fr)"
        date = "2026-11-18"
        reference = "https://socket.dev/blog/agent-framework-pypi-package-compromised-with-credential-stealer?utm_medium=feed"
        description = "Credential stealer and .pth startup hook of the compromised agent-framework PyPI releases 1.26.1 and 1.26.2"
        status = "experimental"
    strings:
        $enc = "aHR0cHM6Ly93ZWJob29rLnNpdGUvZDM4MWZkODAtZWM2Mi00MmFkLThmNWMtZDFiMTUxMDNjOWJi" ascii
        $guard = "_AF_TEL" ascii
        $ua1 = "af-runtime-diagnostics/1" ascii
        $ua2 = "runtime-diagnostics/1" ascii
        $hook = "Lightweight runtime diagnostics hook" ascii
        $gh = "ACTIONS_ID_TOKEN_REQUEST_URL" ascii
        $ado = "SYSTEM_OIDCREQUESTURI" ascii
        $pth1 = "import agent_framework_meta" ascii
        $pth2 = "import af_runtime_diag" ascii
    condition:
        (filesize < 200KB and ($enc or ($guard and 2 of ($ua*, $hook, $gh, $ado))))
        or (filesize < 256 and 1 of ($pth*))
}
yara: compiled Python or .pth file (site-packages) Licence DRL 1.1

Matches the stealer module (Base64-encoded exfiltration URL, _AF_TEL guard, User-Agent, GitHub and Azure DevOps OIDC tokens) and the one-line .pth files importing it. False positives: sample copies in analysis repositories.

8 quotes from the sources
  • “_ENC = "aHR0cHM6Ly93ZWJob29rLnNpdGUvZDM4MWZkODAtZWM2Mi00MmFkLThmNWMtZDFiMTUxMDNjOWJi"” socket.dev
  • “if os.environ.get( "_AF_TEL" ): return” socket.dev
  • “# Lightweight runtime diagnostics hook try” socket.dev
  • “u = os.environ.get( "ACTIONS_ID_TOKEN_REQUEST_URL" )” socket.dev
  • “SYSTEM_ACCESSTOKEN and SYSTEM_OIDCREQUESTURI for Azure DevOps federation tokens” socket.dev
  • “agent_framework_meta.pth contains one line: import agent_framework_meta” www.wiz.io
  • “a 23-byte af_runtime_diag.pth containing a single line, import af_runtime_diag” www.stepsecurity.io
  • “User-Agent runtime-diagnostics/1 ( af-runtime-diagnostics/1 in 1.26.1)” www.stepsecurity.io
17/11 YARA OPTIMJACK track.js payload (clipper, skimmer, iOS loader)Optimizely: a signup flow flaw exploited to hijack scripts served to about 180 organisations (OPTIMJACK) high T1195.002 T1056.003
tb-2026-11-17-charge-track-js-d-optimjack-clipper-skimmer-chargeur-ios.yarDownload YARA rule
rule TB_20261117_OPTIMJACK_track_js
{
    meta:
        author = "Threat Brief (tlpclear.fr)"
        date = "2026-11-17"
        reference = "https://www.stepsecurity.io/blog/optimjack-optimizely-hosted-scripts-crypto-clipper-card-skimmer"
        description = "OPTIMJACK track.js (crypto clipper, card skimmer, iOS stage loader) served through Optimizely-hosted scripts: payload host, exfiltration paths, iOS iframe path and page globals"
        status = "experimental"
    strings:
        $host = "1688360.cc" ascii nocase
        $ios = "/JIUJIU888/weifile.html" ascii
        $p1 = "/card.php" ascii
        $p2 = "/hit.php" ascii
        $p3 = "html2canvas.min.js" ascii
        $g1 = "_qxc" ascii
        $g2 = "_shot" ascii
    condition:
        uint16(0) != 0x5a4d and filesize < 500KB and ($ios or ($host and 1 of ($p*)) or (all of ($g*) and 2 of ($p*)))
}
yara: compiled JavaScript file Licence DRL 1.1

Matches the JavaScript payload, or a copy embedded in an Optimizely script, by its host, exfiltration paths, iOS iframe path and page globals; the payload changed four times on 16/11, hence a content rule rather than a hash. Does not cover the Base64-encoded loader. False positives: analysis reports or blocklists quoting these paths.

4 quotes from the sources
15/11 YARA Backdoored extension.js of the Claude Code extension (Cursor)Cursor: a key held by Fireworks AI, stolen agent traces and a trojanised Claude Code extension served for 11 hoursalso on 31/10 high T1195.002 T1098.004
tb-2026-11-15-extension-js-pi-g-de-l-extension-claude-code-cursor.yarDownload YARA rule
rule TB_20261115_Cursor_ClaudeCode_extension_js
{
    meta:
        author = "Threat Brief (tlpclear.fr)"
        date = "2026-11-15"
        reference = "https://cursor.com/blog/claude-code-extension-security-notice"
        description = "Backdoored extension.js of the trojanised Anthropic.claude-code 2.1.312 and 2.1.313 extension (Cursor marketplace, 29 October 2026)"
        status = "experimental"
    strings:
        $key = "svc-telemetry" ascii
        $ip = "134.209.82.225" ascii
        $tun = ":0:localhost:22" ascii
    condition:
        filesize < 15MB and $key and ($ip or $tun)
}
yara: compiled JavaScript file (extension) Licence DRL 1.1

Script containing the svc-telemetry SSH key comment together with the attacker IP or the reverse tunnel forwarding string, as described by Cursor for the malicious extension.js. False positives: Security reports or remediation scripts quoting these indicators.

2 quotes from the sources
10/11 YARA SleepyDuck loader from bee-js 13.3.0 and Swarm Desktop 0.56.2Supply chain: bee-js 13.3.0 and Swarm Desktop 0.56.2 deliver the SleepyDuck backdoor high T1195.002 T1059.007
tb-2026-11-10-loader-sleepyduck-de-bee-js-13-3-0-et-swarm-desktop-0-56-2.yarDownload YARA rule
rule TB_20261110_beejs_SleepyDuck_loader
{
    meta:
        author = "Threat Brief (tlpclear.fr)"
        date = "2026-11-10"
        reference = "https://socket.dev/blog/bee-js-compromise"
        description = "SleepyDuck loader from bee-js 13.3.0 (scripts/generate-version.cjs) and Swarm Desktop 0.56.2 (Electron main process)"
        status = "experimental"
    strings:
        $d = "frameworkmetrics.xyz" ascii wide
        $p1 = "/v1/analytics" ascii wide
        $p2 = "/v1/electron" ascii wide
        $p3 = "/v1/swarm/report" ascii wide
        $h = "X-Ethersphere" ascii wide nocase
    condition:
        filesize < 200MB and $d and 1 of ($p*, $h)
}
yara: compiled JS file, asar archive or installer Licence DRL 1.1

Matches generate-version.cjs, index.js or app.asar containing the stage 1 domain and the paths /v1/analytics, /v1/electron, /v1/swarm/report or the X-Ethersphere header. False positives: analysis reports or IOC lists containing these strings.

09/11 YARA testmetest worm index.js and sync.pyRubyGems strutil-core 1.0.1: testmetest worm returns, with wiper on revocation high T1195.002 T1059.006
tb-2026-11-09-index-js-et-sync-py-du-ver-testmetest.yarDownload YARA rule
import "hash"

rule TB_20261109_strutil_core_testmetest
{
    meta:
        author = "Threat Brief (tlpclear.fr)"
        date = "2026-11-09"
        reference = "https://socket.dev/blog/shai-hulud-descendant-malicious-ruby-gem"
        description = "index.js payload and sync.py backdoor of the testmetest worm (strutil-core 1.0.1 gem): markers and hashes published by Socket"
        status = "experimental"
    strings:
        $m1 = "msync-3f7a" ascii
        $m2 = "AutoSyncComplete" ascii
        $m3 = "paleasbest.top" ascii
        $m4 = "/var/tmp/.fontconfig_state" ascii
        $m5 = "net-health-checker" ascii
        $m6 = "workspace-tools" ascii
        $m7 = "bun-v1.2.18" ascii
    condition:
        uint16(0) != 0x5a4d and uint32(0) != 0x464c457f and filesize < 8MB and
        (
            2 of ($m1, $m2, $m3, $m4) or
            ($m3 and 2 of ($m5, $m6, $m7)) or
            hash.sha256(0, filesize) == "c7ef186aa59b67d9b198a14f6dc8aaee6dd86510ac7c37d28f65d310cd846411" or
            hash.sha256(0, filesize) == "306c1deec402e8b4a6478e7f0fe02194bcd224d37d8fc6ba61ad1951e8abd7a9" or
            hash.sha256(0, filesize) == "c5264f3b9cf2f95c83a70b7dd7430aab8abc262b853dbbcd5386c3a8a9c74769"
        )
}
yara: compiled script files (JS, Python, Ruby) Licence DRL 1.1

msync-3f7a, AutoSyncComplete, paleasbest.top markers and hashes published by Socket for payload, backdoor and installer. False positives: analysis reports or rule repositories containing these strings.

03/11 YARA extension.js of the weaponised Claude Code loaderTrojanised "Claude Code" extension on the Cursor marketplace: SSH backdoor high T1195.002 T1098.004
tb-2026-11-03-extension-js-du-loader-claude-code-pi-g.yarDownload YARA rule
rule TB_20261103_ClaudeCode_Cursor_extension_loader
{
    meta:
        author = "Threat Brief (tlpclear.fr)"
        date = "2026-11-03"
        reference = "https://opensourcemalware.com/blog/trojanized-claude-code-extension-plants-persistent-ssh-backdoor"
        description = "Weaponised extension.js from anthropic.claude-code extension (Cursor marketplace): svc-telemetry key, authorized_keys, and reverse SSH tunnel"
        status = "experimental"
    strings:
        $k1 = "svc-telemetry" ascii
        $k2 = "authorized_keys" ascii
        $k3 = "134.209.82.225" ascii
        $k4 = "localhost:22" ascii
        $k5 = "child_process" ascii
    condition:
        filesize < 30MB and $k5 and 3 of ($k1, $k2, $k3, $k4)
}
yara: compiled JavaScript file (extension.js) Licence DRL 1.1

Strings from the injected loader prepended to extension.js: svc-telemetry key, authorized_keys, tunnel to 134.209.82.225. False positives: None known.