Function at 0x1400196e0
Capabilities:
Parse pe header

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 7]
sub rsp, 0xd0
mov rax, qword [0x14002c040]
xor rax, rsp
mov qword [rbp - 1], rax
mov r15, rdx
mov qword [rbp - 0x39], rdx
mov rdi, rcx
mov qword [rbp - 0x61], rcx
mov rax, qword [rbp + 0x8f]
mov qword [rbp - 0x31], rax
xor esi, esi
mov qword [rbp - 0x59], rsi
mov qword [rbp - 0x49], rsi
mov eax, 0x5a4d
cmp word [rdx], ax
jne 0x140019c83
movsxd r14, dword [rdx + 0x3c]
add r14, rdx
cmp dword [r14], 0x4550
jne 0x140019c83
test r14, r14
je 0x140019c83
mov eax, 0x20b
cmp word [r14 + 0x18], ax
jne 0x140019c83
mov ebx, dword [r14 + 0x50]
mov edx, ebx
xor ecx, ecx
mov r9d, 4
mov r8d, 0x3000
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov r12, rax
test rax, rax
je 0x140019c83
movzx ecx, word [r14 + 0x14]
mov eax, dword [rcx + r14 + 0x24]
mov dword [rsp + 0x44], eax
sub ebx, eax
mov dword [rbp - 0x79], ebx
mov qword [rbp - 0x69], rsi
mov eax, dword [rbp + 0x77]
cmp eax, 1
jne 0x1400197c6
mov r13d, ebx
lea r8, [rbp - 0x69]
mov edx, ebx
mov rcx, rdi
call fcn.1400192c0
mov rsi, rax
jmp 0x140019a7e
cmp eax, 2
jne 0x14001995c
mov qword [rbp - 0x71], rsi
cmp qword [0x14002ca30], rsi
jne 0x140019869
lea rax, str.x____xxxxxxxx____xxxxxxxxx____xxxxxxxx
mov qword [rsp + 0x20], rax
lea r9, [0x14001e7a0]
mov r8, qword [0x14002c9f8]
lea rdx, str.PAGELK
mov rcx, rdi
call fcn.140014d70
mov rsi, rax
mov qword [0x14002ca30], rax
test rax, rax
je 0x140019952
xor r13d, r13d
mov dword [rsp + 0x48], r13d
lea r8, [rax + 1]
mov r9d, 4
lea rdx, [rsp + 0x48]
mov rcx, rdi
call fcn.140013560
test al, al
jne 0x140019850
mov qword [0x14002ca30], r13
xor esi, esi
mov r13d, ebx
jmp 0x140019a7e
movsxd rcx, dword [rsp + 0x48]
add rcx, 5
add rcx, rsi
mov qword [0x14002ca30], rcx
je 0x140019952
mov r9d, ebx
lea rdx, [rbp - 0x71]
mov rcx, rdi
call fcn.140016b70
test al, al
je 0x140019952
mov rsi, qword [rbp - 0x71]
test rsi, rsi
je 0x140019952
cmp qword [0x14002c970], 0
jne 0x140019920
lea rax, str.xx____x___x_x____xxxxxxx____x
mov qword [rsp + 0x20], rax
lea r9, [0x14001e820]
mov r8, qword [0x14002c9f8]
lea rdx, str.PAGE
mov rcx, rdi
call fcn.140014d70
mov qword [0x14002c970], rax
test rax, rax
je 0x140019944
lea r13, [rax + 0xc]
mov qword [0x14002c970], r13
mov dword [rsp + 0x48], 0
lea r8, [r13 + 1]
mov r9d, 4
lea rdx, [rsp + 0x48]
mov rcx, rdi
call fcn.140013560
test al, al
jne 0x14001990b
mov qword [0x14002c970], 0
jmp 0x140019944
movsxd rcx, dword [rsp + 0x48]
add rcx, 5
add rcx, r13
mov qword [0x14002c970], rcx
je 0x140019944
mov byte [rsp + 0x40], 0
mov dword [rsp + 0x20], ebx
mov r9, rsi
lea rdx, [rsp + 0x40]
mov rcx, rdi
call fcn.140016f70
test al, al
je 0x140019944
cmp byte [rsp + 0x40], 0
jne 0x140019954
mov r8d, ebx
mov rdx, rsi
mov rcx, rdi
call fcn.1400137e0
xor esi, esi
mov r13d, ebx
jmp 0x140019a7e
mov r13d, ebx
test ebx, ebx
je 0x140019a7e
mov edx, 4
mov rax, qword gs:[0x58]
mov rcx, qword [rax]
mov eax, dword [rdx + rcx]
cmp dword [0x14002ca78], eax
jle 0x140019a50
lea rcx, [0x14002ca78]
call fcn.14001c4b0
cmp dword [0x14002ca78], 0xffffffff
jne 0x140019a50
xorps xmm0, xmm0
movups xmmword [rbp - 0x29], xmm0
xorps xmm1, xmm1
movdqu xmmword [rbp - 0x19], xmm1
mov ecx, 0x20
call fcn.14001c528
mov qword [rbp - 0x29], rax
movdqa xmm0, xmmword [0x140027570]
movdqu xmmword [rbp - 0x19], xmm0
movups xmm0, xmmword [0x14001e8c8]
movups xmmword [rax], xmm0
mov ecx, dword [0x14001e8d8]
mov dword [rax + 0x10], ecx
movzx ecx, byte [0x14001e8dc]
mov byte [rax + 0x14], cl
mov byte [rax + 0x15], 0
lea r8, [rbp - 0x29]
mov rdx, qword [0x14002c9f8]
mov rcx, rdi
call fcn.140013c90
mov qword [0x14002cb60], rax
mov rdx, qword [rbp - 0x11]
cmp rdx, 0xf
jbe 0x140019a44
inc rdx
mov rcx, qword [rbp - 0x29]
mov rax, rcx
cmp rdx, 0x1000
jb 0x140019a3e
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x140019a3e
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.14001c400
nop
lea rcx, [0x14002ca78]
call fcn.14001c444
cmp qword [0x14002cb60], 0
je 0x140019a7e
mov qword [rbp - 0x71], rsi
mov qword [rsp + 0x20], r13
lea rdx, [rbp - 0x71]
mov rcx, rdi
call fcn.140017b70
mov rsi, qword [rbp - 0x71]
test al, al
mov eax, 0
cmove rsi, rax
mov rcx, r12
test rsi, rsi
jne 0x140019a99
xor edx, edx
mov r8d, 0x8000
call qword [sym.imp.KERNEL32.dll_VirtualFree]
jmp 0x140019c83
mov r8d, dword [r14 + 0x54]
mov rdx, r15
call sub.VCRUNTIME140.dll_memcpy
movzx ebx, word [r14 + 0x14]
add rbx, 0x28
xor ecx, ecx
mov r15d, ecx
cmp cx, word [r14 + 6]
jae 0x140019afc
add rbx, r14
mov r13, qword [rbp - 0x39]
test dword [rbx + 0x14], 0x80
ja 0x140019ade
mov r8d, dword [rbx]
mov edx, dword [rbx + 4]
add rdx, r13
mov ecx, dword [rbx - 4]
add rcx, r12
call sub.VCRUNTIME140.dll_memcpy
inc r15d
add rbx, 0x28
movzx eax, word [r14 + 6]
cmp r15d, eax
jl 0x140019ac1
mov r15d, dword [rbp - 0x79]
mov r13d, r15d
mov rdi, qword [rbp - 0x61]
jmp 0x140019b00
mov r15d, dword [rbp - 0x79]
mov qword [rbp - 0x79], rsi
mov eax, dword [rsp + 0x44]
sub rsi, rax
mov rbx, rsi
sub rbx, qword [r14 + 0x30]
mov rdx, r12
lea rcx, [rbp - 0x29]
call fcn.14001aae0
mov rdx, rbx
mov rcx, rax
call fcn.140019cc0
mov rdx, rsi
mov rcx, r12
call fcn.140019dc0
test al, al
je 0x140019c83
mov rdx, r12
lea rcx, [rbp - 0x29]
call fcn.14001ac10
mov rdx, rax
mov rcx, rdi
call fcn.140019e80
mov rbx, qword [rbp - 0x79]
test al, al
je 0x140019c3a
mov eax, dword [rsp + 0x44]
add rax, r12
je 0x140019c3a
test r13, r13
je 0x140019c3a
xor ecx, ecx
mov qword [rbp - 0x21], rcx
mov qword [rbp - 0x29], 0x33
mov qword [rbp - 0x19], rax
mov qword [rbp - 0x11], rbx
mov qword [rbp - 9], r13
mov dword [rsp + 0x44], ecx
mov qword [rsp + 0x38], rcx
lea rax, [rsp + 0x44]
mov qword [rsp + 0x30], rax
mov dword [rsp + 0x28], ecx
mov qword [rsp + 0x20], rcx
mov r9d, 0x28
lea r8, [rbp - 0x29]
mov edx, 0x80862007
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x140019c3a
mov r14d, dword [r14 + 0x28]
add r14, rsi
mov rsi, qword [rbp - 0x69]
mov qword [rsp + 0x20], rsi
mov r9, r13
mov r8, rbx
lea rdx, [rbp - 0x59]
lea rcx, [rbp - 0x49]
call fcn.140018c80
test al, al
je 0x140019c3e
xor eax, eax
mov dword [rsp + 0x44], eax
mov rax, qword [rbp - 0x59]
mov qword [rsp + 0x20], rax
mov r9, qword [rbp - 0x49]
mov r8, r14
lea rdx, [rsp + 0x44]
mov rcx, rdi
call fcn.14001a250
test al, al
je 0x140019c3e
mov rax, qword [rbp - 0x31]
test rax, rax
je 0x140019c24
mov ecx, dword [rsp + 0x44]
mov dword [rax], ecx
xor edx, edx
mov r8d, 0x8000
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rax, rbx
jmp 0x140019c85
mov rsi, qword [rbp - 0x69]
xor edx, edx
mov r8d, 0x8000
mov rcx, r12
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov eax, dword [rbp + 0x77]
mov rdx, rbx
cmp eax, 1
jne 0x140019cac
mov r8, rsi
mov rcx, rdi
call fcn.1400138d0
test al, al
je 0x140019c83
mov rdx, rsi
mov rcx, rdi
call fcn.140013a10
test al, al
je 0x140019c83
mov rdx, rsi
mov rcx, rdi
call fcn.140013b50
xor eax, eax
mov rcx, qword [rbp - 1]
xor rcx, rsp
call fcn.14001c3e0
mov rbx, qword [rsp + 0x120]
add rsp, 0xd0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
cmp eax, 2
jne 0x140019c7b
mov r8d, r15d
mov rcx, rdi
call fcn.1400137e0
jmp 0x140019c83