Function at 0x40fbc0
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x57d66d
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x18
push ebx
push esi
push edi
push ecx
mov edx, ecx
mov ecx, esp
call fcn.00410840
lea ecx, [ebp - 0x10]
call fcn.0040f3a0
push 1
push 0xa
mov dword [ebp - 4], 0
call fcn.00562e6c
lea esi, [eax + 8]
mov dword [ebp - 0x18], esi
push 1
push 0xa
call fcn.00562e6c
add esp, 0x14
lea edi, [eax + 8]
mov dword [ebp - 0x24], edi
push 4
lea eax, [ebp - 0x1c]
mov byte [ebp - 4], 2
push eax
lea ecx, [ebp - 0x10]
mov dword [ebp - 0x14], 0
call fcn.0040b7e0
mov eax, dword [eax]
mov ecx, 0x5c9e30
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x40fc5e
test dx, dx
je 0x40fc5a
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x40fc5e
add eax, 4
add ecx, 4
test dx, dx
jne 0x40fc38
xor ebx, ebx
jmp 0x40fc63
sbb ebx, ebx
or ebx, 1
mov byte [ebp - 4], 2
or eax, 0xffffffff
mov edx, dword [ebp - 0x1c]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x40fc82
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
xor ecx, ecx
mov eax, 4
test ebx, ebx
mov ebx, dword [ebp - 0x10]
cmovne eax, ecx
xor edx, edx
mov dword [ebp - 0x1c], eax
mov ecx, eax
mov eax, edx
mov dword [ebp - 0x20], eax
test ecx, ecx
js 0x40fcdb
cmp ecx, dword [ebx - 0xc]
jg 0x40fcdb
lea eax, [ebx + ecx*2]
push 0x5c1e10
push eax
call fcn.0055a0f0
mov ebx, dword [ebp - 0x10]
add esp, 8
test eax, eax
jne 0x40fcc3
or eax, 0xffffffff
jmp 0x40fcc7
sub eax, ebx
sar eax, 1
mov edx, dword [ebp - 0x14]
lea ecx, [eax + 1]
inc edx
mov dword [ebp - 0x14], edx
cmp eax, 0xffffffff
jne 0x40fc98
mov eax, dword [ebp - 0x20]
jmp 0x40fcdf
inc edx
mov dword [ebp - 0x14], edx
test eax, eax
js 0x40fdfb
nop word [eax + eax]
mov eax, dword [ebp - 0x1c]
test eax, eax
js 0x40fd91
cmp eax, dword [ebx - 0xc]
jg 0x40fd91
lea eax, [ebx + eax*2]
push 0x5c1e10
push eax
call fcn.0055a0f0
mov ebx, dword [ebp - 0x10]
add esp, 8
test eax, eax
jne 0x40fd21
or eax, 0xffffffff
jmp 0x40fd25
sub eax, ebx
sar eax, 1
lea ecx, [eax + 1]
mov dword [ebp - 0x1c], ecx
cmp eax, 0xffffffff
je 0x40fd96
push ecx
lea eax, [ebp - 0x20]
push eax
lea ecx, [ebp - 0x10]
call fcn.0040b7e0
mov ebx, dword [eax]
mov ecx, ebx
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40fd44
sub ecx, edx
sar ecx, 1
push ecx
lea ecx, [ebp - 0x18]
call fcn.00410410
mov esi, dword [ebp - 0x18]
mov eax, dword [esi - 8]
lea eax, [eax*2 + 2]
push eax
push ebx
push esi
call fcn.0055a7b0
mov edx, dword [ebp - 0x20]
add esp, 0xc
add edx, 0xfffffff0
or eax, 0xffffffff
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x40fdd0
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
jmp 0x40fdd0
xor ecx, ecx
mov dword [ebp - 0x1c], ecx
mov eax, ebx
lea edx, [eax + 2]
nop dword [eax + eax]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x40fda0
sub eax, edx
lea ecx, [ebp - 0x18]
sar eax, 1
push eax
call fcn.00410410
mov esi, dword [ebp - 0x18]
mov eax, dword [esi - 8]
lea eax, [eax*2 + 2]
push eax
push ebx
push esi
call fcn.0055a7b0
add esp, 0xc
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x40fde9
push 0
push esi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
je 0x40fe54
mov edx, dword [ebp - 0x14]
mov ebx, dword [ebp - 0x10]
dec edx
mov dword [ebp - 0x14], edx
test edx, edx
jg 0x40fcf0
mov dword [ebp - 0x1c], 1
test edi, edi
je 0x40fe15
add edi, 0xfffffff8
push edi
call fcn.0055d993
mov ebx, dword [ebp - 0x10]
add esp, 4
test esi, esi
je 0x40fe28
add esi, 0xfffffff8
push esi
call fcn.0055d993
mov ebx, dword [ebp - 0x10]
add esp, 4
add ebx, 0xfffffff0
or eax, 0xffffffff
lock xadd dword [ebx + 0xc], eax
dec eax
test eax, eax
jg 0x40fe40
mov ecx, dword [ebx]
push ebx
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret
mov ebx, dword [ebp - 0x10]
mov dword [ebp - 0x1c], 0
jmp 0x40fe02