YARA · SEKOIA.IO Community
SEKOIA_Apt_Unc4990_Emptyspace_Pyc
Detects Python Bytecode of EmptySpace
- Author
- Sekoia.io
- Date
- 2024-02-01
- Modified
- 2024-12-19
- Score / Quality
- 75 / 78
What this rule detects
Detects Python Bytecode of EmptySpace
It defines 29 patterns (29 text, 0 hex, 0 regex).
Summary generated from the rule's metadata and condition.
Rule source
apt-unc4990-emptyspace-pyc.yarDetection Rule License 1.1
rule SEKOIA_Apt_Unc4990_Emptyspace_Pyc : FILE
{
meta:
= "Detects Python Bytecode of EmptySpace"
= "Sekoia.io"
= "d970fd9c-1ce5-471c-96a1-146250f36b89"
= "2024-02-01"
= "2024-12-19"
= "https://github.com/SEKOIA-IO/Community"
= "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/yara_rules/apt_unc4990_emptyspace_pyc.yar#L1-L43"
= "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/LICENSE.md"
= "98e9c848f6b6276815b040681d7f36548b367257bb75d133309e89e8572a50b7"
= 75
= 78
= "FILE"
= "1.0"
= "TLP:CLEAR"
strings:
$ = "PYBOOTSTRAP"
$ = "http://google.com/generate_204"
$ = "from"
$ = "pathZ"
$ = "usernamez"
$ = "timeZ"
$ = "win32api"
$ = "base64Z"
$ = "json"
$ = "marshalZ"
$ = "BOOTSTRAP_VERSION"
$ = "getZ"
$ = "sleepZ b64encode"
$ = "dumps"
$ = "executableZ"
$ = "GetUserNameExZ"
$ = "NameSamCompatible"
$ = "encode"
$ = "decodeZ"
$ = "request_dataZ"
$ = "server"
$ = "post"
$ = "raise_for_status"
$ = "exec"
$ = "loadsZ b64decode"
$ = "text"
$ = "globals"
$ = "bootstrap.py"
$ = "<module>"
condition:
uint32be( 0 ) == 0x420d0d0a and all of them
}
Strings (29 patterns)
| Identifier | Type | Value | Modifiers |
|---|---|---|---|
| $ | text | "PYBOOTSTRAP" | |
| $ | text | "http://google.com/generate_204" | |
| $ | text | "from" | |
| $ | text | "pathZ" | |
| $ | text | "usernamez" | |
| $ | text | "timeZ" | |
| $ | text | "win32api" | |
| $ | text | "base64Z" | |
| $ | text | "json" | |
| $ | text | "marshalZ" | |
| $ | text | "BOOTSTRAP_VERSION" | |
| $ | text | "getZ" | |
| $ | text | "sleepZ b64encode" | |
| $ | text | "dumps" | |
| $ | text | "executableZ" | |
| $ | text | "GetUserNameExZ" | |
| $ | text | "NameSamCompatible" | |
| $ | text | "encode" | |
| $ | text | "decodeZ" | |
| $ | text | "request_dataZ" | |
| $ | text | "server" | |
| $ | text | "post" | |
| $ | text | "raise_for_status" | |
| $ | text | "exec" | |
| $ | text | "loadsZ b64decode" | |
| $ | text | "text" | |
| $ | text | "globals" | |
| $ | text | "bootstrap.py" | |
| $ | text | "<module>" |
Condition
uint32be( 0 ) == 0x420d0d0a and all of themIn 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.
References
Licence & attribution
Author: Sekoia.io
Source repository: SEKOIA.IO Community @ a438a5901a
Licence: Detection Rule License 1.1 (repository licence)
Mirrored via YARA Forge 20260927, which prefixes rule names with the source and adds normalised meta fields.
Rule id: d970fd9c-1ce5-471c-96a1-146250f36b89
Metadata
| version | 1.0 |
|---|---|
| classification | TLP:CLEAR |
Tags:FILE
Related rules
- APT / threat actorSEKOIA.IO Community· Sekoia.io· 2024-09-10
- APT / threat actorSEKOIA.IO Community· Sekoia.io· 2024-10-21
- APT / threat actorSEKOIA.IO Community· Sekoia.io· 2024-10-21
- APT / threat actorSEKOIA.IO Community· Sekoia.io· 2024-09-27
- APT / threat actorSEKOIA.IO Community· Sekoia.io· 2024-09-27
- APT / threat actorSEKOIA.IO Community· Sekoia.io· 2024-09-23
- APT / threat actorSEKOIA.IO Community· Sekoia.io· 2024-06-11
- APT / threat actorSEKOIA.IO Community· Sekoia.io· 2024-03-06