Function at 0x140011dc0
Capabilities:
Delete file
Encode data using xor
Get file size
Read file on windows
Write file on windows

Disassembly:
mov qword [rsp + 8], rcx
push rbp
push rbx
push r12
push r14
lea rbp, [rsp - 0xb98]
sub rsp, 0xc98
xor r12d, r12d
mov rbx, rdx
mov qword [rsp + 0x40], r12
test rdx, rdx
je 0x1400121c3
mov qword [rsp + 0x30], r12
xor r9d, r9d
mov dword [rsp + 0x28], 0x80
xor r8d, r8d
mov edx, 0x80000000
mov dword [rsp + 0x20], 3
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov r14, rax
cmp rax, 0xffffffffffffffff
je 0x1400121c3
lea rdx, [rsp + 0x40]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x140011e60
cmp dword [rsp + 0x44], r12d
jne 0x140011e47
cmp dword [rsp + 0x40], 0x10000000
jbe 0x140011e60
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, 1
add rsp, 0xc98
pop r14
pop r12
pop rbx
pop rbp
ret
lea rax, [0x14021d580]
mov qword [rsp + 0xc78], r15
mov qword [rsp + 0x30], rax
lea r9, [0x1401c2940]
mov rax, qword [0x14021c048]
lea rcx, [rsp + 0x50]
mov qword [rsp + 0x28], rax
mov edx, 0x103
mov rax, qword [0x14021be28]
mov r8, 0xffffffffffffffff
mov qword [rsp + 0x20], rax
call fcn.140003dd0
xor r9d, r9d
mov qword [rsp + 0x30], r12
mov dword [rsp + 0x28], 0x80
lea rcx, [rsp + 0x50]
mov edx, 0xc0000000
mov dword [rsp + 0x20], 3
lea r8d, [r9 + 3]
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov r15, rax
cmp rax, 0xffffffffffffffff
jne 0x140011eff
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor al, al
mov r15, qword [rsp + 0xc78]
add rsp, 0xc98
pop r14
pop r12
pop rbx
pop rbp
ret
mov qword [rsp + 0xc90], rsi
lea r8, [rsp + 0x4c]
mov qword [rsp + 0xc88], rdi
mov r9d, 2
xor edx, edx
mov qword [rsp + 0xc80], r13
mov rcx, r15
mov qword [rsp + 0x48], r12
call qword [sym.imp.KERNEL32.dll_SetFilePointer]
lea r9, [rbp + 0xbc0]
mov dword [rbp + 0xbd8], 0x50000
mov r8d, 4
mov dword [rsp + 0x48], eax
lea rdx, [rbp + 0xbd8]
mov qword [rsp + 0x20], r12
mov rcx, r15
mov esi, r12d
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x140011f72
cmp dword [rbp + 0xbc0], 4
je 0x140011f77
mov esi, 1
mov rax, 0xffffffffffffffff
nop
inc rax
cmp word [rbx + rax*2], r12w
jne 0x140011f80
inc eax
mov qword [rsp + 0x20], r12
lea r9, [rbp + 0xbc0]
mov dword [rbp + 0xbd0], eax
mov r8d, 4
lea rdx, [rbp + 0xbd0]
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x140011fc1
cmp dword [rbp + 0xbc0], 4
je 0x140011fc3
inc esi
mov r9, 0xffffffffffffffff
lea rcx, [rbp + 0x160]
mov r8, rbx
mov edx, 0x104
call fcn.14003c5c8
mov eax, dword [rbp + 0xbd0]
lea r13, [0x140000000]
lea r8d, [rax + rax]
test r8d, r8d
je 0x140012025
xor dl, dl
mov r10d, r8d
lea rcx, [rbp + 0x160]
mov r9, r12
mov rax, r9
lea rcx, [rcx + 1]
and eax, 0xf
inc r9
add dl, byte [r13 + rax*4 + 0x1be080]
xor byte [rcx - 1], dl
movzx edx, byte [rcx - 1]
sub r10, 1
jne 0x140012003
lea r9, [rbp + 0xbc0]
mov qword [rsp + 0x20], r12
lea rdx, [rbp + 0x160]
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x140012059
mov ecx, dword [rbp + 0xbd0]
mov eax, dword [rbp + 0xbc0]
add rcx, rcx
cmp rax, rcx
je 0x14001205b
inc esi
lea r9, [rbp + 0xbc0]
mov qword [rsp + 0x20], r12
mov r8d, 4
lea rdx, [rsp + 0x40]
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x140012088
cmp dword [rbp + 0xbc0], 4
je 0x14001208a
inc esi
lea r9, [rbp + 0xbc8]
mov dword [rbp + 0xbc8], r12d
mov r8d, 0x800
mov qword [rsp + 0x20], r12
lea rdx, [rbp + 0x370]
mov rcx, r14
mov ebx, r12d
mov edi, r12d
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x14001216c
nop dword [rax]
nop word [rax + rax]
mov r8d, dword [rbp + 0xbc8]
test r8d, r8d
je 0x14001216c
lea rcx, [rbp + 0x370]
mov edx, r8d
nop word [rax + rax]
mov eax, edi
lea rcx, [rcx + 1]
and eax, 0xf
inc edi
add bl, byte [r13 + rax*4 + 0x1c2990]
xor byte [rcx - 1], bl
movsx ebx, byte [rcx - 1]
sub rdx, 1
jne 0x1400120f0
lea r9, [rbp + 0xbc0]
mov qword [rsp + 0x20], r12
lea rdx, [rbp + 0x370]
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x14001216a
mov eax, dword [rbp + 0xbc8]
cmp dword [rbp + 0xbc0], eax
jne 0x14001216a
lea r9, [rbp + 0xbc8]
mov qword [rsp + 0x20], r12
mov r8d, 0x800
lea rdx, [rbp + 0x370]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x1400120d0
jmp 0x14001216c
inc esi
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov r13, qword [rsp + 0xc80]
mov rdi, qword [rsp + 0xc88]
test esi, esi
je 0x1400121b3
mov r8d, esi
lea rdx, [rsp + 0x50]
lea rcx, str._ndeleted__s_fue__d_errors_r_n
call fcn.140011d70
lea rcx, [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
test esi, esi
mov rsi, qword [rsp + 0xc90]
sete al
jmp 0x140011ee9
xor al, al
add rsp, 0xc98
pop r14
pop r12
pop rbx
pop rbp
ret