Function at 0x14000181b
Capabilities:
Encode data using xor

Disassembly:
push rsi
push rdi
push r12
push r13
push r14
push r15
push rbp
sub rsp, 0x50
mov rdi, r8
mov r13, qword [rsp + 0xb0]
mov esi, edx
mov r15, rcx
lea rcx, [rsp + 0x48]
mov r8d, 4
mov r14, r9
xor ebp, ebp
lea rdx, [r13 + 0x10c]
call fcn.140001bdb
mov r8d, 4
lea rdx, [r13 + 0x100]
lea rcx, [rsp + 0x4c]
call fcn.140001bdb
mov edx, esi
xor esi, esi
xor r8d, r8d
xor r12d, r12d
lea rcx, [r15 + rdx]
add rdx, 0xfffffffffffffff8
mov eax, edx
add eax, 0xfffffff8
je 0x140001b77
mov al, byte [rsp + 0x48]
mov qword [rsp + 0x40], r12
mov r12, r13
mov qword [rsp + 0x30], rdi
mov r13d, r8d
mov qword [rsp + 0x20], r14
mov r14, rcx
mov qword [rsp + 0x38], rbx
add edx, 0xfffffff8
xor ebx, ebx
mov dil, byte [r15 + rbx + 1]
cmp dil, al
je 0x1400018c2
cmp al, 0x3f
jne 0x140001bcd
mov dil, byte [r15 + rbx + 2]
mov r9b, byte [rsp + 0x49]
cmp dil, r9b
je 0x1400018db
cmp r9b, 0x3f
jne 0x140001bcd
mov dil, byte [r15 + rbx + 3]
mov r9b, byte [rsp + 0x4a]
cmp dil, r9b
je 0x1400018f4
cmp r9b, 0x3f
jne 0x140001bcd
mov dil, byte [r15 + rbx + 4]
mov r9b, byte [rsp + 0x4b]
cmp dil, r9b
je 0x14000190d
cmp r9b, 0x3f
jne 0x140001bcd
mov dil, byte [r15 + rbx + 5]
mov r9b, byte [rsp + 0x4c]
cmp dil, r9b
je 0x140001926
cmp r9b, 0x3f
jne 0x140001bcd
mov dil, byte [r15 + rbx + 6]
mov r9b, byte [rsp + 0x4d]
cmp dil, r9b
je 0x14000193f
cmp r9b, 0x3f
jne 0x140001bcd
mov dil, byte [r15 + rbx + 7]
mov r9b, byte [rsp + 0x4e]
cmp dil, r9b
je 0x140001958
cmp r9b, 0x3f
jne 0x140001bcd
mov dil, byte [r15 + rbx + 8]
mov r9b, byte [rsp + 0x4f]
cmp dil, r9b
je 0x140001971
cmp r9b, 0x3f
jne 0x140001bcd
lea r15, [r15 + rbx + 1]
test r15, r15
je 0x140001b5f
mov edi, dword [r15]
mov r9d, edi
shr r9d, 8
mov edx, edi
movzx r9d, r9b
mov ebx, edi
shr edx, 0x10
shl ebx, 0x18
shl r9d, 0x10
movzx edx, dl
add ebx, r9d
shl edx, 8
lea r9, [r15 + 8]
add ebx, edx
shr edi, 0x18
mov r10d, dword [r9]
add ebx, edi
cmp r10d, dword [r12 + 0x94]
jne 0x1400019c5
test rsi, rsi
je 0x140001aff
test rsi, rsi
je 0x140001bb1
lea edi, [rbp + rbx]
cmp edi, r13d
ja 0x140001b89
mov rdx, r9
add rbp, rsi
mov r8d, ebx
mov rcx, rbp
call fcn.140001bdb
mov rdx, r14
mov ebp, edi
sub rdx, r15
add rdx, 0xfffffffffffffff8
mov eax, edx
add eax, 0xfffffff8
je 0x140001a08
mov al, byte [rsp + 0x48]
jmp 0x1400018ab
mov r12, qword [rsp + 0x40]
mov rdi, qword [rsp + 0x30]
mov rbx, qword [rsp + 0x38]
mov edx, dword [r12 + 8]
mov eax, dword [r12 + 4]
test dl, 3
je 0x140001a2d
dec edx
test dl, 3
jne 0x140001a26
test edx, edx
jbe 0x140001ae0
lea r8d, [rdx + 3]
sar r8d, 1
shr r8d, 0x1e
lea r9d, [r8 + rdx + 3]
sar r9d, 2
movsxd r10, r9d
cmp r10, 4
jl 0x140001afa
lea r11, [rsi + 0x10]
and r11, 0xf
test r11d, r11d
je 0x140001a7b
test r11d, 3
jne 0x140001afa
neg r11d
add r11d, 0x10
shr r11d, 2
mov r8d, r11d
lea rdx, [r8 + 4]
cmp r10, rdx
jl 0x140001afa
mov r12d, r9d
xor edx, edx
sub r12d, r11d
and r12d, 3
sub r9d, r12d
movsxd r9, r9d
test r11d, r11d
jbe 0x140001aaa
xor dword [rsi + rdx*4 + 0x10], eax
inc rdx
cmp rdx, r8
jb 0x140001a9e
movd xmm0, eax
pshufd xmm0, xmm0, 0
movdqu xmm1, xmmword [rsi + r8*4 + 0x10]
pxor xmm1, xmm0
movdqu xmmword [rsi + r8*4 + 0x10], xmm1
add r8, 4
cmp r8, r9
jb 0x140001ab3
cmp r9, r10
jae 0x140001ae0
xor dword [rsi + r9*4 + 0x10], eax
inc r9
cmp r9, r10
jb 0x140001ad3
xor eax, eax
test ebp, ebp
mov qword [rdi], rsi
seta al
add rsp, 0x50
pop rbp
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
ret
xor r9d, r9d
jmp 0x140001ace
mov rax, qword [rsp + 0x20]
mov r13d, dword [r9 + 8]
add r13d, 0x10
mov qword [rsp + 0x40], r9
mov rax, qword [rax + 0x50]
jne 0x140001b1c
mov edx, dword [rax + 0x60]
jmp 0x140001b1f
mov edx, r13d
mov ecx, dword [rax + 0x108]
mov rax, qword [rsp + 0x20]
mov qword [rsp + 0x28], r9
call qword [rax + 0x18]
mov r9, qword [rsp + 0x28]
mov rsi, rax
mov rcx, rsi
mov rdx, r9
mov r8d, ebx
call fcn.140001bdb
mov rdx, r14
add ebp, ebx
sub rdx, r15
add rdx, 0xfffffffffffffff8
mov eax, edx
add eax, 0xfffffff8
jne 0x1400019ff
mov r12, qword [rsp + 0x40]
mov rdi, qword [rsp + 0x30]
mov rbx, qword [rsp + 0x38]
test rsi, rsi
jne 0x140001a17
xor eax, eax
add rsp, 0x50
pop rbp
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
ret
mov r8d, r13d
mov rdx, r9
mov ecx, ebp
sub r8d, ebp
add rcx, rsi
mov r12, qword [rsp + 0x40]
mov rdi, qword [rsp + 0x30]
mov rbx, qword [rsp + 0x38]
call fcn.140001bdb
nop
jmp 0x140001a17
mov rdx, r14
sub rdx, r15
add rdx, 0xfffffffffffffff8
mov ebx, edx
add ebx, 0xfffffff8
jne 0x1400018ab
mov rbx, qword [rsp + 0x38]
jmp 0x140001b77
inc ebx
cmp ebx, edx
jb 0x1400018b0
jmp 0x140001b5f