This is a stealer used by LockBit 2.0.
rule win_stealbit_auto { meta: author = "Felix Bilstein - yara-signator at cocacoding dot com" date = "2023-03-28" version = "1" description = "Detects win.stealbit." info = "autogenerated rule brought to you by yara-signator" tool = "yara-signator v0.6.0" signator_config = "callsandjumps;datarefs;binvalue" malpedia_reference = "https://malpedia.caad.fkie.fraunhofer.de/details/win.stealbit" malpedia_rule_date = "20230328" malpedia_hash = "9d2d75cef573c1c2d861f5197df8f563b05a305d" malpedia_version = "20230407" malpedia_license = "CC BY-SA 4.0" malpedia_sharing = "TLP:WHITE" /* DISCLAIMER * The strings used in this rule have been automatically selected from the * disassembly of memory dumps and unpacked files, using YARA-Signator. * The code and documentation is published here: * https://github.com/fxb-cocacoding/yara-signator * As Malpedia is used as data source, please note that for a given * number of families, only single samples are documented. * This likely impacts the degree of generalization these rules will offer. * Take the described generation method also into consideration when you * apply the rules in your use cases and assign them confidence levels. */ strings: $sequence_0 = { e8???????? 8b0f e8???????? 8d7f38 83eb01 75e9 8b96b4020000 } // n = 7, score = 300 // e8???????? | // 8b0f | mov ecx, dword ptr [edi] // e8???????? | // 8d7f38 | lea edi, [edi + 0x38] // 83eb01 | sub ebx, 1 // 75e9 | jne 0xffffffeb // 8b96b4020000 | mov edx, dword ptr [esi + 0x2b4] $sequence_1 = { 85c0 0f8529ffffff 57 56 6a05 5a 8d4df4 } // n = 7, score = 300 // 85c0 | test eax, eax // 0f8529ffffff | jne 0xffffff2f // 57 | push edi // 56 | push esi // 6a05 | push 5 // 5a | pop edx // 8d4df4 | lea ecx, [ebp - 0xc] $sequence_2 = { 8bcf e8???????? 85c0 0f8511010000 53 8d45ac 8bd6 } // n = 7, score = 300 // 8bcf | mov ecx, edi // e8???????? | // 85c0 | test eax, eax // 0f8511010000 | jne 0x117 // 53 | push ebx // 8d45ac | lea eax, [ebp - 0x54] // 8bd6 | mov edx, esi $sequence_3 = { 5a 8bce e8???????? 85c0 740c f0ff8eac020000 e9???????? } // n = 7, score = 300 // 5a | pop edx // 8bce | mov ecx, esi // e8???????? | // 85c0 | test eax, eax // 740c | je 0xe // f0ff8eac020000 | lock dec dword ptr [esi + 0x2ac] // e9???????? | $sequence_4 = { eb03 8b4618 5e c9 c3 55 8bec } // n = 7, score = 300 // eb03 | jmp 5 // 8b4618 | mov eax, dword ptr [esi + 0x18] // 5e | pop esi // c9 | leave // c3 | ret // 55 | push ebp // 8bec | mov ebp, esp $sequence_5 = { 668985befeffff 6a65 58 6a63 668985c0feffff 58 6a79 } // n = 7, score = 300 // 668985befeffff | mov word ptr [ebp - 0x142], ax // 6a65 | push 0x65 // 58 | pop eax // 6a63 | push 0x63 // 668985c0feffff | mov word ptr [ebp - 0x140], ax // 58 | pop eax // 6a79 | push 0x79 $sequence_6 = { 884106 e8???????? 6a04 6a49 884107 e8???????? } // n = 6, score = 300 // 884106 | mov byte ptr [ecx + 6], al // e8???????? | // 6a04 | push 4 // 6a49 | push 0x49 // 884107 | mov byte ptr [ecx + 7], al // e8???????? | $sequence_7 = { 0f85f4010000 6a0c 8d85a0feffff 8bd6 50 8bcf e8???????? } // n = 7, score = 300 // 0f85f4010000 | jne 0x1fa // 6a0c | push 0xc // 8d85a0feffff | lea eax, [ebp - 0x160] // 8bd6 | mov edx, esi // 50 | push eax // 8bcf | mov ecx, edi // e8???????? | $sequence_8 = { 50 8bcf e8???????? 85c0 0f85e1000000 53 8d459c } // n = 7, score = 300 // 50 | push eax // 8bcf | mov ecx, edi // e8???????? | // 85c0 | test eax, eax // 0f85e1000000 | jne 0xe7 // 53 | push ebx // 8d459c | lea eax, [ebp - 0x64] $sequence_9 = { 3bc1 7222 33d2 8b7d14 8bd9 f7f3 8bd0 } // n = 7, score = 300 // 3bc1 | cmp eax, ecx // 7222 | jb 0x24 // 33d2 | xor edx, edx // 8b7d14 | mov edi, dword ptr [ebp + 0x14] // 8bd9 | mov ebx, ecx // f7f3 | div ebx // 8bd0 | mov edx, eax condition: 7 of them and filesize < 131072 }
rule win_stealbit_w0 { meta: description = "Detects Stealbit used by Lockbit 2.0 Ransomware Gang" author = "Frank Boldewin (@r3c0nst)" reference = "https://raw.githubusercontent.com/fboldewin/YARA-rules/master/Lockbit2.Stealbit.yar" date = "2021-08-12" hash1 = "3407f26b3d69f1dfce76782fee1256274cf92f744c65aa1ff2d3eaaaf61b0b1d" hash2 = "bd14872dd9fdead89fc074fdc5832caea4ceac02983ec41f814278130b3f943e" malpedia_reference = "https://malpedia.caad.fkie.fraunhofer.de/details/win.stealbit" malpedia_rule_date = "20210818" malpedia_hash = "" malpedia_version = "20210818" malpedia_license = "CC BY-SA 4.0" malpedia_sharing = "TLP:WHITE" strings: $C2Decryption = {33 C9 8B C1 83 E0 0F 8A 80 ?? ?? ?? ?? 30 81 ?? ?? ?? ?? 41 83 F9 7C 72 E9 E8} condition: uint16(0) == 0x5A4D and filesize < 100KB and $C2Decryption }
If your designated proposal does not fit in any other category, feel free to write a free-text in the comment field below.
Please propose all changes regarding references on the Malpedia library page
Your suggestion will be reviewed before being published. Thank you for contributing!
YYYY-MM-DD
YYYY-MM
YYYY