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

Disassembly:
push rsi
push rdi
sub rsp, 0x28
mov ecx, dword [0x140123018]
test ecx, ecx
je 0x140015930
dec ecx
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 2
jb 0x140015949
mov rdi, rax
cmp qword [rax + 8], 0
je 0x140015949
add rdi, 0x10
jmp 0x140015a53
lea rcx, section..data
call fcn.1400ed5d0
mov ecx, eax
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 2
jae 0x14001591d
mov ecx, dword [0x140123018]
test ecx, ecx
je 0x140015a34
dec ecx
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 1
je 0x140015a51
mov rsi, rax
test rax, rax
jne 0x1400159de
movzx eax, byte [0x1401a4170]
mov rcx, qword [0x1401a4160]
test rcx, rcx
jne 0x14001599b
call sub.KERNEL32.dll_GetProcessHeap
test rax, rax
je 0x140015a77
mov rcx, rax
mov qword [0x1401a4160], rax
mov r8d, 0x18
xor edx, edx
call sub.KERNEL32.dll_HeapAlloc
test rax, rax
je 0x140015a77
mov rsi, rax
lea rax, section..data
mov qword [rsi], rax
mov qword [rsi + 8], 0
mov ecx, dword [0x140123018]
test ecx, ecx
je 0x140015a64
dec ecx
mov rdx, rsi
call sub.KERNEL32.dll_TlsSetValue
mov rax, qword [0x1401a4030]
cmp rax, 3
jne 0x140015a5d
call fcn.140014be0
lea rdi, [rsi + 0x10]
mov rcx, qword [rsi + 0x10]
cmp qword [rsi + 8], 0
mov qword [rsi + 8], 1
mov qword [rsi + 0x10], rax
je 0x140015a53
mov rax, qword [rcx + 0x820]
lea rdx, [rax - 1]
mov qword [rcx + 0x820], rdx
cmp qword [rcx + 0x818], 0
jne 0x140015a53
cmp rax, 1
jne 0x140015a53
call fcn.140014ff0
jmp 0x140015a53
lea rcx, section..data
call fcn.1400ed5d0
mov ecx, eax
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 1
jne 0x140015968
xor edi, edi
mov rax, rdi
add rsp, 0x28
pop rdi
pop rsi
ret
call fcn.140015d20
jmp 0x1400159eb
lea rcx, section..data
call fcn.1400ed5d0
mov ecx, eax
jmp 0x1400159d6
ud2
Function at 0x140022800
Capabilities:
Encode data using xor
Hash data using fnv

Disassembly:
push rsi
push rdi
sub rsp, 0x78
mov rsi, rdx
cmp dword [rcx], 2
jne 0x140022896
movdqu xmm0, xmmword [rcx + 8]
pshufd xmm1, xmm0, 0x44
pxor xmm1, xmmword [0x140124c10]
movdqa xmmword [rsp + 0x30], xmm1
pshufd xmm1, xmm0, 0xee
pxor xmm1, xmmword [0x140124c20]
movdqa xmmword [rsp + 0x40], xmm1
movdqa xmmword [rsp + 0x50], xmm0
pxor xmm0, xmm0
movdqa xmmword [rsp + 0x60], xmm0
mov qword [rsp + 0x70], 0
mov rdi, qword [rsi]
xor eax, eax
test rdi, rdi
setne al
mov qword [rsp + 0x28], rax
lea rcx, [rsp + 0x30]
lea rdx, [rsp + 0x28]
mov r8d, 8
call fcn.140022ad0
test rdi, rdi
je 0x140022925
mov rdx, qword [rsi + 8]
mov r8, qword [rsi + 0x10]
lea rcx, [rsp + 0x30]
jmp 0x14002293e
mov rdx, qword [rsi]
xor ecx, ecx
test rdx, rdx
setne cl
movabs rax, 0xcbf29ce484222325
xor rax, rcx
movabs rcx, 0x1efac7090aef4a21
imul rax, rcx
test rdx, rdx
je 0x140022a36
mov r9, qword [rsi + 0x10]
test r9, r9
je 0x140022ab8
mov rcx, qword [rsi + 8]
movabs rdx, 0x100000001b3
mov r10, r9
and r10, 7
je 0x140022a43
mov r11, rax
mov r8, rcx
nop word cs:[rax + rax]
movzx eax, byte [r8]
inc r8
xor rax, r11
imul rax, rdx
mov r11, rax
dec r10
jne 0x140022900
cmp r9, 8
jae 0x140022a4c
jmp 0x140022ab8
movzx eax, byte [rsi + 8]
mov qword [rsp + 0x28], rax
lea rcx, [rsp + 0x30]
lea rdx, [rsp + 0x28]
mov r8d, 8
call fcn.140022ad0
mov rcx, qword [rsp + 0x40]
mov r9, qword [rsp + 0x60]
shl r9, 0x38
or r9, qword [rsp + 0x68]
mov rax, qword [rsp + 0x48]
mov r8, qword [rsp + 0x30]
add r8, rcx
rol rcx, 0xd
xor rax, r9
xor rcx, r8
rol r8, 0x20
mov rdx, qword [rsp + 0x38]
add rdx, rax
rol rax, 0x10
xor rax, rdx
add r8, rax
rol rax, 0x15
add rdx, rcx
rol rcx, 0x11
xor rax, r8
xor rcx, rdx
rol rdx, 0x20
xor r8, r9
add r8, rcx
rol rcx, 0xd
xor rcx, r8
rol r8, 0x20
xor rdx, 0xff
add rdx, rax
rol rax, 0x10
xor rax, rdx
add r8, rax
rol rax, 0x15
add rdx, rcx
rol rcx, 0x11
xor rcx, rdx
rol rdx, 0x20
xor rax, r8
add r8, rcx
rol rcx, 0xd
xor rcx, r8
rol r8, 0x20
add rdx, rax
rol rax, 0x10
xor rax, rdx
add r8, rax
rol rax, 0x15
add rdx, rcx
rol rcx, 0x11
xor rcx, rdx
rol rdx, 0x20
xor rax, r8
add r8, rcx
rol rcx, 0xd
xor rcx, r8
add rdx, rax
shl rax, 0x10
xor rax, rdx
shr rax, 0x2b
add rdx, rcx
shr rcx, 0x2f
xor rcx, rax
mov rax, rdx
shr rax, 0x20
xor rax, rdx
xor rax, rcx
jmp 0x140022ab8
movzx edx, byte [rsi + 8]
xor rax, rdx
imul rax, rcx
jmp 0x140022ab8
mov r8, rcx
cmp r9, 8
jb 0x140022ab8
add rcx, r9
nop
movzx r9d, byte [r8]
xor r9, rax
imul r9, rdx
movzx eax, byte [r8 + 1]
xor rax, r9
imul rax, rdx
movzx r9d, byte [r8 + 2]
xor r9, rax
imul r9, rdx
movzx eax, byte [r8 + 3]
xor rax, r9
imul rax, rdx
movzx r9d, byte [r8 + 4]
xor r9, rax
imul r9, rdx
movzx eax, byte [r8 + 5]
xor rax, r9
imul rax, rdx
movzx r9d, byte [r8 + 6]
xor r9, rax
imul r9, rdx
movzx eax, byte [r8 + 7]
add r8, 8
xor rax, r9
imul rax, rdx
cmp r8, rcx
jne 0x140022a50
and eax, 0x7fff
add rsp, 0x78
pop rdi
pop rsi
ret
Function at 0x140022ad0
Capabilities:
Encode data using xor

Disassembly:
push rsi
push rdi
push rbx
mov rax, rcx
add qword [rcx + 0x30], r8
mov r11, qword [rcx + 0x40]
test r11, r11
je 0x140022b12
mov r10d, 8
sub r10, r11
cmp r8, r10
mov rdi, r10
cmovb rdi, r8
cmp rdi, 3
jbe 0x140022b1a
mov esi, dword [rdx]
mov r9d, 4
mov rcx, r9
or rcx, 1
cmp rcx, rdi
jb 0x140022b2b
jmp 0x140022b42
xor r10d, r10d
jmp 0x140022bcd
xor esi, esi
xor r9d, r9d
mov rcx, r9
or rcx, 1
cmp rcx, rdi
jae 0x140022b42
movzx ebx, word [rdx + r9]
lea ecx, [r9*8]
shl rbx, cl
or rsi, rbx
or r9, 2
cmp r9, rdi
jae 0x140022b59
movzx edi, byte [rdx + r9]
shl r9d, 3
mov ecx, r9d
shl rdi, cl
or rsi, rdi
lea ecx, [r11*8]
shl rsi, cl
or rsi, qword [rax + 0x38]
mov qword [rax + 0x38], rsi
cmp r10, r8
jbe 0x140022b79
add r11, r8
jmp 0x140022caa
mov r11, qword [rax + 0x18]
mov r9, qword [rax + 0x10]
mov rcx, qword [rax]
add rcx, r9
rol r9, 0xd
xor r11, rsi
xor r9, rcx
rol rcx, 0x20
mov rdi, qword [rax + 8]
add rdi, r11
rol r11, 0x10
xor r11, rdi
add rcx, r11
rol r11, 0x15
xor r11, rcx
add rdi, r9
rol r9, 0x11
mov qword [rax + 0x18], r11
xor r9, rdi
rol rdi, 0x20
mov qword [rax + 0x10], r9
mov qword [rax + 8], rdi
xor rcx, rsi
mov qword [rax], rcx
sub r8, r10
mov r11d, r8d
and r11d, 7
and r8, 0xfffffffffffffff8
cmp r10, r8
jae 0x140022c42
mov rcx, qword [rax]
mov r9, qword [rax + 8]
mov rdi, qword [rax + 0x18]
mov rsi, qword [rax + 0x10]
nop
add rcx, rsi
rol rsi, 0xd
mov rbx, qword [rdx + r10]
xor rsi, rcx
rol rcx, 0x20
xor rdi, rbx
add r9, rdi
rol rdi, 0x10
xor rdi, r9
add rcx, rdi
rol rdi, 0x15
add r9, rsi
rol rsi, 0x11
xor rsi, r9
rol r9, 0x20
xor rdi, rcx
xor rcx, rbx
add r10, 8
cmp r10, r8
jb 0x140022bf0
mov qword [rax + 0x18], rdi
mov qword [rax + 0x10], rsi
mov qword [rax + 8], r9
mov qword [rax], rcx
cmp r11d, 3
jbe 0x140022c60
mov r9d, dword [rdx + r10]
mov r8d, 4
mov rcx, r8
or rcx, 1
cmp rcx, r11
jb 0x140022c72
jmp 0x140022c8c
xor r9d, r9d
xor r8d, r8d
mov rcx, r8
or rcx, 1
cmp rcx, r11
jae 0x140022c8c
lea rcx, [r8 + r10]
movzx esi, word [rdx + rcx]
lea ecx, [r8*8]
shl rsi, cl
or r9, rsi
or r8, 2
cmp r8, r11
jae 0x140022ca6
add r10, r8
movzx edx, byte [rdx + r10]
shl r8d, 3
mov ecx, r8d
shl rdx, cl
or r9, rdx
mov qword [rax + 0x38], r9
mov qword [rax + 0x40], r11
pop rbx
pop rdi
pop rsi
ret
Function at 0x14003f020
Capabilities:
Encode data using xor

Disassembly:
push rsi
push rdi
sub rsp, 0x38
movaps xmmword [rsp + 0x20], xmm6
mov rsi, rcx
mov rax, qword [rcx]
nop word cs:[rax + rax]
mov rcx, rax
xor rcx, 3
lock cmpxchg qword [rsi], rcx
jne 0x14003f040
test al, 1
je 0x14003f1a6
test al, 2
jne 0x14003f1a6
test al, 8
jne 0x14003f084
mov rdi, qword [rsi + 0x20]
xor ecx, ecx
call fcn.140102310
test rax, rax
je 0x14003f09e
movups xmm6, xmmword [rax + 0x20]
mov qword [rax + 0x20], 1
mov qword [rax + 0x28], rdi
jmp 0x14003f0a1
test al, 0x10
je 0x14003f104
mov rax, qword [rsi + 0x60]
test rax, rax
je 0x14003f1a6
mov rcx, qword [rsi + 0x68]
call qword [rax + 0x10]
jmp 0x14003f104
xorps xmm6, xmm6
lea rdi, [rsi + 0x28]
mov rcx, qword [rsi + 0x28]
add rcx, 0xfffffffffffffffe
cmp rcx, 3
mov eax, 1
cmovb rax, rcx
cmp rax, 1
je 0x14003f0e5
test rax, rax
jne 0x14003f0ed
mov r8, qword [rsi + 0x30]
test r8, r8
je 0x14003f0ed
cmp qword [rsi + 0x38], 0
je 0x14003f0ed
mov rcx, qword [0x1401a4160]
xor edx, edx
call sub.KERNEL32.dll_HeapFree
jmp 0x14003f0ed
mov rcx, rdi
call fcn.14003ee20
mov qword [rdi], 4
xor ecx, ecx
call fcn.140102310
test rax, rax
je 0x14003f104
movups xmmword [rax + 0x20], xmm6
mov rax, 0xffffffffffffffc0
lock xadd qword [rsi], rax
cmp rax, 0x3f
jbe 0x14003f1a6
and rax, 0xffffffffffffffc0
cmp rax, 0x40
jne 0x14003f164
mov rcx, qword [rsi + 0x28]
add rcx, 0xfffffffffffffffe
cmp rcx, 3
mov eax, 1
cmovb rax, rcx
cmp rax, 1
je 0x14003f170
test rax, rax
jne 0x14003f179
mov r8, qword [rsi + 0x30]
test r8, r8
je 0x14003f179
cmp qword [rsi + 0x38], 0
je 0x14003f179
mov rcx, qword [0x1401a4160]
xor edx, edx
call sub.KERNEL32.dll_HeapFree
jmp 0x14003f179
movaps xmm6, xmmword [rsp + 0x20]
add rsp, 0x38
pop rdi
pop rsi
ret
lea rcx, [rsi + 0x28]
call fcn.14003ee20
mov rax, qword [rsi + 0x60]
test rax, rax
je 0x14003f189
mov rcx, qword [rsi + 0x68]
call qword [rax + 0x18]
mov r8, qword [rsi - 8]
mov rcx, qword [0x1401a4160]
xor edx, edx
movaps xmm6, xmmword [rsp + 0x20]
add rsp, 0x38
pop rdi
pop rsi
jmp sub.KERNEL32.dll_HeapFree
ud2
Function at 0x14003fad0
Capabilities:
Check for time delay via queryperformancecounter

Disassembly:
push r14
push rsi
push rdi
push rbx
sub rsp, 0x28
test rcx, rcx
je 0x14003fb7f
mov rbx, rdx
mov rdi, rcx
lea rsi, [rcx + 0x10]
mov rcx, rsi
call sub.KERNEL32.dll_AcquireSRWLockExclusive
movzx eax, byte [rdi + 0x18]
test al, al
jne 0x14003fd16
cmp dword [rdi + 0x58], 0x3b9aca00
je 0x14003fbe4
mov qword [rsp + 0x20], 0
lea rcx, [rsp + 0x20]
call sub.KERNEL32.dll_QueryPerformanceCounter
test eax, eax
je 0x14003fd11
mov r14, qword [rsp + 0x20]
mov rcx, qword [0x1401a4140]
test rcx, rcx
jne 0x14003fb69
mov qword [rsp + 0x20], 0
lea rcx, [rsp + 0x20]
call sub.KERNEL32.dll_QueryPerformanceFrequency
test eax, eax
je 0x14003fd11
mov rcx, qword [rsp + 0x20]
mov qword [0x1401a4140], rcx
test rcx, rcx
je 0x14003fd16
mov rax, r14
or rax, rcx
shr rax, 0x20
je 0x14003fb89
mov rax, r14
xor edx, edx
div rcx
jmp 0x14003fb90
add rsp, 0x28
pop rbx
pop rdi
pop rsi
pop r14
ret
mov eax, r14d
xor edx, edx
div ecx
imul r8, rax, 0x3b9aca00
imul rax, rdx, 0x3b9aca00
mov rdx, rax
or rdx, rcx
shr rdx, 0x20
je 0x14003fbb4
xor edx, edx
div rcx
mov rcx, rax
jmp 0x14003fbba
xor edx, edx
div ecx
mov ecx, eax
add rcx, r8
mov rax, rcx
shr rax, 9
movabs rdx, 0x44b82fa09b5a53
mul rdx
shr rdx, 0xb
imul eax, edx, 0x3b9aca00
sub ecx, eax
mov qword [rdi + 0x50], rdx
mov dword [rdi + 0x58], ecx
cmp dword [rdi + 0x48], 0x3b9aca00
jne 0x14003fc16
lea rcx, [rdi + 0x20]
cmp qword [rcx], 0
je 0x14003fd00
add qword [rdi + 0x28], rbx
cmp dword [rdi + 0x38], 0x3b9aca00
jne 0x14003fd00
call fcn.14003fd20
jmp 0x14003fd00
mov qword [rsp + 0x20], 0
lea rcx, [rsp + 0x20]
call sub.KERNEL32.dll_QueryPerformanceCounter
test eax, eax
je 0x14003fd11
mov r14, qword [rsp + 0x20]
mov rcx, qword [0x1401a4140]
test rcx, rcx
jne 0x14003fc72
mov qword [rsp + 0x20], 0
lea rcx, [rsp + 0x20]
call sub.KERNEL32.dll_QueryPerformanceFrequency
test eax, eax
je 0x14003fd11
mov rcx, qword [rsp + 0x20]
mov qword [0x1401a4140], rcx
test rcx, rcx
je 0x14003fd16
mov rax, r14
or rax, rcx
shr rax, 0x20
je 0x14003fc88
mov rax, r14
xor edx, edx
div rcx
jmp 0x14003fc8f
mov eax, r14d
xor edx, edx
div ecx
imul r8, rax, 0x3b9aca00
imul rax, rdx, 0x3b9aca00
mov rdx, rax
or rdx, rcx
shr rdx, 0x20
je 0x14003fcb3
xor edx, edx
div rcx
mov rcx, rax
jmp 0x14003fcb9
xor edx, edx
div ecx
mov ecx, eax
add rcx, r8
mov rax, rcx
shr rax, 9
movabs rdx, 0x44b82fa09b5a53
mul rdx
shr rdx, 0xb
imul rax, rdx, 0x3b9aca00
sub rcx, rax
cmp rdx, qword [rdi + 0x40]
jb 0x14003fd00
jne 0x14003fceb
cmp dword [rdi + 0x48], ecx
ja 0x14003fd00
mov dword [rdi + 0x48], 0x3b9aca00
lea rcx, [rdi + 0x20]
cmp qword [rcx], 0
jne 0x14003fbfb
mov rcx, rsi
add rsp, 0x28
pop rbx
pop rdi
pop rsi
pop r14
jmp fcn.140118b6c
call sub.KERNEL32.dll_GetLastError
ud2
Function at 0x140048fa0
Capabilities:
Encode data using xor
Hash data using fnv

Disassembly:
push rsi
push rdi
sub rsp, 0x78
mov rsi, r8
cmp rcx, 2
jne 0x140049036
movdqa xmm0, xmmword [rdx]
pshufd xmm1, xmm0, 0x44
pxor xmm1, xmmword [0x1401269a0]
movdqa xmmword [rsp + 0x30], xmm1
pshufd xmm1, xmm0, 0xee
pxor xmm1, xmmword [0x1401269b0]
movdqa xmmword [rsp + 0x40], xmm1
movdqa xmmword [rsp + 0x50], xmm0
pxor xmm0, xmm0
movdqa xmmword [rsp + 0x60], xmm0
mov qword [rsp + 0x70], 0
mov rdi, qword [rsi]
xor eax, eax
test rdi, rdi
setne al
mov qword [rsp + 0x28], rax
lea rcx, [rsp + 0x30]
lea rdx, [rsp + 0x28]
mov r8d, 8
call fcn.140022ad0
test rdi, rdi
je 0x1400490b6
mov rdx, qword [rsi + 8]
mov r8, qword [rsi + 0x10]
lea rcx, [rsp + 0x30]
jmp 0x1400490cf
mov rdx, qword [rsi]
xor ecx, ecx
test rdx, rdx
setne cl
movabs rax, 0xcbf29ce484222325
xor rax, rcx
movabs rcx, 0x1efac7090aef4a21
imul rax, rcx
test rdx, rdx
je 0x1400491c7
mov r9, qword [rsi + 0x10]
test r9, r9
je 0x140049248
mov rcx, qword [rsi + 8]
movabs rdx, 0x100000001b3
mov r8, r9
and r8, 7
je 0x1400491d4
xor r10d, r10d
movzx r11d, byte [rcx + r10]
xor rax, r11
imul rax, rdx
inc r10
cmp r8, r10
jne 0x140049090
add r8, rcx
cmp r9, 8
jae 0x1400491dd
jmp 0x140049248
movzx eax, byte [rsi + 8]
mov qword [rsp + 0x28], rax
lea rcx, [rsp + 0x30]
lea rdx, [rsp + 0x28]
mov r8d, 8
call fcn.140022ad0
mov rcx, qword [rsp + 0x40]
mov r9, qword [rsp + 0x60]
shl r9, 0x38
or r9, qword [rsp + 0x68]
mov rax, qword [rsp + 0x48]
mov r8, qword [rsp + 0x30]
add r8, rcx
rol rcx, 0xd
xor rax, r9
xor rcx, r8
rol r8, 0x20
mov rdx, qword [rsp + 0x38]
add rdx, rax
rol rax, 0x10
xor rax, rdx
add r8, rax
rol rax, 0x15
add rdx, rcx
rol rcx, 0x11
xor rax, r8
xor rcx, rdx
rol rdx, 0x20
xor r8, r9
add r8, rcx
rol rcx, 0xd
xor rcx, r8
rol r8, 0x20
xor rdx, 0xff
add rdx, rax
rol rax, 0x10
xor rax, rdx
add r8, rax
rol rax, 0x15
add rdx, rcx
rol rcx, 0x11
xor rcx, rdx
rol rdx, 0x20
xor rax, r8
add r8, rcx
rol rcx, 0xd
xor rcx, r8
rol r8, 0x20
add rdx, rax
rol rax, 0x10
xor rax, rdx
add r8, rax
rol rax, 0x15
add rdx, rcx
rol rcx, 0x11
xor rcx, rdx
rol rdx, 0x20
xor rax, r8
add r8, rcx
rol rcx, 0xd
xor rcx, r8
add rdx, rax
shl rax, 0x10
xor rax, rdx
shr rax, 0x2b
add rdx, rcx
shr rcx, 0x2f
xor rcx, rax
mov rax, rdx
shr rax, 0x20
xor rax, rdx
xor rax, rcx
jmp 0x140049248
movzx edx, byte [rsi + 8]
xor rax, rdx
imul rax, rcx
jmp 0x140049248
mov r8, rcx
cmp r9, 8
jb 0x140049248
add rcx, r9
movzx r9d, byte [r8]
xor r9, rax
imul r9, rdx
movzx eax, byte [r8 + 1]
xor rax, r9
imul rax, rdx
movzx r9d, byte [r8 + 2]
xor r9, rax
imul r9, rdx
movzx eax, byte [r8 + 3]
xor rax, r9
imul rax, rdx
movzx r9d, byte [r8 + 4]
xor r9, rax
imul r9, rdx
movzx eax, byte [r8 + 5]
xor rax, r9
imul rax, rdx
movzx r9d, byte [r8 + 6]
xor r9, rax
imul r9, rdx
movzx eax, byte [r8 + 7]
add r8, 8
xor rax, r9
imul rax, rdx
cmp r8, rcx
jne 0x1400491e0
and eax, 0x7fff
add rsp, 0x78
pop rdi
pop rsi
ret
Function at 0x14004a930
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push rsi
push rdi
sub rsp, 0xc8
mov rdi, rcx
mov ecx, dword [0x140123170]
test ecx, ecx
je 0x14004ab03
dec ecx
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 2
jb 0x14004a965
mov rsi, rax
cmp qword [rax + 8], 0
jne 0x14004ab38
mov ecx, dword [0x140123170]
test ecx, ecx
je 0x14004ab3e
dec ecx
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 1
je 0x14004ab5b
mov rsi, rax
test rax, rax
jne 0x14004a9fa
movzx eax, byte [0x1401a4170]
mov rcx, qword [0x1401a4160]
test rcx, rcx
jne 0x14004a9b7
call sub.KERNEL32.dll_GetProcessHeap
test rax, rax
je 0x14004ab7d
mov rcx, rax
mov qword [0x1401a4160], rax
mov r8d, 0x60
xor edx, edx
call sub.KERNEL32.dll_HeapAlloc
test rax, rax
je 0x14004ab7d
mov rsi, rax
lea rax, [0x140123158]
mov qword [rsi], rax
mov qword [rsi + 8], 0
mov ecx, dword [0x140123170]
test ecx, ecx
je 0x14004ab6a
dec ecx
mov rdx, rsi
call sub.KERNEL32.dll_TlsSetValue
lea rax, [rsi + 8]
test rdi, rdi
je 0x14004aa1f
lea rdx, [rdi + 8]
cmp qword [rdi], 0
mov qword [rdi], 0
lea rcx, [0x140173cc8]
cmovne rcx, rdx
jmp 0x14004aa26
lea rcx, [0x140173cc8]
movups xmm0, xmmword [rcx + 0x40]
movaps xmmword [rsp + 0x60], xmm0
movups xmm0, xmmword [rcx]
movups xmm1, xmmword [rcx + 0x10]
movups xmm2, xmmword [rcx + 0x20]
movups xmm3, xmmword [rcx + 0x30]
movaps xmmword [rsp + 0x50], xmm3
movaps xmmword [rsp + 0x40], xmm2
movaps xmmword [rsp + 0x30], xmm1
movaps xmmword [rsp + 0x20], xmm0
mov rcx, qword [rax + 0x50]
mov qword [rsp + 0xc0], rcx
movups xmm0, xmmword [rax + 0x40]
movaps xmmword [rsp + 0xb0], xmm0
movups xmm0, xmmword [rax]
movups xmm1, xmmword [rax + 0x10]
movups xmm2, xmmword [rax + 0x20]
movups xmm3, xmmword [rax + 0x30]
movaps xmmword [rsp + 0xa0], xmm3
movaps xmmword [rsp + 0x90], xmm2
movaps xmmword [rsp + 0x80], xmm1
movaps xmmword [rsp + 0x70], xmm0
mov qword [rsi + 8], 1
movaps xmm0, xmmword [rsp + 0x60]
movups xmmword [rsi + 0x50], xmm0
movaps xmm0, xmmword [rsp + 0x20]
movaps xmm1, xmmword [rsp + 0x30]
movaps xmm2, xmmword [rsp + 0x40]
movaps xmm3, xmmword [rsp + 0x50]
movups xmmword [rsi + 0x40], xmm3
movups xmmword [rsi + 0x30], xmm2
movups xmmword [rsi + 0x20], xmm1
movups xmmword [rsi + 0x10], xmm0
cmp qword [rsp + 0x70], 0
je 0x14004ab38
mov rax, qword [rsp + 0x80]
cmp rax, 2
je 0x14004ab38
lea rcx, [rsp + 0x88]
test rax, rax
je 0x14004ab25
mov rax, qword [rsp + 0x88]
lock dec qword [rax]
jne 0x14004ab38
call fcn.140048a20
jmp 0x14004ab38
lea rcx, [0x140123158]
call fcn.1400ed5d0
mov ecx, eax
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 2
jae 0x14004a957
jmp 0x14004a965
mov rax, qword [rsp + 0x88]
lock dec qword [rax]
jne 0x14004ab38
call fcn.140039fc0
add rsi, 0x10
jmp 0x14004ab5d
lea rcx, [0x140123158]
call fcn.1400ed5d0
mov ecx, eax
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 1
jne 0x14004a984
xor esi, esi
mov rax, rsi
add rsp, 0xc8
pop rdi
pop rsi
ret
lea rcx, [0x140123158]
call fcn.1400ed5d0
mov ecx, eax
jmp 0x14004a9f2
ud2
Function at 0x14004f480
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push rsi
push rdi
sub rsp, 0x28
mov rsi, rcx
mov ecx, dword [0x140123138]
test ecx, ecx
je 0x14004f4b0
dec ecx
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 2
jb 0x14004f4c9
cmp qword [rax + 8], 0
je 0x14004f4c9
add rax, 0x10
jmp 0x14004f5a7
lea rcx, [0x140123120]
call fcn.1400ed5d0
mov ecx, eax
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 2
jae 0x14004f4a0
mov ecx, dword [0x140123138]
test ecx, ecx
je 0x14004f588
dec ecx
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 1
je case.0x14004d754.341
mov rdi, rax
test rax, rax
jne 0x14004f55a
movzx eax, byte [0x1401a4170]
mov rcx, qword [0x1401a4160]
test rcx, rcx
jne 0x14004f51b
call sub.KERNEL32.dll_GetProcessHeap
test rax, rax
je 0x14004f5be
mov rcx, rax
mov qword [0x1401a4160], rax
mov r8d, 0x18
xor edx, edx
call sub.KERNEL32.dll_HeapAlloc
test rax, rax
je 0x14004f5be
add byte [rax], al
invalid
mov rdi, rax
lea rax, [0x140123120]
lea eax, [0x140123120]
mov qword [rdi], rax
mov qword [rdi + 8], 0
mov ecx, dword [0x140123138]
or eax, 0x74c98500
pop rsi
dec ecx
mov rdx, rdi
call sub.KERNEL32.dll_TlsSetValue
or al, 0
test rsi, rsi
je case.0x14004d754.334
mov rcx, qword [rsi]
mov qword [rsi], 0
add byte [rax], al
add byte [rax - 0x7b], cl
leave
je 0x14004f576
mov rcx, qword [rsi + 8]
jmp 0x14004f576
xor ecx, ecx
lea rax, [rdi + 0x10]
mov qword [rdi + 8], 1
mov dword [rdi + 8], 1
mov qword [rdi + 0x10], rcx
jmp 0x14004f5a7
lea rcx, [0x140123120]
call fcn.1400ed5d0
mov ecx, eax
call sub.KERNEL32.dll_TlsGetValue
invalid
xchg ebp, eax
or al, 0
cmp rax, 1
add dword [rdi], ecx
test dword [rbx - 1], eax
invalid
invalid
xor eax, eax
add rsp, 0x28
pop rdi
pop rsi
ret
lea rcx, [0x140123120]
call fcn.1400ed5d0
mov ecx, eax
jmp 0x14004f552
ud2
Function at 0x140052530
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push rsi
push rdi
sub rsp, 0x28
mov rsi, rcx
mov ecx, dword [0x140123038]
test ecx, ecx
je 0x140052560
dec ecx
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 2
jb 0x140052579
cmp qword [rax + 8], 0
je 0x140052579
add rax, 0x10
jmp 0x14005269c
lea rcx, [0x140123020]
call fcn.1400ed5d0
mov ecx, eax
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 2
jae 0x140052550
mov ecx, dword [0x140123038]
test ecx, ecx
je 0x14005267d
dec ecx
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 1
je 0x14005269a
mov rdi, rax
test rax, rax
jne 0x14005260e
movzx eax, byte [0x1401a4170]
mov rcx, qword [0x1401a4160]
test rcx, rcx
jne 0x1400525cb
call sub.KERNEL32.dll_GetProcessHeap
test rax, rax
je 0x1400526b6
mov rcx, rax
mov qword [0x1401a4160], rax
mov r8d, 0x28
xor edx, edx
call sub.KERNEL32.dll_HeapAlloc
test rax, rax
je 0x1400526b6
mov rdi, rax
lea rax, [0x140123020]
mov qword [rdi], rax
mov qword [rdi + 8], 0
mov ecx, dword [0x140123038]
test ecx, ecx
je 0x1400526a3
dec ecx
mov rdx, rdi
call sub.KERNEL32.dll_TlsSetValue
test rsi, rsi
je 0x140052646
mov rax, qword [rsi]
mov qword [rsi], 0
cmp rax, 1
jne 0x140052646
mov r9, qword [rsi + 8]
movzx r8d, byte [rsi + 0x10]
movzx edx, byte [rsi + 0x11]
movzx eax, word [rsi + 0x16]
mov word [rsp + 0x24], ax
mov eax, dword [rsi + 0x12]
mov dword [rsp + 0x20], eax
mov rcx, qword [rsi + 0x18]
jmp 0x140052650
xor ecx, ecx
xor edx, edx
xor r8d, r8d
xor r9d, r9d
mov qword [rdi + 8], 1
lea rax, [rdi + 0x10]
mov qword [rdi + 0x10], r9
mov byte [rdi + 0x18], r8b
mov byte [rdi + 0x19], dl
mov edx, dword [rsp + 0x20]
mov dword [rdi + 0x1a], edx
movzx edx, word [rsp + 0x24]
mov word [rdi + 0x1e], dx
mov qword [rdi + 0x20], rcx
jmp 0x14005269c
lea rcx, [0x140123020]
call fcn.1400ed5d0
mov ecx, eax
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 1
jne 0x140052598
xor eax, eax
add rsp, 0x28
pop rdi
pop rsi
ret
lea rcx, [0x140123020]
call fcn.1400ed5d0
mov ecx, eax
jmp 0x140052606
ud2