Function at 0x4096d0
Capabilities:
Query environment variable
Query or enumerate registry value

Disassembly:
push 0xffffffffffffffff
push 0x46874d
mov eax, dword fs:[0]
push eax
sub esp, 0x51c
mov eax, dword [0x48b270]
xor eax, esp
mov dword [esp + 0x518], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x48b270]
xor eax, esp
push eax
lea eax, [esp + 0x530]
mov dword fs:[0], eax
mov edi, dword [esp + 0x544]
mov esi, dword [esp + 0x540]
xor ebx, ebx
mov dword [esp + 0x24], ebx
mov eax, dword [edi + 0xd0]
sub eax, 0x10
push eax
mov dword [esp + 0x53c], ebx
mov dword [esp + 0x2c], esi
call fcn.00401290
add eax, 0x10
mov dword [esi], eax
mov eax, dword [edi + 0xd0]
push pe_nt_image_headers32
lea ecx, [esp + 0x34]
push ecx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push eax
mov dword [esp + 0x560], ebx
mov dword [esp + 0x4c], 1
call fcn.00452e01
mov ebp, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
add esp, 0x28
lea edx, [esp + 0x20]
push edx
push 0x20019
push ebx
lea eax, [esp + 0x38]
push eax
push SysReAllocString
mov dword [esp + 0x28], 0x400
mov dword [esp + 0x34], ebx
call ebp
test eax, eax
jne 0x409931
mov eax, dword [esp + 0x20]
lea ecx, [esp + 0x14]
push ecx
lea edx, [esp + 0x130]
push edx
push ebx
push ebx
push ebx
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x409931
mov ecx, dword [esp + 0x20]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
call fcn.00432e51
xor ecx, ecx
cmp eax, ebx
setne cl
cmp ecx, ebx
jne 0x4097e5
push 0x80004005
call fcn.00401090
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x18], eax
lea ecx, [esp + 0x12c]
push ecx
lea edx, [esp + 0x1c]
push str._sShellOpenCommand
push edx
mov dword [esp + 0x544], 1
call fcn.00401f50
mov ecx, dword [esp + 0x24]
add esp, 0xc
lea eax, [esp + 0x1c]
push eax
push 0x20019
push ebx
push ecx
push SysReAllocString
mov dword [esp + 0x28], 0x400
mov dword [esp + 0x30], ebx
call ebp
test eax, eax
jne 0x40990a
mov ecx, dword [esp + 0x1c]
lea edx, [esp + 0x14]
push edx
lea eax, [esp + 0x130]
push eax
push ebx
push ebx
push ebx
push ecx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4098ff
push 0x400
mov ecx, esi
mov dword [esp + 0x18], 0x400
call fcn.004018e0
mov edx, dword [esp + 0x14]
push edx
push eax
lea eax, [esp + 0x134]
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
mov ebp, eax
mov eax, dword [esi]
mov ecx, dword [eax - 8]
cmp eax, ebx
jne 0x40989f
xor eax, eax
jmp 0x4098b1
push ecx
push eax
call fcn.00450e3f
add esp, 8
cmp eax, ebx
jl 0x40995d
mov ecx, dword [esi]
cmp eax, dword [ecx - 8]
jg 0x40995d
mov dword [ecx - 0xc], eax
mov ecx, dword [esi]
mov byte [eax + ecx], bl
cmp ebp, ebx
je 0x4098ff
mov eax, dword [edi + 0xd0]
push eax
push 0x46f7ec
mov ecx, esi
call fcn.00409390
mov edi, dword [edi + 0xd0]
push edi
push 0x46f7e8
mov ecx, esi
call fcn.00409390
push 0x46eb20
push 0x46f7e4
mov ecx, esi
call fcn.00409390
mov edx, dword [esp + 0x1c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
mov byte [esp + 0x538], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x409931
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, esi
mov ecx, dword [esp + 0x530]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x518]
xor ecx, esp
call fcn.004517f0
add esp, 0x528
ret 8
push 0x80070057
call fcn.00401090
int3