Function at 0x4677e0
Capabilities:
Read file on windows

Disassembly:
sub esp, 8
mov edx, dword [esp + 0x10]
push ebx
xor ebx, ebx
push ebp
push esi
cmp edx, ebx
push edi
mov dword [esp + 0x14], ebx
jne 0x4677ff
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 8
ret
mov eax, dword [esp + 0x24]
cmp eax, 6
ja case.0x467810.4
mov edi, dword [esp + 0x1c]
jmp dword [eax*4 + 0x467cd8]
mov edi, dword [esp + 0x1c]
mov eax, edx
cmp edx, ebx
mov dword [esp + 0x10], eax
mov ebp, 0x10000
jle 0x467934
jmp 0x467834
mov eax, dword [esp + 0x10]
test ebp, ebp
jle 0x467934
mov esi, dword [edi + 0xc9c8]
cmp eax, 0x10000
mov ebx, esi
jle 0x467850
mov eax, 0x10000
push eax
push esi
push edi
call fcn.00467010
mov ebp, eax
add esp, 0xc
test ebp, ebp
je 0x467c5d
mov eax, dword [edi + 0xc9c8]
mov edx, dword [esp + 0x10]
sub edx, ebp
mov byte [eax + ebp], 0
mov al, byte [esi]
test al, al
mov dword [esp + 0x10], edx
je 0x467898
cmp al, 0xd
jne 0x46788b
mov al, byte [esi + 1]
inc esi
cmp al, 0xd
je 0x467883
mov cl, byte [esi]
mov byte [ebx], cl
mov al, byte [esi + 1]
inc ebx
inc esi
test al, al
jne 0x46787f
mov eax, dword [esp + 0x24]
mov byte [ebx], 0
cmp eax, 5
jne 0x4678e2
mov eax, dword [edi + 0x8d4]
mov ecx, dword [eax + 0x14]
test ecx, ecx
jne 0x4678c4
test byte [eax + 0x1c], 0x40
je 0x4678d4
mov edx, dword [eax + 0x10]
cmp edx, 0x19
jl 0x4678d4
cmp edx, 0x1a
jg 0x4678d4
cmp ecx, 6
je 0x4678d4
cmp ecx, 0xb
jne 0x4678e2
cmp dword [eax + 0x10], 0x32
jne 0x4678e2
mov eax, dword [edi + 0xc9c8]
push eax
push eax
call dword [sym.imp.USER32.dll_OemToCharA]
mov eax, dword [edi + 0xcb28]
test eax, eax
je 0x4678fc
mov eax, dword [eax + 4]
test eax, eax
je 0x4678fc
mov edx, dword [edi + 0xc9c8]
push edx
call eax
mov eax, dword [edi + 0xc9c8]
mov ecx, dword [esp + 0x20]
push eax
push ecx
push 0x497db0
push edi
call fcn.00465750
push 0x497be4
push 2
push 0x497db0
push edi
call fcn.00465750
mov eax, dword [esp + 0x30]
add esp, 0x20
test eax, eax
jg 0x467830
push 0x40
lea edx, [edi + 0x8d8]
push 0
push edx
push edi
call dword [edi + 0xcb14]
mov eax, dword [esp + 0x14]
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
cmp edx, 0x104
mov dword [esp + 0x1c], ebx
jb 0x467980
add edx, 0xfffffefd
mov dword [esp + 0x20], 0x103
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 0x20]
mov ebx, dword [esp + 0x1c]
mov dword [esp + 0x14], 1
lea esi, [edi + 0xc9dc]
push edx
push esi
push edi
call fcn.00467010
add esp, 0xc
test eax, eax
jne 0x4679a2
pop edi
pop esi
pop ebp
mov eax, 0x33
pop ebx
add esp, 8
ret
mov eax, dword [esp + 0x20]
mov byte [edi + eax + 0xc9dc], 0
mov eax, dword [edi + 0x8d4]
mov ecx, dword [eax + 0x14]
test ecx, ecx
jne 0x4679d5
cmp dword [esp + 0x24], 6
je 0x4679c8
test byte [eax + 0x1c], 0x40
je 0x4679e5
mov edx, dword [eax + 0x10]
cmp edx, 0x19
jl 0x4679e5
cmp edx, 0x1a
jg 0x4679e5
cmp ecx, 6
je 0x4679e5
cmp ecx, 0xb
jne 0x4679ed
cmp dword [eax + 0x10], 0x32
jne 0x4679ed
push esi
push esi
call dword [sym.imp.USER32.dll_OemToCharA]
mov ecx, dword [edi + 0x8d4]
test byte [ecx + 0x1c], 0x10
je 0x467a88
mov ebp, esi
mov dword [esp + 0x24], esi
mov bl, byte [ebp]
test bl, bl
je 0x467a81
mov edx, dword [0x49821c]
push edx
push ebp
call fcn.0047281c
add esp, 8
cmp eax, 1
jbe 0x467a37
mov ecx, eax
dec eax
test ecx, ecx
je 0x467a7a
inc eax
mov dl, byte [ebp]
mov byte [esi], dl
inc esi
inc ebp
dec eax
jne 0x467a27
mov dword [esp + 0x24], esi
jmp 0x467a7a
cmp dword [0x49821c], 1
movsx esi, bl
jle 0x467a50
push 1
push esi
call fcn.0047229e
add esp, 8
jmp 0x467a5b
mov eax, dword [str.________________________________H]
mov al, byte [eax + esi*2]
and eax, 1
test eax, eax
je 0x467a6a
push esi
call fcn.004726e2
add esp, 4
jmp 0x467a6c
mov eax, esi
mov ecx, dword [esp + 0x24]
mov byte [ecx], al
inc ecx
mov dword [esp + 0x24], ecx
inc ebp
mov esi, ecx
mov bl, byte [ebp]
test bl, bl
jne 0x467a0a
mov ebx, dword [esp + 0x1c]
mov byte [esi], 0
mov ecx, dword [edi + 0x8d4]
test byte [ecx + 0x1c], 0x20
je 0x467abf
cmp dword [esp + 0x20], 8
jbe 0x467abf
mov cl, byte [edi + 0xc9e4]
lea eax, [edi + 0xc9e4]
cmp cl, 0x2e
jne 0x467abf
mov dl, byte [eax]
inc eax
test dl, dl
je 0x467abf
mov cl, byte [eax]
mov byte [eax - 1], cl
mov dl, cl
inc eax
test dl, dl
jne 0x467ab3
test bx, bx
je case.0x467810.4
and ebx, 0xffff
mov dword [esp + 0x20], ebx
mov edx, ebx
mov ecx, dword [edi + 0xc8e4]
mov ebx, dword [edi + 0xc8e0]
mov ebp, dword [edi + 0xc90c]
mov eax, ecx
sub eax, ebx
add eax, ebp
add eax, edx
mov esi, eax
and esi, 0x80001fff
jns 0x467b00
dec esi
or esi, 0xffffe000
inc esi
mov edx, eax
sub edx, esi
test eax, eax
jge 0x467b15
pop edi
pop esi
pop ebp
mov eax, 3
pop ebx
add esp, 8
ret
cmp edx, ebp
je 0x467b82
mov eax, dword [edi + 0xc904]
push 0
push edx
push eax
call fcn.0047960b
mov ecx, dword [edi + 0xc8e0]
mov edx, dword [edi + 0xc904]
push 0x2000
push ecx
push edx
mov dword [edi + 0xc90c], eax
call fcn.0047abb6
add esp, 0x18
mov dword [edi + 0xc8e8], eax
test eax, eax
jg 0x467b60
pop edi
pop esi
pop ebp
mov eax, 0x33
pop ebx
add esp, 8
ret
mov ecx, dword [edi + 0xc8e0]
add ecx, esi
sub eax, esi
mov dword [edi + 0xc8e4], ecx
mov dword [edi + 0xc8e8], eax
mov eax, dword [esp + 0x14]
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov eax, dword [edi + 0xc8e8]
sub ecx, ebx
sub ecx, esi
add eax, ecx
add ebx, esi
mov dword [edi + 0xc8e8], eax
mov eax, dword [esp + 0x14]
mov dword [edi + 0xc8e4], ebx
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov esi, dword [esp + 0x1c]
mov eax, dword [esi + 0xc914]
cmp eax, ebx
je 0x467bc3
push eax
call fcn.0046fd2e
mov edx, dword [esp + 0x24]
add esp, 4
push edx
call fcn.0046fea8
add esp, 4
mov dword [esi + 0xc914], eax
test eax, eax
jne 0x467cb2
mov ecx, dword [esi + 0xc8e4]
mov ebx, dword [esi + 0xc8e0]
mov ebp, dword [esi + 0xc90c]
mov edx, dword [esp + 0x20]
mov eax, ecx
sub eax, ebx
add eax, ebp
add eax, edx
mov edi, eax
and edi, 0x80001fff
jns 0x467c0a
dec edi
or edi, 0xffffe000
inc edi
mov edx, eax
sub edx, edi
test eax, eax
jge 0x467c1f
pop edi
pop esi
pop ebp
mov eax, 3
pop ebx
add esp, 8
ret
cmp edx, ebp
je 0x467c8c
push 0
push edx
mov edx, dword [esi + 0xc904]
push edx
call fcn.0047960b
mov ecx, dword [esi + 0xc904]
mov dword [esi + 0xc90c], eax
mov eax, dword [esi + 0xc8e0]
push 0x2000
push eax
push ecx
call fcn.0047abb6
add esp, 0x18
mov dword [esi + 0xc8e8], eax
test eax, eax
jg 0x467c6a
pop edi
pop esi
pop ebp
mov eax, 0x33
pop ebx
add esp, 8
ret
mov edx, dword [esi + 0xc8e0]
add edx, edi
sub eax, edi
mov dword [esi + 0xc8e4], edx
mov dword [esi + 0xc8e8], eax
mov eax, dword [esp + 0x14]
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov eax, dword [esi + 0xc8e8]
sub ecx, ebx
sub ecx, edi
add eax, ecx
add ebx, edi
mov dword [esi + 0xc8e8], eax
mov eax, dword [esp + 0x14]
mov dword [esi + 0xc8e4], ebx
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov ecx, dword [esp + 0x20]
push ecx
push eax
push esi
call fcn.00467010
add esp, 0xc
test eax, eax
mov eax, 0x33
je 0x467cce
mov eax, dword [esp + 0x14]
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret