joyce8/EMBER2024-capa huggingface dataset:
Function at 0x1400dd3e0
Capabilities:
Create thread

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push r14
push r15
sub rsp, 0x30
mov r14, rcx
mov qword [rcx], 0
mov ecx, 0x28
mov rbp, r8
mov r15, rdx
call fcn.14009dae0
mov rbx, rax
test rax, rax
jne 0x1400dd422
lea eax, [rbx + 7]
mov rbx, qword [rsp + 0x60]
add rsp, 0x30
pop r15
pop r14
pop rbp
ret
cmp byte [0x140209374], 0
mov qword [rsp + 0x50], rsi
mov qword [rsp + 0x58], rdi
je 0x1400dd487
mov rax, qword [0x140209500]
test rax, rax
je 0x1400dd44c
mov ecx, 0xc8
call rax
test eax, eax
jne 0x1400dd487
lea rsi, [rbx + 8]
mov qword [rbx + 0x10], r15
lea rdi, [rbx + 0x10]
mov qword [rsp + 0x28], rsi
mov r9, rbx
mov dword [rsp + 0x20], 0
lea r8, [0x1400a1440]
mov qword [rbx + 0x18], rbp
xor edx, edx
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__beginthreadex]
mov qword [rbx], rax
test rax, rax
jne 0x1400dd49f
jmp 0x1400dd48f
lea rdi, [rbx + 0x10]
lea rsi, [rbx + 8]
xorps xmm0, xmm0
xor eax, eax
movups xmmword [rbx], xmm0
movups xmmword [rbx + 0x10], xmm0
mov qword [rbx + 0x20], rax
cmp qword [rdi], 0
mov rdi, qword [rsp + 0x58]
jne 0x1400dd4bc
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov rcx, rbp
mov dword [rsi], eax
call r15
mov qword [rbx + 0x20], rax
mov rsi, qword [rsp + 0x50]
xor eax, eax
mov qword [r14], rbx
mov rbx, qword [rsp + 0x60]
add rsp, 0x30
pop r15
pop r14
pop rbp
ret
Function at 0x140113450
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push rbx
push rsi
push rdi
sub rsp, 0x40
mov rsi, qword [rcx + 0xa8]
mov rbx, rcx
mov rax, qword [rcx]
mov rdi, qword [rcx + 0x10]
mov qword [rsp + 0x60], rax
test rsi, rsi
je 0x140113662
mov qword [rsp + 0x70], r12
xor r9d, r9d
mov qword [rsp + 0x78], r13
lea r12, [rdi + 0x88]
mov qword [rsp + 0x38], r14
mov qword [rsp + 0x30], r15
mov qword [rsp + 0x68], rbp
nop word [rax + rax]
movsxd r14, dword [rsi + 0x10]
mov r15d, dword [rsi + 0x14]
shl r14, 5
add r14, qword [rax + 0x20]
movzx eax, byte [rbx + 0x1f]
test al, al
jne 0x1401134c0
inc dword [rbx + 0x38]
mov ebp, dword [rbx + 0x38]
jmp 0x1401134d6
dec al
lea r12, [rdi + 0x88]
movzx eax, al
mov byte [rbx + 0x1f], al
mov ebp, dword [rbx + rax*4 + 0xe8]
movsxd rcx, dword [rdi + 0x90]
lea r8d, [r15 + 2]
lea edx, [rcx + 7]
cmp dword [rdi + 0x94], ecx
jg 0x140113503
mov r9d, edx
mov dword [rsp + 0x20], r15d
mov edx, 0x37
mov rcx, rdi
call fcn.1400caf80
jmp 0x14011352e
lea eax, [rcx + 1]
mov dword [rdi + 0x90], eax
lea rcx, [rcx + rcx*2]
mov rax, qword [r12]
mov dword [rax + rcx*8], 0x37
mov dword [rax + rcx*8 + 4], r8d
mov dword [rax + rcx*8 + 8], edx
mov dword [rax + rcx*8 + 0xc], r15d
mov qword [rax + rcx*8 + 0x10], r9
mov r9, qword [r14 + 0x18]
xor edx, edx
mov r8d, dword [rsi + 0x10]
mov rcx, rbx
mov dword [rsp + 0x20], 0x71
mov r9, qword [r9 + 0x68]
call fcn.140112720
mov eax, dword [rdi + 0x90]
add eax, 5
cmp eax, dword [rdi + 0x94]
jle 0x14011356d
mov rcx, rdi
call fcn.1400cae40
test eax, eax
jne 0x140113649
movsxd rax, dword [rdi + 0x90]
xor r9d, r9d
lea rcx, [rax + rax*2]
mov rax, qword [r12]
mov dword [rax + rcx*8 + 8], 2
mov byte [rax + rcx*8], 0x33
mov dword [rax + rcx*8 + 4], r9d
lea rax, [rax + rcx*8]
mov ecx, dword [rdi + 0x90]
mov dword [rax + 0xc], r9d
add ecx, 2
mov dword [rax + 8], ecx
mov byte [rax + 1], r9b
mov qword [rax + 0x10], r9
mov word [rax + 2], r9w
mov qword [rax + 0x18], 0x7f
mov qword [rax + 0x20], r9
mov qword [rax + 0x28], r9
mov qword [rax + 0x30], 0x61
mov qword [rax + 0x38], 2
mov qword [rax + 0x40], r9
mov qword [rax + 0x48], 0x80
mov qword [rax + 0x50], r9
mov qword [rax + 0x58], r9
mov qword [rax + 0x60], 0x7a
mov qword [rax + 0x68], r9
mov qword [rax + 0x70], r9
add dword [rdi + 0x90], 5
test rax, rax
je 0x140113649
mov dword [rax + 0x3c], ebp
lea edx, [r15 + 1]
mov dword [rax + 4], edx
lea ecx, [r15 - 1]
mov dword [rax + 0x20], edx
mov dword [rax + 0x34], ecx
mov dword [rax + 0x54], edx
mov dword [rax + 0x50], ebp
mov word [rax + 0x4a], 8
test ebp, ebp
je 0x140113637
movzx eax, byte [rbx + 0x1f]
cmp al, 8
jae 0x140113637
mov dword [rbx + rax*4 + 0xe8], ebp
inc byte [rbx + 0x1f]
mov rsi, qword [rsi]
test rsi, rsi
je 0x140113649
mov rax, qword [rsp + 0x60]
jmp 0x1401134a0
mov rbp, qword [rsp + 0x68]
mov r13, qword [rsp + 0x78]
mov r12, qword [rsp + 0x70]
mov r14, qword [rsp + 0x38]
mov r15, qword [rsp + 0x30]
add rsp, 0x40
pop rdi
pop rsi
pop rbx
ret
Function at 0x140173030
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push rbp
sub rsp, 0x30
cmp byte [rcx + 0x18], 0xb
mov rbp, rcx
jne 0x14017306b
mov eax, dword [rcx + 0x1c]
lea rdx, [rcx + 0x38]
mov r9, qword [rcx + 0x28]
dec eax
mov ecx, 0x1e
lea r8, [rax + rax*2]
mov r9, qword [r9 + r8*8 + 0x10]
lea r8, str.__lld_
add rsp, 0x30
pop rbp
jmp fcn.140169c80
mov edx, dword [rcx + 0xc]
lea r8, [rsp + 0x40]
mov qword [rsp + 0x48], rsi
add rcx, 0xc0
xor esi, esi
mov qword [rsp + 0x50], rdi
mov dword [rsp + 0x40], esi
call fcn.14016c550
add eax, dword [rbp + 0xc]
mov r9d, dword [rsp + 0x40]
mov rdi, qword [rsp + 0x50]
mov edx, eax
add rdx, qword [rbp + 0xc0]
test r9d, r9d
je 0x1401730df
movzx eax, byte [rdx]
lea r8, [0x1401c5040]
test byte [rax + r8], 2
je 0x1401730df
test r9d, r9d
je 0x1401730d2
movzx ecx, byte [rsi + rdx]
test byte [rcx + r8], 6
je 0x1401730df
inc esi
cmp esi, r9d
jb 0x1401730c0
lea ecx, [r9 + 2]
lea r8, str.._.s
jmp 0x1401730ea
lea ecx, [r9 + 4]
lea r8, str..__.s_
add rbp, 0x38
mov qword [rsp + 0x20], rdx
mov rdx, rbp
call fcn.140169c80
mov rsi, qword [rsp + 0x48]
add rsp, 0x30
pop rbp
ret

Function at 0x140174ef0
Capabilities:
Write file on windows

Disassembly:
push rbx
push rdi
push r15
sub rsp, 0x20
cmp qword [rcx + 0x68], 0
mov rbx, r8
mov r15, rdx
mov rdi, rcx
je 0x140174f18
add rsp, 0x20
pop r15
pop rdi
pop rbx
jmp qword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::xsputn_char_const____ptr64__long_long___int64_____ptr64]
mov rax, qword [rcx + 0x40]
mov qword [rsp + 0x40], rbp
mov qword [rsp + 0x48], rsi
mov rsi, rbx
mov qword [rsp + 0x58], r14
mov r9, qword [rax]
test r9, r9
je 0x140174f3e
mov rax, qword [rcx + 0x58]
mov ecx, dword [rax]
jmp 0x140174f40
xor ecx, ecx
movsxd rbp, ecx
test rbx, rbx
jle 0x140174f99
test ecx, ecx
jle 0x140174f79
cmp rbx, rbp
mov rcx, r9
cmovl rbp, rbx
mov r8, rbp
call sub.VCRUNTIME140.dll_memcpy
mov rax, qword [rdi + 0x58]
add r15, rbp
sub rbx, rbp
sub dword [rax], ebp
mov rcx, qword [rdi + 0x40]
movsxd rax, ebp
add qword [rcx], rax
test rbx, rbx
jle 0x140174f99
mov r9, qword [rdi + 0x80]
test r9, r9
je 0x140174f99
mov r8, rbx
mov edx, 1
mov rcx, r15
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
sub rbx, rax
mov r14, qword [rsp + 0x58]
sub rsi, rbx
mov rbp, qword [rsp + 0x40]
mov rax, rsi
mov rsi, qword [rsp + 0x48]
add rsp, 0x20
pop r15
pop rdi
pop rbx
ret
Function at 0x140174fc0
Capabilities:
Read file on windows

Disassembly:
push rbp
push rsi
push r14
sub rsp, 0x30
mov rbp, r8
mov r14, rdx
mov rsi, rcx
test r8, r8
jg 0x140174fe2
xor eax, eax
add rsp, 0x30
pop r14
pop rsi
pop rbp
ret
cmp qword [rcx + 0x68], 0
je 0x140174ff8
add rsp, 0x30
pop r14
pop rsi
pop rbp
jmp qword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::xsgetn_char____ptr64__long_long___int64_____ptr64]
mov rax, qword [rcx + 0x38]
mov qword [rsp + 0x28], rbx
mov rbx, rbp
mov rdx, qword [rax]
test rdx, rdx
je 0x140175014
mov rax, qword [rcx + 0x50]
mov ecx, dword [rax]
jmp 0x140175016
xor ecx, ecx
movsxd rax, ecx
test ecx, ecx
je 0x140175052
mov qword [rsp + 0x20], rdi
cmp rax, rbp
mov rdi, rbp
mov rcx, r14
cmovb rdi, rax
mov r8, rdi
call sub.VCRUNTIME140.dll_memcpy
mov rax, qword [rsi + 0x50]
add r14, rdi
sub rbx, rdi
sub dword [rax], edi
mov rcx, qword [rsi + 0x38]
movsxd rax, edi
mov rdi, qword [rsp + 0x20]
add qword [rcx], rax
cmp qword [rsi + 0x80], 0
je 0x1401750ee
mov r8, qword [rsi + 0x18]
lea rax, [rsi + 0x70]
cmp qword [r8], rax
jne 0x14017508d
mov rcx, qword [rsi + 0x88]
mov rdx, qword [rsi + 0x90]
mov qword [r8], rcx
sub edx, ecx
mov rax, qword [rsi + 0x38]
mov qword [rax], rcx
mov rax, qword [rsi + 0x50]
mov dword [rax], edx
cmp rbx, 0xfff
jbe 0x1401750ce
nop word [rax + rax]
mov r9, qword [rsi + 0x80]
mov edx, 1
mov r8d, 0xfff
mov rcx, r14
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
add r14, rax
sub rbx, rax
cmp rax, 0xfff
jne 0x1401750ee
cmp rbx, rax
ja 0x1401750a0
test rbx, rbx
je 0x1401750ee
mov r9, qword [rsi + 0x80]
mov r8, rbx
mov edx, 1
mov rcx, r14
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
sub rbx, rax
sub rbp, rbx
mov rbx, qword [rsp + 0x28]
mov rax, rbp
add rsp, 0x30
pop r14
pop rsi
pop rbp
ret
Function at 0x140175520
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x20], rbx
push rdi
sub rsp, 0x80
mov rax, qword [0x140209000]
xor rax, rsp
mov qword [rsp + 0x78], rax
mov edi, edx
mov rbx, rcx
cmp edx, 0xffffffff
jne 0x14017554d
xor eax, eax
jmp 0x1401756b9
mov rax, qword [rcx + 0x40]
mov rdx, qword [rax]
test rdx, rdx
je 0x140175587
mov rax, qword [rcx + 0x58]
movsxd r8, dword [rax]
lea rcx, [rdx + r8]
cmp rdx, rcx
jae 0x140175587
lea ecx, [r8 - 1]
mov dword [rax], ecx
mov eax, edi
mov rdx, qword [rbx + 0x40]
mov r8, qword [rdx]
lea rcx, [r8 + 1]
mov qword [rdx], rcx
mov byte [r8], dil
jmp 0x1401756b9
cmp qword [rbx + 0x80], 0
mov qword [rsp + 0xa0], rsi
je 0x1401756ac
mov r8, qword [rbx + 0x18]
lea rax, [rbx + 0x70]
cmp qword [r8], rax
jne 0x1401755ca
mov rcx, qword [rbx + 0x88]
mov rdx, qword [rbx + 0x90]
mov qword [r8], rcx
sub edx, ecx
mov rax, qword [rbx + 0x38]
mov qword [rax], rcx
mov rax, qword [rbx + 0x50]
mov dword [rax], edx
mov rcx, qword [rbx + 0x68]
test rcx, rcx
jne 0x1401755f5
mov rdx, qword [rbx + 0x80]
movsx ecx, dil
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fputc]
mov ecx, 0xffffffff
cmp eax, ecx
cmovne ecx, edi
mov eax, ecx
jmp 0x1401756b1
lea rax, [rsp + 0x40]
mov byte [rsp + 0x50], dil
mov qword [rsp + 0x38], rax
lea rdx, [rbx + 0x74]
lea rax, [rsp + 0x78]
mov qword [rsp + 0x30], rax
lea r9, [rsp + 0x51]
lea rax, [rsp + 0x58]
mov qword [rsp + 0x28], rax
lea r8, [rsp + 0x50]
lea rax, [rsp + 0x48]
mov qword [rsp + 0x20], rax
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::codecvt_char__char__struct__Mbstatet_::out_struct__Mbstatet____ptr64__char_const____ptr64__char_const____ptr64__char_const____ptr64____ptr64__char____ptr64__char____ptr64__char____ptr64____ptr64_const___ptr64]
test eax, eax
je 0x140175664
sub eax, 1
je 0x140175664
cmp eax, 2
jne 0x1401756ac
movsx ecx, byte [rsp + 0x50]
mov rdx, qword [rbx + 0x80]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fputc]
mov ecx, 0xffffffff
cmp eax, ecx
cmovne ecx, edi
mov eax, ecx
jmp 0x1401756b1
mov rsi, qword [rsp + 0x40]
lea rax, [rsp + 0x58]
sub rsi, rax
je 0x140175692
mov r9, qword [rbx + 0x80]
lea rcx, [rsp + 0x58]
mov r8, rsi
mov edx, 1
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
cmp rsi, rax
jne 0x1401756ac
lea rax, [rsp + 0x50]
mov byte [rbx + 0x71], 1
cmp qword [rsp + 0x48], rax
mov ecx, 0xffffffff
cmovne ecx, edi
mov eax, ecx
jmp 0x1401756b1
mov eax, 0xffffffff
mov rsi, qword [rsp + 0xa0]
mov rcx, qword [rsp + 0x78]
xor rcx, rsp
call fcn.1401981a0
mov rbx, qword [rsp + 0xa8]
add rsp, 0x80
pop rdi
ret
Function at 0x140175a90
Capabilities:
Write file on windows

Disassembly:
push rbx
sub rsp, 0x60
mov rax, qword [0x140209000]
xor rax, rsp
mov qword [rsp + 0x58], rax
cmp qword [rcx + 0x68], 0
mov rbx, rcx
je 0x140175b63
cmp byte [rcx + 0x71], 0
je 0x140175b63
mov rax, qword [rcx]
mov edx, 0xffffffff
mov qword [rsp + 0x78], rdi
call qword [rax + 0x18]
cmp eax, 0xffffffff
je 0x140175b5f
mov rcx, qword [rbx + 0x68]
lea rax, [rsp + 0x30]
lea rdx, [rbx + 0x74]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x58]
lea r8, [rsp + 0x38]
call qword [sym.imp.MSVCP140.dll_public:_int___cdecl_std::codecvt_char__char__struct__Mbstatet_::unshift_struct__Mbstatet____ptr64__char____ptr64__char____ptr64__char____ptr64____ptr64_const___ptr64]
test eax, eax
je 0x140175b24
sub eax, 1
je 0x140175b28
cmp eax, 2
jne 0x140175b5f
mov byte [rbx + 0x71], 0
mov al, 1
mov rdi, qword [rsp + 0x78]
mov rcx, qword [rsp + 0x58]
xor rcx, rsp
call fcn.1401981a0
add rsp, 0x60
pop rbx
ret
mov byte [rbx + 0x71], 0
mov rdi, qword [rsp + 0x30]
lea rax, [rsp + 0x38]
sub rdi, rax
je 0x140175b56
mov r9, qword [rbx + 0x80]
lea rcx, [rsp + 0x38]
mov r8, rdi
mov edx, 1
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
cmp rdi, rax
jne 0x140175b5f
cmp byte [rbx + 0x71], 0
sete al
jmp 0x140175b0c
xor al, al
jmp 0x140175b0c
mov al, 1
mov rcx, qword [rsp + 0x58]
xor rcx, rsp
call fcn.1401981a0
add rsp, 0x60
pop rbx
ret
Function at 0x14017de30
Capabilities:
Encrypt data using rc4 prga

Disassembly:
push rbx
sub rsp, 0x20
mov rbx, rcx
mov ecx, dword [rcx + 0x10]
mov r10d, ecx
and r10d, 7
je 0x14017de64
cmp ecx, r10d
jge 0x14017de52
mov rcx, rbx
call fcn.14017d640
mov eax, dword [rbx + 0x14]
mov ecx, r10d
shr eax, cl
sub dword [rbx + 0x10], r10d
mov ecx, dword [rbx + 0x10]
mov dword [rbx + 0x14], eax
xor r8d, r8d
mov eax, ecx
test ecx, ecx
jle 0x14017de9e
mov ecx, dword [rbx + 0x14]
lea rdx, [rsp + 0x30]
movzx r9d, cl
nop dword [rax]
shr ecx, 8
inc r8d
mov byte [rdx], r9b
lea rdx, [rdx + 1]
sub eax, 8
mov dword [rbx + 0x14], ecx
movzx r9d, cl
test eax, eax
jg 0x14017de80
mov dword [rbx + 0x10], eax
test eax, eax
jns 0x14017dec6
mov rax, qword gs:[0x58]
mov edx, 0x28
mov rcx, qword [rax]
lea rax, str.zlib_corrupt
mov qword [rdx + rcx], rax
xor eax, eax
add rsp, 0x20
pop rbx
ret
movsxd rcx, r8d
cmp rcx, 4
jge 0x14017def5
mov r8, qword [rbx + 8]
mov rax, qword [rbx]
cmp rax, r8
jb 0x14017dedf
xor dl, dl
jmp 0x14017dee8
movzx edx, byte [rax]
inc rax
mov qword [rbx], rax
mov byte [rsp + rcx + 0x30], dl
inc rcx
cmp rcx, 4
jl 0x14017ded6
movzx eax, byte [rsp + 0x30]
movzx r8d, byte [rsp + 0x31]
movzx ecx, byte [rsp + 0x33]
shl r8d, 8
add r8d, eax
shl ecx, 8
movzx eax, byte [rsp + 0x32]
add ecx, eax
mov eax, r8d
xor eax, 0xffff
cmp ecx, eax
jne 0x14017dea2
mov rcx, qword [rbx]
mov qword [rsp + 0x38], rdi
mov edi, r8d
add rcx, rdi
cmp rcx, qword [rbx + 8]
jbe 0x14017df5f
mov rax, qword gs:[0x58]
mov edx, 0x28
mov rcx, qword [rax]
lea rax, str.read_past_buffer
mov qword [rdx + rcx], rax
mov rdi, qword [rsp + 0x38]
xor eax, eax
add rsp, 0x20
pop rbx
ret
mov rdx, qword [rbx + 0x18]
lea rax, [r8 + rdx]
cmp rax, qword [rbx + 0x28]
jbe 0x14017df79
mov rcx, rbx
call fcn.14017d780
test eax, eax
je 0x14017df52
mov rdx, qword [rbx]
mov r8, rdi
mov rcx, qword [rbx + 0x18]
call sub.VCRUNTIME140.dll_memcpy
add qword [rbx], rdi
mov eax, 1
add qword [rbx + 0x18], rdi
mov rdi, qword [rsp + 0x38]
add rsp, 0x20
pop rbx
ret
Function at 0x140188ad0
Capabilities:
Write file on windows

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push rbp
lea rbp, [rsp - 0x57]
sub rsp, 0xa0
mov rax, qword [0x140209000]
xor rax, rsp
mov qword [rbp + 0x4f], rax
mov rsi, rdx
mov ebx, ecx
xor edi, edi
mov dword [rbp + 0x27], edi
lea r9, [rbp + 0x27]
xor edx, edx
mov r8d, 0x1000
call qword [0x140213a98]
mov dword [rbp + 0x2f], edi
lea r9, [rbp + 0x2f]
xor edx, edx
mov r8d, 0x1001
mov ecx, ebx
call qword [0x140213a98]
xorps xmm0, xmm0
xor eax, eax
movups xmmword [rbp + 0x37], xmm0
mov qword [rbp + 0x47], rax
mov edx, ebx
lea rcx, [rbp + 0x37]
call fcn.1400911c0
nop
mov dword [0x140215c5c], 1
mov rbx, qword [rbp + 0x37]
mov rcx, rsi
cmp qword [rsi + 0x18], 7
jbe 0x140188b61
mov rcx, qword [rsi]
mov rax, qword [rsi + 0x10]
mov qword [rbp - 9], rcx
mov qword [rbp - 1], rax
call fcn.14019793c
movaps xmm0, xmmword [rbp - 9]
movdqa xmmword [rbp - 9], xmm0
lea r8, [rbp - 9]
mov edx, eax
lea rcx, [rbp + 7]
call fcn.14001cb10
lea rsi, [rbp + 7]
cmp qword [rbp + 0x1f], 0xf
cmova rsi, qword [rbp + 7]
lea rax, [rbp - 0x19]
mov qword [rsp + 0x28], rax
mov r9d, dword [rbp + 0x2f]
mov r8d, dword [rbp + 0x27]
mov rcx, rbx
call fcn.1401882e0
mov rbx, rax
test rax, rax
je 0x140188c07
lea r8, [0x1401e860c]
mov rdx, rsi
lea rcx, [rbp + 0x27]
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen_s]
test eax, eax
je 0x140188bd7
mov qword [rbp + 0x27], rdi
jmp 0x140188bdb
mov rdi, qword [rbp + 0x27]
mov rcx, rbx
test rdi, rdi
je 0x140188c01
movsxd r8, dword [rbp - 0x19]
mov r9, rdi
mov edx, 1
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
mov rcx, rdi
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
lea rcx, [rbp + 7]
call fcn.140005310
nop
mov rcx, qword [rbp + 0x37]
test rcx, rcx
je 0x140188c4e
mov rdx, qword [rbp + 0x47]
sub rdx, rcx
mov rax, rcx
cmp rdx, 0x1000
jb 0x140188c49
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140188c49
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.140198514
mov rcx, qword [rbp + 0x4f]
xor rcx, rsp
call fcn.1401981a0
lea r11, [rsp + 0xa0]
mov rbx, qword [r11 + 0x18]
mov rsi, qword [r11 + 0x20]
mov rdi, qword [r11 + 0x28]
mov rsp, r11
pop rbp
ret

Function at 0x14018f390
Capabilities:
Register raw input devices

Disassembly:
mov rax, rsp
sub rsp, 0x38
and qword [rax - 0x10], 0
lea rcx, [rax - 0x18]
mov edx, 1
mov dword [rax - 0x18], 0x20001
mov dword [rax - 0x14], edx
lea r8d, [rdx + 0xf]
call qword [sym.imp.USER32.dll_RegisterRawInputDevices]
test eax, eax
jne 0x14018f3ce
lea rdx, str.Win32:_Failed_to_remove_raw_input_device
mov ecx, 0x10008
call fcn.140191230
add rsp, 0x38
ret
Function at 0x14018f420
Capabilities:
Register raw input devices

Disassembly:
sub rsp, 0x38
mov rax, qword [rcx + 0x360]
mov edx, 1
and dword [rsp + 0x24], 0
lea rcx, [rsp + 0x20]
mov dword [rsp + 0x20], 0x20001
mov qword [rsp + 0x28], rax
lea r8d, [rdx + 0xf]
call qword [sym.imp.USER32.dll_RegisterRawInputDevices]
test eax, eax
jne 0x14018f466
lea rdx, str.Win32:_Failed_to_register_raw_input_device
mov ecx, 0x10008
call fcn.140191230
add rsp, 0x38
ret

Function at 0x14018f504
Capabilities:
Log keystrokes via polling

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
push rdi
sub rsp, 0x20
mov ecx, 0x10
call qword [sym.imp.USER32.dll_GetKeyState]
movzx ebx, ax
mov ecx, 0x11
shr ebx, 0xf
call qword [sym.imp.USER32.dll_GetKeyState]
mov edi, ebx
mov ecx, 0x12
or edi, 2
test ax, ax
cmovns edi, ebx
call qword [sym.imp.USER32.dll_GetKeyState]
mov esi, edi
mov ecx, 0x5c
or esi, 4
test ax, ax
cmovns esi, edi
call qword [sym.imp.USER32.dll_GetKeyState]
mov ecx, 0x5b
movzx ebx, ax
call qword [sym.imp.USER32.dll_GetKeyState]
mov edi, esi
mov ecx, 0x14
or edi, 8
or bx, ax
cmovns edi, esi
call qword [sym.imp.USER32.dll_GetKeyState]
mov ebx, edi
mov ecx, 0x90
or ebx, 0x10
test al, 1
cmove ebx, edi
call qword [sym.imp.USER32.dll_GetKeyState]
mov rsi, qword [rsp + 0x38]
mov ecx, ebx
or ecx, 0x20
test al, 1
cmove ecx, ebx
mov rbx, qword [rsp + 0x30]
mov eax, ecx
add rsp, 0x20
pop rdi
ret

Function at 0x140190ac8
Capabilities:
Allocate thread local storage

Disassembly:
push rbx
sub rsp, 0x20
mov rbx, rcx
call qword [sym.imp.KERNEL32.dll_TlsAlloc]
mov dword [rbx + 4], eax
cmp eax, 0xffffffff
jne 0x140190af4
lea rdx, str.Win32:_Failed_to_allocate_TLS_index
mov ecx, 0x10008
call fcn.140188fbc
xor eax, eax
jmp 0x140190afb
mov eax, 1
mov dword [rbx], eax
add rsp, 0x20
pop rbx
ret
Function at 0x140191558
Capabilities:
Log keystrokes

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rsi
mov qword [rax + 0x18], rdi
mov qword [rax + 0x20], r12
push rbp
push r14
push r15
lea rbp, [rax - 0xc8]
sub rsp, 0x1b0
mov rax, qword [0x140209000]
xor rax, rsp
mov qword [rbp + 0xa0], rax
xor edx, edx
lea rcx, [rbp - 0x60]
mov r8d, pe_nt_image_headers64
call sub.VCRUNTIME140.dll_memset
xor edx, edx
lea rcx, [0x140210382]
mov r8d, 0x6d1
call sub.VCRUNTIME140.dll_memset
lea rdi, [rsp + 0x40]
mov ebx, 0x20
sub rdi, 0x480
lea r15, [0x140210108]
lea r12, [0x140210422]
movsx esi, word [r15]
cmp esi, 0xffffffff
je 0x1401916fb
cmp ebx, 0x140
jb 0x140191671
cmp ebx, 0x14e
ja 0x140191671
mov dword [rsp + 0x40], 0x60
mov dword [rsp + 0x44], 0x61
mov dword [rsp + 0x48], 0x62
mov dword [rsp + 0x4c], 0x63
mov dword [rsp + 0x50], 0x64
mov dword [rsp + 0x54], 0x65
mov dword [rsp + 0x58], 0x66
mov dword [rsp + 0x5c], 0x67
mov dword [rsp + 0x60], 0x68
mov dword [rsp + 0x64], 0x69
mov dword [rsp + 0x68], 0x6e
mov dword [rsp + 0x6c], 0x6f
mov dword [rsp + 0x70], 0x6a
mov dword [rsp + 0x74], 0x6d
mov dword [rsp + 0x78], 0x6b
mov r14d, dword [rdi]
jmp 0x140191681
mov edx, 1
mov ecx, esi
call qword [sym.imp.USER32.dll_MapVirtualKeyW]
mov r14d, eax
and dword [rsp + 0x28], 0
lea r9, [rbp - 0x80]
lea r8, [rbp - 0x60]
mov dword [rsp + 0x20], 0x10
mov edx, esi
mov ecx, r14d
call qword [sym.imp.USER32.dll_ToUnicode]
cmp eax, 0xffffffff
jne 0x1401916c6
and dword [rsp + 0x28], 0
lea r9, [rbp - 0x80]
lea r8, [rbp - 0x60]
mov dword [rsp + 0x20], 0x10
mov edx, esi
mov ecx, r14d
call qword [sym.imp.USER32.dll_ToUnicode]
cmp eax, 1
jl 0x1401916fb
and qword [rsp + 0x38], 0
lea r8, [rbp - 0x80]
and qword [rsp + 0x30], 0
mov r9d, 1
mov dword [rsp + 0x28], 5
xor edx, edx
mov ecx, 0xfde9
mov qword [rsp + 0x20], r12
call qword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
inc ebx
add r12, 5
add rdi, 4
add r15, 2
cmp ebx, 0x15c
jle 0x1401915d3
mov rcx, qword [rbp + 0xa0]
xor rcx, rsp
call fcn.1401981a0
lea r11, [rsp + 0x1b0]
mov rbx, qword [r11 + 0x20]
mov rsi, qword [r11 + 0x28]
mov rdi, qword [r11 + 0x30]
mov r12, qword [r11 + 0x38]
mov rsp, r11
pop r15
pop r14
pop rbp
ret
Function at 0x140194fa4
Capabilities:
Link many functions at runtime

Disassembly:
push rbx
sub rsp, 0x40
and qword [rsp + 0x30], 0
lea rax, str.libOSMesa.dll
cmp qword [0x14020fc00], 0
lea rcx, str.OSMesa.dll
mov qword [rsp + 0x20], rax
mov qword [rsp + 0x28], rcx
je 0x140194fdc
mov eax, 1
jmp 0x14019511f
xor ebx, ebx
mov rcx, rax
call sub.KERNEL32.dll_LoadLibraryA
mov qword [0x14020fc00], rax
mov rcx, rax
test rax, rax
jne 0x140195002
mov rax, qword [rsp + rbx*8 + 0x28]
inc rbx
test rax, rax
jne 0x140194fde
test rcx, rcx
jne 0x14019501d
lea rdx, str.OSMesa:_Library_not_found
mov ecx, 0x10006
call fcn.140188fbc
jmp 0x14019511d
lea rdx, str.OSMesaCreateContextExt
call sub.KERNEL32.dll_GetProcAddress
mov rcx, qword [0x14020fc00]
lea rdx, str.OSMesaCreateContextAttribs
mov qword [0x14020fc08], rax
call sub.KERNEL32.dll_GetProcAddress
mov rcx, qword [0x14020fc00]
lea rdx, str.OSMesaDestroyContext
mov qword [0x14020fc10], rax
call sub.KERNEL32.dll_GetProcAddress
mov rcx, qword [0x14020fc00]
lea rdx, str.OSMesaMakeCurrent
mov qword [0x14020fc18], rax
call sub.KERNEL32.dll_GetProcAddress
mov rcx, qword [0x14020fc00]
lea rdx, str.OSMesaGetColorBuffer
mov qword [0x14020fc20], rax
call sub.KERNEL32.dll_GetProcAddress
mov rcx, qword [0x14020fc00]
lea rdx, str.OSMesaGetDepthBuffer
mov qword [0x14020fc28], rax
call sub.KERNEL32.dll_GetProcAddress
mov rcx, qword [0x14020fc00]
lea rdx, str.OSMesaGetProcAddress
mov qword [0x14020fc30], rax
call sub.KERNEL32.dll_GetProcAddress
cmp qword [0x14020fc08], 0
mov qword [0x14020fc38], rax
je 0x140195107
cmp qword [0x14020fc18], 0
je 0x140195107
cmp qword [0x14020fc20], 0
je 0x140195107
cmp qword [0x14020fc28], 0
je 0x140195107
cmp qword [0x14020fc30], 0
je 0x140195107
test rax, rax
jne 0x140194fd2
lea rdx, str.OSMesa:_Failed_to_load_required_entry_points
mov ecx, 0x10008
call fcn.140188fbc
call fcn.140195128
xor eax, eax
add rsp, 0x40
pop rbx
ret

Function at 0x14019789c
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 0x1401978d6
xor r9d, r9d
mov dword [rsp + 0x60], r9d
jmp 0x1401978db
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 0x140197924
mov r8, qword [rbx]
dec r8
add r8, rdx
movzx ecx, byte [r8]
lea rax, [0x1401bb030]
cmp byte [rcx + rax], 0
je 0x140197924
dec r8
sub rdx, 1
jne 0x14019790a
mov rbx, qword [rsp + 0x50]
mov rax, rdx
add rsp, 0x40
pop rdi
ret