Actor(s): APT41
According to FireEye, GEARSHIFT is a memory-only dropper for two keylogger DLLs. It is designed to replace a legitimate Fax Service DLL.
rule win_gearshift_auto { meta: author = "Felix Bilstein - yara-signator at cocacoding dot com" date = "2026-05-04" version = "1" description = "Detects win.gearshift." 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.gearshift" 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 = { ff15???????? 85c0 0f84a3000000 8b8db0010000 e8???????? } // n = 5, score = 200 // ff15???????? | // 85c0 | dec ecx // 0f84a3000000 | mov edx, esp // 8b8db0010000 | dec eax // e8???????? | $sequence_1 = { 85c0 7589 8d7801 488bcb } // n = 4, score = 200 // 85c0 | lea ecx, [0xffffbd15] // 7589 | dec ebp // 8d7801 | add eax, dword ptr [ecx + ecx*8 + 0x3ce60] // 488bcb | jmp 0x125d $sequence_2 = { 488bd8 4885c0 7424 ff9608010000 3db7000000 7517 488bcb } // n = 7, score = 200 // 488bd8 | dec ebp // 4885c0 | mov dword ptr [ebx], edx // 7424 | dec eax // ff9608010000 | mov ebx, dword ptr [esp + 8] // 3db7000000 | dec eax // 7517 | mov edi, dword ptr [esp + 0x10] // 488bcb | ret $sequence_3 = { 4c8d258e140300 488b0d???????? eb7c 4c8d2576140300 488b0d???????? eb6c e8???????? } // n = 7, score = 200 // 4c8d258e140300 | lea ecx, [0xffffbd15] // 488b0d???????? | // eb7c | inc ecx // 4c8d2576140300 | test byte ptr [eax + 0x38], 0x7f // 488b0d???????? | // eb6c | jne 0x5d // e8???????? | $sequence_4 = { 4c8be8 4885db 7510 488d0d5db00000 ff15???????? 488bd8 } // n = 6, score = 200 // 4c8be8 | sar eax, 5 // 4885db | dec eax // 7510 | lea edx, [0xbd60] // 488d0d5db00000 | dec eax // ff15???????? | // 488bd8 | mov ecx, ebx $sequence_5 = { 4883c440 5f e9???????? 488b5c2450 488b742458 4883c440 } // n = 6, score = 200 // 4883c440 | pop esp // 5f | ret // e9???????? | // 488b5c2450 | dec eax // 488b742458 | mov dword ptr [esp + 0x40], ebx // 4883c440 | mov ebx, dword ptr [eax + ecx + 0x88] $sequence_6 = { 488bd8 ff15???????? 488d15d4a90000 488bcb 488905???????? ff15???????? } // n = 6, score = 200 // 488bd8 | dec eax // ff15???????? | // 488d15d4a90000 | mov ebx, dword ptr [esp + 8] // 488bcb | dec eax // 488905???????? | // ff15???????? | $sequence_7 = { 488bd8 ff15???????? 488d15e2bc0000 488bcb 488905???????? } // n = 5, score = 200 // 488bd8 | dec eax // ff15???????? | // 488d15e2bc0000 | and dword ptr [esp + 0x20], 0 // 488bcb | dec eax // 488905???????? | $sequence_8 = { 57 4154 4156 4157 488dac2488feffff 4881ec78020000 33c0 } // n = 7, score = 200 // 57 | jne 0x479 // 4154 | dec eax // 4156 | mov ecx, dword ptr [esi + 0xb8] // 4157 | dec ecx // 488dac2488feffff | cmp ecx, esp // 4881ec78020000 | je 0x479 // 33c0 | dec esp $sequence_9 = { 488d05481f0300 4c3bd0 7405 e8???????? } // n = 4, score = 200 // 488d05481f0300 | dec eax // 4c3bd0 | add ebx, ecx // 7405 | dec eax // e8???????? | condition: 7 of them and filesize < 540672 }
rule win_gearshift_w0 { meta: author = "Bundesamt fuer Verfassungsschutz" source = "https://www.verfassungsschutz.de/download/anlage-2019-12-bfv-cyber-brief-2019-01.txt" malpedia_reference = "https://malpedia.caad.fkie.fraunhofer.de/details/win.gearshift" malpedia_version = "20191207" malpedia_sharing = "TLP:WHITE" malpedia_license = "" strings: $b1 = { 4C 8D 41 24 33 D2 B9 03 00 1F 00 FF 9? F8 00 00 00 48 85 C0 74 } $b2 = { 4C 8B 4? 08 BA 01 00 00 00 49 8B C? FF D0 85 C0 [2-6] C7 4? 1C 01 00 00 00 B8 01 00 00 00 } $b3 = { 8B 4B E4 8B 53 EC 41 B8 00 40 00 00 4? 0B C? FF 9? B8 00 00 00 EB } condition: (2 of ($b*)) }
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