Skip to content

YARA · Embee Research

EMBEERESEARCH_Win_Njrat_Bytecodes_V2_Oct_2023

MalwareNjratEmbee ResearchDetection Rule License 1.1Compiles with YARA-X
Author
Matthew @ Embee_Research
Date
2023-10-03
Modified
2023-10-08
Score / Quality
75 / 75

What this rule detects

Associated malware family: Njrat.

Targets: .NET assembly.

It defines 2 patterns (0 text, 2 hex, 0 regex). YARA modules used: dotnet.

Summary generated from the rule's metadata and condition.

Rule source

Includes the imports needed to compile it on its own.

win-njrat-bytecodes-v2-oct-2023.yarDetection Rule License 1.1
import "dotnet"

rule EMBEERESEARCH_Win_Njrat_Bytecodes_V2_Oct_2023
{
	meta:
		description = ""
		author = "Matthew @ Embee_Research"
		id = "9090574e-7ad4-5207-af8b-7b56f2a1c917"
		date = "2023-10-03"
		modified = "2023-10-08"
		reference = "https://github.com/embee-research/Yara-detection-rules/"
		source_url = "https://github.com/embee-research/Yara-detection-rules//blob/ac56d6f6fd2a30c8cb6e5c0455d6519210a8b0f4/Rules/win_njrat_bytecodes_v2_oct_2023.yar#L5-L27"
		license_url = "N/A"
		hash = "9877fc613035d533feda6adc6848e183bf8c8660de3a34b1acd73c75e62e2823"
		hash = "40f07bdfb74e61fe7d7973bcd4167ffefcff2f8ba2ed6f82e9fcb5a295aaf113"
		logic_hash = "0bdbf5715e3873d96c88a24ba08487af2b798d26cdcd3e35d783ce4828dae775"
		score = 75
		quality = 75
		tags = ""

	strings:
		$s1 = {03 1F 72 2E ?? 03 1F 73 2E ?? 03 1F 74 2E ?? 03 1F 75 2E ?? 03 1F 76 2E ?? }
		$s2 = {0B 14 0C 16 0D 16 13 ?? 16 13 ?? 14}

	condition:
		dotnet.is_dotnet and ( all of ( $s* ) )
}

Strings (2 patterns)

IdentifierTypeValueModifiers
$s1hex{03 1F 72 2E ?? 03 1F 73 2E ?? 03 1F 74 2E ?? 03 1F 75 2E ?? 03 1F 76 2E ?? }
$s2hex{0B 14 0C 16 0D 16 13 ?? 16 13 ?? 14}

Condition

dotnet.is_dotnet and ( all of ( $s* ) )

In plain words (Heuristic)

  • All patterns in ( $s* ) must match.
  • Uses the dotnet module.

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).

  • 9877fc613035d533feda6adc6848e183bf8c8660de3a34b1acd73c75e62e2823
  • 40f07bdfb74e61fe7d7973bcd4167ffefcff2f8ba2ed6f82e9fcb5a295aaf113

Licence & attribution

Author: Matthew @ Embee_Research

Source repository: Embee Research @ ac56d6f6fd

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: 9090574e-7ad4-5207-af8b-7b56f2a1c917

More Njrat rules