Function at 0x41c900
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffff7c
mov dword [ebp - 0x2c], eax
mov eax, 0x4d08e4
call fcn.004b9cc0
mov byte [ebp - 0x31], 0
movsx edx, byte [0x4c5664]
cmp edx, 0x30
jne 0x41c93f
mov dl, 0x15
mov eax, dword [ebp - 0x2c]
call fcn.0041cdbc
push 0xc
push dword [0x4dea64]
call sub.RT_USB.DLL_FT_W32_PurgeComm_1
jmp 0x41c956
mov dl, 0x17
mov eax, dword [ebp - 0x2c]
call fcn.0041ce54
push 0xc
push dword [0x4dea64]
call sub.kernel32.dll_PurgeComm_1
mov byte [ebp - 0x32], 0
movsx ecx, byte [0x4c5664]
cmp ecx, 0x30
jne 0x41c980
push 0
push 0x4dec34
push 1
lea eax, [ebp - 0x30]
push eax
push dword [0x4dea64]
call sub.RT_USB.DLL_FT_W32_ReadFile_1
jmp 0x41c998
push 0
push 0x4dec34
push 1
lea edx, [ebp - 0x30]
push edx
push dword [0x4dea64]
call sub.kernel32.dll_ReadFile_1
cmp dword [0x4dec34], 0
jne 0x41c9aa
inc byte [ebp - 0x32]
cmp byte [ebp - 0x32], 5
jb 0x41c95a
cmp dword [0x4dec34], 0
jne 0x41c9c4
mov al, 2
mov edx, dword [ebp - 0x28]
mov dword fs:[0], edx
jmp 0x41cdb6
cmp byte [ebp - 0x30], 0x55
je 0x41ca79
cmp byte [ebp - 0x30], 0xb5
je 0x41c9da
cmp byte [ebp - 0x30], 0xa5
jne 0x41ca1e
mov dword [0x4dec1c], 0x2580
mov dword [0x4dec00], 0x2580
movsx ecx, byte [0x4c5664]
cmp ecx, 0x30
jne 0x41ca0c
push 0x4debfc
push dword [0x4dea64]
call sub.RT_USB.DLL_FT_W32_SetCommState_1
jmp 0x41ca79
push 0x4dec18
push dword [0x4dea64]
call sub.kernel32.dll_SetCommState_1
jmp 0x41ca79
cmp byte [ebp - 0x30], 0x9c
jne 0x41ca68
mov dword [0x4dec1c], 0xe84
mov dword [0x4dec00], 0xe84
movsx eax, byte [0x4c5664]
cmp eax, 0x30
jne 0x41ca56
push 0x4debfc
push dword [0x4dea64]
call sub.RT_USB.DLL_FT_W32_SetCommState_1
jmp 0x41ca79
push 0x4dec18
push dword [0x4dea64]
call sub.kernel32.dll_SetCommState_1
jmp 0x41ca79
mov al, 0xb
mov edx, dword [ebp - 0x28]
mov dword fs:[0], edx
jmp 0x41cdb6
mov byte [ebp - 0x33], 0
movsx ecx, byte [0x4c5664]
cmp ecx, 0x30
jne 0x41caa3
push 0
push 0x4dec34
push 2
lea eax, [ebp - 0x30]
push eax
push dword [0x4dea64]
call sub.RT_USB.DLL_FT_W32_ReadFile_1
jmp 0x41cabb
push 0
push 0x4dec34
push 2
lea edx, [ebp - 0x30]
push edx
push dword [0x4dea64]
call sub.kernel32.dll_ReadFile_1
cmp dword [0x4dec34], 0
jne 0x41cacd
inc byte [ebp - 0x33]
cmp byte [ebp - 0x33], 5
jb 0x41ca7d
cmp dword [0x4dec34], 0
jne 0x41cae7
mov al, 2
mov edx, dword [ebp - 0x28]
mov dword fs:[0], edx
jmp 0x41cdb6
cmp dword [0x4dec34], 2
je 0x41cb01
mov al, 0xc
mov edx, dword [ebp - 0x28]
mov dword fs:[0], edx
jmp 0x41cdb6
cmp byte [ebp - 0x30], 1
je 0x41cb1e
cmp byte [ebp - 0x2f], 0x8a
je 0x41cb1e
mov al, 0xc
mov edx, dword [ebp - 0x28]
mov dword fs:[0], edx
jmp 0x41cdb6
mov cl, 0xff
sub cl, byte [ebp - 0x2f]
mov byte [ebp - 0x2f], cl
push 0x14
call sub.kernel32.dll_Sleep_1
movsx eax, byte [0x4c5664]
cmp eax, 0x30
jne 0x41cb6b
push 0
push 0x4dec34
push 1
lea edx, [ebp - 0x2f]
push edx
push dword [0x4dea64]
call sub.RT_USB.DLL_FT_W32_WriteFile_1
push 0
push 0x4dec34
push 1
lea ecx, [ebp - 0x30]
push ecx
push dword [0x4dea64]
call sub.RT_USB.DLL_FT_W32_ReadFile_1
jmp 0x41cb9b
push 0
push 0x4dec34
push 1
lea eax, [ebp - 0x2f]
push eax
push dword [0x4dea64]
call sub.kernel32.dll_WriteFile_1
push 0
push 0x4dec34
push 1
lea edx, [ebp - 0x30]
push edx
push dword [0x4dea64]
call sub.kernel32.dll_ReadFile_1
cmp dword [0x4dec34], 0
jne 0x41cbb5
mov al, 1
mov edx, dword [ebp - 0x28]
mov dword fs:[0], edx
jmp 0x41cdb6
mov eax, dword [ebp - 0x2c]
call fcn.0041ceec
test eax, eax
je 0x41cbd2
mov al, 3
mov edx, dword [ebp - 0x28]
mov dword fs:[0], edx
jmp 0x41cdb6
mov byte [ebp - 0x34], 2
jmp 0x41cbf7
xor ecx, ecx
mov cl, byte [ebp - 0x34]
mov al, byte [ecx + 0x4dead5]
and al, 0x7f
xor edx, edx
mov dl, byte [ebp - 0x31]
mov byte [ebp + edx - 0x84], al
inc byte [ebp - 0x31]
inc byte [ebp - 0x34]
xor ecx, ecx
mov cl, byte [ebp - 0x34]
xor eax, eax
mov al, byte [0x4dead6]
add eax, 2
cmp ecx, eax
jl 0x41cbd8
cmp byte [0x4dead5], 9
jne 0x41cc5d
xor edx, edx
mov dl, byte [ebp - 0x31]
mov byte [ebp + edx - 0x84], 0
mov word [ebp - 0x18], 8
lea edx, [ebp - 0x84]
lea eax, [ebp - 4]
call fcn.004c3c68
inc dword [ebp - 0xc]
mov edx, dword [eax]
mov eax, dword [sym.Project1.exe__Form8]
mov ecx, dword [eax]
mov eax, dword [ecx + 0x2d4]
call fcn.0048e39c
dec dword [ebp - 0xc]
lea eax, [ebp - 4]
mov edx, 2
call fcn.004c3e54
jmp 0x41cc84
push 0
xor ecx, ecx
mov dl, 9
mov eax, dword [ebp - 0x2c]
call fcn.0041d2bc
test eax, eax
je 0x41cbb5
mov al, 4
mov edx, dword [ebp - 0x28]
mov dword fs:[0], edx
jmp 0x41cdb6
cmp byte [ebp - 0x31], 0
je 0x41ccb7
xor ecx, ecx
mov cl, byte [ebp - 0x31]
movsx eax, byte [ebp + ecx - 0x84]
cmp eax, 0x56
jne 0x41ccae
xor edx, edx
mov dl, byte [ebp - 0x31]
movsx ecx, byte [ebp + edx - 0x83]
cmp ecx, 0x57
je 0x41ccb7
dec byte [ebp - 0x31]
cmp byte [ebp - 0x31], 0
jne 0x41cc8a
cmp byte [ebp - 0x31], 0
jne 0x41ccce
mov al, 0xd
mov edx, dword [ebp - 0x28]
mov dword fs:[0], edx
jmp 0x41cdb6
inc byte [ebp - 0x31]
inc byte [ebp - 0x31]
xor ecx, ecx
mov cl, byte [ebp - 0x31]
movsx eax, byte [ebp + ecx - 0x84]
cmp eax, 0x2d
jne 0x41cce9
inc byte [ebp - 0x31]
xor edx, edx
mov dl, byte [ebp - 0x31]
mov cl, byte [ebp + edx - 0x84]
sub cl, 0x32
je 0x41cd0c
dec cl
je 0x41cd30
sub cl, 2
je 0x41cd54
dec cl
je 0x41cd78
jmp 0x41cd9c
mov byte [0x4dec99], 1
mov byte [0x4dec9a], 0
mov dword [0x4dea5c], 0x100
mov dword [0x4dea60], 0x100
jmp 0x41cdaa
mov byte [0x4dec99], 0xb6
mov byte [0x4dec9a], 0
mov dword [0x4dea5c], 0x200
mov dword [0x4dea60], 0x200
jmp 0x41cdaa
mov byte [0x4dec99], 8
mov byte [0x4dec9a], 0
mov dword [0x4dea5c], 0x200
mov dword [0x4dea60], 0x200
jmp 0x41cdaa
mov byte [0x4dec99], 0xd
mov byte [0x4dec9a], 0
mov dword [0x4dea5c], 0x300
mov dword [0x4dea60], 0x300
jmp 0x41cdaa
mov al, 0xd
mov edx, dword [ebp - 0x28]
mov dword fs:[0], edx
jmp 0x41cdb6
xor eax, eax
mov edx, dword [ebp - 0x28]
mov dword fs:[0], edx
mov esp, ebp
pop ebp
ret