joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1401082f0
Capabilities:
Query or enumerate registry value
Set registry value

Disassembly:
mov r11, rsp
sub rsp, 0x98
mov rax, qword [0x140293028]
xor rax, rsp
mov qword [rsp + 0x88], rax
mov rdx, qword [rcx + 8]
lea r8, str.SOFTWAREMicrosoftWindowsCurrentVersion
mov qword [r11 - 8], rsi
lea rcx, [r11 - 0x48]
xor esi, esi
mov r9d, 0x104
mov qword [r11 - 0x40], rsi
mov qword [r11 - 0x48], rsi
mov qword [r11 - 0x38], rsi
call fcn.140018800
test eax, eax
jne 0x14010841c
mov rdx, qword [rsp + 0x50]
lea rax, [rsp + 0x40]
mov qword [rsp + 0x38], rax
lea r8, str.QualityCompat
mov dword [rsp + 0x28], 0xf013f
lea rcx, [rsp + 0x70]
mov dword [rsp + 0x20], esi
mov qword [rsp + 0xa8], rbx
mov qword [rsp + 0x78], rsi
mov qword [rsp + 0x70], rsi
mov qword [rsp + 0x80], rsi
mov dword [rsp + 0x40], esi
call fcn.140018690
mov rbx, qword [rsp + 0x70]
test eax, eax
jne 0x140108406
cmp dword [rsp + 0x40], 1
mov dword [rsp + 0x48], esi
je 0x1401083d7
lea rax, [rsp + 0x40]
mov dword [rsp + 0x40], 4
mov qword [rsp + 0x28], rax
lea r9, [rsp + 0x68]
lea rax, [rsp + 0x48]
xor r8d, r8d
lea rdx, str.cadca5fe_87d3_4b96_b7fb_a231484277cc
mov qword [rsp + 0x20], rax
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, 2
jne 0x140108406
lea rax, [rsp + 0x40]
mov dword [rsp + 0x28], 4
mov r9d, 4
mov qword [rsp + 0x20], rax
xor r8d, r8d
mov dword [rsp + 0x40], esi
lea rdx, str.cadca5fe_87d3_4b96_b7fb_a231484277cc
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test rbx, rbx
je 0x140108414
mov rcx, rbx
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov rbx, qword [rsp + 0xa8]
cmp qword [rsp + 0x50], 0
mov rsi, qword [rsp + 0x90]
je 0x140108437
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov rcx, qword [rsp + 0x88]
xor rcx, rsp
call fcn.140185380
add rsp, 0x98
ret
Function at 0x14010e900
Capabilities:
Get common file path

Disassembly:
mov qword [rsp + 0x18], rbx
push rdi
sub rsp, 0x280
mov rax, qword [0x140293028]
xor rax, rsp
mov qword [rsp + 0x270], rax
mov rbx, rcx
mov qword [rsp + 0x30], rcx
lea rax, [rsp + 0x60]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
xor ecx, ecx
call qword [sym.imp.SHELL32.dll_SHGetFolderPathW]
mov edi, eax
test eax, eax
jne 0x14010e9a1
lea rax, [rsp + 0x60]
mov r8, 0xffffffffffffffff
inc r8
cmp word [rax + r8*2], 0
jne 0x14010e951
xor eax, eax
mov qword [rbx], rax
mov qword [rbx + 0x10], rax
mov qword [rbx + 0x18], 7
mov word [rbx], ax
lea rdx, [rsp + 0x60]
mov rcx, rbx
call fcn.14000b550
mov rax, rbx
mov rcx, qword [rsp + 0x270]
xor rcx, rsp
call fcn.140185380
mov rbx, qword [rsp + 0x2a0]
add rsp, 0x280
pop rdi
ret
lea rdx, [0x14024c198]
lea rcx, [rsp + 0x38]
call fcn.140010040
nop
lea rdx, [rsp + 0x38]
mov ecx, edi
call fcn.14010e8d0
int3
Function at 0x140116cf0
Capabilities:
Create new key via cryptacquirecontext
Initialize hashing via wincrypt

Disassembly:
mov qword [rsp + 0x10], rbx
push rbp
push rsi
push rdi
lea rbp, [rsp - 0x60]
sub rsp, 0x160
mov rax, qword [0x140293028]
xor rax, rsp
mov qword [rbp + 0x50], rax
mov rdi, rcx
mov qword [rsp + 0x30], rcx
xor eax, eax
mov qword [rcx + 8], rax
lea rsi, [rcx + 0x10]
mov qword [rsi], rax
and edx, r8d
setne al
mov byte [rcx], al
test r8d, edx
je 0x140116db9
mov dword [rsp + 0x20], 0xf0000000
xor r8d, r8d
xor edx, edx
add rcx, 8
call qword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
cmp eax, 1
je 0x140116db9
xor edx, edx
mov r8d, 0x110
lea rcx, [rsp + 0x40]
call fcn.1401a8d80
call fcn.140138af0
mov qword [rsp + 0x40], rax
mov dword [rsp + 0x48], 3
lea rcx, [rsp + 0x50]
call fcn.14000f010
nop
mov rcx, qword [rsp + 0x40]
mov rax, qword [rcx]
mov rax, qword [rax + 8]
call qword [case.0x1400d90b6.0]
cmp dword [rsp + 0x48], eax
setl byte [rbp + 0x48]
jl 0x140116e60
lea rdx, str.CryptAcquireContextW_failed:
lea rcx, [rsp + 0x40]
call fcn.14004a190
jmp 0x140116e42
cmp byte [rdi], 0
je 0x140116e6d
mov qword [rsp + 0x20], rsi
xor r9d, r9d
xor r8d, r8d
mov edx, dword [rbp + 0xa0]
mov rcx, qword [rdi + 8]
call qword [sym.imp.ADVAPI32.dll_CryptCreateHash]
cmp eax, 1
je 0x140116e6d
xor edx, edx
mov r8d, 0x110
lea rcx, [rsp + 0x40]
call fcn.1401a8d80
call fcn.140138af0
mov qword [rsp + 0x40], rax
mov dword [rsp + 0x48], 3
lea rcx, [rsp + 0x50]
call fcn.14000f010
nop
mov rcx, qword [rsp + 0x40]
mov rax, qword [rcx]
mov rax, qword [rax + 8]
call qword [case.0x1400d90b6.0]
cmp dword [rsp + 0x48], eax
setl byte [rbp + 0x48]
jl 0x140116e60
lea rdx, str.CryptCreateHash_failed:
lea rcx, [rsp + 0x40]
call fcn.1400219b0
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [rsp + 0x30], eax
lea rdx, [rsp + 0x30]
mov rcx, rbx
call fcn.1400122b0
mov byte [rbp + 0x48], 1
lea rcx, [rsp + 0x40]
call fcn.14000afe0
mov byte [rdi], 0
mov rax, rdi
mov rcx, qword [rbp + 0x50]
xor rcx, rsp
call fcn.140185380
mov rbx, qword [rsp + 0x188]
add rsp, 0x160
pop rdi
pop rsi
pop rbp
ret

Function at 0x140116f60
Capabilities:
Hash data via wincrypt

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
mov rbx, r8
mov rdi, rcx
add qword [rcx + 8], rbx
mov rsi, rdx
mov rcx, qword [rcx]
cmp byte [rcx], 0
je 0x140116f94
mov rcx, qword [rcx + 0x10]
xor r9d, r9d
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
mov rcx, qword [rdi]
cmp byte [rcx + 0x18], 0
je 0x140116fb0
mov rcx, qword [rcx + 0x28]
xor r9d, r9d
mov r8d, ebx
mov rdx, rsi
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
mov rcx, qword [rdi]
cmp byte [rcx + 0x30], 0
je 0x140116fcc
mov rcx, qword [rcx + 0x40]
xor r9d, r9d
mov r8d, ebx
mov rdx, rsi
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
mov rcx, qword [rdi]
cmp byte [rcx + 0x48], 0
je 0x140116fe5
mov rcx, qword [rcx + 0x58]
xor r9d, r9d
mov r8d, ebx
mov rdx, rsi
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
ret
Function at 0x140117000
Capabilities:
Hash data via wincrypt
Read file on windows

Disassembly:
push rbp
push rsi
push rdi
mov eax, 0x2050
call fcn.1401dd070
sub rsp, rax
mov rax, qword [0x140293028]
xor rax, rsp
mov qword [rsp + 0x2040], rax
mov rsi, rdx
lea r9, [rsp + 0x30]
mov rdi, rcx
lea rdx, [rsp + 0x40]
xor ebp, ebp
mov rcx, rsi
mov r8d, 0x2000
mov dword [rsp + 0x30], ebp
mov qword [rsp + 0x20], rbp
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x14011711d
mov qword [rsp + 0x2080], rbx
nop dword [rax]
mov eax, dword [rsp + 0x30]
test eax, eax
je 0x140117115
mov rcx, qword [rdi]
mov ebx, eax
add qword [rdi + 8], rax
cmp byte [rcx], bpl
je 0x140117092
mov rcx, qword [rcx + 0x10]
lea rdx, [rsp + 0x40]
xor r9d, r9d
mov r8d, ebx
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
mov rcx, qword [rdi]
mov rax, rcx
cmp byte [rcx + 0x18], bpl
je 0x1401170b6
mov rcx, qword [rcx + 0x28]
lea rdx, [rsp + 0x40]
xor r9d, r9d
mov r8d, ebx
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
mov rcx, qword [rdi]
mov rax, rcx
cmp byte [rcx + 0x30], bpl
je 0x1401170d4
mov rcx, qword [rcx + 0x40]
lea rdx, [rsp + 0x40]
xor r9d, r9d
mov r8d, ebx
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
mov rax, qword [rdi]
cmp byte [rax + 0x48], bpl
je 0x1401170ef
mov rcx, qword [rax + 0x58]
lea rdx, [rsp + 0x40]
xor r9d, r9d
mov r8d, ebx
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
lea r9, [rsp + 0x30]
mov qword [rsp + 0x20], rbp
mov r8d, 0x2000
lea rdx, [rsp + 0x40]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x140117060
mov rbx, qword [rsp + 0x2080]
mov rcx, qword [rsp + 0x2040]
xor rcx, rsp
call fcn.140185380
add rsp, 0x2050
pop rdi
pop rsi
pop rbp
ret
Function at 0x140117450
Capabilities:
Encrypt or decrypt data via bcrypt

Disassembly:
mov qword [rsp + 0x10], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x1f80]
mov eax, 0x2080
call fcn.1401dd070
sub rsp, rax
mov rax, qword [0x140293028]
xor rax, rsp
mov qword [rbp + 0x1f70], rax
mov r13, r8
mov r12, rdx
mov rsi, rcx
xor r14d, r14d
mov rax, qword [rcx]
movsxd r9, dword [rax + 4]
test byte [r9 + rcx + 0x10], 6
jne 0x140117645
cmp r14, r12
ja 0x140117645
mov r8d, 0x2000
lea rdx, [rsp + 0x70]
mov rcx, rsi
call fcn.1400c69f0
mov r15d, dword [rsi + 8]
test r15d, r15d
je 0x1401175f8
cmp r14, r12
jae 0x140117641
xorps xmm0, xmm0
xor eax, eax
movdqu xmmword [rsp + 0x58], xmm0
mov qword [rsp + 0x68], rax
lfence
mov ecx, r15d
call fcn.140012d70
mov qword [rsp + 0x58], rax
lea rbx, [rax + r15]
mov qword [rsp + 0x68], rbx
mov r8d, r15d
xor edx, edx
mov rcx, rax
call fcn.1401a8d80
mov qword [rsp + 0x60], rbx
mov r11, qword [rsp + 0x58]
sub rbx, r11
mov dword [rsp + 0x50], ebx
mov r10, qword [r13 + 0x10]
mov rax, qword [r13 + 8]
mov rcx, qword [rax]
lea rdx, [r15 + r14]
mov rax, qword [r13]
xor r9d, r9d
cmp rdx, qword [rax]
setae r9b
mov dword [rsp + 0x48], r9d
lea rax, [rsp + 0x50]
mov qword [rsp + 0x40], rax
mov dword [rsp + 0x38], ebx
mov qword [rsp + 0x30], r11
mov dword [rsp + 0x28], 0x10
mov qword [rsp + 0x20], r10
xor r9d, r9d
mov r8d, r15d
lea rdx, [rsp + 0x70]
mov rcx, qword [rcx + 8]
call qword [sym.imp.bcrypt.dll_BCryptDecrypt]
test eax, eax
js 0x140117609
mov r8d, dword [rsp + 0x50]
mov rdx, qword [rsp + 0x58]
mov rcx, qword [r13 + 0x18]
call fcn.140116f60
mov r8d, dword [rsp + 0x50]
mov rdx, qword [rsp + 0x58]
mov rcx, qword [r13 + 0x20]
call fcn.1400f2690
mov eax, dword [rsp + 0x50]
add r14, rax
mov rcx, qword [rsp + 0x58]
test rcx, rcx
je 0x1401175f8
mov rdx, qword [rsp + 0x68]
sub rdx, rcx
mov rax, rcx
cmp rdx, 0x1000
jb 0x1401175e1
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x140117671
call fcn.1401853a0
xorps xmm0, xmm0
movdqu xmmword [rsp + 0x58], xmm0
mov qword [rsp + 0x68], 0
mov rax, qword [rsi]
movsxd rcx, dword [rax + 4]
test byte [rcx + rsi + 0x10], 6
jmp 0x14011749f
mov rcx, qword [rsp + 0x58]
test rcx, rcx
je 0x140117641
mov rdx, qword [rsp + 0x68]
sub rdx, rcx
mov rax, rcx
cmp rdx, 0x1000
jb 0x14011763c
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x140117671
call fcn.1401853a0
xor al, al
jmp 0x140117647
mov al, 1
mov rcx, qword [rbp + 0x1f70]
xor rcx, rsp
call fcn.140185380
mov rbx, qword [rsp + 0x20c8]
add rsp, 0x2080
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
call fcn.1401b3c00
int3
Function at 0x140117680
Capabilities:
Hash data via wincrypt

Disassembly:
mov qword [rsp + 0x20], rsi
push rdi
mov eax, 0x2030
call fcn.1401dd070
sub rsp, rax
mov rax, qword [0x140293028]
xor rax, rsp
mov qword [rsp + 0x2020], rax
mov rax, qword [rdx]
mov rdi, rdx
mov rsi, rcx
movsxd r8, dword [rax + 4]
test byte [r8 + rdx + 0x10], 6
jne 0x140117784
mov qword [rsp + 0x2050], rbx
nop word [rax + rax]
mov r8d, 0x2000
lea rdx, [rsp + 0x20]
mov rcx, rdi
call fcn.1400c69f0
mov rbx, qword [rdi + 8]
test rbx, rbx
je 0x14011776a
mov rcx, qword [rsi]
movsxd rax, ebx
add qword [rsi + 8], rax
cmp byte [rcx], 0
je 0x140117713
mov rcx, qword [rcx + 0x10]
lea rdx, [rsp + 0x20]
xor r9d, r9d
mov r8d, ebx
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
mov rcx, qword [rsi]
cmp byte [rcx + 0x18], 0
je 0x140117731
mov rcx, qword [rcx + 0x28]
lea rdx, [rsp + 0x20]
xor r9d, r9d
mov r8d, ebx
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
mov rcx, qword [rsi]
cmp byte [rcx + 0x30], 0
je 0x14011774f
mov rcx, qword [rcx + 0x40]
lea rdx, [rsp + 0x20]
xor r9d, r9d
mov r8d, ebx
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
mov rcx, qword [rsi]
cmp byte [rcx + 0x48], 0
je 0x14011776a
mov rcx, qword [rcx + 0x58]
lea rdx, [rsp + 0x20]
xor r9d, r9d
mov r8d, ebx
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
mov rax, qword [rdi]
movsxd rcx, dword [rax + 4]
test byte [rcx + rdi + 0x10], 6
je 0x1401176d0
mov rbx, qword [rsp + 0x2050]
mov rcx, qword [rsp + 0x2020]
xor rcx, rsp
call fcn.140185380
mov rsi, qword [rsp + 0x2058]
add rsp, 0x2030
pop rdi
ret
Function at 0x140117950
Capabilities:
Decode data using base64 via winapi

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
push r14
push r15
sub rsp, 0xb0
mov rax, qword [0x140293028]
xor rax, rsp
mov qword [rsp + 0xa0], rax
mov r14, rdx
mov rdi, rcx
mov qword [rsp + 0x80], rcx
mov r15, qword [rdx + 0x10]
xor esi, esi
test r15, r15
jne 0x1401179a5
mov qword [rcx], rsi
mov qword [rcx + 0x10], rsi
mov qword [rcx + 0x18], 0xf
mov byte [rcx], sil
jmp 0x140117b20
mov dword [rsp + 0x80], esi
mov rcx, r14
cmp qword [rdx + 0x18], 0x10
jb 0x1401179b9
mov rcx, qword [rdx]
mov qword [rsp + 0x30], rsi
mov qword [rsp + 0x28], rsi
lea rax, [rsp + 0x80]
mov qword [rsp + 0x20], rax
xor r9d, r9d
lea r8d, [r9 + 1]
mov edx, r15d
call qword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
test eax, eax
je 0x140117b50
xorps xmm0, xmm0
mov ebp, dword [rsp + 0x80]
movdqu xmmword [rsp + 0x88], xmm0
mov qword [rsp + 0x98], rsi
test rbp, rbp
je 0x140117a74
cmp rbp, 0x1000
jb 0x140117a40
lea rcx, [rbp + 0x27]
cmp rcx, rbp
jbe 0x140117b6d
lfence
call fcn.140185648
mov rcx, rax
test rax, rax
je 0x140117b4a
add rax, 0x27
and rax, 0xffffffffffffffe0
mov qword [rax - 8], rcx
jmp 0x140117a4b
lfence
mov rcx, rbp
call fcn.140185648
mov qword [rsp + 0x88], rax
lea rbx, [rax + rbp]
mov qword [rsp + 0x98], rbx
mov r8, rbp
xor edx, edx
mov rcx, rax
call fcn.1401a8d80
mov qword [rsp + 0x90], rbx
cmp qword [r14 + 0x18], 0x10
jb 0x140117a7e
mov r14, qword [r14]
mov qword [rsp + 0x30], rsi
mov qword [rsp + 0x28], rsi
lea rax, [rsp + 0x80]
mov qword [rsp + 0x20], rax
mov r9, qword [rsp + 0x88]
mov r8d, 1
mov edx, r15d
mov rcx, r14
call qword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
test eax, eax
je 0x140117b73
mov r8d, dword [rsp + 0x80]
mov qword [rdi], rsi
mov qword [rdi + 0x10], rsi
mov qword [rdi + 0x18], 0xf
mov byte [rdi], 0
mov rdx, qword [rsp + 0x88]
mov rcx, rdi
call fcn.140010ea0
nop
mov rcx, qword [rsp + 0x88]
test rcx, rcx
je 0x140117b20
mov rdx, qword [rsp + 0x98]
sub rdx, rcx
mov rax, rcx
cmp rdx, 0x1000
jb 0x140117b1b
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x140117b4a
call fcn.1401853a0
mov rax, rdi
mov rcx, qword [rsp + 0xa0]
xor rcx, rsp
call fcn.140185380
mov rbx, qword [rsp + 0xf0]
add rsp, 0xb0
pop r15
pop r14
pop rdi
pop rsi
pop rbp
ret
call fcn.1401b3c00
int3
lea rdx, [0x14024c7f8]
lea rcx, [rsp + 0x40]
call fcn.140010040
nop
lea rcx, [rsp + 0x40]
call fcn.140030650
nop
call fcn.140008770
nop
lea rdx, str.CryptStringToBinaryA_2_
lea rcx, [rsp + 0x60]
call fcn.140010040
nop
lea rcx, [rsp + 0x60]
call fcn.140030650
int3
Function at 0x140118360
Capabilities:
Hash data via wincrypt

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
sub rsp, 0x40
mov rax, qword [0x140293028]
xor rax, rsp
mov qword [rsp + 0x30], rax
mov rbx, rdx
mov rbp, rcx
mov qword [rsp + 0x20], rcx
xorps xmm0, xmm0
movups xmmword [rsp + 0x20], xmm0
mov edx, 2
lea rcx, [rsp + 0x20]
call fcn.140116e90
nop
mov edi, dword [rbx + 0x10]
mov rsi, qword [rbx + 8]
add qword [rsp + 0x28], rdi
mov rbx, qword [rsp + 0x20]
cmp byte [rbx], 0
je 0x1401183c7
xor r9d, r9d
mov r8d, edi
mov rdx, rsi
mov rcx, qword [rbx + 0x10]
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
cmp byte [rbx + 0x18], 0
je 0x1401183e0
xor r9d, r9d
mov r8d, edi
mov rdx, rsi
mov rcx, qword [rbx + 0x28]
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
cmp byte [rbx + 0x30], 0
je 0x1401183f9
xor r9d, r9d
mov r8d, edi
mov rdx, rsi
mov rcx, qword [rbx + 0x40]
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
cmp byte [rbx + 0x48], 0
je 0x140118412
xor r9d, r9d
mov r8d, edi
mov rdx, rsi
mov rcx, qword [rbx + 0x58]
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
mov r8d, 2
mov rdx, rbp
lea rcx, [rsp + 0x20]
call fcn.1401177b0
nop
lea rcx, [rsp + 0x20]
call fcn.1401171d0
mov rax, rbp
mov rcx, qword [rsp + 0x30]
xor rcx, rsp
call fcn.140185380
mov rbx, qword [rsp + 0x70]
add rsp, 0x40
pop rdi
pop rsi
pop rbp
ret
Function at 0x140119dd0
Capabilities:
Decode data using base64 via winapi

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rsi
push rbp
push rdi
push r12
push r14
push r15
lea rbp, [rsp - 0x37]
sub rsp, 0xf0
mov rax, qword [0x140293028]
xor rax, rsp
mov qword [rbp + 0x2f], rax
mov rsi, rcx
mov qword [rbp - 0x71], rcx
xor r12d, r12d
mov dword [rbp - 0x79], r12d
mov dword [rbp + 0xf], r12d
mov r14d, dword [rdx + 8]
mov r15, qword [rdx]
mov qword [rsp + 0x30], r12
mov qword [rsp + 0x28], r12
lea rax, [rbp + 0xf]
mov qword [rsp + 0x20], rax
xor r9d, r9d
lea r8d, [r12 + 6]
mov edx, r14d
mov rcx, r15
call qword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
test eax, eax
je 0x140119f81
mov eax, dword [rbp + 0xf]
test eax, eax
je 0x140119f9c
xorps xmm0, xmm0
mov edi, eax
movdqu xmmword [rbp + 0x17], xmm0
mov qword [rbp + 0x27], r12
test eax, eax
je 0x140119ec0
cmp rax, 0x1000
jb 0x140119e98
lea rcx, [rax + 0x27]
cmp rcx, rax
jbe 0x140119fbd
lfence
call fcn.140185648
mov rcx, rax
test rax, rax
je 0x140119f7b
add rax, 0x27
and rax, 0xffffffffffffffe0
mov qword [rax - 8], rcx
jmp 0x140119ea3
lfence
mov rcx, rdi
call fcn.140185648
mov qword [rbp + 0x17], rax
lea rbx, [rax + rdi]
mov qword [rbp + 0x27], rbx
mov r8, rdi
xor edx, edx
mov rcx, rax
call fcn.1401a8d80
mov qword [rbp + 0x1f], rbx
mov qword [rsp + 0x30], r12
mov qword [rsp + 0x28], r12
lea rax, [rbp + 0xf]
mov qword [rsp + 0x20], rax
mov r9, qword [rbp + 0x17]
mov r8d, 6
mov edx, r14d
mov rcx, r15
call qword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
test eax, eax
je 0x140119fc3
xor eax, eax
mov qword [rsi], rax
mov r8d, dword [rbp + 0xf]
mov rdx, qword [rbp + 0x17]
lea ecx, [rax + 1]
call qword [sym.imp.CRYPT32.dll_CertCreateCertificateContext]
mov qword [rsi], rax
mov dword [rbp - 0x79], 1
test rax, rax
je 0x140119fde
mov rcx, qword [rbp + 0x17]
test rcx, rcx
je 0x140119f50
mov rdx, qword [rbp + 0x27]
sub rdx, rcx
mov rax, rcx
cmp rdx, 0x1000
jb 0x140119f4b
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x140119f7b
call fcn.1401853a0
mov rax, rsi
mov rcx, qword [rbp + 0x2f]
xor rcx, rsp
call fcn.140185380
lea r11, [rsp + 0xf0]
mov rbx, qword [r11 + 0x40]
mov rsi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r12
pop rdi
pop rbp
ret
call fcn.1401b3c00
int3
lea rdx, str.CryptStringToBinaryA_failed_to_determine_length
lea rcx, [rbp - 0x51]
call fcn.140010040
nop
lea rcx, [rbp - 0x51]
call fcn.140030650
nop
lea rdx, str.CryptStringToBinaryA___returned_0_length
lea rcx, [rbp - 0x69]
call fcn.140030560
lea rdx, [0x14028fd98]
lea rcx, [rbp - 0x69]
call fcn.1401a8f20
int3
call fcn.140008770
nop
lea rdx, str.CryptStringToBinaryA_failed_to_convert_string
lea rcx, [rbp - 0x31]
call fcn.140010040
nop
lea rcx, [rbp - 0x31]
call fcn.140030650
nop
lea rdx, str.Decoding_certificate
lea rcx, [rbp - 0x11]
call fcn.140010040
nop
lea rcx, [rbp - 0x11]
call fcn.140030650
int3
Function at 0x14011f340
Capabilities:
Query or enumerate registry value

Disassembly:
mov r11, rsp
mov qword [r11 + 0x10], rbx
mov qword [r11 + 0x18], rsi
push rdi
sub rsp, 0xe0
mov rax, qword [0x140293028]
xor rax, rsp
mov qword [rsp + 0xd8], rax
mov rbx, rcx
mov qword [rsp + 0x50], rcx
xorps xmm0, xmm0
movups xmmword [r11 - 0x40], xmm0
xor esi, esi
mov qword [r11 - 0x38], rsi
lea rax, vtable.RegistryAccess.0
mov qword [r11 - 0x40], rax
lea rax, [r11 - 0x38]
mov qword [rsp + 0x20], rax
mov r9d, 0x20219
xor r8d, r8d
lea rdx, str.SoftwareSophosAutoUpdate
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov edi, eax
test eax, eax
jne 0x14011f57e
lea rax, [rsp + 0xa0]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rsi
lea r9, [rsp + 0xa4]
xor r8d, r8d
lea rdx, str.ProductType
mov rcx, qword [rsp + 0xb0]
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov edi, eax
test eax, eax
jne 0x14011f59d
mov edx, dword [rsp + 0xa0]
mov ecx, dword [rsp + 0xa4]
call fcn.1401338b0
mov r9d, dword [rsp + 0xa0]
lea r8, str.ProductType
lea rdx, [rsp + 0xb8]
lea rcx, [rsp + 0xa8]
call fcn.140134c10
nop
lea rax, [rsp + 0xb8]
cmp qword [rsp + 0xd0], 8
cmovae rax, qword [rsp + 0xb8]
mov qword [rsp + 0x30], rax
mov rax, qword [rsp + 0xc8]
mov qword [rsp + 0x38], rax
movaps xmm0, xmmword [rsp + 0x30]
movdqa xmmword [rsp + 0x30], xmm0
lea rdx, [rsp + 0x30]
lea rcx, [rsp + 0x60]
call fcn.1401577f0
nop
lea rcx, [rbx + 0x108]
cmp rcx, rax
je 0x14011f494
mov r8, qword [rax + 0x10]
cmp qword [rax + 0x18], 0x10
jb 0x14011f48b
mov rax, qword [rax]
mov rdx, rax
call fcn.140010ea0
nop
mov rdx, qword [rsp + 0x78]
cmp rdx, 0x10
jb 0x14011f4d2
inc rdx
mov rcx, qword [rsp + 0x60]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14011f4cc
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14011f5c2
call fcn.1401853a0
nop
mov rdx, qword [rsp + 0xd0]
cmp rdx, 8
jb 0x14011f51a
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0xb8]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14011f515
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14011f5c8
call fcn.1401853a0
mov qword [rsp + 0xc8], rsi
mov qword [rsp + 0xd0], 7
mov word [rsp + 0xb8], si
lea rax, vtable.RegistryHandle.0
mov qword [rsp + 0xa8], rax
mov rcx, qword [rsp + 0xb0]
test rcx, rcx
je 0x14011f559
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
nop
mov rcx, qword [rsp + 0xd8]
xor rcx, rsp
call fcn.140185380
lea r11, [rsp + 0xe0]
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rsp, r11
pop rdi
ret
lea rdx, str.Failed_to_open_registry_key
lea rcx, [rsp + 0x60]
call fcn.140010040
nop
lea rdx, [rsp + 0x60]
mov ecx, edi
call fcn.140030620
nop
lea rdx, str.Failed_to_get_registry_value_length
lea rcx, [rsp + 0x80]
call fcn.140010040
nop
lea rdx, [rsp + 0x80]
mov ecx, edi
call fcn.140030620
nop
call fcn.1401b3c00
nop
call fcn.1401b3c00
int3
Function at 0x140127900
Capabilities:
Delete registry value

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0xf0
movaps xmmword [rsp + 0xe0], xmm6
mov rbx, r8
mov rax, rdx
mov dword [rsp + 0x20], 0
lea rcx, str.Py__
mov qword [rsp + 0x28], rcx
movaps xmm6, xmmword [rsp + 0x20]
mov rdx, r8
cmp qword [r8 + 0x18], 8
jb 0x140127941
mov rdx, qword [r8]
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
test eax, eax
je 0x140127970
lea ecx, [rax - 2]
cmp ecx, 1
jbe 0x14012796b
mov dword [rsp + 0x20], eax
lea rax, [0x1402984b8]
mov qword [rsp + 0x28], rax
movaps xmm6, xmmword [rsp + 0x20]
xor dil, dil
jmp 0x140127973
mov dil, 1
mov qword [rsp + 0x30], 0
mov qword [rsp + 0x40], 0
mov qword [rsp + 0x48], 0xf
mov byte [rsp + 0x30], 0
mov r8d, 0xb
lea rdx, str.DeleteValue
lea rcx, [rsp + 0x30]
call fcn.140010ea0
nop
movd eax, xmm6
test eax, eax
jne 0x140127a0f
mov rdx, qword [rsp + 0x48]
cmp rdx, 0x10
jb 0x1401279ec
inc rdx
mov rcx, qword [rsp + 0x30]
mov rax, rcx
cmp rdx, 0x1000
jb 0x1401279e7
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x140127a09
call fcn.1401853a0
movzx eax, dil
mov rbx, qword [rsp + 0x100]
movaps xmm6, xmmword [rsp + 0xe0]
add rsp, 0xf0
pop rdi
ret
call fcn.1401b3c00
nop
lea rdx, [rsp + 0x50]
mov rcx, rbx
call fcn.14000fc10
movups xmm0, xmmword [rax]
movaps xmmword [rsp + 0x20], xmm0
lea rdx, [rsp + 0x20]
lea rcx, [rsp + 0x60]
call fcn.1401577f0
mov rbx, rax
lea r8, [0x14024ddac]
lea rdx, [rsp + 0x30]
lea rcx, [rsp + 0x80]
call fcn.140062490
nop
mov r8, rbx
mov rdx, rax
lea rcx, [rsp + 0xa0]
call fcn.14002f410
nop
lea r8, str.__failed
mov rdx, rax
lea rcx, [rsp + 0xc0]
call fcn.140027ce0
nop
movdqa xmmword [rsp + 0x20], xmm6
mov rdx, rax
lea rcx, [rsp + 0x20]
call fcn.1401297c0
int3