joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140002cd0
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.1400048e0
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.1400048e0
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 0x140002d40
Capabilities:
Allocate or change rwx memory

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rsi, dword [0x14000a0a4]
mov rbx, rcx
test esi, esi
jle 0x140002e70
mov rax, qword [0x14000a0a8]
xor r9d, r9d
add rax, 0x18
nop word [rax + rax]
mov r8, qword [rax]
cmp rbx, r8
jb 0x140002d8b
mov rdx, qword [rax + 8]
mov edx, dword [rdx + 8]
add r8, rdx
cmp rbx, r8
jb 0x140002e15
add r9d, 1
add rax, 0x28
cmp r9d, esi
jne 0x140002d70
mov rcx, rbx
call fcn.140003790
mov rdi, rax
test rax, rax
je 0x140002e92
mov rax, qword [0x14000a0a8]
lea rbx, [rsi + rsi*4]
shl rbx, 3
add rax, rbx
mov qword [rax + 0x20], rdi
mov dword [rax], 0
call fcn.1400038d0
mov edx, dword [rdi + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x14000a0a8]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x140002e77
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x140002e0e
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x140002e20
add dword [0x14000a0a4], 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 [0x14000a0a8]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x140002e0e
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.140002cd0
nop dword [rax]
xor esi, esi
jmp 0x140002d98
mov rax, qword [0x14000a0a8]
mov edx, dword [rdi + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call fcn.140002cd0
mov rdx, rbx
lea rcx, str.Address__p_has_no_image_section
call fcn.140002cd0
nop
nop word cs:[rax + rax]
nop dword [rax]

Function at 0x140003400
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea r12, [0x14000a100]
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x14000a0e0]
test rbx, rbx
je 0x14000345c
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 0x140003453
test rsi, rsi
je 0x140003453
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140003438
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 0x140003790
Capabilities:
Enumerate pe sections
Parse pe header

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

Function at 0x140003810
Capabilities:
Parse pe header

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

Function at 0x1400038d0
Capabilities:
Parse pe header

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

Disassembly:
sub rsp, 0x28
mov rax, qword [0x00404470]
xor edx, edx
mov dword [rax], 1
mov rax, qword [0x00404480]
mov dword [rax], 1
mov rax, qword [0x00404490]
mov dword [rax], 1
mov rax, qword [0x00404460]
mov dword [rax], 1
mov rax, qword [0x00404320]
cmp word [rax], 0x5a4d
je 0x4010d0
mov rax, qword [0x00404450]
mov dword [0x00407008], edx
mov eax, dword [rax]
test eax, eax
je 0x4010c2
mov ecx, 2
call sym.__set_app_type
mov rcx, 0xffffffffffffffff
call dbg._encode_pointer
mov rdx, qword [0x004043b0]
mov qword [rdx], rax
mov rdx, qword [0x004043a0]
mov qword [rdx], rax
mov rax, qword [0x00404410]
mov edx, dword [rax]
mov rax, qword [sym.imp.msvcrt.dll__fmode]
mov rax, qword [rax]
mov dword [rax], edx
call dbg._setargv
mov rax, qword [0x004042d0]
cmp dword [rax], 1
je 0x401120
xor eax, eax
add rsp, 0x28
ret
mov ecx, 1
call sym.__set_app_type
jmp 0x401075
movsxd rcx, dword [rax + 0x3c]
add rax, rcx
cmp dword [rax], 0x4550
jne 0x401058
movzx ecx, word [rax + 0x18]
cmp cx, 0x10b
je 0x401133
cmp cx, 0x20b
jne 0x401058
cmp dword [rax + 0x84], 0xe
jbe 0x401058
mov ecx, dword [rax + 0xf8]
xor edx, edx
test ecx, ecx
setne dl
jmp 0x401058
lea rcx, [dbg._matherr]
call dbg.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
cmp dword [rax + 0x74], 0xe
jbe 0x401058
mov r8d, dword [rax + 0xe8]
xor edx, edx
test r8d, r8d
setne dl
jmp 0x401058

Function at 0x401530
Capabilities:
Execute command

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x50
call dbg.__main
mov dword [rbp - 0x20], 0x4d2
mov eax, dword [0x00404020]
mov dword [rbp - 0x1c], eax
mov eax, dword [0x00404024]
mov dword [rbp - 0x18], eax
mov eax, dword [0x00404028]
mov dword [rbp - 0x14], eax
mov eax, dword [0x0040402c]
mov dword [rbp - 0x10], eax
movss xmm1, dword [rbp - 0x1c]
movss xmm0, dword [rbp - 0x18]
addss xmm0, xmm1
movss xmm1, dword [rbp - 0x14]
addss xmm0, xmm1
movss xmm1, dword [rbp - 0x10]
addss xmm0, xmm1
movss xmm1, dword [0x00404030]
divss xmm0, xmm1
movd eax, xmm0
mov dword [rbp - 0x10], eax
mov eax, dword [rbp - 0x20]
mov edx, eax
lea rcx, str.RA_:___d_n
call sym.printf
movss xmm0, dword [rbp - 0x10]
cvtss2sd xmm0, xmm0
movq rax, xmm0
mov rdx, rax
mov qword [rbp - 0x28], rdx
movsd xmm0, qword [rbp - 0x28]
movapd xmm1, xmm0
mov rdx, rax
lea rcx, str.Media_:_.2f_n
call sym.printf
mov ecx, 0xa
call sym.putchar
mov ecx, 0xa
call sym.putchar
lea rcx, str.PAUSE
call sym.system
mov eax, 0
add rsp, 0x50
pop rbp
ret
Function at 0x401810
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call

Disassembly:
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x58
movsxd rbp, dword [0x00407054]
mov rbx, rcx
mov rsi, rdx
mov rdi, r8
test ebp, ebp
jle 0x40192a
mov rax, qword [0x00407058]
xor r9d, r9d
add rax, 8
mov r10, qword [rax]
cmp rbx, r10
jb 0x40185e
mov rdx, qword [rax + 8]
mov r11d, dword [rdx + 8]
add r10, r11
cmp rbx, r10
jb 0x401910
add r9d, 1
add rax, 0x18
cmp r9d, ebp
jne 0x401842
mov rcx, rbx
call dbg.__mingw_GetSectionForAddress
test rax, rax
mov r12, rax
je 0x401962
lea rbp, [rbp + rbp*2]
shl rbp, 3
mov r13, rbp
add r13, qword [0x00407058]
mov qword [r13 + 0x10], rax
mov dword [r13], 0
call dbg._GetPEImageBase
mov edx, dword [r12 + 0xc]
mov r8d, 0x30
add rax, rdx
lea rdx, [rsp + 0x20]
mov qword [r13 + 8], rax
mov rax, qword [0x00407058]
mov rcx, qword [rax + rbp + 8]
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x401945
mov eax, dword [rsp + 0x44]
lea edx, [rax - 4]
and edx, 0xfffffffb
je 0x401909
sub eax, 0x40
and eax, 0xffffffbf
je 0x401909
mov r9, rbp
add r9, qword [0x00407058]
mov r8d, 0x40
mov rdx, qword [rsp + 0x38]
mov rcx, qword [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
je 0x401931
add dword [0x00407054], 1
mov r8, rdi
mov rdx, rsi
mov rcx, rbx
add rsp, 0x58
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
jmp sym.memcpy
xor ebp, ebp
jmp 0x40186b
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call dbg.__report_error
mov rax, qword [0x00407058]
mov edx, dword [r12 + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbp + 8]
call dbg.__report_error
lea rcx, str.Address__p_has_no_image_section
mov rdx, rbx
call dbg.__report_error
nop
nop word cs:[rax + rax]

Function at 0x402540
Capabilities:
Parse pe header

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

Function at 0x402560
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 0x4025a1
sub ecx, 1
lea rcx, [rcx + rcx*4]
lea r9, [rax + rcx*8 + 0x28]
mov r8d, dword [rax + 0xc]
cmp r8, rdx
mov rcx, r8
ja 0x402598
add ecx, dword [rax + 8]
cmp rdx, rcx
jb 0x4025a3
add rax, 0x28
cmp rax, r9
jne 0x402584
xor eax, eax
repz ret

Function at 0x402650
Capabilities:
Enumerate pe sections

Disassembly:
push rsi
push rbx
sub rsp, 0x28
mov rbx, qword [0x00404320]
cmp word [rbx], 0x5a4d
je 0x402670
xor eax, eax
add rsp, 0x28
pop rbx
pop rsi
ret
mov rsi, rcx
mov rcx, rbx
call sym._ValidateImageBase.part.0
test eax, eax
je 0x402664
sub rsi, rbx
mov rcx, rbx
mov rdx, rsi
add rsp, 0x28
pop rbx
pop rsi
jmp dbg._FindPESection
Function at 0x140001001
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
mov rax, qword [0x14007b610]
mov rcx, qword [0x14007b5c0]
xor edx, edx
mov dword [rax], 1
mov rax, qword [0x14007b620]
cmp word [rcx], 0x5a4d
mov dword [rax], 1
mov rax, qword [0x14007b630]
mov dword [rax], 1
jne 0x140001083
movsxd rax, dword [rcx + 0x3c]
add rax, rcx
cmp dword [rax], 0x4550
jne 0x140001083
mov ecx, dword [rax + 0x18]
cmp cx, 0x10b
je 0x14000105e
cmp cx, 0x20b
je 0x14000106d
jmp 0x140001083
cmp dword [rax + 0x74], 0xe
jbe 0x140001083
cmp dword [rax + 0xe8], 0
jmp 0x14000107d
cmp dword [rax + 0x84], 0xe
jbe 0x140001083
cmp dword [rax + 0xf8], 0
setne dl
movzx edx, dl
mov rax, qword [0x14007b600]
mov dword [0x1400a100c], edx
mov ecx, 2
cmp dword [rax], 0
jne 0x14000109f
mov ecx, 1
call sym.__set_app_type
call sym.__p__fmode
mov rdx, qword [0x14007b6f0]
mov edx, dword [rdx]
mov dword [rax], edx
call sym.__p__commode
mov rdx, qword [0x14007b6d0]
mov edx, dword [rdx]
mov dword [rax], edx
call sym._setargv
mov rax, qword [0x14007aae0]
cmp dword [rax], 1
jne 0x1400010e1
mov rcx, qword [sym._matherr]
call sym.__mingw_setusermatherr
xor eax, eax
add rsp, 0x28
ret
Function at 0x140006bb4
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
mov rax, qword [0x1400a10b8]
xor ebx, ebx
add rax, 0x18
mov r12, rcx
mov ecx, dword [0x1400a10b4]
mov rsi, rdx
mov rdi, r8
cmp ebx, ecx
jge 0x140006c02
mov rdx, qword [rax]
cmp r12, rdx
jb 0x140006bfa
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp r12, rdx
jb 0x140006ce9
inc ebx
add rax, 0x28
jmp 0x140006bda
mov rcx, r12
call sym.__mingw_GetSectionForAddress
mov rbp, rax
test rax, rax
jne 0x140006c21
mov rdx, r12
lea rcx, str.Address__p_has_no_image_section
call sym.__report_error
movsxd rbx, ebx
mov rax, qword [0x1400a10b8]
xor edx, edx
imul rbx, rbx, 0x28
add rax, rbx
mov dword [rax], edx
mov qword [rax + 0x20], rbp
call sym._GetPEImageBase
mov edx, dword [rbp + 0xc]
mov r8d, 0x30
lea rcx, [rax + rdx]
mov rax, qword [0x1400a10b8]
lea rdx, [rsp + 0x20]
mov qword [rax + rbx + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
jne 0x140006c83
mov rax, qword [0x1400a10b8]
mov edx, dword [rbp + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rbx + 0x18]
call sym.__report_error
mov eax, dword [rsp + 0x44]
lea edx, [rax - 4]
and edx, 0xfffffffb
je 0x140006ce3
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x140006ce3
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 [0x1400a10b8]
mov qword [rbx + 8], rcx
mov r9, rbx
mov qword [rbx + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x140006ce3
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call sym.__report_error
inc dword [0x1400a10b4]
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 0x140007110
Capabilities:
Get thread local storage value

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
lea rdi, [0x1400a1120]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x1400a1100]
test rbx, rbx
je 0x14000715c
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 0x140007156
test eax, eax
jne 0x140007156
mov rax, qword [rbx + 8]
mov rcx, rsi
call rax
mov rbx, qword [rbx + 0x10]
jmp 0x14000712e
mov rcx, rdi
add rsp, 0x20
pop rbx
pop rsi
pop rdi
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x140007310
Capabilities:
Parse pe header

Disassembly:
xor eax, eax
cmp word [rcx], 0x5a4d
jne 0x140007333
movsxd rdx, dword [rcx + 0x3c]
add rcx, rdx
cmp dword [rcx], 0x4550
jne 0x140007333
xor eax, eax
cmp word [rcx + 0x18], 0x20b
sete al
ret
Function at 0x140007334
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 0x14000736e
mov r10d, dword [rax + 0xc]
mov rcx, r10
cmp rdx, r10
jb 0x140007365
add ecx, dword [rax + 8]
cmp rdx, rcx
jb 0x140007370
inc r8d
add rax, 0x28
jmp 0x14000734c
xor eax, eax
ret

Function at 0x1400073e1
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r9, qword [0x14007b5c0]
mov r8, rcx
mov rcx, r9
call sym._ValidateImageBase
test eax, eax
je 0x14000740d
mov rdx, r8
mov rcx, r9
sub rdx, r9
add rsp, 0x28
jmp sym._FindPESection
xor eax, eax
add rsp, 0x28
ret
Function at 0x14000db9e
Capabilities:
Generate random numbers via rtlgenrandom

Disassembly:
push rsi
push rbx
sub rsp, 0x28
mov rbx, rcx
lea rcx, str.msvcrt.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov rsi, qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.rand_s
mov rcx, rax
call rsi
test rax, rax
jne 0x14000dbf3
lea rcx, str.advapi32.dll
call qword [sym.imp.KERNEL32.dll_LoadLibraryW]
lea rdx, str.SystemFunction036
mov rcx, rax
call rsi
mov qword [0x1400a1ca0], rax
lea rax, [sym.mingw_rand_s]
mov rcx, rbx
mov qword [sym.init_rand_s], rax
add rsp, 0x28
pop rbx
pop rsi
jmp rax

Function at 0x14000f9d3
Capabilities:
Allocate thread local storage

Disassembly:
sub rsp, 0x28
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [0x140073148], eax
inc eax
jne 0x14000f9ed
call sym.abort
nop
add rsp, 0x28
ret

Function at 0x14000fb61
Capabilities:
Print debug messages

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x90
mov rbx, rcx
test rcx, rcx
je 0x14000fbfd
call sym.pthread_spin_destroy
dec eax
jne 0x14000fbf6
xor eax, eax
lea rdi, [rsp + 0x25]
mov ecx, 0xa
lea rsi, str.Error_cleaning_up_spin_keys_for_thread
rep movsd dword [rdi], dword [rsi]
lea rdi, [rsp + 0x4d]
mov ecx, 0x43
rep stosb byte [rdi], al
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
lea rdx, [rsp + 0x4c]
mov r8d, 0xa
mov ecx, eax
call qword [sym.imp.msvcrt.dll__ultoa]
mov eax, 0x27
lea rcx, [rsp + 0x25]
cmp byte [rcx + rax], 0
je 0x14000fbd5
inc rax
cmp rax, 0x6b
jne 0x14000fbc4
jmp 0x14000fbeb
cmp eax, 0x6a
je 0x14000fbeb
movsxd rdx, eax
inc eax
cdqe
mov byte [rsp + rdx + 0x25], 0xa
mov byte [rsp + rax + 0x25], 0
call qword [sym.imp.KERNEL32.dll_OutputDebugStringA]
call sym.abort
mov qword [rbx], 0xffffffffffffffff
add rsp, 0x90
pop rbx
pop rsi
pop rdi
ret
Function at 0x14000fc9f
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x50
call sym._pthread_once_raw.constprop.0.isra.0
mov ecx, dword [0x140073148]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rsi, rax
test rax, rax
jne 0x14000fdae
call sym.pop_pthread_mem
cmp qword [sym.__dyn_tls_pthread], 0
mov rbx, rax
je 0x14000fdae
test rax, rax
je 0x14000fdae
mov dword [rax + 0x44], 1
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
xor r9d, r9d
xor r8d, r8d
mov edx, 1
xor ecx, ecx
mov dword [rbx + 0x70], eax
call qword [sym.imp.KERNEL32.dll_CreateEventA]
mov qword [rbx + 0x38], 0xffffffffffffffff
lea rcx, [rbx + 0x68]
mov qword [rbx + 0x30], rax
call sym.replace_spin_keys.constprop.0
xor edx, edx
xor ecx, ecx
mov rdi, qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov dword [rbx + 0xb8], edx
mov qword [rbx + 0x28], rcx
call rdi
mov qword [rsp + 0x48], rax
call qword [sym.imp.KERNEL32.dll_GetCurrentThread]
mov rsi, rax
call rdi
xor r8d, r8d
mov dword [rsp + 0x30], 2
mov rdx, rsi
mov dword [rsp + 0x28], r8d
mov rcx, rax
lea r9, [rbx + 0x28]
mov dword [rsp + 0x20], r8d
mov r8, qword [rsp + 0x48]
call qword [sym.imp.KERNEL32.dll_DuplicateHandle]
test eax, eax
jne 0x14000fd74
call sym.abort
mov rcx, qword [rbx + 0x28]
call qword [sym.imp.KERNEL32.dll_GetThreadPriority]
mov ecx, dword [0x140073148]
mov rdx, rbx
mov dword [rbx + 0xc0], eax
xor eax, eax
mov dword [rbx + 0xbc], eax
mov al, byte [rbx + 0x40]
and eax, 0xffffffcf
or eax, 0x10
mov byte [rbx + 0x40], al
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
je 0x14000fd6f
mov rsi, rbx
mov rax, rsi
add rsp, 0x50
pop rbx
pop rsi
pop rdi
ret
Function at 0x1400104e8
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
test edx, edx
jne 0x140010522
test r8, r8
jne 0x14001064d
mov rcx, qword [0x1400a1d00]
test rcx, rcx
je 0x14001064d
call qword [sym.imp.KERNEL32.dll_RemoveVectoredExceptionHandler]
xor r9d, r9d
mov qword [0x1400a1d00], r9
jmp 0x14001064d
cmp edx, 1
jne 0x140010545
lea rdx, [sym.SetThreadName_VEH]
mov ecx, 1
call qword [sym.imp.KERNEL32.dll_AddVectoredExceptionHandler]
mov qword [0x1400a1d00], rax
jmp 0x14001064d
cmp edx, 3
jne 0x14001064d
mov ecx, dword [0x140073148]
cmp ecx, 0xffffffff
je 0x14001064d
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rbx, rax
test rax, rax
je 0x14001064d
test byte [rax + 0x40], 0x30
lea rdi, [rax + 0x38]
lea rsi, [rax + 0x68]
je 0x1400105db
mov rcx, qword [rax + 0x1d8]
call sym._pthread_cleanup_dest
mov rcx, qword [rbx + 0x28]
test rcx, rcx
je 0x1400105b3
mov rbp, qword [sym.imp.KERNEL32.dll_CloseHandle]
call rbp
mov rcx, qword [rbx + 0x30]
test rcx, rcx
je 0x1400105a6
call rbp
xor r8d, r8d
mov qword [rbx + 0x30], r8
xor ecx, ecx
mov qword [rbx + 0x28], rcx
mov rcx, rdi
call sym.pthread_mutex_destroy
mov rcx, rsi
call sym.replace_spin_keys.constprop.0
mov rcx, rbx
call sym.push_pthread_mem
mov ecx, dword [0x140073148]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
jmp 0x14001064d
cmp dword [rax + 0xbc], 0
mov rcx, qword [rax + 0x30]
jne 0x14001062c
test rcx, rcx
je 0x1400105f3
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor edx, edx
mov rcx, qword [rbx + 0x1d8]
mov dword [rbx + 0xbc], 1
mov qword [rbx + 0x30], rdx
call sym._pthread_cleanup_dest
test byte [rbx + 0x44], 4
je 0x14001063d
mov rcx, qword [rbx + 0x28]
mov dword [rbx], 0xdeadbeef
test rcx, rcx
je 0x1400105ad
call qword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x1400105ad
test rcx, rcx
je 0x140010637
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
mov qword [rbx + 0x30], rax
mov rcx, rdi
call sym.pthread_mutex_destroy
mov rcx, rsi
call sym.replace_spin_keys.constprop.0
mov eax, 1
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
ret
Function at 0x14001065b
Capabilities:
Set thread local storage value

Disassembly:
push rbp
mov rbp, rsp
push rsi
push rbx
sub rsp, 0x20
mov qword [rbp + 0x10], rcx
call sym._fpreset
lea rcx, [0x140073138]
call sym.pthread_mutex_lock
mov rax, qword [rbp + 0x10]
lea rbx, [rax + 0x38]
mov rcx, rbx
call sym.pthread_mutex_lock
call sym._pthread_once_raw.constprop.0.isra.0
mov rdx, qword [rbp + 0x10]
mov ecx, dword [0x140073148]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov rsi, qword [rbp + 0x10]
mov rcx, rbx
mov dword [rsi + 0x70], eax
call sym.pthread_mutex_unlock
mov rax, qword [rbp + 0x10]
mov rdx, rbp
lea rcx, [rax + 0xd0]
call sym._setjmp
test eax, eax
jne 0x14001073b
lea rcx, [0x140073138]
mov ebx, pe_nt_image_headers64
call sym.pthread_mutex_unlock
mov rax, qword [rbp + 0x10]
mov rax, qword [rax + 0x10]
test rax, rax
je 0x1400106f6
mov rdx, qword [rbp + 0x10]
mov rcx, qword [rdx + 8]
call rax
mov rbx, rax
nop
nop
lea rcx, [0x140073138]
call sym.pthread_mutex_lock
mov rax, qword [rbp + 0x10]
mov qword [rax + 8], rbx
mov rcx, qword [rax + 0x1d8]
call sym._pthread_cleanup_dest
mov rax, qword [rbp + 0x10]
lea rbx, [rax + 0x38]
mov rcx, rbx
call sym.pthread_mutex_lock
mov rax, qword [rbp + 0x10]
mov rcx, qword [rax + 0x30]
mov rsi, qword [rax + 8]
test rcx, rcx
jne 0x140010749
jmp 0x14001074f
lea rcx, [0x140073138]
call sym.pthread_mutex_lock
jmp 0x140010718
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rax, qword [rbp + 0x10]
xor edx, edx
cmp qword [rax + 0x28], 0
mov qword [rax + 0x30], rdx
jne 0x140010793
mov rax, qword [rbp + 0x10]
mov rcx, rbx
mov dword [rax], 0xdeadbeef
call sym.pthread_mutex_unlock
mov rcx, rbx
call sym.pthread_mutex_destroy
mov rcx, qword [rbp + 0x10]
call sym.push_pthread_mem
mov ecx, dword [0x140073148]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
jmp 0x1400107b9
mov rcx, rbx
call sym.pthread_mutex_unlock
mov rcx, rbx
call sym.pthread_mutex_destroy
mov rax, qword [rbp + 0x10]
mov qword [rax + 0x38], 0xffffffffffffffff
mov dword [rax + 0xbc], 1
lea rbx, [0x140073138]
mov rcx, rbx
call sym.pthread_mutex_unlock
test eax, eax
jne 0x1400107d6
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x1400107c0
mov ecx, esi
call qword [sym.imp.msvcrt.dll__endthreadex]
nop
Function at 0x14001092f
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push rsi
push rbx
sub rsp, 0x28
mov rsi, rcx
call sym.__pthread_self_lite
mov qword [rax + 8], rsi
mov rcx, qword [rax + 0x1d8]
mov rbx, rax
call sym._pthread_cleanup_dest
test byte [rbx + 0x40], 0x30
jne 0x140010968
lea rcx, [rbx + 0xd0]
mov edx, 1
call qword [sym.imp.msvcrt.dll_longjmp]
mov ecx, dword [0x140073148]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rbx, rax
test rax, rax
je 0x1400109f3
cmp qword [rax + 0x28], 0
mov rcx, qword [rax + 0x30]
jne 0x1400109a3
mov dword [rax], 0xdeadbeef
test rcx, rcx
je 0x140010998
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor ecx, ecx
mov esi, dword [rbx + 8]
mov qword [rbx + 0x30], rcx
jmp 0x1400109dd
mov dword [rax + 0xbc], 1
mov esi, dword [rax + 8]
test rcx, rcx
je 0x1400109bb
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor edx, edx
mov qword [rbx + 0x30], rdx
test byte [rbx + 0x44], 4
je 0x1400109f3
mov dword [rbx], 0xdeadbeef
mov rcx, qword [rbx + 0x28]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
mov qword [rbx + 0x28], rax
mov rcx, rbx
call sym.push_pthread_mem
mov ecx, dword [0x140073148]
xor edx, edx
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
mov ecx, esi
call qword [sym.imp.msvcrt.dll__endthreadex]
nop