Function at 0x40204a
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x240
mov eax, dword [0x428388]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov ecx, dword [ebp + 0x10]
push ebx
push esi
xor esi, esi
mov dword [ebp - 0x228], eax
push edi
push 0x208
lea eax, [ebp - 0x20c]
mov dword [ebp - 0x238], ecx
push esi
push eax
mov dword [ebp - 0x214], esi
mov edi, esi
mov dword [ebp - 0x224], esi
mov ebx, esi
mov dword [ebp - 0x210], esi
mov dword [ebp - 0x218], esi
mov dword [ebp - 0x21c], esi
mov dword [ebp - 0x220], esi
mov dword [ebp - 0x22c], esi
mov dword [ebp - 0x230], esi
call fcn.004078e2
mov eax, dword [ebp + 0xc]
add eax, eax
push eax
push esi
push dword [ebp - 0x228]
mov dword [ebp - 0x240], eax
call fcn.004078e2
add esp, 0x18
lea eax, [ebp - 0x214]
push eax
push 0x20019
push esi
push str.SoftwareMicrosoftPCHealthErrorReportingDWInstalled
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
je 0x402105
push 0x30303030
call fcn.00405d82
jmp 0x4022e0
push esi
push esi
lea eax, [ebp - 0x218]
push eax
lea eax, [ebp - 0x210]
push eax
lea eax, [ebp - 0x224]
push eax
push esi
push esi
push esi
push esi
push esi
push esi
push dword [ebp - 0x214]
call dword [sym.imp.ADVAPI32.dll_RegQueryInfoKeyW]
test eax, eax
jne 0x4020f6
push dword [ebp - 0x218]
inc dword [ebp - 0x210]
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov ebx, eax
test ebx, ebx
je 0x4022e0
mov eax, dword [ebp - 0x210]
add eax, eax
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov edi, eax
test edi, edi
je 0x4022e0
mov ecx, esi
mov dword [ebp - 0x234], esi
cmp dword [ebp - 0x224], ecx
jbe 0x4022a0
mov dword [ebp - 0x23c], 9
mov eax, dword [ebp - 0x210]
mov dword [ebp - 0x21c], eax
mov eax, dword [ebp - 0x218]
mov dword [ebp - 0x220], eax
lea eax, [ebp - 0x220]
push eax
push ebx
lea eax, [ebp - 0x22c]
push eax
push esi
lea eax, [ebp - 0x21c]
push eax
push edi
push ecx
push dword [ebp - 0x214]
call dword [sym.imp.ADVAPI32.dll_RegEnumValueW]
test eax, eax
jne 0x402287
cmp dword [ebp - 0x22c], 1
jne 0x402287
cmp dword [ebp - 0x21c], 6
jne 0x402287
cmp word [edi], 0x44
jne 0x402287
cmp word [edi + 2], 0x57
jne 0x402287
movzx ecx, word [edi + 4]
push 9
pop edx
lea eax, [ecx - 0x30]
cmp ax, dx
ja 0x402287
movzx eax, word [edi + 6]
add eax, 0xffffffd0
cmp ax, dx
ja 0x402287
movzx eax, word [edi + 8]
add eax, 0xffffffd0
cmp ax, dx
ja 0x402287
movzx edx, word [edi + 0xa]
lea eax, [edx - 0x30]
cmp ax, word [ebp - 0x23c]
ja 0x402287
movzx eax, word [edi + 6]
sub ecx, 0x30
imul ecx, ecx, 0xa
add ecx, 0xffffffd0
add eax, ecx
imul ecx, eax, 0xa
movzx eax, word [edi + 8]
add ecx, 0xffffffd0
add eax, ecx
imul ecx, eax, 0xa
mov eax, edx
add eax, 0xffffffd0
add eax, ecx
cmp eax, dword [ebp - 0x230]
jbe 0x402287
mov dword [ebp - 0x230], eax
mov eax, dword [ebp - 0x240]
cmp dword [ebp - 0x220], eax
jae 0x4022e0
push ebx
push dword [ebp + 0xc]
push dword [ebp - 0x228]
call fcn.0040e502
add esp, 0xc
mov ecx, dword [ebp - 0x234]
inc ecx
mov dword [ebp - 0x234], ecx
cmp ecx, dword [ebp - 0x224]
jb 0x402189
mov eax, dword [ebp - 0x238]
test eax, eax
je 0x4022dd
mov dword [eax], esi
lea eax, [ebp - 0x20c]
push 0x104
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
je 0x4022dd
lea eax, [ebp - 0x20c]
push eax
push dword [ebp - 0x228]
call fcn.00401f66
mov ecx, dword [ebp - 0x238]
mov dword [ecx], eax
xor esi, esi
inc esi
cmp dword [ebp - 0x214], 0
je 0x4022f5
push dword [ebp - 0x214]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test ebx, ebx
je 0x402300
push ebx
call dword [sym.imp.KERNEL32.dll_GlobalFree]
test edi, edi
je 0x40230b
push edi
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004067cd
mov esp, ebp
pop ebp
ret 0xc