Function at 0x10025140
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x8c
mov eax, dword [0x1009c00c]
xor eax, esp
mov dword [esp + 0x84], eax
push ebx
mov ebx, dword [esp + 0x98]
push ebp
mov ebp, dword [esp + 0x98]
push esi
push edi
mov edi, dword [ecx + 0x13b4]
test edi, edi
je 0x100252ae
mov ecx, dword [edi + 4]
test ecx, ecx
je 0x10025419
cmp word [0x100a812c], 3
mov esi, dword [ebx]
jb 0x100251ea
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
push str.__08x__:
lea eax, [esp + 0x30]
push 0x64
push eax
call fcn.10002400
add esp, 4
mov edx, esi
mov ecx, ebp
call fcn.100331b0
add esp, 0xc
lea eax, [esp + 0x28]
push 0x1007caa0
push 0x100a8130
push str.CVPusbIO::Write
push eax
push str._s_s__r_n_s_s
push 1
call fcn.100474ec
add esp, 4
push eax
call fcn.10002360
mov byte [0x100a8130], 0
add esp, 0x18
mov esi, dword [ebx]
mov ecx, dword [edi + 4]
mov dl, byte [edi + 0x18]
lea eax, [esp + 0x10]
push ecx
push dword [edi + 0x20]
mov dword [esp + 0x18], 0
push eax
push esi
push ebp
call fcn.10038880
mov esi, eax
add esp, 0x14
test esi, esi
jne 0x1002527d
mov eax, dword [esp + 0x10]
cmp eax, dword [ebx]
je 0x10025255
push eax
push eax
push str.CVPusbIO_write_count__d__libusb_wrote__d_r_n
mov dword [ebx], eax
mov esi, 1
call fcn.10032e70
add esp, 0xc
push 0x1ed
push str.CVPusbIO::Write
push str.C:DevProjectsVPlibusbVPlibusbVPusbIO.cpp
push str._t_____leaving__s_:__s_:__d_r_n
call fcn.10032e90
shl esi, 0x10
add esp, 0x10
or esi, 0x1b
mov eax, esi
jmp 0x1002541e
movzx ecx, word [edi + 0x1a]
cdq
idiv ecx
test edx, edx
jne 0x1002527d
mov dl, byte [edi + 0x18]
lea eax, [esp + 0x10]
push ecx
push dword [edi + 0x20]
mov ecx, dword [edi + 4]
push eax
push 0
push 0
call fcn.10038880
add esp, 0x14
mov esi, eax
push 0x1ed
push str.CVPusbIO::Write
push str.C:DevProjectsVPlibusbVPlibusbVPusbIO.cpp
push str._t_____leaving__s_:__s_:__d_r_n
call fcn.10032e90
add esp, 0x10
test esi, esi
je 0x10025415
shl esi, 0x10
or esi, 0x1b
mov eax, esi
jmp 0x1002541e
mov esi, dword [ecx + 0x13b8]
test esi, esi
je 0x10025419
mov ecx, dword [esi + 0x3c]
test ecx, ecx
je 0x10025419
cmp word [0x100a812c], 3
mov edi, dword [ebx]
jb 0x10025332
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
push str.__08x__:
lea eax, [esp + 0x30]
push 0x64
push eax
call fcn.10002400
add esp, 4
mov edx, edi
mov ecx, ebp
call fcn.100331b0
add esp, 0xc
lea eax, [esp + 0x28]
push 0x1007caa0
push 0x100a8130
push str.CVPserIO::Write
push eax
push str._s_s__r_n_s_s
push 1
call fcn.100474ec
add esp, 4
push eax
call fcn.10002360
mov byte [0x100a8130], 0
add esp, 0x18
mov edi, dword [ebx]
mov ecx, dword [esi + 0x3c]
mov eax, dword [esi + 0x44]
xorps xmm0, xmm0
mov dword [esp + 0x24], eax
lea eax, [esp + 0x14]
push eax
lea eax, [esp + 0x14]
mov dword [esp + 0x14], 0
push eax
push edi
push ebp
push ecx
movlpd qword [esp + 0x28], xmm0
movlpd qword [esp + 0x30], xmm0
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x100253f7
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
call edi
cmp eax, 0x3e5
je 0x10025387
push eax
push str.PiCommBase::WriteCmd___WriteFile_Result__d_:
call fcn.10032db0
jmp 0x100253c9
push 1
lea eax, [esp + 0x14]
push eax
lea eax, [esp + 0x1c]
push eax
push dword [esi + 0x3c]
call dword [sym.imp.KERNEL32.dll_GetOverlappedResult]
test eax, eax
jne 0x100253f7
call edi
push dword [esp + 0x10]
mov esi, eax
push esi
push str.CVPserIO::Write_:_GetOverlappedResult:__x_dwError__d_dwWritten__d_n
call fcn.10032ed0
add esp, 0xc
cmp esi, 0x3e4
je 0x100253f7
push esi
push str.CVPserIO::Write_:_GetOverlappedResult_Error__d_:
call fcn.10032d90
add esp, 8
mov esi, 1
push 0x20c
push str.CVPserIO::Write
push str.VPserIO.cpp
push str._t_____leaving__s_:__s_:__d_r_n
call fcn.10032e90
shl esi, 0x10
add esp, 0x10
or esi, 0x1d
mov eax, esi
jmp 0x1002541e
push 0x20c
push str.CVPserIO::Write
push str.VPserIO.cpp
push str._t_____leaving__s_:__s_:__d_r_n
call fcn.10032e90
add esp, 0x10
xor esi, esi
mov eax, esi
jmp 0x1002541e
mov eax, 0x19
mov ecx, dword [esp + 0x94]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.100417b6
add esp, 0x8c
ret 8