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

Disassembly:
push 0xffffffffffffffff
push 0x5373dc
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x548
push ebx
push ebp
push esi
push edi
mov ebp, ecx
mov eax, dword [0x5ab980]
xor edi, edi
mov dword [esp + 0x560], edi
mov dword [esp + 0x2c], edi
mov dword [esp + 0x24], edi
mov dword [esp + 0x18], eax
mov dword [esp + 0x34], eax
mov eax, dword [esp + 0x568]
mov esi, 0x200
mov dword [esp + 0x1c], esi
mov dword [esp + 0x3c], edi
mov ecx, dword [eax - 8]
mov byte [esp + 0x560], 2
cmp ecx, edi
jne 0x409bee
push str.SOFTWAREIntuit
lea ecx, [esp + 0x56c]
call fcn.00512a6d
mov eax, dword [ebp + 0xa8]
cmp dword [eax - 8], edi
je 0x409bee
mov ecx, dword [0x5ab980]
mov dword [esp + 0x10], ecx
mov esi, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
push eax
lea edx, [esp + 0x54]
push 0x105
push edx
push edi
mov bl, 3
push str.ProductINI
push str.initialization
mov byte [esp + 0x578], bl
call esi
test eax, eax
jbe 0x409b2d
lea eax, [esp + 0x50]
lea ecx, [esp + 0x14]
push eax
call fcn.00512952
lea ecx, [esp + 0x14]
mov byte [esp + 0x560], 4
push ecx
mov ecx, ebp
call fcn.00407e10
lea ecx, [esp + 0x14]
mov byte [esp + 0x560], bl
call fcn.005128e4
mov eax, dword [ebp + 0xa8]
lea edx, [esp + 0x50]
push eax
push 0x105
push edx
push edi
push str.BackupINI
push str.initialization
call esi
test eax, eax
jbe 0x409b81
lea eax, [esp + 0x50]
lea ecx, [esp + 0x14]
push eax
call fcn.00512952
lea ecx, [esp + 0x14]
mov byte [esp + 0x560], 5
push ecx
mov ecx, ebp
call fcn.00407e10
lea ecx, [esp + 0x14]
mov byte [esp + 0x560], bl
call fcn.005128e4
mov eax, dword [ebp + 0xa8]
lea edx, [esp + 0x50]
push eax
push 0x105
push edx
push edi
push str.TargetDir
push str.initialization
call esi
test eax, eax
jbe 0x409bd8
lea eax, [esp + 0x50]
lea ecx, [esp + 0x10]
push eax
call fcn.00512a6d
lea ecx, [esp + 0x10]
push ecx
call fcn.0041f9c0
lea edx, [esp + 0x14]
push edx
call fcn.0041fe70
add esp, 8
test eax, eax
jne 0x409bd8
lea eax, [esp + 0x10]
mov ecx, ebp
push eax
call fcn.004088b0
lea ecx, [esp + 0x10]
mov byte [esp + 0x560], 2
call fcn.005128e4
mov esi, 0x200
mov edx, dword [esp + 0x568]
lea ecx, [esp + 0x2c]
push ecx
push 0xf003f
push edi
push edx
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
cmp eax, edi
je 0x409c51
lea ecx, [esp + 0x34]
mov byte [esp + 0x560], 1
call fcn.005128e4
lea ecx, [esp + 0x18]
mov byte [esp + 0x560], 0
call fcn.005128e4
lea ecx, [esp + 0x568]
mov dword [esp + 0x560], 0xffffffff
call fcn.005128e4
or eax, 0xffffffff
jmp 0x40a018
mov eax, dword [esp + 0x1c]
mov edx, dword [esp + 0x2c]
lea ecx, [esp + 0x158]
push eax
push ecx
push edi
push edx
mov dword [esp + 0x40], 1
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyA]
cmp eax, edi
jne 0x409fcf
lea eax, [esp + 0x158]
lea ecx, [esp + 0x18]
push eax
mov dword [esp + 0x2c], esi
call fcn.00512a6d
mov ecx, dword [esp + 0x18]
push str.File
push ecx
call fcn.004f9670
add esp, 8
cmp eax, edi
je 0x409d48
mov edx, dword [esp + 0x18]
push str.Shell
push edx
call fcn.004f9670
add esp, 8
cmp eax, edi
je 0x409d48
mov eax, dword [esp + 0x18]
push str.Shared
push eax
call fcn.004f9670
add esp, 8
cmp eax, edi
je 0x409d48
mov ecx, dword [esp + 0x18]
push 0x5971ec
push ecx
call fcn.004f9670
add esp, 8
cmp eax, edi
jne 0x409cf6
mov ebx, 2
jmp 0x409d4d
lea edx, [esp + 0x568]
push 0x5971e8
lea eax, [esp + 0x50]
push edx
push eax
call fcn.00512b79
push ecx
lea edx, [esp + 0x15c]
mov ecx, esp
mov dword [esp + 0x3c], esp
push edx
push eax
push ecx
mov byte [esp + 0x570], 6
call fcn.00512b79
mov ecx, ebp
call fcn.00409a40
lea ecx, [esp + 0x4c]
mov byte [esp + 0x560], 2
call fcn.005128e4
jmp 0x409fa3
mov ebx, 1
lea eax, [esp + 0x568]
push 0x5971e8
lea ecx, [esp + 0x44]
push eax
push ecx
call fcn.00512b79
lea edx, [esp + 0x158]
mov byte [esp + 0x560], 7
push edx
push eax
lea eax, [esp + 0x4c]
push eax
call fcn.00512b79
push eax
lea ecx, [esp + 0x1c]
mov byte [esp + 0x564], 8
call fcn.00512a1d
lea ecx, [esp + 0x44]
mov byte [esp + 0x560], 7
call fcn.005128e4
lea ecx, [esp + 0x40]
mov byte [esp + 0x560], 2
call fcn.005128e4
mov edx, dword [esp + 0x18]
lea ecx, [esp + 0x24]
push ecx
push 0xf003f
push edi
push edx
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x409fa3
mov ecx, 0x80
lea edi, [esp + 0x358]
rep stosd dword es:[edi], eax
lea eax, [esp + 0x1c]
lea ecx, [esp + 0x358]
push eax
lea edx, [esp + 0x40]
push ecx
push edx
mov edx, dword [esp + 0x30]
lea eax, [esp + 0x34]
push 0
lea ecx, [esp + 0x168]
push eax
push ecx
push 0
mov dword [esp + 0x44], esi
mov dword [esp + 0x38], esi
push edx
mov esi, 1
call dword [sym.imp.ADVAPI32.dll_RegEnumValueA]
test eax, eax
jne 0x409f91
lea eax, [esp + 0x158]
lea ecx, [esp + 0x10]
push eax
call fcn.00512952
mov eax, dword [0x5ab980]
mov dword [esp + 0x14], eax
mov dword [esp + 0x20], eax
mov eax, 0x200
mov ecx, 0x80
mov dword [esp + 0x28], eax
mov dword [esp + 0x1c], eax
xor eax, eax
lea edi, [esp + 0x358]
cmp ebx, 2
mov byte [esp + 0x560], 0xb
rep stosd dword es:[edi], eax
jne 0x409ed6
lea ecx, [esp + 0x10]
call fcn.00512e18
push str.hkey_
lea ecx, [esp + 0x14]
call fcn.0050e341
lea ecx, [esp + 0x48]
push eax
push ecx
lea ecx, [esp + 0x18]
call fcn.0050e172
push eax
lea ecx, [esp + 0x14]
mov byte [esp + 0x564], 0xc
call fcn.00512a1d
lea ecx, [esp + 0x48]
mov byte [esp + 0x560], 0xb
call fcn.005128e4
push 0
push 0
push ecx
lea edx, [esp + 0x1c]
mov ecx, esp
mov dword [esp + 0x44], esp
push edx
call fcn.00512659
mov ecx, ebp
call fcn.00407760
jmp 0x409f26
lea eax, [esp + 0x10]
push eax
call fcn.00420f40
lea ecx, [esp + 0x24]
lea edx, [esp + 0x18]
push ecx
lea eax, [esp + 0x18]
push edx
push eax
call fcn.004222e0
add esp, 0x10
test eax, eax
jne 0x409f1a
lea ecx, [esp + 0x20]
lea edx, [esp + 0x14]
push ecx
push ecx
mov ecx, esp
mov dword [esp + 0x40], esp
push edx
call fcn.00512659
mov ecx, ebp
call fcn.00407eb0
jmp 0x409f26
lea eax, [esp + 0x20]
mov ecx, ebp
push eax
call fcn.00407e10
lea ecx, [esp + 0x20]
mov byte [esp + 0x560], 0xa
call fcn.005128e4
lea ecx, [esp + 0x14]
mov byte [esp + 0x560], 9
call fcn.005128e4
lea ecx, [esp + 0x10]
mov byte [esp + 0x560], 2
call fcn.005128e4
lea ecx, [esp + 0x1c]
lea edx, [esp + 0x358]
push ecx
lea ecx, [esp + 0x40]
push edx
push ecx
lea edx, [esp + 0x34]
push 0
lea ecx, [esp + 0x168]
mov eax, esi
push edx
mov edx, dword [esp + 0x38]
push ecx
push eax
push edx
inc esi
call dword [sym.imp.ADVAPI32.dll_RegEnumValueA]
test eax, eax
je 0x409e27
mov eax, dword [esp + 0x24]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor edi, edi
mov esi, 0x200
mov ecx, dword [esp + 0x30]
lea edx, [esp + 0x158]
mov eax, ecx
inc ecx
mov dword [esp + 0x30], ecx
mov ecx, dword [esp + 0x1c]
push ecx
push edx
push eax
mov eax, dword [esp + 0x38]
push eax
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyA]
cmp eax, edi
je 0x409c7a
mov ecx, dword [esp + 0x2c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [esp + 0x34]
mov byte [esp + 0x560], 1
call fcn.005128e4
lea ecx, [esp + 0x18]
mov byte [esp + 0x560], 0
call fcn.005128e4
lea ecx, [esp + 0x568]
mov dword [esp + 0x560], 0xffffffff
call fcn.005128e4
mov eax, 1
mov ecx, dword [esp + 0x558]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0x554
ret 4