joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1400d56e0
Capabilities:
Authenticate hmac
Encode data using xor

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rdi
push r14
sub rsp, 0x20
mov eax, dword [rcx + 0x18]
mov rbx, rcx
mov ebp, r8d
mov r14, rdx
lea ecx, [rax + rax]
mov eax, dword [rbx + 0x20]
add rax, 0x18
add rcx, rax
call qword [sub.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov rdi, rax
test rax, rax
jne 0x1400d5722
mov rbx, qword [rsp + 0x50]
add rsp, 0x20
pop r14
pop rdi
pop rbp
ret
lea rcx, [rax + 0x18]
mov qword [rax], rbx
mov qword [rax + 8], rcx
mov eax, dword [rbx + 0x18]
add rax, rcx
mov qword [rsp + 0x48], rsi
mov qword [rdi + 0x10], rax
cmp ebp, dword [rbx + 0x1c]
jbe 0x1400d5769
call qword [rbx]
mov rcx, qword [rdi + 8]
mov r8d, ebp
mov rdx, r14
call qword [rbx + reloc.WS2_32.dll_htonl]
mov r14d, dword [rbx + 0x18]
add r14, qword [rdi + 0x10]
mov rdx, qword [rdi + 8]
mov rcx, r14
call qword [rbx + reloc.WS2_32.dll_recv]
mov rcx, qword [rdi + 8]
mov ebp, dword [rbx + 0x20]
call qword [rbx]
mov rcx, qword [rdi + 0x10]
call qword [rbx]
xor esi, esi
test rbp, rbp
je 0x1400d57c2
mov rsi, rbp
nop dword [rax + rax]
movzx eax, byte [r14]
lea rdx, [rsp + 0x40]
xor al, 0x36
mov r8d, 1
mov byte [rsp + 0x40], al
mov rcx, qword [rdi + 8]
call qword [rbx + reloc.WS2_32.dll_htonl]
movzx eax, byte [r14]
lea rdx, [rsp + 0x40]
xor al, 0x5c
lea r14, [r14 + 1]
mov byte [rsp + 0x40], al
mov r8d, 1
mov rcx, qword [rdi + 0x10]
call qword [rbx + reloc.WS2_32.dll_htonl]
sub rbp, 1
jne 0x1400d5780
mov eax, dword [rbx + 0x1c]
cmp rsi, rax
jae 0x1400d5803
nop word [rax + rax]
mov rcx, qword [rdi + 8]
lea rdx, [0x1400e9732]
mov r8d, 1
call qword [rbx + reloc.WS2_32.dll_htonl]
mov rcx, qword [rdi + 0x10]
lea rdx, [0x1400e9733]
mov r8d, 1
call qword [rbx + reloc.WS2_32.dll_htonl]
mov eax, dword [rbx + 0x1c]
inc rsi
cmp rsi, rax
jb 0x1400d57d0
mov rsi, qword [rsp + 0x48]
mov rax, rdi
mov rbx, qword [rsp + 0x50]
add rsp, 0x20
pop r14
pop rdi
pop rbp
ret

Function at 0x1400d581c
Capabilities:
Get geographical location

Disassembly:
mov qword [rsp + 8], rbx
push rdi
sub rsp, 0x40
mov rbx, rdx
lea r8, [rsp + 0x60]
mov edi, ecx
mov edx, 0x20000001
lea rcx, str._x_sys_default_locale
mov r9d, 2
call qword [sym.imp.KERNEL32.dll_GetLocaleInfoEx]
test eax, eax
jne 0x1400d5856
xor r9d, r9d
mov dword [rsp + 0x60], r9d
jmp 0x1400d585b
mov r9d, dword [rsp + 0x60]
and qword [rsp + 0x30], 0
mov r8d, edi
and dword [rsp + 0x28], 0
xor edx, edx
mov ecx, 0x1300
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_FormatMessageA]
mov edx, eax
test eax, eax
je 0x1400d58a4
mov r8, qword [rbx]
dec r8
add r8, rdx
movzx ecx, byte [r8]
lea rax, reloc.WS2_32.dll_accept
cmp byte [rcx + rax], 0
je 0x1400d58a4
dec r8
sub rdx, 1
jne 0x1400d588a
mov rbx, qword [rsp + 0x50]
mov rax, rdx
add rsp, 0x40
pop rdi
ret
Function at 0x1400d6d78
Capabilities:
Parse pe header

Disassembly:
sub rsp, 0x28
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x1400d6dc2
mov ecx, 0x5a4d
cmp word [rax], cx
jne 0x1400d6dc2
movsxd rcx, dword [rax + 0x3c]
add rcx, rax
cmp dword [rcx], 0x4550
jne 0x1400d6dc2
mov eax, 0x20b
cmp word [rcx + 0x18], ax
jne 0x1400d6dc2
cmp dword [rcx + 0x84], 0xe
jbe 0x1400d6dc2
cmp dword [rcx + 0xf8], 0
setne al
jmp 0x1400d6dc4
xor al, al
add rsp, 0x28
ret
Function at 0x1400060ca
Capabilities:
Encode data using xor

Disassembly:
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x2b0
mov rbx, rcx
mov rdi, rdx
mov qword [rcx], 0
mov qword [rcx + 8], 0
mov qword [rcx + 0x10], 0
mov ecx, 0x410
call fcn.1400bb9b0
mov rsi, rax
mov word [rsp + 0x2a0], 0x11
mov word [rsp + 0x2a2], 0x42
mov word [rsp + 0x2a4], 0x45
mov word [rsp + 0x2a6], 0x6b
mov word [rsp + 0x2a8], 0x12
mov word [rsp + 0x2aa], 0x17
mov word [rsp + 0x2ac], 0x10
mov word [rsp + 0x2ae], 0x3b
lea rcx, [rsp + 0x2a0]
mov edx, 0
movsxd rax, edx
imul rax, rax, 0x94f2095
sar rax, 0x21
mov r8d, edx
sar r8d, 0x1f
sub eax, r8d
imul eax, eax, 0x37
mov r8d, edx
sub r8d, eax
lea eax, [r8 + 0x34]
xor word [rcx], ax
add edx, 1
add rcx, 2
cmp edx, 8
jne 0x140006162
mov r9, rdi
lea r8, [rsp + 0x2a0]
mov edx, 0x208
mov rcx, rsi
call sub.msvcrt.dll_swprintf_s
lea rdx, [rsp + 0x50]
mov rcx, rsi
mov rax, qword [0x14016af10]
call qword [rax + 0x180]
mov rsi, rax
cmp rax, 0xffffffffffffffff
je 0x140006319
lea r12, [rsp + 0x40]
lea r13, [rsp + 0x7c]
mov rbp, qword [0x14016af10]
jmp 0x1400062ca
mov qword [rsp + 0x30], r12
mov rcx, r13
call sub.msvcrt.dll_wcslen
lea rdi, [rax + rax]
mov r14, rdi
sar r14, 1
mov qword [rsp + 0x28], r14
cmp rdi, 0xe
ja 0x14000625c
mov rcx, qword [rsp + 0x30]
cmp r14, 1
jne 0x140006282
movzx eax, word [rsp + 0x7c]
mov word [rcx], ax
mov rax, qword [rsp + 0x28]
mov qword [rsp + 0x38], rax
mov rdx, qword [rsp + 0x30]
mov word [rdx + rax*2], 0
mov rcx, qword [rbx + 8]
cmp rcx, qword [rbx + 0x10]
je 0x1400062b4
lea rax, [rcx + 0x10]
mov qword [rcx], rax
mov rdx, qword [rsp + 0x30]
mov r9d, 0
mov rax, qword [rsp + 0x38]
lea r8, [rdx + rax*2]
call fcn.1400aa870
jmp 0x140006294
lea rdx, [rsp + 0x28]
lea rcx, [rsp + 0x30]
mov r8d, 0
call fcn.1400ac660
mov qword [rsp + 0x30], rax
mov rax, qword [rsp + 0x28]
mov qword [rsp + 0x40], rax
jmp 0x140006208
test r14, r14
je 0x14000621b
mov r8, rdi
mov rdx, r13
call sub.msvcrt.dll_memcpy
jmp 0x14000621b
add qword [rbx + 8], 0x20
mov rcx, qword [rsp + 0x30]
cmp rcx, r12
je 0x1400062d5
mov rax, qword [rsp + 0x40]
lea rdx, [rax + rax + 2]
call fcn.1400bb9a0
jmp 0x1400062d5
lea r8, [rsp + 0x30]
mov rdx, rcx
mov rcx, rbx
call fcn.1400a5860
jmp 0x140006299
test eax, eax
je 0x1400062e5
test byte [rsp + 0x50], 0x10
je 0x1400061e6
lea rdx, [rsp + 0x50]
mov rcx, rsi
call qword [rbp + 0x188]
jmp 0x1400062c6
mov rcx, rsi
mov rax, qword [0x14016af10]
call qword [rax + 0x190]
jmp 0x140006319
mov rax, rbx
add rsp, 0x2b0
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
ret
Function at 0x140007636
Capabilities:
Resolve function by parsing pe exports

Disassembly:
movsxd rax, dword [rcx + 0x3c]
mov r10d, dword [rcx + rax + 0x88]
add r10, rcx
mov r9d, dword [r10 + 0x20]
mov r8d, dword [r10 + 0x18]
test r8d, r8d
je 0x1400076b3
mov r8d, r8d
mov edx, 0
add r9, rcx
jmp 0x140007668
add rdx, 1
cmp rdx, r8
je 0x1400076ba
mov eax, dword [r9 + rdx*4]
add rax, rcx
cmp dword [rax], 0x50746547
jne 0x14000765f
cmp dword [rax + 4], 0x41636f72
jne 0x14000765f
cmp dword [rax + 8], 0x65726464
jne 0x14000765f
cmp word [rax + 0xc], 0x7373
jne 0x14000765f
cmp byte [rax + 0xe], 0
jne 0x14000765f
mov eax, dword [r10 + 0x24]
lea rdx, [rcx + rdx*2]
movzx edx, word [rdx + rax]
mov eax, dword [r10 + 0x1c]
lea rdx, [rcx + rdx*4]
mov eax, dword [rdx + rax]
add rax, rcx
jmp 0x1400076bf
mov eax, 0
jmp 0x1400076bf
mov eax, 0
ret
Function at 0x14000c5a0
Capabilities:
Encrypt data using aes
Reference aes constants

Disassembly:
push rdi
push rsi
push rbx
mov r8, rdx
mov rax, rdx
mov rdx, rcx
add r8, 0x10
movzx r9d, byte [rax]
mov byte [rcx], r9b
movzx r9d, byte [rax + 1]
mov byte [rcx + 1], r9b
movzx r9d, byte [rax + 2]
mov byte [rcx + 2], r9b
movzx r9d, byte [rax + 3]
mov byte [rcx + 3], r9b
add rax, 4
add rcx, 4
cmp rax, r8
jne 0x14000c5b0
mov r11d, 4
lea rbx, [0x140165680]
lea rsi, [0x140165560]
jmp 0x14000c620
xor r9b, byte [rax]
mov byte [rax + 0x10], r9b
xor r8b, byte [rax + 1]
mov byte [rax + 0x11], r8b
xor r10b, byte [rax + 2]
mov byte [rax + 0x12], r10b
xor cl, byte [rax + 3]
mov byte [rax + 0x13], cl
add r11d, 1
add rdx, 4
cmp r11d, 0x2c
je 0x14000c672
mov rax, rdx
movzx r9d, byte [rdx + 0xc]
movzx r8d, byte [rdx + 0xd]
movzx r10d, byte [rdx + 0xe]
movzx ecx, byte [rdx + 0xf]
test r11b, 3
jne 0x14000c5f5
movzx r8d, r8b
movzx edi, byte [rbx + r8]
movzx r10d, r10b
movzx r8d, byte [rbx + r10]
movzx ecx, cl
movzx r10d, byte [rbx + rcx]
movzx r9d, r9b
movzx ecx, byte [rbx + r9]
mov r9d, r11d
shr r9d, 2
mov r9d, r9d
xor dil, byte [rsi + r9]
mov r9d, edi
jmp 0x14000c5f5
pop rbx
pop rsi
pop rdi
ret

Function at 0x14000c676
Capabilities:
Encode data using xor

Disassembly:
shl rcx, 4
and ecx, 0xff0
add r8, rcx
lea rcx, [rdx + 4]
lea r10, [rdx + 0x14]
lea rax, [rcx - 4]
mov rdx, r8
movzx r9d, byte [rdx]
xor byte [rax], r9b
add rax, 1
add rdx, 1
cmp rax, rcx
jne 0x14000c692
add r8, 4
add rcx, 4
cmp rcx, r10
jne 0x14000c68b
ret

Function at 0x14000c6b4
Capabilities:
Encrypt data using aes
Reference aes constants

Disassembly:
lea rdx, [rcx + 0x10]
lea r9, [rcx + 0x14]
lea r8, [0x140165680]
lea rax, [rdx - 0x10]
movzx ecx, byte [rax]
movzx ecx, byte [r8 + rcx]
mov byte [rax], cl
add rax, 4
cmp rax, rdx
jne 0x14000c6c7
add rdx, 1
cmp rdx, r9
jne 0x14000c6c3
ret

Function at 0x14000c6f5
Capabilities:
Encrypt data using aes
Reference aes constants

Disassembly:
lea rdx, [rcx + 0x10]
lea r9, [rcx + 0x14]
lea r8, [0x140165580]
lea rax, [rdx - 0x10]
movzx ecx, byte [rax]
movzx ecx, byte [r8 + rcx]
mov byte [rax], cl
add rax, 4
cmp rax, rdx
jne 0x14000c708
add rdx, 1
cmp rdx, r9
jne 0x14000c704
ret
Function at 0x14000c9df
Capabilities:
Encode data using xor

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov r13, rcx
mov qword [rsp + 0x88], rdx
mov r8, rdx
mov rdx, rcx
mov ecx, 0
call fcn.14000c676
mov dword [rsp + 0x2c], 1
lea rax, [r13 + 0x10]
mov qword [rsp + 0x20], rax
jmp 0x14000ca45
mov r8, qword [rsp + 0x88]
mov rdx, r13
mov esi, dword [rsp + 0x2c]
mov ecx, esi
call fcn.14000c676
mov eax, esi
add eax, 1
mov dword [rsp + 0x2c], eax
cmp eax, 0xa
je 0x14000cb39
mov rcx, r13
call fcn.14000c6b4
movzx eax, byte [r13 + 1]
movzx edx, byte [r13 + 5]
mov byte [r13 + 1], dl
movzx edx, byte [r13 + 9]
mov byte [r13 + 5], dl
movzx edx, byte [r13 + 0xd]
mov byte [r13 + 9], dl
mov byte [r13 + 0xd], al
movzx eax, byte [r13 + 2]
movzx edx, byte [r13 + 0xa]
mov byte [r13 + 2], dl
mov byte [r13 + 0xa], al
movzx eax, byte [r13 + 6]
movzx edx, byte [r13 + 0xe]
mov byte [r13 + 6], dl
mov byte [r13 + 0xe], al
movzx eax, byte [r13 + 3]
movzx edx, byte [r13 + 0xf]
mov byte [r13 + 3], dl
movzx edx, byte [r13 + 0xb]
mov byte [r13 + 0xf], dl
movzx edx, byte [r13 + 7]
mov byte [r13 + 0xb], dl
mov byte [r13 + 7], al
mov rbx, r13
movzx edi, byte [rbx]
movzx r12d, byte [rbx + 1]
mov ecx, edi
xor ecx, r12d
movzx ebp, byte [rbx + 2]
movzx esi, byte [rbx + 3]
mov r15d, ebp
xor r15d, esi
mov r14d, ecx
xor r14d, r15d
movzx ecx, cl
call fcn.14000c6e4
xor eax, edi
xor eax, r14d
mov byte [rbx], al
mov ecx, r12d
xor ecx, ebp
movzx ecx, cl
call fcn.14000c6e4
xor r12d, eax
xor r12d, r14d
mov byte [rbx + 1], r12b
movzx ecx, r15b
call fcn.14000c6e4
xor ebp, eax
xor ebp, r14d
mov byte [rbx + 2], bpl
xor edi, esi
movzx ecx, dil
call fcn.14000c6e4
xor esi, eax
xor r14d, esi
mov byte [rbx + 3], r14b
add rbx, 4
cmp rbx, qword [rsp + 0x20]
jne 0x14000cabc
jmp 0x14000ca1d
mov rcx, r13
call fcn.14000c6b4
movzx eax, byte [r13 + 1]
movzx edx, byte [r13 + 5]
mov byte [r13 + 1], dl
movzx edx, byte [r13 + 9]
mov byte [r13 + 5], dl
movzx edx, byte [r13 + 0xd]
mov byte [r13 + 9], dl
mov byte [r13 + 0xd], al
movzx eax, byte [r13 + 2]
movzx edx, byte [r13 + 0xa]
mov byte [r13 + 2], dl
mov byte [r13 + 0xa], al
movzx eax, byte [r13 + 6]
movzx edx, byte [r13 + 0xe]
mov byte [r13 + 6], dl
mov byte [r13 + 0xe], al
movzx eax, byte [r13 + 3]
movzx edx, byte [r13 + 0xf]
mov byte [r13 + 3], dl
movzx edx, byte [r13 + 0xb]
mov byte [r13 + 0xf], dl
movzx edx, byte [r13 + 7]
mov byte [r13 + 0xb], dl
mov byte [r13 + 7], al
mov r8, qword [rsp + 0x88]
mov rdx, r13
mov ecx, 0xa
call fcn.14000c676
nop
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
Function at 0x14000ccd4
Capabilities:
Encode data using xor

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
movups xmmword [rsp + 0x20], xmm6
mov rsi, rcx
mov rbx, rdx
mov ebp, r8d
test rbp, rbp
je 0x14000cd31
mov edi, 0
movdqu xmm6, xmmword [rbx]
mov rdx, rsi
mov rcx, rbx
call fcn.14000c725
mov eax, 0
movzx edx, byte [rsi + rax + 0xb0]
xor byte [rbx + rax], dl
add rax, 1
cmp rax, 0x10
jne 0x14000cd08
movups xmmword [rsi + 0xb0], xmm6
add rbx, 0x10
add rdi, 0x10
cmp rdi, rbp
jb 0x14000ccf4
movups xmm6, xmmword [rsp + 0x20]
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret
Function at 0x140017700
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 fcn.140023880
mov r8d, 0x1b
mov edx, 1
lea rcx, str.Mingw_w64_runtime_failure:_n
mov r9, rax
call sub.msvcrt.dll_fwrite
mov rbx, qword [rsp + 0x28]
mov ecx, 2
call fcn.140023880
mov rdx, r12
mov rcx, rax
mov r8, rbx
call sub.msvcrt.dll_vfprintf
call sub.msvcrt.dll_abort
nop
nop word [rax + rax]
Function at 0x140017770
Capabilities:
Allocate or change rwx memory

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
movsxd rdi, dword [0x140192474]
mov r12, rcx
mov rsi, rdx
mov rbx, r8
test edi, edi
jle 0x140017920
mov rax, qword [0x140192478]
xor ecx, ecx
add rax, 0x18
nop
mov rdx, qword [rax]
cmp r12, rdx
jb 0x1400177bc
mov r8, qword [rax + 8]
mov r8d, dword [r8 + 8]
add rdx, r8
cmp r12, rdx
jb 0x140017847
add ecx, 1
add rax, 0x28
cmp ecx, edi
jne 0x1400177a0
mov rcx, r12
call fcn.140018220
mov rbp, rax
test rax, rax
je 0x14001797d
mov rax, qword [0x140192478]
lea rdi, [rdi + rdi*4]
shl rdi, 3
add rax, rdi
mov qword [rax + 0x20], rbp
mov dword [rax], 0
call fcn.140018350
mov ecx, dword [rbp + 0xc]
lea rdx, [rsp + 0x20]
mov r8d, 0x30
add rcx, rax
mov rax, qword [0x140192478]
mov qword [rax + rdi + 0x18], rcx
call qword [sym.imp.KERNEL32.dll_VirtualQuery]
test rax, rax
je 0x140017962
mov eax, dword [rsp + 0x44]
lea edx, [rax - 0x40]
and edx, 0xffffffbf
je 0x140017840
lea edx, [rax - 4]
and edx, 0xfffffffb
jne 0x1400178d0
add dword [0x140192474], 1
cmp ebx, 8
jae 0x140017878
test bl, 4
jne 0x140017930
test ebx, ebx
je 0x140017869
movzx eax, byte [rsi]
mov byte [r12], al
test bl, 2
jne 0x140017950
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 0x140017869
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 0x1400178aa
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 [0x140192478]
mov qword [rdi + 8], rcx
mov r9, rdi
mov qword [rdi + 0x10], rdx
call qword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x140017840
call qword [sym.imp.KERNEL32.dll_GetLastError]
lea rcx, str.__VirtualProtect_failed_with_code_0x_x
mov edx, eax
call fcn.140017700
xor edi, edi
jmp 0x1400177c7
mov eax, dword [rsi]
mov ebx, ebx
mov dword [r12], eax
mov eax, dword [rsi + rbx - 4]
mov dword [r12 + rbx - 4], eax
jmp 0x140017869
mov ebx, ebx
movzx eax, word [rsi + rbx - 2]
mov word [r12 + rbx - 2], ax
jmp 0x140017869
mov rax, qword [0x140192478]
mov edx, dword [rbp + 8]
lea rcx, str.__VirtualQuery_failed_for__d_bytes_at_address__p
mov r8, qword [rax + rdi + 0x18]
call fcn.140017700
mov rdx, r12
lea rcx, str.Address__p_has_no_image_section
call fcn.140017700
nop
nop dword [rax]
Function at 0x140017e90
Capabilities:
Get thread local storage value

Disassembly:
push r12
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rcx, [0x1401924e0]
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x1401924c0]
test rbx, rbx
je 0x140017ee4
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 0x140017edb
test r12, r12
je 0x140017edb
mov rax, qword [rbx + 8]
mov rcx, r12
call rax
mov rbx, qword [rbx + 0x10]
test rbx, rbx
jne 0x140017ec0
lea rcx, [0x1401924e0]
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop r12
jmp qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]

Function at 0x140018220
Capabilities:
Enumerate pe sections

Disassembly:
sub rsp, 0x28
mov r10, qword [0x14016ad80]
xor r8d, r8d
cmp word [r10], 0x5a4d
mov r9, rcx
jne 0x140018299
mov rcx, r10
call fcn.1400180f0
test eax, eax
je 0x140018299
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 0x140018296
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 0x14001828d
add eax, dword [r8 + 8]
cmp rcx, rax
jb 0x140018299
add r8, 0x28
cmp r8, r9
jne 0x140018278
xor r8d, r8d
mov rax, r8
add rsp, 0x28
ret

Function at 0x140018590
Capabilities:
Allocate thread local storage

Disassembly:
push rdi
push rsi
push rbx
sub rsp, 0x20
mov eax, dword [0x1401924c8]
mov edi, ecx
mov rsi, rdx
test eax, eax
jne 0x140017f20
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
mov edx, 0x18
mov ecx, 1
call sub.msvcrt.dll_calloc
mov rbx, rax
test rax, rax
je 0x140017f73
mov dword [rax], edi
lea rcx, [0x1401924e0]
mov qword [rax + 8], rsi
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rax, qword [0x1401924c0]
lea rcx, [0x1401924e0]
mov qword [0x1401924c0], rbx
mov qword [rbx + 0x10], rax
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor eax, eax
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret
or eax, 0xffffffff
jmp 0x140017f16
push r12
push rbx
sub rsp, 0x28
mov rbx, rcx
mov r12, rdx
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov ecx, eax
cmp eax, 0xffffffff
je 0x1400185c0
mov rdx, r12
mov dword [rbx], eax
add rsp, 0x28
pop rbx
pop r12
jmp 0x140023c80
add rsp, 0x28
pop rbx
pop r12
jmp qword [sym.imp.KERNEL32.dll_GetLastError]
test rdx, rdx
jne 0x140023c90
xor eax, eax
ret
jmp 0x140017f00

Function at 0x140018600
Capabilities:
Get thread local storage value

Disassembly:
push r13
push r12
sub rsp, 0x28
mov r12d, ecx
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, r12d
mov r13d, eax
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, r13d
mov r12, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rax, r12
add rsp, 0x28
pop r12
pop r13
ret

Function at 0x140018640
Capabilities:
Set thread local storage value

Disassembly:
sub rsp, 0x28
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
je 0x140018658
xor eax, eax
add rsp, 0x28
ret
add rsp, 0x28
jmp qword [sym.imp.KERNEL32.dll_GetLastError]
Function at 0x1400807f0
Capabilities:
Read file on windows

Disassembly:
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
mov rbp, qword [sym.imp.msvcrt.dll__errno]
mov rdi, rcx
mov rsi, rdx
mov ebx, r8d
jmp 0x140080817
call rbp
cmp dword [rax], 4
jne 0x140080834
mov rcx, rdi
call fcn.140080610
mov r8d, ebx
mov rdx, rsi
mov ecx, eax
call sub.msvcrt.dll__read
movsxd r12, eax
cmp eax, 0xffffffff
je 0x140080810
mov rax, r12
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
ret

Function at 0x140094ca0
Capabilities:
Read file on windows

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov rax, qword [rcx + 8]
mov rdi, rcx
test rax, rax
je 0x140094cc8
xor ecx, ecx
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
jmp rax
mov rbp, qword [sym.imp.msvcrt.dll__errno]
mov ebx, 4
lea rsi, [rsp + 0x2c]
nop dword [rax]
mov ecx, dword [rdi + 0x10]
mov r8d, ebx
mov rdx, rsi
call sub.msvcrt.dll__read
test eax, eax
jle 0x140094d10
cdqe
add rsi, rax
sub rbx, rax
jne 0x140094ce0
mov eax, dword [rsp + 0x2c]
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret
cmp eax, 0xffffffff
jne 0x140094d1c
call rbp
cmp dword [rax], 4
je 0x140094ce0
lea rcx, str.random_device_could_not_be_read
call fcn.1400bc8f0
nop
nop
nop
nop
nop
nop
nop
nop

Function at 0x1400a1670
Capabilities:
Encode data using xor
Generate random numbers using a mersenne twister

Disassembly:
mov r9, rcx
mov rdx, rcx
lea r11, [rcx + 0x38c]
mov r10d, 0x9908b0df
mov eax, dword [rcx]
and eax, 0x80000000
mov r8d, dword [rcx + 4]
and r8d, 0x7fffffff
or eax, r8d
mov r8d, eax
shr r8d, 1
xor r8d, dword [rcx + 0x634]
and eax, 1
cmovne eax, r10d
xor eax, r8d
mov dword [rcx], eax
add rcx, 4
cmp rcx, r11
jne 0x1400a1683
lea r10, [r9 + 0x630]
mov r8d, 0x9908b0df
mov eax, dword [rdx + 0x38c]
and eax, 0x80000000
mov ecx, dword [rdx + 0x390]
and ecx, 0x7fffffff
or eax, ecx
mov ecx, eax
shr ecx, 1
xor ecx, dword [rdx]
and eax, 1
cmovne eax, r8d
xor eax, ecx
mov dword [rdx + 0x38c], eax
add rdx, 4
cmp rdx, r10
jne 0x1400a16c7
mov eax, dword [r9 + 0x9bc]
and eax, 0x80000000
mov edx, dword [r9]
and edx, 0x7fffffff
or eax, edx
mov edx, eax
shr edx, 1
xor edx, dword [r9 + 0x630]
and eax, 1
mov ecx, 0x9908b0df
cmovne eax, ecx
xor eax, edx
mov dword [r9 + 0x9bc], eax
mov qword [r9 + 0x9c0], 0
ret

Function at 0x1400a1740
Capabilities:
Generate random numbers using a mersenne twister

Disassembly:
push rbx
sub rsp, 0x20
mov rbx, rcx
cmp qword [rcx + 0x9c0], 0x26f
ja 0x1400a1796
mov rax, qword [rbx + 0x9c0]
lea rdx, [rax + 1]
mov qword [rbx + 0x9c0], rdx
mov eax, dword [rbx + rax*4]
mov edx, eax
shr edx, 0xb
xor edx, eax
mov eax, edx
shl eax, 7
and eax, 0x9d2c5680
xor edx, eax
mov eax, edx
shl eax, 0xf
and eax, 0xefc60000
xor eax, edx
mov edx, eax
shr edx, 0x12
xor eax, edx
add rsp, 0x20
pop rbx
ret
call fcn.1400a1670
jmp 0x1400a1755
Function at 0x140666058
Capabilities:
Decompress data using aplib

Disassembly:
call fcn.1406661df
push r10
mov r10, rsp
push r10
mov rsi, qword [r10 + 0x10]
mov rdi, qword [r10 + 0x20]
cld
mov dl, 0x80
mov al, byte [rsi]
inc rsi
mov byte [rdi], al
inc rdi
mov ebx, 2
add dl, dl
jne 0x140666089
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x14066606f
add dl, dl
jne 0x140666096
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1406660f6
xor eax, eax
add dl, dl
jne 0x1406660a5
mov dl, byte [rsi]
inc rsi
adc dl, dl
jae 0x1406661ad
add dl, dl
jne 0x1406660b6
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1406660c3
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1406660d0
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x1406660dd
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
je 0x1406660ea
push rdi
mov eax, eax
sub rdi, rax
mov al, byte [rdi]
pop rdi
mov byte [rdi], al
inc rdi
mov ebx, 2
jmp 0x14066607e
mov eax, 1
add dl, dl
jne 0x140666106
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc eax, eax
add dl, dl
jne 0x140666113
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x1406660fb
sub eax, ebx
mov ebx, 1
jne 0x14066614c
mov ecx, 1
add dl, dl
jne 0x14066612e
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x14066613b
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x140666123
push rsi
mov rsi, rdi
sub rsi, rbp
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14066607e
dec eax
shl eax, 8
mov al, byte [rsi]
inc rsi
mov ebp, eax
mov ecx, 1
add dl, dl
jne 0x140666168
mov dl, byte [rsi]
inc rsi
adc dl, dl
adc ecx, ecx
add dl, dl
jne 0x140666175
mov dl, byte [rsi]
inc rsi
adc dl, dl
jb 0x14066615d
cmp eax, 0x7d00
jae 0x14066619b
cmp eax, 0x500
jb 0x140666196
inc ecx
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14066607e
cmp eax, 0x7f
ja 0x14066619e
add ecx, 2
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
jmp 0x14066607e
mov al, byte [rsi]
inc rsi
xor ecx, ecx
shr al, 1
je 0x1406661d2
adc ecx, 2
mov ebp, eax
push rsi
mov rsi, rdi
sub rsi, rax
rep movsb byte [rdi], byte [rsi]
pop rsi
mov ebx, 1
jmp 0x14066607e
pop r10
sub rdi, qword [r10 + 0x20]
mov eax, edi
pop r10
ret 0x20