Function at 0x440850
Capabilities:
Link many functions at runtime

Disassembly:
push 0xffffffffffffffff
push 0x4a185c
mov eax, dword fs:[0]
push eax
sub esp, 0x2bc
mov eax, dword [0x4da22c]
xor eax, esp
mov dword [esp + 0x2b8], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4da22c]
xor eax, esp
push eax
lea eax, [esp + 0x2d0]
mov dword fs:[0], eax
mov esi, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
push str.setupapi.dll
mov dword [esp + 0x4c], ecx
call esi
mov ebx, eax
test ebx, ebx
mov dword [esp + 0x28], ebx
je 0x440be6
push str.HID.dll
call esi
mov edi, eax
test edi, edi
mov dword [esp + 0x40], edi
je 0x440bd6
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.SetupDiEnumDeviceInterfaces
push ebx
call esi
test eax, eax
mov dword [esp + 0x20], eax
je 0x440bd6
push str.SetupDiDestroyDeviceInfoList
push ebx
call esi
test eax, eax
mov dword [esp + 0x30], eax
je 0x440bd6
push str.SetupDiGetDeviceInterfaceDetailA
push ebx
call esi
mov ebp, eax
test ebp, ebp
mov dword [esp + 0x1c], ebp
je 0x440bd6
push str.SetupDiGetClassDevsA
push ebx
call esi
test eax, eax
mov dword [esp + 0x18], eax
je 0x440bd6
push str.HidD_GetHidGuid
push edi
call esi
test eax, eax
mov dword [esp + 0x14], eax
je 0x440bd6
push str.HidD_GetAttributes
push edi
call esi
test eax, eax
mov dword [esp + 0x50], eax
je 0x440bd6
push str.HidD_GetProductString
push edi
call esi
test eax, eax
mov dword [esp + 0x34], eax
je 0x440bd6
push str.HidD_GetPreparsedData
push edi
call esi
test eax, eax
mov dword [esp + 0x3c], eax
je 0x440bd6
push str.HidP_GetCaps
push edi
call esi
test eax, eax
mov dword [esp + 0x2c], eax
je 0x440bd6
push str.HidD_FreePreparsedData
push edi
call esi
test eax, eax
mov dword [esp + 0x4c], eax
je 0x440bd6
lea eax, [esp + 0x60]
push eax
call dword [esp + 0x18]
push 0x12
push 0
push 0
lea ecx, [esp + 0x6c]
push ecx
call dword [esp + 0x28]
mov ebx, eax
cmp ebx, 0xffffffff
mov dword [esp + 0x44], ebx
je 0x440bd2
lea edx, [esp + 0x70]
push edx
push 0
lea eax, [esp + 0x68]
push eax
push 0
push ebx
mov dword [esp + 0x84], 0x1c
mov dword [esp + 0x28], 0
call dword [esp + 0x34]
test eax, eax
je 0x440bcd
push 0
lea ecx, [esp + 0x28]
push ecx
push 0
push 0
lea edx, [esp + 0x80]
push edx
push ebx
call ebp
mov eax, dword [esp + 0x24]
push eax
mov esi, eax
call fcn.0048963c
add esp, 4
push 0
mov edi, eax
lea eax, [esp + 0x28]
push eax
push esi
push edi
lea ecx, [esp + 0x80]
push ecx
push ebx
mov dword [edi], 5
call ebp
test eax, eax
je 0x440b9b
push 0
push 0
push 3
push 0
push 3
lea eax, [edi + 4]
push 0xc0000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
je 0x440b9b
lea edx, [esp + 0x54]
push edx
push esi
mov dword [esp + 0x5c], 0xc
call dword [esp + 0x58]
test al, al
je 0x440b94
cmp word [esp + 0x58], 0x1044
jne 0x440b94
cmp word [esp + 0x5a], 0x4001
jne 0x440b94
push 0x100
lea eax, [esp + 0xd0]
push eax
push esi
call dword [esp + 0x40]
xor ebp, ebp
push ebp
push ebp
push 0x100
lea ecx, [esp + 0x1d8]
push ecx
push 0xffffffffffffffff
lea edx, [esp + 0xe0]
push edx
push ebp
push ebp
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
push 0x1fc
call fcn.00479967
add esp, 4
mov dword [esp + 0x38], eax
cmp eax, ebp
mov dword [esp + 0x2d8], ebp
je 0x440adf
mov ecx, eax
call fcn.0044ff00
mov ebp, eax
mov eax, dword [esp + 0x48]
mov ecx, dword [eax + 8]
push ebp
mov dword [esp + 0x2dc], 0xffffffff
call fcn.0043f770
lea ecx, [esp + 0x18]
push ecx
push esi
call dword [esp + 0x44]
test al, al
je 0x440b90
mov eax, dword [esp + 0x18]
lea edx, [esp + 0x8c]
push edx
push eax
call dword [esp + 0x34]
cmp eax, 0x110000
jne 0x440b87
push 0x238
call fcn.00479967
add esp, 4
mov dword [esp + 0x38], eax
test eax, eax
mov dword [esp + 0x2d8], 1
je 0x440b62
movzx ecx, word [esp + 0x90]
movzx edx, word [esp + 0x92]
push ecx
push edx
lea ecx, [edi + 4]
push ecx
mov ecx, eax
call fcn.00449fa0
mov ebx, eax
jmp 0x440b64
xor ebx, ebx
mov dword [esp + 0x2d8], 0xffffffff
call fcn.00435370
mov ecx, dword [eax + 0x1c]
push ebx
call fcn.00430910
mov dword [ebp + 0x138], ebx
mov ebx, dword [esp + 0x44]
mov eax, dword [esp + 0x18]
push eax
call dword [esp + 0x50]
mov ebp, dword [esp + 0x1c]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call fcn.004896ff
mov eax, dword [esp + 0x18]
add esp, 4
lea ecx, [esp + 0x70]
push ecx
add eax, 1
push eax
lea edx, [esp + 0x68]
push edx
push 0
push ebx
mov dword [esp + 0x28], eax
call dword [esp + 0x34]
test eax, eax
jne 0x4409e4
mov edi, dword [esp + 0x40]
push ebx
call dword [esp + 0x34]
mov ebx, dword [esp + 0x28]
mov esi, dword [sym.imp.KERNEL32.dll_FreeLibrary]
push ebx
call esi
test edi, edi
je 0x440be6
push edi
call esi
mov eax, 1
mov ecx, dword [esp + 0x2d0]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x2b8]
xor ecx, esp
call fcn.00488320
add esp, 0x2c8
ret