Function at 0x407962
Capabilities:
Get hostname
Query or enumerate registry value
Set registry value

Disassembly:
push 0x30
push 0x4182e8
call fcn.0040ec0c
xor esi, esi
mov dword [ebp - 0x3c], esi
mov dword [ebp - 0x40], esi
mov dword [ebp - 0x34], esi
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x28], esi
mov dword [ebp - 0x2c], esi
mov dword [ebp - 0x1c], esi
mov dword [ebp - 4], esi
cmp dword [0x41be64], esi
jne 0x407b5c
mov ecx, 0x41759c
call fcn.004073dd
mov dword [ebp - 0x38], eax
lea ecx, [ebp - 0x1c]
push ecx
push 0x20119
push esi
push eax
push 0x80000002
call dword [sym.imp.advapi32.dll_RegOpenKeyExA]
test eax, eax
jne 0x407b24
mov edi, 0x2800
push edi
push pe_nt_image_headers32
call dword [sym.imp.kernel32.dll_GlobalAlloc]
mov dword [ebp - 0x30], eax
push 0x64
push 0x30
push eax
call fcn.0040d1e0
add esp, 0xc
mov dword [ebp - 0x20], edi
mov ecx, 0x4175d0
call fcn.004073dd
mov dword [ebp - 0x3c], eax
lea ecx, [ebp - 0x20]
push ecx
push dword [ebp - 0x30]
push esi
push esi
push eax
push dword [ebp - 0x1c]
mov edi, dword [sym.imp.advapi32.dll_RegQueryValueExA]
call edi
or eax, eax
je 0x407a0d
mov dword [ebp - 0x28], 1
push 4
pop ebx
mov dword [ebp - 0x20], ebx
mov ecx, 0x4175e8
call fcn.004073dd
mov dword [ebp - 0x40], eax
lea ecx, [ebp - 0x20]
push ecx
lea ecx, [ebp - 0x2c]
push ecx
push esi
push esi
push eax
push dword [ebp - 0x1c]
call edi
or eax, eax
je 0x407a37
inc dword [ebp - 0x28]
cmp dword [ebp - 0x28], esi
jle 0x407ab1
mov dword [ebp - 0x24], esi
mov dword [ebp - 0x20], ebx
mov ecx, 0x4175fc
call fcn.004073dd
mov dword [ebp - 0x34], eax
lea ecx, [ebp - 0x20]
push ecx
lea ecx, [ebp - 0x24]
push ecx
push esi
push esi
push eax
push dword [ebp - 0x1c]
call edi
test eax, eax
je 0x407aab
call dword [sym.imp.kernel32.dll_GetTickCount]
mov dword [ebp - 0x24], eax
push dword [ebp - 0x1c]
call dword [sym.imp.advapi32.dll_RegCloseKey]
lea eax, [ebp - 0x1c]
push eax
push 0x4001f
push esi
push dword [ebp - 0x38]
push 0x80000002
call dword [sym.imp.advapi32.dll_RegOpenKeyExA]
test eax, eax
jne 0x407aa8
push ebx
lea eax, [ebp - 0x24]
push eax
push ebx
push esi
push dword [ebp - 0x34]
push dword [ebp - 0x1c]
call dword [sym.imp.advapi32.dll_RegSetValueExA]
test eax, eax
je 0x407aab
mov dword [ebp - 0x24], esi
mov eax, dword [ebp - 0x24]
xor dword [ebp - 0x2c], eax
push dword [ebp - 0x1c]
call dword [sym.imp.advapi32.dll_RegCloseKey]
mov esi, dword [ebp - 0x30]
add esi, 8
push esi
mov edi, dword [sym.imp.kernel32.dll_lstrlen]
call edi
push eax
push esi
call fcn.00407903
mov esi, eax
xor esi, dword [ebp - 0x2c]
push 0x10
pop eax
mov dword [ebp - 0x20], eax
push eax
call fcn.00407b66
add esp, 0xc
mov ebx, eax
lea eax, [ebp - 0x20]
push eax
push ebx
call dword [sym.imp.kernel32.dll_GetComputerNameA]
push ebx
call edi
push eax
push ebx
call fcn.00407903
mov edi, eax
push ebx
call fcn.00407b73
push dword [ebp - 0x30]
call fcn.00407b73
add esp, 0x10
mov dword [0x41be68], esi
mov dword [0x41be6c], edi
mov dword [0x41be64], 1
push dword [ebp - 0x38]
call fcn.00407b85
push dword [ebp - 0x3c]
call fcn.00407b85
push dword [ebp - 0x40]
call fcn.00407b85
push dword [ebp - 0x34]
call fcn.00407b85
jmp 0x407b59
add esp, 0x10
or dword [ebp - 4], 0xffffffff
call fcn.0040ec47
ret