Function at 0x406390
Capabilities:
Get system information on windows
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x118
mov eax, dword [0x4ce540]
xor eax, ebp
mov dword [ebp - 4], eax
xor eax, eax
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 0xd4], eax
mov dword [ebp - 0xd0], eax
mov dword [ebp - 0xcc], eax
mov dword [ebp - 0xc8], eax
mov dword [ebp - 0xc4], eax
mov dword [ebp - 0xc0], eax
mov dword [ebp - 0xb8], eax
mov dword [ebp - 0xb4], eax
mov dword [ebp - 0xb0], eax
mov dword [ebp - 0xac], eax
mov dword [ebp - 0xa8], eax
mov dword [ebp - 0xa4], eax
mov dword [ebp - 0xf0], eax
mov dword [ebp - 0xec], eax
mov dword [ebp - 0xe8], eax
mov dword [ebp - 0xe4], eax
mov dword [ebp - 0xe0], eax
mov dword [ebp - 0xdc], eax
mov dword [ebp - 0x114], eax
mov dword [ebp - 0x110], eax
mov dword [ebp - 0x10c], eax
mov dword [ebp - 0x108], eax
mov dword [ebp - 0x104], eax
mov dword [ebp - 0x100], eax
mov dword [ebp - 0xfc], eax
mov dword [ebp - 0xf8], eax
lea eax, [ebp - 0x88]
push eax
push 0x20019
push ebx
push str.SYSTEMCurrentControlSet_serviceskbdssvc
mov esi, 4
push reloc.OLEAUT32.dll_SysReAllocString
mov edi, ecx
mov dword [ebp - 0x88], ebx
mov dword [ebp - 0x9c], esi
mov dword [ebp - 0xa0], esi
mov dword [ebp - 0x90], ebx
mov dword [ebp - 0xd8], ebx
mov dword [ebp - 0xbc], ebx
mov dword [ebp - 0xf4], ebx
mov dword [ebp - 0x118], ebx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
cmp eax, ebx
je 0x4064cc
test eax, 0x20000000
je 0x4064c1
cmp eax, ebx
jg 0x4064b0
mov esi, eax
jmp 0x406672
and eax, 0xffff
or eax, 0xa0070000
mov esi, eax
jmp 0x406672
cmp eax, ebx
jg 0x4064ff
mov esi, eax
jmp 0x406672
lea ecx, [ebp - 0xa0]
push ecx
mov ecx, dword [ebp - 0x88]
lea edx, [ebp - 0x90]
push edx
lea eax, [ebp - 0x9c]
push eax
push ebx
push str.Status
push ecx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, ebx
je 0x406510
cmp eax, 2
je 0x40651f
jmp 0x40649e
and eax, 0xffff
or eax, 0x80070000
mov esi, eax
jmp 0x406672
mov eax, dword [ebp - 0x90]
cmp eax, ebx
je 0x406526
cmp eax, 1
je 0x406526
mov dword [edi + 0x2c], 1
cmp dword [edi + 0x2c], ebx
jne 0x406670
lea edx, [ebp - 0xd8]
push edx
push str.kbdhid
call fcn.00414f00
lea eax, [ebp - 0xbc]
push eax
push str.hidusb
call fcn.00414f00
add esp, 0x10
cmp dword [ebp - 0xd4], esi
jne 0x406564
cmp dword [ebp - 0xb8], esi
je 0x406587
lea ecx, [ebp - 0xf4]
push ecx
push str.i8042prt
call fcn.00414f00
add esp, 8
cmp dword [ebp - 0xf0], esi
je 0x406587
mov dword [edi + 0x2c], 1
cmp dword [edi + 0x2c], ebx
jne 0x406670
lea edx, [ebp - 0x118]
push edx
call dword [sym.imp.KERNEL32.dll_GetNativeSystemInfo]
mov eax, dword [ebp - 0x118]
cmp ax, bx
je 0x4065b5
cmp ax, 9
je 0x4065b5
mov dword [edi + 0x2c], 1
cmp dword [edi + 0x2c], ebx
jne 0x406670
push 0x7e
lea ecx, [ebp - 0x82]
xor eax, eax
push ebx
push ecx
mov dword [ebp - 0x8c], ebx
mov word [ebp - 0x84], ax
call fcn.00427b00
add esp, 0xc
lea edx, [ebp - 0x8c]
push edx
push str.HARDWAREDESCRIPTIONSystemBIOS
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [ebp - 0x98], ebx
mov dword [ebp - 0x94], 0x80
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyW]
test eax, eax
jne 0x406660
lea eax, [ebp - 0x94]
push eax
mov eax, dword [ebp - 0x8c]
lea ecx, [ebp - 0x84]
push ecx
lea edx, [ebp - 0x98]
push edx
push ebx
push str.SystemFamily
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x406653
push str.Surface
lea ecx, [ebp - 0x84]
push ecx
call dword [sym.imp.SHLWAPI.dll_StrStrIW]
test eax, eax
je 0x406653
mov dword [edi + 0x2c], 1
mov edx, dword [ebp - 0x8c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp dword [edi + 0x2c], ebx
jne 0x406670
call fcn.004066a0
mov esi, eax
cmp esi, ebx
jl 0x406672
xor esi, esi
mov eax, dword [ebp - 0x88]
cmp eax, ebx
je 0x406683
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp - 4]
pop edi
mov eax, esi
pop esi
xor ecx, ebp
pop ebx
call fcn.004265ea
mov esp, ebp
pop ebp
ret