joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1002e370
Capabilities:
Connect socket
Get local ipv4 addresses
Get socket information
Set socket configuration

Disassembly:
mov r11, rsp
sub rsp, 0x98
mov rax, qword [0x1005d650]
mov qword [rsp + 0x78], rax
mov qword [r11 + 0x20], rbx
mov qword [r11 - 8], rbp
mov qword [r11 - 0x10], rsi
mov qword [r11 - 0x18], rdi
xor dil, dil
cmp qword [rcx], 0xffffffffffffffff
mov esi, r8d
mov rbp, rdx
mov rbx, rcx
jne 0x1002e3b7
call fcn.1002e040
cmp rax, 0xffffffffffffffff
je 0x1002e4b6
mov rcx, qword [rbx]
lea r9, [rsp + 0x30]
mov edx, 0xffff
mov r8d, 0x1002
mov dword [rsp + 0x30], 0x80000
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
lea rcx, [rsp + 0x38]
mov rdx, rbp
call fcn.100305e0
mov rcx, qword [rsp + 0x40]
test rcx, rcx
cmove rcx, qword [sym.imp.msvcp60.dll_char_const__private:_static_char_const____ptr64___cdecl_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::_Nullstr_void_::_2::_C]
xor eax, eax
mov dword [rsp + 0x58], eax
mov word [rsp + 0x58], 2
mov dword [rsp + 0x5c], eax
mov dword [rsp + 0x60], eax
mov dword [rsp + 0x64], eax
call qword [sym.imp.WS2_32.dll_inet_addr]
test si, si
mov dword [rsp + 0x5c], eax
jne 0x1002e42c
mov word [rsp + 0x5a], si
jmp 0x1002e43a
movzx ecx, si
call qword [sym.imp.WS2_32.dll_htons]
mov word [rsp + 0x5a], ax
mov rcx, qword [rbx]
lea rdx, [rsp + 0x58]
mov r8d, reloc.WS2_32.dll_recv
call qword [sym.imp.WS2_32.dll_connect]
test eax, eax
jne 0x1002e4a5
mov rcx, qword [rbx]
cmp rcx, 0xffffffffffffffff
je 0x1002e4a0
lea r8, [rsp + 0x30]
lea rdx, [rsp + 0x68]
mov word [rsp + 0x68], ax
mov qword [rsp + 0x6a], rax
mov dword [rsp + 0x72], eax
mov word [rsp + 0x76], ax
mov dword [rsp + 0x30], reloc.WS2_32.dll_recv
call qword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x1002e4a0
movzx ecx, word [rsp + 0x6a]
call qword [sym.imp.WS2_32.dll_htons]
movzx r11d, ax
mov dword [rbx + 0x8c], r11d
mov dil, 1
jmp 0x1002e4ab
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rcx, [rsp + 0x38]
call qword [sym.imp.msvcp60.dll_public:_void___cdecl_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void____ptr64]
mov rsi, qword [rsp + 0x88]
mov rbp, qword [rsp + 0x90]
mov rbx, qword [rsp + 0xb8]
mov al, dil
mov rdi, qword [rsp + 0x80]
mov rcx, qword [rsp + 0x78]
call fcn.10044fa0
add rsp, 0x98
ret
Function at 0x1002e650
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
sub rsp, 0x48
mov rax, qword [0x1005d650]
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x60], rbx
mov qword [rsp + 0x68], rsi
mov qword [rcx], 0xffffffffffffffff
mov rsi, rdx
mov byte [rcx + 8], 1
mov dword [rcx + 0x8c], 0
mov qword [rsp + 0x40], rdi
mov rdi, rcx
xor edx, edx
add rcx, 9
mov r8d, 0x80
call sub.msvcrt.dll_memset
lea r8, str.tcp_cli_socket
lea rdx, [0x1004c560]
lea rcx, [rdi + 9]
call qword [sym.imp.msvcrt.dll_sprintf]
lea rcx, [rdi + 0x90]
xor edx, edx
mov r8d, 0x400
call sub.msvcrt.dll_memset
cmp rsi, 0xffffffffffffffff
mov rbx, qword [rsp + 0x60]
mov qword [rdi], rsi
je 0x1002e721
xor eax, eax
lea r8, [rsp + 0x20]
lea rdx, [rsp + 0x28]
mov rcx, rsi
mov word [rsp + 0x28], 0
mov dword [rsp + 0x20], reloc.WS2_32.dll_recv
mov qword [rsp + 0x2a], rax
mov dword [rsp + 0x32], eax
mov word [rsp + 0x36], ax
call qword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x1002e721
movzx ecx, word [rsp + 0x2a]
call qword [sym.imp.WS2_32.dll_htons]
movzx r11d, ax
mov dword [rdi + 0x8c], r11d
mov rsi, qword [rsp + 0x68]
mov rax, rdi
mov rdi, qword [rsp + 0x40]
mov rcx, qword [rsp + 0x38]
call fcn.10044fa0
add rsp, 0x48
ret

Function at 0x1002e8b0
Capabilities:
Get local ipv4 addresses
Get socket information
Set socket configuration

Disassembly:
sub rsp, 0x48
mov qword [rsp + 0x58], rbp
mov rbp, rcx
mov rcx, qword [rcx]
cmp rcx, 0xffffffffffffffff
mov qword [rsp + 0x60], rsi
je 0x1002e98c
xor r8d, r8d
xor edx, edx
call qword [sym.imp.WS2_32.dll_accept]
cmp rax, 0xffffffffffffffff
mov rsi, rax
jne 0x1002e92f
mov qword [rsp + 0x50], rbx
mov qword [rsp + 0x68], rdi
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
lea rdx, [0x1004c5f8]
lea rcx, [rsp + 0x38]
mov ebx, eax
call fcn.100277d0
mov r9d, dword [rbp + 0x8c]
lea r8, [rbp + 9]
lea rdx, str._comm__Socket__s:_d_::accept_failed:__d
mov rcx, rax
mov dword [rsp + 0x20], ebx
call fcn.100278d0
mov rdi, qword [rsp + 0x68]
mov rbx, qword [rsp + 0x50]
jmp 0x1002e959
mov rcx, qword [rbp]
lea r9, [rsp + 0x30]
mov edx, 0xffff
mov r8d, 0x1002
mov dword [rsp + 0x30], 0x80000
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
test rsi, rsi
je 0x1002e98c
cmp rsi, 0xffffffffffffffff
je 0x1002e98c
mov ecx, 0x490
call sub.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__
test rax, rax
je 0x1002e98c
mov rdx, rsi
mov rcx, rax
mov rsi, qword [rsp + 0x60]
mov rbp, qword [rsp + 0x58]
add rsp, 0x48
jmp fcn.1002e650
mov rsi, qword [rsp + 0x60]
mov rbp, qword [rsp + 0x58]
xor eax, eax
add rsp, 0x48
ret
Function at 0x1002ee00
Capabilities:
Resolve dns

Disassembly:
mov dword [rsp + 0x10], edx
sub rsp, 0x68
mov qword [rsp + 0x58], rbp
mov rbp, qword [rsp + 0x98]
mov qword [rsp + 0x40], r12
mov qword [rsp + 0x38], r13
mov r13, qword [rsp + 0x90]
mov qword [rsp + 0x30], r14
mov qword [rbp], 0
mov qword [rsp + 0x28], r15
movzx r14d, r9w
mov byte [r13], 0
mov r15d, r8d
call qword [sym.imp.WS2_32.dll_gethostbyname]
test rax, rax
mov r12, rax
je 0x1002ef5e
cmp word [rax + 0x10], 2
mov qword [rsp + 0x60], rbx
mov qword [rsp + 0x50], rsi
mov qword [rsp + 0x48], rdi
jne 0x1002ef0d
cmp word [rax + 0x12], 4
jne 0x1002ef0d
mov rdi, qword [rax + 0x18]
mov rcx, qword [rdi]
test rcx, rcx
je 0x1002ef0d
nop
mov esi, dword [rcx]
mov edx, gethostbyname
lea ecx, [rdx - 0x2f]
call qword [sym.imp.msvcrt.dll_calloc]
test rax, rax
mov rbx, rax
je 0x1002eef3
mov edx, reloc.WS2_32.dll_recv
lea ecx, [rdx - 0xf]
call qword [sym.imp.msvcrt.dll_calloc]
test rax, rax
jne 0x1002eec8
mov rcx, rbx
call qword [sym.imp.msvcrt.dll_free]
xor ebx, ebx
jmp 0x1002eef3
mov ecx, dword [rsp + 0x78]
mov word [rax], 2
mov word [rax + 2], r14w
mov dword [rax + 4], esi
mov dword [rbx + 8], ecx
mov dword [rbx + 4], 2
mov dword [rbx + 0xc], r15d
mov qword [rbx + reloc.WS2_32.dll_recv], 0x10
mov qword [rbx + 0x20], rax
test rbx, rbx
mov qword [rbp], rbx
je 0x1002ef57
mov rcx, qword [rdi + 8]
add rdi, 8
lea rbp, [rbx + 0x28]
test rcx, rcx
jne 0x1002ee90
mov rdx, qword [r12]
mov r8d, 0x400
mov rcx, r13
call qword [sym.imp.msvcrt.dll_strncpy]
mov byte [r13 + 0x400], 0
xor eax, eax
mov rsi, qword [rsp + 0x50]
mov rbx, qword [rsp + 0x60]
mov rdi, qword [rsp + 0x48]
mov r15, qword [rsp + 0x28]
mov r14, qword [rsp + 0x30]
mov r13, qword [rsp + 0x38]
mov r12, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x58]
add rsp, 0x68
ret
mov eax, 8
jmp 0x1002ef2a
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
sub eax, 0x2af9
je 0x1002ef75
dec eax
je 0x1002ef83
dec eax
je 0x1002ef7c
dec eax
mov eax, 0x2af9
jmp 0x1002ef39
mov eax, 0x2afb
jmp 0x1002ef39
mov eax, 0x2afa
jmp 0x1002ef39
Function at 0x1002f9c0
Capabilities:
Get common file path

Disassembly:
mov r11, rsp
sub rsp, 0x288
mov rax, qword [0x1005d650]
mov qword [rsp + 0x270], rax
cmp dword [0x10069700], 0
lea rax, [0x1002f320]
mov qword [r11 + 0x10], rbp
mov qword [rsp + 0x28], rax
lea rax, str.getnameinfo
mov qword [r11 - 8], r12
mov qword [rsp + 0x30], rax
lea rax, [0x1002f6f0]
lea r12, str.getaddrinfo
mov qword [rsp + 0x38], rax
lea rax, str.freeaddrinfo
movzx ebp, cx
mov qword [rsp + 0x40], rax
lea rax, [0x1002f2b0]
mov qword [rsp + 0x20], r12
mov qword [rsp + 0x48], rax
jne 0x1002fb9a
lea rcx, [r11 - 0x128]
mov edx, 0x104
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
je 0x1002fb90
mov qword [rsp + 0x290], rbx
xor ebx, ebx
mov rcx, rbx
movzx eax, byte [rsp + rcx + 0x160]
inc rcx
test al, al
mov byte [rsp + rcx + 0x4f], al
jne 0x1002fa60
xor eax, eax
mov qword [rsp + 0x2a0], rsi
mov qword [rsp + 0x2a8], rdi
lea rdi, [rsp + 0x50]
mov rcx, 0xffffffffffffffff
repne scasb al, byte [rdi]
mov rax, qword [str.ws2_32]
lea rcx, [rsp + 0x50]
mov qword [rdi - 1], rax
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
test rax, rax
mov rsi, rax
je 0x1002facb
mov rdx, r12
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
jne 0x1002fb2d
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov rdx, rbx
nop
movzx eax, byte [rsp + rdx + 0x160]
inc rdx
test al, al
mov byte [rsp + rdx + 0x4f], al
jne 0x1002fad0
xor eax, eax
lea rdi, [rsp + 0x50]
mov rcx, 0xffffffffffffffff
repne scasb al, byte [rdi]
mov rax, qword [str.wship6]
lea rcx, [rsp + 0x50]
mov qword [rdi - 1], rax
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
test rax, rax
mov rsi, rax
je 0x1002fb78
mov rdx, r12
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
jne 0x1002fb2d
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
jmp 0x1002fb78
lea rdi, [rsp + 0x28]
mov rdx, qword [rdi - 8]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
mov qword [rdi], rax
je 0x1002fb22
inc rbx
add rdi, 0x10
cmp rbx, 3
jl 0x1002fb32
mov rax, qword [rsp + 0x28]
mov qword [0x1005da40], rax
mov rax, qword [rsp + 0x38]
mov qword [0x1005da50], rax
mov rax, qword [rsp + 0x48]
mov qword [0x1005da60], rax
mov rsi, qword [rsp + 0x2a0]
mov rdi, qword [rsp + 0x2a8]
mov rbx, qword [rsp + 0x290]
mov dword [0x10069700], 1
mov r12, qword [rsp + 0x280]
movzx eax, bp
mov rbp, qword [rsp + 0x298]
lea rcx, str.getaddrinfo
add rax, rax
mov rax, qword [rcx + rax*8 + 8]
mov rcx, qword [rsp + 0x270]
call fcn.10044fa0
add rsp, 0x288
ret
Function at 0x10034d10
Capabilities:
Query or enumerate registry value

Disassembly:
push rbx
sub rsp, 0x40
mov rcx, qword [rcx + 8]
lea rax, [rsp + 0x68]
mov rbx, r8
mov qword [rsp + 0x28], rax
lea rax, [rsp + 0x50]
lea r9, [rsp + 0x30]
xor r8d, r8d
mov dword [rsp + 0x68], 4
mov dword [rsp + 0x50], 0
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x10034d59
mov ecx, dword [rsp + 0x50]
mov dword [rbx], ecx
add rsp, 0x40
pop rbx
ret

Function at 0x10035840
Capabilities:
Delete registry key
Query or enumerate registry key

Disassembly:
mov r11, rsp
sub rsp, 0x178
mov rax, qword [0x1005d650]
mov qword [rsp + 0x150], rax
mov qword [r11 + 0x20], rbx
mov qword [r11 - 8], rbp
test r8d, r8d
mov qword [r11 - 0x10], rsi
mov ebx, 0x10008
mov eax, 0x10108
cmovne ebx, eax
mov qword [r11 - 0x18], rdi
mov edi, r8d
bts ebx, 9
test rdx, rdx
mov rsi, rdx
mov rbp, rcx
jne 0x10035895
mov eax, 0x3f2
jmp 0x10035960
call fcn.10034fc0
lea r11, [rsp + 0x40]
mov r9d, ebx
xor r8d, r8d
mov rdx, rsi
mov rcx, rbp
mov qword [rsp + 0x20], r11
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x10035960
nop
mov rcx, qword [rsp + 0x40]
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x30], rax
mov qword [rsp + 0x28], rax
lea r9, [rsp + 0x48]
lea r8, [rsp + 0x50]
xor edx, edx
mov dword [rsp + 0x48], 0x100
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_RegEnumKeyExA]
cmp eax, 0x103
mov ebx, eax
je 0x1003591f
test eax, eax
jne 0x10035953
mov rcx, qword [rsp + 0x40]
lea rdx, [rsp + 0x50]
mov r8d, edi
call fcn.10035840
mov ebx, eax
test eax, eax
mov eax, 0
je 0x100358c0
jmp 0x10035953
mov r8d, edi
mov rdx, rsi
mov rcx, rbp
call fcn.10034fc0
test edi, edi
je 0x10035945
mov r8d, edi
mov rdx, rsi
mov rcx, rbp
call fcn.10034f10
test eax, eax
mov ebx, eax
je 0x10035953
mov rdx, rsi
mov rcx, rbp
call qword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
mov ebx, eax
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, ebx
mov rdi, qword [rsp + 0x160]
mov rsi, qword [rsp + 0x168]
mov rbp, qword [rsp + 0x170]
mov rbx, qword [rsp + 0x198]
mov rcx, qword [rsp + 0x150]
call fcn.10044fa0
add rsp, 0x178
ret
Function at 0x10036280
Capabilities:
Get disk information
Get process image filename

Disassembly:
mov r11, rsp
sub rsp, 0x198
mov rax, qword [0x1005d650]
mov qword [rsp + 0x150], rax
mov qword [r11 + 0x20], rbx
mov qword [r11 - 8], rbp
mov qword [r11 - 0x18], rdi
mov qword [r11 - 0x20], r12
mov qword [r11 - 0x28], r13
mov edi, ecx
mov qword [r11 - 0x30], r14
movsxd r13, r8d
mov r14, rdx
lea rcx, [rsp + 0x41]
xor r12d, r12d
xor edx, edx
mov r8d, 0x103
mov byte [rsp + 0x40], r12b
call sub.msvcrt.dll_memset
mov r8d, edi
xor edx, edx
mov ecx, 0x400
call qword [sym.imp.KERNEL32.dll_OpenProcess]
test rax, rax
mov rdi, rax
je 0x10036477
lea rdx, [rsp + 0x40]
mov r8d, 0x104
mov rcx, rax
call sub.PSAPI.DLL_GetProcessImageFileNameA
test eax, eax
je 0x10036477
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsA]
test eax, eax
mov ebx, eax
je 0x10036355
inc eax
mov ecx, eax
mov edi, eax
call sub.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__
mov r8, rdi
xor edx, edx
mov rcx, rax
mov rbp, rax
call sub.msvcrt.dll_memset
mov rdx, rbp
mov ecx, ebx
call qword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsA]
test eax, eax
jne 0x1003635c
mov rcx, rbp
call fcn.100449c0
xor eax, eax
jmp 0x1003647a
movzx eax, word [0x1004d884]
lea rcx, [rsp + 0x30]
mov qword [rsp + 0x188], rsi
mov word [rcx], ax
movzx eax, byte [0x1004d886]
mov byte [rcx + 2], al
mov ecx, 0x104
call sub.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__
mov rbx, rbp
mov rsi, rax
nop
movzx eax, byte [rbx]
lea rcx, [rsp + 0x30]
mov r8d, 0x104
mov rdx, rsi
mov byte [rsp + 0x30], al
call qword [sym.imp.KERNEL32.dll_QueryDosDeviceA]
test eax, eax
jne 0x100363eb
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x1003645f
mov rcx, rsi
call fcn.100449c0
mov ecx, 1
call sub.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__
lea rcx, [rsp + 0x30]
mov r8d, 1
mov rdx, rax
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_QueryDosDeviceA]
test eax, eax
je 0x1003645f
xor eax, eax
mov rcx, 0xffffffffffffffff
mov rdi, rsi
repne scasb al, byte [rdi]
mov rdx, rsi
not rcx
dec rcx
mov rdi, rcx
mov r8d, ecx
lea rcx, [rsp + 0x40]
call qword [sym.imp.msvcrt.dll__strnicmp]
test eax, eax
je 0x10036435
nop
nop
nop
movzx eax, byte [rbx]
inc rbx
test al, al
jne 0x10036420
cmp byte [rbx], r12b
jne 0x10036390
jmp 0x1003645f
mov eax, edi
lea r9, [rsp + 0x30]
lea r8, [0x1004d888]
lea rax, [rsp + rax + 0x40]
mov rdx, r13
mov rcx, r14
mov qword [rsp + 0x20], rax
call qword [sym.imp.msvcrt.dll__snprintf]
mov r12d, 1
mov rcx, rbp
call fcn.100449c0
mov rcx, rsi
call fcn.100449c0
mov rsi, qword [rsp + 0x188]
mov eax, r12d
mov r14, qword [rsp + 0x168]
mov r13, qword [rsp + 0x170]
mov r12, qword [rsp + 0x178]
mov rdi, qword [rsp + 0x180]
mov rbp, qword [rsp + 0x190]
mov rbx, qword [rsp + 0x1b8]
mov rcx, qword [rsp + 0x150]
call fcn.10044fa0
add rsp, 0x198
ret
Function at 0x10037100
Capabilities:
Compare security identifiers

Disassembly:
mov r11, rsp
sub rsp, 0x98
mov rax, qword [0x1005d650]
mov qword [rsp + 0x80], rax
mov qword [r11 + 8], rbx
xor ebx, ebx
mov qword [r11 + 0x20], rdi
mov qword [r11 - 0x38], rbx
mov dword [rsp + 0x68], ebx
call qword [sym.imp.KERNEL32.dll_GetCurrentThread]
lea r9, [rsp + 0x60]
lea edx, [rbx + 8]
lea r8d, [rbx + 1]
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenThreadToken]
test eax, eax
mov edi, eax
jne 0x1003717c
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x3f0
jne 0x1003727e
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea r8, [rsp + 0x60]
lea edx, [rbx + 8]
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x10037280
mov ecx, 0x400
mov qword [rsp + 0xa8], rbp
mov qword [rsp + 0xb0], rsi
call sub.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__
mov rcx, qword [rsp + 0x60]
mov r9d, 0x400
mov rsi, rax
lea rax, [rsp + 0x68]
mov edx, 2
mov r8, rsi
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_GetTokenInformation]
mov rcx, qword [rsp + 0x60]
mov ebp, eax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test ebp, ebp
je 0x10037262
lea rax, [rsp + 0x70]
lea rcx, [rsp + 0x78]
mov r9d, 0x220
mov qword [rsp + 0x50], rax
mov dword [rsp + 0x48], ebx
mov dword [rsp + 0x40], ebx
mov dword [rsp + 0x38], ebx
mov dword [rsp + 0x30], ebx
mov r8d, 0x20
mov dl, 2
mov dword [rsp + 0x28], ebx
mov byte [rsp + 0x78], bl
mov dword [rsp + 0x20], ebx
mov byte [rsp + 0x79], bl
mov byte [rsp + 0x7a], bl
mov byte [rsp + 0x7b], bl
mov byte [rsp + 0x7c], bl
mov byte [rsp + 0x7d], 5
call qword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
mov eax, dword [rsi]
dec eax
js 0x10037257
lea rdi, [rsi + 8]
nop
mov rdx, qword [rdi]
mov rcx, qword [rsp + 0x70]
call qword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
jne 0x10037252
mov eax, dword [rsi]
inc ebx
add rdi, 0x10
dec eax
cmp ebx, eax
jle 0x10037230
jmp 0x10037257
mov ebp, 1
mov rcx, qword [rsp + 0x70]
call qword [sym.imp.ADVAPI32.dll_FreeSid]
mov rcx, rsi
call fcn.100449c0
mov rsi, qword [rsp + 0xb0]
mov eax, ebp
mov rbp, qword [rsp + 0xa8]
jmp 0x10037280
mov eax, edi
mov rdi, qword [rsp + 0xb8]
mov rbx, qword [rsp + 0xa0]
mov rcx, qword [rsp + 0x80]
call fcn.10044fa0
add rsp, 0x98
ret
Function at 0x100372b0
Capabilities:
Get token privileges

Disassembly:
sub rsp, 0x98
mov rax, qword [0x1005d650]
mov qword [rsp + 0x80], rax
mov qword [rsp + 0xa8], rbp
xor ebp, ebp
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea r8, [rsp + 0x38]
mov edx, 0x2000000
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x1003742e
mov rcx, qword [rsp + 0x38]
xor eax, eax
xor r9d, r9d
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x48], rax
mov qword [rsp + 0x50], rax
mov qword [rsp + 0x58], rax
mov qword [rsp + 0x60], rax
mov qword [rsp + 0x68], rax
mov qword [rsp + 0x70], rax
mov qword [rsp + 0x78], rax
lea rax, [rsp + 0x30]
lea edx, [r9 + 3]
xor r8d, r8d
mov dword [rsp + 0x30], ebp
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_GetTokenInformation]
mov r11d, dword [rsp + 0x30]
test r11d, r11d
je 0x10037421
mov rcx, r11
mov qword [rsp + 0xb8], rdi
call sub.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__
mov r9d, dword [rsp + 0x30]
mov rcx, qword [rsp + 0x38]
mov rdi, rax
lea rax, [rsp + 0x30]
mov edx, 3
mov r8, rdi
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_GetTokenInformation]
test eax, eax
jne 0x10037392
mov rcx, rdi
call fcn.100449c0
jmp 0x10037419
cmp dword [rdi], ebp
mov qword [rsp + 0xa0], rbx
mov ebx, ebp
jbe 0x10037409
mov qword [rsp + 0xb0], rsi
lea rsi, [rdi + 0xc]
nop
mov eax, ebx
lea r9, [rsp + 0x30]
lea r8, [rsp + 0x40]
lea rcx, [rax + rax*2]
mov dword [rsp + 0x30], 0x3f
lea rdx, [rdi + rcx*4 + 4]
xor ecx, ecx
call qword [sym.imp.ADVAPI32.dll_LookupPrivilegeNameA]
test byte [rsi], 2
je 0x100373f0
lea rdx, str.SeLoadDriverPrivilege
lea rcx, [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
je 0x100373fc
inc ebx
add rsi, 0xc
cmp ebx, dword [rdi]
jb 0x100373b0
jmp 0x10037401
mov ebp, 1
mov rsi, qword [rsp + 0xb0]
mov rcx, rdi
call fcn.100449c0
mov rbx, qword [rsp + 0xa0]
mov rdi, qword [rsp + 0xb8]
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, ebp
mov rbp, qword [rsp + 0xa8]
mov rcx, qword [rsp + 0x80]
call fcn.10044fa0
add rsp, 0x98
ret
Function at 0x10038660
Capabilities:
Query environment variable

Disassembly:
mov r11, rsp
sub rsp, 0x188
mov rax, qword [0x1005d650]
mov qword [rsp + 0x160], rax
mov qword [r11 + 0x20], rbx
mov qword [r11 - 8], rsi
movsxd rsi, edx
movzx ebx, r8b
mov qword [r11 - 0x10], rdi
xor edx, edx
mov r8, rsi
mov rdi, rcx
call sub.msvcrt.dll_memset
lea rcx, [rsp + 0x51]
xor edx, edx
mov r8d, 0x103
mov byte [rsp + 0x50], 0
call sub.msvcrt.dll_memset
lea rdx, [rsp + 0x50]
lea rcx, [0x1004db00]
mov r8d, 0x104
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
lea rcx, [0x1004d7f8]
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
lea rdx, [0x1004d7e0]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x10038727
lea rcx, [rsp + 0x20]
call rax
cmp word [rsp + 0x20], 9
jne 0x10038727
test bl, bl
je 0x10038727
lea rcx, [rsp + 0x50]
xor edx, edx
mov r8d, 0x104
call sub.msvcrt.dll_memset
lea rdx, [rsp + 0x50]
lea rcx, [0x1004db10]
mov r8d, 0x104
call qword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
lea r9, [rsp + 0x50]
lea r8, [0x1004db28]
mov rdx, rsi
mov rcx, rdi
call fcn.1001ff70
mov rdi, qword [rsp + 0x178]
mov rsi, qword [rsp + 0x180]
mov rbx, qword [rsp + 0x1a8]
mov eax, 1
mov rcx, qword [rsp + 0x160]
call fcn.10044fa0
add rsp, 0x188
ret

Function at 0x10038df0
Capabilities:
Check if file exists
Get file attributes
Set file attributes

Disassembly:
test rcx, rcx
je 0x10038e27
push rbx
sub rsp, 0x20
mov rbx, rcx
call qword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x10038e14
add rsp, 0x20
pop rbx
jmp qword [sym.imp.KERNEL32.dll_GetLastError]
and eax, 0xfffffffe
mov rcx, rbx
mov edx, eax
call qword [sym.imp.KERNEL32.dll_SetFileAttributesA]
add rsp, 0x20
pop rbx
ret 0

Function at 0x10038e30
Capabilities:
Delete file
Move file

Disassembly:
push rbx
sub rsp, 0x190
mov qword [rsp + 0x60], 0xfffffffffffffffe
mov rax, qword [0x1005d650]
mov qword [rsp + 0x180], rax
mov rbx, rcx
mov qword [rsp + 0x50], rcx
test rcx, rcx
jne 0x10038e66
lea eax, [rcx - 1]
jmp 0x10038f3e
test edx, edx
je 0x10038e7f
call fcn.10038df0
mov rcx, rbx
call fcn.10038910
nop
jmp 0x10038e7f
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_DeleteFileA]
test eax, eax
jne 0x10038f3c
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
jne 0x10038f35
lea rcx, [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_GetSystemTime]
mov byte [rsp + 0x70], 0
xor edx, edx
mov r8d, 0x103
lea rcx, [rsp + 0x71]
call sub.msvcrt.dll_memset
movzx r11d, word [rsp + 0x5e]
movzx eax, word [rsp + 0x5c]
movzx r8d, word [rsp + 0x5a]
movzx r9d, word [rsp + 0x58]
movzx r10d, word [rsp + 0x56]
mov dword [rsp + 0x40], r11d
mov dword [rsp + 0x38], eax
mov dword [rsp + 0x30], r8d
mov dword [rsp + 0x28], r9d
mov dword [rsp + 0x20], r10d
mov r9, rbx
lea r8, str._s._x_x_x_x_x
mov edx, 0x103
lea rcx, [rsp + 0x70]
call qword [sym.imp.msvcrt.dll__snprintf]
mov r8d, 3
lea rdx, [rsp + 0x70]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_MoveFileExA]
xor edx, edx
lea r8d, [rdx + 4]
lea rcx, [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_MoveFileExA]
mov eax, 0xffffffff
jmp 0x10038f3e
xor eax, eax
mov rcx, qword [rsp + 0x180]
call fcn.10044fa0
add rsp, 0x190
pop rbx
ret
Function at 0x100395a0
Capabilities:
Read file on windows

Disassembly:
mov r11, rsp
sub rsp, 0xc8
mov rax, qword [0x1005d650]
mov qword [rsp + 0xa0], rax
test rdx, rdx
mov qword [r11 + 0x20], rbp
mov rbp, rdx
je 0x1003973f
test rcx, rcx
je 0x1003973f
lea rdx, [0x1004dc04]
mov qword [r11 - 0x18], r12
call qword [sym.imp.msvcrt.dll_fopen]
test rax, rax
mov r12, rax
je 0x1003973b
mov ecx, 0x4000
mov qword [rsp + 0xc0], rsi
mov qword [rsp + 0xb8], rdi
call sub.msvcrt.dll_void____ptr64___cdecl_operator_new_unsigned_long_long_unsigned___int64__
mov rcx, r12
mov rsi, rax
call qword [sym.imp.msvcrt.dll__fileno]
lea rcx, [rsp + 0x20]
mov edi, eax
call fcn.1003de90
mov r8d, 0x4000
mov rdx, rsi
mov ecx, edi
call qword [sym.imp.msvcrt.dll__read]
test eax, eax
jle 0x10039665
nop
nop
nop
lea rcx, [rsp + 0x20]
mov r8d, eax
mov rdx, rsi
call fcn.1003f0a0
mov r8d, 0x4000
mov rdx, rsi
mov ecx, edi
call qword [sym.imp.msvcrt.dll__read]
test eax, eax
jg 0x10039640
lea rdx, [rsp + 0x20]
lea rcx, [rsp + 0x90]
mov qword [rsp + 0xe0], rbx
call fcn.1003f3d0
mov byte [rbp], 0
xor ebx, ebx
nop
nop
nop
movzx r9d, byte [rsp + rbx + 0x90]
lea r8, str._02x
lea rcx, [rsp + 0x80]
mov edx, reloc.WS2_32.dll_recv
call fcn.1001ff70
xor eax, eax
mov rdi, rbp
mov rcx, 0xffffffffffffffff
lea rdx, [rsp + 0x80]
repne scasb al, byte [rdi]
xor ecx, ecx
nop
nop
movzx eax, byte [rdx + rcx]
inc rcx
test al, al
mov byte [rdi + rcx - 2], al
jne 0x100396d0
inc rbx
cmp rbx, 0x10
jl 0x10039690
mov rcx, r12
call qword [sym.imp.msvcrt.dll_fclose]
mov rcx, rsi
call fcn.100449c0
mov rdi, qword [rsp + 0xb8]
mov rsi, qword [rsp + 0xc0]
mov rbx, qword [rsp + 0xe0]
mov eax, 1
mov r12, qword [rsp + 0xb0]
mov rbp, qword [rsp + 0xe8]
mov rcx, qword [rsp + 0xa0]
call fcn.10044fa0
add rsp, 0xc8
ret
xor eax, eax
jmp 0x10039716
xor eax, eax
jmp 0x1003971e