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

Disassembly:
push rsi
push rdi
sub rsp, 0x38
mov rsi, rcx
mov ecx, dword [0x140141108]
test ecx, ecx
je 0x1400deba6
dec ecx
call sub.kernel32.dll_TlsGetValue
cmp rax, 1
jbe 0x1400deac2
mov rdi, rax
cmp qword [rax + 8], 0
jne 0x1400deba0
mov ecx, dword [0x140141108]
test ecx, ecx
je 0x1400debc8
dec ecx
call sub.kernel32.dll_TlsGetValue
cmp rax, 1
je 0x1400debe5
mov rdi, rax
test rax, rax
jne 0x1400deb4c
mov qword [rsp + 0x28], 0
lea rax, dbg.destroy_value_core::cell::Cell_core::option::Option_alloc::sync::Arc_std::sync::mutex::Mutex_alloc::vec::Vec_u8__alloc::alloc::Global____alloc::alloc::Global____
mov qword [rsp + 0x20], rax
mov rax, qword [0x140181648]
movzx eax, byte [rax]
mov ecx, 0x18
mov edx, 8
call sym.__rust_alloc
test rax, rax
je 0x1400dec04
mov rdi, rax
mov rax, qword [rsp + 0x30]
mov qword [rdi + 0x10], rax
movups xmm0, xmmword [rsp + 0x20]
movups xmmword [rdi], xmm0
mov ecx, dword [0x140141108]
test ecx, ecx
je 0x1400debf1
dec ecx
mov rdx, rdi
call fcn.14013f6bc
test rsi, rsi
je 0x1400deb66
mov rax, qword [rsi]
mov qword [rsi], 0
test rax, rax
je 0x1400deb68
mov rax, qword [rsi + 8]
jmp 0x1400deb68
xor eax, eax
mov rdx, qword [rdi + 8]
mov rcx, qword [rdi + 0x10]
mov qword [rsp + 0x20], rdx
mov qword [rsp + 0x28], rcx
mov qword [rdi + 8], 1
mov qword [rdi + 0x10], rax
test rdx, rdx
je 0x1400deba0
test rcx, rcx
je 0x1400deba0
lock dec qword [rcx]
jne 0x1400deba0
lea rcx, [rsp + 0x28]
call dbg.drop_slow<std::sync::mutex::Mutex<alloc::vec::Vec<u8, alloc::alloc::Global>>, alloc::alloc::Global>
add rdi, 0x10
jmp 0x1400debe7
lea rcx, dbg.destroy_value_core::cell::Cell_core::option::Option_alloc::sync::Arc_std::sync::mutex::Mutex_alloc::vec::Vec_u8__alloc::alloc::Global____alloc::alloc::Global____
call sym.std::sys::windows::thread_local_key::StaticKey::init::h2de08b4a932e6024
mov ecx, eax
call sub.kernel32.dll_TlsGetValue
cmp rax, 1
ja 0x1400deab4
jmp 0x1400deac2
lea rcx, dbg.destroy_value_core::cell::Cell_core::option::Option_alloc::sync::Arc_std::sync::mutex::Mutex_alloc::vec::Vec_u8__alloc::alloc::Global____alloc::alloc::Global____
call sym.std::sys::windows::thread_local_key::StaticKey::init::h2de08b4a932e6024
mov ecx, eax
call sub.kernel32.dll_TlsGetValue
cmp rax, 1
jne 0x1400deae1
xor edi, edi
mov rax, rdi
add rsp, 0x38
pop rdi
pop rsi
ret
lea rcx, dbg.destroy_value_core::cell::Cell_core::option::Option_alloc::sync::Arc_std::sync::mutex::Mutex_alloc::vec::Vec_u8__alloc::alloc::Global____alloc::alloc::Global____
call sym.std::sys::windows::thread_local_key::StaticKey::init::h2de08b4a932e6024
mov ecx, eax
jmp 0x1400deb44
mov ecx, 8
mov edx, 0x18
call dbg.handle_alloc_error
ud2
Function at 0x1400dec30
Capabilities:
Generate random numbers via winapi
Get thread local storage value
Set thread local storage value

Disassembly:
push rsi
push rdi
sub rsp, 0x38
mov rsi, rcx
mov ecx, dword [0x140141128]
test ecx, ecx
je 0x1400dec63
dec ecx
call sub.kernel32.dll_TlsGetValue
cmp rax, 1
jbe 0x1400dec7c
mov rcx, rax
cmp qword [rax + 8], 0
je 0x1400dec7c
add rcx, 0x10
jmp 0x1400ded79
lea rcx, dbg.destroy_value_core::cell::Cell__u64__u64___
call sym.std::sys::windows::thread_local_key::StaticKey::init::h2de08b4a932e6024
mov ecx, eax
call sub.kernel32.dll_TlsGetValue
cmp rax, 1
ja 0x1400dec50
mov ecx, dword [0x140141128]
test ecx, ecx
je 0x1400ded5a
dec ecx
call sub.kernel32.dll_TlsGetValue
cmp rax, 1
je 0x1400ded77
mov rdi, rax
test rax, rax
jne 0x1400decf2
mov rax, qword [0x140181648]
movzx eax, byte [rax]
mov ecx, 0x20
mov edx, 8
call sym.__rust_alloc
test rax, rax
je 0x1400ded96
mov rdi, rax
lea rax, dbg.destroy_value_core::cell::Cell__u64__u64___
mov qword [rdi], rax
mov qword [rdi + 8], 0
mov ecx, dword [0x140141128]
test ecx, ecx
je 0x1400ded83
dec ecx
mov rdx, rdi
call fcn.14013f6bc
test rsi, rsi
je 0x1400ded0f
mov rcx, qword [rsi]
mov rax, qword [rsi + 8]
mov rdx, qword [rsi + 0x10]
mov qword [rsi], 0
cmp rcx, 1
je 0x1400ded44
xorps xmm0, xmm0
movaps xmmword [rsp + 0x20], xmm0
lea rdx, [rsp + 0x20]
xor ecx, ecx
mov r8d, 0x10
mov r9d, 2
call sub.bcrypt.dll_BCryptGenRandom
test eax, eax
js 0x1400ded3f
mov rax, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x28]
jmp 0x1400ded44
call dbg.fallback_rng
mov qword [rdi + 8], 1
lea rcx, [rdi + 0x10]
mov qword [rdi + 0x10], rax
mov qword [rdi + 0x18], rdx
jmp 0x1400ded79
lea rcx, dbg.destroy_value_core::cell::Cell__u64__u64___
call sym.std::sys::windows::thread_local_key::StaticKey::init::h2de08b4a932e6024
mov ecx, eax
call sub.kernel32.dll_TlsGetValue
cmp rax, 1
jne 0x1400dec9b
xor ecx, ecx
mov rax, rcx
add rsp, 0x38
pop rdi
pop rsi
ret
lea rcx, dbg.destroy_value_core::cell::Cell__u64__u64___
call sym.std::sys::windows::thread_local_key::StaticKey::init::h2de08b4a932e6024
mov ecx, eax
jmp 0x1400decea
mov ecx, 8
mov edx, 0x20
call dbg.handle_alloc_error
ud2
Function at 0x140125f90
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push r14
push rsi
push rdi
push rbx
sub rsp, 0x28
test r8, r8
je 0x14012600a
mov rax, rdx
mov rdx, qword [rsp + 0x70]
mov esi, ecx
shr esi, 8
lea r8, [rax + r8*2]
xor r11d, r11d
mov rbx, rax
movzx edi, byte [rax + 1]
add rax, 2
lea r10, [r11 + rdi]
cmp byte [rbx], sil
jne 0x140126000
cmp r11, r10
ja 0x1401260a3
cmp r10, rdx
ja 0x1401260b7
add r11, r9
xor ebx, ebx
nop dword [rax]
cmp rdi, rbx
je 0x140126002
lea r14, [rbx + 1]
cmp byte [r11 + rbx], cl
mov rbx, r14
jne 0x140125fe0
jmp 0x140126077
ja 0x14012600a
mov r11, r10
cmp rax, r8
jne 0x140125fb2
mov rdx, qword [rsp + 0x80]
test rdx, rdx
je 0x14012607b
mov r8, qword [rsp + 0x78]
add rdx, r8
movzx ecx, cx
mov al, 1
nop word cs:[rax + rax]
lea r10, [r8 + 1]
movzx r9d, byte [r8]
test r9b, r9b
js 0x140126050
mov r8, r10
sub ecx, r9d
jns 0x14012606e
jmp 0x14012607d
cmp r10, rdx
je 0x140126089
movzx r10d, byte [r8 + 1]
add r8, 2
and r9d, 0x7f
shl r9d, 8
or r9d, r10d
sub ecx, r9d
js 0x14012607d
xor al, 1
cmp r8, rdx
jne 0x140126030
jmp 0x14012607d
xor eax, eax
jmp 0x14012607d
mov al, 1
and al, 1
add rsp, 0x28
pop rbx
pop rdi
pop rsi
pop r14
ret
lea rcx, str.called__Option::unwrap____on_a__None__valueassertion_failed:__buf.is_empty__
lea r8, [0x1401744f8]
mov edx, 0x2b
call dbg.panic
ud2
lea r8, [0x140174510]
mov rcx, r11
mov rdx, r10
call dbg.slice_index_order_fail
ud2
lea r8, [0x140174510]
mov rcx, r10
call dbg.slice_end_index_len_fail
ud2
Function at 0x140140180
Capabilities:
Write file on windows

Disassembly:
push r12
push rbx
sub rsp, 0x38
mov r12, 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 dbg.__acrt_iob_func
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sym.fwrite
mov rbx, qword [rsp + 0x28]
mov ecx, 2
call dbg.__acrt_iob_func
mov rdx, r12
mov rcx, rax
mov r8, rbx
call sym.vfprintf
call sym.abort
nop
nop word [rax + rax]
Function at 0x1401401f0
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rdi, dword [0x1401a12d4]
mov r12, rcx
mov rsi, rdx
mov rbx, r8
test edi, edi
jle 0x1401403a0
mov rax, qword [0x1401a12d8]
xor ecx, ecx
add rax, 0x18
nop
mov rdx, qword [rax]
cmp r12, rdx
jb 0x14014023c
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp r12, rdx
jb 0x1401402c7
add ecx, 1
add rax, 0x28
cmp ecx, edi
jne 0x140140220
mov rcx, r12
call dbg.__mingw_GetSectionForAddress
mov rbp, rax
test rax, rax
je 0x1401403fd
mov rax, qword [0x1401a12d8]
lea rdi, [rdi + rdi*4]
shl rdi, 3
add rax, rdi
mov qword [rax + 0x20], rbp
mov dword [rax], 0
call dbg._GetPEImageBase
mov ecx, dword [rbp + 0xc]
lea rdx, [rsp + 0x20]
mov r8d, 0x30
add rcx, rax
mov rax, qword [0x1401a12d8]
mov qword [rax + rdi + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x1401403e2
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x1401402c0
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x140140350
add dword [0x1401a12d4], 1
cmp ebx, 8
jae 0x1401402f8
test bl, 4
jne 0x1401403b0
test ebx, ebx
je 0x1401402e9
movzx eax, byte [rsi]
mov byte [r12], al
test bl, 2
jne 0x1401403d0
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
mov rax, qword [rsi]
lea rcx, [r12 + 8]
and rcx, 0xfffffffffffffff8
mov qword [r12], rax
mov eax, ebx
mov rdx, qword [rsi + rax - 8]
mov qword [r12 + rax - 8], rdx
sub r12, rcx
add ebx, r12d
sub rsi, r12
and ebx, 0xfffffff8
cmp ebx, 8
jb 0x1401402e9
and ebx, 0xfffffff8
xor eax, eax
mov edx, eax
add eax, 8
mov r8, qword [rsi + rdx]
mov qword [rcx + rdx], r8
cmp eax, ebx
jb 0x14014032a
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
cmp eax, 2
mov rcx, qword [rsp + 0x20]
mov rdx, qword [rsp + 0x38]
mov r8d, 4
mov eax, 0x40
cmovne r8d, eax
add rdi, qword [0x1401a12d8]
mov qword [rdi + 8], rcx
mov r9, rdi
mov qword [rdi + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x1401402c0
call qword [sym.imp.kernel32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call dbg.__report_error
xor edi, edi
jmp 0x140140247
mov eax, dword [rsi]
mov ebx, ebx
mov dword [r12], eax
mov eax, dword [rsi + rbx - 4]
mov dword [r12 + rbx - 4], eax
jmp 0x1401402e9
mov ebx, ebx
movzx eax, word [rsi + rbx - 2]
mov word [r12 + rbx - 2], ax
jmp 0x1401402e9
mov rax, qword [0x1401a12d8]
mov edx, dword [rbp + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rdi + 0x18]
call dbg.__report_error
mov rdx, r12
lea rcx, str.Address__p_has_no_image_section
call dbg.__report_error
nop
nop dword [rax]
Function at 0x140140910
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x1401a1340]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x1401a1320]
test rbx, rbx
je 0x140140964
mov rdi, qword [sym.imp.kernel32.dll_TlsGetValue]
mov rsi, qword [sym.imp.kernel32.dll_GetLastError]
mov ecx, dword [rbx]
call rdi
mov r12, rax
call rsi
test eax, eax
jne 0x14014095b
test r12, r12
je 0x14014095b
mov rax, qword [rbx + 8]
mov rcx, r12
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140140940
lea rcx, [0x1401a1340]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x140140b90
Capabilities:
Parse pe header

Disassembly:
cmp word [rcx], 0x5a4d
jne 0x140140ba0
jmp sym._ValidateImageBase.part.0
xor eax, eax
ret

Function at 0x140140bb0
Capabilities:
Enumerate pe sections

Disassembly:
movsxd rax, dword [rcx + 0x3c]
add rcx, rax
movzx eax, word [rcx + 0x14]
lea rax, [rcx + rax + 0x18]
movzx ecx, word [rcx + 6]
test ecx, ecx
je 0x140140bf5
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
nop dword [rax]
mov r8d, dword [rax + 0xc]
mov rcx, r8
cmp r8, rdx
ja 0x140140bec
add ecx, dword [rax + 8]
cmp rcx, rdx
ja 0x140140bf7
add rax, 0x28
cmp rax, r9
jne 0x140140bd8
xor eax, eax
ret

Function at 0x140140ca0
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r10, qword [0x1401815c0]
xor r8d, r8d
cmp word [r10], 0x5a4d
mov r9, rcx
jne 0x140140d19
mov rcx, r10
call sym._ValidateImageBase.part.0
test eax, eax
je 0x140140d19
movsxd rax, dword [r10 + 0x3c]
mov rcx, r9
sub rcx, r10
add r10, rax
movzx eax, word [r10 + 0x14]
lea r8, [r10 + rax + 0x18]
movzx eax, word [r10 + 6]
test eax, eax
je 0x140140d16
sub eax, 1
lea rax, [rax + rax*4]
lea r9, [r8 + rax*8 + 0x28]
nop dword [rax]
mov edx, dword [r8 + 0xc]
mov rax, rdx
cmp rcx, rdx
jb 0x140140d0d
add eax, dword [r8 + 8]
cmp rcx, rax
jb 0x140140d19
add r8, 0x28
cmp r8, r9
jne 0x140140cf8
xor r8d, r8d
mov rax, r8
add rsp, 0x28
ret

Function at 0x140140e00
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r9, qword [0x1401815c0]
xor eax, eax
cmp word [r9], 0x5a4d
mov r8, rcx
jne 0x140140e6f
mov rcx, r9
call sym._ValidateImageBase.part.0
test eax, eax
je 0x140140e6f
movsxd rax, dword [r9 + 0x3c]
mov rcx, r8
sub rcx, r9
add r9, rax
movzx eax, word [r9 + 0x14]
movzx edx, word [r9 + 6]
lea rax, [r9 + rax + 0x18]
test edx, edx
je 0x140140e6d
sub edx, 1
lea rdx, [rdx + rdx*4]
lea r9, [rax + rdx*8 + 0x28]
mov r8d, dword [rax + 0xc]
mov rdx, r8
cmp rcx, r8
jb 0x140140e64
add edx, dword [rax + 8]
cmp rcx, rdx
jb 0x140140e78
add rax, 0x28
cmp rax, r9
jne 0x140140e50
xor eax, eax
add rsp, 0x28
ret
mov eax, dword [rax + 0x24]
not eax
shr eax, 0x1f
add rsp, 0x28
ret
Function at 0x140140e90
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r11, qword [0x1401815c0]
xor r9d, r9d
cmp word [r11], 0x5a4d
mov r8d, ecx
jne 0x140140f08
mov rcx, r11
call sym._ValidateImageBase.part.0
test eax, eax
je 0x140140f08
movsxd rcx, dword [r11 + 0x3c]
add rcx, r11
mov eax, dword [rcx + 0x90]
test eax, eax
je 0x140140f08
movzx edx, word [rcx + 0x14]
lea rdx, [rcx + rdx + 0x18]
movzx ecx, word [rcx + 6]
test ecx, ecx
je 0x140140f08
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r10, [rdx + rcx*8 + 0x28]
nop dword [rax + rax]
mov r9d, dword [rdx + 0xc]
mov rcx, r9
cmp rax, r9
jb 0x140140efc
add ecx, dword [rdx + 8]
cmp rax, rcx
jb 0x140140f10
add rdx, 0x28
cmp rdx, r10
jne 0x140140ee8
xor r9d, r9d
mov rax, r9
add rsp, 0x28
ret
add rax, r11
jmp 0x140140f20
sub r8d, 1
add rax, 0x14
mov ecx, dword [rax + 4]
test ecx, ecx
jne 0x140140f2e
mov edx, dword [rax + 0xc]
test edx, edx
je 0x140140f05
test r8d, r8d
jg 0x140140f18
mov r9d, dword [rax + 0xc]
add r9, r11
mov rax, r9
add rsp, 0x28
ret
Function at 0x140004020
Capabilities:
Parse pe header

Disassembly:
push rbx
sub rsp, 0x40
mov qword [rsp + 0x58], rdx
mov rbx, r8
xor edx, edx
test rcx, rcx
je 0x140004054
cmp word [rcx], 0x5a4d
jne 0x140004054
movsxd rax, dword [rcx + 0x3c]
cmp eax, 0x400
jg 0x140004054
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x140004054
mov edx, dword [rcx + 0x28]
add rdx, qword [rsp + 0x58]
mov rcx, rbx
call fcn.140003f60
test eax, eax
jne 0x140004070
xor eax, eax
add rsp, 0x40
pop rbx
ret
mov rcx, rbx
call fcn.140003fd0
test rax, rax
je 0x140004065
lea rdx, [rax + 0x10]
lea rax, [rsp + 0x38]
mov rcx, qword [rbx]
mov r9d, 8
mov qword [rsp + 0x20], rax
lea r8, [rsp + 0x58]
mov qword [rsp + 0x38], 0
call fcn.140004816
not eax
shr eax, 0x1f
add rsp, 0x40
pop rbx
ret

Function at 0x140004720
Capabilities:
Execute syscall

Disassembly:
pop rax
mov qword [rsp + 8], rcx
mov qword [rsp + 0x10], rdx
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x20], r9
sub rsp, 0x28
mov rcx, r10
call fcn.1400046c0
add rsp, 0x28
mov rcx, qword [rsp + 8]
mov rdx, qword [rsp + 0x10]
mov r8, qword [rsp + 0x18]
mov r9, qword [rsp + 0x20]
mov r10, rcx
syscall
ret

Function at 0x140004b74
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
mov rax, qword [0x140561818]
xor ebx, ebx
add rax, 0x18
mov r12, rcx
mov ecx, dword [0x140561814]
mov rsi, rdx
mov rdi, r8
cmp ebx, ecx
jge 0x140004bc2
mov rdx, qword [rax]
cmp r12, rdx
jb 0x140004bba
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp r12, rdx
jb 0x140004ca9
inc ebx
add rax, 0x28
jmp 0x140004b9a
mov rcx, r12
call fcn.1400053a1
mov rbp, rax
test rax, rax
jne 0x140004be1
mov rdx, r12
lea rcx, str.Address__p_has_no_image_section
call fcn.140004b10
movsxd rbx, ebx
mov rax, qword [0x140561818]
xor edx, edx
imul rbx, rbx, 0x28
add rax, rbx
mov dword [rax], edx
mov qword [rax + 0x20], rbp
call fcn.14000544f
mov edx, dword [rbp + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x140561818]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
jne 0x140004c43
mov rax, qword [0x140561818]
mov edx, dword [rbp + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call fcn.140004b10
mov eax, dword [rsp + 0x44]
lea edx, [rax - 4]
and edx, 0xfffffffb
je 0x140004ca3
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x140004ca3
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 [0x140561818]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x140004ca3
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.140004b10
inc dword [0x140561814]
mov ecx, edi
mov rdi, r12
rep movsb byte [rdi], byte [rsi]
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret
Function at 0x1400050d0
Capabilities:
Get thread local storage value

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
lea rdi, [0x140561880]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x140561860]
test rbx, rbx
je 0x14000511c
mov ecx, dword [rbx]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_GetLastError]
test rsi, rsi
je 0x140005116
test eax, eax
jne 0x140005116
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
jmp 0x1400050ee
mov rcx, rdi
add rsp, 0x20
pop rbx
pop rsi
pop rdi
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x1400052d0
Capabilities:
Parse pe header

Disassembly:
xor eax, eax
cmp word [rcx], 0x5a4d
jne 0x1400052f3
movsxd rdx, dword [rcx + 0x3c]
add rcx, rdx
cmp dword [rcx], 0x4550
jne 0x1400052f3
xor eax, eax
cmp word [rcx + 0x18], 0x20b
sete al
ret

Function at 0x1400052f4
Capabilities:
Enumerate pe sections

Disassembly:
xor r8d, r8d
movsxd rax, dword [rcx + 0x3c]
add rcx, rax
movzx eax, word [rcx + 0x14]
movzx r9d, word [rcx + 6]
lea rax, [rcx + rax + 0x18]
cmp r8d, r9d
jae 0x14000532e
mov r10d, dword [rax + 0xc]
mov rcx, r10
cmp rdx, r10
jb 0x140005325
add ecx, dword [rax + 8]
cmp rdx, rcx
jb 0x140005330
inc r8d
add rax, 0x28
jmp 0x14000530c
xor eax, eax
ret

Function at 0x1400053a1
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r9, qword [0x14055d8d0]
mov r8, rcx
mov rcx, r9
call fcn.1400052d0
test eax, eax
je 0x1400053cd
mov rdx, r8
mov rcx, r9
sub rdx, r9
add rsp, 0x28
jmp fcn.1400052f4
xor eax, eax
add rsp, 0x28
ret
Function at 0x140017df0
Capabilities:
Write file on windows

Disassembly:
sub rsp, 0x38
mov ecx, 3
call fcn.14001f140
cmp eax, 1
je 0x140017e22
mov ecx, 3
call fcn.1400c2000
test eax, eax
jne 0x140017ed6
cmp dword [reloc.OLEAUT32.dll_SysReAllocString], 1
jne 0x140017ed6
mov qword [rsp + 0x48], rbx
lea rbx, reloc.OLEAUT32.dll_SysReAllocString
mov qword [rsp + 0x30], rdi
mov rax, rbx
xor edi, edi
cmp dword [rax], 0xfc
je 0x140017e4e
add edi, 1
add rax, 0x10
cmp edi, 0x17
jb 0x140017e38
jmp 0x140017ec2
cmp edi, 0x17
jae 0x140017ec2
mov ecx, 3
call fcn.14001f140
cmp eax, 1
je 0x140017e79
mov ecx, 3
call fcn.14001f140
test eax, eax
jne 0x140017ec2
cmp dword [reloc.OLEAUT32.dll_SysReAllocString], 1
jne 0x140017ec2
mov ecx, 0xfffffff4
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
test rax, rax
mov r11, rax
je 0x140017ec2
cmp rax, 0xffffffffffffffff
je 0x140017ec2
movsxd rcx, edi
xor eax, eax
lea r9, [rsp + 0x40]
add rcx, rcx
mov qword [rsp + 0x20], rax
mov rdx, qword [rbx + rcx*8 + 8]
or rcx, 0xffffffffffffffff
mov rdi, rdx
repne scasb al, byte [rdi]
not rcx
lea r8, [rcx - 1]
mov rcx, r11
call qword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, 0xff
call fcn.140017bb0
mov rdi, qword [rsp + 0x30]
mov rbx, qword [rsp + 0x48]
add rsp, 0x38
ret
Function at 0x140001090
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov r11, rsp
mov qword [r11 + 0x10], rbx
mov qword [r11 + 0x18], rbp
push rsi
push rdi
push r12
push r14
push r15
sub rsp, 0x110
mov rax, qword [0x140005008]
xor rax, rsp
mov qword [rsp + 0x108], rax
xor r12d, r12d
mov dword [r11 - 0x78], 0x4e
mov dword [rsp + 0x70], r12d
lea rax, [0x140001060]
mov qword [rsp + 0x78], rax
xorps xmm0, xmm0
mov qword [r11 - 0xb0], rcx
lea rax, [r11 - 0x78]
mov qword [r11 - 0xb8], r12
xorps xmm1, xmm1
mov r14, rcx
movdqa xmmword [rsp + 0x90], xmm0
movdqa xmmword [rsp + 0xa0], xmm1
lea rcx, [rsp + 0x70]
mov qword [r11 - 0x88], rax
mov r15d, r9d
call qword [sym.imp.USER32.dll_RegisterClassW]
mov eax, dword [0x1400056c8]
lea r8, str.Evil_Mario_Virus
cdq
mov qword [rsp + 0x58], r12
sub eax, edx
mov qword [rsp + 0x50], r14
sar eax, 1
mov r9d, 0xc80000
mov qword [rsp + 0x48], r12
mov qword [rsp + 0x40], r12
mov dword [rsp + 0x38], 0x1e0
lea ecx, [rax - 0xf0]
mov dword [rsp + 0x30], 0x280
mov eax, dword [0x1400056cc]
cdq
mov dword [rsp + 0x28], ecx
sub eax, edx
lea ecx, [r12 + 8]
sar eax, 1
lea rdx, [rsp + 0xc0]
sub eax, 0x140
mov dword [rsp + 0x20], eax
call qword [sym.imp.USER32.dll_CreateWindowExW]
lea r9, [rsp + 0xc8]
mov dword [rsp + 0xd0], r12d
mov rbp, rax
xor r8d, r8d
lea rax, vtable.PlayerCallback.0
xor edx, edx
mov qword [rsp + 0xc8], rax
xor ecx, ecx
lea rax, [0x1400056b8]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], rbp
call qword [sym.imp.MFPlay.DLL_MFPCreateMediaPlayer]
mov rdx, qword [0x1400056b8]
mov rcx, r14
mov r8, qword [rdx]
lea edx, [r12 + 0x66]
mov rsi, qword [r8 + 0x78]
lea r8, [0x140003380]
call qword [sym.imp.KERNEL32.dll_FindResourceW]
mov rdx, rax
mov rcx, r14
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_LoadResource]
mov rdx, rbx
mov rcx, r14
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_SizeofResource]
mov rcx, rdi
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_LockResource]
mov rcx, rax
mov edx, ebx
call qword [sym.imp.SHLWAPI.dll_SHCreateMemStream]
mov rcx, rdi
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_FreeResource]
lea rdx, [rsp + 0x60]
mov rcx, rbx
call qword [sym.imp.MFPlat.DLL_MFCreateMFByteStreamOnStream]
xor r9d, r9d
mov qword [rsp + 0x20], r12
mov rdx, qword [rsp + 0x60]
xor r8d, r8d
mov rcx, qword [0x1400056b8]
call rsi
mov edx, r15d
mov rcx, rbp
call qword [sym.imp.USER32.dll_ShowWindow]
xor r9d, r9d
lea rcx, [rsp + 0xd8]
xor r8d, r8d
xor edx, edx
call qword [sym.imp.USER32.dll_GetMessageW]
test eax, eax
jle 0x1400012b6
nop word [rax + rax]
lea rcx, [rsp + 0xd8]
call qword [sym.imp.USER32.dll_TranslateMessage]
lea rcx, [rsp + 0xd8]
call qword [sym.imp.USER32.dll_DispatchMessageW]
xor r9d, r9d
lea rcx, [rsp + 0xd8]
xor r8d, r8d
xor edx, edx
call qword [sym.imp.USER32.dll_GetMessageW]
test eax, eax
jg 0x140001280
mov rcx, qword [0x1400056b8]
mov rax, qword [rcx]
call qword [rax + 0x10]
xor eax, eax
mov rcx, qword [rsp + 0x108]
xor rcx, rsp
call fcn.1400015f0
lea r11, [rsp + 0x110]
mov rbx, qword [r11 + 0x38]
mov rbp, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r12
pop rdi
pop rsi
ret