Function at 0x14003e330
Capabilities:
Parse pe header

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], r9
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x50
mov r15, rcx
mov eax, 0x5a4d
cmp word [0x1400d7060], ax
jne 0x14003e620
movsxd rdi, dword [0x1400d709c]
lea rsi, [0x1400d7060]
add rdi, rsi
cmp dword [rdi], 0x4550
jne 0x14003e620
mov eax, 0x20b
cmp word [rdi + 0x18], ax
jne 0x14003e620
mov ebx, dword [rdi + 0x50]
mov edx, ebx
xor ecx, ecx
lea r9d, [rcx + 4]
mov r8d, 0x3000
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rbp, rax
test rax, rax
je 0x14003e620
movzx ecx, word [rdi + 0x14]
mov r13d, dword [rcx + rdi + 0x24]
sub ebx, r13d
mov r12d, ebx
je 0x14003e60f
mov edx, 4
mov rax, qword gs:[0x58]
mov rcx, qword [rax]
xor ebx, ebx
mov eax, dword [rdx + rcx]
cmp dword [0x1400fc1d4], eax
jle 0x14003e49a
lea rcx, [0x1400fc1d4]
call fcn.140053ba8
cmp dword [0x1400fc1d4], 0xffffffff
jne 0x14003e49a
mov qword [rsp + 0x30], rbx
mov qword [rsp + 0x40], rbx
mov qword [rsp + 0x48], 0xf
mov byte [rsp + 0x30], bl
lea r8d, [rbx + 0x15]
lea rdx, [0x1400ca938]
lea rcx, [rsp + 0x30]
call fcn.140003f70
nop
lea r8, [rsp + 0x30]
mov rdx, qword [0x1400fb698]
mov rcx, r15
call fcn.140039be0
mov qword [0x1400fc238], rax
mov rdx, qword [rsp + 0x48]
cmp rdx, 0x10
jb 0x14003e48e
inc rdx
mov rcx, qword [rsp + 0x30]
mov rax, rcx
cmp rdx, 0x1000
jb 0x14003e488
add rdx, 0x27
mov rcx, qword [rcx - 8]
sub rax, rcx
add rax, 0xfffffffffffffff8
cmp rax, 0x1f
jbe 0x14003e488
call qword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3
call fcn.1400539ec
nop
lea rcx, [0x1400fc1d4]
call fcn.140053b48
cmp qword [0x1400fc238], 0
je 0x14003e60f
mov qword [rsp + 0x98], rbx
mov qword [rsp + 0x20], r12
lea rdx, [rsp + 0x98]
mov rcx, r15
call fcn.14003cee0
test al, al
je 0x14003e60f
mov r14, qword [rsp + 0x98]
test r14, r14
je 0x14003e60f
mov r8d, dword [rdi + 0x54]
mov rdx, rsi
mov rcx, rbp
call sub.VCRUNTIME140.dll_memcpy
movzx ebx, word [rdi + 0x14]
add rbx, 0x28
xor eax, eax
mov esi, eax
cmp ax, word [rdi + 6]
jae 0x14003e543
add rbx, rdi
lea r14, [0x1400d7060]
nop dword [rax]
test dword [rbx + 0x14], 0x80
ja 0x14003e52d
mov r8d, dword [rbx]
mov edx, dword [rbx + 4]
add rdx, r14
mov ecx, dword [rbx - 4]
add rcx, rbp
call sub.VCRUNTIME140.dll_memcpy
inc esi
add rbx, 0x28
movzx eax, word [rdi + 6]
cmp esi, eax
jl 0x14003e510
mov r14, qword [rsp + 0x98]
mov rsi, r14
sub rsi, r13
mov rbx, rsi
sub rbx, qword [rdi + 0x30]
mov rdx, rbp
lea rcx, [rsp + 0x30]
call fcn.14003f460
mov rdx, rbx
mov rcx, rax
call fcn.14003e640
mov rdx, rsi
mov rcx, rbp
call fcn.14003e740
test al, al
je 0x14003e620
mov rdx, rbp
lea rcx, [rsp + 0x30]
call fcn.14003f590
mov rdx, rax
mov rcx, r15
call fcn.14003e7f0
test al, al
je 0x14003e5f1
mov r8, r13
add r8, rbp
mov r9, r12
mov rdx, r14
mov rcx, r15
call fcn.140039890
test al, al
je 0x14003e5f1
mov r8d, dword [rdi + 0x28]
add r8, rsi
xor eax, eax
mov dword [rsp + 0xa0], eax
mov qword [rsp + 0x20], rax
xor r9d, r9d
lea rdx, [rsp + 0xa0]
mov rcx, r15
call fcn.14003eb40
test al, al
je 0x14003e5f1
xor edx, edx
mov r8d, 0x8000
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rax, r14
jmp 0x14003e622
xor edx, edx
mov r8d, 0x8000
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rdx, r14
mov rcx, r15
call fcn.140039ac0
jmp 0x14003e620
xor edx, edx
mov r8d, 0x8000
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_VirtualFree]
xor eax, eax
lea r11, [rsp + 0x50]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret