Function at 0x403169
Capabilities:
Query or enumerate registry value

Disassembly:
and dword [ebp - 0x220], 0
lea ecx, [ebp - 0x220]
push ecx
push 0x20019
push 0
push dword [ebp - 0x228]
push eax
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x403238
mov eax, dword [ebp - 0x210]
xor ecx, ecx
cmp eax, ecx
mov dword [ebp - 0x224], ecx
je 0x403135
mov eax, dword [eax]
mov dword [ebp - 0x21c], eax
lea eax, [ebp - 0x21c]
push eax
push dword [ebp - 0x214]
lea eax, [ebp - 0x224]
push eax
push ecx
push dword [ebp - 0x230]
push dword [ebp - 0x220]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [ebp - 0x220]
mov edi, eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test edi, edi
jne 0x403140
mov eax, dword [esi + 0x40f520]
cmp eax, dword [ebp - 0x224]
jne 0x403238
mov eax, dword [ebp - 0x21c]
test eax, eax
jbe 0x403238
mov ecx, dword [ebp - 0x22c]
test ecx, ecx
je 0x40310d
mov edx, dword [esi + 0x40f520]
mov dword [ecx], edx
mov ecx, dword [ebp - 0x218]
test ecx, ecx
je 0x403119
mov dword [ecx], ebx
mov ecx, dword [ebp - 0x210]
test ecx, ecx
je 0x403125
mov dword [ecx], eax
mov eax, edi
neg eax
sbb eax, eax
and eax, 0x80040702
jmp 0x4032bc
mov dword [ebp - 0x21c], ecx
jmp 0x4030a2
cmp edi, 0xea
je 0x4030db
jmp 0x403238
push dword [esi + 0x40f524]
jmp 0x4032a0
mov dword [edi], eax
mov eax, 0x80040702
jmp 0x4032bc
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x230
mov eax, dword [0x40f040]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x22c], eax
mov eax, dword [ebp + 0x18]
mov dword [ebp - 0x218], eax
mov eax, dword [ebp + 0x1c]
push esi
mov esi, dword [ebp + 0x10]
push edi
mov edi, dword [ebp + 0x14]
mov dword [ebp - 0x228], eax
mov eax, dword [ebp + 0x20]
mov dword [ebp - 0x214], esi
mov dword [ebp - 0x210], edi
mov dword [ebp - 0x230], eax
call fcn.00403347
test esi, esi
je 0x4031c7
test edi, edi
je 0x4059f2
mov esi, dword [ebp + 8]
push ebx
xor ebx, ebx
imul esi, esi, 0x18
xor edi, edi
inc edi
cmp ebx, edi
jg 0x403212
push dword [ebp - 0x228]
lea eax, [ebp - 0x20c]
push 0x4032d0
push 0x104
push eax
call fcn.004028a3
add esp, 0x10
test eax, eax
jl 0x403212
xor eax, eax
test ebx, ebx
setne al
push 2
push eax
lea eax, [ebp - 0x20c]
push eax
call fcn.00402a87
mov edi, eax
mov eax, dword [ebx*4 + 0x40fc58]
mov ecx, eax
and ecx, dword [esi + 0x40f52c]
cmp ecx, eax
jne 0x403238
mov eax, dword [ebx*4 + 0x40f3bc]
test eax, eax
je 0x403238
test edi, edi
jne 0x40305a
push 4
inc ebx
pop ecx
cmp ebx, ecx
jl 0x4031d0
mov eax, dword [0x40fc68]
test dword [esi + 0x40f52c], eax
je 0x4059fc
mov eax, dword [ebp - 0x22c]
test eax, eax
je 0x403263
mov edx, dword [esi + 0x40f520]
mov dword [eax], edx
mov eax, dword [ebp - 0x218]
test eax, eax
je 0x40326f
mov dword [eax], ecx
cmp dword [ebp - 0x214], 0
mov edi, dword [ebp - 0x210]
je 0x4032ae
mov eax, dword [esi + 0x40f528]
cmp dword [edi], eax
jb 0x403158
cmp dword [esi + 0x40f520], ecx
push eax
jne 0x40314d
lea eax, [esi + 0x40f524]
push eax
push dword [ebp - 0x214]
call sub.msvcrt.dll_memcpy
add esp, 0xc
test edi, edi
je 0x4032ba
mov eax, dword [esi + 0x40f528]
mov dword [edi], eax
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.004032ff
leave
ret 0x1c
mov eax, 0x80040702
jmp 0x4032bd
mov eax, dword [ebp - 0x218]
test eax, eax
je 0x405a0c
mov dword [eax], 5
mov eax, 0x80040700
jmp 0x4032bc