Function at 0x406360
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
mov dword [ebp - 4], 0
mov dword [ebp - 8], 0
push 0x14
call fcn.0041fee2
add esp, 4
mov dword [ebp - 0xc], eax
mov ebx, eax
mov edi, eax
xor eax, eax
mov ecx, 5
rep stosd dword es:[edi], eax
mov dword [ebp - 0x10], 0
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x18], 0
cmp dword [0x42e781], 0xffffffff
jne 0x4063c0
mov eax, 0
jmp 0x4066c4
push 0x80000301
push 0
push 0x41
push 1
mov ebx, 0x1bc
call fcn.00421e40
add esp, 0x10
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x1c]
push eax
mov ebx, dword [ebp - 4]
test ebx, ebx
je 0x4063f5
push ebx
call fcn.0041fef4
add esp, 4
pop eax
mov dword [ebp - 4], eax
push 0x80000301
push 0
push dword [0x42e781]
push 1
mov ebx, 0x168
call fcn.004218e0
add esp, 0x10
mov dword [ebp - 0x1c], eax
push dword [ebp - 0x1c]
push str.HID_ReadData_
mov ecx, 2
call fcn.0040107b
add esp, 8
mov dword [ebp - 0x20], eax
mov ebx, dword [ebp - 0x1c]
test ebx, ebx
je 0x406443
push ebx
call fcn.0041fef4
add esp, 4
mov dword [ebp - 0x24], esp
push dword [ebp - 0x20]
push 1
push 1
push 0
xor eax, eax
call dword [sym.imp.KERNEL32.dll_CreateEventA]
nop
nop
cmp dword [ebp - 0x24], esp
je 0x40647e
push 0xe3
push 0x401c81f
push 6
call fcn.0041fee8
add esp, 0xc
mov dword [ebp - 0x28], eax
mov ebx, dword [ebp - 0x20]
test ebx, ebx
je 0x406491
push ebx
call fcn.0041fef4
add esp, 4
mov eax, dword [ebp - 0x28]
mov dword [ebp - 8], eax
mov ebx, dword [ebp - 0xc]
add ebx, 0x10
mov dword [ebp - 0x1c], ebx
mov eax, dword [ebp - 8]
mov ebx, dword [ebp - 0x1c]
mov dword [ebx], eax
mov ebx, dword [ebp - 0xc]
add ebx, 8
mov dword [ebp - 0x1c], ebx
mov ebx, dword [ebp - 0x1c]
mov dword [ebx], 0
mov ebx, dword [ebp - 0xc]
add ebx, 0xc
mov dword [ebp - 0x1c], ebx
mov ebx, dword [ebp - 0x1c]
mov dword [ebx], 0
mov dword [ebp - 0x1c], esp
push dword [ebp - 8]
xor eax, eax
call dword [sym.imp.KERNEL32.dll_ResetEvent]
nop
nop
cmp dword [ebp - 0x1c], esp
je 0x4064f8
push 0x182
push 0x401c81f
push 6
call fcn.0041fee8
add esp, 0xc
mov dword [ebp - 0x1c], esp
push dword [ebp - 0xc]
mov eax, 0x41
mov dword [ebp - 0x20], eax
lea eax, [ebp - 0x20]
push eax
push 0x41
mov eax, dword [ebp - 4]
test eax, eax
je 0x406519
add eax, 8
push eax
push dword [0x42e781]
xor eax, eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
nop
nop
cmp dword [ebp - 0x1c], esp
je 0x406546
push 0x1b5
push 0x401c81f
push 6
call fcn.0041fee8
add esp, 0xc
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
and eax, 1
xor eax, 1
test eax, eax
je 0x4065fb
mov dword [ebp - 0x1c], esp
push 0xa
push dword [ebp - 8]
xor eax, eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
nop
nop
cmp dword [ebp - 0x1c], esp
je 0x40658b
push 0x236
push 0x401c81f
push 6
call fcn.0041fee8
add esp, 0xc
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x10], 1
cmp dword [ebp - 0x14], 0x80
je 0x4065b3
cmp dword [ebp - 0x14], 0x102
je 0x4065b3
xor eax, eax
jmp 0x4065b8
mov eax, 1
test eax, eax
je 0x4065f6
mov dword [ebp - 0x1c], esp
push dword [0x42e781]
xor eax, eax
call dword [sym.imp.KERNEL32.dll_CancelIo]
nop
nop
cmp dword [ebp - 0x1c], esp
je 0x4065ef
push 0x2e3
push 0x401c81f
push 6
call fcn.0041fee8
add esp, 0xc
mov dword [ebp - 0x10], 0
jmp 0x406690
mov ebx, dword [ebp - 4]
call fcn.00401540
mov eax, 1
cmp eax, ecx
jl 0x406623
push 0x343
push 0x401c81f
push 1
call fcn.0041fee8
add esp, 0xc
add ebx, eax
mov dword [ebp - 0x1c], ebx
mov ebx, dword [ebp - 0x1c]
mov al, byte [ebx]
and eax, 0xff
mov dword [ebp - 0x18], eax
push 0x80000301
push 0
push dword [ebp - 0x18]
push 0x80000301
push 0
push 3
push VariantClear
push 0
mov eax, dword [ebp - 4]
test eax, eax
jne 0x40665e
mov eax, 0x42a2db
push eax
push 3
mov ebx, 0x1a8
call fcn.004224f0
add esp, 0x28
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x1c]
push eax
mov ebx, dword [ebp + 8]
mov ebx, dword [ebx]
test ebx, ebx
je 0x40668a
push ebx
call fcn.0041fef4
add esp, 4
pop eax
mov ebx, dword [ebp + 8]
mov dword [ebx], eax
mov dword [ebp - 0x1c], esp
push dword [ebp - 8]
xor eax, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
nop
nop
cmp dword [ebp - 0x1c], esp
je 0x4066bc
push 0x3b0
push 0x401c81f
push 6
call fcn.0041fee8
add esp, 0xc
mov eax, dword [ebp - 0x10]
jmp 0x4066c4
push eax
mov ebx, dword [ebp - 4]
test ebx, ebx
je 0x4066d5
push ebx
call fcn.0041fef4
add esp, 4
mov ebx, dword [ebp - 0xc]
push ebx
call fcn.0041fef4
add esp, 4
pop eax
mov esp, ebp
pop ebp
ret 4