joyce8/EMBER2024-capa huggingface dataset:
Function at 0x14000bed0
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x1400e1120]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x1400e1100]
test rbx, rbx
je 0x14000bf24
mov rdi, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rsi, qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [rbx]
call rdi
mov r12, rax
call rsi
test eax, eax
jne 0x14000bf1b
test r12, r12
je 0x14000bf1b
mov rax, qword [rbx + 8]
mov rcx, r12
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x14000bf00
lea rcx, [0x1400e1120]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x14000c150
Capabilities:
Parse pe header

Disassembly:
cmp word [rcx], 0x5a4d
jne 0x14000c160
jmp sym._ValidateImageBase.part.0
xor eax, eax
ret

Function at 0x14000c170
Capabilities:
Enumerate pe sections

Disassembly:
movsxd rax, dword [rcx + 0x3c]
add rcx, rax
movzx eax, word [rcx + 0x14]
lea rax, [rcx + rax + 0x18]
movzx ecx, word [rcx + 6]
test ecx, ecx
je 0x14000c1b5
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
nop dword [rax]
mov r8d, dword [rax + 0xc]
mov rcx, r8
cmp r8, rdx
ja 0x14000c1ac
add ecx, dword [rax + 8]
cmp rcx, rdx
ja 0x14000c1b7
add rax, 0x28
cmp rax, r9
jne 0x14000c198
xor eax, eax
ret

Function at 0x14000c260
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r10, qword [0x1400ba5e0]
xor r8d, r8d
cmp word [r10], 0x5a4d
mov r9, rcx
jne 0x14000c2d9
mov rcx, r10
call sym._ValidateImageBase.part.0
test eax, eax
je 0x14000c2d9
movsxd rax, dword [r10 + 0x3c]
mov rcx, r9
sub rcx, r10
add r10, rax
movzx eax, word [r10 + 0x14]
lea r8, [r10 + rax + 0x18]
movzx eax, word [r10 + 6]
test eax, eax
je 0x14000c2d6
sub eax, 1
lea rax, [rax + rax*4]
lea r9, [r8 + rax*8 + 0x28]
nop dword [rax]
mov edx, dword [r8 + 0xc]
mov rax, rdx
cmp rcx, rdx
jb 0x14000c2cd
add eax, dword [r8 + 8]
cmp rcx, rax
jb 0x14000c2d9
add r8, 0x28
cmp r8, r9
jne 0x14000c2b8
xor r8d, r8d
mov rax, r8
add rsp, 0x28
ret

Function at 0x14000c3c0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r9, qword [0x1400ba5e0]
xor eax, eax
cmp word [r9], 0x5a4d
mov r8, rcx
jne 0x14000c42f
mov rcx, r9
call sym._ValidateImageBase.part.0
test eax, eax
je 0x14000c42f
movsxd rax, dword [r9 + 0x3c]
mov rcx, r8
sub rcx, r9
add r9, rax
movzx eax, word [r9 + 0x14]
movzx edx, word [r9 + 6]
lea rax, [r9 + rax + 0x18]
test edx, edx
je 0x14000c42d
sub edx, 1
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
mov r8d, dword [rax + 0xc]
mov rdx, r8
cmp rcx, r8
jb 0x14000c424
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x14000c438
add rax, 0x28
cmp rax, r9
jne 0x14000c410
xor eax, eax
add rsp, 0x28
ret
mov eax, dword [rax + 0x24]
not eax
shr eax, 0x1f
add rsp, 0x28
ret
Function at 0x14000c450
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r11, qword [0x1400ba5e0]
xor r9d, r9d
cmp word [r11], 0x5a4d
mov r8d, ecx
jne 0x14000c4c8
mov rcx, r11
call sym._ValidateImageBase.part.0
test eax, eax
je 0x14000c4c8
movsxd rcx, dword [r11 + 0x3c]
add rcx, r11
mov eax, dword [rcx + 0x90]
test eax, eax
je 0x14000c4c8
movzx edx, word [rcx + 0x14]
lea rdx, [rcx + rdx + 0x18]
movzx ecx, word [rcx + 6]
test ecx, ecx
je 0x14000c4c8
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r10, [rdx + rcx*8 + 0x28]
nop dword [rax + rax]
mov r9d, dword [rdx + 0xc]
mov rcx, r9
cmp rax, r9
jb 0x14000c4bc
add ecx, dword [rdx + 8]
cmp rax, rcx
jb 0x14000c4d0
add rdx, 0x28
cmp rdx, r10
jne 0x14000c4a8
xor r9d, r9d
mov rax, r9
add rsp, 0x28
ret
add rax, r11
jmp 0x14000c4e0
sub r8d, 1
add rax, 0x14
mov ecx, dword [rax + 4]
test ecx, ecx
jne 0x14000c4ee
mov edx, dword [rax + 0xc]
test edx, edx
je 0x14000c4c5
test r8d, r8d
jg 0x14000c4d8
mov r9d, dword [rax + 0xc]
add r9, r11
mov rax, r9
add rsp, 0x28
ret

Function at 0x14000c5d0
Capabilities:
Allocate thread local storage

Disassembly:
push r12
push rbx
sub rsp, 0x28
mov rbx, rcx
mov r12, rdx
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov ecx, eax
cmp eax, 0xffffffff
je 0x14000c600
mov rdx, r12
mov dword [rbx], eax
add rsp, 0x28
pop rbx
pop r12
jmp dbg.__mingwthr_key_dtor
add rsp, 0x28
pop rbx
pop r12
jmp qword [sym.imp.KERNEL32.dll_GetLastError]

Function at 0x14000c640
Capabilities:
Get thread local storage value

Disassembly:
push r13
push r12
sub rsp, 0x28
mov r12d, ecx
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, r12d
mov r13d, eax
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, r13d
mov r12, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rax, r12
add rsp, 0x28
pop r12
pop r13
ret

Function at 0x14000c680
Capabilities:
Set thread local storage value

Disassembly:
sub rsp, 0x28
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
je 0x14000c698
xor eax, eax
add rsp, 0x28
ret
add rsp, 0x28
jmp qword [sym.imp.KERNEL32.dll_GetLastError]

Function at 0x1400178b0
Capabilities:
Generate random numbers via rtlgenrandom

Disassembly:
push r12
push rbx
sub rsp, 0x28
mov r12, rcx
lea rcx, str.msvcrt.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov rbx, qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.rand_s
mov rcx, rax
call rbx
test rax, rax
je 0x1400178f8
mov rcx, r12
mov qword [dbg.init_rand_s], rax
add rsp, 0x28
pop rbx
pop r12
jmp rax
lea rcx, str.advapi32.dll
call qword [sym.imp.KERNEL32.dll_LoadLibraryW]
lea rdx, str.SystemFunction036
mov rcx, rax
call rbx
mov qword [0x1400e1ba0], rax
lea rax, [dbg.mingw_rand_s]
jmp 0x1400178df

Function at 0x140019b70
Capabilities:
Read file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x28
mov r9, qword [rcx + 0x40]
mov rsi, rdx
mov rbx, rcx
mov edx, 1
mov rcx, rsi
call sym.fread
mov edx, 0xffffffff
test rax, rax
jle 0x140019b9c
movzx edx, byte [rsi + rax - 1]
mov dword [rbx + 0x48], edx
add rsp, 0x28
pop rbx
pop rsi
ret
Function at 0x14001a820
Capabilities:
Write file on windows

Disassembly:
push r13
push r12
push rbx
sub rsp, 0x30
cmp byte [0x1400b4f40], 0
jne 0x14001a92a
mov byte [0x1400b4f40], 1
call sym.__cxa_current_exception_type
test rax, rax
je 0x14001a900
mov r12, qword [rax + 8]
xor eax, eax
lea r9, [rsp + 0x2c]
cmp byte [r12], 0x2a
mov dword [rsp + 0x2c], 0xffffffff
sete al
xor r8d, r8d
xor edx, edx
add r12, rax
mov rcx, r12
call sym.__cxa_demangle
mov ecx, 2
mov rbx, qword [dbg.__acrt_iob_func]
mov r13, rax
call rbx
mov edx, 1
lea rcx, str.terminate_called_after_throwing_an_instance_of_
mov r8d, 0x30
mov r9, rax
call sym.fwrite
mov edx, dword [rsp + 0x2c]
mov ecx, 2
test edx, edx
je 0x14001a8f1
call rbx
mov rcx, r12
mov rdx, rax
call sym.fputs
mov ecx, 2
call rbx
mov r8d, 2
mov edx, 1
lea rcx, [0x1400b50f1]
mov r9, rax
call sym.fwrite
mov eax, dword [rsp + 0x2c]
test eax, eax
jne 0x14001a8ec
mov rcx, r13
call sym.free
call sym.__cxa_rethrow
call rbx
mov rcx, r13
mov rdx, rax
call sym.fputs
jmp 0x14001a8bb
mov ecx, 2
call qword [dbg.__acrt_iob_func]
mov r8d, 0x2d
mov edx, 1
lea rcx, str.terminate_called_without_an_active_exception_n
mov r9, rax
call sym.fwrite
call sym.abort
mov ecx, 2
call qword [dbg.__acrt_iob_func]
mov r8d, 0x1d
mov edx, 1
lea rcx, str.terminate_called_recursively_n
mov r9, rax
call sym.fwrite
call sym.abort
sub rdx, 1
mov rcx, rax
jne 0x14001a9bf
call sym.__cxa_begin_catch
mov rcx, rax
mov rax, qword [rax]
call qword [rax + 0x10]
mov ecx, 2
mov r12, rax
call rbx
mov r9, rax
mov r8d, 0xb
mov edx, 1
lea rcx, str.__what__:
call sym.fwrite
mov ecx, 2
call rbx
mov rdx, rax
mov rcx, r12
call sym.fputs
mov ecx, 2
call rbx
mov rdx, rax
mov ecx, 0xa
call sym.fputc
call sym.__cxa_end_catch
jmp 0x14001a925
call sym.__cxa_begin_catch
call sym.__cxa_end_catch
jmp 0x14001a925

Function at 0x140074da0
Capabilities:
Read file on windows

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
mov rbp, qword [sym.imp.msvcrt.dll__errno]
mov rdi, rcx
mov rsi, rdx
mov ebx, r8d
jmp 0x140074dc7
call rbp
cmp dword [rax], 4
jne 0x140074de4
mov rcx, rdi
call method.std::__basic_file_char_.fd__
mov r8d, ebx
mov rdx, rsi
mov ecx, eax
call sym.read
movsxd r12, eax
cmp eax, 0xffffffff
je 0x140074dc0
mov rax, r12
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret

Function at 0x140089250
Capabilities:
Read file on windows

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov rax, qword [rcx + 8]
mov rdi, rcx
test rax, rax
je 0x140089278
xor ecx, ecx
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
jmp rax
mov rbp, qword [sym.imp.msvcrt.dll__errno]
mov ebx, 4
lea rsi, [rsp + 0x2c]
nop dword [rax]
mov ecx, dword [rdi + 0x10]
mov r8d, ebx
mov rdx, rsi
call sym.read
test eax, eax
jle 0x1400892c0
cdqe
add rsi, rax
sub rbx, rax
jne 0x140089290
mov eax, dword [rsp + 0x2c]
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret
cmp eax, 0xffffffff
jne 0x1400892cc
call rbp
cmp dword [rax], 4
je 0x140089290
lea rcx, str.random_device_could_not_be_read
call method.std.__throw_runtime_error_char_const_
nop
nop
nop
nop
nop
nop
nop
nop
Function at 0x140003e60
Capabilities:
Create process on windows

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
push rdi
sub rsp, 0x110
mov rdx, qword [rsp + 0x128]
lea rcx, [rsp + 0x80]
call fcn.140005660
mov dword [rsp + 0xa0], 0x68
lea rax, [rsp + 0xa8]
mov rdi, rax
xor eax, eax
mov ecx, 0x60
rep stosb byte [rdi], al
lea rax, [rsp + 0x68]
mov rdi, rax
xor eax, eax
mov ecx, 0x18
rep stosb byte [rdi], al
lea rcx, [rsp + 0x80]
call fcn.1400053a0
lea rcx, [rsp + 0x68]
mov qword [rsp + 0x48], rcx
lea rcx, [rsp + 0xa0]
mov qword [rsp + 0x40], rcx
mov qword [rsp + 0x38], 0
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 1
mov dword [rsp + 0x20], 0
xor r9d, r9d
xor r8d, r8d
mov rdx, rax
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
jne 0x140003f5f
mov dword [rsp + 0x50], 0
mov qword [rsp + 0x60], 0xffffffffffffffff
mov qword [rsp + 0x58], 0xffffffffffffffff
lea r9, [rsp + 0x58]
lea r8, [rsp + 0x60]
lea rdx, [rsp + 0x50]
mov rcx, qword [rsp + 0x120]
call fcn.14000cf80
lea rcx, [rsp + 0x80]
call fcn.1400054b0
mov rax, qword [rsp + 0x120]
jmp 0x140003f90
lea r9, [rsp + 0x70]
lea r8, [rsp + 0x68]
lea rdx, [rsp + 0x78]
mov rcx, qword [rsp + 0x120]
call fcn.14000cf80
lea rcx, [rsp + 0x80]
call fcn.1400054b0
mov rax, qword [rsp + 0x120]
add rsp, 0x110
pop rdi
ret
Function at 0x1400042f0
Capabilities:
Encrypt data using rc4 prga

Disassembly:
mov qword [rsp + 0x20], r9
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
sub rsp, 0x28
mov rax, qword [rsp + 0x30]
mov eax, dword [rax]
mov dword [rsp + 4], eax
mov rax, qword [rsp + 0x30]
mov eax, dword [rax + 4]
mov dword [rsp + 8], eax
mov rax, qword [rsp + 0x30]
add rax, 8
mov qword [rsp + 0x10], rax
mov qword [rsp + 0x18], 0
jmp 0x140004345
mov rax, qword [rsp + 0x18]
inc rax
mov qword [rsp + 0x18], rax
mov rax, qword [rsp + 0x38]
cmp qword [rsp + 0x18], rax
jae 0x140004449
mov eax, dword [rsp + 4]
inc eax
cdq
and edx, 0xff
add eax, edx
and eax, 0xff
sub eax, edx
mov dword [rsp + 4], eax
movsxd rax, dword [rsp + 4]
mov rcx, qword [rsp + 0x10]
movzx eax, byte [rcx + rax]
mov ecx, dword [rsp + 8]
add ecx, eax
mov eax, ecx
cdq
and edx, 0xff
add eax, edx
and eax, 0xff
sub eax, edx
mov dword [rsp + 8], eax
movsxd rax, dword [rsp + 4]
mov rcx, qword [rsp + 0x10]
movzx eax, byte [rcx + rax]
mov byte [rsp], al
movsxd rax, dword [rsp + 8]
movsxd rcx, dword [rsp + 4]
mov rdx, qword [rsp + 0x10]
mov r8, qword [rsp + 0x10]
movzx eax, byte [r8 + rax]
mov byte [rdx + rcx], al
movsxd rax, dword [rsp + 8]
mov rcx, qword [rsp + 0x10]
movzx edx, byte [rsp]
mov byte [rcx + rax], dl
mov rax, qword [rsp + 0x18]
mov rcx, qword [rsp + 0x40]
add rcx, rax
mov rax, rcx
movzx eax, byte [rax]
mov dword [rsp + 0xc], eax
movsxd rcx, dword [rsp + 4]
mov rdx, qword [rsp + 0x10]
movzx ecx, byte [rdx + rcx]
movsxd rdx, dword [rsp + 8]
mov r8, qword [rsp + 0x10]
movzx edx, byte [r8 + rdx]
add ecx, edx
mov eax, ecx
cdq
and edx, 0xff
add eax, edx
and eax, 0xff
sub eax, edx
cdqe
mov rcx, qword [rsp + 0x10]
movzx eax, byte [rcx + rax]
mov ecx, dword [rsp + 0xc]
xor ecx, eax
mov eax, ecx
mov rcx, qword [rsp + 0x18]
mov rdx, qword [rsp + 0x48]
add rdx, rcx
mov rcx, rdx
mov byte [rcx], al
jmp 0x140004338
mov rax, qword [rsp + 0x30]
mov ecx, dword [rsp + 4]
mov dword [rax], ecx
mov rax, qword [rsp + 0x30]
mov ecx, dword [rsp + 8]
mov dword [rax + 4], ecx
add rsp, 0x28
ret
Function at 0x140006370
Capabilities:
Write file on windows

Disassembly:
mov dword [rsp + 0x10], edx
mov qword [rsp + 8], rcx
sub rsp, 0xc8
call fcn.140001e50
mov dword [rsp + 0x50], eax
lea rdx, [rsp + 0xd8]
lea rcx, [rsp + 0x50]
call fcn.140001dc0
movzx eax, al
test eax, eax
je 0x1400063b4
lea rcx, [rsp + 0xd8]
call fcn.140001e00
jmp 0x14000661a
mov rcx, qword [rsp + 0xd0]
call fcn.14000a010
test rax, rax
je 0x140006420
mov rcx, qword [rsp + 0xd0]
call fcn.14000a010
mov qword [rsp + 0x60], rax
mov rcx, qword [rsp + 0xd0]
call fcn.140009f60
mov rcx, qword [rsp + 0x60]
cmp rcx, rax
jae 0x140006420
lea rcx, [rsp + 0xd8]
call fcn.140001db0
mov byte [rsp + 0x42], al
mov rcx, qword [rsp + 0xd0]
call fcn.140009dc0
movzx ecx, byte [rsp + 0x42]
mov byte [rax], cl
mov eax, dword [rsp + 0xd8]
jmp 0x14000661a
mov rax, qword [rsp + 0xd0]
cmp qword [rax + 0x80], 0
jne 0x14000643c
call fcn.140001e50
jmp 0x14000661a
mov rcx, qword [rsp + 0xd0]
call fcn.140009920
mov rax, qword [rsp + 0xd0]
cmp qword [rax + 0x68], 0
jne 0x1400064b2
mov rax, qword [rsp + 0xd0]
mov rax, qword [rax + 0x80]
mov qword [rsp + 0x68], rax
lea rcx, [rsp + 0xd8]
call fcn.140001db0
mov byte [rsp + 0x43], al
mov rdx, qword [rsp + 0x68]
movzx ecx, byte [rsp + 0x43]
call fcn.140003c80
movzx eax, al
test eax, eax
je 0x1400064a0
mov eax, dword [rsp + 0xd8]
mov dword [rsp + 0x48], eax
jmp 0x1400064a9
call fcn.140001e50
mov dword [rsp + 0x48], eax
mov eax, dword [rsp + 0x48]
jmp 0x14000661a
mov qword [rsp + 0x88], 0x20
lea rcx, [rsp + 0xd8]
call fcn.140001db0
mov byte [rsp + 0x40], al
mov rax, qword [rsp + 0xd0]
mov rax, qword [rax + 0x68]
mov qword [rsp + 0x70], rax
lea rax, [rsp + 0xb0]
lea rcx, [rsp + 0x41]
mov rdx, qword [rsp + 0xd0]
add rdx, 0x74
lea r8, [rsp + 0x78]
mov qword [rsp + 0x38], r8
mov qword [rsp + 0x30], rax
lea rax, [rsp + 0x90]
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x80]
mov qword [rsp + 0x20], rax
mov r9, rcx
lea r8, [rsp + 0x40]
mov rcx, qword [rsp + 0x70]
call fcn.1400086b0
mov dword [rsp + 0x44], eax
cmp dword [rsp + 0x44], 0
jl 0x140006615
cmp dword [rsp + 0x44], 1
jle 0x14000655a
cmp dword [rsp + 0x44], 3
je 0x1400065d9
jmp 0x140006615
lea rax, [rsp + 0x90]
mov rcx, qword [rsp + 0x78]
sub rcx, rax
mov rax, rcx
mov qword [rsp + 0x58], rax
cmp qword [rsp + 0x58], 0
jbe 0x1400065ae
mov rax, qword [rsp + 0xd0]
mov r9, qword [rax + 0x80]
mov r8, qword [rsp + 0x58]
mov edx, 1
lea rcx, [rsp + 0x90]
call fcn.1400194b0
cmp qword [rsp + 0x58], rax
je 0x1400065ae
call fcn.140001e50
jmp 0x14000661a
mov rax, qword [rsp + 0xd0]
mov byte [rax + 0x71], 1
lea rax, [rsp + 0x40]
cmp qword [rsp + 0x80], rax
je 0x1400065d2
mov eax, dword [rsp + 0xd8]
jmp 0x14000661a
call fcn.140001e50
jmp 0x14000661a
mov rax, qword [rsp + 0xd0]
mov rdx, qword [rax + 0x80]
movzx ecx, byte [rsp + 0x40]
call fcn.140003c80
movzx eax, al
test eax, eax
je 0x140006606
mov eax, dword [rsp + 0xd8]
mov dword [rsp + 0x4c], eax
jmp 0x14000660f
call fcn.140001e50
mov dword [rsp + 0x4c], eax
mov eax, dword [rsp + 0x4c]
jmp 0x14000661a
call fcn.140001e50
add rsp, 0xc8
ret
Function at 0x1400099d0
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 8], rcx
sub rsp, 0xa8
mov rax, qword [rsp + 0xb0]
cmp qword [rax + 0x68], 0
je 0x1400099fb
mov rax, qword [rsp + 0xb0]
movzx eax, byte [rax + 0x71]
test eax, eax
jne 0x140009a02
mov al, 1
jmp 0x140009b4e
mov rax, qword [rsp + 0xb0]
mov rax, qword [rax]
mov rax, qword [rax + 0x18]
mov qword [rsp + 0x50], rax
call fcn.140001e50
mov dword [rsp + 0x38], eax
mov edx, dword [rsp + 0x38]
mov rcx, qword [rsp + 0xb0]
call qword [rsp + 0x50]
mov dword [rsp + 0x3c], eax
call fcn.140001e50
mov dword [rsp + 0x40], eax
lea rdx, [rsp + 0x3c]
lea rcx, [rsp + 0x40]
call fcn.140001dc0
movzx eax, al
test eax, eax
je 0x140009a59
xor al, al
jmp 0x140009b4e
mov qword [rsp + 0x68], 0x20
mov rax, qword [rsp + 0xb0]
mov rax, qword [rax + 0x68]
mov qword [rsp + 0x58], rax
lea rax, [rsp + 0x90]
mov rcx, qword [rsp + 0xb0]
add rcx, 0x74
lea rdx, [rsp + 0x60]
mov qword [rsp + 0x20], rdx
mov r9, rax
lea r8, [rsp + 0x70]
mov rdx, rcx
mov rcx, qword [rsp + 0x58]
call fcn.14000ba30
mov dword [rsp + 0x30], eax
cmp dword [rsp + 0x30], 0
je 0x140009ac8
cmp dword [rsp + 0x30], 1
je 0x140009ad4
cmp dword [rsp + 0x30], 3
je 0x140009b48
jmp 0x140009b4c
mov rax, qword [rsp + 0xb0]
mov byte [rax + 0x71], 0
lea rax, [rsp + 0x70]
mov rcx, qword [rsp + 0x60]
sub rcx, rax
mov rax, rcx
mov qword [rsp + 0x48], rax
cmp qword [rsp + 0x48], 0
jbe 0x140009b1f
mov rax, qword [rsp + 0xb0]
mov r9, qword [rax + 0x80]
mov r8, qword [rsp + 0x48]
mov edx, 1
lea rcx, [rsp + 0x70]
call fcn.1400194b0
cmp qword [rsp + 0x48], rax
je 0x140009b1f
xor al, al
jmp 0x140009b4e
mov rax, qword [rsp + 0xb0]
movzx eax, byte [rax + 0x71]
test eax, eax
jne 0x140009b39
mov dword [rsp + 0x34], 1
jmp 0x140009b41
mov dword [rsp + 0x34], 0
movzx eax, byte [rsp + 0x34]
jmp 0x140009b4e
mov al, 1
jmp 0x140009b4e
xor al, al
add rsp, 0xa8
ret

Function at 0x140016330
Capabilities:
Parse pe header

Disassembly:
mov qword [rsp + 8], rbx
mov dword [rsp + 0x18], r8d
mov dword [rsp + 0x10], edx
push rbp
mov rbp, rsp
sub rsp, 0x50
mov ebx, ecx
test r8d, r8d
jne 0x1400161c3
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x1400161c3
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x1400161c3
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x1400161c3
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x1400161c3
cmp dword [rcx + 0x84], 0xe
jbe 0x1400161c3
cmp dword [rcx + 0xf8], 0
je 0x1400161c3
mov ecx, ebx
call fcn.140016264
lea rax, [rbp + 0x18]
mov byte [rbp + 0x28], 0
mov qword [rbp - 0x20], rax
lea r9, [rbp - 0x2c]
lea rax, [rbp + 0x20]
mov qword [rbp - 0x18], rax
lea r8, [rbp - 0x20]
lea rax, [rbp + 0x28]
mov qword [rbp - 0x10], rax
lea rdx, [rbp - 0x28]
mov eax, 2
lea rcx, [rbp - 0x30]
mov dword [rbp - 0x2c], eax
mov dword [rbp - 0x28], eax
call fcn.140016054
cmp dword [rbp + 0x20], 0
je 0x140016210
mov rbx, qword [rsp + 0x60]
add rsp, 0x50
pop rbp
ret
mov ecx, ebx
call fcn.140016218
int3
xor r8d, r8d
xor edx, edx
jmp 0x14001615c
Function at 0x1400012a4
Capabilities:
Get token membership

Disassembly:
mov r11, rsp
mov qword [r11 + 8], rbx
mov qword [r11 + 0x10], rsi
mov qword [r11 + 0x18], rdi
push rbp
mov rbp, rsp
sub rsp, 0x80
mov rax, qword [0x140015018]
xor rax, rsp
mov qword [rbp - 8], rax
xor edi, edi
mov word [rbp - 0xc], 0x500
lea rax, [rbp - 0x18]
mov dword [rbp - 0x20], edi
mov qword [r11 - 0x38], rax
lea rcx, [rbp - 0x10]
mov dword [rsp + 0x48], edi
xor r9d, r9d
mov dword [rsp + 0x40], edi
lea esi, [rdi + 1]
mov dword [rsp + 0x38], edi
lea r8d, [rdi + 0x12]
mov dword [rsp + 0x30], edi
mov dl, sil
mov dword [rsp + 0x28], edi
mov ebx, edi
mov dword [rsp + 0x20], edi
mov dword [rbp - 0x10], edi
mov qword [rbp - 0x18], rdi
call qword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
test eax, eax
je 0x140001335
mov rdx, qword [rbp - 0x18]
lea r8, [rbp - 0x20]
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_CheckTokenMembership]
test eax, eax
je 0x140001335
cmp dword [rbp - 0x20], edi
cmovne ebx, esi
mov rcx, qword [rbp - 0x18]
test rcx, rcx
je 0x140001344
call qword [sym.imp.ADVAPI32.dll_FreeSid]
mov eax, ebx
mov rcx, qword [rbp - 8]
xor rcx, rsp
call fcn.14000e250
lea r11, [rsp + 0x80]
mov rbx, qword [r11 + 0x10]
mov rsi, qword [r11 + 0x18]
mov rdi, qword [r11 + 0x20]
mov rsp, r11
pop rbp
ret

Function at 0x140001374
Capabilities:
Get token membership

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rdi
push rbp
mov rbp, rsp
sub rsp, 0x80
mov rax, qword [0x140015018]
xor rax, rsp
mov qword [rbp - 8], rax
xor edi, edi
mov word [rbp - 0xc], 0x500
lea rax, [rbp - 0x18]
mov dword [rbp - 0x20], edi
mov qword [rsp + 0x50], rax
lea rcx, [rbp - 0x10]
mov dword [rsp + 0x48], edi
mov r9d, 0x220
mov dword [rsp + 0x40], edi
lea r8d, [rdi + 0x20]
mov dword [rsp + 0x38], edi
mov dl, 2
mov dword [rsp + 0x30], edi
mov ebx, edi
mov dword [rsp + 0x28], edi
mov dword [rsp + 0x20], edi
mov dword [rbp - 0x10], edi
mov qword [rbp - 0x18], rdi
call qword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
test eax, eax
je 0x140001420
mov rdx, qword [rbp - 0x18]
lea r8, [rbp - 0x20]
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_CheckTokenMembership]
test eax, eax
je 0x140001420
cmp dword [rbp - 0x20], edi
je 0x140001420
lea rdx, [rbp - 0x1c]
mov dword [rbp - 0x1c], 0x1000
xor ecx, ecx
call qword [sym.imp.iertutil.dll_Ordinal_35]
test eax, eax
jne 0x140001420
cmp dword [rbp - 0x1c], 0x3000
setae bl
mov rcx, qword [rbp - 0x18]
test rcx, rcx
je 0x14000142f
call qword [sym.imp.ADVAPI32.dll_FreeSid]
mov eax, ebx
mov rcx, qword [rbp - 8]
xor rcx, rsp
call fcn.14000e250
lea r11, [rsp + 0x80]
mov rbx, qword [r11 + 0x10]
mov rdi, qword [r11 + 0x18]
mov rsp, r11
pop rbp
ret
Function at 0x140002044
Capabilities:
Set registry value

Disassembly:
mov rax, rsp
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rbp
mov qword [rax + 8], rcx
push rsi
push rdi
push r12
push r14
push r15
sub rsp, 0x30
xor ebx, ebx
xor ecx, ecx
xor esi, esi
mov qword [rax + 8], rcx
mov r14, r9
mov r15d, r8d
mov r12, rdx
lea ebp, [rbx + 1]
test r8d, r8d
je 0x140002109
mov rdi, r9
test ebp, ebp
je 0x1400020a5
lea r8, [rsp + 0x60]
mov rcx, r12
lea rdx, str.Distribution_Units
call qword [sym.imp.ADVAPI32.dll_RegCreateKeyW]
test eax, eax
jne 0x1400020eb
mov rcx, qword [rsp + 0x60]
xor ebp, ebp
test r14, r14
je 0x1400020de
mov rdx, qword [rdi]
test rdx, rdx
je 0x1400020de
lea rax, [0x140011c10]
mov dword [rsp + 0x28], 1
mov r9d, 1
mov qword [rsp + 0x20], rax
xor r8d, r8d
call qword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
jne 0x1400020eb
mov rcx, qword [rsp + 0x60]
inc esi
add rdi, 8
cmp esi, r15d
jae 0x1400020fe
jmp 0x140002081
mov rcx, qword [rsp + 0x60]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
test rcx, rcx
je 0x140002109
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov rbp, qword [rsp + 0x70]
mov eax, ebx
mov rbx, qword [rsp + 0x68]
add rsp, 0x30
pop r15
pop r14
pop r12
pop rdi
pop rsi
ret
Function at 0x1400023fc
Capabilities:
Query or enumerate registry value
Set registry value

Disassembly:
mov qword [rsp + 8], rcx
push rbp
push rbx
push rdi
mov rbp, rsp
sub rsp, 0x40
and qword [rbp - 8], 0
lea rcx, [rbp - 8]
and qword [rbp - 0x10], 0
mov rdi, rdx
and dword [rbp + 0x38], 0
and dword [rbp + 0x20], 0
mov dword [rbp + 0x30], 4
call fcn.140009d14
mov ebx, eax
test eax, eax
jne 0x1400024ec
mov rcx, qword [rbp - 8]
lea rax, [rbp - 0x10]
mov r9d, 0x2001f
mov qword [rsp + 0x20], rax
xor r8d, r8d
lea rdx, str.SOFTWAREMicrosoftWindowsCurrentVersionSharedDlls
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
je 0x14000247a
mov rcx, qword [rbp - 8]
lea r8, [rbp - 0x10]
lea rdx, str.SOFTWAREMicrosoftWindowsCurrentVersionSharedDlls
call qword [sym.imp.ADVAPI32.dll_RegCreateKeyW]
test eax, eax
jne 0x1400024de
mov rcx, qword [rbp - 0x10]
lea rax, [rbp + 0x30]
mov qword [rsp + 0x28], rax
lea r9, [rbp + 0x38]
lea rax, [rbp + 0x20]
xor r8d, r8d
mov rdx, rdi
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x1400024ab
mov eax, dword [rbp + 0x20]
inc eax
jmp 0x1400024b0
mov eax, 1
mov rcx, qword [rbp - 0x10]
mov r9d, 4
mov dword [rbp + 0x20], eax
xor r8d, r8d
lea rax, [rbp + 0x20]
mov dword [rsp + 0x28], 4
mov rdx, rdi
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
je 0x1400024ec
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
mov rcx, qword [rbp - 0x10]
test rcx, rcx
je 0x1400024fb
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, ebx
add rsp, 0x40
pop rdi
pop rbx
pop rbp
ret