YARA · SEKOIA.IO Community
SEKOIA_Apt_Luckymouse_Rshell_Strings
Detects LuckyMouse RShell Mach-O implant
- Author
- Sekoia.io
- Date
- 2022-08-05
- Modified
- 2024-12-19
- Score / Quality
- 75 / 80
What this rule detects
Detects LuckyMouse RShell Mach-O implant
Targets: Windows PE, macOS Mach-O.
It defines 2 patterns (0 text, 2 hex, 0 regex).
Summary generated from the rule's metadata and condition.
Rule source
apt-luckymouse-rshell-strings.yarDetection Rule License 1.1
rule SEKOIA_Apt_Luckymouse_Rshell_Strings : FILE
{
meta:
= "Detects LuckyMouse RShell Mach-O implant"
= "Sekoia.io"
= "89f18013-ea3e-440f-821e-cef102a43b7b"
= "2022-08-05"
= "2024-12-19"
= "https://github.com/SEKOIA-IO/Community"
= "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/yara_rules/apt_luckymouse_rshell_strings.yar#L1-L26"
= "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/LICENSE.md"
= "ffca47856d4c4d83312220cff23c0a556be0e675d59ac009c2f74fc0e39cb816"
= 75
= 80
= "FILE"
= "1.0"
= "TLP:CLEAR"
strings:
$ = { 64 69 72 00 70 61 74 68
00 64 6F 77 6E 00 72 65
61 64 00 75 70 6C 6F 61
64 00 77 72 69 74 65 00
64 65 6C }
$ = { 6C 6F 67 69 6E 00 68 6F
73 74 6E 61 6D 65 00 6C
61 6E 00 75 73 65 72 6E
61 6D 65 00 76 65 72 73
69 6F 6E }
condition:
( uint32be( 0 ) == 0xCFFAEDFE or uint16be( 0 ) == 0x4d5a ) and filesize < 300KB and all of them
}
Strings (2 patterns)
| Identifier | Type | Value | Modifiers |
|---|---|---|---|
| $ | hex | { 64 69 72 00 70 61 74 68 00 64 6F 77 6E 00 72 65 61 64 00 75 70 6C 6F 61 64 00 77 72 69 74 65 00 64 65 6C } | |
| $ | hex | { 6C 6F 67 69 6E 00 68 6F 73 74 6E 61 6D 65 00 6C 61 6E 00 75 73 65 72 6E 61 6D 65 00 76 65 72 73 69 6F 6E } |
Condition
( uint32be( 0 ) == 0xCFFAEDFE or uint16be( 0 ) == 0x4d5a ) and filesize < 300KB and all of themIn plain words (Heuristic)
- The file must start with “MZ” — a Windows executable (PE).
- The file must start with a Mach-O / fat binary magic — a macOS executable.
- The file must be smaller than 300KB (a cheap guard that skips large files).
- 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: 89f18013-ea3e-440f-821e-cef102a43b7b
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