Function at 0x10005870
Capabilities:
Create directory
Set file attributes

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, 0x494c
call fcn.100974c0
mov eax, dword [0x100e6018]
xor eax, esp
mov dword [esp + 0x4948], eax
push ebx
mov ebx, dword [ebp + 0x10]
push esi
mov esi, dword [ebp + 8]
push edi
mov dword [esp + 0x10], ebx
test esi, esi
je 0x10005e29
mov edi, dword [ebp + 0xc]
test edi, edi
je 0x10005e29
xor eax, eax
push 0x61a
push eax
mov word [esp + 0x4338], ax
lea eax, [esp + 0x433a]
push eax
call sub.MSVCR110.dll_memset
add esp, 0xc
lea ecx, [ebx + 2]
mov ax, word [ebx]
add ebx, 2
test ax, ax
jne 0x100058d1
push dword [esp + 0x10]
lea eax, [esp + 0x4334]
sub ebx, ecx
push 0x30e
push eax
sar ebx, 1
call dword [sym.imp.MSVCR110.dll_wcscpy_s]
mov eax, dword [esp + 0x1c]
add esp, 0xc
cmp word [eax + ebx*2 - 2], 0x5c
je 0x1000593f
push 0x100a21f4
lea eax, [esp + 0x4334]
push 0x30e
push eax
call dword [sym.imp.MSVCR110.dll_wcscat_s]
lea ebx, [esp + 0x433c]
add esp, 0xc
lea ecx, [ebx + 2]
jmp 0x10005930
mov ax, word [ebx]
add ebx, 2
test ax, ax
jne 0x10005930
sub ebx, ecx
sar ebx, 1
call fcn.10001090
xorps xmm0, xmm0
lea edx, [esp + 0x30]
lea ecx, [esp + 0x40cc]
mov dword [esp + 0x90], 0x10001000
mov dword [esp + 0x94], 0x10001020
mov dword [esp + 0x98], 0x10001000
mov dword [esp + 0x9c], 0x10001020
mov dword [esp + 0x40c4], 0x10004980
mov dword [esp + 0x40c8], 0x100049a0
mov dword [esp + 0xa0], 0x10005f00
mov dword [esp + 0xa4], 0x10005f60
mov dword [esp + 0xa8], 0x10005f70
mov dword [esp + 0xac], 0x10005fc0
mov dword [esp + 0x40d4], 0
mov dword [esp + 0x40cc], esi
mov dword [esp + 0x40d0], edi
movlpd qword [esp + 0x30], xmm0
call fcn.10004b20
test eax, eax
jne 0x100059ed
lea edi, [eax + 0xb]
jmp 0x10005a3b
cmp dword [esp + 0x34], 0
mov eax, dword [esp + 0x40d0]
mov ecx, dword [esp + 0x30]
jl 0x10005a0e
jg 0x10005a05
cmp ecx, eax
jbe 0x10005a0e
mov dword [esp + 0x40d4], eax
jmp 0x10005a15
mov dword [esp + 0x40d4], ecx
lea eax, [esp + 0x40c4]
mov dword [esp + 0xb0], eax
mov dword [esp + 0xb8], 0
mov dword [esp + 0xb4], 0
xor edi, edi
lea ecx, [esp + 0x40]
call fcn.100022b0
test edi, edi
jne 0x10005d4f
lea eax, [esp + 0x98]
push eax
lea eax, [esp + 0x94]
push eax
lea edx, [esp + 0xa8]
call fcn.100041e0
mov edi, eax
add esp, 8
test edi, edi
je 0x10005a89
lea edx, [esp + 0x90]
lea ecx, [esp + 0x40]
call fcn.10002320
test edi, edi
jne 0x10005d4f
xor edx, edx
mov dword [esp + 0x30], 0xffffffff
mov dword [esp + 0x20], 0
mov dword [esp + 0x3c], 0
mov dword [esp + 0x18], edx
cmp dword [esp + 0x5c], edx
jbe 0x10005d39
xor ecx, ecx
mov dword [esp + 0x28], ecx
jmp 0x10005ac0
mov eax, dword [esp + 0x50]
add eax, ecx
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x80]
mov dword [esp + 0x24], 0
mov ecx, dword [eax + edx*4]
mov edx, dword [eax + edx*4 + 4]
sub edx, ecx
mov dword [esp + 0xc], 0
cmp edx, 0x104
jae 0x10005d34
lea esi, [esp + 0x4330]
lea esi, [esi + ebx*2]
test esi, esi
je 0x10005b37
mov eax, dword [esp + 0x84]
lea esi, [eax + ecx*2]
test edx, edx
je 0x10005b2d
lea eax, [esp + 0x4330]
lea eax, [eax + ebx*2]
mov ecx, eax
sub esi, eax
mov ax, word [esi + ecx]
mov word [ecx], ax
lea ecx, [ecx + 2]
dec edx
jne 0x10005b20
lea esi, [esp + 0x4330]
lea esi, [esi + ebx*2]
lea eax, [esp + 0x98]
push eax
lea eax, [esp + 0x94]
push eax
lea eax, [esp + 0x14]
push eax
lea eax, [esp + 0x30]
push eax
lea eax, [esp + 0x4c]
push eax
lea eax, [esp + 0x34]
push eax
lea eax, [esp + 0x48]
push eax
push dword [esp + 0x34]
lea edx, [esp + 0xc0]
lea ecx, [esp + 0x60]
call fcn.10004580
mov edi, eax
add esp, 0x20
mov dword [esp + 0x14], edi
test edi, edi
jne 0x10005d39
cmp word [esi], di
je 0x10005bd5
lea eax, [esp + 0x4330]
lea eax, [eax + ebx*2]
cmp word [esi], 0x2f
jne 0x10005bca
xor eax, eax
push eax
mov word [esi], ax
lea eax, [esp + 0x4334]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x10005bb8
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, 0x5c
mov word [esi], ax
lea eax, [esp + 0x4330]
lea eax, [eax + ebx*2]
inc edi
cmp word [eax + edi*2], 0
lea esi, [eax + edi*2]
jne 0x10005b94
mov eax, dword [esp + 0x1c]
cmp byte [eax + 0x19], 0
je 0x10005c20
push 0
lea eax, [esp + 0x4334]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x10005bf9
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, dword [esp + 0x14]
mov edx, dword [esp + 0x18]
mov ecx, dword [esp + 0x28]
inc edx
add ecx, 0x20
mov dword [esp + 0x18], edx
mov dword [esp + 0x28], ecx
cmp edx, dword [esp + 0x5c]
jb 0x10005ac0
jmp 0x10005d39
lea eax, [esp + 0x40e0]
push eax
lea eax, [esp + 0x4334]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
cmp eax, 0xffffffff
jne 0x10005d2d
push 0
push 0x80
push 2
push 0
push 1
push 0x40000000
lea eax, [esp + 0x4348]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [esp + 0x2c], eax
cmp eax, 0xffffffff
jne 0x10005c76
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x10005d34
mov ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x24]
mov esi, dword [esp + 0xc]
lea eax, [esp + 0xc]
lea edx, [edx + ecx]
push eax
lea ecx, [esp + 0x30]
mov dword [esp + 0x10], esi
call fcn.10001eb0
add esp, 4
test eax, eax
jne 0x10005ca4
cmp dword [esp + 0xc], esi
je 0x10005cab
mov edi, 0xb
jmp 0x10005caf
mov edi, dword [esp + 0x14]
mov ecx, dword [esp + 0x1c]
mov esi, dword [esp + 0x2c]
cmp byte [ecx + 0x1c], 0
je 0x10005ce3
mov eax, dword [ecx]
mov dword [esp + 0x40d8], eax
mov eax, dword [ecx + 4]
mov dword [esp + 0x40dc], eax
lea eax, [esp + 0x40d8]
push eax
push 0
push 0
push esi
call dword [sym.imp.KERNEL32.dll_SetFileTime]
cmp esi, 0xffffffff
je 0x10005cfb
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
jne 0x10005cfb
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x10005cfd
xor eax, eax
test edi, edi
jne 0x10005d39
test eax, eax
jne 0x10005d29
mov eax, dword [esp + 0x1c]
cmp byte [eax + 0x1d], 0
je 0x10005bfd
push dword [eax + 0x14]
lea eax, [esp + 0x4334]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
jmp 0x10005bfd
mov edi, eax
jmp 0x10005d39
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
mov edi, 0xb
push dword [esp + 0x20]
lea eax, [esp + 0x94]
push eax
call dword [esp + 0x9c]
add esp, 8
push dword [esp + 0x70]
lea eax, [esp + 0x94]
push eax
call dword [esp + 0x9c]
push dword [esp + 0x7c]
lea eax, [esp + 0x9c]
push eax
call dword [esp + 0xa4]
push dword [esp + 0x88]
lea eax, [esp + 0xa4]
push eax
call dword [esp + 0xac]
push dword [esp + 0x94]
lea eax, [esp + 0xac]
push eax
call dword [esp + 0xb4]
push dword [esp + 0xa0]
lea eax, [esp + 0xb4]
push eax
call dword [esp + 0xbc]
push dword [esp + 0xac]
lea eax, [esp + 0xbc]
push eax
call dword [esp + 0xc4]
add esp, 0x30
lea edx, [esp + 0x90]
lea ecx, [esp + 0x40]
mov dword [esp + 0x84], 0
mov dword [esp + 0x88], 0
call fcn.10002200
test edi, edi
jne 0x10005e29
lea eax, [esp + 0x4330]
push eax
push dword [ebp + 0x14]
push dword [esp + 0x18]
call dword [sym.imp.MSVCR110.dll_wcscpy_s]
add esp, 0xc
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x4948]
xor ecx, esp
call fcn.100947be
mov esp, ebp
pop ebp
ret
mov ecx, dword [esp + 0x4954]
pop edi
pop esi
pop ebx
xor ecx, esp
mov eax, 1
call fcn.100947be
mov esp, ebp
pop ebp
ret