joyce8/EMBER2024-capa huggingface dataset:
Function at 0x140091060
Capabilities:
Persist via windows service
Query or enumerate registry value
Set registry value

Disassembly:
push rbp
push rsi
push r12
push r13
push r14
sub rsp, 0x70
mov rax, qword [0x140106010]
xor rax, rsp
mov qword [rsp + 0x58], rax
movzx eax, word [rcx]
xor ebp, ebp
movzx esi, word [rdx]
mov r14, r9
add esi, eax
mov dword [rsp + 0x50], ebp
mov r12, rdx
mov dword [rsp + 0x4c], ebp
mov r13, rcx
mov qword [rsp + 0x40], rbp
lea rax, [rsp + 0x40]
xor r8d, r8d
lea r9d, [rbp + 3]
mov qword [rsp + 0x20], rax
lea rdx, str.SYSTEMCurrentControlSetServicesSophos_Endpoint_Defense
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x140091256
mov rcx, qword [rsp + 0x40]
lea rax, [rsp + 0x4c]
mov qword [rsp + 0x28], rax
lea r9, [rsp + 0x50]
mov qword [rsp + 0xb0], rbx
xor r8d, r8d
mov rdx, r14
mov qword [rsp + 0x20], rbp
mov qword [rsp + 0x68], rdi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov edi, eax
test eax, eax
jne 0x140091122
cmp dword [rsp + 0x50], 7
jne 0x14009111a
mov ebx, dword [rsp + 0x4c]
cmp ebx, 2
jb 0x14009111a
add ebx, 0xfffffffe
mov dword [rsp + 0x4c], ebx
jmp 0x14009112f
mov ebx, ebp
mov dword [rsp + 0x4c], ebx
jmp 0x14009112f
cmp eax, 2
jne 0x14009123c
mov ebx, dword [rsp + 0x4c]
mov dword [rsp + 0x48], ebp
mov dword [rsp + 0x54], ebp
lea ebp, [rsi + 6]
add ebp, ebx
mov qword [rsp + 0x60], r15
mov r15, qword [rsp + 0x40]
mov ecx, ebp
call fcn.1400a3674
mov rsi, rax
test rax, rax
je 0x140091232
test ebx, ebx
je 0x1400911b4
lea rax, [rsp + 0x48]
mov dword [rsp + 0x48], ebp
mov qword [rsp + 0x30], rax
mov r9d, 0x20
lea rax, [rsp + 0x54]
mov qword [rsp + 0x28], rsi
mov r8, r14
mov qword [rsp + 0x20], rax
xor edx, edx
mov rcx, r15
call qword [sym.imp.ADVAPI32.dll_RegGetValueW]
mov edi, eax
test eax, eax
jne 0x140091228
mov eax, dword [rsp + 0x48]
cmp eax, 2
jb 0x1400911aa
add eax, 0xfffffffe
mov dword [rsp + 0x48], eax
jmp 0x1400911b8
xor edi, edi
mov eax, edi
mov dword [rsp + 0x48], eax
jmp 0x1400911ba
mov eax, dword [rsp + 0x48]
xor edi, edi
cmp ebx, eax
jne 0x140091223
movzx r8d, word [r13]
add rbx, rsi
mov rdx, qword [r13 + 8]
mov rcx, rbx
call fcn.140096e20
movzx eax, word [r13]
add rbx, rax
mov word [rbx], di
lea rcx, [rbx + 2]
movzx r8d, word [r12]
mov rdx, qword [r12 + 8]
call fcn.140096e20
movzx eax, word [r12]
xor ecx, ecx
mov dword [rsp + 0x28], ebp
xor r8d, r8d
mov rdx, r14
mov qword [rsp + 0x20], rsi
mov dword [rax + rbx + 2], ecx
lea r9d, [rcx + 7]
mov rcx, r15
call qword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov rcx, rsi
mov edi, eax
call fcn.1400a16a0
jmp 0x140091237
mov edi, 0x18
mov rcx, rsi
call fcn.1400a16a0
jmp 0x140091237
mov edi, 8
mov r15, qword [rsp + 0x60]
mov rcx, qword [rsp + 0x40]
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov rbx, qword [rsp + 0xb0]
mov eax, edi
mov rdi, qword [rsp + 0x68]
mov rcx, qword [rsp + 0x58]
xor rcx, rsp
call fcn.140091ba0
add rsp, 0x70
pop r14
pop r13
pop r12
pop rsi
pop rbp
ret
Function at 0x1400921d0
Capabilities:
Contain obfuscated stackstrings

Disassembly:
push rbp
sub rsp, 0x280
lea rbp, [rsp + 0x80]
mov dword [rbp + 0x1ec], 0x7f47
mov dword [rbp + 0x1e8], 0x17126b
mov dword [rbp + 0x1e4], 0x1308c
mov dword [rbp + 0x1e0], 0x8d04e
mov dword [rbp + 0x1dc], 0x3019d
mov dword [rbp + 0x1d8], 0x433b269
mov dword [rbp + 0x1d4], 0
mov qword [rbp + 0x1c8], 0
mov qword [rbp + 0x1b0], 0
mov qword [rbp + 0x1a8], 0
mov byte [rbp + 0x190], 0x5a
mov byte [rbp + 0x191], 0x57
mov byte [rbp + 0x192], 0x50
mov byte [rbp + 0x193], 0x73
mov byte [rbp + 0x194], 0x44
mov byte [rbp + 0x195], 0x4d
mov byte [rbp + 0x196], 0x46
mov byte [rbp + 0x197], 0x4f
mov byte [rbp + 0x198], 0x72
mov byte [rbp + 0x199], 0x64
mov byte [rbp + 0x19a], 0x2a
mov byte [rbp + 0x19b], 0x52
mov byte [rbp + 0x19c], 0x28
mov byte [rbp + 0x19d], 0x58
mov byte [rbp + 0x19e], 0x6d
mov byte [rbp + 0x19f], 0x4d
mov byte [rbp + 0x1a0], 0
mov qword [rbp + 0x1c0], 0
mov eax, dword [rbp + 0x1dc]
add eax, eax
lea edx, [rax + 0x6b430]
mov eax, dword [rbp + 0x1dc]
add edx, eax
mov eax, dword [rbp + 0x1dc]
add edx, eax
mov eax, dword [rbp + 0x1dc]
add eax, edx
mov dword [rbp + 0x1bc], eax
mov eax, dword [rbp + 0x1dc]
lea edx, [rax + rax]
mov eax, dword [rbp + 0x1dc]
add edx, eax
mov eax, dword [rbp + 0x1dc]
add edx, eax
mov eax, dword [rbp + 0x1dc]
add eax, edx
invalid
invalid

Function at 0x1400921f0
Capabilities:
Contain obfuscated stackstrings

Disassembly:
push rbp
sub rsp, 0x280
lea rbp, [rsp + 0x80]
mov dword [rbp + 0x1ec], 0x7f47
mov dword [rbp + 0x1e8], 0x17126b
mov dword [rbp + 0x1e4], 0x1308c
mov dword [rbp + 0x1e0], 0x8d04e
mov dword [rbp + 0x1dc], 0x3019d
mov dword [rbp + 0x1d8], 0x433b269
mov dword [rbp + 0x1d4], 0
mov qword [rbp + 0x1c8], 0
mov qword [rbp + 0x1b0], 0
mov qword [rbp + 0x1a8], 0
mov byte [rbp + 0x190], 0x5a
mov byte [rbp + 0x191], 0x57
mov byte [rbp + 0x192], 0x50
mov byte [rbp + 0x193], 0x73
mov byte [rbp + 0x194], 0x44
mov byte [rbp + 0x195], 0x4d
mov byte [rbp + 0x196], 0x46
mov byte [rbp + 0x197], 0x4f
mov byte [rbp + 0x198], 0x72
mov byte [rbp + 0x199], 0x64
mov byte [rbp + 0x19a], 0x2a
mov byte [rbp + 0x19b], 0x52
mov byte [rbp + 0x19c], 0x28
mov byte [rbp + 0x19d], 0x58
mov byte [rbp + 0x19e], 0x6d
mov byte [rbp + 0x19f], 0x4d
mov byte [rbp + 0x1a0], 0
mov qword [rbp + 0x1c0], 0
mov eax, dword [rbp + 0x1dc]
add eax, eax
lea edx, [rax + 0x6b430]
mov eax, dword [rbp + 0x1dc]
add edx, eax
mov eax, dword [rbp + 0x1dc]
add edx, eax
mov eax, dword [rbp + 0x1dc]
add eax, edx
mov dword [rbp + 0x1bc], eax
mov eax, dword [rbp + 0x1dc]
lea edx, [rax + rax]
mov eax, dword [rbp + 0x1dc]
add edx, eax
mov eax, dword [rbp + 0x1dc]
add edx, eax
mov eax, dword [rbp + 0x1dc]
add eax, edx
invalid
invalid
Function at 0x140092a31
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push rbp
mov rbp, rsp
sub rsp, 0x60
mov qword [rbp + 0x10], rcx
mov dword [rbp + 0x18], edx
mov rax, qword [rbp + 0x10]
mov qword [rbp - 0x10], rax
mov rax, qword [rbp - 0x10]
mov eax, dword [rax + 0x3c]
movsxd rdx, eax
mov rax, qword [rbp + 0x10]
add rax, rdx
mov qword [rbp - 0x18], rax
mov rax, qword [rbp - 0x18]
mov eax, dword [rax + 0x88]
mov edx, eax
mov rax, qword [rbp + 0x10]
adc byte [rax + 1], cl
ror byte [rax - 0x77], 1
loopne 0x140092abd
mov eax, dword [rbp - 0x20]

Function at 0x140092b40
Capabilities:
Access peb ldr_data

Disassembly:
xor rax, rax
mov rax, qword gs:[0x60]
mov rax, qword [rax + 0x18]
mov rax, qword [rax + 0x20]
mov rax, qword [rax]
mov rax, qword [rax + 0x20]
ret

Function at 0x1400ab8e4
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 8], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
mov eax, 0x1050
call fcn.1400c2e00
sub rsp, rax
mov rax, qword [0x140106010]
xor rax, rsp
mov qword [rsp + 0x1040], rax
mov r15, r8
mov rbp, rdx
mov rbx, rcx
call fcn.1400b4864
xor edi, edi
movsxd r14, eax
cmp dword [rbx + 0x10], edi
jne 0x1400ab933
mov rax, rbp
jmp 0x1400aba3b
mov rax, qword [rbx]
mov rcx, r14
sub rax, qword [rbx + 8]
and ecx, 0x3f
cqo
mov rbx, r14
sub rax, rdx
sar rbx, 6
sar rax, 1
mov r9, r15
lea r12, [rcx + rcx*8]
mov rsi, rax
lea rax, [0x140000000]
xor r8d, r8d
mov rdx, qword [rax + rbx*8 + 0x10c870]
mov ecx, r14d
mov rdx, qword [rdx + r12*8 + 0x30]
call fcn.1400b864c
mov r13, rax
lea rax, [0x140000000]
mov rcx, qword [rax + rbx*8 + 0x10c870]
cmp r13, qword [rcx + r12*8 + 0x30]
jne 0x1400aba37
mov rcx, qword [rcx + r12*8 + 0x28]
lea r9, [rsp + 0x30]
mov r8d, 0x1000
mov qword [rsp + 0x20], rdi
lea rdx, [rsp + 0x40]
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1400aba37
mov r9, r15
xor r8d, r8d
mov rdx, rbp
mov ecx, r14d
call fcn.1400b864c
test rax, rax
js 0x1400aba37
mov eax, dword [rsp + 0x30]
cmp rsi, rax
jg 0x1400aba37
lea rdx, [rsp + 0x40]
add rdx, rax
lea rcx, [rsp + 0x40]
test rsi, rsi
je 0x1400aba29
lea r8, [0x140000000]
cmp rcx, rdx
jae 0x1400aba29
cmp byte [rcx], 0xd
jne 0x1400aba0f
lea rax, [rdx - 1]
cmp rcx, rax
jae 0x1400aba1e
cmp byte [rcx + 1], 0xa
jne 0x1400aba1e
inc rcx
jmp 0x1400aba1e
movzx eax, byte [rcx]
movsx rax, byte [rax + r8 + 0x106460]
add rcx, rax
inc rdi
inc rcx
cmp rdi, rsi
jne 0x1400ab9f1
lea rax, [rsp + 0x40]
sub rcx, rax
lea rax, [rcx + r13]
jmp 0x1400aba3b
or rax, 0xffffffffffffffff
mov rcx, qword [rsp + 0x1040]
xor rcx, rsp
call fcn.140091ba0
mov rbx, qword [rsp + 0x1090]
add rsp, 0x1050
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret

Function at 0x1400aecb8
Capabilities:
Parse pe header

Disassembly:
xor r8d, r8d
xor edx, edx
jmp 0x1400aeaa8
Function at 0x1400b773c
Capabilities:
Read file on windows

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push r14
sub rsp, 0x20
mov rsi, rcx
test rcx, rcx
jne 0x1400b776e
call fcn.1400a5738
mov dword [rax], 0x16
call fcn.14009b168
jmp 0x1400b788d
mov eax, dword [rcx + 0x14]
shr eax, 0xd
test al, 1
je 0x1400b788d
mov eax, dword [rcx + 0x14]
shr eax, 0xc
test al, 1
jne 0x1400b788d
mov eax, dword [rcx + 0x14]
shr eax, 1
test al, 1
je 0x1400b779d
lock or dword [rcx + 0x14], 0x10
jmp 0x1400b788d
lock or dword [rcx + 0x14], 1
mov eax, dword [rcx + 0x14]
test eax, 0x4c0
jne 0x1400b77b1
call fcn.1400b795c
mov rdi, qword [rsi + 8]
mov rcx, rsi
mov ebx, dword [rsi + 0x20]
mov qword [rsi], rdi
call fcn.1400b4864
mov r8d, ebx
mov rdx, rdi
mov ecx, eax
call fcn.1400b7e74
mov dword [rsi + 0x10], eax
lea ecx, [rax + 1]
cmp ecx, 1
jbe 0x1400b787b
mov eax, dword [rsi + 0x14]
or edi, 0xffffffff
test al, 6
jne 0x1400b7846
mov rcx, rsi
call fcn.1400b4864
cmp eax, edi
je 0x1400b7831
mov rcx, rsi
call fcn.1400b4864
cmp eax, 0xfffffffe
je 0x1400b7831
mov rcx, rsi
call fcn.1400b4864
movsxd rbx, eax
lea r14, [0x14010c870]
mov rcx, rsi
sar rbx, 6
call fcn.1400b4864
and eax, 0x3f
lea rcx, [rax + rax*8]
mov rax, qword [r14 + rbx*8]
lea rdx, [rax + rcx*8]
jmp 0x1400b7838
lea rdx, [0x140106410]
mov al, byte [rdx + 0x38]
and al, 0x82
cmp al, 0x82
jne 0x1400b7846
lock or dword [rsi + 0x14], 0x20
cmp dword [rsi + 0x20], 0x200
jne 0x1400b786a
mov eax, dword [rsi + 0x14]
shr eax, 6
test al, 1
je 0x1400b786a
mov eax, dword [rsi + 0x14]
shr eax, 8
test al, 1
jne 0x1400b786a
mov dword [rsi + 0x20], 0x1000
mov rax, qword [rsi]
add dword [rsi + 0x10], edi
movzx edi, byte [rax]
inc rax
mov qword [rsi], rax
jmp 0x1400b7890
neg eax
sbb eax, eax
and eax, 8
add eax, 8
lock or dword [rsi + 0x14], eax
and dword [rsi + 0x10], 0
or edi, 0xffffffff
mov rbx, qword [rsp + 0x30]
mov eax, edi
mov rdi, qword [rsp + 0x40]
mov rsi, qword [rsp + 0x38]
add rsp, 0x20
pop r14
ret
Function at 0x1400b79c8
Capabilities:
Read file on windows

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
sub rsp, 0x30
movsxd rbp, ecx
mov r9, r8
mov rax, rbp
lea rcx, [0x14010c870]
and eax, 0x3f
mov r10, rbp
sar r10, 6
xor edi, edi
mov rsi, rdx
mov r14, rbp
lea r8, [rax + rax*8]
mov rax, qword [rcx + r10*8]
mov ecx, 4
mov qword [rsp + 0x78], rcx
mov r11, qword [rax + r8*8 + 0x28]
lea r12d, [rcx + 6]
test r9, r9
je 0x1400b7a26
cmp word [rdx], r12w
jne 0x1400b7a26
or byte [rax + r8*8 + 0x38], cl
jmp 0x1400b7a2c
and byte [rax + r8*8 + 0x38], 0xfb
lea rdx, [rdx + r9*2]
mov rcx, rsi
mov rbx, rsi
cmp rsi, rdx
jae 0x1400b7b87
mov r9d, 0x1a
lea r13d, [r9 - 0xd]
movzx eax, word [rcx]
cmp ax, r9w
je 0x1400b7b62
lea r9, [rcx + 2]
cmp ax, r13w
je 0x1400b7a65
mov rcx, r9
jmp 0x1400b7a88
cmp r9, rdx
jae 0x1400b7a9f
cmp word [r9], r12w
mov eax, 2
cmove rax, qword [rsp + 0x78]
add rcx, rax
mov eax, r12d
cmp word [r9], r12w
cmovne ax, r13w
mov word [rbx], ax
mov r9d, 0x1a
add rbx, 2
cmp rcx, rdx
jb 0x1400b7a49
jmp 0x1400b7b87
lea r9, [rsp + 0x80]
mov qword [rsp + 0x20], rdi
mov r8d, 2
lea rdx, [rsp + 0x70]
mov rcx, r11
call qword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x1400b7b5c
cmp dword [rsp + 0x80], edi
je 0x1400b7b5c
mov rdx, r14
lea r11, [0x14010c870]
sar rdx, 6
and r14d, 0x3f
mov rax, qword [r11 + rdx*8]
lea r8, [r14 + r14*8]
test byte [rax + r8*8 + 0x38], 0x48
je 0x1400b7b35
movzx eax, word [rsp + 0x70]
cmp ax, r12w
jne 0x1400b7b08
mov word [rbx], r12w
jmp 0x1400b7b83
mov word [rbx], r13w
mov word [rsp + 0x78], ax
mov rax, qword [r11 + rdx*8]
lea rcx, [rax + r8*8]
mov al, byte [rsp + rdi + 0x78]
mov byte [rcx + rdi + 0x3a], al
inc rdi
cmp rdi, 2
jl 0x1400b7b11
mov rax, qword [r11 + rdx*8]
mov byte [rax + r8*8 + 0x3c], r12b
jmp 0x1400b7b83
cmp word [rsp + 0x70], r12w
jne 0x1400b7b42
cmp rbx, rsi
je 0x1400b7b02
mov rdx, 0xfffffffffffffffe
mov ecx, ebp
lea r8d, [rdx + 3]
call fcn.1400b8654
cmp word [rsp + 0x70], r12w
je 0x1400b7b87
mov word [rbx], r13w
jmp 0x1400b7b83
lea r11, [0x14010c870]
mov rcx, qword [r11 + r10*8]
mov al, byte [rcx + r8*8 + 0x38]
test al, 0x40
jne 0x1400b7b7f
or al, 2
mov byte [rcx + r8*8 + 0x38], al
jmp 0x1400b7b87
mov word [rbx], r9w
add rbx, 2
sub rbx, rsi
sar rbx, 1
lea eax, [rbx + rbx]
add rsp, 0x30
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret
Function at 0x1400bccf8
Capabilities:
Query environment variable

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
sub rsp, 0x20
call qword [sym.imp.KERNEL32.dll_GetEnvironmentStringsW]
xor ebp, ebp
mov rbx, rax
test rax, rax
je 0x1400bcd7f
mov rsi, rbx
cmp word [rax], bp
je 0x1400bcd3e
or rax, 0xffffffffffffffff
inc rax
cmp word [rsi + rax*2], bp
jne 0x1400bcd28
lea rsi, [rsi + rax*2]
add rsi, 2
cmp word [rsi], bp
jne 0x1400bcd24
sub rsi, rbx
add rsi, 2
sar rsi, 1
add rsi, rsi
mov rcx, rsi
call fcn.1400b3620
mov rdi, rax
test rax, rax
je 0x1400bcd6c
mov r8, rsi
mov rdx, rbx
mov rcx, rax
call fcn.140096e20
mov rbp, rdi
xor ecx, ecx
call fcn.1400b35e4
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsW]
mov rax, rbp
mov rbx, qword [rsp + 0x30]
mov rbp, qword [rsp + 0x38]
mov rsi, qword [rsp + 0x40]
add rsp, 0x20
pop rdi
ret

Function at 0x1400c2274
Capabilities:
Clear file content

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
push r12
push r14
push r15
sub rsp, 0x20
mov rbx, rdx
mov rsi, r8
xor edx, edx
mov r14d, ecx
lea r8d, [rdx + 1]
call fcn.1400b8654
xor edx, edx
mov ecx, r14d
mov r12, rax
lea r8d, [rdx + 2]
call fcn.1400b8654
mov rbp, rbx
sub rbp, rax
cmp r12, 0xffffffffffffffff
je 0x1400c23c4
cmp rax, 0xffffffffffffffff
je 0x1400c23c4
xor edi, edi
test rbp, rbp
jle 0x1400c236f
lea edx, [rdi + 1]
mov ecx, 0x1000
call fcn.1400b356c
mov rbx, rax
test rax, rax
jne 0x1400c22fc
lea edi, [rax + 0xc]
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], edi
jmp 0x1400c2365
mov edx, 0x8000
mov ecx, r14d
call fcn.1400afa30
mov r15d, eax
mov eax, 0x1000
mov r8d, ebp
cmp rbp, rax
mov r9, rsi
mov rdx, rbx
mov ecx, r14d
cmovge r8d, eax
call fcn.1400b6fe8
cmp eax, 0xffffffff
je 0x1400c2345
cdqe
sub rbp, rax
test rbp, rbp
jg 0x1400c230c
mov edx, r15d
mov ecx, r14d
call fcn.1400afa30
jmp 0x1400c2365
cmp byte [rsi + 0x38], dil
je 0x1400c235c
cmp dword [rsi + 0x34], 5
jne 0x1400c235c
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], 0xd
cmp byte [rsi + 0x30], dil
je 0x1400c2365
mov edi, dword [rsi + 0x2c]
mov rcx, rbx
call fcn.1400b35e4
jmp 0x1400c23d8
jns 0x1400c23d8
xor r8d, r8d
mov rdx, rbx
mov ecx, r14d
call fcn.1400b8654
cmp rax, 0xffffffffffffffff
jne 0x1400c2390
cmp byte [rsi + 0x30], dil
je 0x1400c23d8
mov edi, dword [rsi + 0x2c]
jmp 0x1400c23d8
mov ecx, r14d
call fcn.1400bd66c
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEndOfFile]
test eax, eax
jne 0x1400c23d8
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov byte [rsi + 0x38], 1
mov edi, 0xd
mov dword [rsi + 0x34], eax
mov byte [rsi + 0x30], 1
mov dword [rsi + 0x2c], 0xd
jmp 0x1400c23d8
xor edi, edi
cmp byte [rsi + 0x30], dil
je 0x1400c23d1
mov eax, dword [rsi + 0x2c]
jmp 0x1400c23d6
mov eax, 0x16
mov edi, eax
xor r8d, r8d
mov rdx, r12
mov ecx, r14d
call fcn.1400b8654
mov rbx, qword [rsp + 0x40]
mov eax, edi
mov rdi, qword [rsp + 0x58]
mov rbp, qword [rsp + 0x48]
mov rsi, qword [rsp + 0x50]
add rsp, 0x20
pop r15
pop r14
pop r12
ret
Function at 0x1400227f0
Capabilities:
Get thread local storage value

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x20], r9
push rbx
push rsi
push rdi
sub rsp, 0x20
mov rdi, rcx
mov ecx, dword [0x140312328]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
lea rbx, [rdi + 3]
xor esi, esi
shr rbx, 2
test rax, rax
je 0x140022853
mov rax, qword [rax + 8]
test rax, rax
je 0x140022853
mov rcx, qword [rax]
test rcx, rcx
je 0x140022853
mov qword [rax], rsi
movzx eax, byte [rcx]
cmp rax, rbx
jb 0x14002284e
mov byte [rcx + rdi], al
mov rax, rcx
add rsp, 0x20
pop rdi
pop rsi
pop rbx
ret
call fcn.140219624
lea rcx, [rbx*4 + 1]
call fcn.1402192c8
cmp rbx, 0xff
movzx ecx, bl
cmova ecx, esi
mov byte [rax + rdi], cl
add rsp, 0x20
pop rdi
pop rsi
pop rbx
ret

Function at 0x140022880
Capabilities:
Get thread local storage value

Disassembly:
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x20], r9
push rbx
push rdi
sub rsp, 0x28
mov rbx, rcx
mov rdi, rdx
mov ecx, dword [0x140312328]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
test rax, rax
je 0x1400228ad
mov r8, qword [rax + 8]
jmp 0x1400228b0
xor r8d, r8d
cmp rdi, 0x3fc
ja 0x1400228d4
test r8, r8
je 0x1400228d4
cmp qword [r8], 0
jne 0x1400228d4
movzx eax, byte [rbx + rdi]
mov byte [rbx], al
mov qword [r8], rbx
add rsp, 0x28
pop rdi
pop rbx
ret
mov rcx, rbx
add rsp, 0x28
pop rdi
pop rbx
jmp fcn.140219624

Function at 0x140022ae0
Capabilities:
Terminate thread

Disassembly:
push rbx
sub rsp, 0x30
mov rax, qword [rcx + 0x10]
lea rdx, [rsp + 0x20]
xor r8d, r8d
mov qword [rsp + 0x20], rax
mov rax, qword [rcx + 8]
mov rbx, rcx
mov r9d, 0xffffffff
mov qword [rsp + 0x28], rax
lea ecx, [r8 + 2]
call qword [sym.imp.KERNEL32.dll_WaitForMultipleObjects]
mov rcx, qword [rbx + 0x10]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
lock xadd dword [0x140312278], eax
mov rcx, qword [rbx + 8]
test eax, eax
je 0x140022b3d
xor edx, edx
call qword [sym.imp.KERNEL32.dll_TerminateThread]
add rsp, 0x30
pop rbx
ret
mov rdx, rcx
xor r8d, r8d
lea rcx, [fcn.140015220]
call qword [sym.imp.KERNEL32.dll_QueueUserAPC]
mov rcx, qword [rbx + 8]
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
add rsp, 0x30
pop rbx
ret
Function at 0x140022b70
Capabilities:
Create thread

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
push r14
push r15
sub rsp, 0x40
xor r9d, r9d
mov r14d, r8d
mov rsi, rdx
mov rbp, rcx
xor r8d, r8d
xor ecx, ecx
lea edx, [r9 + 1]
call qword [sym.imp.KERNEL32.dll_CreateEventW]
mov qword [rsi + 8], rax
mov rdi, rax
lea r15, [0x1402b2d00]
test rax, rax
jne 0x140022be2
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r8, qword [rsi]
lea edx, [rdi + 1]
mov rcx, rsi
mov ebx, eax
call qword [r8]
test ebx, ebx
mov dword [rsp + 0x30], ebx
mov qword [rsp + 0x38], r15
setne byte [rsp + 0x34]
test ebx, ebx
jne 0x140022cef
xor r9d, r9d
xor r8d, r8d
xor ecx, ecx
lea edx, [r9 + 1]
call qword [sym.imp.KERNEL32.dll_CreateEventW]
mov qword [rbp + 0x10], rax
mov qword [rsi + 0x10], rax
cmp qword [rbp + 0x10], 0
jne 0x140022c31
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r8, qword [rsi]
mov edx, 1
mov rcx, rsi
mov ebx, eax
call qword [r8]
test ebx, ebx
mov dword [rsp + 0x30], ebx
mov qword [rsp + 0x38], r15
setne byte [rsp + 0x34]
test ebx, ebx
jne 0x140022d01
xor ecx, ecx
lea rax, [rsp + 0x68]
mov qword [rsp + 0x28], rax
lea r8, [0x140022d20]
mov r9, rsi
mov dword [rsp + 0x20], ecx
mov edx, r14d
mov dword [rsp + 0x68], ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__beginthreadex]
mov qword [rbp + 8], rax
test rax, rax
jne 0x140022ca8
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r8, qword [rsi]
mov edx, 1
mov rcx, rsi
mov ebx, eax
call qword [r8]
test rdi, rdi
je 0x140022c85
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rbp + 0x10]
test rcx, rcx
je 0x140022c94
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test ebx, ebx
mov dword [rsp + 0x30], ebx
mov qword [rsp + 0x38], r15
setne byte [rsp + 0x34]
test ebx, ebx
jne 0x140022cdd
test rdi, rdi
je 0x140022cc4
mov edx, 0xffffffff
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rbx, qword [rsp + 0x60]
mov rbp, qword [rsp + 0x70]
mov rsi, qword [rsp + 0x78]
add rsp, 0x40
pop r15
pop r14
pop rdi
ret
lea rdx, str.thread
lea rcx, [rsp + 0x30]
call fcn.1400226b0
int3
lea rdx, str.thread.entry_event
lea rcx, [rsp + 0x30]
call fcn.1400226b0
int3
lea rdx, str.thread.exit_event
lea rcx, [rsp + 0x30]
call fcn.1400226b0
int3
Function at 0x1400233e0
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x50
mov rsi, rdx
mov rdi, rcx
xor ebx, ebx
mov eax, ebx
lock xadd dword [rcx + 0x30], eax
test eax, eax
jne 0x140023440
call fcn.140023550
mov dword [rsp + 0x20], ebx
mov byte [rsp + 0x24], bl
lea rax, [0x1402b2d00]
mov qword [rsp + 0x28], rax
movups xmm0, xmmword [rsp + 0x20]
movups xmmword [rsi], xmm0
xor eax, eax
mov rbx, qword [rsp + 0x60]
mov rsi, qword [rsp + 0x68]
add rsp, 0x50
pop rdi
ret
xorps xmm0, xmm0
movdqu xmmword [rsp + 0x38], xmm0
mov qword [rsp + 0x48], rbx
lea rax, [rcx + 0x28]
test rdi, rdi
cmove rax, rbx
mov qword [rsp + 0x20], rax
lea rax, [rsp + 0x38]
mov qword [rsp + 0x28], rax
mov ecx, dword [0x140312328]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov qword [rsp + 0x30], rax
lea rdx, [rsp + 0x20]
mov ecx, dword [0x140312328]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
nop
mov r8, rsi
mov rcx, rdi
call fcn.140023650
test rax, rax
je 0x1400234bf
nop dword [rax + rax]
lea rax, [rbx + 1]
cmp rbx, 0xffffffffffffffff
cmove rax, rbx
mov rbx, rax
mov r8, rsi
mov rcx, rdi
call fcn.140023650
test rax, rax
jne 0x1400234a0
mov rdx, qword [rsp + 0x30]
mov ecx, dword [0x140312328]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
nop
lea rdi, [rsp + 0x38]
mov esi, 3
nop dword [rax + rax]
mov rcx, qword [rdi]
test rcx, rcx
je 0x1400234ed
call fcn.140219624
add rdi, 8
sub rsi, 1
jne 0x1400234e0
mov rax, rbx
mov rbx, qword [rsp + 0x60]
mov rsi, qword [rsp + 0x68]
add rsp, 0x50
pop rdi
ret
Function at 0x140023dd0
Capabilities:
Set socket configuration

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rsi
push rdi
push r14
push r15
sub rsp, 0x40
xor ebp, ebp
lea r15, [0x1402b2d00]
mov rdi, r9
mov r14, rdx
mov rsi, rcx
mov ebx, ebp
cmp rcx, 0xffffffffffffffff
je 0x140023f0f
test r8b, r8b
je 0x140023e49
movzx eax, byte [rdx]
test al, 8
je 0x140023e49
or al, 8
mov dword [rsp + 0x60], ebp
xor ecx, ecx
mov byte [rdx], al
call qword [sym.imp.WS2_32.dll_WSASetLastError]
lea r9, [rsp + 0x60]
mov dword [rsp + 0x20], 4
mov edx, 0xffff
mov r8d, 0x80
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_setsockopt]
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
xor ecx, ecx
call qword [sym.imp.WS2_32.dll_WSASetLastError]
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_closesocket]
mov ebx, eax
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
test eax, eax
mov dword [rsp + 0x30], eax
mov qword [rsp + 0x38], r15
setne byte [rsp + 0x34]
movups xmm0, xmmword [rsp + 0x30]
movups xmmword [rdi], xmm0
test ebx, ebx
je 0x140023f0f
mov eax, dword [rdi]
cmp eax, 0x2733
jne 0x140023ea4
mov rcx, qword [rdi + 8]
movabs rdx, 0x8fafd21e25c5e09b
cmp qword [rcx + 8], rdx
je 0x140023ebf
jmp 0x140023f25
cmp eax, 0x4d5
jne 0x140023f25
mov rax, qword [rdi + 8]
movabs rdx, 0x8fafd21e25c5e09b
cmp qword [rax + 8], rdx
jne 0x140023f25
lea r8, [rsp + 0x60]
mov dword [rsp + 0x60], ebp
mov edx, 0x8004667e
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_ioctlsocket]
and byte [r14], 0xfc
xor ecx, ecx
call qword [sym.imp.WS2_32.dll_WSASetLastError]
mov rcx, rsi
call qword [sym.imp.WS2_32.dll_closesocket]
mov ebx, eax
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
test eax, eax
mov dword [rsp + 0x30], eax
mov qword [rsp + 0x38], r15
setne byte [rsp + 0x34]
movups xmm0, xmmword [rsp + 0x30]
movups xmmword [rdi], xmm0
test ebx, ebx
jne 0x140023f25
mov dword [rsp + 0x30], ebp
mov byte [rsp + 0x34], bpl
mov qword [rsp + 0x38], r15
movups xmm0, xmmword [rsp + 0x30]
movups xmmword [rdi], xmm0
mov rbp, qword [rsp + 0x70]
mov eax, ebx
mov rbx, qword [rsp + 0x68]
mov rsi, qword [rsp + 0x78]
add rsp, 0x40
pop r15
pop r14
pop rdi
ret