Function at 0x40b187
Capabilities:
Delete registry key
Query or enumerate registry value

Disassembly:
mov eax, 0x452f7e
call fcn.0044ca14
sub esp, 0x974
push ebx
push esi
push edi
xor ebx, ebx
push 0x4686e4
lea ecx, [ebp - 0x3c]
mov dword [ebp - 0x1c], ebx
call fcn.0040ad4c
push 0x458f9c
lea ecx, [ebp - 0x3c]
mov dword [ebp - 4], ebx
call fcn.00405fa8
push dword [ebp + 8]
lea ecx, [ebp - 0x64]
call fcn.0040162e
push ebx
lea eax, [ebp - 0x64]
lea ecx, [ebp - 0x80]
mov byte [ebp - 4], 1
call fcn.00425fc3
pop ecx
push 0xffffffffffffffff
push ebx
push eax
lea ecx, [ebp - 0x3c]
mov byte [ebp - 4], 2
call fcn.004065bf
xor edi, edi
push ebx
inc edi
push edi
lea ecx, [ebp - 0x80]
call fcn.004018a6
push ebx
push edi
lea ecx, [ebp - 0x64]
mov byte [ebp - 4], bl
call fcn.004017a5
xor eax, eax
push 0x7fe
mov word [ebp - 0x980], ax
lea eax, [ebp - 0x97e]
push ebx
push eax
call fcn.0043ae00
mov esi, 0xff
push esi
lea eax, [ebp - 0x17f]
push ebx
push eax
mov byte [ebp - 0x180], bl
call fcn.0043ae00
mov eax, dword [ebp - 0x38]
add esp, 0x18
cmp dword [ebp - 0x24], 8
jae 0x40b245
lea eax, [ebp - 0x38]
lea ecx, [ebp - 0x18]
push ecx
push 0xf003f
push ebx
push eax
push dword [0x468670]
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x40b27d
push dword [ebp + 8]
push 0x458fa0
push 8
push dword [0x468678]
call fcn.00429300
add esp, 0x10
jmp 0x40b434
push dword [ebp - 0x18]
mov ecx, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x48]
push eax
call fcn.0040db58
pop ecx
pop ecx
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x980]
push eax
lea eax, [ebp - 0x14]
push eax
push ebx
push str.LocalPath
push dword [ebp - 0x18]
mov dword [ebp - 0x10], 0x3ff
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x40b40f
cmp dword [ebp - 0x14], edi
jne 0x40b40f
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x180]
push eax
lea eax, [ebp - 0x14]
push eax
push ebx
push str.ModifyTime
push dword [ebp - 0x18]
mov dword [ebp - 0x10], esi
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
call esi
test eax, eax
jne 0x40b42a
cmp dword [ebp - 0x14], edi
jne 0x40b42a
push 4
pop edi
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x20]
push eax
lea eax, [ebp - 0x14]
push eax
push ebx
push str.Length
push dword [ebp - 0x18]
mov dword [ebp - 0x10], edi
call esi
test eax, eax
jne 0x40b40f
cmp dword [ebp - 0x14], edi
jne 0x40b40f
lea eax, [ebp - 0x48]
push eax
call fcn.0040db6b
lea eax, [ebp - 0x980]
push eax
call fcn.004195dd
pop ecx
pop ecx
test al, al
je 0x40b37c
lea eax, [ebp - 0x180]
push eax
lea ecx, [ebp - 0x64]
call fcn.0040162e
lea eax, [ebp - 0x64]
push eax
mov byte [ebp - 4], 3
push dword [ebp - 0x20]
lea eax, [ebp - 0x980]
push eax
mov dword [ebp - 0x1c], 1
call fcn.0041953f
add esp, 0xc
mov byte [ebp + 0xb], 1
test al, al
je 0x40b37f
mov byte [ebp + 0xb], bl
mov dword [ebp - 4], ebx
test byte [ebp - 0x1c], 1
je 0x40b393
push ebx
push 1
lea ecx, [ebp - 0x64]
call fcn.004017a5
cmp byte [ebp + 0xb], bl
je 0x40b3f2
lea eax, [ebp - 0x980]
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
cmp cx, bx
jne 0x40b3a1
sub eax, edx
sar eax, 1
xor ecx, ecx
push 2
inc eax
pop edx
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0043a3d2
mov esi, eax
lea eax, [ebp - 0x980]
pop ecx
lea ecx, [eax + 2]
mov dx, word [eax]
inc eax
inc eax
cmp dx, bx
jne 0x40b3d0
sub eax, ecx
sar eax, 1
lea ecx, [ebp - 0x980]
push ecx
inc eax
push eax
push esi
call fcn.0043abf5
add esp, 0xc
jmp 0x40b41b
cmp dword [ebp - 0x24], 8
mov eax, dword [ebp - 0x38]
jae 0x40b3fe
lea eax, [ebp - 0x38]
push eax
push dword [0x468670]
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
xor esi, esi
jmp 0x40b41b
lea eax, [ebp - 0x48]
push eax
xor esi, esi
call fcn.0040db6b
pop ecx
push ebx
push 1
lea ecx, [ebp - 0x3c]
call fcn.004018a6
mov eax, esi
jmp 0x40b440
lea eax, [ebp - 0x48]
push eax
call fcn.0040db6b
pop ecx
push ebx
push edi
lea ecx, [ebp - 0x3c]
call fcn.004018a6
xor eax, eax
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret 4