Actor(s): Leviathan
BADFLICK, a backdoor that is capable of modifying the file system, generating a reverse shell, and modifying its command-and-control configuration.
rule win_badflick_auto { meta: author = "Felix Bilstein - yara-signator at cocacoding dot com" date = "2026-09-17" version = "1" description = "Detects win.badflick." 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.badflick" malpedia_rule_date = "20260916" malpedia_hash = "53a643781c18e08f4a50949af60172d837a0b6f6" malpedia_version = "20260917" 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 = { 59 8b0e 8b09 83c604 894c07fc } // n = 5, score = 100 // 59 | pop ecx // 8b0e | mov ecx, dword ptr [esi] // 8b09 | mov ecx, dword ptr [ecx] // 83c604 | add esi, 4 // 894c07fc | mov dword ptr [edi + eax - 4], ecx $sequence_1 = { 53 ff15???????? 85c0 7411 3b7df8 } // n = 5, score = 100 // 53 | push ebx // ff15???????? | // 85c0 | test eax, eax // 7411 | je 0x13 // 3b7df8 | cmp edi, dword ptr [ebp - 8] $sequence_2 = { 85c0 7471 8b07 3b45fc 756a 0fb74606 } // n = 6, score = 100 // 85c0 | test eax, eax // 7471 | je 0x73 // 8b07 | mov eax, dword ptr [edi] // 3b45fc | cmp eax, dword ptr [ebp - 4] // 756a | jne 0x6c // 0fb74606 | movzx eax, word ptr [esi + 6] $sequence_3 = { 8bec 83ec1c 8365fc00 56 8b7510 85f6 7411 } // n = 7, score = 100 // 8bec | mov ebp, esp // 83ec1c | sub esp, 0x1c // 8365fc00 | and dword ptr [ebp - 4], 0 // 56 | push esi // 8b7510 | mov esi, dword ptr [ebp + 0x10] // 85f6 | test esi, esi // 7411 | je 0x13 $sequence_4 = { 8d44000a 50 6a41 e8???????? ff750c 8bf0 8d460d } // n = 7, score = 100 // 8d44000a | lea eax, [eax + eax + 0xa] // 50 | push eax // 6a41 | push 0x41 // e8???????? | // ff750c | push dword ptr [ebp + 0xc] // 8bf0 | mov esi, eax // 8d460d | lea eax, [esi + 0xd] $sequence_5 = { 53 50 ff15???????? ff75fc 8b35???????? } // n = 5, score = 100 // 53 | push ebx // 50 | push eax // ff15???????? | // ff75fc | push dword ptr [ebp - 4] // 8b35???????? | $sequence_6 = { 56 e8???????? 56 8bf8 57 ff750c ff7508 } // n = 7, score = 100 // 56 | push esi // e8???????? | // 56 | push esi // 8bf8 | mov edi, eax // 57 | push edi // ff750c | push dword ptr [ebp + 0xc] // ff7508 | push dword ptr [ebp + 8] $sequence_7 = { 59 50 8d85e0faffff 68???????? 50 ffd7 } // n = 6, score = 100 // 59 | pop ecx // 50 | push eax // 8d85e0faffff | lea eax, [ebp - 0x520] // 68???????? | // 50 | push eax // ffd7 | call edi $sequence_8 = { 50 6a41 e8???????? ff750c 8bf0 8d460d } // n = 6, score = 100 // 50 | push eax // 6a41 | push 0x41 // e8???????? | // ff750c | push dword ptr [ebp + 0xc] // 8bf0 | mov esi, eax // 8d460d | lea eax, [esi + 0xd] $sequence_9 = { 6a01 ff7305 e8???????? 59 50 56 e8???????? } // n = 7, score = 100 // 6a01 | push 1 // ff7305 | push dword ptr [ebx + 5] // e8???????? | // 59 | pop ecx // 50 | push eax // 56 | push esi // e8???????? | condition: 7 of them and filesize < 81920 }
rule win_badflick_w0 { meta: description = "Detects BADFLICK backdoor" author = "@VK_Intel" reference = "BADFLICK backdoor" date = "2018-03-26" hash = "7ba05abdf8f0323aa30c3d52e22df951eb5b67a2620014336eab7907b0a5cedf" reference = "https://www.fireeye.com/blog/threat-research/2018/03/suspected-chinese-espionage-group-targeting-maritime-and-engineering-industries.html" malpedia_reference = "https://malpedia.caad.fkie.fraunhofer.de/details/win.badflick" malpedia_version = "20180407" malpedia_license = "CC BY-NC-SA 4.0" malpedia_sharing = "TLP:WHITE" strings: $s0 = "%s\\en-US\\cmd.exe.mui" fullword wide $s1 = "[Green] pid=%d tid=%d modulePath=%s|" fullword wide $s2 = "1|103.243.175.181|80|5|xxxxxxxxxxxxxxxxxxxxxxx" wide ascii $s3 = "modulePath=%[^|]" fullword wide $s4 = "%s:%d:%s:%d:%d" fullword ascii $s5 = "regsvr32 %s %s %s go \"%s\"" fullword wide $s6 = "modulePath=" fullword wide $s7 = "%d %d.%d.%d %s" fullword wide $s8 = "winMain static green" fullword wide $s9 = "o%d Core %.2f GHz" fullword wide $s10 = "6&62676=6B6G6N6c6s6" fullword ascii $op0 = { 8b 54 24 54 8b cf 2b cb 8d 04 0a 3b c7 76 02 8b } $op1 = { a1 08 77 40 00 89 45 94 8d 45 94 50 ff 35 04 77 } $op2 = { 8b 7c 24 14 8b f7 2b f5 8d 64 24 00 8a 1f 84 db } condition: uint16(0) == 0x5a4d and filesize < 108KB and 8 of ($s*) and 1 of ($op*) }
If your designated proposal does not fit in any other category, feel free to write a free-text in the comment field below. Changes regarding references should be proposed on the Malpedia library page.
Your suggestion will be reviewed before being published. Thank you for contributing!
YYYY-MM-DD
YYYY-MM
YYYY