joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140003b18
Capabilities:
Encrypt data using des via winapi

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r12
push r13
push r14
sub rsp, 0x30
mov r14, rcx
mov esi, r9d
mov ecx, 0x6603
xor ebx, ebx
mov r12, r8
mov r13d, edx
lea ebp, [rsi + 0xc]
cmp edx, ecx
je 0x140003bb8
lea ecx, [rbx + 0x40]
mov edx, ebp
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov rdi, rax
cmp rax, rbx
je 0x140003be6
lea rcx, [rax + 0xc]
mov r8, rsi
mov rdx, r12
mov byte [rax], 8
mov byte [rax + 1], 2
mov word [rax + 2], bx
mov dword [rax + 4], r13d
mov dword [rax + 8], esi
call sub.msvcrt.dll_memcpy
mov r11, qword [rsp + 0x78]
mov eax, dword [rsp + 0x70]
xor r9d, r9d
mov qword [rsp + 0x28], r11
mov r8d, ebp
mov rdx, rdi
mov rcx, r14
mov dword [rsp + 0x20], eax
call qword [sym.imp.ADVAPI32.dll_CryptImportKey]
mov rcx, rdi
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x140003be6
mov rax, qword [rsp + 0x80]
cmp rax, rbx
je 0x140003be6
mov r9d, dword [rsp + 0x70]
mov qword [rsp + 0x28], rax
mov rax, qword [rsp + 0x78]
mov r8d, esi
mov rdx, r12
mov qword [rsp + 0x20], rax
call fcn.140004704
mov ebx, eax
mov rbp, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
mov rdi, qword [rsp + 0x68]
mov eax, ebx
mov rbx, qword [rsp + 0x50]
add rsp, 0x30
pop r14
pop r13
pop r12
ret

Function at 0x140003c08
Capabilities:
Encode data using xor

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push r12
push r13
push r14
sub rsp, 0x150
xor edi, edi
cmp r8d, dword [rsp + 0x190]
mov r12, r9
setae dil
mov ebx, r8d
mov rsi, rdx
mov r13d, ecx
test edi, edi
je 0x140003c52
mov r8d, dword [rsp + 0x190]
mov rcx, r9
jmp 0x140003d04
mov r14d, Ordinal_69
lea rcx, [rsp + 0x70]
lea edx, [r14 - 0xa]
mov r8, r14
call sub.msvcrt.dll_memset
lea edx, [r14 + 0x1c]
lea rcx, [rsp + 0x30]
mov r8, r14
call sub.msvcrt.dll_memset
test ebx, ebx
je 0x140003ca2
lea rcx, [rsp + 0x70]
lea rdx, [rsp + 0x30]
mov r8, rbx
sub rcx, rsi
sub rdx, rsi
mov al, byte [rsi]
xor byte [rcx + rsi], al
xor byte [rdx + rsi], al
inc rsi
sub r8, 1
jne 0x140003c91
lea r9, [rsp + 0xb0]
lea rdx, [rsp + 0x70]
mov r8d, r14d
mov ecx, r13d
mov dword [rsp + 0x20], ebx
call fcn.140003970
test eax, eax
je 0x140003d09
lea r9, [rsp + rbx + 0xb0]
lea rdx, [rsp + 0x30]
mov r8d, r14d
mov ecx, r13d
mov dword [rsp + 0x20], ebx
call fcn.140003970
mov edi, eax
test eax, eax
je 0x140003d09
lea ecx, [rbx + rbx]
lea rdx, [rsp + 0xb0]
cmp dword [rsp + 0x190], ecx
cmovb ecx, dword [rsp + 0x190]
mov r8d, ecx
mov rcx, r12
call sub.msvcrt.dll_memcpy
lea r11, [rsp + 0x150]
mov eax, edi
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rdi, qword [r11 + 0x30]
mov rsp, r11
pop r14
pop r13
pop r12
ret
Function at 0x140004270
Capabilities:
Encode data using xor
Encrypt or decrypt via wincrypt

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x20], rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x60
xor ebp, ebp
mov rdi, r9
mov ebx, r8d
lea r15d, [rbp + 0x10]
mov r12, rdx
mov rsi, rcx
cmp r8d, r15d
jbe 0x140004436
lea r9, [rax - 0x58]
xor r8d, r8d
xor edx, edx
call qword [sym.imp.ADVAPI32.dll_CryptDuplicateKey]
test eax, eax
je 0x140004465
lea edx, [rbp + 1]
xor r9d, r9d
mov r8, rdi
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_CryptSetKeyParam]
test eax, eax
je 0x140004429
lea edi, [rbx + 0xf]
mov r13d, r15d
shr edi, 4
and ebx, 0xf
cmovne r13d, ebx
cmp edi, 2
jbe 0x140004325
lea eax, [rdi - 2]
xor r9d, r9d
xor r8d, r8d
shl eax, 4
xor edx, edx
mov rcx, rsi
mov dword [rsp + 0xa0], eax
lea rax, [rsp + 0xa0]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r12
call qword [sym.imp.ADVAPI32.dll_CryptDecrypt]
test eax, eax
je 0x140004429
lea eax, [r13 + 0x10]
lea r14d, [rdi - 2]
lea rcx, [rsp + 0x40]
shl r14d, 4
mov r8d, eax
mov ebx, eax
add r14, r12
mov rdx, r14
call sub.msvcrt.dll_memcpy
mov r11d, r15d
lea rax, [rsp + rbx + 0x40]
sub r11d, r13d
xor edx, edx
mov rcx, rax
mov r8d, r11d
mov r15d, r11d
mov qword [rsp + 0x38], rax
call sub.msvcrt.dll_memset
mov rcx, qword [rsp + 0x30]
lea rax, [rsp + 0xa0]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x40]
mov ebx, 0x10
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov qword [rsp + 0x20], rax
mov dword [rsp + 0xa0], ebx
call qword [sym.imp.ADVAPI32.dll_CryptDecrypt]
test eax, eax
je 0x140004429
lea rdx, [rsp + 0x40]
mov r9, rbx
mov al, byte [rdx + 0x10]
xor byte [rdx], al
inc rdx
sub r9, 1
jne 0x1400043ac
mov rcx, qword [rsp + 0x38]
lea rdx, [rsp + r13 + 0x40]
mov r8, r15
mov ebx, r13d
call sub.msvcrt.dll_memcpy
lea rax, [rsp + 0xa0]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x50]
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rcx, rsi
mov qword [rsp + 0x20], rax
mov dword [rsp + 0xa0], SQLAllocHandle
call qword [sym.imp.ADVAPI32.dll_CryptDecrypt]
mov ebp, eax
test eax, eax
je 0x140004429
movdqu xmm0, xmmword [rsp + 0x50]
shl edi, 4
lea rdx, [rsp + 0x40]
lea ecx, [rdi - 0x10]
mov r8, rbx
add rcx, r12
movdqu xmmword [r14], xmm0
call sub.msvcrt.dll_memcpy
mov rcx, qword [rsp + 0x30]
call qword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
jmp 0x140004465
cmp ebx, r15d
jne 0x140004465
lea rax, [rsp + 0xa0]
xor r9d, r9d
xor r8d, r8d
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rdx
xor edx, edx
mov dword [rsp + 0xa0], r15d
call qword [sym.imp.ADVAPI32.dll_CryptDecrypt]
mov ebp, eax
lea r11, [rsp + 0x60]
mov eax, ebp
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret
Function at 0x140004488
Capabilities:
Encrypt or decrypt via wincrypt

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x20], rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x60
xor r13d, r13d
mov rax, r9
mov ebx, r8d
lea r15d, [r13 + 0x10]
mov r12, rdx
mov rsi, rcx
cmp r8d, r15d
jbe 0x1400045c1
lea edx, [r13 + 1]
xor r9d, r9d
mov r8, rax
call qword [sym.imp.ADVAPI32.dll_CryptSetKeyParam]
test eax, eax
je 0x1400045f6
lea edi, [rbx + 0xf]
mov ebp, r15d
shr edi, 4
and ebx, 0xf
cmovne ebp, ebx
cmp edi, 2
jbe 0x140004528
lea eax, [rdi - 2]
xor r9d, r9d
xor r8d, r8d
shl eax, 4
xor edx, edx
mov rcx, rsi
mov dword [rsp + 0x30], eax
mov dword [rsp + 0xa0], eax
lea rax, [rsp + 0xa0]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r12
call qword [sym.imp.ADVAPI32.dll_CryptEncrypt]
test eax, eax
je 0x1400045f6
lea eax, [rbp + 0x10]
lea r14d, [rdi - 2]
lea rcx, [rsp + 0x40]
shl r14d, 4
mov r8d, eax
mov ebx, eax
add r14, r12
mov rdx, r14
call sub.msvcrt.dll_memcpy
mov r8d, r15d
lea rcx, [rsp + rbx + 0x40]
sub r8d, ebp
xor edx, edx
call sub.msvcrt.dll_memset
mov r11d, Ordinal_36
lea rax, [rsp + 0xa0]
mov dword [rsp + 0x30], r11d
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x40]
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov rcx, rsi
mov qword [rsp + 0x20], rax
mov dword [rsp + 0xa0], r11d
call qword [sym.imp.ADVAPI32.dll_CryptEncrypt]
mov r13d, eax
test eax, eax
je 0x1400045f6
movdqu xmm0, xmmword [rsp + 0x50]
shl edi, 4
lea rdx, [rsp + 0x40]
sub edi, r15d
mov r8d, ebp
mov ecx, edi
add rcx, r12
movdqu xmmword [r14], xmm0
call sub.msvcrt.dll_memcpy
jmp 0x1400045f6
cmp ebx, r15d
jne 0x1400045f6
lea rax, [rsp + 0xa0]
mov dword [rsp + 0x30], r15d
xor r9d, r9d
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rdx
xor r8d, r8d
xor edx, edx
mov dword [rsp + 0xa0], r15d
call qword [sym.imp.ADVAPI32.dll_CryptEncrypt]
mov r13d, eax
lea r11, [rsp + 0x60]
mov eax, r13d
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret
Function at 0x1400049d0
Capabilities:
Create new key via cryptacquirecontext
Initialize hashing via wincrypt

Disassembly:
push rbx
sub rsp, 0x30
and dword [rsp + 0x48], 0
mov ebx, ecx
lea rcx, [rsp + 0x58]
mov r9d, reloc.ODBC32.dll_SQLAllocHandle
xor r8d, r8d
xor edx, edx
mov dword [rsp + 0x20], 0xf0000000
call qword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
test eax, eax
je 0x140004a54
mov rcx, qword [rsp + 0x58]
lea rax, [rsp + 0x50]
xor r9d, r9d
xor r8d, r8d
mov edx, ebx
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_CryptCreateHash]
test eax, eax
je 0x140004a47
mov rcx, qword [rsp + 0x50]
and dword [rsp + 0x20], 0
xor r8d, r8d
lea edx, [r8 + 2]
lea r9, [rsp + 0x48]
call qword [sym.imp.ADVAPI32.dll_CryptGetHashParam]
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
mov rcx, qword [rsp + 0x58]
xor edx, edx
call qword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov eax, dword [rsp + 0x48]
add rsp, 0x30
pop rbx
ret

Function at 0x140004a60
Capabilities:
Create new key via cryptacquirecontext

Disassembly:
mov rax, rsp
push rbx
sub rsp, 0x40
and dword [rax + 0x10], 0
mov ebx, ecx
lea rcx, [rax - 0x18]
mov r9d, reloc.ODBC32.dll_SQLAllocHandle
xor r8d, r8d
xor edx, edx
mov dword [rax + 0x18], 4
mov dword [rax - 0x28], 0xf0000000
call qword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
test eax, eax
je 0x140004ae5
mov rcx, qword [rsp + 0x30]
lea r9, [rsp + 0x68]
xor r8d, r8d
mov edx, ebx
call qword [sym.imp.ADVAPI32.dll_CryptGenKey]
test eax, eax
je 0x140004ad8
mov rcx, qword [rsp + 0x68]
and dword [rsp + 0x20], 0
lea r9, [rsp + 0x60]
lea r8, [rsp + 0x58]
mov edx, 8
call qword [sym.imp.ADVAPI32.dll_CryptGetKeyParam]
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
mov rcx, qword [rsp + 0x30]
xor edx, edx
call qword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov eax, dword [rsp + 0x58]
shr eax, 3
add rsp, 0x40
pop rbx
ret

Function at 0x140004af4
Capabilities:
Create new key via cryptacquirecontext

Disassembly:
mov rax, rsp
push rbx
sub rsp, 0x40
and dword [rax + 0x10], 0
mov ebx, ecx
lea rcx, [rax - 0x18]
mov r9d, reloc.ODBC32.dll_SQLAllocHandle
xor r8d, r8d
xor edx, edx
mov dword [rax + 0x18], 4
mov dword [rax - 0x28], 0xf0000000
call qword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
test eax, eax
je 0x140004b79
mov rcx, qword [rsp + 0x30]
lea r9, [rsp + 0x68]
xor r8d, r8d
mov edx, ebx
call qword [sym.imp.ADVAPI32.dll_CryptGenKey]
test eax, eax
je 0x140004b6c
mov rcx, qword [rsp + 0x68]
and dword [rsp + 0x20], 0
lea r9, [rsp + 0x60]
lea r8, [rsp + 0x58]
mov edx, 9
call qword [sym.imp.ADVAPI32.dll_CryptGetKeyParam]
mov rcx, qword [rsp + 0x68]
call qword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
mov rcx, qword [rsp + 0x30]
xor edx, edx
call qword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov eax, dword [rsp + 0x58]
shr eax, 3
add rsp, 0x40
pop rbx
ret
Function at 0x140004c90
Capabilities:
Encrypt or decrypt via wincrypt

Disassembly:
mov r11, rsp
mov qword [r11 + 8], rbx
mov qword [r11 + 0x10], rbp
mov qword [r11 + 0x18], rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x50
mov r14, qword [rsp + 0xb0]
xor r12d, r12d
mov r15, r8
and qword [r11 - 0x48], r12
lea rax, [r11 - 0x30]
mov r8, rcx
mov rcx, qword [r14]
mov r13d, r9d
mov rbx, rdx
mov qword [r11 - 0x50], rax
and dword [r11 - 0x58], r12d
lea edi, [r12 + 1]
lea r9d, [r12 + 0x10]
mov edx, 0x660e
mov dword [rsp + 0x40], edi
call fcn.140003b18
test eax, eax
je 0x140004de8
mov rcx, qword [rsp + 0x48]
lea r8, [rsp + 0x40]
lea edx, [rdi + 3]
xor r9d, r9d
call qword [sym.imp.ADVAPI32.dll_CryptSetKeyParam]
test eax, eax
je 0x140004dc7
mov rcx, qword [rsp + 0x48]
xor r9d, r9d
mov r8, rbx
mov edx, edi
call qword [sym.imp.ADVAPI32.dll_CryptSetKeyParam]
test eax, eax
je 0x140004db8
lea ecx, [rdi + 0x3f]
mov rdx, r13
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov rbx, qword [rsp + 0xa0]
mov qword [rbx], rax
mov rdi, rax
test rax, rax
je 0x140004ddb
mov rbp, qword [rsp + 0xa8]
mov r8, r13
mov rdx, r15
mov rcx, rax
mov dword [rbp], r13d
call sub.msvcrt.dll_memcpy
mov rcx, qword [rsp + 0x48]
lea r8d, [r12 + 1]
xor r9d, r9d
xor edx, edx
mov qword [rsp + 0x28], rbp
mov qword [rsp + 0x20], rdi
call qword [sym.imp.ADVAPI32.dll_CryptDecrypt]
mov r12d, eax
test eax, eax
jne 0x140004ddb
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.ERROR_kull_m_crypto_genericAES128Decrypt___CryptDecrypt__0x_08x__n
mov edx, eax
call fcn.14000c020
mov rcx, qword [rbx]
call qword [sym.imp.KERNEL32.dll_LocalFree]
and dword [rbp], r12d
mov qword [rbx], rax
jmp 0x140004ddb
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.ERROR_kull_m_crypto_genericAES128Decrypt___CryptSetKeyParam__IV___0x_08x__n
jmp 0x140004dd4
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.ERROR_kull_m_crypto_genericAES128Decrypt___CryptSetKeyParam__MODE___0x_08x__n
mov edx, eax
call fcn.14000c020
mov rcx, qword [rsp + 0x48]
call qword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
jmp 0x140004dfc
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.ERROR_kull_m_crypto_genericAES128Decrypt___kull_m_crypto_hkey__0x_08x__n
mov edx, eax
call fcn.14000c020
mov rcx, qword [r14]
xor edx, edx
call qword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
lea r11, [rsp + 0x50]
mov eax, r12d
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret
Function at 0x140004eec
Capabilities:
Create new key via cryptacquirecontext

Disassembly:
mov r11, rsp
mov qword [r11 + 8], rbx
mov qword [r11 + 0x10], rbp
mov qword [r11 + 0x18], rsi
mov qword [r11 + 0x20], rdi
push r12
sub rsp, 0x70
xor ebx, ebx
lea rax, str.Microsoft_Enhanced_Cryptographic_Provider_v1.0
mov ebp, r9d
mov qword [r11 - 0x30], rax
mov qword [r11 - 0x38], rbx
mov dword [rsp + 0x50], 1
mov dword [rsp + 0x54], ebx
mov dword [rsp + 0x58], ebx
mov qword [r11 - 0x18], rbx
mov dword [rsp + 0x68], 1
mov r12, r8
mov edi, edx
mov rsi, rcx
call fcn.140012e94
mov qword [rsp + 0x40], rax
cmp rax, rbx
je 0x14000502a
mov r9d, dword [rsp + 0x50]
mov r8, qword [rsp + 0x48]
lea rcx, [rsp + 0x30]
mov rdx, rax
mov dword [rsp + 0x20], 8
call qword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
cmp eax, ebx
je 0x14000500b
mov rcx, qword [rsp + 0x30]
lea rax, [rsp + 0x38]
xor r9d, r9d
mov qword [rsp + 0x28], rax
mov r8d, ebp
mov rdx, r12
mov dword [rsp + 0x20], 1
call qword [sym.imp.ADVAPI32.dll_CryptImportKey]
cmp eax, ebx
je 0x140004feb
lea ecx, [rbx + 2]
mov r9d, 0x2000
xor r8d, r8d
xor edx, edx
mov qword [rsp + 0x20], rbx
call qword [sym.imp.CRYPT32.dll_CertOpenStore]
cmp rax, rbx
je 0x140004fde
mov r9, qword [rsp + 0xa8]
lea r8, [rsp + 0x40]
mov edx, edi
mov rcx, rsi
mov qword [rsp + 0x20], rax
call fcn.140005048
mov ebx, eax
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
jmp 0x140004fff
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.ERROR_kull_m_crypto_DerAndKeyToPfx___CryptImportKey__0x_08x__n
mov edx, eax
call fcn.14000c020
mov rcx, qword [rsp + 0x30]
call fcn.140003d2c
jmp 0x14000501f
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.ERROR_kull_m_crypto_DerAndKeyToPfx___CryptAcquireContext__0x_08x__n
mov edx, eax
call fcn.14000c020
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_LocalFree]
lea r11, [rsp + 0x70]
mov eax, ebx
mov rbx, qword [r11 + 0x10]
mov rbp, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rdi, qword [r11 + 0x28]
mov rsp, r11
pop r12
ret
Function at 0x140006058
Capabilities:
Hash data via bcrypt

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
push r12
push r13
push r14
sub rsp, 0x60
mov r13d, r9d
mov r14, r8
mov esi, edx
mov r12, rcx
xor ebx, ebx
mov dword [rax - 0x34], ebx
lea r9d, [rbx + 8]
lea r8, str.Microsoft_Primitive_Provider
lea rdx, str.SHA256
lea rcx, [rax - 0x20]
call sub.bcrypt.dll_BCryptOpenAlgorithmProvider
test eax, eax
js 0x14000619d
and dword [rsp + 0x28], ebx
lea rax, [rsp + 0x48]
mov qword [rsp + 0x20], rax
lea r9d, [rbx + 4]
lea r8, [rsp + 0x40]
lea rdx, str.ObjectLength
mov rcx, qword [rsp + 0x58]
call sub.bcrypt.dll_BCryptGetProperty
test eax, eax
js 0x140006181
mov edx, dword [rsp + 0x40]
lea ecx, [rbx + 0x40]
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov rdi, rax
test rax, rax
je 0x14000618f
and dword [rsp + 0x30], ebx
mov dword [rsp + 0x28], esi
mov qword [rsp + 0x20], r12
mov r9d, dword [rsp + 0x40]
mov r8, rax
lea rdx, [rsp + 0x50]
mov rcx, qword [rsp + 0x58]
call sub.bcrypt.dll_BCryptCreateHash
test eax, eax
js 0x140006168
xor r9d, r9d
mov r8d, r13d
mov rdx, r14
mov rcx, qword [rsp + 0x50]
call sub.bcrypt.dll_BCryptHashData
xor r9d, r9d
lea r8d, [rbx + 0x20]
mov rdx, qword [rsp + 0xa0]
mov rcx, qword [rsp + 0x50]
call sub.bcrypt.dll_BCryptFinishHash
test eax, eax
setns bl
mov dword [rsp + 0x44], ebx
test ebx, ebx
jne 0x14000615c
mov edx, eax
lea rcx, str.ERROR_kull_m_crypto_ngc_signature_derived___BCryptFinishHash:_0x_08x_n
call fcn.14000c020
mov rcx, qword [rsp + 0x50]
call sub.bcrypt.dll_BCryptDestroyHash
jmp 0x140006176
mov edx, eax
lea rcx, str.ERROR_kull_m_crypto_ngc_signature_derived___BCryptCreateHash:_0x_08x_n
call fcn.14000c020
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x14000618f
mov edx, eax
lea rcx, str.ERROR_kull_m_crypto_ngc_signature_derived___BCryptGetProperty:_0x_08x_n
call fcn.14000c020
xor edx, edx
mov rcx, qword [rsp + 0x58]
call sub.bcrypt.dll_BCryptCloseAlgorithmProvider
jmp 0x1400061ab
mov edx, eax
lea rcx, str.ERROR_kull_m_crypto_ngc_signature_derived___BCryptOpenAlgorithmProvider:_0x_08x_n
call fcn.14000c020
jmp 0x1400061bd
mov eax, ebx
lea r11, [rsp + 0x60]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rdi, qword [r11 + 0x30]
mov rsp, r11
pop r14
pop r13
pop r12
ret
Function at 0x14000811c
Capabilities:
Authenticate hmac
Encode data using xor

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0xd0
xor ebx, ebx
mov esi, edx
mov rdi, rcx
mov r12, r8
lea r15d, [rbx + 0x40]
lea rcx, [rsp + 0x50]
lea edx, [rbx + 0x36]
mov r8, r15
mov ebp, r9d
call sub.msvcrt.dll_memset
lea edx, [rbx + 0x5c]
lea rcx, [rsp + 0x90]
mov r8, r15
call sub.msvcrt.dll_memset
cmp esi, ebx
jbe 0x14000819a
lea rcx, [rsp + 0x50]
lea rdx, [rsp + 0x90]
mov r8, rsi
sub rcx, rdi
sub rdx, rdi
mov al, byte [rdi]
xor byte [rcx + rdi], al
xor byte [rdx + rdi], al
inc rdi
sub r8, 1
jne 0x140008189
lea rdx, [rbp + 0x40]
mov ecx, r15d
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov rsi, rax
cmp rax, rbx
je 0x1400082c0
lea rdx, [rsp + 0x50]
mov rcx, rax
mov r8, r15
call sub.msvcrt.dll_memcpy
lea rcx, [rsi + 0x40]
mov r8, rbp
mov rdx, r12
call sub.msvcrt.dll_memcpy
lea r8d, [rbp + 0x40]
lea r9, [rsp + 0x30]
mov rdx, rsi
mov ecx, 0x8004
mov dword [rsp + 0x20], SQLAllocHandle
call fcn.140003970
cmp eax, ebx
je 0x1400082b7
mov ebp, dword [rsp + 0x128]
mov r12d, dword [rsp + 0x138]
mov ecx, r15d
lea rdx, [r12 + rbp + 0x54]
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov rdi, rax
cmp rax, rbx
je 0x1400082b7
lea rdx, [rsp + 0x90]
mov rcx, rax
mov r8, r15
call sub.msvcrt.dll_memcpy
mov rdx, qword [rsp + 0x120]
lea rcx, [rsp + 0x30]
mov rax, qword [rcx]
mov qword [rdi + 0x40], rax
mov rax, qword [rcx + 8]
mov qword [rdi + 0x48], rax
mov eax, dword [rcx + 0x10]
mov dword [rdi + 0x50], eax
cmp rdx, rbx
je 0x14000826b
cmp ebp, ebx
je 0x14000826b
lea rcx, [rdi + 0x54]
mov r8, rbp
call sub.msvcrt.dll_memcpy
mov rdx, qword [rsp + reloc.WLDAP32.dll_Ordinal_304]
cmp rdx, rbx
je 0x14000828a
cmp r12d, ebx
je 0x14000828a
lea rcx, [rbp + rdi + 0x54]
mov r8, r12
call sub.msvcrt.dll_memcpy
mov r9, qword [rsp + 0x140]
lea r8d, [rbp + r12 + 0x54]
mov rdx, rdi
mov ecx, 0x8004
mov dword [rsp + 0x20], SQLAllocHandle
call fcn.140003970
mov rcx, rdi
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_LocalFree]
lea r11, [rsp + 0xd0]
mov eax, ebx
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret
Function at 0x140009924
Capabilities:
Encrypt or decrypt via wincrypt

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x20], r9
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x60
mov esi, dword [rcx + 0x1c]
mov eax, 0x8004
mov rbp, rcx
xor edi, edi
cmp esi, 0x8009
mov r15, rdx
cmove esi, eax
mov ecx, esi
call fcn.1400049d0
mov ecx, dword [rbp + 0x28]
call fcn.140004af4
mov ecx, dword [rbp + 0x28]
mov ebx, eax
call fcn.140004a60
lea ecx, [rdi + 0x40]
lea r13d, [rax + rbx]
mov edx, r13d
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov r12, rax
test rax, rax
je 0x140009b2a
mov dword [rsp + 0x40], 1
mov dword [rsp + 0x38], r13d
mov qword [rsp + 0x30], rax
mov eax, dword [rbp + 0x20]
lea r13d, [rdi + 0x14]
lea r14d, [rdi + 0x10]
mov dword [rsp + 0x28], eax
lea r9, [rbp + 0x34]
mov r8d, r13d
mov rdx, r15
mov ecx, esi
mov dword [rsp + 0x20], r14d
call fcn.140003fc8
test eax, eax
je 0x140009b21
mov ecx, dword [rbp + 0x28]
lea rax, [rsp + 0x58]
xor r9d, r9d
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x50]
mov r8d, ebx
mov rdx, r12
mov qword [rsp + 0x20], rax
call fcn.140004704
test eax, eax
je 0x140009b0d
mov rcx, qword [rsp + 0x50]
lea r8, [r12 + rbx]
lea edx, [rdi + 1]
xor r9d, r9d
call qword [sym.imp.ADVAPI32.dll_CryptSetKeyParam]
test eax, eax
je 0x140009ae5
mov eax, dword [rbp + 0x54]
lea ecx, [rdi + 0x40]
mov rdx, rax
mov dword [rsp + 0xa0], eax
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov rsi, rax
test rax, rax
je 0x140009ae5
mov r8d, dword [rsp + 0xa0]
mov rdx, qword [rbp + 0x4c]
mov rcx, rax
call sub.msvcrt.dll_memcpy
mov rcx, qword [rsp + 0x50]
lea r11, [rsp + 0xa0]
mov qword [rsp + 0x28], r11
xor r9d, r9d
xor r8d, r8d
xor edx, edx
mov qword [rsp + 0x20], rsi
call qword [sym.imp.ADVAPI32.dll_CryptDecrypt]
test eax, eax
je 0x140009adc
cmp dword [rbp + 0x2c], r13d
mov rcx, qword [rsp + 0xc0]
mov rdx, rsi
cmovb r13d, dword [rbp + 0x2c]
mov r8d, r13d
call sub.msvcrt.dll_memcpy
mov ebx, dword [rbp + 0x30]
mov ebp, dword [rbp + 0x2c]
mov rcx, qword [rsp + 0xb8]
cmp ebx, r14d
cmovb r14d, ebx
add rbp, rsi
mov rdx, rbp
mov r8d, r14d
call sub.msvcrt.dll_memcpy
add ebx, 0xfffffff0
mov edi, 1
je 0x140009adc
xor edx, edx
test ebx, ebx
je 0x140009adc
lea rcx, [rbp + 0x10]
test edi, edi
je 0x140009adc
xor eax, eax
cmp byte [rcx], al
sete al
inc edx
inc rcx
and edi, eax
cmp edx, ebx
jb 0x140009ac6
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rcx, qword [rsp + 0x50]
call qword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
mov rcx, qword [rsp + 0x58]
call fcn.140003d2c
test eax, eax
jne 0x140009b21
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.ERROR_kull_m_dpapi_unprotect_credhist_entry_with_shaDerivedkey___kull_m_crypto_close_hprov_delete_container__0x_08x__n
jmp 0x140009b1a
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.ERROR_kull_m_dpapi_unprotect_credhist_entry_with_shaDerivedkey___kull_m_crypto_hkey_session__0x_08x__n
mov edx, eax
call fcn.14000c020
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, edi
mov rbx, qword [rsp + 0xa8]
add rsp, 0x60
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret