Function at 0x140008670
Capabilities:
Parse pe header

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rsi
mov qword [rsp + 0x18], rdi
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rsp - 7]
sub rsp, 0xc0
mov rax, qword [0x14001c010]
xor rax, rsp
mov qword [rbp - 1], rax
mov rax, qword [rbp + 0x7f]
mov qword [rbp - 0x69], rax
xor esi, esi
mov qword [rbp - 0x49], rsi
mov qword [rbp - 0x39], rsi
mov r15, qword [0x141772670]
mov eax, 0x5a4d
cmp word [0x14001c050], ax
jne 0x1400088e4
movsxd rdi, dword [0x14001c08c]
lea rax, [0x14001c050]
add rdi, rax
cmp dword [rdi], 0x4550
jne 0x1400088e4
mov eax, 0x20b
cmp word [rdi + 0x18], ax
jne 0x1400088e4
mov ebx, dword [rdi + 0x50]
mov edx, ebx
xor ecx, ecx
lea r9d, [rsi + 4]
mov r8d, 0x3000
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov r14, rax
test rax, rax
je 0x1400088e4
movzx ecx, word [rdi + 0x14]
mov eax, dword [rcx + rdi + 0x24]
mov dword [rbp - 0x59], eax
sub ebx, eax
mov qword [rbp - 0x71], rsi
mov r12d, ebx
mov qword [rbp - 0x79], r12
lea r8, [rbp - 0x71]
mov edx, ebx
mov rcx, r15
call fcn.140008270
mov r13, rax
mov qword [rbp - 0x61], rax
test rax, rax
je 0x1400088c7
mov r8d, dword [rdi + 0x54]
lea rdx, [0x14001c050]
mov rcx, r14
call sub.VCRUNTIME140.dll_memcpy
movzx ebx, word [rdi + 0x14]
add rbx, 0x28
xor eax, eax
cmp ax, word [rdi + 6]
jae 0x1400087af
add rbx, rdi
lea r12, [0x14001c050]
nop
test dword [rbx + 0x14], 0x80
ja 0x14000879d
mov r8d, dword [rbx]
mov edx, dword [rbx + 4]
add rdx, r12
mov ecx, dword [rbx - 4]
add rcx, r14
call sub.VCRUNTIME140.dll_memcpy
inc esi
add rbx, 0x28
movzx eax, word [rdi + 6]
cmp esi, eax
jl 0x140008780
mov r12, qword [rbp - 0x79]
mov rsi, r13
mov eax, dword [rbp - 0x59]
sub r13, rax
mov rbx, r13
sub rbx, qword [rdi + 0x30]
mov rdx, r14
lea rcx, [rbp - 0x29]
call fcn.140009700
mov rdx, rbx
mov rcx, rax
call fcn.140008920
mov rdx, r14
lea rcx, [rbp - 0x29]
call fcn.140009850
mov rdx, rax
mov rcx, r15
call fcn.140008a20
test al, al
je 0x1400088c7
mov eax, dword [rbp - 0x59]
add rax, r14
je 0x1400088c7
test r12, r12
je 0x1400088c7
xor ecx, ecx
mov qword [rbp - 0x21], rcx
mov qword [rbp - 0x29], 0x33
mov qword [rbp - 0x19], rax
mov qword [rbp - 0x11], rsi
mov qword [rbp - 9], r12
mov dword [rbp - 0x59], ecx
mov qword [rsp + 0x38], rcx
lea rax, [rbp - 0x59]
mov qword [rsp + 0x30], rax
mov dword [rsp + 0x28], ecx
mov qword [rsp + 0x20], rcx
lea r9d, [rcx + 0x28]
lea r8, [rbp - 0x29]
mov edx, 0x80862007
mov rcx, r15
call qword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x1400088c7
mov ebx, dword [rdi + 0x28]
add rbx, r13
mov rax, qword [rbp - 0x71]
mov qword [rsp + 0x20], rax
mov r9, r12
mov r8, rsi
lea rdx, [rbp - 0x49]
lea rcx, [rbp - 0x39]
call fcn.140001df0
test al, al
je 0x1400088c7
xor eax, eax
mov dword [rbp - 0x59], eax
mov rax, qword [rbp - 0x49]
mov qword [rsp + 0x20], rax
mov r9, qword [rbp - 0x39]
mov r8, rbx
lea rdx, [rbp - 0x59]
mov rcx, r15
call fcn.140008df0
test al, al
je 0x1400088c7
mov rax, qword [rbp - 0x69]
test rax, rax
je 0x1400088b1
mov ecx, dword [rbp - 0x59]
mov dword [rax], ecx
xor edx, edx
mov r8d, 0x8000
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rax, rsi
jmp 0x1400088e6
xor edx, edx
mov r8d, 0x8000
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rdx, qword [rbp - 0x61]
mov rcx, r15
call fcn.140003140
xor eax, eax
mov rcx, qword [rbp - 1]
xor rcx, rsp
call fcn.14000b720
lea r11, [rsp + 0xc0]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x38]
mov rdi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret