Function at 0x1400778a0
Capabilities:
Encode data using base64

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x58
mov rsi, rcx
mov rax, qword [0x140287028]
xor rax, rsp
mov qword [rsp + 0x50], rax
test rdx, rdx
je 0x140077b60
mov rbx, rdx
cmp word [rdx], 0
je 0x140077b60
mov eax, dword [0x1402a2900]
mov ecx, dword [0x140296f94]
mov rdx, qword gs:[0x58]
mov rcx, qword [rdx + rcx*8]
cmp eax, dword [rcx + 4]
jle 0x140077947
lea rcx, [0x1402a2900]
call fcn.140172b08
cmp dword [0x1402a2900], 0xffffffff
jne 0x140077947
lea rcx, str.api_ms_win_security_base_l1_2_2.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x140077db1
lea rdx, str.DeriveCapabilitySidsFromName
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x1402a28f8], rax
lea rcx, [0x1402a2900]
call fcn.140172aa8
mov r14, qword [0x1402a28f8]
test r14, r14
je 0x140077b60
mov ecx, 0x80
call fcn.140172a4c
mov rdi, rax
xor eax, eax
lea rdx, [rsp + 0x48]
mov qword [rdx], rax
lea r8, [rsp + 0x44]
mov dword [r8], eax
lea r9, [rsp + 0x38]
mov qword [r9], rax
lea rcx, [rsp + 0x34]
mov dword [rcx], eax
mov qword [rsp + 0x20], rcx
mov rcx, rbx
mov rax, r14
call qword [case.0x1401d7990.0]
test eax, eax
je 0x140077ba0
test rdi, rdi
je 0x140077d70
mov rax, qword [rsp + 0x48]
mov qword [rdi], rax
cmp rdi, 0xfffffffffffffff8
je 0x140077d70
lea r15, [rdi + 0x80]
mov rax, qword [rsp + 0x38]
mov qword [rdi + 8], rax
mov r14, rdi
add r14, 0x10
cmp dword [rsp + 0x44], 0
je 0x140077a11
xor r12d, r12d
mov rbx, qword [rsp + 0x48]
cmp r14, r15
jae 0x140077bba
test r14, r14
je 0x140077d70
mov rax, qword [rbx + r12*8]
mov qword [r14], rax
add r14, 8
cmp rdi, r14
je 0x140077b74
inc r12
mov eax, dword [rsp + 0x44]
cmp r12, rax
jb 0x1400779da
cmp dword [rsp + 0x34], 0
jne 0x140077a35
mov rbx, rdi
mov rdi, r14
mov byte [rsi], 0
xorps xmm0, xmm0
movups xmmword [rsi + 8], xmm0
mov qword [rsi + 0x18], 0
jmp 0x140077ad3
xor r12d, r12d
mov rbx, rdi
mov rdi, r14
mov r14, qword [rsp + 0x38]
cmp rdi, r15
jae 0x140077c97
test rdi, rdi
je 0x140077d70
mov rax, qword [r14 + r12*8]
mov qword [rdi], rax
add rdi, 8
cmp rbx, rdi
je 0x140077b74
inc r12
mov eax, dword [rsp + 0x34]
cmp r12, rax
jb 0x140077a3e
test eax, eax
je 0x140077a1e
mov rax, qword [rsp + 0x38]
mov r14, qword [rax]
test r14, r14
je 0x140077a1e
mov rcx, r14
call qword [sym.imp.ADVAPI32.dll_IsValidSid]
test eax, eax
je 0x140077a1e
mov rcx, r14
call qword [sym.imp.ADVAPI32.dll_GetLengthSid]
test eax, eax
je 0x140077da6
mov r12d, eax
mov rcx, r12
call fcn.140172a4c
mov r15, rax
lea r13, [rax + r12]
mov rcx, rax
mov rdx, r14
mov r8, r12
call fcn.140177150
mov byte [rsi], 1
mov qword [rsi + 8], r15
mov qword [rsi + 0x10], r13
mov qword [rsi + 0x18], r13
test rbx, rbx
je 0x140077b13
cmp rdi, rbx
je 0x140077b0b
add rdi, 0xfffffffffffffff8
mov r14, qword [sym.imp.KERNEL32.dll_LocalFree]
test rdi, rdi
je 0x140077b34
mov rcx, qword [rdi]
mov qword [rdi], 0
test rcx, rcx
je 0x140077aff
call r14
lea rax, [rdi - 8]
cmp rdi, rbx
mov rdi, rax
jne 0x140077ae8
mov rcx, rbx
call fcn.140172a44
mov rcx, qword [rsp + 0x50]
xor rcx, rsp
call fcn.1401756e0
mov rax, rsi
add rsp, 0x58
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
lea rax, str.null_pointer_given_to_destroy_at
mov qword [rsp + 0x20], rax
lea rcx, str._s:_d:_assertion__s_failed:__s
lea rdx, str....._buildtools_third_partylibc_trunkinclude__memoryconstruct_at.h
lea r9, str.__loc___nullptr
mov r8d, 0x3f
call fcn.1401b2820
mov byte [rsi], 0
xorps xmm0, xmm0
movups xmmword [rsi + 8], xmm0
mov qword [rsi + 0x18], 0
jmp 0x140077b13
lea rax, str.back___called_on_an_empty_vector
mov qword [rsp + 0x20], rax
lea rcx, str._s:_d:_assertion__s_failed:__s
lea rdx, str....._buildtools_third_partylibc_trunkinclude_vector
lea r9, str._empty__
mov r8d, 0x22a
call fcn.1401b2820
mov byte [rsi], 0
xorps xmm0, xmm0
movups xmmword [rsi + 8], xmm0
mov qword [rsi + 0x18], 0
mov rbx, rdi
jmp 0x140077ad3
mov r13, r14
sub r13, rdi
sar r13, 3
lea rcx, [r13 + 1]
mov rax, rcx
shr rax, 0x3d
jne 0x140077d9c
movabs rax, 0x1fffffffffffffff
sub r15, rdi
mov rbp, r15
sar rbp, 2
cmp rbp, rcx
cmovbe rbp, rcx
movabs rcx, 0x7ffffffffffffff8
cmp r15, rcx
cmovae rbp, rax
test rbp, rbp
je 0x140077db8
cmp rbp, rax
ja 0x140077da1
lea rcx, [rbp*8]
call fcn.140172a4c
mov r15, rax
shl r13, 3
add r13, r15
je 0x140077d70
mov rax, qword [rbx + r12*8]
mov qword [r13], rax
mov rbx, r13
cmp r14, rdi
je 0x140077c77
mov rbx, r13
mov rax, r14
mov rcx, qword [rax - 8]
mov qword [rax - 8], 0
lea rdx, [rax - 8]
mov qword [rbx - 8], rcx
add rbx, 0xfffffffffffffff8
mov rax, rdx
cmp rdx, rdi
jne 0x140077c46
add r14, 0xfffffffffffffff8
mov rcx, r14
call fcn.1401ed8b0
cmp r14, rdi
jne 0x140077c66
lea r15, [r15 + rbp*8]
add r13, 8
test rdi, rdi
je 0x140077c8c
mov rcx, rdi
call fcn.140172a44
mov r14, r13
mov rdi, rbx
jmp 0x1400779fc
mov r13, rdi
sub r13, rbx
sar r13, 3
lea rcx, [r13 + 1]
mov rax, rcx
shr rax, 0x3d
jne 0x140077d9c
movabs rax, 0x1fffffffffffffff
sub r15, rbx
mov rbp, r15
sar rbp, 2
cmp rbp, rcx
cmovbe rbp, rcx
movabs rcx, 0x7ffffffffffffff8
cmp r15, rcx
cmovae rbp, rax
test rbp, rbp
je 0x140077dc0
cmp rbp, rax
ja 0x140077da1
lea rcx, [rbp*8]
call fcn.140172a4c
mov r15, rax
shl r13, 3
add r13, r15
je 0x140077d70
mov rax, qword [r14 + r12*8]
mov qword [r13], rax
mov r14, r13
cmp rdi, rbx
je 0x140077d50
mov r14, r13
mov rax, rdi
mov rcx, qword [rax - 8]
mov qword [rax - 8], 0
lea rdx, [rax - 8]
mov qword [r14 - 8], rcx
add r14, 0xfffffffffffffff8
mov rax, rdx
cmp rdx, rbx
jne 0x140077d1f
add rdi, 0xfffffffffffffff8
mov rcx, rdi
call fcn.1401ed8b0
cmp rdi, rbx
jne 0x140077d3f
lea r15, [r15 + rbp*8]
add r13, 8
test rbx, rbx
je 0x140077d65
mov rcx, rbx
call fcn.140172a44
mov rdi, r13
mov rbx, r14
jmp 0x140077a60
lea rax, str.null_pointer_given_to_construct_at
mov qword [rsp + 0x20], rax
lea rcx, str._s:_d:_assertion__s_failed:__s
lea rdx, str....._buildtools_third_partylibc_trunkinclude__memoryconstruct_at.h
lea r9, str.__location___nullptr
mov r8d, 0x23
call fcn.1401b2820
call fcn.14018c460
call fcn.1401b3360
xor r13d, r13d
xor r15d, r15d
jmp 0x140077ac4
xor eax, eax
jmp 0x140077934
xor r15d, r15d
jmp 0x140077c23
xor r15d, r15d
jmp 0x140077d00