Function at 0x404600
Capabilities:
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
push 0xffffffffffffffff
push 0x43c8f8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x20
push ebx
push esi
xor ebx, ebx
push 0x43ffb2
lea ecx, [esp + 0xc]
mov dword [esp + 0x20], ebx
call fcn.00401a30
lea eax, [esp + 0xc]
push eax
push 1
push ebx
push str.HARDWAREDEVICEMAPSERIALCOMM
push reloc.OLEAUT32.dll_SysReAllocString
mov dword [esp + 0x44], ebx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
cmp eax, ebx
je 0x404663
mov esi, dword [esp + 0x38]
push str.COM1_COM2_COM3_COM4_COM5_COM6_COM7_COM7_COM8_COM9_COM10
mov ecx, esi
call fcn.00401a30
jmp 0x4047f2
mov edx, dword [esp + 0xc]
push ebx
push ebx
push ebx
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x24]
push ecx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push edx
call dword [sym.imp.ADVAPI32.dll_RegQueryInfoKeyA]
cmp eax, ebx
je 0x40469a
mov esi, dword [esp + 0x38]
push str.COM1_COM2_COM3_COM4_COM5_COM6_COM7_COM7_COM8_COM9_COM10
mov ecx, esi
call fcn.00401a30
jmp 0x4047f2
cmp dword [esp + 0x14], ebx
mov dword [esp + 0x10], 6
jbe 0x4047d9
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_VirtualAlloc]
push edi
mov eax, dword [esp + 0x20]
push 4
inc eax
push 0x1000
push eax
push 0
mov dword [esp + 0x34], eax
mov dword [esp + 0x28], 6
call ebp
mov ecx, dword [esp + 0x14]
push 0
push 0
push 0
push 0
mov edi, eax
lea eax, [esp + 0x34]
push eax
push edi
push ebx
push ecx
call dword [sym.imp.ADVAPI32.dll_RegEnumValueA]
xor edx, edx
cmp eax, 0x103
setne dl
xor ecx, ecx
test eax, eax
setne cl
test ecx, edx
jne 0x4047ca
push 4
push 0x1000
push 6
push 0
call ebp
lea edx, [esp + 0x18]
push edx
mov esi, eax
mov eax, dword [esp + 0x18]
push esi
push 0
push 0
push edi
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4047ca
push esi
lea ecx, [esp + 0x30]
call fcn.00401a30
push 0x440310
push eax
lea ecx, [esp + 0x30]
push ecx
mov byte [esp + 0x44], 1
call fcn.00402c60
add esp, 0xc
mov eax, dword [eax]
mov ecx, dword [eax - 0xc]
push ecx
push eax
lea ecx, [esp + 0x18]
mov byte [esp + 0x40], 2
call fcn.004017f0
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
mov byte [esp + 0x38], 1
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40478d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov eax, dword [esp + 0x2c]
add eax, 0xfffffff0
mov byte [esp + 0x38], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4047b0
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
push 0x8000
push 0
push edi
mov edi, dword [sym.imp.KERNEL32.dll_VirtualFree]
call edi
push 0x8000
push 0
push esi
call edi
mov eax, dword [esp + 0x1c]
inc ebx
cmp ebx, eax
jb 0x4046b4
pop edi
pop ebp
mov eax, dword [esp + 8]
add eax, 0xfffffff0
push eax
call fcn.00402790
mov esi, dword [esp + 0x3c]
add esp, 4
add eax, 0x10
mov dword [esi], eax
mov eax, dword [esp + 8]
add eax, 0xfffffff0
mov dword [esp + 0x30], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x404818
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
mov ecx, dword [esp + 0x28]
mov eax, esi
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x2c
ret 4