Function at 0x401ecb
Capabilities:
Check mutex on windows
Persist via windows service
Query or enumerate registry key
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2b0
push ebx
push esi
mov esi, str.sporder.dll
push edi
xor ebx, ebx
push esi
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_CreateMutexW]
push esi
push ebx
push 0x100000
call dword [sym.imp.KERNEL32.dll_OpenMutexW]
push ebx
push eax
mov dword [ebp - 0xc], eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x401f0e
add eax, 0xffffffa8
jmp 0x4021da
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
lea eax, [ebp - 8]
push eax
push 1
push ebx
push str.SYSTEMCurrentControlSetServicesWinSock2Parameters
push 0x80000002
call esi
cmp eax, ebx
je 0x401f32
mov ebx, eax
jmp 0x40217d
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x1c], 0x80
push eax
lea eax, [ebp - 0xa8]
push eax
push ebx
push ebx
push str.Current_Protocol_Catalog
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [ebp - 8]
mov edi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [ebp - 4], eax
call edi
cmp dword [ebp - 4], ebx
je 0x401f6f
mov ebx, dword [ebp - 4]
jmp 0x40217d
lea eax, [ebp - 0xa8]
push str.Protocol_Catalog9
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiW]
test eax, eax
je 0x401f8d
push 2
pop ebx
jmp 0x40217d
lea eax, [ebp - 8]
push eax
push 0xb
push ebx
push str.SYSTEMCurrentControlSetServicesWinSock2ParametersProtocol_Catalog9Catalog_Entries
push 0x80000002
call esi
cmp eax, ebx
jne 0x401f2b
push ebx
push ebx
push ebx
push ebx
push ebx
lea eax, [ebp - 0x28]
push ebx
push eax
lea eax, [ebp - 0x24]
push eax
push ebx
push ebx
push ebx
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryInfoKeyW]
mov esi, eax
cmp esi, ebx
jne 0x4021b8
mov eax, dword [ebp + 0xc]
cmp eax, dword [ebp - 0x24]
jne 0x4021b8
imul eax, eax, 0x584
push eax
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
pop ecx
mov dword [ebp - 0x10], eax
xor esi, esi
mov dword [ebp - 4], eax
lea eax, [ebp - 0x2b0]
push 0x104
push eax
push esi
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyW]
cmp eax, ebx
mov dword [ebp - 0x14], eax
jne 0x402017
lea eax, [ebp - 0x2b0]
push eax
push dword [ebp - 4]
call sub.MSVCRT.dll_wcscpy
pop ecx
pop ecx
add dword [ebp - 4], 0x584
inc esi
cmp dword [ebp - 0x14], ebx
je 0x401fe9
dec esi
cmp dword [ebp + 0xc], esi
je 0x402034
mov esi, 0x271e
jmp 0x4020e8
cmp dword [ebp + 0xc], ebx
mov dword [ebp - 4], ebx
jbe 0x4020ae
mov eax, dword [ebp - 0x10]
lea esi, [eax + 0x331]
lea eax, [ebp - 0x18]
push eax
push 3
lea eax, [esi - 0x331]
push ebx
push eax
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
cmp eax, ebx
jne 0x4020e6
lea eax, [ebp - 0x1c]
mov dword [ebp - 0x1c], 0x378
push eax
lea eax, [esi - 0x129]
push eax
push ebx
push ebx
push str.PackedCatalogItem
push dword [ebp - 0x18]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
movzx ecx, byte [esi]
movzx eax, byte [esi - 1]
shl ecx, 8
add eax, ecx
mov dword [esi + 0x24f], eax
push dword [ebp - 0x18]
call edi
inc dword [ebp - 4]
add esi, 0x584
mov eax, dword [ebp - 4]
cmp eax, dword [ebp + 0xc]
jb 0x402045
cmp dword [ebp + 0xc], ebx
mov dword [ebp - 0x14], ebx
jbe 0x40216f
mov eax, dword [ebp - 0x10]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp + 8]
mov dword [ebp + 8], eax
mov eax, dword [ebp + 8]
xor esi, esi
mov ecx, dword [eax]
mov eax, dword [ebp - 0x10]
add eax, 0x580
cmp ecx, dword [eax]
je 0x40210f
inc esi
add eax, 0x584
cmp esi, dword [ebp + 0xc]
jb 0x4020d5
jmp 0x402155
mov esi, eax
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 8]
call edi
push dword [ebp - 0x10]
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
pop ecx
mov eax, esi
jmp 0x4021da
lea eax, [ebp - 0x18]
push eax
push 3
push ebx
push dword [ebp - 0x20]
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
cmp eax, ebx
mov dword [ebp - 4], eax
jne 0x402193
imul esi, esi, 0x584
mov eax, dword [ebp - 0x10]
push 0x378
lea eax, [esi + eax + 0x208]
push eax
push 3
push ebx
push str.PackedCatalogItem
push dword [ebp - 0x18]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push dword [ebp - 0x18]
call edi
inc dword [ebp - 0x14]
add dword [ebp + 8], 4
mov eax, dword [ebp - 0x14]
add dword [ebp - 0x20], 0x584
cmp eax, dword [ebp + 0xc]
jb 0x4020c6
push dword [ebp - 8]
call edi
push dword [ebp - 0x10]
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
pop ecx
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebx
jmp 0x4021da
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 8]
call edi
push dword [ebp - 0x10]
call sub.MSVCRT.dll_void___cdecl_operator_delete_void__
mov eax, dword [ebp - 4]
pop ecx
jmp 0x4021da
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 8]
call edi
cmp esi, ebx
mov eax, esi
jne 0x4021da
mov eax, 0x2726
pop edi
pop esi
pop ebx
leave
ret 8