Skip to content

YARA · SEKOIA.IO Community

SEKOIA_Apt_Sidecopy_Malicious_Macro

Detects malicious macro used by SideCopy

APT / threat actorSEKOIA.IO CommunityDetection Rule License 1.1Compiles with YARA-X
Author
Sekoia.io
Date
2023-05-11
Modified
2024-12-19
Score / Quality
75 / 80

What this rule detects

Detects malicious macro used by SideCopy

Targets: OLE / legacy Office.

It defines 6 patterns (6 text, 0 hex, 0 regex).

Summary generated from the rule's metadata and condition.

Rule source

apt-sidecopy-malicious-macro.yarDetection Rule License 1.1
rule SEKOIA_Apt_Sidecopy_Malicious_Macro : FILE
{
	meta:
		description = "Detects malicious macro used by SideCopy"
		author = "Sekoia.io"
		id = "4b90c33e-48d4-48b6-87a7-c35686e7e913"
		date = "2023-05-11"
		modified = "2024-12-19"
		reference = "https://github.com/SEKOIA-IO/Community"
		source_url = "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/yara_rules/apt_sidecopy_malicious_macro.yar#L1-L21"
		license_url = "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/LICENSE.md"
		logic_hash = "b1d9d7af8507b478b2a8d34a4a5ca3714b219a42d5b3f9d5026d98351294e1cf"
		score = 75
		quality = 80
		tags = "FILE"
		version = "1.0"
		classification = "TLP:CLEAR"

	strings:
		$ = "htmlFile$"
		$ = "Gecko/20100101 Firefox/91.0"
		$ = "Start Menu\\Programs\\Startup\\"
		$ = "Document_Close"
		$ = "ThisDocument" wide
		$ = "ServerXMLHTTP.6.0"

	condition:
		uint32be( 0 ) == 0xD0CF11E0 and all of them
}

Strings (6 patterns)

IdentifierTypeValueModifiers
$text"htmlFile$"
$text"Gecko/20100101 Firefox/91.0"
$text"Start Menu\\Programs\\Startup\\"
$text"Document_Close"
$text"ThisDocument"wide
$text"ServerXMLHTTP.6.0"

Condition

uint32be( 0 ) == 0xD0CF11E0 and all of them

In plain words (Heuristic)

  • The file must start with the OLE header — legacy Office documents, MSI.
  • All patterns in the rule must match.

Test this rule in your browser

Drop a file to scan it with this rule using YARA-X compiled to WebAssembly. Nothing is uploaded.

Drop a file here or click to chooseScanned locally with YARA-X. Files up to 200 MB.

Open in editor

References

Licence & attribution

Author: Sekoia.io

Source repository: SEKOIA.IO Community @ a438a5901a

Licence: Detection Rule License 1.1 (repository licence)

Original rule

Mirrored via YARA Forge 20260927, which prefixes rule names with the source and adds normalised meta fields.

Rule id: 4b90c33e-48d4-48b6-87a7-c35686e7e913

Metadata

version1.0
classificationTLP:CLEAR

Tags:FILE