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

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffc9c
mov dword [ebp - 0xc], ecx
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 8]
movsx edx, byte [eax]
cmp edx, 0x2e
jne 0x426830
lea ecx, [ebp - 0x10]
push ecx
push 0x20019
push 0
push dword [ebp - 8]
push SysReAllocStringLen
call sub.ADVAPI32.DLL_RegOpenKeyExA
test eax, eax
je 0x4267b0
xor eax, eax
jmp 0x426b5d
mov dword [ebp - 0x2c], 0xff
lea edx, [ebp - 0x2c]
push edx
lea ecx, [ebp - 0x24c]
push ecx
lea eax, [ebp - 0x28]
push eax
push 0
push 0x6eb91d
push dword [ebp - 0x10]
call sub.ADVAPI32.DLL_RegQueryValueExA
test eax, eax
jne 0x426814
mov edx, dword [ebp - 0xc]
test edx, edx
je 0x426826
push dword [ebp - 0xc]
call fcn.0066ca1c
pop ecx
mov dword [ebp - 0x24], eax
push dword [ebp - 0x24]
push dword [ebp - 0xc]
lea ecx, [ebp - 0x24c]
push ecx
call fcn.0066cc80
add esp, 0xc
test eax, eax
je 0x426826
push dword [ebp - 0x10]
call sub.ADVAPI32.DLL_RegCloseKey
xor eax, eax
jmp 0x426b5d
push dword [ebp - 8]
lea edx, [ebp - 0x24c]
push edx
call fcn.0066c9ec
add esp, 8
push dword [ebp - 0x10]
call sub.ADVAPI32.DLL_RegCloseKey
jmp 0x426842
push dword [ebp - 8]
lea ecx, [ebp - 0x24c]
push ecx
call fcn.0066c9ec
add esp, 8
lea eax, [ebp - 0x14]
push eax
push 0x20019
push 0
lea edx, [ebp - 0x24c]
push edx
push SysReAllocStringLen
call sub.ADVAPI32.DLL_RegOpenKeyExA
test eax, eax
je 0x426869
xor eax, eax
jmp 0x426b5d
mov dword [ebp - 0x2c], 0xff
lea edx, [ebp - 0x2c]
push edx
lea ecx, [ebp - 0x24c]
push ecx
lea eax, [ebp - 0x28]
push eax
push 0
push 0x6eb91e
push dword [ebp - 0x14]
call sub.ADVAPI32.DLL_RegQueryValueExA
xor edx, edx
mov dword [ebp - 0x258], edx
lea ecx, [ebp - 0x1c]
push ecx
push 0x20019
push 0
push str.shellopencommand
push dword [ebp - 0x14]
call sub.ADVAPI32.DLL_RegOpenKeyExA
test eax, eax
jne 0x426972
mov dword [ebp - 0x2c], 0xff
lea eax, [ebp - 0x2c]
push eax
lea edx, [ebp - 0x24c]
push edx
lea ecx, [ebp - 0x28]
push ecx
push 0
push 0x6eb932
push dword [ebp - 0x1c]
call sub.ADVAPI32.DLL_RegQueryValueExA
mov eax, dword [ebp - 0x28]
cmp eax, 2
jne 0x426933
mov edx, dword [ebp - 0x2c]
add edx, 0xa
push edx
call fcn.0066c210
pop ecx
mov dword [ebp - 0x34], eax
push dword [ebp - 0x2c]
push dword [ebp - 0x34]
lea ecx, [ebp - 0x24c]
push ecx
call sub.KERNEL32.DLL_ExpandEnvironmentStringsA
push dword [ebp - 0x34]
lea eax, [ebp - 0x14c]
push eax
call fcn.0066c9ec
add esp, 8
lea ecx, [ebp - 0x264]
mov edx, dword [ebp - 0x34]
mov eax, dword [ebp - 4]
call fcn.00403fec
push dword [ebp - 0x34]
call fcn.0066c220
pop ecx
jmp 0x426965
mov edx, dword [ebp - 0x28]
cmp edx, 1
jne 0x426965
lea ecx, [ebp - 0x24c]
push ecx
lea eax, [ebp - 0x14c]
push eax
call fcn.0066c9ec
add esp, 8
lea ecx, [ebp - 0x264]
lea edx, [ebp - 0x24c]
mov eax, dword [ebp - 4]
call fcn.00403fec
push dword [ebp - 0x1c]
call sub.ADVAPI32.DLL_RegCloseKey
jmp 0x426b1a
lea edx, [ebp - 0x18]
push edx
push 0x20019
push 0
push str.shell
push dword [ebp - 0x14]
call sub.ADVAPI32.DLL_RegOpenKeyExA
test eax, eax
jne 0x426b1a
push 0
push 0
push 0
push 0
push 0
push 0
lea ecx, [ebp - 0x3c]
push ecx
lea eax, [ebp - 0x38]
push eax
push 0
push 0
push 0
push dword [ebp - 0x18]
call sub.ADVAPI32.DLL_RegQueryInfoKeyA
test eax, eax
jne 0x426b12
mov edx, dword [ebp - 0x3c]
inc edx
push edx
call fcn.0066c210
pop ecx
mov dword [ebp - 0x40], eax
xor ecx, ecx
mov dword [ebp - 0x44], ecx
mov eax, dword [ebp - 0x44]
mov edx, dword [ebp - 0x38]
cmp eax, edx
jae 0x426b12
mov dword [ebp - 0x30], 0xff
push 0
push 0
push 0
push 0
lea ecx, [ebp - 0x30]
push ecx
push dword [ebp - 0x40]
push dword [ebp - 0x44]
push dword [ebp - 0x18]
call sub.ADVAPI32.DLL_RegEnumKeyExA
lea eax, [ebp - 0x1c]
push eax
push 0x20019
push 0
push dword [ebp - 0x40]
push dword [ebp - 0x18]
call sub.ADVAPI32.DLL_RegOpenKeyExA
test eax, eax
jne 0x426b01
lea edx, [ebp - 0x20]
push edx
push 0x20019
push 0
push str.command
push dword [ebp - 0x1c]
call sub.ADVAPI32.DLL_RegOpenKeyExA
test eax, eax
jne 0x426af9
mov dword [ebp - 0x2c], 0xff
lea ecx, [ebp - 0x2c]
push ecx
lea eax, [ebp - 0x24c]
push eax
lea edx, [ebp - 0x28]
push edx
push 0
push 0x6eb941
push dword [ebp - 0x20]
call sub.ADVAPI32.DLL_RegQueryValueExA
mov ecx, dword [ebp - 0x28]
cmp ecx, 2
jne 0x426ab9
mov eax, dword [ebp - 0x2c]
add eax, 0xa
push eax
call fcn.0066c210
pop ecx
mov dword [ebp - 0x34], eax
push dword [ebp - 0x2c]
push dword [ebp - 0x34]
lea edx, [ebp - 0x24c]
push edx
call sub.KERNEL32.DLL_ExpandEnvironmentStringsA
push dword [ebp - 0x34]
lea ecx, [ebp - 0x14c]
push ecx
call fcn.0066c9ec
add esp, 8
lea ecx, [ebp - 0x264]
mov edx, dword [ebp - 0x34]
mov eax, dword [ebp - 4]
call fcn.00403fec
push dword [ebp - 0x34]
call fcn.0066c220
pop ecx
jmp 0x426aeb
mov eax, dword [ebp - 0x28]
cmp eax, 1
jne 0x426aeb
lea edx, [ebp - 0x24c]
push edx
lea ecx, [ebp - 0x14c]
push ecx
call fcn.0066c9ec
add esp, 8
lea ecx, [ebp - 0x264]
lea edx, [ebp - 0x24c]
mov eax, dword [ebp - 4]
call fcn.00403fec
push dword [ebp - 0x20]
call sub.ADVAPI32.DLL_RegCloseKey
mov eax, dword [ebp - 0x38]
mov dword [ebp - 0x44], eax
push dword [ebp - 0x1c]
call sub.ADVAPI32.DLL_RegCloseKey
inc dword [ebp - 0x44]
mov edx, dword [ebp - 0x44]
mov ecx, dword [ebp - 0x38]
cmp edx, ecx
jb 0x4269dd
push dword [ebp - 0x18]
call sub.ADVAPI32.DLL_RegCloseKey
push dword [ebp - 0x14]
call sub.ADVAPI32.DLL_RegCloseKey
mov eax, dword [ebp - 0x258]
test eax, eax
je 0x426b5b
push dword [ebp - 0x258]
push dword [ebp + 0xc]
call fcn.0066c9ec
add esp, 8
mov edx, dword [ebp + 8]
mov ecx, dword [ebp - 0x250]
mov dword [edx], ecx
push dword [ebp - 0x258]
call fcn.0066c220
pop ecx
mov eax, 1
jmp 0x426b5d
xor eax, eax
mov esp, ebp
pop ebp
ret 8