Skip to content

YARA · Google Cloud Threat Intelligence (GCTI)

GCTI_Cobaltstrike_Resources__Template_Vbs_V3_3_To_V4_X

Cobalt Strike's resources/btemplate.vbs signature for versions v3.3 to v4.x

Hack toolCobalt StrikeGoogle Cloud Threat Intelligence (GCTI)Apache License 2.0Compiles with YARA-X (with warnings)
Author
gssincla@google.com
Date
2022-11-18
Modified
2022-11-22
Score / Quality
75 / 83

What this rule detects

Cobalt Strike's resources/btemplate.vbs signature for versions v3.3 to v4.x

Associated malware family: Cobalt Strike.

It defines 10 patterns (9 text, 1 hex, 0 regex).

YARA-X says: warning[text_as_hex]: hex pattern could be written as text literal

Summary generated from the rule's metadata and condition.

Rule source

cobaltstrike-resources-template-vbs-v3-3-to-v4-x.yarApache License 2.0
rule GCTI_Cobaltstrike_Resources__Template_Vbs_V3_3_To_V4_X
{
	meta:
		description = "Cobalt Strike's resources/btemplate.vbs signature for versions v3.3 to v4.x"
		author = "gssincla@google.com"
		id = "62f35d02-1e4e-5651-b575-888ce06b8bdd"
		date = "2022-11-18"
		modified = "2022-11-22"
		reference = "https://cloud.google.com/blog/products/identity-security/making-cobalt-strike-harder-for-threat-actors-to-abuse"
		source_url = "https://github.com/chronicle/GCTI/blob/1c5fd42b1895098527fde00c2d9757edf6b303bb/YARA/CobaltStrike/CobaltStrike__Resources_Template_Vbs_v3_3_to_v4_x.yara#L17-L41"
		license_url = "https://github.com/chronicle/GCTI/blob/1c5fd42b1895098527fde00c2d9757edf6b303bb/LICENSE"
		hash = "e0683f953062e63b2aabad7bc6d76a78748504b114329ef8e2ece808b3294135"
		logic_hash = "c9df0e287eb0eacf7c6cfcf3f6d1043ae6f2fdacd3b22bd42ac71f4b0d7226ff"
		score = 75
		quality = 83
		tags = ""

	strings:
		$ea = "Excel.Application" nocase
		$vis = "Visible = False" nocase
		$wsc = "Wscript.Shell" nocase
		$regkey1 = "HKEY_CURRENT_USER\\Software\\Microsoft\\Office\\" nocase
		$regkey2 = "\\Excel\\Security\\AccessVBOM" nocase
		$regwrite = ".RegWrite" nocase
		$dw = "REG_DWORD"
		$code = ".CodeModule.AddFromString"
		$ao = { 41 75 74 6f 5f 4f 70 65 6e }
		$da = ".DisplayAlerts"

	condition:
		all of them
}

Strings (10 patterns)

IdentifierTypeValueModifiers
$eatext"Excel.Application"nocase
$vistext"Visible = False"nocase
$wsctext"Wscript.Shell"nocase
$regkey1text"HKEY_CURRENT_USER\\Software\\Microsoft\\Office\\"nocase
$regkey2text"\\Excel\\Security\\AccessVBOM"nocase
$regwritetext".RegWrite"nocase
$dwtext"REG_DWORD"
$codetext".CodeModule.AddFromString"
$aohex{ 41 75 74 6f 5f 4f 70 65 6e }
$datext".DisplayAlerts"

Condition

all of them

In plain words (Heuristic)

  • 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

Sample hashes

Hashes of samples the author lists in the rule's meta (look them up in your threat-intelligence platform).

  • e0683f953062e63b2aabad7bc6d76a78748504b114329ef8e2ece808b3294135

Licence & attribution

Author: gssincla@google.com

Source repository: Google Cloud Threat Intelligence (GCTI) @ 1c5fd42b18

Licence: Apache License 2.0 (repository licence)

Original rule

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

Rule id: 62f35d02-1e4e-5651-b575-888ce06b8bdd

More Cobalt Strike rules