Function at 0x4027cd
Capabilities:
Create directory
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x178
push esi
push edi
mov dword [ebp - 0x10c], 0
mov dword [ebp - 0x110], 0
mov dword [ebp - 0x11c], 0
push 0
push 0
push 0
push 0
push 0x100
lea eax, [ebp - 0x104]
push eax
lea ecx, [ebp - 0x16c]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.00403025
add esp, 0x20
mov dword [ebp - 0x10c], eax
cmp dword [ebp - 0x10c], 0
je 0x402837
mov eax, dword [ebp - 0x10c]
jmp 0x402ac1
mov dword [ebp - 0x118], 0x2000
mov eax, dword [ebp - 0x118]
push eax
call dword [sym.imp.MSVCRT.dll_malloc]
add esp, 4
mov dword [ebp - 0x108], eax
cmp dword [ebp - 0x108], 0
jne 0x40286a
mov eax, 0xffffff98
jmp 0x402ac1
lea ecx, [ebp - 0x104]
mov dword [ebp - 0x114], ecx
mov edx, dword [ebp - 0x114]
mov dword [ebp - 4], edx
mov eax, dword [ebp - 4]
movsx ecx, byte [eax]
test ecx, ecx
je 0x4028b6
mov edx, dword [ebp - 4]
movsx eax, byte [edx]
cmp eax, 0x2f
je 0x40289f
mov ecx, dword [ebp - 4]
movsx edx, byte [ecx]
cmp edx, 0x5c
jne 0x4028ab
mov eax, dword [ebp - 4]
add eax, 1
mov dword [ebp - 0x114], eax
mov ecx, dword [ebp - 4]
add ecx, 1
mov dword [ebp - 4], ecx
jmp 0x40287f
mov edx, dword [ebp - 0x114]
movsx eax, byte [edx]
test eax, eax
jne 0x4028e0
mov ecx, dword [ebp + 0xc]
cmp dword [ecx], 0
jne 0x4028db
lea edx, [ebp - 0x104]
push edx
call dword [sym.imp.MSVCRT.dll__mkdir]
add esp, 4
jmp 0x402aab
mov dword [ebp - 0x170], 0
mov eax, dword [ebp + 0xc]
cmp dword [eax], 0
jne 0x402900
lea ecx, [ebp - 0x104]
mov dword [ebp - 0x174], ecx
jmp 0x40290c
mov edx, dword [ebp - 0x114]
mov dword [ebp - 0x174], edx
mov eax, dword [ebp + 8]
push eax
call fcn.0040341b
add esp, 4
mov dword [ebp - 0x10c], eax
cmp dword [ebp - 0x170], 0
jne 0x4029c6
cmp dword [ebp - 0x10c], 0
jne 0x4029c6
push 0x4080c8
mov ecx, dword [ebp - 0x174]
push ecx
call dword [sym.imp.MSVCRT.dll_fopen]
add esp, 8
mov dword [ebp - 0x110], eax
cmp dword [ebp - 0x110], 0
jne 0x4029c6
mov edx, dword [ebp + 0xc]
cmp dword [edx], 0
jne 0x4029c6
mov eax, dword [ebp - 0x114]
lea ecx, [ebp - 0x104]
cmp eax, ecx
je 0x4029c6
mov edx, dword [ebp - 0x114]
mov al, byte [edx - 1]
mov byte [ebp - 0x178], al
mov ecx, dword [ebp - 0x114]
mov byte [ecx - 1], 0
mov edx, dword [ebp - 0x174]
push edx
call fcn.00402ac7
add esp, 4
mov eax, dword [ebp - 0x114]
mov cl, byte [ebp - 0x178]
mov byte [eax - 1], cl
push 0x4080cc
mov edx, dword [ebp - 0x174]
push edx
call dword [sym.imp.MSVCRT.dll_fopen]
add esp, 8
mov dword [ebp - 0x110], eax
cmp dword [ebp - 0x110], 0
je 0x402a82
mov eax, dword [ebp - 0x118]
push eax
mov ecx, dword [ebp - 0x108]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.004036c4
add esp, 0xc
mov dword [ebp - 0x10c], eax
cmp dword [ebp - 0x10c], 0
jge 0x4029fe
jmp 0x402a41
cmp dword [ebp - 0x10c], 0
jle 0x402a38
mov eax, dword [ebp - 0x110]
push eax
push 1
mov ecx, dword [ebp - 0x10c]
push ecx
mov edx, dword [ebp - 0x108]
push edx
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
cmp eax, 1
je 0x402a38
mov dword [ebp - 0x10c], 0xffffffff
jmp 0x402a41
cmp dword [ebp - 0x10c], 0
jg 0x4029d3
mov eax, dword [ebp - 0x110]
push eax
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
cmp dword [ebp - 0x10c], 0
jne 0x402a82
sub esp, 0x18
mov ecx, 6
lea esi, [ebp - 0x134]
mov edi, esp
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [ebp - 0x15c]
push ecx
mov edx, dword [ebp - 0x174]
push edx
call fcn.00402c00
add esp, 0x20
cmp dword [ebp - 0x10c], 0
jne 0x402a9f
mov eax, dword [ebp + 8]
push eax
call fcn.0040383a
add esp, 4
mov dword [ebp - 0x10c], eax
jmp 0x402aab
mov ecx, dword [ebp + 8]
push ecx
call fcn.0040383a
add esp, 4
mov edx, dword [ebp - 0x108]
push edx
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
mov eax, dword [ebp - 0x10c]
pop edi
pop esi
mov esp, ebp
pop ebp
ret