Function at 0x1400219e6
Capabilities:
Encode data using xor

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x48
mov rsi, r9
mov edi, r8d
mov rbx, rdx
mov r12d, dword [rsp + 0xb0]
call fcn.14005f897
mov r15, rax
movsxd r13, edi
mov qword [rsp + 0x30], rbx
lea r14, [rbx + 8]
xor eax, eax
mov qword [rsp + 0x40], rax
mov rbx, r15
mov dword [rsp + 0x28], 0
mov dword [rsp + 0x2c], edi
jmp 0x140021ad4
mov al, byte [rbx]
test al, al
sete cl
cmp al, 0x2c
setne dl
xor dl, cl
inc rbx
test dl, dl
jne 0x140021a36
lea rcx, [rbx - 1]
test al, al
je 0x140021a58
mov byte [rcx], 0
jmp 0x140021a5b
mov rbx, rcx
test edi, edi
jle 0x140021ad4
mov qword [rsp + 0x38], r14
mov rdi, r14
xor r14d, r14d
mov rcx, qword [rdi - 8]
mov rdx, rbp
call fcn.14008d170
test eax, eax
je 0x140021a91
inc r14
add rdi, 0x18
cmp r14, r13
jl 0x140021a6a
mov edi, dword [rsp + 0x2c]
mov r14, qword [rsp + 0x38]
jmp 0x140021ad4
mov eax, dword [rdi]
cmp eax, 0xffffffff
mov edi, dword [rsp + 0x2c]
mov r14, qword [rsp + 0x38]
je 0x140021ad4
mov edx, 1
mov ecx, eax
shl edx, cl
mov ecx, dword [rsp + 0x28]
bt ecx, eax
jb 0x140021ad4
or dword [rsp + 0x28], edx
mov rcx, rsi
mov edx, r12d
mov rbp, qword [rsp + 0x40]
mov r8d, ebp
mov r9d, eax
call fcn.140003bf1
inc ebp
mov qword [rsp + 0x40], rbp
mov rbp, rbx
lea rbx, [rbx + 1]
jmp 0x140021ae3
inc rbp
inc rbx
mov al, byte [rbp]
cmp al, 0x2c
je 0x140021add
test al, al
jne 0x140021a36
mov rcx, r15
call fcn.140011913
mov r15, qword [rsp + 0x40]
cmp r15d, edi
mov rcx, qword [rsp + 0x30]
mov ebx, dword [rsp + 0x28]
jge 0x140021c87
mov eax, edi
mov qword [rsp + 0x38], rax
test edi, edi
jle 0x140021c7a
xor r14d, r14d
lea rdi, [r14 + r14*2]
lea r13, [rcx + rdi*8]
add r13, 8
mov eax, dword [r13]
test eax, eax
jns 0x140021b60
mov r8d, 0x17c
mov rbp, r15
mov r15, rcx
lea rcx, str.mapping_i_.v___0
lea rdx, str..._settings.c
call fcn.140089884
mov rcx, r15
mov r15, rbp
mov eax, dword [r13]
cmp eax, 0x20
jl 0x140021b88
mov r8d, 0x17d
mov rbp, rcx
lea rcx, str.mapping_i_.v___32
lea rdx, str..._settings.c
call fcn.140089884
mov rcx, rbp
mov eax, dword [r13]
bt ebx, eax
jb 0x140021c6c
mov eax, dword [rcx + rdi*8 + 0xc]
cmp eax, 0xffffffff
je 0x140021bd6
bt ebx, eax
jae 0x140021c6c
test r15d, r15d
mov dword [rsp + 0x28], ebx
mov rbp, r15
jle 0x140021be6
lea rbx, [rcx + rdi*8]
add rbx, 0xc
xor r15d, r15d
mov rcx, rsi
mov edx, r12d
mov r8d, r15d
call fcn.1400034cc
cmp eax, dword [rbx]
je 0x140021c02
inc r15d
cmp r15d, ebp
jl 0x140021bba
jmp 0x140021be9
mov dword [rsp + 0x28], ebx
mov ebx, dword [rcx + rdi*8 + 0x10]
sar ebx, 0x1f
and ebx, r15d
jmp 0x140021c17
xor r15d, r15d
mov r8d, 0x191
lea rcx, str.j___n
lea rdx, str..._settings.c
call fcn.140089884
mov rax, qword [rsp + 0x30]
mov ebx, dword [rax + rdi*8 + 0x10]
shr ebx, 0x1f
xor ebx, 1
add ebx, r15d
mov r15, rbp
cmp r15d, ebx
jle 0x140021c47
mov edi, r15d
lea ebp, [rdi - 1]
mov rcx, rsi
mov edx, r12d
mov r8d, ebp
call fcn.1400034cc
mov rcx, rsi
mov edx, r12d
mov r8d, edi
mov r9d, eax
call fcn.140003bf1
mov edi, ebp
cmp ebp, ebx
jg 0x140021c1f
mov r9d, dword [r13]
mov rcx, rsi
mov edx, r12d
mov r8d, ebx
call fcn.140003bf1
mov al, byte [r13]
mov ebx, dword [rsp + 0x28]
bts ebx, eax
inc r15d
mov rcx, qword [rsp + 0x30]
inc r14
cmp r14, qword [rsp + 0x38]
jne 0x140021b23
mov edi, dword [rsp + 0x2c]
cmp r15d, edi
jl 0x140021b18
add rsp, 0x48
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret