Function at 0x416fb0
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov edx, dword [ebp + 0x10]
sub esp, 0x1c
push ebx
mov ebx, dword [ebp + 8]
push 0xfffffffffffffffe
pop eax
cmp ebx, eax
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x1c], edx
jne 0x416fe7
call fcn.0040bba7
and dword [eax], 0
call fcn.0040bb94
mov dword [eax], 9
or eax, 0xffffffff
jmp 0x417564
push esi
xor esi, esi
cmp ebx, esi
jl 0x416ff6
cmp ebx, dword [0x424a40]
jb 0x417015
call fcn.0040bba7
mov dword [eax], esi
call fcn.0040bb94
mov dword [eax], 9
call fcn.0040bb42
or eax, 0xffffffff
jmp 0x417563
mov eax, ebx
sar eax, 5
push edi
and ebx, 0x1f
lea edi, [eax*4 + 0x424a60]
mov eax, dword [edi]
shl ebx, 6
mov cl, byte [eax + ebx + 4]
test cl, 1
jne 0x417047
call fcn.0040bba7
mov dword [eax], esi
call fcn.0040bb94
mov dword [eax], 9
jmp 0x4170af
cmp edx, 0x7fffffff
ja 0x41709d
cmp edx, esi
mov dword [ebp - 0xc], esi
je 0x417560
test cl, 2
jne 0x417560
cmp dword [ebp + 0xc], esi
je 0x41709d
mov al, byte [eax + ebx + 0x24]
add al, al
sar al, 1
mov byte [ebp - 2], al
movsx eax, al
dec eax
push 4
pop ecx
je 0x417095
dec eax
jne 0x41708d
mov eax, edx
not eax
test al, 1
je 0x41709d
and edx, 0xfffffffe
mov dword [ebp + 0x10], edx
mov esi, dword [ebp + 0xc]
mov dword [ebp - 0x10], esi
jmp 0x41710f
mov eax, edx
not eax
test al, 1
jne 0x4170b6
call fcn.0040bba7
mov dword [eax], esi
call fcn.0040bb94
mov dword [eax], 0x16
call fcn.0040bb42
jmp 0x4170ec
mov eax, edx
shr eax, 1
mov dword [ebp + 0x10], ecx
cmp eax, ecx
jb 0x4170c4
mov dword [ebp + 0x10], eax
push dword [ebp + 0x10]
call fcn.0040d109
mov esi, eax
pop ecx
mov dword [ebp - 0x10], esi
or esi, esi
jne 0x4170f4
call fcn.0040bb94
mov dword [eax], 0xc
call fcn.0040bba7
mov dword [eax], 8
or eax, 0xffffffff
jmp 0x417562
push 1
push 0
push 0
push dword [ebp + 8]
call fcn.00413cf0
mov ecx, dword [edi]
mov dword [ebx + ecx + 0x28], eax
add esp, 0x10
mov dword [ebx + ecx + 0x2c], edx
mov eax, esi
mov ecx, dword [edi]
add ecx, ebx
test byte [ecx + 4], 0x48
je 0x417195
mov cl, byte [ecx + 5]
cmp cl, 0xa
je 0x417195
cmp dword [ebp + 0x10], 0
je 0x417195
dec dword [ebp + 0x10]
lea eax, [esi + 1]
cmp byte [ebp - 2], 0
mov byte [esi], cl
mov ecx, dword [edi]
mov dword [ebp - 0xc], 1
mov byte [ebx + ecx + 5], 0xa
je 0x417195
mov ecx, dword [edi]
mov cl, byte [ebx + ecx + 0x25]
cmp cl, 0xa
je 0x417195
cmp dword [ebp + 0x10], 0
je 0x417195
mov byte [eax], cl
mov ecx, dword [edi]
inc eax
dec dword [ebp + 0x10]
cmp byte [ebp - 2], 1
mov dword [ebp - 0xc], 2
mov byte [ebx + ecx + 0x25], 0xa
jne 0x417195
mov ecx, dword [edi]
mov cl, byte [ebx + ecx + 0x26]
cmp cl, 0xa
je 0x417195
cmp dword [ebp + 0x10], 0
je 0x417195
mov byte [eax], cl
inc eax
mov ecx, dword [edi]
dec dword [ebp + 0x10]
mov dword [ebp - 0xc], 3
mov byte [ebx + ecx + 0x26], 0xa
lea ecx, [ebp - 0x18]
push 0
push ecx
push dword [ebp + 0x10]
push eax
mov eax, dword [edi]
push dword [ebx + eax]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x41752a
mov ecx, dword [ebp - 0x18]
or ecx, ecx
js 0x41752a
cmp ecx, dword [ebp + 0x10]
ja 0x41752a
mov eax, dword [edi]
add dword [ebp - 0xc], ecx
lea eax, [ebx + eax + 4]
test byte [eax], 0x80
je 0x4173bc
cmp byte [ebp - 2], 2
je 0x4173f6
test ecx, ecx
je 0x4171f0
cmp byte [esi], 0xa
jne 0x4171f0
or byte [eax], 4
jmp 0x4171f3
and byte [eax], 0xfb
mov esi, dword [ebp - 0x10]
mov eax, dword [ebp - 0xc]
add eax, esi
mov dword [ebp + 0x10], esi
cmp esi, eax
mov dword [ebp - 0xc], eax
jae 0x4172da
mov ecx, dword [ebp + 0x10]
mov al, byte [ecx]
cmp al, 0x1a
je 0x4172c5
cmp al, 0xd
je 0x417226
mov byte [esi], al
inc esi
inc ecx
mov dword [ebp + 0x10], ecx
jmp 0x4172b7
mov eax, dword [ebp - 0xc]
dec eax
cmp ecx, eax
jae 0x417246
lea eax, [ecx + 1]
cmp byte [eax], 0xa
jne 0x417241
add ecx, 2
mov dword [ebp + 0x10], ecx
mov byte [esi], 0xa
jmp 0x4172b6
mov dword [ebp + 0x10], eax
jmp 0x4172b3
lea eax, [ebp - 0x18]
inc dword [ebp + 0x10]
push 0
push eax
push 1
lea eax, [ebp - 1]
push eax
mov eax, dword [edi]
push dword [ebx + eax]
call dword [sym.imp.KERNEL32.dll_ReadFile]
or eax, eax
jne 0x41726e
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x4172b3
cmp dword [ebp - 0x18], 0
je 0x4172b3
mov eax, dword [edi]
test byte [ebx + eax + 4], 0x48
je 0x417291
cmp byte [ebp - 1], 0xa
je 0x41723c
mov byte [esi], 0xd
mov cl, byte [ebp - 1]
mov eax, dword [edi]
mov byte [ebx + eax + 5], cl
jmp 0x4172b6
cmp esi, dword [ebp - 0x10]
jne 0x41729c
cmp byte [ebp - 1], 0xa
je 0x41723c
push 1
push 0xffffffffffffffff
push 0xffffffffffffffff
push dword [ebp + 8]
call fcn.00413cf0
sub esp, 0xfffffff0
cmp byte [ebp - 1], 0xa
je 0x4172b7
mov byte [esi], 0xd
inc esi
mov eax, dword [ebp - 0xc]
cmp dword [ebp + 0x10], eax
jb 0x417209
jmp 0x4172da
mov eax, dword [edi]
lea eax, [ebx + eax + 4]
test byte [eax], 0x40
jne 0x4172d5
or byte [eax], 2
jmp 0x4172da
mov al, byte [ecx]
mov byte [esi], al
inc esi
mov eax, esi
sub eax, dword [ebp - 0x10]
cmp byte [ebp - 2], 1
mov dword [ebp - 0xc], eax
jne 0x4173bc
or eax, eax
je 0x4173bc
dec esi
mov cl, byte [esi]
test cl, cl
js 0x417301
inc esi
jmp 0x417387
movzx ecx, cl
xor eax, eax
inc eax
jmp 0x417318
cmp eax, 4
jg 0x417321
cmp esi, dword [ebp - 0x10]
jb 0x417321
dec esi
inc eax
movzx ecx, byte [esi]
cmp byte [ecx + 0x4221f0], 0
je 0x417309
mov dl, byte [esi]
movzx ecx, dl
movsx ecx, byte [ecx + 0x4221f0]
or ecx, ecx
jne 0x41733e
call fcn.0040bb94
mov dword [eax], 0x2a
jmp 0x4173b8
inc ecx
cmp ecx, eax
jne 0x417347
add esi, eax
jmp 0x417387
mov ecx, dword [edi]
test byte [ecx + ebx + 4], 0x48
je 0x417375
inc esi
cmp eax, 2
mov byte [ecx + ebx + 5], dl
jl 0x417363
mov dl, byte [esi]
inc esi
mov ecx, dword [edi]
mov byte [ebx + ecx + 0x25], dl
cmp eax, 3
jne 0x417371
mov ecx, dword [edi]
mov dl, byte [esi]
inc esi
mov byte [ebx + ecx + 0x26], dl
sub esi, eax
jmp 0x417387
neg eax
cdq
push 1
push edx
push eax
push dword [ebp + 8]
call fcn.00413cf0
add esp, 0x10
mov eax, dword [ebp - 0x1c]
sub esi, dword [ebp - 0x10]
shr eax, 1
push eax
push dword [ebp + 0xc]
push esi
push dword [ebp - 0x10]
push 0
push 0xfde9
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
test eax, eax
mov dword [ebp - 0xc], eax
jne 0x4173df
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.0040bbba
pop ecx
or dword [ebp - 0x14], 0xffffffff
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp + 0xc]
je 0x4173cb
push eax
call fcn.00409842
pop ecx
mov eax, dword [ebp - 0x14]
cmp eax, 0xfffffffe
jne 0x417562
mov eax, dword [ebp - 0xc]
jmp 0x417562
xor ecx, ecx
mov edx, dword [edi]
mov edi, dword [ebp - 0xc]
cmp edi, esi
setne cl
add edi, edi
mov dword [ebp - 0xc], edi
mov dword [ebx + edx + 0x30], ecx
jmp 0x4173bc
test ecx, ecx
je 0x417405
cmp word [esi], 0xa
jne 0x417405
or byte [eax], 4
jmp 0x417408
and byte [eax], 0xfb
mov eax, dword [ebp - 0xc]
mov esi, dword [ebp - 0x10]
add eax, esi
cmp esi, eax
mov dword [ebp + 0x10], esi
mov dword [ebp - 0xc], eax
jae 0x41751f
mov eax, dword [ebp + 0x10]
movzx ecx, word [eax]
cmp ecx, 0x1a
je 0x417506
cmp ecx, 0xd
je 0x417443
mov word [esi], cx
sub esi, 0xfffffffe
add eax, 2
mov dword [ebp + 0x10], eax
jmp 0x4174f8
mov ecx, dword [ebp - 0xc]
add ecx, 0xfffffffe
cmp eax, ecx
jae 0x41746b
lea ecx, [eax + 2]
cmp word [ecx], 0xa
jne 0x417463
sub eax, 0xfffffffc
mov dword [ebp + 0x10], eax
push 0xa
jmp 0x4174f1
mov dword [ebp + 0x10], ecx
jmp 0x4174ef
lea eax, [ebp - 0x18]
sub dword [ebp + 0x10], 0xfffffffe
push 0
push eax
push 2
lea eax, [ebp - 8]
push eax
mov eax, dword [edi]
push dword [ebx + eax]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x417494
call dword [sym.imp.KERNEL32.dll_GetLastError]
or eax, eax
jne 0x4174ef
cmp dword [ebp - 0x18], 0
je 0x4174ef
mov eax, dword [edi]
test byte [ebx + eax + 4], 0x48
je 0x4174cb
cmp word [ebp - 8], 0xa
je 0x41745c
push 0xd
pop eax
mov word [esi], ax
mov eax, dword [edi]
mov cl, byte [ebp - 8]
mov byte [ebx + eax + 5], cl
mov eax, dword [edi]
mov cl, byte [ebp - 7]
mov byte [ebx + eax + 0x25], cl
mov eax, dword [edi]
mov byte [ebx + eax + 0x26], 0xa
jmp 0x4174f5
cmp esi, dword [ebp - 0x10]
jne 0x4174d7
cmp word [ebp - 8], 0xa
je 0x41745c
push 1
push 0xffffffffffffffff
push 0xfffffffffffffffe
push dword [ebp + 8]
call fcn.00413cf0
sub esp, 0xfffffff0
cmp word [ebp - 8], 0xa
je 0x4174f8
push 0xd
pop eax
mov word [esi], ax
add esi, 2
mov eax, dword [ebp - 0xc]
cmp dword [ebp + 0x10], eax
jb 0x41741e
jmp 0x41751f
mov ecx, dword [edi]
lea ebx, [ebx + ecx + 4]
test byte [ebx], 0x40
jne 0x417516
or byte [ebx], 2
jmp 0x41751f
mov ax, word [eax]
mov word [esi], ax
sub esi, 0xfffffffe
sub esi, dword [ebp - 0x10]
mov dword [ebp - 0xc], esi
jmp 0x4173bc
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 5
pop edi
cmp eax, edi
jne 0x41754e
call fcn.0040bb94
mov dword [eax], 9
call fcn.0040bba7
mov dword [eax], edi
jmp 0x4173b8
cmp eax, 0x6d
jne 0x4173b1
and dword [ebp - 0x14], 0
jmp 0x4173bc
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret