Function at 0x402240
Capabilities:
Create process on windows
Get common file path
Get session user name
Query or enumerate registry value

Disassembly:
sub esp, 0xa4c
mov eax, dword [0x487264]
xor eax, esp
mov dword [esp + 0xa48], eax
push ebx
push ebp
mov ebp, dword [esp + 0xa58]
push esi
xor ebx, ebx
push 0x103
lea eax, [esp + 0x31]
mov esi, 0x104
push ebx
push eax
mov dword [esp + 0x2c], esi
mov dword [esp + 0x24], esi
mov byte [esp + 0x38], bl
call fcn.004441f0
push 0x103
lea ecx, [esp + 0x349]
push ebx
push ecx
mov byte [esp + 0x350], bl
call fcn.004441f0
push 0x103
lea edx, [esp + 0x459]
push ebx
push edx
mov byte [esp + 0x460], bl
call fcn.004441f0
lea edx, [esp + 0x154]
add esp, 0x24
mov dword [esp + 0x1c], esi
mov dword [esp + 0x24], 1
mov dword [esp + 0x14], esi
mov eax, ebp
sub edx, ebp
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
cmp cl, bl
jne 0x4022d3
lea eax, [esp + 0x130]
push eax
call fcn.00459b35
add esp, 4
cmp byte [esp + 0x130], 0x68
jne 0x402333
mov al, 0x74
cmp byte [esp + 0x131], al
jne 0x402333
cmp byte [esp + 0x132], al
jne 0x402333
cmp byte [esp + 0x133], 0x70
jne 0x402333
mov ecx, dword [str..html]
mov dx, word [0x45dea0]
mov dword [esp + 0x540], ecx
mov word [esp + 0x544], dx
jmp 0x40235c
lea eax, [esp + 0x130]
push 0x2e
push eax
call fcn.00444270
add esp, 8
cmp eax, ebx
je 0x402382
lea edx, [esp + 0x540]
sub edx, eax
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
cmp cl, bl
jne 0x402352
push esi
lea ecx, [esp + 0x33c]
push ecx
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
lea edx, [esp + 0x1c]
push edx
lea eax, [esp + 0x440]
push eax
call dword [sym.imp.ADVAPI32.dll_GetUserNameA]
test eax, eax
jne 0x402389
xor eax, eax
jmp 0x4026ce
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
lea ecx, [esp + 0x10]
push ecx
lea edx, [esp + 0x548]
push edx
push SysReAllocString
call edi
test eax, eax
jne 0x4026cb
lea eax, [esp + 0x18]
push eax
mov eax, dword [esp + 0x14]
lea ecx, [esp + 0x854]
push ecx
lea edx, [esp + 0x30]
push edx
push ebx
push ebx
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4026c0
lea ecx, [esp + 0x850]
push ecx
lea edx, [esp + 0x64c]
push 0x45de98
push edx
call fcn.00444326
mov eax, dword [esp + 0x1c]
mov esi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
add esp, 0xc
push eax
call esi
lea ecx, [esp + 0x10]
push ecx
push ebx
push SysReAllocString
mov dword [esp + 0x1c], ebx
call edi
test eax, eax
jne 0x4026cb
lea eax, [esp + 0x648]
dec eax
mov edi, edi
mov cl, byte [eax + 1]
inc eax
cmp cl, bl
jne 0x402420
mov edx, dword [str._shellopencommand]
mov ecx, dword [0x45de88]
mov dword [eax], edx
mov edx, dword [0x45de8c]
mov dword [eax + 4], ecx
mov ecx, dword [0x45de90]
mov dword [eax + 8], edx
mov edx, dword [0x45de94]
mov dword [eax + 0xc], ecx
mov dword [eax + 0x10], edx
mov edx, dword [esp + 0x10]
lea eax, [esp + 0x14]
push eax
push 0xf003f
push ebx
lea ecx, [esp + 0x654]
push ecx
push edx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x4026b7
mov eax, dword [esp + 0x10]
push eax
call esi
lea ecx, [esp + 0x1c]
push ecx
lea edx, [esp + 0x750]
push edx
lea eax, [esp + 0x34]
push eax
mov eax, dword [esp + 0x20]
push ebx
lea ecx, [esp + 0x34]
push ecx
lea edx, [esp + 0x968]
push edx
push ebx
push eax
mov dword [esp + 0x30], ebx
call dword [sym.imp.ADVAPI32.dll_RegEnumValueA]
mov ecx, dword [esp + 0x14]
push ecx
call esi
mov dword [esp + 0x14], ebx
xor eax, eax
mov edi, edi
mov cl, byte [esp + eax + 0x74c]
mov byte [esp + eax + 0x238], cl
inc eax
cmp cl, bl
jne 0x4024c0
lea edx, [esp + 0x238]
push edx
call fcn.00459b35
lea eax, [esp + 0x23c]
push str..exe
push eax
call fcn.004442a0
add esp, 0xc
test eax, eax
je 0x4026a7
lea ecx, [esp + 0x238]
push 0x45de78
push ecx
call fcn.004442a0
add esp, 8
test eax, eax
je 0x4026a7
mov esi, dword [str._allusersprofile_]
xor edi, edi
cmp esi, ebx
je 0x40258d
mov eax, esi
lea edx, [eax + 1]
jmp 0x402530
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x402530
sub eax, edx
lea ecx, [esp + 0x238]
cmp eax, 4
jb 0x402559
mov edx, dword [esi]
cmp edx, dword [ecx]
jne 0x402581
sub eax, 4
add ecx, 4
add esi, 4
cmp eax, 4
jae 0x402545
cmp eax, ebx
je 0x4025dd
mov dl, byte [ecx]
cmp dl, byte [esi]
jne 0x402581
cmp eax, 1
jbe 0x4025dd
mov dl, byte [ecx + 1]
cmp dl, byte [esi + 1]
jne 0x402581
cmp eax, 2
jbe 0x4025dd
mov al, byte [ecx + 2]
cmp al, byte [esi + 2]
je 0x4025dd
mov esi, dword [edi*8 + 0x473110]
inc edi
cmp esi, ebx
jne 0x402526
xor eax, eax
nop
mov cl, byte [esp + eax + 0x238]
mov byte [esp + eax + 0x30], cl
inc eax
cmp cl, bl
jne 0x402590
lea edx, [esp + 0x30]
push 0x25
push edx
call fcn.00444270
add esp, 8
cmp eax, ebx
je 0x40264d
mov byte [eax], bl
mov eax, ebp
mov ecx, ebp
lea ecx, [ecx]
mov dl, byte [eax]
inc eax
cmp dl, bl
jne 0x4025c0
lea edi, [esp + 0x30]
sub eax, ecx
mov esi, ecx
dec edi
mov cl, byte [edi + 1]
inc edi
cmp cl, bl
jne 0x4025d0
jmp 0x40267f
movsx edx, byte [esp + 0x33c]
mov eax, dword [edi*8 + 0x47310c]
lea ecx, [esp + 0x440]
push ecx
push edx
push eax
lea ecx, [esp + 0x3c]
push ecx
call fcn.00444326
mov eax, dword [edi*8 + 0x473108]
add esp, 0x10
lea edx, [eax + 1]
lea ecx, [ecx]
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x402610
sub eax, edx
lea eax, [esp + eax + 0x238]
mov ecx, eax
mov dl, byte [eax]
inc eax
cmp dl, bl
jne 0x402622
lea edi, [esp + 0x30]
sub eax, ecx
mov esi, ecx
dec edi
mov cl, byte [edi + 1]
inc edi
cmp cl, bl
jne 0x402632
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
jmp 0x4025a0
lea edi, [esp + 0x30]
dec edi
mov al, byte [edi + 1]
inc edi
cmp al, bl
jne 0x402652
mov ax, word [0x45de74]
mov word [edi], ax
mov eax, ebp
mov ecx, ebp
mov dl, byte [eax]
inc eax
cmp dl, bl
jne 0x402667
lea edi, [esp + 0x30]
sub eax, ecx
mov esi, ecx
dec edi
mov cl, byte [edi + 1]
inc edi
cmp cl, bl
jne 0x402677
mov ecx, eax
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 [esp + 0xa64]
push ecx
lea edx, [esp + 0x34]
push edx
call dword [sym.imp.KERNEL32.dll_WinExec]
mov eax, 1
jmp 0x4026cd
mov eax, dword [esp + 0x10]
push eax
call esi
push ebx
mov dword [esp + 0x14], ebx
call esi
jmp 0x4026cb
mov ecx, dword [esp + 0x10]
push ecx
call esi
jmp 0x4026cb
mov edx, dword [esp + 0x10]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
pop edi
mov ecx, dword [esp + 0xa54]
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.00443a17
add esp, 0xa4c
ret 8