Function at 0x18004c1c0
Capabilities:
Delete file
Get file size
Read file on windows
Write file on windows

Disassembly:
mov rax, rsp
push rbp
push rdi
push r12
push r14
push r15
lea rbp, [rax - 0x5f]
sub rsp, 0xc0
mov qword [rbp - 0x19], 0xfffffffffffffffe
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
mov rax, qword [0x1801b8080]
xor rax, rsp
mov qword [rbp + 0x2f], rax
movzx edi, dl
mov rbx, rcx
xor r12d, r12d
mov dword [rbp - 0x29], r12d
test dl, dl
je 0x18004c21e
mov rcx, qword [rcx + 0xe8]
test rcx, rcx
je 0x18004c21e
mov rax, qword [rcx]
mov rdx, qword [rbx + 0xf0]
call qword [rax + 8]
mov edx, 8
lea rcx, [rbp - 0x21]
call fcn.18001cd30
lea rdx, [rbx + 8]
lea rcx, [rbp - 0x21]
call fcn.18001b730
nop
test dil, dil
je 0x18004c4cb
xorps xmm0, xmm0
movdqu xmmword [rbp - 0x39], xmm0
xor r8d, r8d
xor edx, edx
call fcn.18004c8f0
mov rdx, rax
mov qword [rbp - 0x39], rax
lea rcx, [rbx + 0x20]
lea rax, [rbp - 0x39]
cmp rcx, rax
je 0x18004c281
mov rax, qword [rcx]
mov qword [rcx], rdx
mov qword [rbp - 0x39], rax
add rcx, 8
lea rdx, [rbp - 0x31]
call fcn.18001f000
nop
lea rcx, [rbp - 0x39]
call fcn.18004c7d0
nop
mov edx, 0x88
mov rcx, qword [rbp - 0x39]
call fcn.1800ece80
nop
lea rdx, [rbx + 0x40]
lea rcx, [rbp - 9]
call fcn.18000cb60
mov r15d, 1
mov dword [rbp - 0x29], r15d
cmp dword [rbx + 0x38], 0
jbe 0x18004c470
cmp qword [rbp + 7], 0
je 0x18004c470
lea rcx, [rbp - 9]
cmp qword [rbp + 0xf], 8
cmovae rcx, qword [rbp - 9]
mov qword [rsp + 0x30], r12
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 4
xor r9d, r9d
xor r8d, r8d
mov edx, 0xc0000000
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rdi, rax
lea rcx, [rax - 1]
cmp rcx, 0xfffffffffffffffd
ja 0x18004c470
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
mov edx, dword [rbx + 0x38]
cmp eax, edx
sete r14b
jbe 0x18004c42f
xor r9d, r9d
xor r8d, r8d
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
sub esi, dword [rbx + 0x38]
mov dword [rbp - 0x11], r12d
xor eax, eax
mov qword [rbp + 0x17], rax
mov qword [rbp + 0x1f], rax
mov qword [rbp + 0x27], rax
xorps xmm0, xmm0
movdqu xmmword [rbp + 0x17], xmm0
mov qword [rbp + 0x27], r12
mov byte [rbp - 0x49], al
lea rax, [rbp + 0x17]
mov qword [rbp - 0x39], rax
lea rax, [rbp - 0x49]
mov qword [rbp - 0x31], rax
movaps xmm0, xmmword [rbp - 0x39]
movdqa xmmword [rbp - 0x39], xmm0
mov edx, esi
lea r8, [rbp - 0x39]
lea rcx, [rbp + 0x17]
call fcn.18004c9e0
mov qword [rsp + 0x20], r12
lea r9, [rbp - 0x11]
mov r8d, esi
mov rdx, qword [rbp + 0x17]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x18004c3e6
cmp dword [rbp - 0x11], esi
jne 0x18004c3e6
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov dword [rbp - 0xd], r12d
mov qword [rsp + 0x20], r12
lea r9, [rbp - 0xd]
mov r8d, esi
mov rdx, qword [rbp + 0x17]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x18004c3e6
cmp dword [rbp - 0xd], esi
jne 0x18004c3e9
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
jmp 0x18004c3e9
mov r14b, 1
mov rcx, qword [rbp + 0x17]
test rcx, rcx
je 0x18004c42f
mov rdx, qword [rbp + 0x27]
sub rdx, rcx
mov rax, rcx
cmp rdx, 0x1000
jb 0x18004c41e
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x18004c5f8
call fcn.1800ece80
xorps xmm0, xmm0
movdqu xmmword [rbp + 0x17], xmm0
mov qword [rbp + 0x27], r12
test r14b, r14b
je 0x18004c44e
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test r14b, r14b
je 0x18004c470
lea rcx, [rbp - 9]
cmp qword [rbp + 0xf], 8
cmovae rcx, qword [rbp - 9]
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
and r15d, 0xfffffffe
mov dword [rbp - 0x29], r15d
mov rdx, qword [rbp + 0xf]
cmp rdx, 8
jb 0x18004c4b8
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 9]
mov rax, rcx
cmp rdx, 0x1000
jb 0x18004c4b3
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x18004c5fe
call fcn.1800ece80
mov qword [rbp + 7], r12
mov qword [rbp + 0xf], 7
mov word [rbp - 9], r12w
jmp 0x18004c53a
cmp qword [rbx + 0x28], 0
je 0x18004c53a
lea rcx, [rbx + 0x10]
mov rdx, qword [rcx]
lea rdi, [rbx + 0x20]
mov r9, qword [rdi]
mov r8, qword [r9]
call fcn.18004cb40
xorps xmm0, xmm0
movdqu xmmword [rbp - 0x39], xmm0
xor r8d, r8d
xor edx, edx
call fcn.18004c8f0
mov rcx, rax
mov qword [rbp - 0x39], rax
lea rax, [rbp - 0x39]
cmp rdi, rax
je 0x18004c522
mov rax, qword [rdi]
mov qword [rdi], rcx
mov qword [rbp - 0x39], rax
lea rcx, [rdi + 8]
lea rdx, [rbp - 0x31]
call fcn.18001f000
nop
lea rcx, [rbp - 0x39]
call fcn.18004c7d0
nop
mov edx, 0x88
mov rcx, qword [rbp - 0x39]
call fcn.1800ece80
mov rcx, qword [rbx + 0x30]
test rcx, rcx
je 0x18004c5bd
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov qword [rbx + 0x30], r12
lea rdx, [rbp - 9]
mov rcx, rbx
call fcn.18004c710
nop
lea rcx, [rbp - 9]
cmp qword [rbp + 0xf], 8
cmovae rcx, qword [rbp - 9]
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
nop
mov rdx, qword [rbp + 0xf]
cmp rdx, 8
jb 0x18004c5ab
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 9]
mov rax, rcx
cmp rdx, 0x1000
jb 0x18004c5a6
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x18004c5f2
call fcn.1800ece80
movdqa xmm0, xmmword [0x18016e140]
movdqu xmmword [rbp + 7], xmm0
mov word [rbp - 9], r12w
mov dword [rbx + 0x38], r12d
lea rcx, [rbp - 0x21]
call fcn.18001b760
mov rcx, qword [rbp + 0x2f]
xor rcx, rsp
call fcn.1800ece20
lea r11, [rsp + 0xc0]
mov rbx, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r12
pop rdi
pop rbp
ret
call fcn.18010e944
nop
call fcn.18010e944
nop
call fcn.18010e944
int3