Function at 0x4fd190
Capabilities:
Check if file exists
Read file on windows
Set file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x50c276
mov eax, dword fs:[0]
push eax
sub esp, 0xc8
mov eax, dword [0x531304]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0xc0], 0
mov dword [ebp - 0x5c], 0
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecA]
push 0x51e938
push 0x104
mov ecx, dword [ebp + 8]
push ecx
call fcn.004189df
add esp, 0xc
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
jne 0x4fd202
mov eax, dword [ebp - 0x5c]
jmp 0x4fd50f
push 0x7c
call fcn.00418aea
add esp, 4
mov dword [ebp - 0x88], eax
mov dword [ebp - 4], 0
cmp dword [ebp - 0x88], 0
je 0x4fd245
lea eax, [ebp - 0x8c]
push eax
call fcn.004eee80
add esp, 4
push eax
mov ecx, dword [ebp - 0x88]
call fcn.004ef190
mov dword [ebp - 0xc4], eax
jmp 0x4fd24f
mov dword [ebp - 0xc4], 0
mov ecx, dword [ebp - 0xc4]
mov dword [ebp - 0x84], ecx
mov dword [ebp - 4], 0xffffffff
mov edx, dword [ebp - 0x84]
mov dword [ebp - 0x64], edx
push 0
lea ecx, [ebp - 0x54]
call fcn.004ebad0
mov dword [ebp - 4], 1
lea ecx, [ebp - 0x34]
call fcn.004e7500
mov byte [ebp - 4], 2
push 0x51e94c
mov eax, dword [ebp + 8]
push eax
call fcn.0041625a
add esp, 8
mov dword [ebp - 0x38], eax
push 2
push 0
mov ecx, dword [ebp - 0x38]
push ecx
call fcn.00416afd
add esp, 0xc
mov edx, dword [ebp - 0x38]
push edx
call fcn.004169d3
add esp, 4
mov dword [ebp - 0x58], eax
push 0
push 0
mov eax, dword [ebp - 0x38]
push eax
call fcn.00416afd
add esp, 0xc
mov ecx, dword [ebp - 0x58]
add ecx, 1
push ecx
call fcn.00415d52
add esp, 4
mov dword [ebp - 0x60], eax
mov edx, dword [ebp - 0x38]
push edx
mov eax, dword [ebp - 0x58]
push eax
push 1
mov ecx, dword [ebp - 0x60]
push ecx
call fcn.0041651a
add esp, 0x10
mov edx, dword [ebp - 0x60]
add edx, dword [ebp - 0x58]
mov byte [edx], 0
mov eax, dword [ebp - 0x38]
push eax
call fcn.00416bf5
add esp, 4
cmp dword [ebp - 0x58], 0x64
jle 0x4fd37b
push 0x51e950
mov ecx, dword [ebp - 0x60]
push ecx
call fcn.00401000
add esp, 8
test eax, eax
je 0x4fd37b
push 0x51e954
mov edx, dword [ebp - 0x60]
push edx
call fcn.00401000
add esp, 8
push eax
lea ecx, [ebp - 0xac]
call fcn.00401e20
mov byte [ebp - 4], 3
mov eax, dword [ebp - 0xc0]
or eax, 1
mov dword [ebp - 0xc0], eax
push 1
lea ecx, [ebp - 0x54]
push ecx
lea edx, [ebp - 0xac]
push edx
mov ecx, dword [ebp - 0x64]
call fcn.004f3df0
movzx eax, al
test eax, eax
je 0x4fd37b
mov dword [ebp - 0xc8], 1
jmp 0x4fd385
mov dword [ebp - 0xc8], 0
mov cl, byte [ebp - 0xc8]
mov byte [ebp - 0x8d], cl
mov dword [ebp - 4], 2
mov edx, dword [ebp - 0xc0]
and edx, 1
je 0x4fd3b5
and dword [ebp - 0xc0], 0xfffffffe
lea ecx, [ebp - 0xac]
call fcn.00401260
movzx eax, byte [ebp - 0x8d]
test eax, eax
je 0x4fd49c
sub esp, 0x18
mov ecx, esp
mov dword [ebp - 0xb0], esp
push 0
call fcn.004eac00
mov dword [ebp - 0xcc], eax
mov ecx, dword [ebp - 0xcc]
mov dword [ebp - 0xd0], ecx
mov byte [ebp - 4], 4
push 0x51e960
push 0x51e958
lea ecx, [ebp - 0x54]
call fcn.004ee360
mov ecx, eax
call fcn.004ee360
mov byte [ebp - 4], 2
mov ecx, eax
call fcn.004eb520
lea edx, [ebp - 0x54]
push edx
lea eax, [ebp - 0x80]
push eax
lea ecx, [ebp - 0x34]
call fcn.004ea3e0
mov byte [ebp - 4], 5
push 0x80
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push 0x51e974
mov edx, dword [ebp + 8]
push edx
call fcn.0041625a
add esp, 8
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 0x38]
push eax
push 1
lea ecx, [ebp - 0x80]
call fcn.004012e0
push eax
call fcn.00415e20
add esp, 4
push eax
lea ecx, [ebp - 0x80]
call fcn.004012e0
push eax
call fcn.004167ae
add esp, 0x10
mov ecx, dword [ebp - 0x38]
push ecx
call fcn.00416bf5
add esp, 4
push 0x51e978
call fcn.004e4170
add esp, 4
mov dword [ebp - 0x5c], 1
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x80]
call fcn.00401260
mov edx, dword [ebp - 0x64]
mov dword [ebp - 0xb8], edx
mov eax, dword [ebp - 0xb8]
mov dword [ebp - 0xb4], eax
cmp dword [ebp - 0xb4], 0
je 0x4fd4cf
push 1
mov ecx, dword [ebp - 0xb4]
call fcn.00413240
mov dword [ebp - 0xd4], eax
jmp 0x4fd4d9
mov dword [ebp - 0xd4], 0
mov ecx, dword [ebp - 0x60]
push ecx
call fcn.00415c75
add esp, 4
mov edx, dword [ebp - 0x5c]
mov dword [ebp - 0xbc], edx
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x34]
call fcn.00410630
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x54]
call fcn.004eb3f0
mov eax, dword [ebp - 0xbc]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004158f4
mov esp, ebp
pop ebp
ret