Function at 0x140040f40
Capabilities:
Create thread
Encode data using xor
Generate random numbers using a mersenne twister
Log keystrokes via polling
Terminate process

Disassembly:
mov qword [rsp + 8], rbx
push rbp
lea rbp, [rsp - 0x1350]
mov eax, 0x1450
call fcn.1400b5f10
sub rsp, rax
movaps xmmword [rsp + 0x1440], xmm6
movaps xmmword [rsp + 0x1430], xmm7
movaps xmmword [rsp + 0x1420], xmm8
mov rax, qword [0x1401a3080]
xor rax, rsp
mov qword [rbp + 0x1310], rax
xor ebx, ebx
lea rcx, [0x1401a6360]
call fcn.140060010
cmp byte [0x1401a6590], bl
jne 0x14004100c
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_char__struct_std::char_traits_char___std::cout]
lea rdx, [rsp + 0x50]
call fcn.140041620
movzx edx, byte [rax + 0xa]
test dl, dl
je 0x140040fe1
xor byte [rax], 0x38
xor byte [rax + 1], 0x39
xor byte [rax + 2], 0x3a
xor byte [rax + 3], 0x3b
xor byte [rax + 4], 0x3c
xor byte [rax + 5], 0x3d
xor byte [rax + 6], 0x3e
xor byte [rax + 7], 0x3f
xor byte [rax + 8], 0x40
xor byte [rax + 9], 0x41
xor dl, 0x42
mov byte [rax + 0xa], dl
mov rdx, rax
call fcn.140043190
mov rcx, rax
lea rdx, [0x1401a6598]
call fcn.140043360
mov ecx, 0x5dc
call qword [sym.imp.KERNEL32.dll_Sleep]
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
int3
call qword [sym.imp.KERNEL32.dll_GetConsoleWindow]
mov rcx, rax
xor edx, edx
call qword [sym.imp.USER32.dll_ShowWindow]
xor ecx, ecx
call qword [sym.imp.USER32.dll_GetSystemMetrics]
mov dword [0x1401a4eb4], eax
mov ecx, 1
call qword [sym.imp.USER32.dll_GetSystemMetrics]
mov dword [0x1401a4ed4], eax
mov ecx, 8
call fcn.1400b54f0
lea rcx, [0x1400409b0]
mov qword [rax], rcx
mov qword [rsp + 0x50], rax
lea rcx, [rbp + 0x1308]
mov qword [rsp + 0x28], rcx
mov dword [rsp + 0x20], ebx
mov r9, rax
lea r8, [0x140044d30]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__beginthreadex]
mov qword [rbp + 0x1300], rax
test rax, rax
je 0x14004160b
cmp dword [rbp + 0x1308], 0
je 0x1400415ff
movaps xmm0, xmmword [rbp + 0x1300]
movdqa xmmword [rsp + 0x50], xmm0
lea rcx, [rsp + 0x50]
call qword [sym.imp.MSVCP140.dll__Thrd_detach]
test eax, eax
jne 0x1400415ff
xorps xmm0, xmm0
movdqa xmmword [rbp + 0x1300], xmm0
mov ecx, 8
call fcn.1400b54f0
lea rcx, [0x1400406d0]
mov qword [rax], rcx
mov qword [rsp + 0x50], rax
lea rcx, [rbp + 0x1308]
mov qword [rsp + 0x28], rcx
mov dword [rsp + 0x20], ebx
mov r9, rax
lea r8, [0x140044d30]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__beginthreadex]
mov qword [rbp + 0x1300], rax
test rax, rax
je 0x1400415ed
cmp dword [rbp + 0x1308], 0
je 0x1400415e1
movaps xmm0, xmmword [rbp + 0x1300]
movdqa xmmword [rsp + 0x50], xmm0
lea rcx, [rsp + 0x50]
call qword [sym.imp.MSVCP140.dll__Thrd_detach]
test eax, eax
jne 0x1400415e1
xorps xmm0, xmm0
movdqa xmmword [rbp + 0x1300], xmm0
mov ecx, 8
call fcn.1400b54f0
lea rcx, [0x14003ec00]
mov qword [rax], rcx
mov qword [rsp + 0x50], rax
lea rcx, [rbp + 0x1308]
mov qword [rsp + 0x28], rcx
mov dword [rsp + 0x20], ebx
mov r9, rax
lea r8, [0x140044d30]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__beginthreadex]
mov qword [rbp + 0x1300], rax
test rax, rax
je 0x1400415cf
cmp dword [rbp + 0x1308], 0
je 0x1400415c3
movaps xmm0, xmmword [rbp + 0x1300]
movdqa xmmword [rsp + 0x50], xmm0
lea rcx, [rsp + 0x50]
call qword [sym.imp.MSVCP140.dll__Thrd_detach]
test eax, eax
jne 0x1400415c3
xorps xmm0, xmm0
movdqa xmmword [rbp + 0x1300], xmm0
mov ecx, 8
call fcn.1400b54f0
lea rcx, [0x14003dfe0]
mov qword [rax], rcx
mov qword [rsp + 0x50], rax
lea rcx, [rbp + 0x1308]
mov qword [rsp + 0x28], rcx
mov dword [rsp + 0x20], ebx
mov r9, rax
lea r8, [0x140044d30]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__beginthreadex]
mov qword [rbp + 0x1300], rax
test rax, rax
je 0x1400415b1
cmp dword [rbp + 0x1308], 0
je 0x1400415a5
movaps xmm0, xmmword [rbp + 0x1300]
movdqa xmmword [rsp + 0x50], xmm0
lea rcx, [rsp + 0x50]
call qword [sym.imp.MSVCP140.dll__Thrd_detach]
test eax, eax
jne 0x1400415a5
xorps xmm0, xmm0
movdqa xmmword [rbp + 0x1300], xmm0
lea r9, str.BrazilOnTop
xor r8d, r8d
mov edx, 1
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateEventW]
mov qword [rsp + 0x40], rax
movsd xmm0, qword [str..dd32695]
movsd qword [rbp + 0x1300], xmm0
mov eax, dword [0x140190210]
mov dword [rbp + 0x1308], eax
mov qword [rsp + 0x30], rbx
mov dword [rsp + 0x28], 0x80
mov dword [rsp + 0x20], 3
xor r9d, r9d
xor r8d, r8d
mov edx, 0xc0000000
lea rcx, [rbp + 0x1300]
call qword [sym.imp.KERNEL32.dll_CreateFileA]
mov qword [0x1401a4ec8], rax
mov dword [rsp + 0x60], ebx
mov qword [rsp + 0x38], rbx
lea rcx, [rsp + 0x60]
mov qword [rsp + 0x30], rcx
mov dword [rsp + 0x28], ebx
mov qword [rsp + 0x20], rbx
mov r9d, 0xa8
lea r8, [rsp + 0x40]
mov edx, 0x2224a0
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
mov qword [rsp + 0x50], rbx
mov qword [rsp + 0x38], rbx
lea rax, [rsp + 0x60]
mov qword [rsp + 0x30], rax
mov dword [rsp + 0x28], 0x44
lea rax, [rsp + 0x50]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
mov edx, 0x2224a4
mov rcx, qword [0x1401a4ec8]
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
cmp byte [reloc.WS2_32.dll_accept], 0
je 0x14004154f
mov ebx, 0x80000000
movsd xmm7, qword [0x140191460]
movss xmm8, dword [0x1401914d0]
cmp byte [0x1401a7a71], 0
je 0x14004152f
mov ecx, dword [reloc.WS2_32.dll_getsockname]
call qword [sym.imp.USER32.dll_GetAsyncKeyState]
test ax, ax
je 0x14004152f
call qword [sym.imp.MSVCP140.dll_unsigned_int___cdecl_std::_Random_device_void_]
mov dword [rbp + 0x12f4], 0xffffffff
mov dword [rsp + 0x74], eax
mov edx, 1
nop dword [rax]
mov ecx, eax
shr ecx, 0x1e
xor ecx, eax
imul eax, ecx, 0x6c078965
add eax, edx
mov dword [rsp + rdx*4 + 0x74], eax
inc rdx
cmp rdx, 0x270
jb 0x140041390
mov dword [rsp + 0x70], 0x270
lea rcx, reloc.WS2_32.dll_bind
call qword [sym.imp.MSVCP140.dll__Mtx_lock]
test eax, eax
jne 0x140041599
cmp dword [0x1401a31cc], 0x7fffffff
je 0x140041583
mov eax, dword [0x1401a315c]
mov dword [0x1401a4ec4], eax
movd xmm0, dword [0x1401a4ed0]
cvtdq2pd xmm0, xmm0
movaps xmm1, xmm7
call sub.api_ms_win_crt_math_l1_1_0.dll_pow
movaps xmm6, xmm0
movd xmm0, dword [0x1401a4ec0]
cvtdq2pd xmm0, xmm0
movaps xmm1, xmm7
call sub.api_ms_win_crt_math_l1_1_0.dll_pow
addsd xmm6, xmm0
xorps xmm1, xmm1
ucomisd xmm1, xmm6
ja 0x140041429
xorps xmm0, xmm0
sqrtsd xmm0, xmm6
jmp 0x140041431
movaps xmm0, xmm6
call sub.api_ms_win_crt_math_l1_1_0.dll_sqrt
xorps xmm6, xmm6
cvtsd2ss xmm6, xmm0
minss xmm6, xmm8
lea rcx, [rsp + 0x50]
call fcn.14003db40
mov rax, qword [rsp + 0x50]
sub rax, qword [0x1401a4ed8]
cmp rax, 0x4d3f640
jl 0x140041522
movaps xmm0, xmm6
mulss xmm0, dword [0x140191470]
mov eax, dword [0x1401a4ec0]
movd xmm1, eax
cvtdq2ps xmm1, xmm1
divss xmm1, xmm6
mulss xmm1, xmm0
mov ecx, dword [0x1401a4ed0]
movd xmm2, ecx
cvtdq2ps xmm2, xmm2
divss xmm2, xmm6
mulss xmm2, xmm0
test eax, eax
jne 0x14004149c
test ecx, ecx
je 0x14004150e
cvttss2si r8d, xmm2
cvttss2si edx, xmm1
xor r9d, r9d
call fcn.14003dc50
xor r9d, r9d
xor r8d, r8d
xor edx, edx
call fcn.14003dc50
lea rcx, [rsp + 0x70]
call fcn.140044a20
mov ecx, eax
lea rax, [rcx + rcx*2]
test eax, eax
jne 0x1400414e5
nop
lea rcx, [rsp + 0x70]
call fcn.140044a20
mov ecx, eax
lea rax, [rcx + rcx*2]
cmp eax, 1
jb 0x1400414d0
shr rax, 0x20
sub rax, rbx
xor rax, 0xffffffff80000000
mov qword [rsp + 0x40], rax
lea rcx, [rsp + 0x40]
call fcn.140042f70
xor r9d, r9d
xor r8d, r8d
xor edx, edx
call fcn.14003dc50
lea rcx, [rsp + 0x60]
call fcn.14003db40
mov rcx, qword [rax]
mov qword [0x1401a4ed8], rcx
lea rcx, reloc.WS2_32.dll_bind
call qword [sym.imp.MSVCP140.dll__Mtx_unlock]
mov qword [rsp + 0x40], 1
lea rcx, [rsp + 0x40]
call fcn.140042f70
cmp byte [reloc.WS2_32.dll_accept], 0
jne 0x140041352
mov eax, 1
mov rcx, qword [rbp + 0x1310]
xor rcx, rsp
call fcn.1400b53b0
lea r11, [rsp + 0x1450]
mov rbx, qword [r11 + 0x10]
movaps xmm6, xmmword [r11 - 0x10]
movaps xmm7, xmmword [r11 - 0x20]
movaps xmm8, xmmword [r11 - 0x30]
mov rsp, r11
pop rbp
ret
mov dword [0x1401a31cc], 0x7ffffffe
mov ecx, 6
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
int3
mov ecx, 5
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
nop
mov ecx, 1
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
nop
mov dword [rbp + 0x1308], ebx
mov ecx, 6
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
nop
mov ecx, 1
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
nop
mov dword [rbp + 0x1308], ebx
mov ecx, 6
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
nop
mov ecx, 1
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
nop
mov dword [rbp + 0x1308], ebx
mov ecx, 6
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
nop
mov ecx, 1
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
nop
mov dword [rbp + 0x1308], ebx
mov ecx, 6
call qword [sym.imp.MSVCP140.dll_void___cdecl_std::_Throw_Cpp_error_int_]
int3