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

Disassembly:
sub esp, 0xc
push ebx
mov ebx, dword [esp + 0x18]
push esi
cmp byte [ebx + 0x11], 0x6e
jne 0x40165f
push dword [esp + 0x20]
push ebx
push dword [esp + 0x20]
call fcn.00401040
mov esi, eax
add esp, 0xc
test esi, esi
jns 0x401657
lea ecx, [ebx + 0x12]
push ecx
push str.Failed_to_create_symbolic_link__s__n
call fcn.004024b0
add esp, 8
mov eax, esi
pop esi
pop ebx
add esp, 0xc
ret
push ebp
push 0x424688
push dword [esp + 0x28]
call fcn.004040c0
mov ebp, eax
add esp, 8
mov dword [esp + 0x14], ebp
test ebp, ebp
jne 0x4016a2
call fcn.004103d3
lea ecx, [ebx + 0x12]
push ecx
push str.Failed_to_extract__s:_failed_to_open_target_file__n
push dword [eax]
push str.fopen
call fcn.00402630
add esp, 0x10
or eax, 0xffffffff
pop ebp
pop esi
pop ebx
add esp, 0xc
ret
mov esi, dword [esp + 0x1c]
push edi
push 0x4245a0
push esi
call fcn.004040c0
mov edi, eax
add esp, 8
mov dword [esp + 0x14], edi
test edi, edi
jne 0x4016e6
lea eax, [ebx + 0x12]
push eax
push str.Failed_to_extract__s:_failed_to_open_archive_file__n
call fcn.004024b0
add esp, 8
or ebx, 0xffffffff
push ebp
call fcn.0040d65c
add esp, 4
mov eax, ebx
pop edi
pop ebp
pop esi
pop ebx
add esp, 0xc
ret
mov ecx, dword [ebx + 4]
xor eax, eax
add ecx, dword [esi + 0x1000]
push 0
adc eax, dword [esi + 0x1004]
push eax
push ecx
push edi
call fcn.0040dd15
add esp, 0x10
test eax, eax
jns 0x40172d
call fcn.004103d3
lea ecx, [ebx + 0x12]
push ecx
push str.Failed_to_extract__s:_failed_to_seek_to_the_entrys_data__n
push dword [eax]
push str.fseek
call fcn.00402630
add esp, 0x10
or ebx, 0xffffffff
jmp 0x4017f9
cmp byte [ebx + 0x10], 1
jne 0x401747
push 0
push ebp
push ebx
push edi
call fcn.00401230
add esp, 0x10
mov ebx, eax
jmp 0x4017f9
push 0x2000
call fcn.0041040c
add esp, 4
mov dword [esp + 0x10], eax
test eax, eax
jne 0x40177e
call fcn.004103d3
lea ecx, [ebx + 0x12]
push ecx
push str.Failed_to_extract__s:_failed_to_allocate_temporary_buffer__n
push dword [eax]
push str.malloc
call fcn.00402630
add esp, 0x10
or ebx, 0xffffffff
jmp 0x4017f9
mov esi, dword [ebx + 0xc]
xor ebp, ebp
test esi, esi
je 0x4017ea
test ebp, ebp
jb 0x40179c
ja 0x401795
cmp esi, 0x2000
jbe 0x40179c
mov edi, 0x2000
jmp 0x40179e
mov edi, esi
push dword [esp + 0x14]
push 1
push edi
push eax
call fcn.0040d91e
add esp, 0x10
cmp eax, 1
jb 0x40183f
push dword [esp + 0x18]
push 1
push edi
push dword [esp + 0x1c]
call fcn.0040df4f
add esp, 0x10
cmp eax, 1
jb 0x401815
mov eax, dword [esp + 0x10]
sub esi, edi
sbb ebp, 0
test ebp, ebp
ja 0x401795
jb 0x4017e2
test esi, esi
jne 0x401787
mov eax, dword [esp + 0x10]
mov edi, dword [esp + 0x14]
xor ebx, ebx
push eax
call fcn.004103f1
mov ebp, dword [esp + 0x1c]
add esp, 4
push edi
call fcn.0040d65c
add esp, 4
push ebp
call fcn.0040d65c
add esp, 4
mov eax, ebx
pop edi
pop ebp
pop esi
pop ebx
add esp, 0xc
ret
call fcn.004103d3
lea ecx, [ebx + 0x12]
push ecx
push str.Failed_to_extract__s:_failed_to_write_data_chunk__n
push dword [eax]
push str.fwrite
call fcn.00402630
mov eax, dword [esp + 0x20]
add esp, 0x10
mov edi, dword [esp + 0x14]
or ebx, 0xffffffff
jmp 0x4017ec
call fcn.004103d3
lea ecx, [ebx + 0x12]
push ecx
push str.Failed_to_extract__s:_failed_to_read_data_chunk__n
push dword [eax]
push str.fread
jmp 0x40182a