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

Disassembly:
jmp 0x14001a410
mov dword [rsp + 0x18], r8d
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
push rbp
push rdi
sub rsp, 0x248
lea rbp, [rsp + 0x40]
lea rdi, [rsp + 0x40]
mov ecx, 0x52
mov eax, 0xcccccccc
rep stosd dword [rdi], eax
mov rcx, qword [rsp + 0x268]
mov rax, qword [0x1400361b8]
xor rax, rbp
mov qword [rbp + 0x1f8], rax
lea rcx, [0x14003c45c]
call fcn.14001176c
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 3
xor r9d, r9d
xor r8d, r8d
mov edx, 0xc0000000
mov rcx, qword [rbp + 0x220]
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov qword [rbp + 8], rax
cmp qword [rbp + 8], 0xffffffffffffffff
jne 0x14001a4a6
xor eax, eax
jmp 0x14001a83a
xor edx, edx
mov rcx, qword [rbp + 8]
call qword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [rbp + 0x24], eax
mov eax, dword [rbp + 0x24]
mov ecx, eax
call fcn.140011334
mov qword [rbp + 0x1e8], rax
mov rax, qword [rbp + 0x1e8]
mov qword [rbp + 0x48], rax
mov qword [rsp + 0x20], 0
lea r9, [rbp + 0x64]
mov r8d, dword [rbp + 0x24]
mov rdx, qword [rbp + 0x48]
mov rcx, qword [rbp + 8]
call qword [sym.imp.KERNEL32.dll_ReadFile]
mov rax, qword [rbp + 0x48]
mov qword [rbp + 0x88], rax
mov rax, qword [rbp + 0x88]
movzx eax, word [rax]
cmp eax, 0x5a4d
je 0x14001a513
xor eax, eax
jmp 0x14001a83a
mov rax, qword [rbp + 0x88]
movsxd rax, dword [rax + 0x3c]
mov rcx, qword [rbp + 0x48]
add rcx, rax
mov rax, rcx
mov qword [rbp + 0xa8], rax
mov rax, qword [rbp + 0x88]
movsxd rax, dword [rax + 0x3c]
mov rcx, qword [rbp + 0x48]
lea rax, [rcx + rax + 4]
mov qword [rbp + 0xc8], rax
mov rax, qword [rbp + 0x88]
movsxd rax, dword [rax + 0x3c]
mov rcx, qword [rbp + 0x48]
lea rax, [rcx + rax + 0x18]
mov qword [rbp + 0xe8], rax
mov rax, qword [rbp + 0x88]
movsxd rax, dword [rax + 0x3c]
mov rcx, qword [rbp + 0x48]
lea rax, [rcx + rax + 0x108]
mov qword [rbp + 0x108], rax
mov rax, qword [rbp + 0xa8]
movzx eax, word [rax + 6]
cmp eax, 6
jg 0x14001a81d
mov rax, qword [rbp + 0xc8]
movzx eax, word [rax + 2]
imul rax, rax, 0x28
mov rcx, qword [rbp + 0x108]
add rcx, rax
mov rax, rcx
mov r8d, 0x28
xor edx, edx
mov rcx, rax
call fcn.1400115cd
mov rax, qword [rbp + 0xc8]
movzx eax, word [rax + 2]
imul rax, rax, 0x28
mov rcx, qword [rbp + 0x108]
add rcx, rax
mov rax, rcx
mov r8d, 8
mov rdx, qword [rbp + 0x228]
mov rcx, rax
call fcn.1400113c5
xor r8d, r8d
mov rax, qword [rbp + 0xe8]
mov edx, dword [rax + 0x20]
mov ecx, dword [rbp + 0x230]
call fcn.1400110be
mov rcx, qword [rbp + 0xc8]
movzx ecx, word [rcx + 2]
imul rcx, rcx, 0x28
mov rdx, qword [rbp + 0x108]
mov dword [rdx + rcx + 8], eax
mov rax, qword [rbp + 0xc8]
movzx eax, word [rax + 2]
dec eax
cdqe
imul rax, rax, 0x28
mov rcx, qword [rbp + 0xc8]
movzx ecx, word [rcx + 2]
dec ecx
movsxd rcx, ecx
imul rcx, rcx, 0x28
mov rdx, qword [rbp + 0x108]
mov r8d, dword [rdx + rax + 0xc]
mov rax, qword [rbp + 0xe8]
mov edx, dword [rax + 0x20]
mov rax, qword [rbp + 0x108]
mov ecx, dword [rax + rcx + 8]
call fcn.1400110be
mov rcx, qword [rbp + 0xc8]
movzx ecx, word [rcx + 2]
imul rcx, rcx, 0x28
mov rdx, qword [rbp + 0x108]
mov dword [rdx + rcx + 0xc], eax
xor r8d, r8d
mov rax, qword [rbp + 0xe8]
mov edx, dword [rax + 0x24]
mov ecx, dword [rbp + 0x230]
call fcn.1400110be
mov rcx, qword [rbp + 0xc8]
movzx ecx, word [rcx + 2]
imul rcx, rcx, 0x28
mov rdx, qword [rbp + 0x108]
mov dword [rdx + rcx + 0x10], eax
mov rax, qword [rbp + 0xc8]
movzx eax, word [rax + 2]
dec eax
cdqe
imul rax, rax, 0x28
mov rcx, qword [rbp + 0xc8]
movzx ecx, word [rcx + 2]
dec ecx
movsxd rcx, ecx
imul rcx, rcx, 0x28
mov rdx, qword [rbp + 0x108]
mov r8d, dword [rdx + rax + 0x14]
mov rax, qword [rbp + 0xe8]
mov edx, dword [rax + 0x24]
mov rax, qword [rbp + 0x108]
mov ecx, dword [rax + rcx + 0x10]
call fcn.1400110be
mov rcx, qword [rbp + 0xc8]
movzx ecx, word [rcx + 2]
imul rcx, rcx, 0x28
mov rdx, qword [rbp + 0x108]
mov dword [rdx + rcx + 0x14], eax
mov rax, qword [rbp + 0xc8]
movzx eax, word [rax + 2]
imul rax, rax, 0x28
mov rcx, qword [rbp + 0x108]
mov dword [rcx + rax + 0x24], 0xe00000e0
mov rax, qword [rbp + 0xc8]
movzx eax, word [rax + 2]
imul rax, rax, 0x28
mov rcx, qword [rbp + 0xc8]
movzx ecx, word [rcx + 2]
imul rcx, rcx, 0x28
mov rdx, qword [rbp + 0x108]
mov eax, dword [rdx + rax + 0x14]
mov rdx, qword [rbp + 0x108]
add eax, dword [rdx + rcx + 0x10]
xor r9d, r9d
xor r8d, r8d
mov edx, eax
mov rcx, qword [rbp + 8]
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov rcx, qword [rbp + 8]
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov rax, qword [rbp + 0xc8]
movzx eax, word [rax + 2]
imul rax, rax, 0x28
mov rcx, qword [rbp + 0xc8]
movzx ecx, word [rcx + 2]
imul rcx, rcx, 0x28
mov rdx, qword [rbp + 0x108]
mov eax, dword [rdx + rax + 0xc]
mov rdx, qword [rbp + 0x108]
add eax, dword [rdx + rcx + 8]
mov rcx, qword [rbp + 0xe8]
mov dword [rcx + 0x38], eax
mov rax, qword [rbp + 0xc8]
movzx eax, word [rax + 2]
inc eax
mov rcx, qword [rbp + 0xc8]
mov word [rcx + 2], ax
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rcx, qword [rbp + 8]
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
mov qword [rsp + 0x20], 0
lea r9, [rbp + 0x64]
mov r8d, dword [rbp + 0x24]
mov rdx, qword [rbp + 0x48]
mov rcx, qword [rbp + 8]
call qword [sym.imp.KERNEL32.dll_WriteFile]
jmp 0x14001a82b
mov rcx, qword [rbp + 8]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
jmp 0x14001a83a
mov rcx, qword [rbp + 8]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 1
mov rdi, rax
lea rcx, [rbp - 0x40]
lea rdx, [0x1400274f0]
call fcn.140011659
mov rax, rdi
mov rcx, qword [rbp + 0x1f8]
xor rcx, rbp
call fcn.1400113bb
lea rsp, [rbp + 0x208]
pop rdi
pop rbp
ret