Function at 0x402824
Capabilities:
Create directory
Set file attributes
Timestomp file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffff30
mov eax, 0x45d7bc
push ebx
push esi
push edi
mov edi, dword [ebp + 0x10]
mov ebx, dword [ebp + 0x18]
mov esi, dword [ebp + 0xc]
call fcn.0045225c
mov dword [ebp - 0x44], 1
lea edx, [ebp + 0x14]
lea eax, [ebp + 0x14]
call fcn.0042e7fb
inc dword [ebp - 0x44]
mov word [ebp - 0x50], 8
cmp dword [ebx], 0
jne 0x402882
dec dword [ebp - 0x44]
lea eax, [ebp + 0x14]
mov edx, 2
call fcn.0042ea24
mov ecx, dword [ebp - 0x60]
mov dword fs:[0], ecx
jmp 0x403068
mov word [ebp - 0x50], 0x14
push edi
push esi
call fcn.00410d6c
add esp, 8
push eax
push 0x86
push 0x469e3c
call fcn.0041393c
add esp, 0xc
mov edx, eax
lea eax, [ebp - 4]
call fcn.0042e7c4
inc dword [ebp - 0x44]
mov edx, dword [eax]
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x300]
call fcn.0041f6dc
dec dword [ebp - 0x44]
lea eax, [ebp - 4]
mov edx, 2
call fcn.0042ea24
push edi
push esi
call fcn.00410d30
add esp, 8
test al, al
je 0x4028ff
dec dword [ebp - 0x44]
lea eax, [ebp + 0x14]
mov edx, 2
call fcn.0042ea24
mov ecx, dword [ebp - 0x60]
mov dword fs:[0], ecx
jmp 0x403068
push edi
push esi
call fcn.00410fb4
add esp, 8
test al, 8
je 0x40292c
dec dword [ebp - 0x44]
lea eax, [ebp + 0x14]
mov edx, 2
call fcn.0042ea24
mov ecx, dword [ebp - 0x60]
mov dword fs:[0], ecx
jmp 0x403068
push edi
push esi
call fcn.00410d6c
add esp, 8
movsx eax, byte [eax]
cmp eax, 0x2e
jne 0x40295d
dec dword [ebp - 0x44]
lea eax, [ebp + 0x14]
mov edx, 2
call fcn.0042ea24
mov ecx, dword [ebp - 0x60]
mov dword fs:[0], ecx
jmp 0x403068
push edi
push esi
call fcn.00410fb4
add esp, 8
test al, 0x10
je 0x402ad8
mov word [ebp - 0x50], 0x2c
mov edx, 0x45ebc9
lea eax, [ebp - 0x20]
call fcn.0042e7c4
inc dword [ebp - 0x44]
xor eax, eax
mov dword [ebp - 0x24], eax
lea eax, [ebp + 0x14]
inc dword [ebp - 0x44]
lea edx, [ebp - 0x20]
lea ecx, [ebp - 0x24]
call fcn.0042ea7b
lea edx, [ebp - 0x24]
push edx
push edi
push esi
call fcn.00410d6c
add esp, 8
mov edx, eax
lea eax, [ebp - 0x28]
call fcn.0042e7c4
inc dword [ebp - 0x44]
xor eax, eax
mov dword [ebp - 8], eax
lea edx, [ebp - 0x28]
inc dword [ebp - 0x44]
lea ecx, [ebp - 8]
pop eax
call fcn.0042ea7b
dec dword [ebp - 0x44]
lea eax, [ebp - 0x28]
mov edx, 2
call fcn.0042ea24
dec dword [ebp - 0x44]
lea eax, [ebp - 0x24]
mov edx, 2
call fcn.0042ea24
dec dword [ebp - 0x44]
lea eax, [ebp - 0x20]
mov edx, 2
call fcn.0042ea24
mov word [ebp - 0x50], 0x20
push 0
cmp dword [ebp - 8], 0
je 0x402a0d
mov ecx, dword [ebp - 8]
jmp 0x402a12
mov ecx, 0x45ebcb
push ecx
call sub.KERNEL32.dll_CreateDirectoryA
mov word [ebp - 0x50], 0x38
push edi
push esi
call fcn.0041109c
add esp, 8
push eax
mov eax, dword [ebp + 8]
mov edx, dword [eax + 0x2c0]
push edx
lea eax, [ebp - 0x1c]
push eax
call fcn.00410af4
add esp, 0xc
inc dword [ebp - 0x44]
mov word [ebp - 0x50], 0x20
lea edx, [ebp - 0x1c]
push edx
call fcn.00410b68
pop ecx
xor esi, esi
jmp 0x402aa4
push esi
lea eax, [ebp - 0x1c]
push eax
call fcn.00410d30
add esp, 8
test al, al
jne 0x402aa3
push esi
lea edx, [ebp - 0x1c]
push edx
call fcn.00410fb4
add esp, 8
test al, 8
jne 0x402aa3
push esi
lea ecx, [ebp - 0x1c]
push ecx
call fcn.00410d6c
add esp, 8
movsx eax, byte [eax]
cmp eax, 0x2e
je 0x402aa3
push ebx
lea ecx, [ebp - 0x1c]
mov edx, dword [ebp - 8]
push edx
push esi
push ecx
mov eax, dword [ebp + 8]
push eax
call fcn.00402824
add esp, 0x14
inc esi
lea edx, [ebp - 0x1c]
push edx
call fcn.00410c1c
pop ecx
cmp esi, eax
jl 0x402a56
dec dword [ebp - 0x44]
push 2
lea ecx, [ebp - 0x1c]
push ecx
call fcn.00410b44
add esp, 8
dec dword [ebp - 0x44]
lea eax, [ebp - 8]
mov edx, 2
call fcn.0042ea24
jmp 0x40304e
mov word [ebp - 0x50], 0x50
mov edx, 0x45ebcc
lea eax, [ebp - 0x30]
call fcn.0042e7c4
inc dword [ebp - 0x44]
xor eax, eax
mov dword [ebp - 0x34], eax
lea eax, [ebp + 0x14]
inc dword [ebp - 0x44]
lea edx, [ebp - 0x30]
lea ecx, [ebp - 0x34]
call fcn.0042ea7b
lea edx, [ebp - 0x34]
push edx
push edi
push esi
call fcn.00410d6c
add esp, 8
mov edx, eax
lea eax, [ebp - 0x38]
call fcn.0042e7c4
inc dword [ebp - 0x44]
xor eax, eax
mov dword [ebp - 0x2c], eax
lea edx, [ebp - 0x38]
inc dword [ebp - 0x44]
lea ecx, [ebp - 0x2c]
pop eax
call fcn.0042ea7b
dec dword [ebp - 0x44]
lea eax, [ebp - 0x38]
mov edx, 2
call fcn.0042ea24
dec dword [ebp - 0x44]
lea eax, [ebp - 0x34]
mov edx, 2
call fcn.0042ea24
dec dword [ebp - 0x44]
lea eax, [ebp - 0x30]
mov edx, 2
call fcn.0042ea24
mov word [ebp - 0x50], 0x44
mov eax, dword [ebp - 0x2c]
call fcn.0044b92c
test al, al
je 0x402da8
cmp dword [ebx], 4
jne 0x402bad
dec dword [ebp - 0x44]
lea eax, [ebp - 0x2c]
mov edx, 2
call fcn.0042ea24
dec dword [ebp - 0x44]
lea eax, [ebp + 0x14]
mov edx, 2
call fcn.0042ea24
mov ecx, dword [ebp - 0x60]
mov dword fs:[0], ecx
jmp 0x403068
cmp dword [ebx], 3
je 0x402d8d
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
cmp dword [ebp - 0x2c], 0
je 0x402bd3
mov eax, dword [ebp - 0x2c]
jmp 0x402bd8
mov eax, 0x45ebce
push eax
call sub.KERNEL32.dll_CreateFileA
mov dword [ebp - 0x64], eax
cmp dword [ebp - 0x64], 0xffffffff
jne 0x402c3a
cmp dword [ebp - 0x2c], 0
je 0x402bf2
mov edx, dword [ebp - 0x2c]
jmp 0x402bf7
mov edx, 0x45ebcf
push edx
push 0x6e
call fcn.00413580
add esp, 8
cmp dword [ebx], 0
sete al
and eax, 1
dec dword [ebp - 0x44]
lea eax, [ebp - 0x2c]
mov edx, 2
call fcn.0042ea24
dec dword [ebp - 0x44]
lea eax, [ebp + 0x14]
mov edx, 2
call fcn.0042ea24
mov ecx, dword [ebp - 0x60]
mov dword fs:[0], ecx
jmp 0x403068
lea eax, [ebp - 0x6c]
push eax
push 0
push 0
mov edx, dword [ebp - 0x64]
push edx
call sub.KERNEL32.dll_GetFileTime
lea ecx, [ebp - 0x74]
push ecx
lea eax, [ebp - 0x6c]
push eax
call sub.KERNEL32.dll_FileTimeToLocalFileTime
lea edx, [ebp - 0xb0]
push edx
lea ecx, [ebp - 0x74]
push ecx
call sub.KERNEL32.dll_FileTimeToSystemTime
mov eax, dword [ebp - 0x64]
push eax
call sub.KERNEL32.dll_CloseHandle
mov eax, 0x46218c
mov ecx, dword [ebp + 8]
mov dl, 1
call fcn.00411c24
mov dword [ebp - 0x78], eax
push edi
push esi
lea eax, [ebp - 0xc0]
push eax
call fcn.00410fe0
add esp, 0xc
lea edx, [ebp - 0xc0]
push edx
push edi
push esi
call fcn.00410d6c
add esp, 8
lea ecx, [ebp - 0xb0]
push eax
push ecx
cmp dword [ebp - 0x2c], 0
je 0x402cb8
mov eax, dword [ebp - 0x2c]
jmp 0x402cbd
mov eax, 0x45ebd0
push eax
mov edx, dword [ebp - 0x78]
push edx
call fcn.00411c7c
add esp, 0x14
mov dword [ebx], eax
mov ecx, dword [ebp - 0x78]
mov dword [ebp - 0x3c], ecx
cmp dword [ebp - 0x3c], 0
je 0x402cf1
mov word [ebp - 0x50], 0x68
mov edx, 3
mov eax, dword [ebp - 0x3c]
mov ecx, dword [eax]
call dword [ecx - 4]
mov word [ebp - 0x50], 0x5c
cmp dword [ebx], 0
jne 0x402d25
dec dword [ebp - 0x44]
lea eax, [ebp - 0x2c]
mov edx, 2
call fcn.0042ea24
dec dword [ebp - 0x44]
lea eax, [ebp + 0x14]
mov edx, 2
call fcn.0042ea24
mov ecx, dword [ebp - 0x60]
mov dword fs:[0], ecx
jmp 0x403068
cmp dword [ebx], 2
jne 0x402d59
dec dword [ebp - 0x44]
lea eax, [ebp - 0x2c]
mov edx, 2
call fcn.0042ea24
dec dword [ebp - 0x44]
lea eax, [ebp + 0x14]
mov edx, 2
call fcn.0042ea24
mov ecx, dword [ebp - 0x60]
mov dword fs:[0], ecx
jmp 0x403068
cmp dword [ebx], 4
jne 0x402d8d
dec dword [ebp - 0x44]
lea eax, [ebp - 0x2c]
mov edx, 2
call fcn.0042ea24
dec dword [ebp - 0x44]
lea eax, [ebp + 0x14]
mov edx, 2
call fcn.0042ea24
mov ecx, dword [ebp - 0x60]
mov dword fs:[0], ecx
jmp 0x403068
push 0x80
cmp dword [ebp - 0x2c], 0
je 0x402d9d
mov eax, dword [ebp - 0x2c]
jmp 0x402da2
mov eax, 0x45ebd1
push eax
call sub.KERNEL32.dll_SetFileAttributesA
mov dword [ebp - 0x7c], 0x80
mov word [ebp - 0x50], 0x44
push edi
push esi
call fcn.00410fb4
add esp, 8
test al, 0x20
je 0x402dc7
or dword [ebp - 0x7c], 0x20
test al, 1
je 0x402dcf
or dword [ebp - 0x7c], 1
test al, 2
je 0x402dd7
or dword [ebp - 0x7c], 2
test al, 4
je 0x402ddf
or dword [ebp - 0x7c], 4
push 0
mov edx, dword [ebp - 0x7c]
push edx
push 2
push 0
push 1
push 0x40000000
cmp dword [ebp - 0x2c], 0
je 0x402dfb
mov ecx, dword [ebp - 0x2c]
jmp 0x402e00
mov ecx, 0x45ebd2
push ecx
call sub.KERNEL32.dll_CreateFileA
mov dword [ebp - 0x80], eax
cmp dword [ebp - 0x80], 0xffffffff
jne 0x402e5d
cmp dword [ebp - 0x2c], 0
je 0x402e1a
mov eax, dword [ebp - 0x2c]
jmp 0x402e1f
mov eax, 0x45ebd3
push eax
push 0x6e
call fcn.00413580
add esp, 8
xor edx, edx
mov dword [ebx], edx
dec dword [ebp - 0x44]
lea eax, [ebp - 0x2c]
mov edx, 2
call fcn.0042ea24
dec dword [ebp - 0x44]
lea eax, [ebp + 0x14]
mov edx, 2
call fcn.0042ea24
mov ecx, dword [ebp - 0x60]
mov dword fs:[0], ecx
jmp 0x403068
push edi
push esi
call fcn.004110f0
add esp, 8
test eax, eax
je 0x402fda
push edi
push esi
call fcn.0041109c
add esp, 8
push eax
mov eax, dword [ebp + 8]
mov edx, dword [eax + 0x2c0]
push edx
call fcn.0040bbc8
add esp, 8
mov dword [ebp - 0x84], eax
cmp dword [ebp - 0x84], 0
jne 0x402ee9
cmp dword [ebp - 0x2c], 0
je 0x402ea6
mov ecx, dword [ebp - 0x2c]
jmp 0x402eab
mov ecx, 0x45ebd4
push ecx
push 0x73
call fcn.00413580
add esp, 8
xor eax, eax
mov dword [ebx], eax
dec dword [ebp - 0x44]
lea eax, [ebp - 0x2c]
mov edx, 2
call fcn.0042ea24
dec dword [ebp - 0x44]
lea eax, [ebp + 0x14]
mov edx, 2
call fcn.0042ea24
mov ecx, dword [ebp - 0x60]
mov dword fs:[0], ecx
jmp 0x403068
mov eax, dword [ebp + 8]
mov edx, dword [eax + 0x2c0]
mov ecx, dword [edx + 0x28]
push ecx
call fcn.00459ce0
pop ecx
mov dword [ebp - 0x88], eax
mov eax, dword [ebp - 0x84]
mov ebx, eax
jmp 0x402fa7
mov edx, dword [ebp - 0x88]
push edx
push eax
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x2c0]
push ecx
call fcn.0040bf2c
add esp, 0xc
cmp dword [ebx + 4], 0xfffffff
jne 0x402f7e
push edi
push esi
call fcn.004110f0
mov edx, dword [ebp + 8]
add esp, 8
mov ecx, dword [edx + 0x2c0]
xor edx, edx
div dword [ecx + 0x28]
mov word [ebp - 0x50], 0x44
mov eax, edx
lea ecx, [ebp - 0x8c]
push 0
push ecx
test eax, eax
jne 0x402f6b
mov eax, dword [ebp + 8]
mov edx, dword [eax + 0x2c0]
mov eax, dword [edx + 0x28]
push eax
mov edx, dword [ebp - 0x88]
push edx
mov ecx, dword [ebp - 0x80]
push ecx
call sub.KERNEL32.dll_WriteFile
jmp 0x402fa4
push 0
lea eax, [ebp - 0x90]
push eax
mov edx, dword [ebp + 8]
mov ecx, dword [edx + 0x2c0]
mov eax, dword [ecx + 0x28]
push eax
mov edx, dword [ebp - 0x88]
push edx
mov ecx, dword [ebp - 0x80]
push ecx
call sub.KERNEL32.dll_WriteFile
add ebx, 4
mov eax, dword [ebx]
cmp eax, 0xfffffff
jne 0x402f0f
mov edx, dword [ebp - 0x88]
push edx
call fcn.00459c88
pop ecx
mov ecx, dword [ebp - 0x84]
push ecx
mov eax, dword [ebp + 8]
mov edx, dword [eax + 0x2c0]
push edx
call fcn.0040bd4c
add esp, 8
push edi
push esi
lea ecx, [ebp - 0xd0]
push ecx
call fcn.00410fe0
add esp, 0xc
mov word [ebp - 0x50], 0x44
lea eax, [ebp - 0x98]
push eax
lea edx, [ebp - 0xd0]
push edx
call sub.KERNEL32.dll_SystemTimeToFileTime
lea ecx, [ebp - 0xa0]
push ecx
lea eax, [ebp - 0x98]
push eax
call sub.KERNEL32.dll_LocalFileTimeToFileTime
lea edx, [ebp - 0xa0]
push edx
lea ecx, [ebp - 0xa0]
push ecx
lea eax, [ebp - 0xa0]
push eax
mov edx, dword [ebp - 0x80]
push edx
call sub.KERNEL32.dll_SetFileTime
mov ecx, dword [ebp - 0x80]
push ecx
call sub.KERNEL32.dll_CloseHandle
dec dword [ebp - 0x44]
lea eax, [ebp - 0x2c]
mov edx, 2
call fcn.0042ea24
dec dword [ebp - 0x44]
lea eax, [ebp + 0x14]
mov edx, 2
call fcn.0042ea24
mov ecx, dword [ebp - 0x60]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret