Function at 0x402c40
Capabilities:
Query or enumerate registry value
Read .ini file

Disassembly:
sub esp, 0x740
mov eax, dword [0x42119c]
push esi
xor esi, esi
mov dword [esp + 0x740], eax
push edi
mov dword [esp + 8], esi
lea ebx, [ebx]
push 0x104
call fcn.00411284
add esp, 4
mov dword [esp + esi*4 + 0x18], eax
inc esi
cmp esi, 9
mov byte [eax], 0
jle 0x402c60
mov esi, dword [esp + 0x750]
mov eax, dword [esi + 8]
push ebx
mov ebx, dword [esi + 4]
cmp ebx, eax
je 0x402ee2
push ebp
lea ebp, [ebx + 0x106]
jmp 0x402ca0
mov al, byte [ebx]
cmp al, 1
jne 0x402d78
lea eax, [esp + 0x20]
push eax
lea ecx, [ebp - 0x104]
push ecx
lea edx, [esp + 0x154]
push edx
call fcn.00401bf0
lea eax, [esp + 0x2c]
push eax
lea ecx, [esp + 0x35c]
push ebp
push ecx
call fcn.00401bf0
movzx ecx, byte [ebp - 0x105]
add esp, 0x18
lea edx, [esp + 0x14]
push edx
mov edx, dword [ecx*4 + 0x421098]
push 0x20019
push 0
lea eax, [esp + 0x158]
push eax
push edx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x402ed9
mov dword [esp + 0x1c], 1
mov dword [esp + 0x18], 0x104
movzx eax, byte [ebp + 0x208]
mov ecx, dword [esp + eax*4 + 0x20]
mov byte [ecx], 0
movzx eax, byte [ebp + 0x208]
mov ecx, dword [esp + eax*4 + 0x20]
lea edx, [esp + 0x18]
push edx
push ecx
mov ecx, dword [esp + 0x1c]
lea edx, [esp + 0x24]
push edx
push 0
lea eax, [esp + 0x35c]
push eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x402ece
mov edx, dword [esp + 0x14]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
movzx eax, byte [ebp + 0x208]
mov ecx, dword [esp + eax*4 + 0x20]
mov al, byte [ecx]
jmp 0x402eb1
cmp al, 2
jne 0x402eb5
lea edx, [esp + 0x20]
push edx
lea eax, [ebp - 0x104]
push eax
lea ecx, [esp + 0x154]
push ecx
call fcn.00401bf0
lea edx, [esp + 0x2c]
push edx
lea eax, [esp + 0x35c]
push ebp
push eax
call fcn.00401bf0
lea ecx, [esp + 0x38]
push ecx
lea edx, [ebp + 0x104]
push edx
lea eax, [esp + 0x56c]
push eax
call fcn.00401bf0
mov al, byte [ebp - 0x105]
add esp, 0x24
cmp al, 5
ja 0x402e61
movzx eax, al
imul eax, eax, 0x104
add eax, 0x422ab8
lea edx, [esp + 0x48]
mov cl, byte [eax]
inc eax
mov byte [edx], cl
inc edx
test cl, cl
jne 0x402de8
lea eax, [esp + 0x48]
lea edx, [eax + 1]
lea esp, [esp]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x402e00
sub eax, edx
cmp byte [esp + eax + 0x47], 0x5c
je 0x402e27
lea edi, [esp + 0x48]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x402e15
mov cx, word [0x41a25c]
mov word [edi], cx
lea eax, [esp + 0x14c]
mov edx, eax
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x402e30
lea edi, [esp + 0x48]
sub eax, edx
dec edi
mov edi, edi
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x402e40
mov ecx, eax
shr ecx, 2
mov esi, edx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x758]
jmp 0x402e73
xor eax, eax
mov cl, byte [esp + eax + 0x14c]
mov byte [esp + eax + 0x48], cl
inc eax
test cl, cl
jne 0x402e63
movzx eax, byte [ebp + 0x208]
mov ecx, dword [esp + eax*4 + 0x20]
lea edx, [esp + 0x48]
push edx
push 0x104
push ecx
push 0x41a259
lea edx, [esp + 0x55c]
push edx
lea eax, [esp + 0x360]
push eax
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
movzx ecx, byte [ebp + 0x208]
mov edx, dword [esp + ecx*4 + 0x20]
mov al, byte [edx]
test al, al
je 0x402ed9
mov eax, dword [esi + 8]
add ebx, 0x30f
add ebp, 0x30f
cmp ebx, eax
jne 0x402ca0
jmp 0x402ee1
mov eax, dword [esp + 0x14]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [esp + 0x10], 0x10008
pop ebp
mov eax, dword [esp + 0x1c]
mov edx, dword [esp + 0x750]
sub edx, eax
pop ebx
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x402ef0
xor edi, edi
xor esi, esi
mov edi, edi
mov eax, dword [esp + esi*4 + 0x18]
cmp eax, edi
je 0x402f15
push eax
call fcn.00411da3
add esp, 4
mov dword [esp + esi*4 + 0x18], edi
inc esi
cmp esi, 9
jle 0x402f00
mov ecx, dword [esp + 0x744]
mov eax, dword [esp + 8]
pop edi
pop esi
call fcn.004120e8
add esp, 0x740
ret