Function at 0x40e496
Capabilities:
Check if file exists
Copy file
Delete file
Get file attributes
Write file on windows

Disassembly:
mov eax, 0x444e13
call fcn.004205a0
sub esp, 0x7a0
push ebx
push esi
push edi
push 1
push dword [ebp + 8]
mov dword [ebp - 0x84], ecx
call fcn.0040f6bc
pop ecx
mov ebx, eax
pop ecx
lea ecx, [ebp - 0x58]
call fcn.0040f3a3
xor edi, edi
push edi
mov dword [ebp - 4], edi
sub esp, 0x1c
mov ecx, esp
mov dword [ebp - 0x30], esp
push 1
push dword [ebp + 8]
call fcn.0040ee90
lea ecx, [ebp - 0x58]
call fcn.0040f413
test al, al
je 0x40ee5a
push edi
push ebx
lea ecx, [ebp - 0x58]
call fcn.0040f643
lea eax, [ebp - 0x7ac]
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov dword [ebp - 0x1c], eax
cmp eax, 0xffffffff
mov byte [ebp - 4], 1
jne 0x40e537
and byte [ebp - 4], 0
lea ecx, [ebp - 0x1c]
call fcn.00410e81
mov dword [ebp - 0x58], vtable.is::file_lite.0
mov dword [ebp - 4], 2
mov esi, 0xfffffcdb
jmp 0x40ecc0
mov esi, dword [sym.imp.KERNEL32.dll_FindClose]
mov ecx, dword [ebp - 0x78c]
cmp esi, edi
mov dword [ebp - 0x2c], ecx
je 0x40e551
push eax
call esi
or dword [ebp - 0x1c], 0xffffffff
push 0x4000
call fcn.00420d90
mov edi, dword [ebp + 0x10]
pop ecx
test edi, edi
mov dword [ebp - 0x14], eax
je 0x40e596
lea eax, [ebp + 0xb]
push 1
push eax
lea ecx, [ebp - 0x80]
push dword [ebp + 0xc]
call fcn.00401698
mov eax, dword [edi + 8]
lea ecx, [ebp - 0x80]
push ecx
push eax
mov ecx, edi
mov byte [ebp - 4], 3
call fcn.004115db
lea ecx, [ebp - 0x80]
mov byte [ebp - 4], 1
call fcn.00401291
cmp ebx, dword [ebp - 0x2c]
mov dword [ebp - 0x10], ebx
jae 0x40ec5b
mov esi, dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenA]
mov ebx, vtable.zpath.0
and byte [ebp + 0xb], 0
push 0
push dword [ebp - 0x10]
lea ecx, [ebp - 0x58]
call fcn.0040f643
push 0x104
lea ecx, [ebp - 0x58]
push dword [ebp - 0x14]
call fcn.0040f5ff
push dword [ebp - 0x14]
lea eax, [ebp - 0x458]
push eax
call esi
lea eax, [ebp - 0x458]
push eax
call edi
mov ecx, dword [ebp - 0x10]
push 0
lea eax, [ecx + eax + 1]
lea ecx, [ebp - 0x58]
push eax
mov dword [ebp - 0x10], eax
call fcn.0040f643
push 0x104
lea ecx, [ebp - 0x58]
push dword [ebp - 0x14]
call fcn.0040f5ff
push dword [ebp - 0x14]
lea eax, [ebp - 0x55c]
push eax
call esi
lea eax, [ebp - 0x55c]
push eax
call edi
mov ecx, dword [ebp - 0x10]
push 0
lea eax, [ecx + eax + 1]
lea ecx, [ebp - 0x58]
push eax
mov dword [ebp - 0x10], eax
call fcn.0040f643
push 0x104
lea ecx, [ebp - 0x58]
push dword [ebp - 0x14]
call fcn.0040f5ff
push dword [ebp - 0x14]
lea eax, [ebp - 0x160]
push eax
call esi
lea eax, [ebp - 0x160]
push eax
call edi
mov ecx, dword [ebp - 0x10]
push 0
lea eax, [ecx + eax + 1]
lea ecx, [ebp - 0x58]
push eax
mov dword [ebp - 0x10], eax
call fcn.0040f643
push 0xf
lea ecx, [ebp - 0x58]
push dword [ebp - 0x14]
call fcn.0040f5ff
push 0xa
push dword [ebp - 0x14]
call fcn.00410d2b
pop ecx
mov dword [ebp - 0x18], eax
pop ecx
push dword [ebp - 0x14]
call edi
inc eax
push 0
add dword [ebp - 0x10], eax
lea eax, [ebp - 0x55c]
push eax
lea ecx, [ebp - 0xc8]
mov dword [ebp - 0xbc], 0x449e08
mov dword [ebp - 0xb4], 0x449e00
call fcn.00410b5b
mov dword [ebp - 0xc8], ebx
lea eax, [ebp - 0x200]
lea ecx, [ebp - 0xc8]
push eax
mov byte [ebp - 4], 4
call fcn.0040ef41
push 0
push eax
lea ecx, [ebp - 0xa4]
mov byte [ebp - 4], 5
mov dword [ebp - 0x98], 0x449e08
mov dword [ebp - 0x90], 0x449e00
call fcn.00410beb
mov dword [ebp - 0xa4], ebx
lea ecx, [ebp - 0x200]
mov byte [ebp - 4], 7
call fcn.00410c99
push dword [ebp + 0xc]
lea eax, [ebp - 0x354]
push eax
call esi
lea eax, [ebp - 0x354]
push 0x4534c0
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
cmp dword [ebp - 0x94], 0
je 0x40e826
push dword [ebp - 0x94]
call dword [sym.imp.OLEAUT32.dll_VariantInit]
test eax, eax
jbe 0x40e826
lea ecx, [ebp - 0xa4]
call fcn.0041188b
push dword [ebp - 0xa0]
lea eax, [ebp - 0x354]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [ebp - 0x354]
push 0
push eax
lea ecx, [ebp - 0x100]
mov dword [ebp - 0xf4], 0x449e08
mov dword [ebp - 0xec], 0x449e00
call fcn.00410b5b
mov dword [ebp - 0x100], ebx
lea ecx, [ebp - 0x100]
mov byte [ebp - 4], 8
call fcn.0041188b
push dword [ebp - 0xfc]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x40e817
mov ecx, dword [ebp - 0x84]
lea eax, [ebp - 0x100]
push eax
call fcn.0040fb1e
cmp dword [ebp + 0x14], 0
je 0x40e817
lea eax, [ebp - 0x25]
push 1
push eax
lea eax, [ebp - 0x354]
push eax
lea ecx, [ebp - 0x188]
call fcn.00401698
mov ecx, dword [ebp + 0x14]
lea edx, [ebp - 0x188]
push edx
mov byte [ebp - 4], 9
mov eax, dword [ecx + 8]
push eax
call fcn.004115db
lea ecx, [ebp - 0x188]
mov byte [ebp - 4], 8
call fcn.00401291
lea ecx, [ebp - 0x100]
mov byte [ebp - 4], 7
call fcn.00410c99
lea eax, [ebp - 0x458]
push eax
lea eax, [ebp - 0x354]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [ebp - 0x458]
push 0
push eax
lea ecx, [ebp - 0xe4]
mov dword [ebp - 0xd8], 0x449e08
mov dword [ebp - 0xd0], 0x449e00
call fcn.00410b5b
mov dword [ebp - 0xe4], ebx
lea eax, [ebp - 0x228]
push 0
push eax
lea ecx, [ebp - 0xe4]
mov byte [ebp - 4], 0xa
call fcn.0040f060
mov ecx, eax
mov dword [ebp - 0x24], ecx
mov byte [ebp - 4], 0xb
call fcn.0041188b
mov eax, dword [ebp - 0x24]
push str..cab
mov eax, dword [eax + 4]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
neg eax
sbb al, al
lea ecx, [ebp - 0x228]
inc al
mov byte [ebp - 4], 0xa
mov byte [ebp - 0x1d], al
call fcn.00410c99
cmp byte [ebp - 0x1d], 0
je 0x40e99b
lea eax, [ebp - 0x458]
push 5
push eax
lea eax, [ebp - 0xac]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpynA]
lea eax, [ebp - 0x1b0]
lea ecx, [ebp - 0xa4]
push eax
call fcn.0040eec1
mov ecx, eax
call fcn.0040ef41
push 0
push eax
lea ecx, [ebp - 0x11c]
mov byte [ebp - 4], 0xc
mov dword [ebp - 0x110], 0x449e08
mov dword [ebp - 0x108], 0x449e00
call fcn.00410beb
mov dword [ebp - 0x11c], ebx
lea ecx, [ebp - 0x1b0]
mov byte [ebp - 4], 0xe
call fcn.00410c99
lea eax, [ebp - 0xac]
push str.data
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x40e975
lea eax, [ebp - 0x458]
push str.data1.cab
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
je 0x40e975
cmp dword [ebp - 0x10c], 0
je 0x40e971
push dword [ebp - 0x10c]
call dword [sym.imp.OLEAUT32.dll_VariantInit]
test eax, eax
jne 0x40e975
mov byte [ebp + 0xb], 1
lea ecx, [ebp - 0x11c]
mov byte [ebp - 4], 0xa
call fcn.00410c99
cmp byte [ebp + 0xb], 0
je 0x40e99b
cmp byte [ebp + 0x18], 0
jne 0x40e99b
mov eax, dword [ebp - 0x18]
add dword [ebp - 0x10], eax
jmp 0x40ec19
lea ecx, [ebp - 0x80]
call fcn.0040f3a3
push 2
lea eax, [ebp - 0x354]
sub esp, 0x1c
mov byte [ebp - 4], 0xf
mov ecx, esp
mov dword [ebp + 8], esp
push 1
push eax
call fcn.0040ee90
lea ecx, [ebp - 0x80]
call fcn.0040f4fe
test al, al
je 0x40ecdb
cmp dword [ebp - 0x18], 0x4000
jb 0x40ea38
push 0
lea ecx, [ebp - 0x58]
push dword [ebp - 0x10]
call fcn.0040f643
push 0x4000
lea ecx, [ebp - 0x58]
push dword [ebp - 0x14]
call fcn.0040f5ff
lea ecx, [ebp - 0x88]
mov eax, 0x4000
push 0
add dword [ebp - 0x10], eax
push ecx
push eax
push dword [ebp - 0x14]
push dword [ebp - 0x7c]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x40ea1f
mov eax, dword [ebp - 0x88]
jmp 0x40ea22
or eax, 0xffffffff
cmp eax, 0xffffffff
je 0x40ed51
mov eax, 0x4000
sub dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], eax
jae 0x40e9d8
cmp dword [ebp - 0x18], 0
jbe 0x40ea87
push 0
lea ecx, [ebp - 0x58]
push dword [ebp - 0x10]
call fcn.0040f643
push dword [ebp - 0x18]
lea ecx, [ebp - 0x58]
push dword [ebp - 0x14]
call fcn.0040f5ff
mov eax, dword [ebp - 0x18]
lea ecx, [ebp - 0x30]
push 0
add dword [ebp - 0x10], eax
push ecx
push eax
push dword [ebp - 0x14]
push dword [ebp - 0x7c]
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x40ea7b
mov eax, dword [ebp - 0x30]
jmp 0x40ea7e
or eax, 0xffffffff
cmp eax, 0xffffffff
je 0x40edc7
lea ecx, [ebp - 0x80]
call fcn.0040f678
lea eax, [ebp - 0x1d8]
lea ecx, [ebp - 0xc8]
push eax
call fcn.0040effb
mov ecx, eax
mov dword [ebp + 8], ecx
mov byte [ebp - 4], 0x16
call fcn.0041188b
mov eax, dword [ebp + 8]
lea ecx, [ebp - 0xe4]
mov eax, dword [eax + 4]
mov dword [ebp - 0x24], eax
lea eax, [ebp - 0x250]
push eax
call fcn.0040effb
mov ecx, eax
mov dword [ebp + 8], ecx
mov byte [ebp - 4], 0x17
call fcn.0041188b
mov eax, dword [ebp + 8]
push dword [ebp - 0x24]
mov eax, dword [eax + 4]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
lea ecx, [ebp - 0x250]
mov byte [ebp - 4], 0x16
setne byte [ebp + 0xb]
call fcn.00410c99
lea ecx, [ebp - 0x1d8]
mov byte [ebp - 4], 0xf
call fcn.00410c99
cmp byte [ebp + 0xb], 0
je 0x40ebba
push dword [ebp + 0xc]
lea eax, [ebp - 0x458]
push eax
call esi
lea eax, [ebp - 0x458]
push 0x4534c0
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [ebp - 0x55c]
push eax
lea eax, [ebp - 0x458]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [ebp - 0x5e4]
push 0
push eax
lea eax, [ebp - 0x354]
push eax
call sub.LZ32.dll_LZOpenFileA
mov dword [ebp + 8], eax
lea eax, [ebp - 0x66c]
push 0x1001
push eax
lea eax, [ebp - 0x458]
push eax
call sub.LZ32.dll_LZOpenFileA
push eax
mov dword [ebp - 0x24], eax
push dword [ebp + 8]
call sub.LZ32.dll_LZCopy
push dword [ebp + 8]
mov dword [ebp - 0x18], eax
call sub.LZ32.dll_LZClose
push dword [ebp - 0x24]
call sub.LZ32.dll_LZClose
cmp dword [ebp - 0x18], 0
jle 0x40ebba
lea eax, [ebp - 0x354]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea eax, [ebp - 0x458]
push eax
lea eax, [ebp - 0x354]
push eax
call esi
cmp dword [ebp + 0x10], 0
je 0x40ebfa
lea eax, [ebp - 0x26]
push 1
push eax
lea eax, [ebp - 0x354]
push eax
lea ecx, [ebp - 0x144]
call fcn.00401698
mov ecx, dword [ebp + 0x10]
lea eax, [ebp - 0x144]
push eax
mov byte [ebp - 4], 0x18
call fcn.00410603
lea ecx, [ebp - 0x144]
mov byte [ebp - 4], 0xf
call fcn.00401291
mov dword [ebp - 0x80], vtable.is::file_lite.0
lea ecx, [ebp - 0x80]
mov byte [ebp - 4], 0x19
call fcn.0040f678
lea ecx, [ebp - 0x78]
mov byte [ebp - 4], 0xa
call fcn.00410c99
lea ecx, [ebp - 0xe4]
mov byte [ebp - 4], 7
call fcn.00410c99
lea ecx, [ebp - 0xa4]
mov byte [ebp - 4], 4
call fcn.00410c99
lea ecx, [ebp - 0xc8]
mov byte [ebp - 4], 1
call fcn.00410c99
mov eax, dword [ebp - 0x2c]
cmp dword [ebp - 0x10], eax
jb 0x40e5b3
mov edi, dword [ebp + 0x10]
mov esi, dword [sym.imp.KERNEL32.dll_FindClose]
test edi, edi
je 0x40ec94
lea eax, [ebp + 0x1b]
push 1
push eax
lea ecx, [ebp - 0x144]
push dword [ebp + 0xc]
call fcn.00401698
lea eax, [ebp - 0x144]
mov ecx, edi
push eax
mov byte [ebp - 4], 0x1a
call fcn.00410603
lea ecx, [ebp - 0x144]
mov byte [ebp - 4], 1
call fcn.00401291
push dword [ebp - 0x14]
call fcn.0041fd63
cmp dword [ebp - 0x1c], 0xffffffff
pop ecx
je 0x40ecb0
test esi, esi
je 0x40ecb0
push dword [ebp - 0x1c]
call esi
or dword [ebp - 0x1c], 0xffffffff
mov dword [ebp - 0x58], vtable.is::file_lite.0
mov dword [ebp - 4], 0x1b
xor esi, esi
lea ecx, [ebp - 0x58]
call fcn.0040f678
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x50]
call fcn.00410c99
mov eax, esi
jmp 0x40ee7f
push dword [ebp - 0x14]
call fcn.0041fd63
mov esi, vtable.is::file_lite.0
pop ecx
mov dword [ebp - 0x80], esi
lea ecx, [ebp - 0x80]
mov byte [ebp - 4], 0x10
call fcn.0040f678
lea ecx, [ebp - 0x78]
mov byte [ebp - 4], 0xa
call fcn.00410c99
lea ecx, [ebp - 0xe4]
mov byte [ebp - 4], 7
call fcn.00410c99
lea ecx, [ebp - 0xa4]
mov byte [ebp - 4], 4
call fcn.00410c99
lea ecx, [ebp - 0xc8]
mov byte [ebp - 4], 1
call fcn.00410c99
and byte [ebp - 4], 0
lea ecx, [ebp - 0x1c]
call fcn.00410e81
mov dword [ebp - 0x58], esi
mov dword [ebp - 4], 0x11
mov esi, 0xfffffce0
jmp 0x40ecc0
push dword [ebp - 0x14]
call fcn.0041fd63
mov esi, vtable.is::file_lite.0
pop ecx
mov dword [ebp - 0x80], esi
lea ecx, [ebp - 0x80]
mov byte [ebp - 4], 0x12
call fcn.0040f678
lea ecx, [ebp - 0x78]
mov byte [ebp - 4], 0xa
call fcn.00410c99
lea ecx, [ebp - 0xe4]
mov byte [ebp - 4], 7
call fcn.00410c99
lea ecx, [ebp - 0xa4]
mov byte [ebp - 4], 4
call fcn.00410c99
lea ecx, [ebp - 0xc8]
mov byte [ebp - 4], 1
call fcn.00410c99
and byte [ebp - 4], 0
lea ecx, [ebp - 0x1c]
call fcn.00410e81
mov dword [ebp - 0x58], esi
mov dword [ebp - 4], 0x13
mov esi, 0xfffffcda
jmp 0x40ecc0
push dword [ebp - 0x14]
call fcn.0041fd63
mov esi, vtable.is::file_lite.0
pop ecx
mov dword [ebp - 0x80], esi
lea ecx, [ebp - 0x80]
mov byte [ebp - 4], 0x14
call fcn.0040f678
lea ecx, [ebp - 0x78]
mov byte [ebp - 4], 0xa
call fcn.00410c99
lea ecx, [ebp - 0xe4]
mov byte [ebp - 4], 7
call fcn.00410c99
lea ecx, [ebp - 0xa4]
mov byte [ebp - 4], 4
call fcn.00410c99
lea ecx, [ebp - 0xc8]
mov byte [ebp - 4], 1
call fcn.00410c99
cmp dword [ebp - 0x1c], 0xffffffff
je 0x40ee35
mov eax, dword [sym.imp.KERNEL32.dll_FindClose]
test eax, eax
je 0x40ee35
push dword [ebp - 0x1c]
call eax
or dword [ebp - 0x1c], 0xffffffff
mov dword [ebp - 0x58], esi
lea ecx, [ebp - 0x58]
mov dword [ebp - 4], 0x15
call fcn.0040f678
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x50]
call fcn.00410c99
mov eax, 0xfffffcda
jmp 0x40ee7f
mov dword [ebp - 0x58], vtable.is::file_lite.0
lea ecx, [ebp - 0x58]
mov dword [ebp - 4], 0x1c
call fcn.0040f678
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x50]
call fcn.00410c99
or eax, 0xffffffff
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret 0x14