← Back to SOC feed Coverage →

Identifies XOR'd strings used in Cobalt Strike Beacon DLL

yara LOW signature-base
cobalt-strikecobaltstrike_beaconflorian-roth
This rule was pulled from an open-source repository and enriched with AI. Validate in a test environment before deploying to production.
View original rule at signature-base →
Retrieved: 2026-08-02T23:00:00Z · Confidence: medium

Hunt Hypothesis

This rule detects adversaries employing Cobalt Strike’s Beacon DLL to obfuscate command and control traffic through XOR-encoded strings, a technique often used to evade signature-based detection during post-exploitation phases. SOC teams should proactively hunt for this behavior in Azure Sentinel because identifying these specific XOR patterns early allows analysts to uncover stealthy lateral movement activities that might otherwise remain hidden within standard network logs.

YARA Rule

rule HKTL_CobaltStrike_Beacon_XOR_Strings {
   meta:
      author = "Elastic"
      description = "Identifies XOR'd strings used in Cobalt Strike Beacon DLL"
      reference = "https://www.elastic.co/blog/detecting-cobalt-strike-with-memory-signatures"
      date = "2021-03-16"
      modified = "2026-05-26"
      /* Used for beacon config decoding in THOR */
      xor_s1 = "%02d/%02d/%02d %02d:%02d:%02d"
      xor_s2 = "Started service %s on %s"
      xor_s3 = "%s as %s\\%s: %d"
      id = "359160a8-cf1c-58a8-bf7f-c09a8d661308"
   strings:
      $s1 = "%02d/%02d/%02d %02d:%02d:%02d" xor(0x01-0xff)
      $s2 = "Started service %s on %s" xor(0x01-0xff)
      $s3 = "%s as %s\\%s: %d" xor(0x01-0xff)

      $fp1 = "MalwareRemovalTool" ascii wide
      $fp2 = "advanced malware removal tool" ascii wide
   condition:
      2 of ($s*) and not 1 of ($fp*)
}

Deployment Notes

This YARA rule can be deployed in the following contexts:

This rule contains 5 string patterns in its detection logic.

References

False Positive Guidance

Here are 5 specific false positive scenarios for the Cobalt Strike Beacon DLL XOR String detection rule, including targeted filters and exclusions:

Original source: https://github.com/Neo23x0/signature-base/blob/main/yara/apt_cobaltstrike.yar