Function at 0x401290
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov eax, 0x1010
call fcn.004e6b50
mov eax, dword [0x519bc0]
xor eax, esp
mov dword [esp + 0x100c], eax
push ebx
push ebp
mov ebp, dword [esp + 0x101c]
push esi
mov eax, ebp
push edi
mov esi, ecx
mov dword [esp + 0x18], ebp
lea edx, [eax + 2]
mov edi, edi
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4012c0
sub eax, edx
sar eax, 1
mov edi, eax
cmp edi, 7
jbe 0x4014b8
lea eax, [ebp + edi*2 - 0xe]
push str..7z.001
push eax
call fcn.004e6aa7
add esp, 8
test eax, eax
jne 0x4014b8
lea edi, [esp + edi*2 + 0x16]
mov dword [esi + 0x18], eax
lea ebx, [eax + 1]
mov dword [esp + 0x14], edi
push 0x800
push ebp
lea ecx, [esp + 0x24]
push ecx
call fcn.004694b0
xor edx, edx
lea eax, [esp + 0x1c]
mov word [edi], dx
lea edx, [eax + 2]
mov edi, edi
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x401320
sub eax, edx
sar eax, 1
push ebx
lea eax, [esp + eax*2 + 0x20]
push 0x501834
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
lea ecx, [esp + 0x1c]
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x401356
inc dword [esi + 0x18]
inc ebx
cmp ebx, 0x3e8
jb 0x401302
cmp dword [esi + 0x18], 1
jbe 0x4014b8
mov edx, dword [esi + 0x14]
push edx
call fcn.004e6904
mov eax, dword [esi + 0x18]
xor ecx, ecx
mov edx, 0x10
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.004e68bd
xor ebx, ebx
add esp, 8
mov dword [esi + 0x14], eax
cmp dword [esi + 0x18], ebx
jbe 0x40146b
mov dword [esp + 0x10], ebx
jmp 0x4013aa
mov edi, dword [esp + 0x14]
mov ebp, dword [esp + 0x18]
push 0x800
push ebp
lea eax, [esp + 0x24]
push eax
call fcn.004694b0
xor ecx, ecx
lea eax, [esp + 0x1c]
mov word [edi], cx
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4013c6
sub eax, edx
lea ebp, [ebx + 1]
sar eax, 1
push ebp
lea edx, [esp + eax*2 + 0x20]
push 0x501834
push edx
call dword [sym.imp.USER32.dll_wsprintfW]
mov eax, dword [esi]
mov edi, dword [esi + 0x14]
mov edx, dword [eax + 4]
add edi, dword [esp + 0x1c]
add esp, 0xc
mov ecx, esi
mov byte [esi + 4], 0
call edx
cmp byte [esi + 5], 0
je 0x40140f
mov dword [esi + 8], 1
jmp 0x40143e
mov eax, dword [esp + 0x1030]
mov ecx, dword [esp + 0x102c]
mov edx, dword [esp + 0x1028]
push 0
push eax
push ecx
push 0
push edx
push SysReAllocString
lea eax, [esp + 0x34]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [esi + 8], eax
mov eax, dword [esi + 8]
cmp eax, 0xffffffff
setne cl
mov byte [esi + 4], cl
test cl, cl
je 0x40147e
mov dword [edi], eax
add edi, 8
push edi
mov ecx, esi
call fcn.004010a0
add dword [esp + 0x10], 0x10
mov ebx, ebp
cmp ebx, dword [esi + 0x18]
jb 0x4013a2
mov ecx, dword [esi + 0x14]
mov edx, dword [ecx]
mov dword [esi + 8], edx
mov byte [esi + 0x10], 1
mov al, 1
jmp 0x401505
test ebx, ebx
jbe 0x4014a1
mov ebp, dword [sym.imp.KERNEL32.dll_CloseHandle]
xor edi, edi
lea ebx, [ebx]
mov ecx, dword [esi + 0x14]
mov edx, dword [edi + ecx]
push edx
call ebp
add edi, 0x10
sub ebx, 1
jne 0x401490
mov eax, dword [esi + 0x14]
push eax
call fcn.004e6904
add esp, 4
mov dword [esi + 0x14], 0
xor al, al
jmp 0x401505
mov eax, dword [esi]
mov edx, dword [eax + 4]
mov ecx, esi
call edx
cmp byte [esi + 5], 0
je 0x4014d0
mov dword [esi + 8], 1
jmp 0x4014fb
mov eax, dword [esp + 0x1030]
mov ecx, dword [esp + 0x102c]
mov edx, dword [esp + 0x1028]
push 0
push eax
push ecx
push 0
push edx
push SysReAllocString
push ebp
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [esi + 8], eax
cmp dword [esi + 8], 0xffffffff
setne al
mov byte [esi + 4], al
mov ecx, dword [esp + 0x101c]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.004e6b3a
add esp, 0x1010
ret 0x10