Function at 0x14004f660
Capabilities:
Encode data using xor

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
sub rsp, 0x4a0
mov rax, qword [0x1400b34a8]
xor rax, rsp
mov qword [rsp + 0x490], rax
cmp dword [rcx + 0x148], 1
mov rdi, rdx
mov rax, qword [rsp + 0x518]
mov rbx, rcx
mov r12, qword [rsp + 0x508]
mov r9, qword [rsp + 0x510]
mov qword [rsp + 0x48], rax
jne 0x14004f9a7
mov rbp, qword [rcx + 8]
lea rax, [rbp - 0x10]
cmp rax, 0x3f0
ja 0x14004f9a7
mov ecx, dword [rcx + 0x14c]
call fcn.14001f3f0
mov r14, rax
test rax, rax
je 0x14004f9a7
movzx esi, byte [rax + 0xc]
lea r13d, [rsi + rsi]
lea r11d, [r13 + 2]
cmp r11, rbp
ja 0x14004f9a7
lea rax, [rsp + 0x90]
mov rdx, rdi
mov rcx, rbx
mov qword [rsp + 0x20], rax
call fcn.14004d640
mov edi, eax
test eax, eax
jne 0x14004f976
xorps xmm0, xmm0
lea rcx, [rsp + 0x30]
xor eax, eax
xor r8d, r8d
mov rdx, r14
mov qword [rsp + 0x40], rax
movups xmmword [rsp + 0x30], xmm0
call fcn.14001f550
mov edi, eax
test eax, eax
je 0x14004f74a
lea rcx, [rsp + 0x30]
call fcn.14001f470
jmp 0x14004f976
mov qword [rsp + 0x4f8], r15
lea rax, [rsp + 0x30]
mov r15, rbp
mov qword [rsp + 0x20], rax
sub r15, rsi
lea rbx, [rsp + 0x91]
add rbx, rsi
lea rcx, [rsp + 0x91]
mov r8, rbx
mov rdx, rsi
lea r9, [r15 - 1]
call fcn.14004ef90
mov edi, eax
test eax, eax
jne 0x14004f964
lea rax, [rsp + 0x30]
mov r9, rsi
lea r8, [rsp + 0x91]
mov qword [rsp + 0x20], rax
lea rdx, [r15 - 1]
mov rcx, rbx
call fcn.14004ef90
mov edi, eax
test eax, eax
jne 0x14004f964
lea rcx, [rsp + 0x30]
call fcn.14001f470
lea r9, [rsp + 0x50]
xor r8d, r8d
xor edx, edx
mov rcx, r14
call fcn.14001fb10
mov edi, eax
test eax, eax
jne 0x14004f96e
movzx r8d, byte [rsp + 0x90]
xor edi, edi
mov ecx, edi
test rsi, rsi
je 0x14004f895
cmp rsi, 0x20
jb 0x14004f880
mov rax, rsi
xorps xmm3, xmm3
and rax, 0xffffffffffffffe0
xorps xmm2, xmm2
nop dword [rax]
movdqu xmm0, xmmword [rbx]
movdqu xmm1, xmmword [rsp + rcx + 0x50]
xorps xmm1, xmm0
movdqu xmm0, xmmword [rbx + 0x10]
add rbx, 0x20
orps xmm3, xmm1
movdqu xmm1, xmmword [rsp + rcx + 0x60]
add rcx, 0x20
xorps xmm1, xmm0
orps xmm2, xmm1
cmp rcx, rax
jb 0x14004f810
orps xmm2, xmm3
movdqa xmm0, xmm2
psrldq xmm0, 8
orps xmm2, xmm0
movdqa xmm0, xmm2
psrldq xmm0, 4
orps xmm2, xmm0
movdqa xmm0, xmm2
psrldq xmm0, 2
orps xmm2, xmm0
movdqa xmm0, xmm2
psrldq xmm0, 1
orps xmm2, xmm0
movd eax, xmm2
or r8b, al
cmp rcx, rsi
jae 0x14004f895
nop dword [rax]
movzx eax, byte [rsp + rcx + 0x50]
inc rcx
xor al, byte [rbx]
inc rbx
or r8b, al
cmp rcx, rsi
jb 0x14004f880
mov eax, r13d
mov r14, rbp
sub r14, rax
xor dl, dl
add r14, 0xfffffffffffffffe
mov r9, rdi
mov r10, rdi
mov r11, rdi
mov rcx, rdi
cmp r14, 2
jb 0x14004f8f6
lea rsi, [r14 - 1]
nop word [rax + rax]
or dl, byte [rcx + rbx]
movzx eax, dl
neg al
or al, dl
or dl, byte [rcx + rbx + 1]
not al
add rcx, 2
movzx eax, al
shr rax, 7
add r9, rax
movzx eax, dl
neg al
or al, dl
not al
movzx eax, al
shr rax, 7
add r10, rax
cmp rcx, rsi
jb 0x14004f8c0
cmp rcx, r14
jae 0x14004f90f
or dl, byte [rcx + rbx]
movzx eax, dl
neg al
or al, dl
not al
movzx r11d, al
shr r11, 7
lea rax, [r10 + r9]
add rax, r11
add rbx, rax
movzx eax, byte [rbx]
inc rbx
xor al, 1
or r8b, al
je 0x14004f92d
mov edi, 0xffffbf00
jmp 0x14004f96e
sub rbp, rbx
lea r8, [rsp + 0x90]
add r8, rbp
cmp r8, qword [rsp + 0x520]
jbe 0x14004f94c
mov edi, 0xffffbc00
jmp 0x14004f96e
mov qword [r12], r8
test r8, r8
je 0x14004f96e
mov rcx, qword [rsp + 0x48]
mov rdx, rbx
call fcn.14006bf10
jmp 0x14004f96e
lea rcx, [rsp + 0x30]
call fcn.14001f470
mov r15, qword [rsp + 0x4f8]
mov rax, qword [fcn.14006c5b0]
lea rcx, [rsp + 0x90]
xor edx, edx
mov r8d, 0x400
call rax
mov rax, qword [fcn.14006c5b0]
lea rcx, [rsp + 0x50]
xor edx, edx
lea r8d, [rdx + 0x40]
call rax
mov eax, edi
jmp 0x14004f9ac
mov eax, 0xffffbf80
mov rcx, qword [rsp + 0x490]
xor rcx, rsp
call fcn.140068c30
add rsp, 0x4a0
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret