Function at 0x4078e0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x450
mov al, byte [0x41ed78]
push ebx
push ebp
push esi
mov dword [esp + 0x10], ecx
push edi
mov byte [esp + 0x60], al
mov ecx, 0xff
xor eax, eax
lea edi, [esp + 0x61]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov ebp, dword [esp + 0x46c]
mov edx, 0x1c
stosb byte es:[edi], al
mov ecx, 6
xor eax, eax
lea edi, [esp + 0x2c]
mov dword [esp + 0x28], edx
rep stosd dword es:[edi], eax
xor ebx, ebx
mov ecx, 6
lea edi, [esp + 0x48]
mov dword [esp + 0x44], edx
cmp ebp, ebx
mov dword [esp + 0x18], ebx
rep stosd dword es:[edi], eax
jne 0x407942
mov ebp, 1
mov eax, dword [esp + 0x468]
cmp eax, ebx
jne 0x407961
cmp ebp, 1
je 0x40795c
cmp ebp, 4
mov eax, 0x12
jne 0x407961
mov eax, 0x10
push eax
push ebx
push ebx
push 0x4170c0
call dword [sym.imp.SETUPAPI.dll_SetupDiGetClassDevsA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x407993
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, ebx
jne 0x407b1d
or eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x450
ret 0x10
mov dword [esp + 0x60], 5
mov dword [esp + 0x10], ebx
mov edx, dword [esp + 0x10]
mov ecx, 7
xor eax, eax
lea edi, [esp + 0x44]
rep stosd dword es:[edi], eax
lea ecx, [esp + 0x44]
mov dword [esp + 0x24], ebx
push ecx
push edx
push 0x4170c0
push ebx
push esi
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
mov dword [esp + 0x58], 0x1c
call dword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInterfaces]
test eax, eax
jne 0x4079fa
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, ebx
je 0x407b09
cmp eax, 0x103
je 0x407b12
inc dword [esp + 0x10]
jmp 0x40799f
mov ecx, pe_nt_image_headers32
xor eax, eax
lea edi, [esp + 0x60]
lea edx, [esp + 0x44]
rep stosd dword es:[edi], eax
mov ecx, 7
lea edi, [esp + 0x28]
rep stosd dword es:[edi], eax
lea eax, [esp + 0x28]
lea ecx, [esp + 0x60]
push eax
push ebx
push 0x400
push ecx
push edx
push esi
mov dword [esp + 0x78], 5
mov dword [esp + 0x40], 0x1c
call dword [sym.imp.SETUPAPI.dll_SetupDiGetDeviceInterfaceDetailA]
test eax, eax
je 0x407b09
push 0x10
lea eax, [esp + 0x68]
push str._usbstordisk
push eax
call fcn.00411750
add esp, 0xc
test eax, eax
jne 0x407b09
mov edx, dword [esp + 0x3c]
lea ecx, [esp + 0x20]
push 1
push ecx
mov ecx, dword [esp + 0x1c]
push edx
call fcn.00407180
cmp eax, 0xd
je 0x407b09
cmp eax, 5
je 0x407b09
mov eax, dword [esp + 0x20]
cmp eax, ebp
je 0x407b09
cmp eax, 1
jne 0x407a9d
cmp ebp, 4
je 0x407b09
jmp 0x407aa7
cmp eax, 5
jne 0x407aa7
cmp ebp, 2
je 0x407b09
mov edi, dword [esp + 0x464]
cmp edi, ebx
je 0x407aed
lea eax, [esp + 0x1c]
lea ecx, [esp + 0x24]
push eax
push ebx
lea edx, [esp + 0x6c]
push ecx
push edx
call fcn.004127c0
add esp, 0x10
test eax, eax
je 0x407b09
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x24]
push eax
push ecx
call fcn.00412730
add esp, 8
cmp eax, ebx
jne 0x407ae9
mov eax, 0x10000000
test edi, eax
je 0x407b09
mov edx, dword [esp + 0x470]
mov ecx, dword [esp + 0x14]
push edx
lea eax, [esp + 0x2c]
push ebp
push eax
push esi
call fcn.00408690
mov dword [esp + 0x18], eax
inc dword [esp + 0x10]
jmp 0x40799f
push esi
call dword [sym.imp.SETUPAPI.dll_SetupDiDestroyDeviceInfoList]
mov eax, dword [esp + 0x18]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x450
ret 0x10