joyce8/EMBER2024-capa huggingface dataset:
Function at 0x14000d570
Capabilities:
Encode data using xor

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
push rbp
push r14
push r15
lea rbp, [rax - 0x38]
sub rsp, 0x120
mov rbx, rcx
mov dword [rsp + 0x24], 0x60000
xor r15d, r15d
mov dword [rsp + 0x28], 0x860100aa
xor edx, edx
lea rcx, [rsp + 0x2c]
mov r8d, 0xf4
lea edi, [r15 + 1]
mov dword [rsp + 0x20], edi
call fcn.1400c1ef0
xor dl, dl
xor cl, cl
movzx eax, cl
add cl, dil
xor dl, byte [rsp + rax + 0x2a]
cmp cl, 2
jb 0x14000d5c3
lea rcx, [0x140100380]
mov byte [rsp + 0x2c], dl
mov byte [rsp + 0x2d], 0xbb
call fcn.14000b8b0
mov r8d, edi
lea rcx, [rsp + 0x20]
mov edx, reloc.Cabinet.dll_FCIDestroy
call fcn.140011f30
lea rcx, reloc.Cabinet.dll_FCICreate
call fcn.14000b8b0
mov esi, 0xa
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_Sleep]
mov r14d, 0x100
lea rdx, [rsp + 0x20]
mov r8d, r14d
mov rcx, rbx
call qword [sym.imp.HID.DLL_HidD_SetFeature]
test al, al
je 0x14000d770
mov ecx, esi
call qword [sym.imp.KERNEL32.dll_Sleep]
mov r8d, r14d
lea rdx, [rsp + 0x20]
mov rcx, rbx
call qword [sym.imp.HID.DLL_HidD_GetFeature]
test al, al
je 0x14000d770
cmp byte [rsp + 0x20], 3
jne 0x14000d770
movzx ebx, word [rsp + 0x26]
lea edx, [r14 - 0xe]
lea eax, [rbx - 6]
cmp ax, dx
ja 0x14000d770
lea rcx, [0x140100388]
call fcn.14000b8b0
movzx edx, bx
lea rcx, [rsp + 0x20]
add edx, 8
mov r8d, edi
call fcn.140011f30
lea rcx, reloc.Cabinet.dll_FCICreate
call fcn.14000b8b0
sub bl, 6
cmp byte [rsp + 0x28], 0xaa
jne 0x14000d770
movzx eax, byte [rsp + 0x2a]
sub eax, edi
movzx edx, bl
cmp eax, edx
jne 0x14000d770
xor r8b, r8b
lea r9d, [rdx + 2]
xor cl, cl
test r9d, r9d
je 0x14000d6de
movzx eax, cl
add cl, dil
xor r8b, byte [rsp + rax + 0x2a]
movzx eax, cl
cmp eax, r9d
jb 0x14000d6cb
cmp r8b, byte [rsp + rdx + 0x2c]
jne 0x14000d770
mov byte [rsp + rdx + 0x2d], 0xbb
movzx ecx, byte [rsp + 0x2b]
test ecx, ecx
je 0x14000d71d
sub ecx, edi
je 0x14000d770
sub ecx, edi
je 0x14000d770
sub ecx, edi
je 0x14000d770
sub ecx, edi
je 0x14000d770
sub ecx, edi
je 0x14000d770
sub ecx, 2
je 0x14000d770
sub ecx, 3
je 0x14000d770
cmp ecx, 0xf5
jne 0x14000d770
mov rsi, qword [rbp + 0x60]
mov r15d, edi
test rsi, rsi
je 0x14000d77c
mov rdi, qword [rbp + 0x68]
test rdi, rdi
je 0x14000d77c
and qword [rsi], 0
mov byte [rdi], 0
test bl, bl
je 0x14000d77c
movzx r14d, bl
mov ecx, 0x40
mov edx, r14d
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov qword [rsi], rax
test rax, rax
je 0x14000d76b
mov r8d, r14d
lea rdx, [rsp + 0x2c]
mov rcx, rax
call fcn.1400c2660
mov byte [rdi], bl
jmp 0x14000d77c
xor r15d, r15d
jmp 0x14000d77c
lea rcx, str.ERROR_rdm_send_receive___ERROR
call fcn.14000b8b0
lea r11, [rsp + 0x120]
mov eax, r15d
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rdi, qword [r11 + 0x30]
mov rsp, r11
pop r15
pop r14
pop rbp
ret
Function at 0x14000dabc
Capabilities:
Read file via mapping

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x30
mov rax, qword [r9]
xor ebx, ebx
mov rdi, r9
mov esi, r8d
mov rbp, rdx
mov dword [rax], ecx
test ecx, ecx
je 0x14000dc1a
cmp ecx, 1
jne 0x14000dc0f
lea edx, [rbx + 0x20]
lea ecx, [rbx + 0x40]
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov rcx, rax
mov rax, qword [rdi]
mov qword [rax + 8], rcx
mov rax, qword [rdi]
cmp qword [rax + 8], rbx
je 0x14000dc0f
mov eax, esi
mov rcx, rbp
neg eax
sbb r8d, r8d
and qword [rsp + 0x28], rbx
and dword [rsp + 0x20], ebx
and r8d, 2
add r8d, 2
xor r9d, r9d
xor edx, edx
call qword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov rdx, rax
mov rax, qword [rdi]
mov rcx, qword [rax + 8]
mov qword [rcx], rdx
mov rax, qword [rdi]
mov rcx, qword [rax + 8]
mov rcx, qword [rcx]
test rcx, rcx
je 0x14000dc0f
neg esi
sbb edx, edx
and qword [rsp + 0x20], rbx
and edx, 0xfffffffe
xor r9d, r9d
add edx, 4
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov rdx, rax
mov rax, qword [rdi]
mov rcx, qword [rax + 8]
mov qword [rcx + 8], rdx
mov rax, qword [rdi]
mov r8, qword [rax + 8]
mov rdx, qword [r8 + 8]
test rdx, rdx
je 0x14000dc0f
cmp dword [rdx], 0x66676572
mov rcx, rax
jne 0x14000dbf1
cmp dword [rdx + 0x1c], ebx
jne 0x14000dbf1
add rdx, 0x1000
cmp dword [rdx], 0x6e696268
jne 0x14000dbf1
mov qword [r8 + 0x10], rdx
movsxd rax, dword [rdx + 4]
add rdx, 0x20
add rdx, rax
mov rax, qword [rdi]
mov rcx, qword [rax + 8]
mov qword [rcx + 0x18], rdx
mov rcx, qword [rdi]
mov rax, qword [rcx + 8]
mov rdx, qword [rax + 0x18]
mov eax, 0x6b6e
cmp word [rdx + 4], ax
jne 0x14000dbed
test byte [rdx + 6], 0xc
je 0x14000dbed
mov ebx, 1
test ebx, ebx
jne 0x14000dc1f
mov rcx, qword [rcx + 8]
mov rcx, qword [rcx + 8]
call qword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov rax, qword [rdi]
mov rcx, qword [rax + 8]
mov rcx, qword [rcx]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rdi]
call qword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x14000dc1f
mov ebx, 1
mov rbp, qword [rsp + 0x48]
mov eax, ebx
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret
Function at 0x14000e200
Capabilities:
Query or enumerate registry value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push r14
sub rsp, 0x30
mov r9d, dword [rcx]
xor edi, edi
mov r10, r8
mov r11, rdx
mov r14, rcx
test r9d, r9d
je 0x14000e2ad
cmp r9d, 1
jne 0x14000e2e7
call fcn.14000e0c0
test rax, rax
mov rcx, rax
setne dil
test rax, rax
je 0x14000e2e7
mov ebx, dword [rax + 8]
mov rdx, qword [rsp + 0x60]
btr ebx, 0x1f
test rdx, rdx
je 0x14000e264
mov eax, dword [rax + 0x10]
mov dword [rdx], eax
mov rsi, qword [rsp + 0x70]
test rsi, rsi
je 0x14000e2e7
mov r9, qword [rsp + 0x68]
test r9, r9
je 0x14000e2a9
xor edi, edi
cmp dword [rsi], ebx
setae dil
jb 0x14000e2a9
cmp dword [rcx + 8], 0
lea rdx, [rcx + 0xc]
jl 0x14000e29e
mov rax, qword [r14 + 8]
movsxd rdx, dword [rdx]
mov rax, qword [rax + 0x10]
add rax, 4
add rdx, rax
mov r8d, ebx
mov rcx, r9
call fcn.1400c2660
mov dword [rsi], ebx
jmp 0x14000e2e7
mov rax, qword [rsp + 0x70]
xor r8d, r8d
mov r9, qword [rsp + 0x60]
mov rdx, r10
mov qword [rsp + 0x28], rax
mov rcx, r11
mov rax, qword [rsp + 0x68]
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
sete dil
test eax, eax
je 0x14000e2e7
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rbx, qword [rsp + 0x40]
mov eax, edi
mov rdi, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x48]
add rsp, 0x30
pop r14
ret

Function at 0x14000e300
Capabilities:
Set registry value

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x30
mov r9d, dword [rcx]
xor ebx, ebx
mov r10, r8
mov r11, rdx
mov rdi, rcx
test r9d, r9d
je 0x14000e391
cmp r9d, 1
jne 0x14000e3c8
call fcn.14000e0c0
mov r8, rax
test rax, rax
je 0x14000e3c8
mov ecx, dword [rax + 8]
mov edx, ecx
mov r9d, dword [rsp + 0x70]
btr edx, 0x1f
cmp edx, r9d
setae bl
jb 0x14000e38a
mov eax, dword [rsp + 0x60]
and ecx, 0x80000000
or ecx, r9d
mov dword [r8 + 0x10], eax
mov dword [r8 + 8], ecx
lea rcx, [r8 + 0xc]
jl 0x14000e37b
mov rax, qword [rdi + 8]
movsxd rcx, dword [rcx]
mov rax, qword [rax + 0x10]
add rax, 4
add rcx, rax
mov r8d, edx
mov rdx, qword [rsp + 0x68]
call fcn.1400c2660
jmp 0x14000e3c8
mov ecx, Ordinal_54
jmp 0x14000e3c2
mov eax, dword [rsp + 0x70]
xor r8d, r8d
mov r9d, dword [rsp + 0x60]
mov rdx, r10
mov dword [rsp + 0x28], eax
mov rcx, r11
mov rax, qword [rsp + 0x68]
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
sete bl
test eax, eax
je 0x14000e3c8
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, ebx
mov rbx, qword [rsp + 0x40]
add rsp, 0x30
pop rdi
ret
Function at 0x14000e3d8
Capabilities:
Query or enumerate registry key

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 r14
push r15
sub rsp, 0x40
mov r10d, dword [rcx]
xor r12d, r12d
mov r14, qword [rsp + 0x80]
mov rsi, r9
mov r11d, r8d
mov rbp, rdx
mov edi, r12d
test r10d, r10d
je 0x14000e514
cmp r10d, 1
jne 0x14000e54c
cmp dword [rdx + 0x18], r12d
je 0x14000e54c
cmp r11d, dword [rdx + 0x18]
jae 0x14000e54c
cmp dword [rdx + 0x20], 0xffffffff
je 0x14000e54c
mov rax, qword [rcx + 8]
movsxd rcx, dword [rdx + 0x20]
mov r8, qword [rax + 0x10]
mov eax, 0x666c
add rcx, r8
cmp word [rcx + 4], ax
je 0x14000e469
mov eax, 0x686c
cmp word [rcx + 4], ax
jne 0x14000e54c
cmp word [rcx + 6], r12w
je 0x14000e54c
movzx eax, word [rcx + 6]
cmp r11d, eax
jae 0x14000e54c
movsxd rdx, dword [rcx + r11*8 + 8]
mov eax, 0x6b6e
add rdx, r8
cmp word [rdx + 4], ax
jne 0x14000e54c
test rsi, rsi
je 0x14000e54c
test r14, r14
je 0x14000e54c
test byte [rdx + 6], 0x20
movzx ebx, word [rdx + 0x4c]
je 0x14000e4ea
cmp dword [r14], ebx
seta dil
jbe 0x14000e506
lea rcx, [rdx + 0x50]
mov edx, ebx
call fcn.140011d2c
mov rbp, rax
test rax, rax
je 0x14000e506
lea r8, [rbx + rbx]
mov rdx, rax
mov rcx, rsi
call fcn.1400c2660
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x14000e506
shr ebx, 1
cmp dword [r14], ebx
seta dil
jbe 0x14000e506
movzx r8d, word [rbp + 0x4c]
add rdx, 0x50
mov rcx, rsi
call fcn.1400c2660
test edi, edi
je 0x14000e50f
mov word [rsi + rbx*2], r12w
mov dword [r14], ebx
jmp 0x14000e54c
mov qword [rsp + 0x38], r12
mov r9, r14
mov qword [rsp + 0x30], r12
mov r8, rsi
mov qword [rsp + 0x28], r12
mov edx, r11d
mov rcx, rbp
mov qword [rsp + 0x20], r12
call qword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
test eax, eax
sete dil
test eax, eax
je 0x14000e54c
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rbx, qword [rsp + 0x60]
mov eax, edi
mov rdi, qword [rsp + 0x78]
mov rbp, qword [rsp + 0x68]
mov rsi, qword [rsp + 0x70]
add rsp, 0x40
pop r15
pop r14
pop r12
ret
Function at 0x14000e570
Capabilities:
Query or enumerate registry value

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, 0x40
xor r13d, r13d
mov r11d, r8d
mov r10, rdx
mov r12, r9
mov edx, dword [rcx]
mov r15, rcx
mov esi, r13d
test edx, edx
je 0x14000e729
cmp edx, 1
jne 0x14000e77e
test r10, r10
jne 0x14000e5be
mov rax, qword [rcx + 8]
mov r10, qword [rax + 0x18]
mov eax, 0x6b6e
cmp word [r10 + 4], ax
jne 0x14000e77e
cmp dword [r10 + 0x28], r13d
je 0x14000e77e
cmp r11d, dword [r10 + 0x28]
jae 0x14000e77e
cmp dword [r10 + 0x2c], 0xffffffff
je 0x14000e77e
mov rax, qword [rcx + 8]
movsxd rcx, dword [r10 + 0x2c]
add rcx, qword [rax + 0x10]
movsxd rbx, dword [rcx + r11*4 + 4]
add rbx, qword [rax + 0x10]
mov eax, 0x6b76
cmp word [rbx + 4], ax
jne 0x14000e77e
test r12, r12
je 0x14000e77e
mov r14, qword [rsp + 0x90]
test r14, r14
je 0x14000e77e
movzx eax, word [rbx + 6]
test ax, ax
je 0x14000e6b2
test byte [rbx + 0x14], 1
movzx ebp, ax
movzx edx, ax
je 0x14000e64e
lea rcx, [rbx + 0x18]
call fcn.140011d2c
mov rdi, rax
jmp 0x14000e67c
add rdx, 2
shr ebp, 1
mov ecx, 0x40
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov rdi, rax
test rax, rax
je 0x14000e77e
movzx r8d, word [rbx + 6]
lea rdx, [rbx + 0x18]
mov rcx, rax
call fcn.1400c2660
inc ebp
test rdi, rdi
je 0x14000e77e
cmp dword [r14], ebp
setae sil
jb 0x14000e6a7
mov r8d, ebp
mov rdx, rdi
add r8, r8
mov rcx, r12
call fcn.1400c2660
lea eax, [rbp - 1]
mov dword [r14], eax
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x14000e6b5
mov dword [r14], r13d
test esi, esi
je 0x14000e77e
mov edi, dword [rbx + 8]
mov rcx, qword [rsp + 0xa0]
btr edi, 0x1f
test rcx, rcx
je 0x14000e6d6
mov eax, dword [rbx + 0x10]
mov dword [rcx], eax
mov r14, qword [rsp + 0xb0]
test r14, r14
je 0x14000e77e
mov rcx, qword [rsp + 0xa8]
test rcx, rcx
je 0x14000e724
cmp dword [r14], edi
mov esi, r13d
setae sil
jb 0x14000e724
lea rdx, [rbx + 0xc]
cmp dword [rbx + 8], r13d
jl 0x14000e71c
mov rax, qword [r15 + 8]
movsxd rdx, dword [rdx]
mov rax, qword [rax + 0x10]
add rax, 4
add rdx, rax
mov r8d, edi
call fcn.1400c2660
mov dword [r14], edi
jmp 0x14000e77e
mov rax, qword [rsp + 0xb0]
mov r8, r12
mov r9, qword [rsp + 0x90]
mov edx, r11d
mov qword [rsp + 0x38], rax
mov rcx, r10
mov rax, qword [rsp + 0xa8]
mov qword [rsp + 0x30], rax
mov rax, qword [rsp + 0xa0]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], r13
call qword [sym.imp.ADVAPI32.dll_RegEnumValueW]
test eax, eax
sete sil
test eax, eax
je 0x14000e77e
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_SetLastError]
lea r11, [rsp + 0x40]
mov eax, esi
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 0x14000ef5c
Capabilities:
Encode data using xor
Read file on windows
Write file on windows

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
push rbp
push r14
push r15
lea rbp, [rax - 0x68]
sub rsp, 0x150
mov dil, r9b
mov word [rsp + 0x30], 0x103
mov r15, r8
mov bl, dl
mov r14, rcx
xor edx, edx
mov r8d, 0x100
lea rcx, [rsp + 0x50]
lea eax, [rdi + 5]
xor esi, esi
mov byte [rsp + 0x32], al
xor eax, eax
mov qword [rsp + 0x33], rax
mov qword [rsp + 0x3b], rax
mov dword [rsp + 0x43], eax
mov byte [rsp + 0x47], al
call fcn.1400c1ef0
cmp dil, 0x12
jae 0x14000f162
movzx r8d, dil
lea rcx, [rsp + 0x34]
mov rdx, r15
mov byte [rsp + 0x33], bl
call fcn.1400c2660
movzx r9d, dil
xor dl, dl
xor cl, cl
lea r8d, [r9 + 3]
test r8d, r8d
je 0x14000effd
movzx eax, cl
inc cl
xor dl, byte [rsp + rax + 0x31]
movzx eax, cl
cmp eax, r8d
jb 0x14000efec
mov byte [rsp + r9 + 0x34], dl
mov rcx, r14
mov edx, reloc.WLDAP32.dll_Ordinal_12
mov byte [rsp + r9 + 0x35], 4
call qword [sym.imp.KERNEL32.dll_PurgeComm]
mov edi, 0x64
mov ecx, edi
call qword [sym.imp.KERNEL32.dll_Sleep]
and qword [rsp + 0x20], rsi
lea r9, [rbp + 0x88]
lea r8d, [rdi - 0x4c]
mov rcx, r14
lea rdx, [rsp + 0x30]
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x14000f156
cmp dword [rbp + 0x88], 0x18
jne 0x14000f156
xor r8d, r8d
xor edx, edx
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_ClearCommError]
mov ecx, edi
call qword [sym.imp.KERNEL32.dll_Sleep]
and qword [rsp + 0x20], rsi
lea r9, [rbp + 0x88]
mov r8d, 0x100
lea rdx, [rsp + 0x50]
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x14000f156
cmp dword [rbp + 0x88], 6
jb 0x14000f156
cmp byte [rsp + 0x50], 5
jne 0x14000f156
cmp byte [rsp + 0x51], 1
jne 0x14000f156
mov cl, byte [rsp + 0x52]
cmp cl, 5
jb 0x14000f156
or bl, 0x80
cmp byte [rsp + 0x53], bl
jne 0x14000f156
sub cl, 5
xor r8b, r8b
movzx r9d, cl
xor dl, dl
lea r10d, [r9 + 3]
test r10d, r10d
je 0x14000f0f8
movzx eax, dl
inc dl
xor r8b, byte [rsp + rax + 0x51]
movzx eax, dl
cmp eax, r10d
jb 0x14000f0e6
cmp byte [rsp + r9 + 0x54], r8b
jne 0x14000f156
cmp byte [rsp + r9 + 0x55], 4
jne 0x14000f156
mov esi, 1
test cl, cl
je 0x14000f162
mov rbx, qword [rbp + 0x90]
test rbx, rbx
je 0x14000f162
mov rax, qword [rbp + 0x98]
test rax, rax
je 0x14000f162
movzx edi, cl
mov byte [rax], cl
mov edx, edi
lea ecx, [rsi + 0x3f]
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov qword [rbx], rax
test rax, rax
je 0x14000f152
mov r8d, edi
lea rdx, [rsp + 0x54]
mov rcx, rax
call fcn.1400c2660
jmp 0x14000f162
xor esi, esi
jmp 0x14000f162
lea rcx, str.ERROR_sR98_send_receive___ERROR
call fcn.14000b8b0
lea r11, [rsp + 0x150]
mov eax, esi
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rdi, qword [r11 + 0x30]
mov rsp, r11
pop r15
pop r14
pop rbp
ret
Function at 0x1400115dc
Capabilities:
Query service status

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x30
mov rdi, r8
mov rbp, rdx
mov rdx, rcx
xor ebx, ebx
mov rcx, rdi
lea r8d, [rbx + 4]
call qword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov rsi, rax
test rax, rax
je 0x140011637
lea rax, [rsp + 0x58]
mov r8, rbp
lea r9d, [rbx + 0x24]
mov qword [rsp + 0x20], rax
xor edx, edx
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_QueryServiceStatusEx]
mov rcx, rsi
mov ebx, eax
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rdi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rbp, qword [rsp + 0x48]
mov eax, ebx
mov rbx, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret

Function at 0x1400116d4
Capabilities:
Delete service

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
mov rdi, rcx
lea rdx, str.ServicesActive
xor ebx, ebx
xor ecx, ecx
lea r8d, [rbx + 1]
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov rsi, rax
test rax, rax
je 0x14001173a
mov r8d, 0x10000
mov rdx, rdi
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov rdi, rax
test rax, rax
je 0x140011731
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_DeleteService]
mov rcx, rdi
mov ebx, eax
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rsi, qword [rsp + 0x38]
mov eax, ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret
Function at 0x140011998
Capabilities:
Create service
Persist via windows service
Start service

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbp
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
mov qword [rax + 0x20], r12
push r13
push r14
push r15
sub rsp, 0x70
mov r12, r8
mov r13, rdx
mov rdi, rcx
lea rdx, str.ServicesActive
xor ebp, ebp
xor ecx, ecx
mov r15d, r9d
lea r8d, [rbp + 3]
call qword [sym.imp.ADVAPI32.dll_OpenSCManagerW]
mov r14, rax
test rax, rax
je 0x140011b15
lea r8d, [rbp + 0x10]
mov rdx, rdi
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenServiceW]
mov rsi, rax
test rax, rax
je 0x140011a0e
lea rcx, str.____s_service_already_registered_n
mov rdx, rdi
call fcn.14000b8b0
jmp 0x140011ab5
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x424
jne 0x140011aa9
mov rdx, rdi
lea rcx, str.____s_service_not_present_n
call fcn.14000b8b0
xor eax, eax
mov r9d, 0x60010
mov qword [rsp + 0x60], rax
mov r8, r13
mov qword [rsp + 0x58], rax
mov rdx, rdi
mov qword [rsp + 0x50], rax
mov rcx, r14
mov qword [rsp + 0x48], rax
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x38], r12
mov dword [rsp + 0x30], 1
mov dword [rsp + 0x28], 2
mov dword [rsp + 0x20], r15d
call qword [sym.imp.ADVAPI32.dll_CreateServiceW]
mov rsi, rax
test rax, rax
je 0x140011aa9
mov rdx, rdi
lea rcx, str.____s_service_successfully_registered_n
call fcn.14000b8b0
mov rcx, rsi
call fcn.140011834
mov ebp, eax
test eax, eax
je 0x140011aa9
lea rcx, str.____s_service_ACL_to_everyone_n
jmp 0x140011a01
lea rcx, str.ERROR_idwcflvcservice_install___ERROR
call fcn.14000b8b0
test rsi, rsi
je 0x140011b0a
xor r8d, r8d
xor edx, edx
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_StartServiceW]
mov ebp, eax
test eax, eax
je 0x140011ad7
lea rcx, str.____s_service_started_n
jmp 0x140011aeb
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x420
jne 0x140011af5
lea rcx, str.____s_service_already_started_n
mov rdx, rdi
call fcn.14000b8b0
jmp 0x140011b01
lea rcx, str.ERROR_idwcflvcservice_install___ERROR
call fcn.14000b8b0
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov rcx, r14
call qword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x140011b21
lea rcx, str.ERROR_idwcflvcservice_install___ERROR
call fcn.14000b8b0
lea r11, [rsp + 0x70]
mov eax, ebp
mov rbp, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rdi, qword [r11 + 0x30]
mov r12, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop r13
ret
Function at 0x140012648
Capabilities:
Decode data using base64 via winapi

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
push rdi
sub rsp, 0x40
xor edi, edi
mov rsi, r8
and qword [rax - 0x18], rdi
mov rbx, rdx
and qword [rdx], rdi
xor r9d, r9d
and qword [rax - 0x20], rdi
xor edx, edx
and dword [r8], edi
mov rbp, rcx
mov qword [rax - 0x28], r8
lea r8d, [rdi + 1]
call qword [sym.imp.CRYPT32.dll_CryptStringToBinaryW]
test eax, eax
je 0x1400126d2
mov edx, dword [rsi]
lea ecx, [rdi + 0x40]
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov qword [rbx], rax
test rax, rax
je 0x1400126d2
and qword [rsp + 0x30], rdi
lea r8d, [rdi + 1]
and qword [rsp + 0x28], rdi
mov r9, rax
xor edx, edx
mov qword [rsp + 0x20], rsi
mov rcx, rbp
call qword [sym.imp.CRYPT32.dll_CryptStringToBinaryW]
mov edi, eax
test eax, eax
jne 0x1400126d2
mov rcx, qword [rbx]
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov qword [rbx], rax
mov rbx, qword [rsp + 0x50]
mov eax, edi
mov rbp, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
add rsp, 0x40
pop rdi
ret

Function at 0x1400127c0
Capabilities:
Decode data using base64 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 r14
push r15
sub rsp, 0x40
mov r15, r8
mov r14, rdx
mov r12, rcx
xor ebx, ebx
call qword [sym.imp.KERNEL32.dll_lstrlenA]
mov ebp, eax
lea ecx, [rbx + 0x40]
and eax, 3
lea edx, [rax + 1]
add edx, ebp
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov rdi, rax
test rax, rax
je 0x1400128c9
mov r8d, ebp
mov rdx, r12
mov rcx, rax
mov esi, ebp
call fcn.1400c2660
test ebp, ebp
je 0x140012848
mov rax, rdi
cmp byte [rax], 0x2d
jne 0x14001282e
mov byte [rax], reloc.ODBC32.dll_SQLGetData
jmp 0x14001283f
cmp byte [rax], 0x5f
jne 0x140012838
mov byte [rax], 0x2f
jmp 0x14001283f
cmp byte [rax], bl
jne 0x14001283f
mov byte [rax], 0x3d
inc rax
sub rsi, 1
jne 0x140012824
xor r9d, r9d
mov qword [rsp + 0x30], rbx
mov qword [rsp + 0x28], rbx
xor edx, edx
mov rcx, rdi
mov qword [r14], rbx
mov esi, ebx
mov dword [r15], ebx
lea r8d, [r9 + 1]
mov qword [rsp + 0x20], r15
call qword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
test eax, eax
je 0x1400128be
mov edx, dword [r15]
mov ecx, 0x40
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov qword [r14], rax
test rax, rax
je 0x1400128be
xor edx, edx
mov qword [rsp + 0x30], rbx
mov qword [rsp + 0x28], rbx
mov r9, rax
mov rcx, rdi
mov qword [rsp + 0x20], r15
lea r8d, [rdx + 1]
call qword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
mov esi, eax
test eax, eax
jne 0x1400128be
mov rcx, qword [r14]
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov qword [r14], rax
mov rcx, rdi
mov ebx, esi
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rbp, qword [rsp + 0x68]
mov eax, ebx
mov rbx, qword [rsp + 0x60]
mov rsi, qword [rsp + 0x70]
mov rdi, qword [rsp + 0x78]
add rsp, 0x40
pop r15
pop r14
pop r12
ret
Function at 0x1400128ec
Capabilities:
Encode data using base64 via winapi

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
push rdi
sub rsp, 0x30
lea rax, [rax + 0x20]
mov rbx, r8
xor edi, edi
mov qword [rsp + 0x20], rax
and dword [rax], edi
xor r9d, r9d
mov r8d, 0x40000001
mov esi, edx
mov rbp, rcx
call qword [sym.imp.CRYPT32.dll_CryptBinaryToStringA]
test eax, eax
je 0x14001296d
mov edx, dword [rsp + 0x58]
lea ecx, [rdi + 0x40]
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov qword [rbx], rax
test rax, rax
je 0x14001296d
lea rcx, [rsp + 0x58]
mov r9, rax
mov qword [rsp + 0x20], rcx
mov r8d, 0x40000001
mov rcx, rbp
mov edx, esi
call qword [sym.imp.CRYPT32.dll_CryptBinaryToStringA]
mov edi, eax
test eax, eax
jne 0x14001296d
mov rcx, qword [rbx]
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov qword [rbx], rax
mov rbx, qword [rsp + 0x40]
mov eax, edi
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret

Function at 0x1400129e0
Capabilities:
Encode data using base64 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 r14
push r15
sub rsp, 0x30
mov rbp, qword [rsp + 0x70]
mov r12, rdx
mov rsi, rcx
xor ebx, ebx
mov r14, r9
mov r15d, r8d
mov edx, dword [rbp]
lea ecx, [rbx + 0x40]
call qword [sym.imp.KERNEL32.dll_LocalAlloc]
mov rdi, rax
test rax, rax
je 0x140012a67
mov r9, rax
mov qword [rsp + 0x20], rbp
mov r8d, 0x80000001
mov edx, r15d
mov rcx, r12
call qword [sym.imp.CRYPT32.dll_CryptBinaryToStringA]
test eax, eax
je 0x140012a5e
mov r9, rdi
mov qword [rsp + 0x20], rsi
mov r8, rsi
lea rdx, str._____BEGIN__s______n_s_____END__s______n
mov rcx, r14
call fcn.140012b48
mov ebx, eax
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_LocalFree]
mov rbp, qword [rsp + 0x58]
mov eax, ebx
mov rbx, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x60]
mov rdi, qword [rsp + 0x68]
add rsp, 0x30
pop r15
pop r14
pop r12
ret