Function at 0x140005460
Capabilities:
Encode data using base64

Disassembly:
mov qword [rsp + 8], rcx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x20]
sub rsp, 0x120
mov qword [rsp + 0x48], 0xfffffffffffffffe
mov qword [rsp + 0x170], rbx
mov r15d, r8d
mov r14, rdx
mov rbx, rcx
xor edi, edi
mov dword [rsp + 0x24], edi
mov qword [rcx + 0x18], 0xf
mov qword [rcx + 0x10], rdi
cmp qword [rcx + 0x18], 0x10
jb 0x1400054b4
mov rax, qword [rcx]
jmp 0x1400054b7
mov rax, rbx
mov byte [rax], dil
mov dword [rsp + 0x24], 1
xor edx, edx
mov r8d, 0xc4
lea rcx, [rsp + 0x50]
call fcn.1400d8b80
nop
lea rcx, [rsp + 0x50]
call fcn.140005930
mov qword [rsp + 0x40], 0xf
mov qword [rsp + 0x38], rdi
mov byte [rsp + 0x28], 0
cmp byte [rax], 0
jne 0x1400054fc
mov r8, rdi
jmp 0x14000550a
or r8, 0xffffffffffffffff
inc r8
cmp byte [rax + r8], 0
jne 0x140005500
mov rdx, rax
lea rcx, [rsp + 0x28]
call fcn.140004560
nop
lea rdi, [rsp + 0x50]
xor eax, eax
mov ecx, 0x41
rep stosb byte [rdi], al
lea rdi, [rbp - 0x6e]
mov ecx, 0x82
rep stosb byte [rdi], al
xor esi, esi
test r15d, r15d
je 0x1400058ab
xor ecx, ecx
nop
dec r15d
movzx eax, byte [r14]
mov byte [rbp + rcx + 0x78], al
inc esi
inc rcx
inc r14
mov qword [rbp + 0x68], r14
movzx edx, byte [rbp + 0x7a]
movzx r12d, byte [rbp + 0x79]
movzx r13d, byte [rbp + 0x78]
cmp rcx, 3
jne 0x14000567b
movzx eax, r13b
shr al, 2
mov byte [rsp + 0x20], al
movzx ecx, r13b
and cl, 3
shl cl, 4
movzx eax, r12b
shr al, 4
add cl, al
mov byte [rsp + 0x21], cl
movzx ecx, r12b
and cl, 0xf
shl cl, 2
movzx eax, dl
shr al, 6
add cl, al
mov byte [rsp + 0x22], cl
movzx eax, dl
and al, 0x3f
mov byte [rsp + 0x23], al
xor esi, esi
nop dword [rax]
nop word [rax + rax]
movzx ecx, byte [rsp + rsi + 0x20]
lea rax, [rsp + 0x28]
cmp qword [rsp + 0x40], 0x10
cmovae rax, qword [rsp + 0x28]
movzx r14d, byte [rax + rcx]
mov rax, qword [rbx + 0x10]
not rax
cmp rax, 1
jbe 0x140005692
mov rax, qword [rbx + 0x10]
lea rdi, [rax + 1]
cmp rdi, 0xfffffffffffffffe
ja 0x140005685
cmp qword [rbx + 0x18], rdi
jae 0x140005614
mov r8, rax
mov rdx, rdi
mov rcx, rbx
call fcn.140004220
jmp 0x14000562f
test rdi, rdi
jne 0x140005634
mov qword [rbx + 0x10], rdi
cmp qword [rbx + 0x18], 0x10
jb 0x140005629
mov rax, qword [rbx]
jmp 0x14000562c
mov rax, rbx
mov byte [rax], 0
test rdi, rdi
je 0x140005662
mov rcx, qword [rbx + 0x10]
cmp qword [rbx + 0x18], 0x10
jb 0x140005644
mov rax, qword [rbx]
jmp 0x140005647
mov rax, rbx
mov byte [rax + rcx], r14b
mov qword [rbx + 0x10], rdi
cmp qword [rbx + 0x18], 0x10
jb 0x14000565b
mov rax, qword [rbx]
jmp 0x14000565e
mov rax, rbx
mov byte [rax + rdi], 0
inc rsi
cmp rsi, 4
jl 0x1400055c0
xor esi, esi
xor ecx, ecx
mov r14, qword [rbp + 0x68]
movzx edx, byte [rbp + 0x7a]
test r15d, r15d
je 0x14000569f
jmp 0x140005540
lea rcx, str.string_too_long
call fcn.1400d6d84
int3
lea rcx, str.string_too_long
call fcn.1400d6d84
int3
test esi, esi
je 0x1400058ab
cmp esi, 3
jge 0x1400056d2
mov eax, 3
sub eax, esi
movsxd rcx, eax
movsxd rax, esi
lea rdi, [rbp + 0x78]
add rdi, rax
xor eax, eax
rep stosb byte [rdi], al
movzx edx, byte [rbp + 0x7a]
movzx r12d, byte [rbp + 0x79]
movzx r13d, byte [rbp + 0x78]
movzx eax, r13b
shr al, 2
mov byte [rsp + 0x20], al
and r13b, 3
shl r13b, 4
movzx eax, r12b
shr al, 4
add r13b, al
mov byte [rsp + 0x21], r13b
and r12b, 0xf
shl r12b, 2
movzx eax, dl
shr al, 6
add r12b, al
mov byte [rsp + 0x22], r12b
and dl, 0x3f
mov byte [rsp + 0x23], dl
xor r14d, r14d
lea r13d, [rsi + 1]
test r13d, r13d
jle 0x1400057f8
lea r15, [rsp + 0x20]
nop word [rax + rax]
movzx ecx, byte [r15]
lea rax, [rsp + 0x28]
cmp qword [rsp + 0x40], 0x10
cmovae rax, qword [rsp + 0x28]
movzx r12d, byte [rax + rcx]
mov rax, qword [rbx + 0x10]
not rax
cmp rax, 1
jbe 0x1400057eb
mov rax, qword [rbx + 0x10]
lea rdi, [rax + 1]
cmp rdi, 0xfffffffffffffffe
ja 0x1400057de
cmp qword [rbx + 0x18], rdi
jae 0x14000577f
mov r8, rax
mov rdx, rdi
mov rcx, rbx
call fcn.140004220
jmp 0x14000579a
test rdi, rdi
jne 0x14000579f
mov qword [rbx + 0x10], rdi
cmp qword [rbx + 0x18], 0x10
jb 0x140005794
mov rax, qword [rbx]
jmp 0x140005797
mov rax, rbx
mov byte [rax], 0
test rdi, rdi
je 0x1400057cd
mov rcx, qword [rbx + 0x10]
cmp qword [rbx + 0x18], 0x10
jb 0x1400057af
mov rax, qword [rbx]
jmp 0x1400057b2
mov rax, rbx
mov byte [rcx + rax], r12b
mov qword [rbx + 0x10], rdi
cmp qword [rbx + 0x18], 0x10
jb 0x1400057c6
mov rax, qword [rbx]
jmp 0x1400057c9
mov rax, rbx
mov byte [rdi + rax], 0
inc r14d
inc r15
cmp r14d, r13d
jl 0x140005730
jmp 0x1400057f8
lea rcx, str.string_too_long
call fcn.1400d6d84
int3
lea rcx, str.string_too_long
call fcn.1400d6d84
int3
cmp esi, 3
jge 0x1400058ab
inc esi
mov rax, qword [rbx + 0x10]
not rax
cmp rax, 1
jbe 0x14000589e
mov rax, qword [rbx + 0x10]
lea rdi, [rax + 1]
cmp rdi, 0xfffffffffffffffe
ja 0x140005891
cmp qword [rbx + 0x18], rdi
jae 0x140005838
mov r8, rax
mov rdx, rdi
mov rcx, rbx
call fcn.140004220
jmp 0x140005853
test rdi, rdi
jne 0x140005858
mov qword [rbx + 0x10], rdi
cmp qword [rbx + 0x18], 0x10
jb 0x14000584d
mov rax, qword [rbx]
jmp 0x140005850
mov rax, rbx
mov byte [rax], 0
test rdi, rdi
je 0x140005886
mov rcx, qword [rbx + 0x10]
cmp qword [rbx + 0x18], 0x10
jb 0x140005868
mov rax, qword [rbx]
jmp 0x14000586b
mov rax, rbx
mov byte [rcx + rax], 0x3d
mov qword [rbx + 0x10], rdi
cmp qword [rbx + 0x18], 0x10
jb 0x14000587f
mov rax, qword [rbx]
jmp 0x140005882
mov rax, rbx
mov byte [rax + rdi], 0
cmp esi, 3
jl 0x140005801
jmp 0x1400058ab
lea rcx, str.string_too_long
call fcn.1400d6d84
int3
lea rcx, str.string_too_long
call fcn.1400d6d84
nop
mov rax, qword [rsp + 0x40]
cmp rax, 0x10
jb 0x14000590a
inc rax
mov rcx, qword [rsp + 0x28]
cmp rax, 0x1000
jb 0x140005905
test cl, 0x1f
je 0x1400058d1
call fcn.1400daf34
int3
mov rax, qword [rsp + 0x28]
mov rcx, qword [rax - 8]
cmp rcx, rax
jb 0x1400058e5
call fcn.1400daf34
int3
mov rax, qword [rsp + 0x28]
sub rax, rcx
cmp rax, 8
jae 0x1400058f9
call fcn.1400daf34
int3
cmp rax, 0x27
jbe 0x140005905
call fcn.1400daf34
int3
call fcn.1400d6f24
mov rax, rbx
mov rbx, qword [rsp + 0x170]
add rsp, 0x120
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret