Function at 0x140007490
Capabilities:
Allocate or change rwx memory
Parse pe header

Disassembly:
mov r11, rsp
mov dword [r11 + 0x18], r8d
mov qword [r11 + 0x10], rdx
mov qword [r11 + 8], rcx
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x40
mov r12, rdx
xor eax, eax
mov qword [r11 - 0x50], rax
mov esi, eax
mov qword [r11 - 0x48], rax
mov edi, eax
mov qword [rcx], rax
mov r13, rdx
mov qword [r11 - 0x50], rdx
mov ecx, 0x5a4d
cmp word [rdx], cx
jne 0x14000751b
movsxd rsi, dword [rdx + 0x3c]
add rsi, rdx
mov qword [r11 - 0x48], rsi
cmp dword [rsi], 0x4550
jne 0x14000751b
test byte [rsi + 0x38], 1
jne 0x14000751b
mov ecx, 0x8664
mov r15d, 0x2000
cmp word [rsi + 4], cx
je 0x140007504
mov edi, 0x4000000e
jmp 0x140007526
mov r14d, 0xc00000bb
test word [rsi + 0x16], r15w
jne 0x140007530
mov edi, r14d
mov dword [rsp + 0x20], r14d
jmp 0x140007530
mov edi, 0xc000007b
mov r15d, 0x2000
mov dword [rsp + 0x20], edi
mov r14d, 0xc00000bb
jmp 0x140007558
test edi, edi
js 0x1400078c7
cmp edi, 0x4000000e
je 0x1400078c7
mov rbx, rax
mov qword [rsp + 0x98], rax
test byte [rsi + 0x5e], 0x40
jne 0x14000759e
mov edx, dword [rsi + 0x50]
mov r9d, 0x40
mov r8d, r15d
mov rcx, qword [rsi + 0x30]
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rbx, rax
mov qword [rsp + 0x98], rax
test rbx, rbx
jne 0x1400075cf
mov edx, dword [rsi + 0x50]
lea r9d, [rbx + 0x40]
mov r8d, r15d
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rbx, rax
mov qword [rsp + 0x98], rax
mov r15d, 0xc0000017
test rax, rax
cmove edi, r15d
jmp 0x1400075d5
mov r15d, 0xc0000017
test edi, edi
js 0x1400078c7
mov rax, qword [0x1400f24f0]
mov r8d, dword [rax + 0x1c]
mov edx, dword [rsi + 0x54]
add edx, 0x3f
add edx, r8d
neg r8d
mov eax, r8d
and rdx, rax
mov r9d, 4
mov r8d, 0x1000
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rcx, rbx
test rax, rax
jne 0x140007638
xor edx, edx
mov r8d, 0x8000
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov eax, r15d
add rsp, 0x40
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
ret
movsxd r15, dword [r13 + 0x3c]
add r15, rbx
mov r8d, dword [rsi + 0x54]
mov rdx, r13
call fcn.14009ade0
mov qword [r15 + 0x30], rbx
movsxd rdx, dword [rbx + 0x3c]
movzx eax, word [rdx + rbx + 6]
lea ecx, [rax + rax*4]
lea edx, [rdx + rcx*8]
add edx, 0x108
movzx eax, word [r15 + 0x14]
xor r13d, r13d
mov r8d, r13d
movzx r9d, word [r15 + 6]
movsxd r10, edx
test r9d, r9d
je 0x1400076a7
lea rdx, [r10 + 0x40]
lea rcx, [r15 + 0x24]
add rcx, rax
nop word [rax + rax]
mov eax, dword [rcx]
cmp rax, rdx
jb 0x1400078ac
inc r8d
add rcx, 0x28
cmp r8d, r9d
jl 0x140007690
xorps xmm0, xmm0
movups xmmword [r10 + rbx], xmm0
movups xmmword [r10 + rbx + 0x10], xmm0
movups xmmword [r10 + rbx + 0x20], xmm0
movups xmmword [r10 + rbx + 0x30], xmm0
mov rax, qword [r15 + 0x30]
mov qword [r10 + rbx + 0x10], rax
mov eax, dword [rsp + 0x90]
mov dword [r10 + rbx + 0x30], eax
movabs rax, 0xaabbcc11ffee00
mov qword [r10 + rbx], rax
mov eax, dword [r15 + 0x54]
mov dword [r10 + rbx + 8], eax
mov qword [r10 + rbx + 0x18], r12
mov dword [r10 + rbx + 0x2c], 1
movzx edi, word [r15 + 0x14]
add rdi, 0x28
mov r14d, r13d
cmp r13w, word [r15 + 6]
jae 0x140007771
add rdi, r15
mov ecx, dword [r15 + 0x38]
lea edx, [rcx - 1]
add edx, dword [rdi - 8]
neg ecx
and edx, ecx
cmp edx, dword [rdi]
jb 0x140007818
mov ecx, dword [rdi - 4]
add rcx, qword [r15 + 0x30]
mov r9d, 4
mov r8d, 0x1000
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
test rax, rax
je 0x1400077f7
mov ecx, dword [rdi]
test ecx, ecx
je 0x140007760
mov r8d, ecx
mov edx, dword [rdi + 4]
add rdx, r12
mov rcx, rax
call fcn.14009ade0
inc r14d
add rdi, 0x28
movzx eax, word [r15 + 6]
cmp r14d, eax
jb 0x140007711
mov r11, qword [r15 + 0x30]
sub r11, qword [rsi + 0x30]
je 0x140007884
mov ecx, dword [r15 + 0xb0]
lea r8, [rcx + rbx]
mov eax, dword [r15 + 0xb4]
test eax, eax
je 0x140007884
test ecx, ecx
je 0x140007884
add rax, rcx
add rax, rbx
cmp r8, rax
jae 0x140007884
cmp dword [r8], r13d
jbe 0x140007884
lea r9, [r8 + 8]
mov r10d, r13d
mov ecx, dword [r8 + 4]
lea eax, [rcx - 8]
test eax, 0xfffffffe
jbe 0x140007862
movzx eax, word [r9]
mov ecx, eax
shr ecx, 0xc
cmp ecx, 3
je 0x140007839
cmp ecx, 0xa
jne 0x140007849
and eax, 0xfff
mov edx, dword [r8]
lea rcx, [rbx + rax]
add qword [rdx + rcx], r11
jmp 0x140007849
mov r14d, 0xc0000017
mov rcx, rbx
call fcn.1400078e0
mov eax, r14d
add rsp, 0x40
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
ret
mov r14d, 0xc000007b
mov rcx, rbx
call fcn.1400078e0
mov eax, r14d
add rsp, 0x40
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
ret
and eax, 0xfff
mov edx, dword [r8]
lea rcx, [rbx + rax]
add dword [rdx + rcx], r11d
inc r10d
add r9, 2
mov ecx, dword [r8 + 4]
lea eax, [rcx - 8]
shr eax, 1
cmp r10d, eax
jb 0x1400077d2
mov eax, ecx
add r8, rax
mov eax, dword [r15 + 0xb4]
mov ecx, dword [r15 + 0xb0]
add rax, rbx
add rcx, rax
cmp r8, rcx
jb 0x1400077b0
mov rax, qword [rsp + 0x80]
mov qword [rax], rbx
xor eax, eax
add rsp, 0x40
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
ret
mov rcx, rbx
call fcn.1400078e0
mov eax, r14d
add rsp, 0x40
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
ret
mov eax, edi
add rsp, 0x40
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
ret