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

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x423c
call fcn.00514e70
mov eax, dword [0x590090]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x14]
push ebx
mov ebx, dword [ebp + 0xc]
push esi
mov esi, ecx
mov dword [ebp - 0x423c], ebx
cmp eax, 4
jne 0x407928
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
xor eax, eax
jmp 0x407bde
push edi
cmp eax, 3
je 0x407962
cmp eax, 2
je 0x407938
cmp eax, 1
jne 0x407958
cmp dword [esi + 4], 0xffffffff
je 0x407946
push dword [esi]
call fcn.00405eb4
pop ecx
mov eax, dword [esi]
mov edi, dword [ebp + 8]
or dword [esi + 4], 0xffffffff
cmp edi, dword [eax + 4]
jl 0x4079e1
mov eax, 0x10000
jmp 0x407bdd
mov eax, dword [esi + 4]
mov edi, dword [ebp + 8]
cmp edi, eax
je 0x4079a8
cmp eax, 0xffffffff
je 0x407979
push dword [esi]
call fcn.00405eb4
pop ecx
mov eax, dword [esi]
or dword [esi + 4], 0xffffffff
cmp edi, dword [eax + 4]
jge 0x407958
cmp edi, dword [eax + 0x10]
jge 0x407997
push eax
call fcn.00405c70
jmp 0x407996
call fcn.00405cb1
pop ecx
mov eax, dword [esi]
push eax
cmp dword [eax + 0x10], edi
jl 0x407991
call fcn.004075fe
pop ecx
mov dword [esi + 4], edi
push dword [ebp + 0x10]
push ebx
push dword [esi]
call fcn.004076ef
mov edi, eax
add esp, 0xc
test edi, edi
jle 0x4079c6
mov eax, 0x600
jmp 0x407bdd
push dword [esi]
call fcn.00405eb4
or dword [esi + 4], 0xffffffff
mov eax, edi
neg eax
sbb eax, eax
and eax, 0x5000000
jmp 0x407bdc
cmp edi, dword [eax + 0x10]
jge 0x4079f6
push eax
call fcn.00405c70
jmp 0x4079f5
push dword [esi]
call fcn.00405cb1
pop ecx
mov eax, dword [esi]
cmp dword [eax + 0x10], edi
jl 0x4079ee
lea eax, [ebp - 0x4234]
push eax
push edi
mov ecx, esi
call fcn.00405f97
test byte [ebp - 0x412c], 0x10
je 0x407a3d
cmp dword [ebp + 0x14], 1
jne 0x407a22
xor eax, eax
jmp 0x407bdd
lea eax, [ebp - 0x4230]
push eax
add esi, 0x138
push esi
call fcn.0040636e
pop ecx
xor eax, eax
jmp 0x407bdc
cmp dword [ebp + 0x14], 1
je 0x407b16
mov al, byte [ebx]
mov edi, ebx
mov ecx, ebx
test al, al
je 0x407afb
cmp al, 0x2f
je 0x407a5d
cmp al, 0x5c
jne 0x407a60
lea edi, [ecx + 1]
inc ecx
mov al, byte [ecx]
test al, al
jne 0x407a55
cmp edi, ebx
je 0x407afb
lea eax, [ebp - 0x108]
push ebx
push eax
call fcn.005158d0
sub edi, ebx
pop ecx
mov byte [ebp + edi - 0x109], 0
cmp byte [ebp - 0x108], 0x2f
pop ecx
je 0x407aa7
cmp byte [ebp - 0x108], 0x5c
je 0x407aa7
cmp byte [ebp - 0x107], 0x3a
je 0x407aa7
xor bl, bl
jmp 0x407aa9
mov bl, 1
lea eax, [ebp - 0x108]
push 0x541b58
push eax
call fcn.005154b1
mov edi, eax
lea eax, [ebp - 0x108]
push 0x541b54
push eax
call fcn.005154b1
add esp, 0x10
test eax, eax
setne al
test edi, edi
setne cl
or al, cl
or al, bl
jne 0x407af5
lea eax, [ebp - 0x108]
push eax
lea eax, [esi + 0x138]
push eax
call fcn.0040636e
pop ecx
pop ecx
mov ebx, dword [ebp - 0x423c]
xor eax, eax
push eax
push dword [ebp - 0x412c]
push 2
push eax
push eax
push 0x40000000
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x407b25
mov eax, 0x200
jmp 0x407bdd
push dword [esi]
call fcn.004075fe
mov edi, 0x4000
push edi
lea eax, [ebp - 0x4108]
push eax
push dword [esi]
mov byte [ebp - 0x4235], 0
call fcn.004076ef
add esp, 0x10
jmp 0x407b7c
je 0x407b87
push 0
lea ecx, [ebp - 0x423c]
push ecx
push eax
lea eax, [ebp - 0x4108]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x407b80
push edi
lea eax, [ebp - 0x4108]
push eax
push dword [esi]
call fcn.004076ef
add esp, 0xc
test eax, eax
jns 0x407b4c
mov byte [ebp - 0x4235], 1
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileType]
cmp eax, 1
jne 0x407bb8
cmp byte [ebp - 0x4235], 0
jne 0x407bb8
lea eax, [ebp - 0x4118]
push eax
lea eax, [ebp - 0x4128]
push eax
lea eax, [ebp - 0x4120]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SetFileTime]
cmp dword [ebp + 0x14], 1
je 0x407bc5
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [esi]
call fcn.00405eb4
movzx eax, byte [ebp - 0x4235]
neg eax
sbb eax, eax
and eax, 0x400
pop ecx
pop edi
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.005122fd
leave
ret 0x10