Function at 0x140001690
Capabilities:
Acquire debug privileges
Encode data using xor
Enumerate processes
Generate random numbers using a mersenne twister
Link many functions at runtime

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x1620]
mov eax, 0x1720
call fcn.140004e30
sub rsp, rax
mov rax, qword [0x14000a040]
xor rax, rsp
mov qword [rbp + 0x1610], rax
mov r12, rdx
xor r13d, r13d
mov dword [rbp - 0x30], r13d
cmp ecx, 3
je 0x14000174f
lea rdx, str.Usage:
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcerr]
call fcn.140003210
mov rcx, rax
mov rdx, qword [r12]
call fcn.140003210
mov rcx, rax
lea rdx, str.__process_name___process_id_
call fcn.140003210
mov rcx, rax
lea rdx, [0x1400033f0]
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
lea eax, [r13 + 1]
mov rcx, qword [rbp + 0x1610]
xor rcx, rsp
call fcn.140003fe0
lea r11, [rsp + 0x1720]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x40]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret
mov rsi, qword [rdx + 8]
xorps xmm0, xmm0
movups xmmword [rbp - 0x28], xmm0
mov qword [rbp - 0x18], r13
mov qword [rbp - 0x10], r13
mov rbx, 0xffffffffffffffff
nop dword [rax]
inc rbx
cmp word [rsi + rbx*2], r13w
jne 0x140001770
movabs r14, 0x7ffffffffffffffe
cmp rbx, r14
ja 0x140001f85
mov r15d, 0xa
cmp rbx, 7
ja 0x1400017c2
mov qword [rbp - 0x18], rbx
mov qword [rbp - 0x10], 7
add rbx, rbx
mov r8, rbx
mov rdx, rsi
lea rcx, [rbp - 0x28]
call sub.VCRUNTIME140.dll_memcpy
mov word [rbp + rbx - 0x28], r13w
jmp 0x14000186b
mov rax, rbx
or rax, 7
cmp rax, r14
jbe 0x1400017de
movabs rax, 0x7fffffffffffffff
lea rcx, [rax + rax]
jmp 0x14000180b
mov r14, rax
cmp rax, r15
cmovb r14, r15
lea rcx, [r14 + 1]
movabs rax, 0x7fffffffffffffff
cmp rcx, rax
ja 0x140001f8b
add rcx, rcx
cmp rcx, 0x1000
jb 0x140001837
lea rax, [rcx + 0x27]
cmp rax, rcx
jbe 0x140001f8b
mov rcx, rax
call fcn.140004000
test rax, rax
je 0x140001f72
lea rdi, [rax + 0x27]
and rdi, 0xffffffffffffffe0
mov qword [rdi - 8], rax
jmp 0x140001849
test rcx, rcx
je 0x140001846
call fcn.140004000
mov rdi, rax
jmp 0x140001849
mov rdi, r13
mov qword [rbp - 0x28], rdi
mov qword [rbp - 0x18], rbx
mov qword [rbp - 0x10], r14
add rbx, rbx
mov r8, rbx
mov rdx, rsi
mov rcx, rdi
call sub.VCRUNTIME140.dll_memcpy
mov word [rdi + rbx], r13w
mov rcx, qword [r12 + 0x10]
call qword [sym.imp.api_ms_win_crt_convert_l1_1_0.dll__wtoi]
mov r14d, eax
lea rcx, str.advapi32.dll
call qword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov rdi, rax
lea rcx, str.kernel32.dll
call qword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov rbx, rax
test rdi, rdi
je 0x1400018e3
lea rdx, str.OpenProcessToken
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x14000a988], rax
lea rdx, str.LookupPrivilegeValueW
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x14000a990], rax
lea rdx, str.AdjustTokenPrivileges
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x14000a960], rax
test rbx, rbx
je 0x14000195b
lea rdx, str.OpenProcess
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x14000a970], rax
lea rdx, str.ReadProcessMemory
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x14000a980], rax
lea rdx, str.GetLastError
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x14000a968], rax
lea rdx, str.VirtualQueryEx
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x14000a958], rax
lea rdx, str.GetSystemInfo
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x14000a978], rax
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov rcx, rax
lea r8, [rbp - 0x30]
mov edx, 0x28
call qword [0x14000a988]
mov esi, 1
test eax, eax
je 0x140001f17
lea r8, [rbp - 4]
lea rdx, str.SeDebugPrivilege
xor ecx, ecx
call qword [0x14000a990]
mov rcx, qword [rbp - 0x30]
test eax, eax
je 0x140001f11
mov dword [rbp - 8], esi
mov dword [rbp + 4], 2
mov qword [rsp + 0x28], r13
mov qword [rsp + 0x20], r13
lea r9d, [rsi + 0xf]
lea r8, [rbp - 8]
xor edx, edx
call qword [0x14000a960]
mov rcx, qword [rbp - 0x30]
test eax, eax
je 0x140001f11
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test r14d, r14d
jne 0x140001ad1
mov r14d, r13d
xor edx, edx
lea ecx, [rsi + 1]
call qword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
mov rbx, rax
cmp rax, 0xffffffffffffffff
je 0x140001a90
mov dword [rbp + 0x40], 0x238
lea rdx, [rbp + 0x40]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_Process32FirstW]
test eax, eax
je 0x140001a87
lea rax, [rbp + 0x6c]
mov rcx, 0xffffffffffffffff
nop dword [rax]
inc rcx
cmp word [rax + rcx*2], r14w
jne 0x140001a20
lea r9, [rbp - 0x28]
cmp qword [rbp - 0x10], 7
cmova r9, qword [rbp - 0x28]
mov r10, qword [rbp - 0x18]
mov r8, r10
cmp rcx, r10
cmovb r8, rcx
lea rdx, [rbp + 0x6c]
test r8, r8
je 0x140001a69
lea rax, [rbp + 0x6c]
sub r9, rax
movzx eax, word [rdx]
cmp word [rdx + r9], ax
jne 0x140001a70
add rdx, 2
sub r8, rsi
jne 0x140001a56
cmp r10, rcx
jb 0x140001a70
jbe 0x140001a83
lea rdx, [rbp + 0x40]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_Process32NextW]
test eax, eax
jne 0x140001a11
jmp 0x140001a87
mov r14d, dword [rbp + 0x48]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_CloseHandle]
test r14d, r14d
jne 0x140001ad1
lea rdx, str.Process
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcerr]
call fcn.140003210
lea rdx, [rbp - 0x28]
cmp qword [rbp - 0x10], 7
cmova rdx, qword [rbp - 0x28]
mov r8, qword [rbp - 0x18]
mov rcx, rax
call fcn.140003a70
lea rdx, str._not_found.
mov rcx, rax
jmp 0x140001f25
movaps xmm0, xmmword [str.abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789]
movaps xmmword [rsp + 0x50], xmm0
movaps xmm1, xmmword [0x140006650]
movaps xmmword [rsp + 0x60], xmm1
movaps xmm0, xmmword [0x140006660]
movaps xmmword [rsp + 0x70], xmm0
movaps xmm1, xmmword [0x140006670]
movaps xmmword [rbp - 0x80], xmm1
movaps xmm0, xmmword [0x140006680]
movaps xmmword [rbp - 0x70], xmm0
movaps xmm1, xmmword [0x140006690]
movaps xmmword [rbp - 0x60], xmm1
movaps xmm0, xmmword [0x1400066a0]
movaps xmmword [rbp - 0x50], xmm0
movsd xmm0, qword [0x1400066b0]
movsd qword [rbp - 0x40], xmm0
mov eax, dword [0x1400066b8]
mov dword [rbp - 0x38], eax
movzx eax, word [0x1400066bc]
mov word [rbp - 0x34], ax
xorps xmm0, xmm0
movups xmmword [rsp + 0x30], xmm0
mov qword [rsp + 0x40], r13
mov qword [rsp + 0x48], 7
mov word [rsp + 0x30], r13w
mov dword [rbp - 0x30], esi
call qword [sym.imp.MSVCP140.dll_unsigned_int___cdecl_std::_Random_device_void_]
mov dword [rbp + 0x1604], 0xffffffff
mov dword [rbp + 0x284], eax
mov rdx, rsi
nop word [rax + rax]
mov ecx, eax
shr ecx, 0x1e
xor ecx, eax
imul eax, ecx, 0x6c078965
add eax, edx
mov dword [rbp + rdx*4 + 0x284], eax
inc rdx
cmp rdx, 0x270
jb 0x140001b80
mov dword [rbp + 0x280], 0x270
nop dword [rax]
lea rcx, [rbp + 0x280]
call fcn.140003df0
mov ecx, eax
imul rax, rcx, 0x3e
cmp eax, 3
ja 0x140001be7
nop word [rax + rax]
lea rcx, [rbp + 0x280]
call fcn.140003df0
mov ecx, eax
imul rax, rcx, 0x3e
cmp eax, 4
jb 0x140001bd0
shr rax, 0x20
cdqe
movzx r9d, word [rsp + rax*2 + 0x50]
mov rcx, qword [rsp + 0x40]
mov rdx, qword [rsp + 0x48]
cmp rcx, rdx
jae 0x140001c27
lea rax, [rcx + 1]
mov qword [rsp + 0x40], rax
lea rax, [rsp + 0x30]
cmp rdx, 7
cmova rax, qword [rsp + 0x30]
mov word [rax + rcx*2], r9w
mov word [rax + rcx*2 + 2], r13w
jmp 0x140001c31
lea rcx, [rsp + 0x30]
call fcn.140003540
sub r15, 1
jne 0x140001bb0
mov r8, qword [rsp + 0x40]
mov rcx, qword [rsp + 0x48]
mov rax, rcx
sub rax, r8
cmp rax, 7
jb 0x140001ce8
lea rax, [r8 + 7]
mov qword [rsp + 0x40], rax
lea rdi, [rsp + 0x30]
cmp rcx, 7
cmova rdi, qword [rsp + 0x30]
lea rax, [0x140006846]
lea r15, str.output_
cmp rax, rdi
jbe 0x140001c9e
lea rax, [rdi + r8*2]
cmp r15, rax
ja 0x140001c9e
cmp rdi, r15
ja 0x140001c93
mov rbx, r13
jmp 0x140001ca3
mov rbx, rdi
sub rbx, r15
sar rbx, 1
jmp 0x140001ca3
mov ebx, 7
lea rcx, [rdi + 0xe]
lea r8, [r8*2 + 2]
mov rdx, rdi
call sub.VCRUNTIME140.dll_memmove
add rbx, rbx
mov r8, rbx
mov rdx, r15
mov rcx, rdi
call sub.VCRUNTIME140.dll_memcpy
lea rcx, [rdi + rbx]
mov r8d, 0xe
sub r8, rbx
lea rdx, [r15 + 0xe]
add rdx, rbx
call sub.VCRUNTIME140.dll_memcpy
lea rax, [rsp + 0x30]
jmp 0x140001d00
mov qword [rsp + 0x28], 7
mov edx, 7
lea rcx, [rsp + 0x30]
call fcn.140003c40
xorps xmm0, xmm0
movups xmmword [rbp - 8], xmm0
xorps xmm1, xmm1
movdqu xmmword [rbp + 8], xmm1
movups xmm0, xmmword [rax]
movups xmmword [rbp - 8], xmm0
movups xmm1, xmmword [rax + 0x10]
movups xmmword [rbp + 8], xmm1
mov qword [rax + 0x10], r13
mov qword [rax + 0x18], 7
mov word [rax], r13w
mov dword [rbp - 0x30], 3
mov rcx, qword [rbp + 8]
mov rdx, qword [rbp + 0x10]
mov rax, rdx
sub rax, rcx
cmp rax, 4
jb 0x140001d78
lea rax, [rcx + 4]
mov qword [rbp + 8], rax
lea rax, [rbp - 8]
cmp rdx, 7
cmova rax, qword [rbp - 8]
movabs rdx, 0x6e00690062002e
mov qword [rax + rcx*2], rdx
mov word [rax + rcx*2 + 8], r13w
lea rax, [rbp - 8]
jmp 0x140001d8f
mov qword [rsp + 0x20], 4
mov edx, 4
lea rcx, [rbp - 8]
call fcn.140003850
xorps xmm0, xmm0
movups xmmword [rbp + 0x18], xmm0
mov qword [rbp + 0x28], r13
mov qword [rbp + 0x30], r13
movups xmm0, xmmword [rax]
movups xmmword [rbp + 0x18], xmm0
movups xmm1, xmmword [rax + 0x10]
movups xmmword [rbp + 0x28], xmm1
mov qword [rax + 0x10], r13
mov qword [rax + 0x18], 7
mov word [rax], r13w
mov rdx, qword [rbp + 0x10]
cmp rdx, 7
jbe 0x140001e00
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 8]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140001dfb
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140001dfb
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14000403c
movdqa xmm0, xmmword [0x140006970]
movdqu xmmword [rbp + 8], xmm0
mov word [rbp - 8], r13w
mov rdx, qword [rsp + 0x48]
cmp rdx, 7
jbe 0x140001e57
lea rdx, [rdx*2 + 2]
mov rcx, qword [rsp + 0x30]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140001e52
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140001e52
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14000403c
mov qword [rsp + 0x40], r13
mov qword [rsp + 0x48], 7
mov word [rsp + 0x30], r13w
lea rdx, [rbp + 0x18]
mov ecx, r14d
call fcn.140001290
test al, al
je 0x140001ebb
lea rdx, str.Memory_dump_created_successfully_at
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcout]
call fcn.140003210
lea rdx, [rbp + 0x18]
cmp qword [rbp + 0x30], 7
cmova rdx, qword [rbp + 0x18]
mov r8, qword [rbp + 0x28]
mov rcx, rax
call fcn.140003a70
mov rcx, rax
lea rdx, [0x1400033f0]
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
mov esi, r13d
mov rdx, qword [rbp + 0x30]
cmp rdx, 7
jbe 0x140001efe
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp + 0x18]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140001ef9
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140001ef9
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14000403c
mov qword [rbp + 0x28], r13
mov qword [rbp + 0x30], 7
mov word [rbp + 0x18], r13w
jmp 0x140001f3b
call qword [sym.imp.KERNEL32.dll_CloseHandle]
lea rdx, str.Failed_to_enable_debug_privilege.
mov rcx, qword [sym.imp.MSVCP140.dll_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t___std::wcerr]
call fcn.140003210
lea rdx, [0x1400033f0]
mov rcx, rax
call qword [sym.imp.MSVCP140.dll_public:_class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64___cdecl_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t__::operator___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64____cdecl___class_std::basic_ostream_wchar_t__struct_std::char_traits_wchar_t______ptr64_____ptr64]
nop
mov rdx, qword [rbp - 0x10]
cmp rdx, 7
jbe 0x140001f7e
lea rdx, [rdx*2 + 2]
mov rcx, qword [rbp - 0x28]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140001f79
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140001f79
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14000403c
mov eax, esi
jmp 0x14000171f
call fcn.1400011b0
int3
call fcn.140001110
int3