YARA · SEKOIA.IO Community
SEKOIA_Downloader_Win_Newsterminal
Detect the PowerShell based downloader used by APT42 called NEWSTERMINAL
- Author
- Sekoia.io
- Date
- 2024-08-26
- Modified
- 2024-12-19
- Score / Quality
- 75 / 78
What this rule detects
Detect the PowerShell based downloader used by APT42 called NEWSTERMINAL
It defines 4 patterns (3 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
rule SEKOIA_Downloader_Win_Newsterminal : FILE
{
meta:
= "Detect the PowerShell based downloader used by APT42 called NEWSTERMINAL"
= "Sekoia.io"
= "2f9aae45-e3bd-4d87-b336-5d141738952b"
= "2024-08-26"
= "2024-12-19"
= "https://github.com/SEKOIA-IO/Community"
= "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/yara_rules/downloader_win_newsterminal.yar#L1-L20"
= "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/LICENSE.md"
= "2b756515400d7e3b6e21ee3a83f313c8"
= "45c6c2b5b3723bf3ed46c82e6a254547d8c8b3446bb2fa4b4f0fc8441731ae7e"
= 75
= 78
= "FILE"
= "1.0"
= "TLP:CLEAR"
strings:
$ = "Start-Process -FilePath $takeownCommand -ArgumentList $takeownArgs -Wait -NoNewWindow"
$ = "function Download-And-Extract-Dll {"
$ = {24 69 63 61 63 6C 73 41 72 67 73 20 3D 20 24 64 65 73 74 69 6E 61 74 69 6F 6E 46 69 6C 65 50 61 74 68 2C 20 22 2F 67 72 61 6E 74 22 2C 20 22 41 64 6D 69 6E 69 73 74 72 61 74 6F 72 73 3A 46 22 2C 20 22 2F 63 22 2C 20 22 2F 71 22}
$ = "$publicip=(iwr http://127.0.0.1:4040/api/tunnels"
condition:
1 of them and filesize < 30KB
}
Strings (4 patterns)
| Identifier | Type | Value | Modifiers |
|---|---|---|---|
| $ | text | "Start-Process -FilePath $takeownCommand -ArgumentList $takeownArgs -Wait -NoNewWindow" | |
| $ | text | "function Download-And-Extract-Dll {" | |
| $ | hex | {24 69 63 61 63 6C 73 41 72 67 73 20 3D 20 24 64 65 73 74 69 6E 61 74 69 6F 6E 46 69 6C 65 50 61 74 68 2C 20 22 2F 67 72 61 6E 74 22 2C 20 22 41 64 6D 69 6E 69 … | |
| $ | text | "$publicip=(iwr http://127.0.0.1:4040/api/tunnels" |
Condition
1 of them and filesize < 30KBIn plain words (Heuristic)
- The file must be smaller than 30KB (a cheap guard that skips large files).
- At least 1 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.
References
Sample hashes
Hashes of samples the author lists in the rule's meta (look them up in your threat-intelligence platform).
- 2b756515400d7e3b6e21ee3a83f313c8
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: 2f9aae45-e3bd-4d87-b336-5d141738952b
Metadata
| version | 1.0 |
|---|---|
| classification | TLP:CLEAR |
Tags:FILE
Related rules
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-07-16
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-08-23
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-04-22
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-07-23
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-10-20
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-03-20
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-03-20
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-03-20