Megumin Trojan, is a malware focused on multiple fields (DDoS, Miner, Loader, Clipper).
rule win_megumin_auto { meta: author = "Felix Bilstein - yara-signator at cocacoding dot com" date = "2026-05-04" version = "1" description = "Detects win.megumin." 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.megumin" malpedia_rule_date = "20260422" malpedia_hash = "a182e35da64e6d71cb55f125c4d4225196523f14" malpedia_version = "20260504" 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 = { 83ec18 c645fc2b 8bf4 8965c8 b9???????? 6a0e e8???????? } // n = 7, score = 200 // 83ec18 | sub esp, 0x18 // c645fc2b | mov byte ptr [ebp - 4], 0x2b // 8bf4 | mov esi, esp // 8965c8 | mov dword ptr [ebp - 0x38], esp // b9???????? | // 6a0e | push 0xe // e8???????? | $sequence_1 = { 53 56 57 33f6 c78524f8ffff00000000 56 56 } // n = 7, score = 200 // 53 | push ebx // 56 | push esi // 57 | push edi // 33f6 | xor esi, esi // c78524f8ffff00000000 | mov dword ptr [ebp - 0x7dc], 0 // 56 | push esi // 56 | push esi $sequence_2 = { 8d4dd8 e9???????? 8d4db8 e9???????? 8b542408 8d420c 8b8a2cfeffff } // n = 7, score = 200 // 8d4dd8 | lea ecx, [ebp - 0x28] // e9???????? | // 8d4db8 | lea ecx, [ebp - 0x48] // e9???????? | // 8b542408 | mov edx, dword ptr [esp + 8] // 8d420c | lea eax, [edx + 0xc] // 8b8a2cfeffff | mov ecx, dword ptr [edx - 0x1d4] $sequence_3 = { 8d4dd8 c645fc01 e8???????? 83ec10 8d8dc0fdffff 68???????? e8???????? } // n = 7, score = 200 // 8d4dd8 | lea ecx, [ebp - 0x28] // c645fc01 | mov byte ptr [ebp - 4], 1 // e8???????? | // 83ec10 | sub esp, 0x10 // 8d8dc0fdffff | lea ecx, [ebp - 0x240] // 68???????? | // e8???????? | $sequence_4 = { 8d8d70ffffff c745840f000000 c68570ffffff00 6a07 68???????? e8???????? 8d9570ffffff } // n = 7, score = 200 // 8d8d70ffffff | lea ecx, [ebp - 0x90] // c745840f000000 | mov dword ptr [ebp - 0x7c], 0xf // c68570ffffff00 | mov byte ptr [ebp - 0x90], 0 // 6a07 | push 7 // 68???????? | // e8???????? | // 8d9570ffffff | lea edx, [ebp - 0x90] $sequence_5 = { 53 56 8bf1 57 8b4608 2500010000 7414 } // n = 7, score = 200 // 53 | push ebx // 56 | push esi // 8bf1 | mov esi, ecx // 57 | push edi // 8b4608 | mov eax, dword ptr [esi + 8] // 2500010000 | and eax, 0x100 // 7414 | je 0x16 $sequence_6 = { 8d8dd4fbffff 6a08 68???????? c785e4fbffff00000000 c785e8fbffff0f000000 c685d4fbffff00 e8???????? } // n = 7, score = 200 // 8d8dd4fbffff | lea ecx, [ebp - 0x42c] // 6a08 | push 8 // 68???????? | // c785e4fbffff00000000 | mov dword ptr [ebp - 0x41c], 0 // c785e8fbffff0f000000 | mov dword ptr [ebp - 0x418], 0xf // c685d4fbffff00 | mov byte ptr [ebp - 0x42c], 0 // e8???????? | $sequence_7 = { 0f82cc0a0000 2bc6 83c9ff 83f8ff 0f42c8 837de810 8d45d4 } // n = 7, score = 200 // 0f82cc0a0000 | jb 0xad2 // 2bc6 | sub eax, esi // 83c9ff | or ecx, 0xffffffff // 83f8ff | cmp eax, -1 // 0f42c8 | cmovb ecx, eax // 837de810 | cmp dword ptr [ebp - 0x18], 0x10 // 8d45d4 | lea eax, [ebp - 0x2c] $sequence_8 = { 8b1f 53 56 e8???????? ff7514 ff75f0 ff75f8 } // n = 7, score = 200 // 8b1f | mov ebx, dword ptr [edi] // 53 | push ebx // 56 | push esi // e8???????? | // ff7514 | push dword ptr [ebp + 0x14] // ff75f0 | push dword ptr [ebp - 0x10] // ff75f8 | push dword ptr [ebp - 8] $sequence_9 = { 51 ff7668 e8???????? ff7658 8bce 66c746640000 c6467401 } // n = 7, score = 200 // 51 | push ecx // ff7668 | push dword ptr [esi + 0x68] // e8???????? | // ff7658 | push dword ptr [esi + 0x58] // 8bce | mov ecx, esi // 66c746640000 | mov word ptr [esi + 0x64], 0 // c6467401 | mov byte ptr [esi + 0x74], 1 condition: 7 of them and filesize < 1007616 }
rule win_megumin_w0 { meta: description = "Detecting Megumin v2" author = "Fumik0_" date = "2019-05-02" malpedia_reference = "https://malpedia.caad.fkie.fraunhofer.de/details/win.megumin" malpedia_version = "20190503" malpedia_license = "CC BY-NC-SA 4.0" malpedia_sharing = "TLP:WHITE" strings: $s1 = "Megumin/2.0" wide ascii $s2 = "/cpu" wide ascii $s3 = "/task?hwid=" wide ascii $s4 = "/gate?hwid=" wide ascii $s5 = "/suicide" wide ascii condition: all of them }
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