Function at 0x413490
Capabilities:
Check if file exists
Read file on windows

Disassembly:
push 0xffffffffffffffff
push 0x43eef1
mov eax, dword fs:[0]
push eax
mov eax, 0x8124
call fcn.00427790
mov eax, dword [0x44fb64]
xor eax, esp
mov dword [esp + 0x8120], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x44fb64]
xor eax, esp
push eax
lea eax, [esp + 0x8138]
mov dword fs:[0], eax
mov eax, dword [esp + 0x8148]
mov esi, ecx
xor edi, edi
mov dword [esp + 0x2c], esi
mov dword [esp + 0x24], eax
mov dword [esp + 0x20], edi
call fcn.00413be1
xor ecx, ecx
cmp eax, edi
setne cl
cmp ecx, edi
jne 0x413500
push 0x80004005
call fcn.0040a000
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x14], eax
mov dword [esp + 0x8140], edi
call fcn.00413be1
xor ecx, ecx
cmp eax, edi
setne cl
cmp ecx, edi
jne 0x413531
push 0x80004005
call fcn.0040a000
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x1c], eax
mov byte [esp + 0x8140], 1
call fcn.00413be1
xor ecx, ecx
cmp eax, edi
setne cl
cmp ecx, edi
jne 0x413563
push 0x80004005
call fcn.0040a000
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esp + 0x28], eax
push 0x103
lea ecx, [esp + 0x35]
mov byte [esp + 0x8144], 2
push edi
push ecx
mov dword [esp + 0x24], edi
mov byte [esp + 0x3c], 0
call fcn.004253a0
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
add esp, 0xc
lea ecx, [ecx]
push 0x447ae8
push esi
call fcn.004228cf
mov ebp, eax
add esp, 8
test ebp, ebp
jne 0x413896
call ebx
mov esi, eax
inc edi
cmp esi, 2
je 0x4135d8
cmp edi, 0x12c
jg 0x4135d8
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
mov esi, dword [esp + 0x2c]
jmp 0x4135a0
mov ebx, dword [esp + 0x2c]
push esi
push ebx
lea edx, [esp + 0x1c]
push str.CompressFile_SrcFile__s__Fail__d_
push edx
call fcn.00409910
mov eax, dword [esp + 0x24]
add esp, 0x10
push 0
push eax
push 0x453d11
call fcn.0040d890
push 0
push 0
lea ecx, [esp + 0x20]
push ecx
push 0x400
push esi
push 0
push 0x1100
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
push str.LdWaterMarkHook
push ebx
call fcn.00423370
add esp, 8
test eax, eax
jne 0x41367a
push str.LdPrintMonitor
push ebx
call fcn.00423370
add esp, 8
test eax, eax
jne 0x41367a
mov edx, dword [esp + 0x18]
push edx
lea eax, [esp + 0x2c]
push 0x447b00
push eax
call fcn.00409910
push ebx
lea ecx, [esp + 0x2c]
push 0x447b00
push ecx
call fcn.00409910
mov edx, dword [esp + 0x30]
push edx
push ebx
push str.Open__s_Failed_.__s_
lea eax, [esp + 0x38]
push eax
jmp 0x41386d
push 0x208
lea ecx, [esp + 0x34]
push ecx
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [esp + 0x30]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x413693
sub eax, edx
add eax, 0xffffffff
js 0x4136ae
mov cl, 0x5c
cmp byte [esp + eax + 0x30], cl
je 0x4136ae
sub eax, 1
jns 0x4136a3
lea edi, [esp + 0x30]
mov byte [esp + eax + 0x30], 0
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x4136b8
mov dx, word [0x447968]
push str.LdWaterMarkHook32.dll
push ebx
mov word [edi], dx
call fcn.00423370
add esp, 8
test eax, eax
je 0x413725
lea eax, [esp + 0x30]
dec eax
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x4136e1
mov ecx, dword [str.LdWaterMarkHook32.dll]
mov edx, dword [0x449150]
mov dword [eax], ecx
mov ecx, dword [0x449154]
mov dword [eax + 4], edx
mov edx, dword [0x449158]
mov dword [eax + 8], ecx
mov ecx, dword [0x44915c]
mov dword [eax + 0xc], edx
mov dx, word [0x449160]
mov dword [eax + 0x10], ecx
mov word [eax + 0x14], dx
jmp 0x413835
push str.LdWaterMarkHook64.dll
push ebx
call fcn.00423370
add esp, 8
test eax, eax
je 0x413784
lea eax, [esp + 0x30]
dec eax
lea esp, [esp]
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x413740
mov ecx, dword [str.LdWaterMarkHook64.dll]
mov edx, dword [0x449168]
mov dword [eax], ecx
mov ecx, dword [0x44916c]
mov dword [eax + 4], edx
mov edx, dword [0x449170]
mov dword [eax + 8], ecx
mov ecx, dword [0x449174]
mov dword [eax + 0xc], edx
mov dx, word [0x449178]
mov dword [eax + 0x10], ecx
mov word [eax + 0x14], dx
jmp 0x413835
push str.LdPrintMonitor.dll
push ebx
call fcn.00423370
add esp, 8
test eax, eax
je 0x4137e1
lea eax, [esp + 0x30]
dec eax
jmp 0x4137a0
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x4137a0
mov ecx, dword [str.LdPrintMonitor.dll]
mov edx, dword [0x449180]
mov dword [eax], ecx
mov ecx, dword [0x449184]
mov dword [eax + 4], edx
mov edx, dword [0x449188]
mov dword [eax + 8], ecx
mov cx, word [0x44918c]
mov dword [eax + 0xc], edx
mov dl, byte [0x44918e]
mov word [eax + 0x10], cx
mov byte [eax + 0x12], dl
jmp 0x413835
push str.LdPrintMonitor64.dll
push ebx
call fcn.00423370
add esp, 8
test eax, eax
je 0x413835
lea eax, [esp + 0x30]
dec eax
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x4137f8
mov ecx, dword [str.LdPrintMonitor64.dll]
mov edx, dword [0x449194]
mov dword [eax], ecx
mov ecx, dword [0x449198]
mov dword [eax + 4], edx
mov edx, dword [0x44919c]
mov dword [eax + 8], ecx
mov ecx, dword [0x4491a0]
mov dword [eax + 0xc], edx
mov dl, byte [0x4491a4]
mov dword [eax + 0x10], ecx
mov byte [eax + 0x14], dl
mov eax, dword [esp + 0x18]
push eax
lea ecx, [esp + 0x2c]
push 0x447b00
push ecx
call fcn.00409910
lea edx, [esp + 0x3c]
push edx
lea eax, [esp + 0x2c]
push 0x447b00
push eax
call fcn.00409910
lea ecx, [esp + 0x48]
push ecx
push ebx
push str.Open__s_Failed_.__s_
lea edx, [esp + 0x38]
push edx
call fcn.00409910
mov eax, dword [esp + 0x3c]
add esp, 0x28
push 0
push eax
push 0x453d11
call fcn.0040d890
mov ecx, dword [esp + 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x4139bf
cmp edi, 5
jle 0x4138c0
push edi
push esi
lea edx, [esp + 0x1c]
push str.CompressFile_SrcFile__s__Time__d_
push edx
call fcn.00409910
mov eax, dword [esp + 0x24]
add esp, 0x10
push 0
push eax
push 0x453d11
call fcn.0040d890
xor esi, esi
mov ecx, dword [esp + 0x24]
push 0x447ed4
push ecx
call fcn.00438d50
mov edi, eax
add esp, 8
test edi, edi
jne 0x41391d
inc esi
cmp esi, 0x12c
jg 0x4138ed
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x4138c2
call ebx
mov edx, dword [esp + 0x24]
push eax
push edx
lea eax, [esp + 0x1c]
push str.CompressFile_DestFile__s__Fail__d_
push eax
call fcn.00409910
mov ecx, dword [esp + 0x24]
add esp, 0x10
push 0
push ecx
push 0x453d11
call fcn.0040d890
jmp 0x4139a9
cmp esi, 5
jle 0x41394b
mov edx, dword [esp + 0x24]
push esi
push edx
lea eax, [esp + 0x1c]
push str.CompressFile_DestFile__s__Time__d_
push eax
call fcn.00409910
mov ecx, dword [esp + 0x24]
add esp, 0x10
push 0
push ecx
push 0x453d11
call fcn.0040d890
push ebp
call fcn.0042303e
add esp, 4
test eax, eax
jne 0x4139a9
mov dword [esp + 0x20], 1
push ebp
push 0x8000
lea edx, [esp + 0x13c]
push 1
push edx
call fcn.00423346
add esp, 0x10
test eax, eax
jle 0x4139a9
push eax
lea eax, [esp + 0x138]
push eax
push edi
call fcn.00439550
add esp, 0xc
test eax, eax
je 0x4139a1
push ebp
call fcn.0042303e
add esp, 4
test eax, eax
je 0x413960
jmp 0x4139a9
mov dword [esp + 0x20], 0
push ebp
call fcn.0042295d
add esp, 4
test edi, edi
je 0x4139bf
push edi
call fcn.00439730
add esp, 4
mov byte [esp + 0x8140], 1
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4139e7
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x8140], 0
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x413a0f
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x8140], 0xffffffff
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x413a3a
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x8138]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x8120]
xor ecx, esp
call fcn.00421f05
add esp, 0x8130
ret