Function at 0x41ac8d
Capabilities:
Delete file
Get common file path
Get file attributes
Move file
Set file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x4584
call fcn.0041ee00
push ebx
push esi
mov dword [ebp - 0x4580], ecx
cmp dword [ebp + 0x14], 3
je 0x41acbe
cmp dword [ebp + 0x14], 2
je 0x41acbe
cmp dword [ebp + 0x14], 1
je 0x41acbe
mov eax, 0x10000
jmp 0x41b2ef
cmp dword [ebp + 0x14], 3
jne 0x41ade9
mov eax, dword [ebp - 0x4580]
mov ecx, dword [ebp + 8]
cmp ecx, dword [eax + 4]
je 0x41ad7f
mov edx, dword [ebp - 0x4580]
cmp dword [edx + 4], 0xffffffff
je 0x41acf7
mov eax, dword [ebp - 0x4580]
mov ecx, dword [eax]
push ecx
call fcn.00419fa7
add esp, 4
mov edx, dword [ebp - 0x4580]
mov dword [edx + 4], 0xffffffff
mov eax, dword [ebp - 0x4580]
mov ecx, dword [eax]
mov edx, dword [ebp + 8]
cmp edx, dword [ecx + 4]
jl 0x41ad1e
mov eax, 0x10000
jmp 0x41b2ef
mov eax, dword [ebp - 0x4580]
mov ecx, dword [eax]
mov edx, dword [ebp + 8]
cmp edx, dword [ecx + 0x10]
jge 0x41ad3f
mov eax, dword [ebp - 0x4580]
mov ecx, dword [eax]
push ecx
call fcn.004194e3
add esp, 4
mov edx, dword [ebp - 0x4580]
mov eax, dword [edx]
mov ecx, dword [eax + 0x10]
cmp ecx, dword [ebp + 8]
jge 0x41ad62
mov edx, dword [ebp - 0x4580]
mov eax, dword [edx]
push eax
call fcn.00419551
add esp, 4
jmp 0x41ad3f
mov ecx, dword [ebp - 0x4580]
mov edx, dword [ecx]
push edx
call fcn.004199b0
add esp, 4
mov eax, dword [ebp - 0x4580]
mov ecx, dword [ebp + 8]
mov dword [eax + 4], ecx
mov edx, dword [ebp + 0x10]
push edx
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp - 0x4580]
mov edx, dword [ecx]
push edx
call fcn.00419b72
add esp, 0xc
mov dword [ebp - 0x4140], eax
cmp dword [ebp - 0x4140], 0
jle 0x41adb1
mov eax, 0x600
jmp 0x41b2ef
mov eax, dword [ebp - 0x4580]
mov ecx, dword [eax]
push ecx
call fcn.00419fa7
add esp, 4
mov edx, dword [ebp - 0x4580]
mov dword [edx + 4], 0xffffffff
cmp dword [ebp - 0x4140], 0
jne 0x41addf
xor eax, eax
jmp 0x41b2ef
mov eax, 0x5000000
jmp 0x41b2ef
mov eax, dword [ebp - 0x4580]
cmp dword [eax + 4], 0xffffffff
je 0x41ae06
mov ecx, dword [ebp - 0x4580]
mov edx, dword [ecx]
push edx
call fcn.00419fa7
add esp, 4
mov eax, dword [ebp - 0x4580]
mov dword [eax + 4], 0xffffffff
mov ecx, dword [ebp - 0x4580]
mov edx, dword [ecx]
mov eax, dword [ebp + 8]
cmp eax, dword [edx + 4]
jl 0x41ae2d
mov eax, 0x10000
jmp 0x41b2ef
mov ecx, dword [ebp - 0x4580]
mov edx, dword [ecx]
mov eax, dword [ebp + 8]
cmp eax, dword [edx + 0x10]
jge 0x41ae4e
mov ecx, dword [ebp - 0x4580]
mov edx, dword [ecx]
push edx
call fcn.004194e3
add esp, 4
mov eax, dword [ebp - 0x4580]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x10]
cmp edx, dword [ebp + 8]
jge 0x41ae71
mov eax, dword [ebp - 0x4580]
mov ecx, dword [eax]
push ecx
call fcn.00419551
add esp, 4
jmp 0x41ae4e
push 0x12c
push 0
lea edx, [ebp - 0x412c]
push edx
call sub.MSVCRT.dll_memset
add esp, 0xc
lea eax, [ebp - 0x412c]
push eax
mov ecx, dword [ebp + 8]
push ecx
mov ecx, dword [ebp - 0x4580]
call fcn.0041a24c
mov edx, dword [ebp - 0x4024]
and edx, 0x10
test edx, edx
je 0x41aeda
cmp dword [ebp + 0x14], 1
jne 0x41aeb7
xor eax, eax
jmp 0x41b2ef
lea eax, [ebp - 0x4128]
push eax
mov ecx, dword [ebp - 0x4580]
add ecx, 0x138
push ecx
call fcn.0041a9bf
add esp, 8
xor eax, eax
jmp 0x41b2ef
cmp dword [ebp + 0x14], 1
jne 0x41aeee
mov edx, dword [ebp + 0xc]
mov dword [ebp - 0x4134], edx
jmp 0x41b19e
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x4358], eax
mov ecx, dword [ebp - 0x4358]
mov dword [ebp - 0x434c], ecx
mov edx, dword [ebp - 0x434c]
movsx eax, byte [edx]
test eax, eax
je 0x41af4c
mov ecx, dword [ebp - 0x434c]
movsx edx, byte [ecx]
cmp edx, 0x2f
je 0x41af2c
mov eax, dword [ebp - 0x434c]
movsx ecx, byte [eax]
cmp ecx, 0x5c
jne 0x41af3b
mov edx, dword [ebp - 0x434c]
add edx, 1
mov dword [ebp - 0x4358], edx
mov eax, dword [ebp - 0x434c]
add eax, 1
mov dword [ebp - 0x434c], eax
jmp 0x41af03
mov ecx, dword [ebp - 0x4358]
cmp ecx, dword [ebp + 0xc]
je 0x41b03d
mov edx, dword [ebp + 0xc]
push edx
lea eax, [ebp - 0x4460]
push eax
call sub.MSVCRT.dll_strcpy
add esp, 8
mov ecx, dword [ebp - 0x4358]
sub ecx, dword [ebp + 0xc]
mov byte [ebp + ecx - 0x4461], 0
movsx edx, byte [ebp - 0x4460]
cmp edx, 0x2f
je 0x41afaf
movsx eax, byte [ebp - 0x4460]
cmp eax, 0x5c
je 0x41afaf
movsx ecx, byte [ebp - 0x445f]
cmp ecx, 0x3a
je 0x41afaf
mov dword [ebp - 0x4584], 0
jmp 0x41afb9
mov dword [ebp - 0x4584], 1
mov dl, byte [ebp - 0x4584]
mov byte [ebp - 0x435c], dl
mov ebx, dword [ebp - 0x435c]
and ebx, 0xff
push 0x428718
lea eax, [ebp - 0x4460]
push eax
call fcn.0041baf0
add esp, 8
mov esi, eax
neg esi
sbb esi, esi
neg esi
push 0x42871c
lea ecx, [ebp - 0x4460]
push ecx
call fcn.0041baf0
add esp, 8
neg eax
sbb eax, eax
neg eax
or esi, eax
or ebx, esi
mov byte [ebp - 0x435c], bl
mov edx, dword [ebp - 0x435c]
and edx, 0xff
test edx, edx
jne 0x41b03d
lea eax, [ebp - 0x4460]
push eax
mov ecx, dword [ebp - 0x4580]
add ecx, 0x138
push ecx
call fcn.0041a9bf
add esp, 8
mov edx, dword [ebp + 0xc]
push edx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
and eax, 1
test eax, eax
je 0x41b069
mov dword [ebp - 0x4464], 0x80
mov eax, dword [ebp - 0x4464]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov dword [ebp - 0x4354], 0x104
lea edx, [ebp - 0x4244]
push edx
mov eax, dword [ebp - 0x4354]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
jne 0x41b0f1
call dword [sym.imp.MSVCRT.dll_rand]
mov dword [ebp - 0x4468], eax
call dword [sym.imp.MSVCRT.dll_rand]
mov dword [ebp - 0x446c], eax
mov edx, dword [ebp - 0x446c]
push edx
mov eax, dword [ebp - 0x4468]
push eax
push 0x428720
lea ecx, [ebp - 0x4570]
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0x10
lea edx, [ebp - 0x4570]
push edx
mov eax, dword [ebp + 0xc]
push eax
call dword [sym.imp.MSVCRT.dll_rename]
add esp, 8
lea ecx, [ebp - 0x4570]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov edx, dword [ebp + 0xc]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov eax, dword [ebp - 0x4024]
and eax, 1
test eax, eax
je 0x41b117
mov ecx, dword [ebp - 0x4024]
and ecx, 0xfffffffe
mov dword [ebp - 0x4024], ecx
push 0x5c
mov edx, dword [ebp + 0xc]
push edx
call dword [sym.imp.MSVCRT.dll_strrchr]
add esp, 8
mov dword [ebp - 0x4350], eax
cmp dword [ebp - 0x4350], 0
je 0x41b17a
push 0x104
push 0
lea eax, [ebp - 0x4348]
push eax
call sub.MSVCRT.dll_memset
add esp, 0xc
mov ecx, dword [ebp - 0x4350]
sub ecx, dword [ebp + 0xc]
add ecx, 1
push ecx
mov edx, dword [ebp + 0xc]
push edx
lea eax, [ebp - 0x4348]
push eax
call sub.MSVCRT.dll_memcpy
add esp, 0xc
lea ecx, [ebp - 0x4348]
push ecx
call fcn.0041aac3
add esp, 4
push 0
mov edx, dword [ebp - 0x4024]
push edx
push 2
push 0
push 0
push 0x40000000
mov eax, dword [ebp + 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov dword [ebp - 0x4134], eax
cmp dword [ebp - 0x4134], 0xffffffff
jne 0x41b1b1
mov eax, 0x200
jmp 0x41b2ef
mov ecx, dword [ebp - 0x4580]
mov edx, dword [ecx]
push edx
call fcn.004199b0
add esp, 4
mov byte [ebp - 0x4138], 0
push 0x4000
lea eax, [ebp - 0x4000]
push eax
mov ecx, dword [ebp - 0x4580]
mov edx, dword [ecx]
push edx
call fcn.00419b72
add esp, 0xc
mov dword [ebp - 0x4574], eax
cmp dword [ebp - 0x4574], 0
jge 0x41b1fe
mov byte [ebp - 0x4138], 1
jmp 0x41b247
cmp dword [ebp - 0x4574], 0
jne 0x41b209
jmp 0x41b247
push 0
lea eax, [ebp - 0x4578]
push eax
mov ecx, dword [ebp - 0x4574]
push ecx
lea edx, [ebp - 0x4000]
push edx
mov eax, dword [ebp - 0x4134]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [ebp - 0x457c], eax
cmp dword [ebp - 0x457c], 0
jne 0x41b245
mov byte [ebp - 0x4138], 1
jmp 0x41b247
jmp 0x41b1c9
mov byte [ebp - 0x413c], 0
mov ecx, dword [ebp - 0x4134]
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileType]
mov dword [ebp - 0x4130], eax
cmp dword [ebp - 0x4130], 1
jne 0x41b281
mov edx, dword [ebp - 0x4138]
and edx, 0xff
test edx, edx
jne 0x41b281
mov byte [ebp - 0x413c], 1
mov eax, dword [ebp - 0x413c]
and eax, 0xff
test eax, eax
je 0x41b2b2
lea ecx, [ebp - 0x4010]
push ecx
lea edx, [ebp - 0x4020]
push edx
lea eax, [ebp - 0x4018]
push eax
mov ecx, dword [ebp - 0x4134]
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileTime]
cmp dword [ebp + 0x14], 1
je 0x41b2c5
mov edx, dword [ebp - 0x4134]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x4580]
mov ecx, dword [eax]
push ecx
call fcn.00419fa7
add esp, 4
mov edx, dword [ebp - 0x4138]
and edx, 0xff
test edx, edx
je 0x41b2ed
mov eax, 0x400
jmp 0x41b2ef
xor eax, eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10