Function at 0x450120
Capabilities:
Check if file exists
Create directory
Print debug messages
Set file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x56c260]
mov edx, dword [eax + 0xc]
push ebx
push esi
push edi
mov ecx, 0x56c260
call edx
lea ebx, [eax + 0x10]
mov eax, dword [0x56c260]
mov edx, dword [eax + 0xc]
mov ecx, 0x56c260
mov dword [ebp - 8], ebx
call edx
lea edi, [eax + 0x10]
mov eax, dword [0x56c260]
mov edx, dword [eax + 0xc]
mov ecx, 0x56c260
mov dword [ebp - 0xc], edi
call edx
mov ecx, dword [ebp + 8]
lea esi, [eax + 0x10]
xor eax, eax
mov dword [ebp - 0x14], esi
mov dword [ebp - 0x10], eax
test eax, eax
js 0x450197
cmp eax, dword [ecx - 0xc]
jg 0x450197
lea eax, [ecx + eax*2]
push 0x556338
push eax
call fcn.004fe4a9
mov ecx, dword [ebp + 8]
add esp, 8
test eax, eax
je 0x450197
sub eax, ecx
sar eax, 1
jmp 0x45019a
or eax, 0xffffffff
inc eax
test eax, eax
jle 0x4501a2
inc dword [ebp - 0x10]
lea edx, [eax - 1]
cmp edx, 0xffffffff
jne 0x450170
mov eax, dword [ebp - 0x10]
dec eax
mov dword [ebp - 0x18], 0
js 0x450656
mov edi, dword [ebp - 8]
mov dword [ebp - 0x20], eax
jmp 0x4501c6
mov ecx, dword [ebp + 8]
mov eax, dword [ebp - 0x18]
test eax, eax
js 0x4501f0
cmp eax, dword [ecx - 0xc]
jg 0x4501f0
lea eax, [ecx + eax*2]
push 0x556338
push eax
call fcn.004fe4a9
mov ecx, dword [ebp + 8]
add esp, 8
test eax, eax
je 0x4501f0
sub eax, ecx
sar eax, 1
jmp 0x4501f3
or eax, 0xffffffff
inc eax
lea edx, [eax - 1]
mov dword [ebp - 0x18], eax
cmp edx, 0xffffffff
jne 0x45025a
lea eax, [ecx - 0x10]
lea esi, [edi - 0x10]
cmp eax, esi
je 0x4503b7
cmp dword [esi + 0xc], 0
lea edi, [esi + 0xc]
jl 0x450248
mov edx, dword [eax]
cmp edx, dword [esi]
jne 0x450248
push eax
call fcn.00403b50
mov ebx, eax
add esp, 4
or eax, 0xffffffff
lock xadd dword [edi], eax
dec eax
test eax, eax
jg 0x45023d
mov ecx, dword [esi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push esi
call eax
lea edi, [ebx + 0x10]
mov dword [ebp - 8], edi
jmp 0x4503b7
mov edx, dword [ecx - 0xc]
push edx
push ecx
lea ecx, [ebp - 8]
call fcn.00403ee0
jmp 0x4503b4
mov edi, eax
test eax, eax
jns 0x450262
xor edi, edi
cmp edi, dword [ecx - 0xc]
jl 0x4502cf
lea esi, [ecx - 0x10]
mov ecx, dword [esi]
mov eax, dword [ecx]
mov edx, dword [eax + 0x10]
call edx
cmp dword [esi + 0xc], 0
lea ecx, [esi + 0xc]
jl 0x450293
cmp eax, dword [esi]
jne 0x450293
mov edi, esi
mov eax, 1
lock xadd dword [ecx], eax
lea esi, [edi + 0x10]
jmp 0x450349
mov ecx, dword [esi + 4]
mov edx, dword [eax]
mov edx, dword [edx]
push 2
push ecx
mov ecx, eax
call edx
mov edi, eax
test edi, edi
je 0x4506d7
mov eax, dword [esi + 4]
mov dword [edi + 4], eax
mov eax, dword [esi + 4]
lea eax, [eax + eax + 2]
push eax
add esi, 0x10
push esi
push eax
lea ecx, [edi + 0x10]
push ecx
call fcn.004fe509
add esp, 0x10
lea esi, [edi + 0x10]
jmp 0x450349
mov ecx, dword [ecx - 0x10]
test ecx, ecx
je 0x4502e1
mov edx, dword [ecx]
mov eax, dword [edx + 0x10]
call eax
test eax, eax
jne 0x4502f1
mov edx, dword [0x56c260]
mov eax, dword [edx + 0x10]
mov ecx, 0x56c260
call eax
mov ecx, dword [ebp + 8]
mov ebx, ecx
test eax, eax
je 0x4506dc
test ecx, ecx
jne 0x45030a
test edi, edi
jne 0x4506e6
mov edx, dword [eax]
push 2
mov ecx, eax
mov eax, dword [edx]
push edi
call eax
test eax, eax
je 0x4506d7
lea esi, [eax + 0x10]
test edi, edi
js 0x4506e6
cmp edi, dword [esi - 8]
jg 0x4506e6
lea eax, [edi + edi]
push eax
push ebx
push eax
xor ecx, ecx
mov dword [esi - 0xc], edi
push esi
mov word [eax + esi], cx
call fcn.004fe509
add esp, 0x10
mov ebx, dword [ebp - 8]
lea edi, [esi - 0x10]
add ebx, 0xfffffff0
cmp edi, ebx
je 0x45039b
cmp dword [ebx + 0xc], 0
jl 0x45038e
mov edx, dword [edi]
cmp edx, dword [ebx]
jne 0x45038e
push edi
call fcn.00403b50
mov esi, eax
add esp, 4
lea eax, [ebx + 0xc]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x450386
mov ecx, dword [ebx]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push ebx
call eax
add esi, 0x10
mov dword [ebp - 8], esi
jmp 0x45039b
mov ecx, dword [esi - 0xc]
push ecx
push esi
lea ecx, [ebp - 8]
call fcn.00403ee0
lea edx, [edi + 0xc]
or eax, 0xffffffff
lock xadd dword [edx], eax
dec eax
test eax, eax
jg 0x4503b4
mov ecx, dword [edi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push edi
call eax
mov edi, dword [ebp - 8]
push edi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x450644
push eax
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x45062a
mov esi, dword [edi - 0xc]
lea ebx, [edi - 0x10]
cmp esi, 1
jg 0x4503f2
push ebx
call fcn.00403b50
lea esi, [eax + 0x10]
add esp, 4
mov dword [ebp - 0x1c], esi
jmp 0x450426
mov ecx, dword [ebx]
test ecx, ecx
je 0x450403
mov edx, dword [ecx]
mov eax, dword [edx + 0x10]
call eax
test eax, eax
jne 0x450413
mov edx, dword [0x56c260]
mov eax, dword [edx + 0x10]
mov ecx, 0x56c260
call eax
push eax
push 1
lea ecx, [edi + esi*2 - 2]
push ecx
lea ecx, [ebp - 0x1c]
call fcn.00403330
mov esi, dword [ebp - 0x1c]
push 0x556338
push esi
call fcn.004fe94a
add esp, 8
test eax, eax
sete byte [ebp - 1]
add esi, 0xfffffff0
lea edx, [esi + 0xc]
or eax, 0xffffffff
lock xadd dword [edx], eax
dec eax
test eax, eax
jg 0x450456
mov ecx, dword [esi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push esi
call eax
cmp byte [ebp - 1], 0
je 0x4504d6
mov eax, dword [edi - 0xc]
lea esi, [eax - 1]
test esi, esi
jns 0x450468
xor esi, esi
cmp esi, eax
jl 0x45047d
push ebx
call fcn.00403b50
lea esi, [eax + 0x10]
add esp, 4
mov dword [ebp - 0x10], esi
jmp 0x4504ac
mov ecx, dword [ebx]
test ecx, ecx
je 0x45048e
mov edx, dword [ecx]
mov eax, dword [edx + 0x10]
call eax
test eax, eax
jne 0x45049e
mov edx, dword [0x56c260]
mov eax, dword [edx + 0x10]
mov ecx, 0x56c260
call eax
push eax
push esi
push edi
lea ecx, [ebp - 0x10]
call fcn.00403330
mov esi, dword [ebp - 0x10]
lea ecx, [ebp - 0x10]
push ecx
lea ecx, [ebp - 0xc]
call fcn.00423fc0
lea eax, [esi - 0x10]
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x4504e2
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
jmp 0x4504e2
lea ecx, [ebp - 8]
push ecx
lea ecx, [ebp - 0xc]
call fcn.00423fc0
mov ebx, dword [ebp - 0xc]
push ebx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x450611
push str._old
lea edx, [ebp - 0xc]
push edx
lea eax, [ebp - 0x24]
push eax
call fcn.00428550
mov ecx, dword [eax]
push ecx
push ebx
call fcn.00504eff
mov eax, dword [ebp - 0x24]
add eax, 0xfffffff0
add esp, 0x14
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x450531
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push 0
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x45062a
mov edx, dword [0x56c260]
mov eax, dword [edx + 0xc]
mov ecx, 0x56c260
call eax
push edi
push str._nCreateDirectory_Fail:_s
lea ecx, [ebp + 0xc]
add eax, 0x10
push ecx
mov dword [ebp + 0xc], eax
call fcn.00428a30
mov esi, dword [ebp + 0xc]
add esp, 0xc
push esi
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
lea eax, [esi - 0x10]
or ecx, 0xffffffff
lea edx, [eax + 0xc]
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x450590
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x14]
add eax, 0xfffffff0
or edx, 0xffffffff
lea ecx, [eax + 0xc]
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4505af
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea eax, [ebx - 0x10]
or edx, 0xffffffff
lea ecx, [eax + 0xc]
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4505cb
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
add edi, 0xfffffff0
or edx, 0xffffffff
lea ecx, [edi + 0xc]
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4505e7
mov ecx, dword [edi]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push edi
call edx
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x450606
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 8
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
push 0
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
je 0x4506f0
cmp dword [ebp + 0xc], 0
je 0x450644
push 6
push edi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push str._ntest_n
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
dec dword [ebp - 0x20]
jns 0x4501c3
mov ebx, dword [ebp - 8]
mov edi, dword [ebp - 0xc]
mov esi, dword [ebp - 0x14]
lea eax, [esi - 0x10]
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x450672
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea eax, [edi - 0x10]
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x45068e
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea eax, [ebx - 0x10]
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4506aa
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4506c9
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
pop edi
pop esi
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret 8
call fcn.00403d10
push 0x80004005
call fcn.00404190
push 0x80070057
call fcn.00404190
mov edx, dword [0x56c260]
mov eax, dword [edx + 0xc]
mov ecx, 0x56c260
call eax
push edi
push str._nCreateDirectory_Fail_2:_s
jmp 0x450558