Function at 0x4214f0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, dword [ebp + 8]
cmp eax, dword [0x46b680]
jae 0x42151e
mov ecx, dword [ebp + 8]
sar ecx, 5
mov edx, dword [ebp + 8]
and edx, 0x1f
mov eax, dword [ecx*4 + 0x46b6a0]
movsx ecx, byte [eax + edx*8 + 4]
and ecx, 1
jne 0x42153a
mov dword [0x46b0ec], 9
mov dword [0x46b0f0], 0
or eax, 0xffffffff
jmp 0x421938
mov dword [ebp - 0x18], 0
mov edx, dword [ebp + 0xc]
mov dword [ebp - 0x1c], edx
cmp dword [ebp + 0x10], 0
je 0x42156a
mov eax, dword [ebp + 8]
sar eax, 5
mov ecx, dword [ebp + 8]
and ecx, 0x1f
mov edx, dword [eax*4 + 0x46b6a0]
movsx eax, byte [edx + ecx*8 + 4]
and eax, 2
je 0x421571
xor eax, eax
jmp 0x421938
mov ecx, dword [ebp + 8]
sar ecx, 5
mov edx, dword [ebp + 8]
and edx, 0x1f
mov eax, dword [ecx*4 + 0x46b6a0]
movsx ecx, byte [eax + edx*8 + 4]
and ecx, 0x48
je 0x4215fa
mov edx, dword [ebp + 8]
sar edx, 5
mov eax, dword [ebp + 8]
and eax, 0x1f
mov ecx, dword [edx*4 + 0x46b6a0]
movsx edx, byte [ecx + eax*8 + 5]
cmp edx, 0xa
je 0x4215fa
mov eax, dword [ebp + 8]
sar eax, 5
mov ecx, dword [ebp + 8]
and ecx, 0x1f
mov edx, dword [eax*4 + 0x46b6a0]
mov eax, dword [ebp - 0x1c]
mov cl, byte [edx + ecx*8 + 5]
mov byte [eax], cl
mov edx, dword [ebp - 0x1c]
add edx, 1
mov dword [ebp - 0x1c], edx
mov eax, dword [ebp - 0x18]
add eax, 1
mov dword [ebp - 0x18], eax
mov ecx, dword [ebp + 0x10]
sub ecx, 1
mov dword [ebp + 0x10], ecx
mov edx, dword [ebp + 8]
sar edx, 5
mov eax, dword [ebp + 8]
and eax, 0x1f
mov ecx, dword [edx*4 + 0x46b6a0]
mov byte [ecx + eax*8 + 5], 0xa
push 0
lea edx, [ebp - 0xc]
push edx
mov eax, dword [ebp + 0x10]
push eax
mov ecx, dword [ebp - 0x1c]
push ecx
mov edx, dword [ebp + 8]
sar edx, 5
mov eax, dword [ebp + 8]
and eax, 0x1f
mov ecx, dword [edx*4 + 0x46b6a0]
mov edx, dword [ecx + eax*8]
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x421673
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 5
jne 0x421652
mov dword [0x46b0ec], 9
mov eax, dword [ebp - 0x10]
mov dword [0x46b0f0], eax
or eax, 0xffffffff
jmp 0x421938
cmp dword [ebp - 0x10], 0x6d
jne 0x42165f
xor eax, eax
jmp 0x421938
mov ecx, dword [ebp - 0x10]
push ecx
call fcn.00421360
add esp, 4
or eax, 0xffffffff
jmp 0x421938
mov edx, dword [ebp - 0x18]
add edx, dword [ebp - 0xc]
mov dword [ebp - 0x18], edx
mov eax, dword [ebp + 8]
sar eax, 5
mov ecx, dword [ebp + 8]
and ecx, 0x1f
mov edx, dword [eax*4 + 0x46b6a0]
movsx eax, byte [edx + ecx*8 + 4]
and eax, 0x80
je 0x421935
cmp dword [ebp - 0xc], 0
je 0x4216e4
mov ecx, dword [ebp + 0xc]
movsx edx, byte [ecx]
cmp edx, 0xa
jne 0x4216e4
mov eax, dword [ebp + 8]
sar eax, 5
mov ecx, dword [ebp + 8]
and ecx, 0x1f
mov edx, dword [eax*4 + 0x46b6a0]
movsx eax, byte [edx + ecx*8 + 4]
or eax, 4
mov ecx, dword [ebp + 8]
sar ecx, 5
mov edx, dword [ebp + 8]
and edx, 0x1f
mov ecx, dword [ecx*4 + 0x46b6a0]
mov byte [ecx + edx*8 + 4], al
jmp 0x421716
mov edx, dword [ebp + 8]
sar edx, 5
mov eax, dword [ebp + 8]
and eax, 0x1f
mov ecx, dword [edx*4 + 0x46b6a0]
movsx edx, byte [ecx + eax*8 + 4]
and edx, 0xfffffffb
mov eax, dword [ebp + 8]
sar eax, 5
mov ecx, dword [ebp + 8]
and ecx, 0x1f
mov eax, dword [eax*4 + 0x46b6a0]
mov byte [eax + ecx*8 + 4], dl
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0x14], ecx
mov edx, dword [ebp - 0x14]
mov dword [ebp - 4], edx
mov eax, dword [ebp + 0xc]
add eax, dword [ebp - 0x18]
cmp dword [ebp - 4], eax
jae 0x42192c
mov ecx, dword [ebp - 4]
movsx edx, byte [ecx]
cmp edx, 0x1a
jne 0x421790
mov eax, dword [ebp + 8]
sar eax, 5
mov ecx, dword [ebp + 8]
and ecx, 0x1f
mov edx, dword [eax*4 + 0x46b6a0]
movsx eax, byte [edx + ecx*8 + 4]
and eax, 0x40
jne 0x42178b
mov ecx, dword [ebp + 8]
sar ecx, 5
mov edx, dword [ebp + 8]
and edx, 0x1f
mov eax, dword [ecx*4 + 0x46b6a0]
movsx ecx, byte [eax + edx*8 + 4]
or ecx, 2
mov edx, dword [ebp + 8]
sar edx, 5
mov eax, dword [ebp + 8]
and eax, 0x1f
mov edx, dword [edx*4 + 0x46b6a0]
mov byte [edx + eax*8 + 4], cl
jmp 0x42192c
mov eax, dword [ebp - 4]
movsx ecx, byte [eax]
cmp ecx, 0xd
je 0x4217bc
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 4]
mov cl, byte [eax]
mov byte [edx], cl
mov edx, dword [ebp - 0x14]
add edx, 1
mov dword [ebp - 0x14], edx
mov eax, dword [ebp - 4]
add eax, 1
mov dword [ebp - 4], eax
jmp 0x421927
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp + 0xc]
lea eax, [edx + ecx - 1]
cmp dword [ebp - 4], eax
jae 0x421812
mov ecx, dword [ebp - 4]
movsx edx, byte [ecx + 1]
cmp edx, 0xa
jne 0x4217f1
mov eax, dword [ebp - 4]
add eax, 2
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 0x14]
mov byte [ecx], 0xa
mov edx, dword [ebp - 0x14]
add edx, 1
mov dword [ebp - 0x14], edx
jmp 0x42180d
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 4]
mov dl, byte [ecx]
mov byte [eax], dl
mov eax, dword [ebp - 0x14]
add eax, 1
mov dword [ebp - 0x14], eax
mov ecx, dword [ebp - 4]
add ecx, 1
mov dword [ebp - 4], ecx
jmp 0x421927
mov edx, dword [ebp - 4]
add edx, 1
mov dword [ebp - 4], edx
mov dword [ebp - 0x10], 0
push 0
lea eax, [ebp - 0xc]
push eax
push 1
lea ecx, [ebp - 5]
push ecx
mov edx, dword [ebp + 8]
sar edx, 5
mov eax, dword [ebp + 8]
and eax, 0x1f
mov ecx, dword [edx*4 + 0x46b6a0]
mov edx, dword [ecx + eax*8]
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x421858
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
jne 0x421864
cmp dword [ebp - 0xc], 0
jne 0x421878
mov eax, dword [ebp - 0x14]
mov byte [eax], 0xd
mov ecx, dword [ebp - 0x14]
add ecx, 1
mov dword [ebp - 0x14], ecx
jmp 0x421927
mov edx, dword [ebp + 8]
sar edx, 5
mov eax, dword [ebp + 8]
and eax, 0x1f
mov ecx, dword [edx*4 + 0x46b6a0]
movsx edx, byte [ecx + eax*8 + 4]
and edx, 0x48
je 0x4218da
movsx eax, byte [ebp - 5]
cmp eax, 0xa
jne 0x4218af
mov ecx, dword [ebp - 0x14]
mov byte [ecx], 0xa
mov edx, dword [ebp - 0x14]
add edx, 1
mov dword [ebp - 0x14], edx
jmp 0x4218d8
mov eax, dword [ebp - 0x14]
mov byte [eax], 0xd
mov ecx, dword [ebp - 0x14]
add ecx, 1
mov dword [ebp - 0x14], ecx
mov edx, dword [ebp + 8]
sar edx, 5
mov eax, dword [ebp + 8]
and eax, 0x1f
mov ecx, dword [edx*4 + 0x46b6a0]
mov dl, byte [ebp - 5]
mov byte [ecx + eax*8 + 5], dl
jmp 0x421927
mov eax, dword [ebp - 0x14]
cmp eax, dword [ebp + 0xc]
jne 0x4218fc
movsx ecx, byte [ebp - 5]
cmp ecx, 0xa
jne 0x4218fc
mov edx, dword [ebp - 0x14]
mov byte [edx], 0xa
mov eax, dword [ebp - 0x14]
add eax, 1
mov dword [ebp - 0x14], eax
jmp 0x421927
push 1
push 0xffffffffffffffff
mov ecx, dword [ebp + 8]
push ecx
call fcn.0041af00
add esp, 0xc
mov dword [ebp - 0x20], eax
movsx edx, byte [ebp - 5]
cmp edx, 0xa
je 0x421927
mov eax, dword [ebp - 0x14]
mov byte [eax], 0xd
mov ecx, dword [ebp - 0x14]
add ecx, 1
mov dword [ebp - 0x14], ecx
jmp 0x421722
mov edx, dword [ebp - 0x14]
sub edx, dword [ebp + 0xc]
mov dword [ebp - 0x18], edx
mov eax, dword [ebp - 0x18]
mov esp, ebp
pop ebp
ret