Function at 0x40f130
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
lea ebp, [esp - 0xcc]
sub esp, 0x14c
mov eax, dword [0x46d750]
xor eax, ebp
mov dword [ebp + 0xc8], eax
push ebx
push esi
push edi
call dword [0x46eaf4]
mov esi, dword [ebp + 0xd4]
mov edi, eax
mov eax, dword [esi - 0xc]
test eax, eax
mov dword [ebp - 0x40], edi
jl 0x40f181
push 0x45fc80
push esi
call fcn.0043a679
add esp, 8
test eax, eax
je 0x40f181
sub eax, esi
sar eax, 1
cmp eax, 0xffffffff
jne 0x40f1ed
lea eax, [ebp - 0x50]
push str._ReadReg__Invalid_arguments__Missing_operator_____:
push eax
lea ecx, [ebp + 0xd4]
call fcn.00401eb0
mov ebx, dword [eax]
xor esi, esi
add esp, 8
cmp ebx, esi
jne 0x40f1a5
mov dword [ebp - 0x40], esi
jmp 0x40f1d3
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
add eax, 1
cmp eax, 0x3fffffff
jle 0x40f1bb
mov dword [ebp - 0x40], esi
jmp 0x40f1d3
lea esi, [eax + eax]
mov eax, esi
call fcn.00440090
mov eax, esp
push edi
push esi
push ebx
push eax
call fcn.00408150
mov dword [ebp - 0x40], eax
lea ecx, [ebp - 0x40]
push ecx
lea ecx, [ebp - 0x64]
call fcn.0043920e
push 0x467390
lea edx, [ebp - 0x64]
push edx
call fcn.0043b69a
cmp dword [esi - 0xc], 0
jge 0x40f1f8
or eax, 0xffffffff
jmp 0x40f213
push 0x45fc80
push esi
call fcn.0043a679
add esp, 8
test eax, eax
jne 0x40f20f
or eax, 0xffffffff
jmp 0x40f213
sub eax, esi
sar eax, 1
push eax
lea eax, [ebp - 0x44]
push eax
lea ecx, [ebp + 0xd4]
call fcn.00407750
cmp dword [esi - 0xc], 0
jge 0x40f22e
or eax, 0xffffffff
jmp 0x40f249
push 0x45fc80
push esi
call fcn.0043a679
add esp, 8
test eax, eax
jne 0x40f245
or eax, 0xffffffff
jmp 0x40f249
sub eax, esi
sar eax, 1
add eax, 2
lea ebx, [ebp + 0xd4]
call fcn.004075c0
mov eax, dword [ebp + 0xd4]
add eax, 0xfffffff0
push eax
mov dword [ebp - 0x50], eax
call fcn.004020e0
add esp, 4
add eax, 0x10
push 0xa
lea ecx, [ebp - 0x80]
mov dword [ebp - 0x54], eax
call fcn.00429689
mov ebx, dword [ebp - 0x44]
lea ecx, [ebp - 0x80]
push ecx
push ecx
add ebx, 0xfffffff0
mov dword [ebp - 0x58], esp
mov esi, esp
push ebx
mov dword [ebp - 0x44], ebx
call fcn.004020e0
add eax, 0x10
add esp, 4
mov dword [esi], eax
call fcn.0040b770
add esp, 8
cmp eax, 3
je 0x40f316
lea edx, [ebp - 0x50]
push str._ReadReg__Invalid_arguments__nArg_3_:
push edx
lea ecx, [ebp + 0xd4]
call fcn.00401eb0
mov ebx, dword [eax]
xor esi, esi
add esp, 8
cmp ebx, esi
jne 0x40f2ce
mov dword [ebp - 0x40], esi
jmp 0x40f2fc
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
add eax, 1
cmp eax, 0x3fffffff
jle 0x40f2e4
mov dword [ebp - 0x40], esi
jmp 0x40f2fc
lea esi, [eax + eax]
mov eax, esi
call fcn.00440090
mov eax, esp
push edi
push esi
push ebx
push eax
call fcn.00408150
mov dword [ebp - 0x40], eax
lea eax, [ebp - 0x40]
push eax
lea ecx, [ebp - 0x64]
call fcn.0043920e
push 0x467390
lea ecx, [ebp - 0x64]
push ecx
call fcn.0043b69a
push 0
lea ecx, [ebp - 0x80]
mov dword [ebp - 0x48], reloc.OLEAUT32.dll_SysReAllocString
call fcn.00429665
test eax, eax
jne 0x40f330
jmp fcn.004232a7
add eax, 8
push str.HKEY_CURRENT_USER
push eax
call fcn.004036d0
add esp, 8
test al, al
je 0x40f34e
mov dword [ebp - 0x48], SysReAllocString
jmp 0x40f37d
push 0
lea ecx, [ebp - 0x80]
call fcn.00429665
test eax, eax
jne 0x40f361
jmp fcn.004232a7
add eax, 8
push str.HKEY_CLASSES_ROOT
push eax
call fcn.004036d0
add esp, 8
test al, al
je 0x40f37d
mov dword [ebp - 0x48], SysReAllocString
push 1
lea ecx, [ebp - 0x80]
call fcn.00429665
test eax, eax
jne 0x40f390
jmp fcn.004232a7
mov eax, dword [eax + 8]
sub eax, 0x10
push eax
call fcn.004020e0
add esp, 4
mov esi, eax
push 2
lea ecx, [ebp - 0x80]
add esi, 0x10
call fcn.00429665
test eax, eax
jne 0x40f3b7
jmp fcn.004232a7
mov eax, dword [eax + 8]
sub eax, 0x10
push eax
call fcn.004020e0
mov edi, eax
add esp, 4
add edi, 0x10
test esi, esi
jne 0x40f3d3
xor eax, eax
jmp 0x40f403
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
add eax, 1
cmp eax, 0x3fffffff
jle 0x40f3e8
xor eax, eax
jmp 0x40f403
lea ebx, [eax + eax]
mov eax, ebx
call fcn.00440090
mov edx, dword [ebp - 0x40]
mov eax, esp
push edx
push ebx
push esi
push eax
call fcn.00408150
mov ebx, dword [ebp - 0x44]
mov edx, dword [ebp - 0x48]
lea ecx, [ebp - 0x4c]
push ecx
push 0xf003f
push 0
push eax
push edx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x40f51d
test esi, esi
je 0x40f455
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
add eax, 1
cmp eax, 0x3fffffff
jle 0x40f43a
xor eax, eax
jmp 0x40f455
lea ebx, [eax + eax]
mov eax, ebx
call fcn.00440090
mov ecx, dword [ebp - 0x40]
mov eax, esp
push ecx
push ebx
push esi
push eax
call fcn.00408150
mov ebx, dword [ebp - 0x44]
lea edx, [ebp - 0x4c]
push edx
push eax
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyA]
test eax, eax
jne 0x40f513
test edi, edi
mov dword [ebp - 0x48], 0x104
mov dword [ebp - 0x58], 1
je 0x40f4ac
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
add eax, 1
cmp eax, 0x3fffffff
jle 0x40f494
xor eax, eax
jmp 0x40f4ac
lea ebx, [eax + eax]
mov eax, ebx
call fcn.00440090
mov ecx, dword [ebp - 0x40]
mov eax, esp
push ecx
push ebx
push edi
push eax
call fcn.00408150
lea edx, [ebp - 0x48]
push edx
lea ecx, [ebp - 0x3c]
push ecx
lea edx, [ebp - 0x58]
push edx
push 0
push eax
mov eax, dword [ebp - 0x4c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
lea ecx, [ebp - 0x3c]
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov ebx, eax
add ebx, 1
cmp ebx, 0x3fffffff
jle 0x40f4e0
xor eax, eax
jmp 0x40f4f9
lea eax, [ebx + ebx]
call fcn.00440090
mov edx, dword [ebp - 0x40]
mov eax, esp
push edx
push ebx
lea ecx, [ebp - 0x3c]
push ecx
push eax
call fcn.00414760
mov edx, dword [0x471c24]
push edx
push eax
mov eax, dword [ebp - 0x54]
push eax
push 0x45f800
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
mov ebx, dword [ebp - 0x44]
mov ecx, dword [ebp - 0x4c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
add edi, 0xfffffff0
lea edx, [edi + 0xc]
or eax, 0xffffffff
lock xadd dword [edx], eax
dec eax
test eax, eax
jg 0x40f539
mov ecx, dword [edi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push edi
call eax
add esi, 0xfffffff0
lea ecx, [esi + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f555
mov ecx, dword [esi]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push esi
call edx
lea ecx, [ebp - 0x80]
call fcn.004297c1
mov eax, dword [ebp - 0x54]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f57c
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea ecx, [ebx + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f595
mov ecx, dword [ebx]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push ebx
call edx
mov eax, dword [ebp - 0x50]
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f5b1
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea esp, [ebp - 0x8c]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0xc8]
xor ecx, ebp
call fcn.00438dc7
add ebp, 0xcc
mov esp, ebp
pop ebp
ret