Function at 0x140021c3a
Capabilities:
Encode data using base64

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x48
mov qword [rsp + 0x30], 0
mov r15, rcx
mov rsi, rdx
mov rbx, r8
mov qword [rsp + 0x38], 0
test r9b, r9b
jne 0x140021c90
imul rax, r8, 4
jo 0x140021d03
cqo
mov edi, 3
idiv rdi
add rax, 6
mov rcx, rax
jns 0x140022086
jmp 0x1400220ff
imul rax, r8, 4
jo 0x140021d03
cqo
mov edi, 3
idiv rdi
add rax, 6
mov rcx, rax
js 0x1400220ff
lea r12, [rsp + 0x30]
mov rdx, rax
mov r14, rbx
xor r13d, r13d
mov rcx, r12
call fcn.140004bf7
mov rax, rbx
cqo
idiv rdi
sub r14, rdx
mov qword [rsp + 0x20], rdx
seto r13b
jo 0x140021d03
xor r9d, r9d
lea rbp, [0x140049f20]
cmp r14, r13
je 0x140021d0d
cmp rbx, r13
jle 0x140022112
movzx edi, byte [rsi + r13]
mov rcx, r13
mov eax, edi
shl eax, 0x10
inc rcx
jns 0x140021d1e
call fcn.140003684
jmp 0x1400224ef
cmp qword [rsp + 0x20], 1
jne 0x140021e8e
jmp 0x140021e9f
cmp rcx, r13
jb 0x140021d03
test rcx, rcx
js 0x1400223c1
cmp rcx, rbx
jge 0x1400223c1
movzx edi, byte [rsi + rcx]
mov r10, rcx
shl edi, 8
or edi, eax
add r10, 1
jo 0x140021d03
test r10, r10
js 0x14002216c
cmp r10, rbx
jge 0x14002216c
movzx eax, byte [rsi + r10]
mov rdx, qword [rsp + 0x30]
lea r13, [rcx + 2]
or edi, eax
test r9, r9
js 0x1400223d9
cmp rdx, r9
jle 0x1400223d9
mov rcx, r12
mov qword [rsp + 0x28], r9
call fcn.140021bc3
mov eax, edi
mov r9, qword [rsp + 0x28]
shr eax, 0x12
mov dl, byte [rbp + rax]
mov rax, qword [rsp + 0x38]
mov byte [rax + r9 + 8], dl
add r9, 1
mov rcx, r9
jo 0x140021d03
mov rdx, qword [rsp + 0x30]
test r9, r9
js 0x14002226d
cmp r9, rdx
jge 0x140022276
mov rcx, r12
mov qword [rsp + 0x28], r9
call fcn.140021bc3
mov eax, edi
mov r9, qword [rsp + 0x28]
shr eax, 0xc
and eax, 0x3f
mov dl, byte [rbp + rax]
mov rax, qword [rsp + 0x38]
mov byte [rax + r9 + 8], dl
add r9, 1
mov rcx, r9
jo 0x140021d03
mov rdx, qword [rsp + 0x30]
test r9, r9
js 0x14002226d
cmp r9, rdx
jge 0x140022276
mov rcx, r12
mov qword [rsp + 0x28], r9
call fcn.140021bc3
mov eax, edi
mov r9, qword [rsp + 0x28]
shr eax, 6
and eax, 0x3f
mov dl, byte [rbp + rax]
mov rax, qword [rsp + 0x38]
mov byte [rax + r9 + 8], dl
add r9, 1
mov rcx, r9
jo 0x140021d03
mov rdx, qword [rsp + 0x30]
test r9, r9
js 0x14002226d
cmp r9, rdx
jge 0x140022276
and edi, 0x3f
mov rcx, r12
mov qword [rsp + 0x28], r9
call fcn.140021bc3
mov r9, qword [rsp + 0x28]
mov dl, byte [rbp + rdi]
mov rax, qword [rsp + 0x38]
mov byte [rax + r9 + 8], dl
add r9, 1
jno 0x140021ce3
jmp 0x140021d03
cmp qword [rsp + 0x20], 2
jne 0x1400220dd
jmp 0x140021f9d
cmp rbx, r14
jle 0x140022396
mov rax, r14
inc rax
js 0x140021d03
cmp rax, r14
jb 0x140021d03
mov rdx, qword [rsp + 0x30]
test r9, r9
js 0x1400223d9
cmp r9, rdx
jge 0x1400223d9
movzx ebx, byte [rsi + r14]
mov rcx, r12
mov qword [rsp + 0x20], r9
lea rsi, [0x140049f20]
call fcn.140021bc3
mov r9, qword [rsp + 0x20]
shl ebx, 0x10
mov eax, ebx
shr eax, 0x12
mov dl, byte [rsi + rax]
mov rax, qword [rsp + 0x38]
mov byte [rax + r9 + 8], dl
add r9, 1
mov r13, r9
jo 0x140021d03
test r9, r9
js 0x14002243b
cmp r9, qword [rsp + 0x30]
jge 0x14002243b
shr ebx, 0xc
mov rcx, r12
call fcn.140021bc3
and ebx, 0x30
mov rax, qword [rsp + 0x38]
mov dl, byte [rsi + rbx]
mov byte [rax + r13 + 8], dl
add r13, 1
jo 0x140021d03
mov rdx, qword [rsp + 0x30]
test r13, r13
js 0x1400224b2
cmp rdx, r13
jle 0x1400224b2
mov rcx, r12
call fcn.140021bc3
mov rax, qword [rsp + 0x38]
mov byte [rax + r13 + 8], 0x3d
add r13, 1
jo 0x140021d03
mov rdx, qword [rsp + 0x30]
test r13, r13
js 0x1400224b2
cmp r13, rdx
jge 0x1400224b2
jmp 0x1400224bf
cmp rbx, r14
jle 0x140022396
mov rcx, r13
inc rcx
js 0x140021d03
cmp rcx, r13
jb 0x140021d03
test rcx, rcx
js 0x1400223c1
cmp rcx, rbx
jge 0x1400223c1
mov rdx, qword [rsp + 0x30]
test r9, r9
js 0x1400223d9
cmp rdx, r9
jle 0x1400223d9
movzx ebx, byte [rsi + r13]
movzx eax, byte [rsi + rcx]
mov rcx, r12
mov qword [rsp + 0x20], r9
lea rsi, [0x140049f20]
shl ebx, 0x10
shl eax, 8
or eax, ebx
mov ebx, eax
call fcn.140021bc3
mov eax, ebx
mov r9, qword [rsp + 0x20]
shr eax, 0x12
mov dl, byte [rsi + rax]
mov rax, qword [rsp + 0x38]
mov byte [rax + r9 + 8], dl
add r9, 1
mov r13, r9
jo 0x140021d03
test r9, r9
js 0x14002243b
cmp r9, qword [rsp + 0x30]
jge 0x14002243b
mov rcx, r12
call fcn.140021bc3
mov eax, ebx
shr eax, 0xc
and eax, 0x3f
mov dl, byte [rsi + rax]
mov rax, qword [rsp + 0x38]
mov byte [rax + r13 + 8], dl
add r13, 1
jo 0x140021d03
mov rdx, qword [rsp + 0x30]
test r13, r13
js 0x1400224b2
cmp r13, rdx
jge 0x1400224b2
jmp 0x14002247c
lea r12, [rsp + 0x30]
mov rdx, rax
mov r14, rbx
xor r13d, r13d
mov rcx, r12
call fcn.140004bf7
mov rax, rbx
cqo
idiv rdi
sub r14, rdx
mov qword [rsp + 0x20], rdx
seto r13b
jo 0x140021d03
xor r9d, r9d
lea rbp, str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789__
cmp r14, r13
jne 0x14002210d
cmp qword [rsp + 0x20], 1
je 0x1400222b0
cmp qword [rsp + 0x20], 2
je 0x140022391
test r9, r9
jns 0x1400224e4
movabs r8, 0x7fffffffffffffff
xor edx, edx
mov rcx, r9
call fcn.140003d34
jmp 0x1400224ef
movabs r8, 0x7fffffffffffffff
xor edx, edx
jmp 0x1400220f5
cmp rbx, r13
jg 0x14002211b
lea rdx, [rbx - 1]
jmp 0x1400224b5
movzx edi, byte [rsi + r13]
mov rcx, r13
mov eax, edi
shl eax, 0x10
inc rcx
js 0x140021d03
cmp rcx, r13
jb 0x140021d03
test rcx, rcx
js 0x1400223c1
cmp rcx, rbx
jge 0x1400223c1
movzx edi, byte [rsi + rcx]
mov r10, rcx
shl edi, 8
or edi, eax
add r10, 1
jo 0x140021d03
test r10, r10
js 0x14002216c
cmp r10, rbx
jl 0x140022178
lea rdx, [rbx - 1]
mov rcx, r10
jmp 0x1400224b8
movzx eax, byte [rsi + r10]
mov rdx, qword [rsp + 0x30]
lea r13, [rcx + 2]
or edi, eax
test r9, r9
js 0x1400223d9
cmp rdx, r9
jle 0x1400223d9
mov rcx, r12
mov qword [rsp + 0x28], r9
call fcn.140021bc3
mov eax, edi
mov r9, qword [rsp + 0x28]
shr eax, 0x12
mov dl, byte [rbp + rax]
mov rax, qword [rsp + 0x38]
mov byte [rax + r9 + 8], dl
add r9, 1
mov rcx, r9
jo 0x140021d03
mov rdx, qword [rsp + 0x30]
test r9, r9
js 0x14002226d
cmp rdx, r9
jle 0x140022276
mov rcx, r12
mov qword [rsp + 0x28], r9
call fcn.140021bc3
mov eax, edi
mov r9, qword [rsp + 0x28]
shr eax, 0xc
and eax, 0x3f
mov dl, byte [rbp + rax]
mov rax, qword [rsp + 0x38]
mov byte [rax + r9 + 8], dl
add r9, 1
mov rcx, r9
jo 0x140021d03
mov rdx, qword [rsp + 0x30]
test r9, r9
js 0x14002226d
cmp rdx, r9
jle 0x140022276
mov rcx, r12
mov qword [rsp + 0x28], r9
call fcn.140021bc3
mov eax, edi
mov r9, qword [rsp + 0x28]
shr eax, 6
and eax, 0x3f
mov dl, byte [rbp + rax]
mov rax, qword [rsp + 0x38]
mov byte [rax + r9 + 8], dl
add r9, 1
mov rcx, r9
jo 0x140021d03
mov rdx, qword [rsp + 0x30]
test r9, r9
js 0x14002226d
cmp rdx, r9
jg 0x14002227e
jmp 0x140022276
mov ecx, 1
shl rcx, 0x3f
dec rdx
jmp 0x1400224b8
and edi, 0x3f
mov rcx, r12
mov qword [rsp + 0x28], r9
call fcn.140021bc3
mov r9, qword [rsp + 0x28]
mov dl, byte [rbp + rdi]
mov rax, qword [rsp + 0x38]
mov byte [rax + r9 + 8], dl
add r9, 1
jno 0x1400220c0
jmp 0x140021d03
cmp rbx, r14
jle 0x140022396
mov rax, r14
inc rax
js 0x140021d03
cmp rax, r14
jb 0x140021d03
mov rdx, qword [rsp + 0x30]
test r9, r9
js 0x1400223d9
cmp rdx, r9
jle 0x1400223d9
movzx eax, byte [rsi + r14]
mov rcx, r12
mov qword [rsp + 0x20], r9
lea rsi, str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789__
shl eax, 0x10
mov ebx, eax
call fcn.140021bc3
mov eax, ebx
mov r9, qword [rsp + 0x20]
shr eax, 0x12
mov dl, byte [rsi + rax]
mov rax, qword [rsp + 0x38]
mov byte [rax + r9 + 8], dl
add r9, 1
mov r13, r9
jo 0x140021d03
test r9, r9
js 0x14002243b
cmp r9, qword [rsp + 0x30]
jge 0x14002243b
mov rcx, r12
call fcn.140021bc3
mov eax, ebx
shr eax, 0xc
and eax, 0x30
mov dl, byte [rsi + rax]
mov rax, qword [rsp + 0x38]
mov byte [rax + r13 + 8], dl
add r13, 1
jo 0x140021d03
mov rdx, qword [rsp + 0x30]
test r13, r13
js 0x1400224b2
cmp rdx, r13
jle 0x1400224b2
mov rcx, r12
call fcn.140021bc3
mov rax, qword [rsp + 0x38]
mov byte [rax + r13 + 8], 0x3d
jmp 0x140022499
cmp rbx, r14
jg 0x1400223a2
lea rdx, [rbx - 1]
mov rcx, r14
jmp 0x1400224b8
mov rcx, r13
inc rcx
js 0x140021d03
cmp rcx, r13
jb 0x140021d03
test rcx, rcx
js 0x1400223c1
cmp rbx, rcx
jg 0x1400223ca
lea rdx, [rbx - 1]
jmp 0x1400224b8
mov rdx, qword [rsp + 0x30]
test r9, r9
js 0x1400223d9
cmp rdx, r9
jg 0x1400223e4
dec rdx
mov rcx, r9
jmp 0x1400224b8
movzx ebx, byte [rsi + r13]
movzx eax, byte [rsi + rcx]
mov rcx, r12
mov qword [rsp + 0x20], r9
lea rsi, str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789__
shl ebx, 0x10
shl eax, 8
or eax, ebx
mov ebx, eax
call fcn.140021bc3
mov eax, ebx
mov r9, qword [rsp + 0x20]
shr eax, 0x12
mov dl, byte [rsi + rax]
mov rax, qword [rsp + 0x38]
mov byte [rax + r9 + 8], dl
add r9, 1
mov r13, r9
jo 0x140021d03
test r9, r9
js 0x14002243b
cmp r9, qword [rsp + 0x30]
jl 0x140022446
mov rax, qword [rsp + 0x30]
lea rdx, [rax - 1]
jmp 0x1400224b5
mov rcx, r12
call fcn.140021bc3
mov eax, ebx
shr eax, 0xc
and eax, 0x3f
mov dl, byte [rsi + rax]
mov rax, qword [rsp + 0x38]
mov byte [rax + r13 + 8], dl
add r13, 1
jo 0x140021d03
mov rdx, qword [rsp + 0x30]
test r13, r13
js 0x1400224b2
cmp rdx, r13
jle 0x1400224b2
mov rcx, r12
call fcn.140021bc3
mov eax, ebx
shr eax, 6
and eax, 0x3c
mov dl, byte [rsi + rax]
mov rax, qword [rsp + 0x38]
mov byte [rax + r13 + 8], dl
add r13, 1
jo 0x140021d03
mov rdx, qword [rsp + 0x30]
test r13, r13
js 0x1400224b2
cmp rdx, r13
jg 0x1400224bf
dec rdx
mov rcx, r13
call fcn.140004df8
jmp 0x1400224ef
mov rcx, r12
call fcn.140021bc3
mov rax, qword [rsp + 0x38]
mov r9, r13
add r9, 1
mov byte [rax + r13 + 8], 0x3d
jno 0x1400220dd
jmp 0x140021d03
mov rdx, r9
mov rcx, r12
call fcn.140004bf7
movups xmm0, xmmword [rsp + 0x30]
mov rax, r15
movups xmmword [r15], xmm0
add rsp, 0x48
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret