Function at 0x4c8620
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff0
sub esp, 0x90
mov esi, dword [ebp + 0xc]
mov eax, dword [esi + 0xc]
cmp dword [esi + 8], 0
mov dword [esi + 8], 0
je 0x4c8648
push eax
call sub.kernel32.dll_CloseHandle
mov edx, dword [esi + 0x14]
mov eax, dword [esi + 0x18]
cmp dword [esi + 0x10], 0
mov dword [esi + 0x10], 0
xorps xmm0, xmm0
mov dword [esp + 0x48], 1
mov dword [esp + 0x54], 1
mov ecx, dword [esi + 0x1c]
movlps qword [esp + 0x4c], xmm0
movlps qword [esp + 0x58], xmm0
mov dword [esi + 0x18], 0
mov dword [esp + 8], ecx
je 0x4c86c9
test eax, eax
je 0x4c88ca
lea eax, [esp + 0x48]
lea ecx, [esp + 0x20]
push eax
call fcn.004d1b10
add esp, 4
mov eax, dword [esp + 0x30]
mov ebx, dword [esp + 0x20]
mov esi, dword [esp + 0x24]
cmp eax, 3
jne 0x4c8b13
mov eax, ebx
shr eax, 0x10
mov edi, eax
push dword [esp + 8]
call sub.kernel32.dll_CloseHandle
jmp 0x4c8de3
test eax, eax
je 0x4c8dec
xor esi, esi
xor ecx, ecx
mov dword [esp + 0x1c], 1
mov dword [esp + 0xc], 0
jmp 0x4c870e
call sub.kernel32.dll_GetLastError
mov ebx, eax
push ebx
call fcn.004d6220
add esp, 4
mov esi, dword [esp + 0x44]
cmp al, 0x23
mov ecx, edi
jne 0x4c8ac6
cmp ecx, esi
jne 0x4c8730
mov edx, esi
lea ecx, [esp + 0x54]
push 0x20
call fcn.004b2460
add esp, 4
mov ecx, dword [esp + 0x5c]
mov eax, dword [esp + 0x54]
mov esi, dword [esp + 0x58]
jmp 0x4c8734
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x44], esi
sub esi, ecx
mov dword [esp + 0x1c], eax
lea ebx, [eax + ecx]
mov eax, esi
sub eax, dword [esp + 0xc]
jb 0x4c8f32
mov edi, ecx
je 0x4c8763
mov ecx, dword [esp + 0xc]
add ecx, ebx
push eax
push 0
push ecx
call sub.msvcrt.dll_memset
add esp, 0xc
xorps xmm0, xmm0
lea eax, [esp + 0x60]
mov dword [esp + 0x60], 0
movaps xmmword [esp + 0x20], xmm0
mov dword [esp + 0x30], eax
push 0x4d1af0
lea eax, [esp + 0x24]
push eax
push esi
push ebx
push dword [esp + 0x18]
call sub.kernel32.dll_ReadFileEx
test eax, eax
je 0x4c86f0
nop dword [eax + eax]
push 1
push 0xffffffffffffffff
call sub.kernel32.dll_SleepEx
cmp dword [esp + 0x60], 1
jne 0x4c87a0
mov ebx, dword [esp + 0x64]
test ebx, ebx
jne 0x4c86f7
mov eax, dword [esp + 0x68]
cmp esi, eax
mov ecx, eax
cmova ecx, esi
test eax, eax
mov dword [esp + 0xc], ecx
je 0x4c8ad2
cmp esi, eax
jb 0x4c8f93
mov esi, dword [esp + 0x44]
mov ecx, edi
sub dword [esp + 0xc], eax
add ecx, eax
mov dword [esp + 0x5c], ecx
mov eax, esi
or eax, ecx
jne 0x4c870e
xorps xmm0, xmm0
lea esi, [esp + 0x10]
movaps xmmword [esp + 0x30], xmm0
movaps xmmword [esp + 0x20], xmm0
jmp 0x4c8828
call sub.kernel32.dll_GetLastError
mov ebx, eax
push ebx
call fcn.004d6220
add esp, 4
cmp al, 0x23
jne 0x4c8ac6
xorps xmm0, xmm0
mov dword [esp + 0x10], 0
movaps xmmword [esp + 0x60], xmm0
mov dword [esp + 0x70], esi
push 0x4d1af0
lea eax, [esp + 0x64]
push eax
push 0x20
lea eax, [esp + 0x2c]
push eax
push dword [esp + 0x18]
call sub.kernel32.dll_ReadFileEx
test eax, eax
je 0x4c8810
nop word [eax + eax]
push 1
push 0xffffffffffffffff
call sub.kernel32.dll_SleepEx
cmp dword [esp + 0x10], 1
jne 0x4c8860
mov ebx, dword [esp + 0x14]
test ebx, ebx
jne 0x4c8817
mov ebx, dword [esp + 0x18]
test ebx, ebx
je 0x4c8ad2
cmp ebx, 0x21
jae 0x4c8fa8
xor edx, edx
lea ecx, [esp + 0x54]
push ebx
call fcn.004b2460
add esp, 4
mov eax, dword [esp + 0x54]
mov esi, dword [esp + 0x58]
mov edi, dword [esp + 0x5c]
mov dword [esp + 0x1c], eax
add eax, edi
push ebx
lea ecx, [esp + 0x24]
push ecx
push eax
call sub.msvcrt.dll_memcpy
mov ecx, edi
add esp, 0xc
add ecx, ebx
mov dword [esp + 0x5c], ecx
jmp 0x4c870e
xor esi, esi
xor ecx, ecx
mov dword [esp + 8], edx
mov dword [esp + 0x1c], 1
mov dword [esp + 0xc], 0
jmp 0x4c890e
call sub.kernel32.dll_GetLastError
mov edi, eax
push edi
call fcn.004d6220
add esp, 4
mov esi, dword [esp + 0x44]
cmp al, 0x23
mov ecx, ebx
jne 0x4c8adb
cmp ecx, esi
jne 0x4c8930
mov edx, esi
lea ecx, [esp + 0x48]
push 0x20
call fcn.004b2460
add esp, 4
mov ecx, dword [esp + 0x50]
mov eax, dword [esp + 0x48]
mov esi, dword [esp + 0x4c]
jmp 0x4c8934
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x44], esi
sub esi, ecx
mov dword [esp + 0x1c], eax
lea edi, [eax + ecx]
mov eax, esi
sub eax, dword [esp + 0xc]
jb 0x4c8f1e
mov ebx, ecx
je 0x4c8963
mov ecx, dword [esp + 0xc]
add ecx, edi
push eax
push 0
push ecx
call sub.msvcrt.dll_memset
add esp, 0xc
xorps xmm0, xmm0
lea eax, [esp + 0x60]
mov dword [esp + 0x60], 0
movaps xmmword [esp + 0x20], xmm0
mov dword [esp + 0x30], eax
push 0x4d1af0
lea eax, [esp + 0x24]
push eax
push esi
push edi
push dword [esp + 0x18]
call sub.kernel32.dll_ReadFileEx
test eax, eax
je 0x4c88f0
nop dword [eax + eax]
push 1
push 0xffffffffffffffff
call sub.kernel32.dll_SleepEx
cmp dword [esp + 0x60], 1
jne 0x4c89a0
mov edi, dword [esp + 0x64]
test edi, edi
jne 0x4c88f7
mov eax, dword [esp + 0x68]
cmp esi, eax
mov ecx, eax
cmova ecx, esi
test eax, eax
mov dword [esp + 0xc], ecx
je 0x4c8ae7
cmp esi, eax
jb 0x4c8f7e
mov esi, dword [esp + 0x44]
mov ecx, ebx
sub dword [esp + 0xc], eax
add ecx, eax
mov dword [esp + 0x50], ecx
mov eax, esi
or eax, ecx
jne 0x4c890e
mov esi, dword [esp + 8]
xorps xmm0, xmm0
lea ebx, [esp + 0x10]
movaps xmmword [esp + 0x30], xmm0
movaps xmmword [esp + 0x20], xmm0
jmp 0x4c8a28
call sub.kernel32.dll_GetLastError
mov edi, eax
push edi
call fcn.004d6220
add esp, 4
cmp al, 0x23
jne 0x4c8d87
xorps xmm0, xmm0
mov dword [esp + 0x10], 0
movaps xmmword [esp + 0x60], xmm0
mov dword [esp + 0x70], ebx
push 0x4d1af0
lea eax, [esp + 0x64]
push eax
push 0x20
lea eax, [esp + 0x2c]
push eax
push esi
call sub.kernel32.dll_ReadFileEx
test eax, eax
je 0x4c8a10
nop word [eax + eax]
push 1
push 0xffffffffffffffff
call sub.kernel32.dll_SleepEx
cmp dword [esp + 0x10], 1
jne 0x4c8a60
mov edi, dword [esp + 0x14]
test edi, edi
jne 0x4c8a17
mov edi, dword [esp + 0x18]
test edi, edi
je 0x4c8ad6
cmp edi, 0x21
jae 0x4c8fb8
xor edx, edx
lea ecx, [esp + 0x48]
push edi
call fcn.004b2460
add esp, 4
mov eax, dword [esp + 0x48]
mov esi, dword [esp + 0x4c]
mov ebx, dword [esp + 0x50]
mov dword [esp + 0x1c], eax
add eax, ebx
push edi
lea ecx, [esp + 0x24]
push ecx
push eax
call sub.msvcrt.dll_memcpy
mov ecx, ebx
add esp, 0xc
add ecx, edi
mov dword [esp + 0x50], ecx
jmp 0x4c890e
movzx eax, al
cmp eax, 0xb
jne 0x4c8eef
mov esi, dword [esp + 8]
mov ebx, dword [ebp + 0xc]
jmp 0x4c8aee
movzx eax, al
cmp eax, 0xb
jne 0x4c8d93
mov ebx, dword [ebp + 0xc]
mov esi, dword [esp + 8]
push esi
call sub.kernel32.dll_CloseHandle
mov eax, dword [ebx + 0xc]
cmp dword [ebx + 8], 0
mov dword [ebx + 8], 0
je 0x4c8df6
push eax
call sub.kernel32.dll_CloseHandle
jmp 0x4c8df6
mov ecx, dword [esp + 0x2c]
mov dword [esp + 0x60], ebx
mov dword [esp + 0x64], esi
mov dword [esp + 0x6c], ecx
mov ecx, dword [esp + 0x28]
mov dword [esp + 0x68], ecx
mov dword [esp + 0x70], eax
mov eax, dword [esp + 0x34]
mov dword [esp + 0x74], eax
mov edx, dword [esp + 8]
lea eax, [esp + 0x54]
lea ecx, [esp + 0x20]
push eax
call fcn.004d1b10
add esp, 4
mov eax, dword [esp + 0x30]
mov ebx, dword [esp + 0x20]
mov esi, dword [esp + 0x24]
cmp eax, 3
jne 0x4c8b69
mov eax, ebx
shr eax, 0x10
mov edi, eax
jmp 0x4c8dda
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x2c]
mov edi, dword [esp + 0x34]
mov dword [esp + 0x20], ebx
mov dword [esp + 0x24], esi
mov dword [esp + 0x28], ecx
mov ecx, dword [esp + 0x64]
mov dword [esp + 0x2c], edx
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], edi
lea edi, [esp + 0x60]
mov dword [esp + 0x84], ecx
mov dword [esp + 0x88], esi
lea esi, [esp + 0x10]
nop word [eax + eax]
push 0xffffffffffffffff
push 0
lea eax, [esp + 0x8c]
push eax
push 2
call sub.kernel32.dll_WaitForMultipleObjects
cmp eax, 1
je 0x4c8c10
test eax, eax
jne 0x4c8dc2
mov eax, dword [esp + 0x70]
test eax, eax
je 0x4c8cd5
cmp eax, 1
jne 0x4c8c47
mov eax, dword [esp + 0x60]
mov ecx, dword [esp + 0x68]
mov dword [esp + 0x10], 0
push 1
push esi
push ecx
push eax
call sub.kernel32.dll_GetOverlappedResult
test eax, eax
je 0x4c8ca7
mov ebx, dword [esp + 0x10]
jmp 0x4c8cbe
mov eax, dword [esp + 0x30]
test eax, eax
je 0x4c8c7f
cmp eax, 1
jne 0x4c8c41
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x28]
mov dword [esp + 0x10], 0
push 1
push esi
push ecx
push eax
call sub.kernel32.dll_GetOverlappedResult
test eax, eax
je 0x4c8c4d
mov ebx, dword [esp + 0x10]
jmp 0x4c8c64
mov ebx, dword [esp + 0x34]
jmp 0x4c8c68
mov ebx, dword [esp + 0x74]
jmp 0x4c8cc2
xor ebx, ebx
call sub.kernel32.dll_GetLastError
cmp eax, 0x26
je 0x4c8c64
mov esi, eax
cmp eax, 0x6d
jne 0x4c8ee4
lea esi, [esp + 0x10]
mov dword [esp + 0x30], 0
mov eax, dword [esp + 0x2c]
add dword [eax + 8], ebx
test ebx, ebx
je 0x4c8d00
mov ecx, esi
lea edx, [esp + 0x20]
call fcn.004d1be0
movzx ebx, byte [esp + 0x10]
mov bh, byte [esp + 0x11]
cmp bl, 4
jne 0x4c8d7c
cmp bh, 1
je 0x4c8bb0
jmp 0x4c8d00
xor ebx, ebx
call sub.kernel32.dll_GetLastError
cmp eax, 0x26
je 0x4c8cbe
mov esi, eax
cmp eax, 0x6d
jne 0x4c8ee4
lea esi, [esp + 0x10]
mov dword [esp + 0x70], 0
mov eax, dword [esp + 0x6c]
add dword [eax + 8], ebx
test ebx, ebx
je 0x4c8cf9
mov ecx, esi
mov edx, edi
call fcn.004d1be0
movzx ebx, byte [esp + 0x10]
mov bh, byte [esp + 0x11]
cmp bl, 4
jne 0x4c8d7c
cmp bh, 1
je 0x4c8bb0
lea edi, [esp + 0x20]
nop dword [eax]
mov eax, dword [edi + 0x10]
test eax, eax
je 0x4c8d5d
cmp eax, 1
jne 0x4c8d2c
mov eax, dword [edi + 8]
mov dword [esp + 0x10], 0
push 1
push esi
push eax
push dword [edi]
call sub.kernel32.dll_GetOverlappedResult
test eax, eax
je 0x4c8d31
mov ebx, dword [esp + 0x10]
jmp 0x4c8d48
mov ebx, dword [edi + 0x14]
jmp 0x4c8d4c
xor ebx, ebx
call sub.kernel32.dll_GetLastError
cmp eax, 0x26
je 0x4c8d48
mov esi, eax
cmp eax, 0x6d
jne 0x4c8ee4
lea esi, [esp + 0x10]
mov dword [edi + 0x10], 0
mov eax, dword [edi + 0xc]
add dword [eax + 8], ebx
test ebx, ebx
je 0x4c8d78
mov ecx, esi
mov edx, edi
call fcn.004d1be0
movzx ebx, byte [esp + 0x10]
mov bh, byte [esp + 0x11]
cmp bl, 4
jne 0x4c8d7c
test bh, bh
jne 0x4c8d00
mov bl, 4
jmp 0x4c8dd1
movzx edi, word [esp + 0x12]
mov esi, dword [esp + 0x14]
jmp 0x4c8dd1
movzx eax, al
cmp eax, 0xb
je 0x4c8ad6
mov dword [esp + 0x24], edi
mov dword [esp + 0x20], 0
push 0x567ed0
push 0x5669fc
lea eax, [esp + 0x28]
push eax
push 0x2b
push 0x566a0c
call fcn.00414e90
add esp, 0x14
jmp 0x4c8fa6
call sub.kernel32.dll_GetLastError
mov esi, eax
xor ebx, ebx
xor edi, edi
xor eax, eax
mov bh, al
lea ecx, [esp + 0x20]
call fcn.004ac360
lea ecx, [esp + 0x60]
call fcn.004ac360
cmp bl, 4
jne 0x4c8f46
mov ebx, dword [ebp + 0xc]
mov dword [ebx + 8], 0
mov esi, dword [ebp + 8]
mov edi, dword [ebx]
push 0xffffffffffffffff
push edi
call sub.kernel32.dll_WaitForSingleObject
test eax, eax
je 0x4c8e6a
call sub.kernel32.dll_GetLastError
cmp dword [esp + 0x58], 0
mov byte [esi + 8], 0
mov byte [esi + 0xb], 0
mov word [esi + 9], 0
mov dword [esi + 0xc], eax
mov dword [esi + 4], 0
je 0x4c8e3c
push dword [esp + 0x54]
push 0
push dword [0x5880e0]
call sub.kernel32.dll_HeapFree
cmp dword [esp + 0x4c], 0
je 0x4c8e54
push dword [esp + 0x48]
push 0
push dword [0x5880e0]
call sub.kernel32.dll_HeapFree
push edi
call sub.kernel32.dll_CloseHandle
push dword [ebx + 4]
call sub.kernel32.dll_CloseHandle
cmp dword [ebx + 0x10], 0
je 0x4c8ec7
jmp 0x4c8ebf
mov dword [esp + 0x20], 0
lea eax, [esp + 0x20]
push eax
push edi
call sub.kernel32.dll_GetExitCodeProcess
test eax, eax
je 0x4c8edf
movsd xmm0, qword [esp + 0x48]
mov ecx, dword [esp + 0x50]
mov eax, dword [esp + 0x20]
mov edx, dword [esp + 0x5c]
movsd qword [esi + 4], xmm0
movsd xmm0, qword [esp + 0x54]
mov dword [esi + 0xc], ecx
mov dword [esi + 0x18], edx
movsd qword [esi + 0x10], xmm0
mov dword [esi], eax
push edi
call sub.kernel32.dll_CloseHandle
push dword [ebx + 4]
call sub.kernel32.dll_CloseHandle
cmp dword [ebx + 0x10], 0
je 0x4c8ec7
push dword [ebx + 0x14]
call sub.kernel32.dll_CloseHandle
cmp dword [ebx + 0x18], 0
je 0x4c8ed5
push dword [ebx + 0x1c]
call sub.kernel32.dll_CloseHandle
mov eax, esi
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
jmp 0x4c8e07
xor eax, eax
xor ebx, ebx
xor edi, edi
jmp 0x4c8dcf
mov dword [esp + 0x24], ebx
mov dword [esp + 0x20], 0
push 0x567ee0
push 0x5669fc
lea eax, [esp + 0x28]
push eax
push 0x2b
push 0x566a0c
call fcn.00414e90
add esp, 0x14
jmp 0x4c8fa6
push 0x567bf4
push esi
push dword [esp + 0x14]
call fcn.00417ea0
add esp, 0xc
jmp 0x4c8fa6
push 0x567bf4
push esi
push dword [esp + 0x14]
call fcn.00417ea0
add esp, 0xc
jmp 0x4c8fa6
movzx eax, bh
shl edi, 0x10
movzx ecx, bl
mov dword [esp + 0x24], esi
shl eax, 8
or eax, edi
or ecx, eax
mov dword [esp + 0x20], ecx
push 0x567ec0
push 0x5669fc
lea eax, [esp + 0x28]
push eax
push 0x2b
push 0x566a0c
call fcn.00414e90
add esp, 0x14
jmp 0x4c8fa6
mov eax, 0x567be4
push eax
push esi
push dword [esp + 0x14]
call fcn.00417f20
add esp, 0xc
jmp 0x4c8fa6
mov eax, 0x567be4
push eax
push esi
push dword [esp + 0x14]
call fcn.00417f20
add esp, 0xc
ud2
mov eax, 0x567cc0
mov esi, 0x20
mov dword [esp + 0xc], ebx
jmp 0x4c8f98
mov eax, 0x567cc0
mov esi, 0x20
mov dword [esp + 0xc], edi
jmp 0x4c8f83