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

Disassembly:
push rbp
push r15
push r14
push rsi
push rdi
push rbx
sub rsp, 0x88
lea rbp, [rsp + 0x80]
mov rdi, rcx
lea rax, str.stdoutstd_srciomod.rsfailed_to_write_whole_buffer
mov qword [rbp - 0x60], rax
mov qword [rbp - 0x58], 6
mov eax, dword [0x140044070]
cmp eax, 3
jne 0x140031f82
mov ecx, dword [0x1400440d8]
test ecx, ecx
je 0x140031f8c
dec ecx
call sub.KERNEL32.dll_TlsGetValue
mov rsi, rax
test rax, rax
je 0x140031f9f
mov rax, qword [0x140044038]
cmp rsi, rax
jne 0x140031e6c
mov eax, dword [0x140044040]
cmp eax, 0xffffffff
je 0x14003201c
inc eax
jmp 0x140031e8a
mov cl, 1
xor eax, eax
lock cmpxchg byte [0x140044044], cl
jne 0x140031fac
mov qword [0x140044038], rsi
mov eax, 1
mov dword [0x140044040], eax
lea rax, [0x140044038]
mov qword [rbp], rax
mov r14, rbp
mov qword [rbp - 0x20], r14
mov qword [rbp - 0x18], 0
lea rdx, [0x14003c698]
lea rsi, [rbp - 0x20]
mov rcx, rsi
mov r8, rdi
call fcn.1400043d0
mov r15, qword [rbp - 0x18]
test al, al
je 0x140031f04
test r15, r15
jne 0x140031f4b
lea rax, str.a_formatting_trait_implementation_returned_an_error_when_the_underlying_stream_did_not
mov qword [rbp - 0x50], rax
mov qword [rbp - 0x48], 1
mov qword [rbp - 0x40], 8
xorps xmm0, xmm0
movups xmmword [rbp - 0x38], xmm0
lea rdx, [0x14003cff0]
lea rcx, [rbp - 0x50]
call fcn.140003510
jmp 0x14003201a
mov eax, r15d
and eax, 3
cmp eax, 1
jne 0x140031f48
lea rdi, [r15 - 1]
mov rbx, qword [r15 - 1]
mov r15, qword [r15 + 7]
mov rax, qword [r15]
test rax, rax
je 0x140031f28
mov rcx, rbx
call rax
cmp qword [r15 + 8], 0
je 0x140031f3b
mov rdx, qword [r15 + 0x10]
mov rcx, rbx
call fcn.1400072b0
mov edx, 8
mov rcx, rdi
call fcn.1400072b0
xor r15d, r15d
mov rcx, qword [rbp]
dec dword [rcx + 8]
jne 0x140031f6d
mov qword [rcx], 0
xor eax, eax
xchg byte [rcx + 0xc], al
cmp al, 2
jne 0x140031f6d
add rcx, 0xc
call sub.api_ms_win_core_synch_l1_2_0.dll_WakeByAddressSingle
test r15, r15
jne 0x140031fbd
add rsp, 0x88
pop rbx
pop rdi
pop rsi
pop r14
pop r15
pop rbp
ret
call fcn.14003175d
jmp 0x140031e2c
lea rcx, [0x1400440c0]
call fcn.14000f4b0
mov ecx, eax
jmp 0x140031e3c
call fcn.140010e40
mov rsi, rax
jmp 0x140031e4d
lea rcx, [0x140044044]
call fcn.140013a30
jmp 0x140031e7e
mov qword [rbp], r15
lea rax, [rbp - 0x60]
mov qword [rbp - 0x20], rax
lea rax, [0x1400119e0]
mov qword [rbp - 0x18], rax
mov qword [rbp - 0x10], r14
lea rax, [0x140030e40]
mov qword [rbp - 8], rax
lea rax, [0x14003cee8]
mov qword [rbp - 0x50], rax
mov qword [rbp - 0x48], 2
mov qword [rbp - 0x30], 0
mov qword [rbp - 0x40], rsi
mov qword [rbp - 0x38], 2
lea rdx, str.std_srcio_stdio.rs
lea rcx, [rbp - 0x50]
call fcn.140003510
ud2
call fcn.140005370
mov rsi, rax
cmp qword [r15 + 8], 0
je 0x140032037
mov rdx, qword [r15 + 0x10]
mov rcx, rbx
call fcn.1400072b0
mov edx, 8
mov rcx, rdi
call fcn.1400072b0
jmp 0x14003206a
mov rcx, qword [rbp]
call fcn.1400112b0
mov rcx, rsi
call fcn.1400353a0
call fcn.140005591
int3
Function at 0x140033d05
Capabilities:
Get thread local storage value
Query environment variable

Disassembly:
push rbp
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbx
sub rsp, 0x4e8
lea rbp, [rsp + 0x80]
mov qword [rbp + 0x400], rcx
mov qword [rbp + 0x408], rdx
mov qword [rbp + 0x420], r8
lock inc qword [0x1400440a0]
jle 0x14003461b
mov r12d, r9d
mov rsi, rdx
mov rdi, rcx
call fcn.140010470
test rax, rax
jne 0x140033d7c
lea rcx, [rbp + 0x3e8]
and dword [rcx], 0
mov byte [rcx + 4], 0
lea rax, [rbp + 0x420]
lea r8, [rbp + 0x3a8]
mov qword [r8], rax
lea rax, [0x140033b10]
mov qword [r8 + 8], rax
lea rax, [rbp + 0x400]
mov qword [r8 + 0x10], rax
lea rax, [0x14003d630]
lea rdx, [rbp - 0x58]
mov qword [rdx], rax
mov qword [rdx + 8], 3
and qword [rdx + 0x20], 0
lea rax, [0x140004390]
mov qword [r8 + 0x18], rax
mov qword [rdx + 0x10], r8
mov qword [rdx + 0x18], 2
call fcn.14000f680
lea rcx, [rbp + 0x428]
jmp 0x140034721

Function at 0x140035d10
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 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.140036b20
call sub.api_ms_win_crt_runtime_l1_1_0.dll_abort
nop
nop dword [rax]
Function at 0x140035d80
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x140044184]
mov rbx, rcx
test esi, esi
jle 0x140035eb0
mov rax, qword [0x140044188]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x140035dcb
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x140035e55
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x140035db0
mov rcx, rbx
call fcn.140036840
mov rdi, rax
test rax, rax
je 0x140035ed2
mov rax, qword [0x140044188]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call fcn.140036980
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x140044188]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x140035eb7
mov eax, dword [rsp + 0x44]
lea edx, [rax - 4]
and edx, 0xfffffffb
je 0x140035e4e
lea edx, [rax - 0x40]
and edx, 0xffffffbf
jne 0x140035e60
add dword [0x140044184], 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 [0x140044188]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x140035e4e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.140035d10
nop dword [rax]
xor esi, esi
jmp 0x140035dd8
mov rax, qword [0x140044188]
mov edx, dword [rdi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call fcn.140035d10
mov rdx, rbx
lea rcx, str.Address__p_has_no_image_section
call fcn.140035d10
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x140036480
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x1400441e0]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x1400441c0]
test rbx, rbx
je 0x1400364e4
mov rbp, qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, qword [sym.imp.KERNEL32.dll_GetLastError]
nop word cs:[rax + rax]
nop
mov ecx, dword [rbx]
call rbp
mov rsi, rax
call rdi
test rsi, rsi
je 0x1400364db
test eax, eax
jne 0x1400364db
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x1400364c0
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 0x140036840
Capabilities:
Enumerate pe sections
Parse pe header

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

Function at 0x1400368c0
Capabilities:
Parse pe header

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

Function at 0x140036980
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x14003e7a0]
xor edx, edx
cmp word [rax], 0x5a4d
jne 0x14003699f
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
je 0x1400369a8
mov rax, rdx
ret
cmp word [rcx + 0x18], 0x20b
cmove rdx, rax
mov rax, rdx
ret
Function at 0x140001565
Capabilities:
Create thread

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x40
xor r9d, r9d
mov rbp, rcx
xor ecx, ecx
mov dword [rsp + 0x20], edx
mov ebx, edx
mov qword [rsp + 0x28], rcx
xor edx, edx
or rcx, 0xffffffffffffffff
mov r12, r8
mov r8d, 0x40
call qword [sym.imp.KERNEL32.dll_CreateFileMappingA]
xor r8d, r8d
xor r9d, r9d
mov edx, 0xf003f
mov qword [rsp + 0x20], r8
mov rdi, rax
xor r8d, r8d
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov rcx, rdi
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
cmp ebx, eax
jle 0x1400015de
mov rdx, rax
and edx, 0x7f
mov dl, byte [r12 + rdx]
xor dl, byte [rbp + rax]
mov byte [rsi + rax], dl
inc rax
jmp 0x1400015c4
mov rcx, rsi
lea r9, [rsp + 0x3c]
mov r8d, 0x20
call fcn.140001533
movsxd rdx, ebx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
xor eax, eax
xor edx, edx
mov r9, rsi
mov dword [rsp + 0x20], edx
lea r8, [0x140001530]
xor edx, edx
xor ecx, ecx
mov qword [rsp + 0x28], rax
call qword [sym.imp.KERNEL32.dll_CreateThread]
nop
add rsp, 0x40
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret

Function at 0x140001950
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.140002780
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.140002780
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 0x1400019c0
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x1400770e4]
mov rbx, rcx
test esi, esi
jle 0x140001af0
mov rax, qword [0x1400770e8]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x140001a0b
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x140001a95
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x1400019f0
mov rcx, rbx
call fcn.140002410
mov rdi, rax
test rax, rax
je 0x140001b12
mov rax, qword [0x1400770e8]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call fcn.140002550
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x1400770e8]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x140001af7
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x140001a8e
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x140001aa0
add dword [0x1400770e4], 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 [0x1400770e8]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x140001a8e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.140001950
nop dword [rax]
xor esi, esi
jmp 0x140001a18
mov rax, qword [0x1400770e8]
mov edx, dword [rdi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call fcn.140001950
mov rdx, rbx
lea rcx, str.Address__p_has_no_image_section
call fcn.140001950
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x140002080
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x140077140]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x140077120]
test rbx, rbx
je 0x1400020dc
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 0x1400020d3
test rsi, rsi
je 0x1400020d3
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x1400020b8
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 0x140002410
Capabilities:
Enumerate pe sections
Parse pe header

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

Function at 0x140002490
Capabilities:
Parse pe header

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

Function at 0x140002550
Capabilities:
Parse pe header

Disassembly:
mov rax, qword [0x140074390]
xor edx, edx
cmp word [rax], 0x5a4d
jne 0x14000256f
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
je 0x140002578
mov rax, rdx
ret
cmp word [rcx + 0x18], 0x20b
cmove rdx, rax
mov rax, rdx
ret
Function at 0x1400012fc
Capabilities:
Encode data using xor
Hash data using fnv

Disassembly:
movabs rdx, 0xcbf29ce484222325
xor r8d, r8d
movzx eax, byte [rcx + r8]
movabs r9, 0x100000001b3
xor rdx, rax
inc r8
imul rdx, r9
cmp r8, 4
jb 0x140001309
mov rax, rdx
ret

Function at 0x140001ed8
Capabilities:
Allocate or change rwx memory

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x20
mov rdx, qword [rcx + 8]
mov rbx, rcx
sub rdx, qword [rcx]
mov r8d, 0x3000
xor ecx, ecx
lea r9d, [rcx + 0x40]
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rdi, rax
test rax, rax
je 0x140001f61
mov r8, qword [rbx + 8]
mov rcx, rax
sub r8, qword [rbx]
mov rdx, qword [rbx]
call sub.VCRUNTIME140.dll_memcpy
xor r8d, r8d
lea rcx, [0x140001080]
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_CreateThreadpoolWork]
mov rbx, rax
test rax, rax
je 0x140001f50
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SubmitThreadpoolWork]
xor edx, edx
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_WaitForThreadpoolWorkCallbacks]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseThreadpoolWork]
xor edx, edx
mov r8d, 0x8000
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rbx, qword [rsp + 0x30]
add rsp, 0x20
pop rdi
ret

Function at 0x140001f6c
Capabilities:
Resolve function by parsing pe exports

Disassembly:
mov rax, rsp
mov qword [rax + 0x18], rbx
mov dword [rax + 8], ecx
push rdi
sub rsp, 0x30
lea r8, [rax + 8]
lea rdx, [rax + 0x10]
lea rcx, [0x140008330]
call fcn.1400016ec
mov rdx, qword [0x140008338]
cmp qword [rax], rdx
je 0x140001fba
lea r8, [rsp + 0x40]
lea rdx, [rsp + 0x20]
lea rcx, [0x140008330]
call fcn.14000146c
mov rax, qword [rax]
mov rax, qword [rax + 0x18]
jmp 0x14000202c
lea rcx, [0x140005588]
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov r8, rax
test rax, rax
je 0x14000202a
movsxd rcx, dword [rax + 0x3c]
xor r9d, r9d
mov edx, dword [rcx + rax + 0x88]
add rdx, rax
mov ecx, dword [rdx + 0x20]
mov r11d, dword [rdx + 0x1c]
add rcx, rax
mov ebx, dword [rdx + 0x24]
add r11, rax
mov edi, dword [rdx + 0x18]
add rbx, rax
test edi, edi
je 0x14000202a
mov edx, dword [rcx]
add rdx, r8
xor r10d, r10d
jmp 0x140002011
imul r10d, r10d, 0x21
movsx eax, al
add r10d, eax
inc rdx
mov al, byte [rdx]
test al, al
jne 0x140002004
cmp r10d, dword [rsp + 0x40]
je 0x140002037
inc r9d
add rcx, 4
cmp r9d, edi
jb 0x140001ffa
xor eax, eax
mov rbx, qword [rsp + 0x50]
add rsp, 0x30
pop rdi
ret
movzx ecx, word [rbx + r9*2]
lea rdx, [rsp + 0x20]
mov ebx, dword [r11 + rcx*4]
lea rcx, [0x140008330]
add rbx, r8
lea r8, [rsp + 0x40]
call fcn.14000146c
mov rcx, qword [rax]
mov rax, rbx
mov qword [rcx + 0x18], rbx
jmp 0x14000202c
Function at 0x140002068
Capabilities:
Enumerate pe sections
Get common file path
Get file size
Overwrite dll .text section to remove hooks
Read file via mapping

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x460
xor r14d, r14d
lea rdx, str.VirtualProtect
mov ecx, r14d
mov al, 0x56
lea esi, [r14 + 1]
imul ecx, ecx, 0x21
add rdx, rsi
movsx eax, al
add ecx, eax
mov al, byte [rdx]
test al, al
jne 0x14000209a
call fcn.140001f6c
lea rcx, str.ntdll.dll
mov r13, rax
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov r12, rax
test rax, rax
je 0x14000226f
mov ebx, 0x208
lea rcx, [rsp + 0x250]
mov r8d, ebx
xor edx, edx
call sub.VCRUNTIME140.dll_memset
mov edi, 0x104
lea rcx, [rsp + 0x250]
mov edx, edi
call qword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
mov r8d, ebx
lea rcx, [rsp + 0x40]
xor edx, edx
call sub.VCRUNTIME140.dll_memset
lea r8, [rsp + 0x250]
mov edx, edi
lea rcx, [rsp + 0x40]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscat_s]
lea r8, str._ntdll.dll
mov edx, edi
lea rcx, [rsp + 0x40]
call qword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_wcscat_s]
mov qword [rsp + 0x30], r14
lea rcx, [rsp + 0x40]
mov dword [rsp + 0x28], 0x80
xor r9d, r9d
mov r8d, esi
mov dword [rsp + 0x20], 3
mov edx, 0x80000000
call qword [sym.imp.KERNEL32.dll_CreateFileW]
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x14000226f
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0xffffffff
je 0x140002266
xor r9d, r9d
mov qword [rsp + 0x28], r14
xor edx, edx
mov dword [rsp + 0x20], eax
mov rcx, rbx
lea r8d, [r9 + 2]
call qword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov rsi, rax
test rax, rax
je 0x140002266
xor r9d, r9d
mov qword [rsp + 0x20], r14
xor r8d, r8d
mov rcx, rax
lea edx, [r9 + 4]
call qword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov rbp, rax
test rax, rax
je 0x14000225d
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
xor eax, eax
movzx edi, word [rcx + 0x14]
movzx r15d, word [rcx + 6]
add rdi, 0x18
add rdi, rcx
cmp ax, r15w
jae 0x140002254
lea rdx, str..text
mov rcx, rdi
call sub.api_ms_win_crt_string_l1_1_0.dll_strcmp
test eax, eax
je 0x140002209
inc r14w
add rdi, 0x28
cmp r14w, r15w
jb 0x1400021e6
jmp 0x140002254
mov ecx, dword [rdi + 0xc]
lea r9, [rsp + 0x490]
mov edx, dword [rdi + 8]
add rcx, r12
mov r8d, 0x40
call r13
mov edx, dword [rdi + 0x14]
mov ecx, dword [rdi + 0xc]
add rdx, rbp
mov r8d, dword [rdi + 0x10]
add rcx, r12
call sub.VCRUNTIME140.dll_memcpy
mov ecx, dword [rdi + 0xc]
lea r9, [rsp + 0x490]
mov edx, dword [rdi + 8]
add rcx, r12
mov r8d, dword [rsp + 0x490]
call r13
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea r11, [rsp + 0x460]
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 0x1400024b8
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x10], rbx
push rdi
sub rsp, 0x50
cmp qword [rcx + 0x68], 0
mov rbx, rcx
je 0x140002514
cmp byte [rcx + 0x71], 0
je 0x140002514
mov rax, qword [rcx]
or edx, 0xffffffff
call qword [rax + 0x18]
cmp eax, 0xffffffff
je 0x14000255c
mov rcx, qword [rbx + 0x68]
lea rax, [rsp + 0x60]
lea rdx, [rbx + 0x74]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x50]
lea r8, [rsp + 0x30]
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::codecvt_char__char__struct__Mbstatet_::unshift_struct__Mbstatet____ptr64__char____ptr64__char____ptr64__char____ptr64____ptr64_const___ptr64]
test eax, eax
je 0x140002521
sub eax, 1
je 0x140002525
cmp eax, 2
jne 0x14000255c
mov byte [rbx + 0x71], 0
mov al, 1
mov rbx, qword [rsp + 0x68]
add rsp, 0x50
pop rdi
ret
mov byte [rbx + 0x71], 0
mov rdi, qword [rsp + 0x60]
lea rax, [rsp + 0x30]
sub rdi, rax
je 0x140002553
mov r9, qword [rbx + 0x80]
lea rcx, [rsp + 0x30]
mov r8, rdi
mov edx, 1
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
cmp rdi, rax
jne 0x14000255c
cmp byte [rbx + 0x71], 0
sete al
jmp 0x140002516
xor al, al
jmp 0x140002516
Function at 0x1400029f4
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rbp
push rdi
push r14
mov rbp, rsp
sub rsp, 0x70
or r14d, 0xffffffff
mov esi, edx
mov rdi, rcx
cmp edx, r14d
jne 0x140002a1e
xor eax, eax
jmp 0x140002b3f
call qword [sym.imp.MSVCP140.dll_protected:_char____ptr64___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::pptr_void_const___ptr64]
test rax, rax
je 0x140002a56
mov rcx, rdi
call qword [sym.imp.MSVCP140.dll_protected:_char____ptr64___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::epptr_void_const___ptr64]
mov rcx, rdi
mov rbx, rax
call qword [sym.imp.MSVCP140.dll_protected:_char____ptr64___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::pptr_void_const___ptr64]
cmp rax, rbx
jae 0x140002a56
mov rcx, rdi
call qword [sym.imp.MSVCP140.dll_protected:_char____ptr64___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::_Pninc_void____ptr64]
mov byte [rax], sil
mov eax, esi
jmp 0x140002b3f
cmp qword [rdi + 0x80], 0
je 0x140002b3c
mov rcx, rdi
call qword [sym.imp.MSVCP140.dll_protected:_char____ptr64___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::eback_void_const___ptr64]
lea rcx, [rdi + 0x70]
cmp rax, rcx
jne 0x140002a90
mov rdx, qword [rdi + 0x88]
mov rcx, rdi
mov r9, qword [rdi + 0x90]
mov r8, rdx
call qword [sym.imp.MSVCP140.dll_protected:_void___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::setg_char____ptr64__char____ptr64__char____ptr64____ptr64]
mov rcx, qword [rdi + 0x68]
test rcx, rcx
jne 0x140002ab3
movsx ecx, sil
mov rdx, qword [rdi + 0x80]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fputc]
cmp eax, r14d
cmove esi, r14d
jmp 0x140002a4f
lea rax, [rbp + 0x30]
mov byte [rbp - 0x30], sil
mov qword [rsp + 0x38], rax
lea rdx, [rdi + 0x74]
lea rax, [rbp - 8]
mov qword [rsp + 0x30], rax
lea r9, [rbp - 0x2f]
lea rax, [rbp - 0x28]
mov qword [rsp + 0x28], rax
lea r8, [rbp - 0x30]
lea rax, [rbp + 0x38]
mov qword [rsp + 0x20], rax
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::codecvt_char__char__struct__Mbstatet_::out_struct__Mbstatet____ptr64__char_const____ptr64__char_const____ptr64__char_const____ptr64____ptr64__char____ptr64__char____ptr64__char____ptr64____ptr64_const___ptr64]
test eax, eax
je 0x140002b01
sub eax, 1
je 0x140002b01
cmp eax, 2
jne 0x140002b3c
movsx ecx, byte [rbp - 0x30]
jmp 0x140002a9d
mov rbx, qword [rbp + 0x30]
lea rax, [rbp - 0x28]
sub rbx, rax
je 0x140002b2c
mov r9, qword [rdi + 0x80]
lea rcx, [rbp - 0x28]
mov r8, rbx
mov edx, 1
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
cmp rbx, rax
jne 0x140002b3c
lea rax, [rbp - 0x30]
mov byte [rdi + 0x71], 1
cmp qword [rbp + 0x38], rax
cmovne r14d, esi
mov eax, r14d
lea r11, [rsp + 0x70]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rsp, r11
pop r14
pop rdi
pop rbp
ret