Function at 0x140021310
Capabilities:
Acquire debug privileges

Disassembly:
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push rbp
push r12
push r13
push r14
push r15
mov rbp, rsp
sub rsp, 0x80
mov rax, qword [0x14007f058]
xor rax, rsp
mov qword [rbp - 8], rax
mov r15, rcx
mov qword [rbp - 0x40], rcx
xor ebx, ebx
mov qword [rcx], rbx
mov qword [rcx + 8], rbx
mov ecx, 0x1b0
call fcn.1400379bc
mov qword [rax], rax
mov qword [rax + 8], rax
mov qword [rax + 0x10], rax
mov word [rax + 0x18], 0x101
mov qword [r15], rax
lea rcx, [r15 + 0x10]
lea edx, [rbx + 2]
call fcn.140037090
nop
lea rcx, [r15 + 0x60]
call fcn.140033a80
nop
lea rcx, [r15 + 0xf8]
call fcn.140030ce0
nop
mov qword [r15 + 0x1d8], rbx
mov dword [r15 + 0x194], 0x4cbebc20
mov dword [r15 + 0x184], 0x4cbebc20
mov dword [r15 + 0x180], 0x4cbebc20
mov dword [r15 + 0x17c], 0x4cbebc20
mov dword [r15 + 0x178], 0x4cbebc20
mov dword [r15 + 0x174], 0x4cbebc20
mov dword [r15 + 0x170], 0x4cbebc20
mov dword [r15 + 0x190], 0x4cbebc20
mov dword [r15 + 0x18c], 0x4cbebc20
mov dword [r15 + 0x188], 0x4cbebc20
mov qword [r15 + 0x1b0], rbx
mov qword [r15 + 0x1a8], rbx
mov qword [r15 + 0x1a0], rbx
mov qword [r15 + 0x198], rbx
mov qword [r15 + 0x1d0], rbx
mov qword [r15 + 0x1c8], rbx
mov qword [r15 + 0x1c0], rbx
mov qword [r15 + 0x1b8], rbx
lea rcx, [r15 + 0x1e0]
call fcn.14001fe40
nop
lea rcx, [r15 + 0x218]
call fcn.1400356e0
nop
mov word [r15 + 0x2c0], 1
mov dword [r15 + 0x2c4], 0xffffffff
lea r12, [r15 + 0x2c8]
xorps xmm0, xmm0
movups xmmword [r12], xmm0
mov qword [r12 + 0x10], rbx
mov qword [r12 + 0x18], 7
mov word [r12], bx
lea rsi, [r15 + 0x2e8]
movups xmmword [rsi], xmm0
mov qword [rsi + 0x10], rbx
mov qword [rsi + 0x18], 7
mov word [rsi], bx
movups xmmword [r15 + 0x308], xmm0
mov qword [r15 + 0x318], rbx
mov qword [r15 + 0x320], 7
mov word [r15 + 0x308], bx
movups xmmword [r15 + 0x328], xmm0
mov qword [r15 + 0x338], rbx
mov qword [r15 + 0x340], 7
mov word [r15 + 0x328], bx
lea r8d, [rbx + 0xe]
lea rdx, str.Warhammer3.exe
mov rcx, r12
call fcn.1400075d0
xorps xmm0, xmm0
movups xmmword [rbp - 0x28], xmm0
mov qword [rbp - 0x10], rbx
mov r13, r12
cmp qword [r12 + 0x18], 8
jb 0x14002151a
mov r13, qword [r12]
mov r14, qword [r12 + 0x10]
movabs rbx, 0x7ffffffffffffffe
cmp r14, rbx
ja 0x140021762
cmp r14, 8
jae 0x140021555
mov qword [rbp - 0x18], r14
mov ebx, 7
mov qword [rbp - 0x10], rbx
movups xmm0, xmmword [r13]
movups xmmword [rbp - 0x28], xmm0
movq rdi, xmm0
jmp 0x1400215a3
mov rax, r14
or rax, 7
cmp rax, rbx
ja 0x140021570
mov rbx, rax
mov ecx, 0xa
cmp rax, rcx
cmovb rbx, rcx
lea rdx, [rbx + 1]
lea rcx, [rbp - 0x28]
call fcn.140002790
mov rdi, rax
mov qword [rbp - 0x28], rax
mov qword [rbp - 0x18], r14
mov qword [rbp - 0x10], rbx
lea r8, [r14*2 + 2]
mov rdx, r13
mov rcx, rax
call fcn.140039c70
movups xmm0, xmmword [rbp - 0x28]
movups xmmword [rbp - 0x38], xmm0
lea rax, [rbp - 0x28]
cmp rsi, rax
je 0x140021618
mov rdx, qword [rsi + 0x18]
cmp rdx, 8
jb 0x1400215ef
mov rcx, qword [rsi]
lea rdx, [rdx*2 + 2]
cmp rdx, 0x1000
jb 0x1400215ea
add rdx, 0x27
mov r8, qword [rcx - 8]
sub rcx, r8
lea rax, [rcx - 8]
cmp rax, 0x1f
ja 0x14002175c
mov rcx, r8
call fcn.1400379f8
xor r14d, r14d
mov qword [rsi + 0x18], 7
movups xmm0, xmmword [rbp - 0x38]
movups xmmword [rsi], xmm0
movups xmm0, xmmword [rbp - 0x18]
movups xmmword [rsi + 0x10], xmm0
lea ebx, [r14 + 7]
mov word [rbp - 0x28], r14w
mov rdi, qword [rbp - 0x28]
jmp 0x14002161b
xor r14d, r14d
cmp rbx, 8
jb 0x140021656
lea rdx, [rbx*2 + 2]
mov rax, rdi
cmp rdx, 0x1000
jb 0x14002164e
add rdx, 0x27
mov rdi, qword [rdi - 8]
sub rax, rdi
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
ja 0x14002175c
mov rcx, rdi
call fcn.1400379f8
mov qword [rbp - 0x50], r14
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov rcx, rax
lea r8, [rbp - 0x50]
mov edx, 0x28
call qword [0x1400807b8]
test eax, eax
je 0x1400216d3
lea r8, [rbp - 0x48]
lea rdx, str.SeDebugPrivilege
xor ecx, ecx
call qword [0x1400807c0]
test eax, eax
je 0x1400216c9
mov dword [rbp - 0x38], 1
mov rax, qword [rbp - 0x48]
mov qword [rbp - 0x34], rax
mov dword [rbp - 0x2c], 2
mov qword [rsp + 0x28], r14
mov qword [rsp + 0x20], r14
mov r9d, 0x10
lea r8, [rbp - 0x38]
xor edx, edx
mov rcx, qword [rbp - 0x50]
call qword [0x1400807c8]
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov rcx, qword [rbp - 0x50]
call qword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [r15 + 0x348], r14d
mov r8d, 7
lea rdx, str.NOT_SET
lea rcx, [r15 + 0x328]
call fcn.1400075d0
mov r8, rsi
mov rdx, r12
lea rcx, [r15 + 0x60]
call fcn.1400349c0
lea rdx, [r15 + 0x60]
lea rbx, [r15 + 0xf8]
mov rcx, rbx
call fcn.1400338d0
mov qword [r15 + 0x1d8], rbx
mov rdx, rbx
lea rcx, [r15 + 0x218]
call fcn.1400356d0
nop
mov rax, r15
mov rcx, qword [rbp - 8]
xor rcx, rsp
call fcn.140037b10
lea r11, [rsp + 0x80]
mov rbx, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret
call fcn.14003e524
nop
call fcn.1400026f0
int3