Function at 0x140003970
Capabilities:
Access peb ldr_data
Encode data using xor
Resolve function by parsing pe exports

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x40
mov rax, qword gs:[0x60]
mov r8d, 0x2beaf37
mov r9d, 0x5a4d
mov qword [rsp + 0x20], rdx
mov ecx, 0x20b
mov rax, qword [rax + 0x18]
add rax, 0x10
mov qword [rsp + 0x30], rax
xor esi, esi
mov r12, qword [rax]
nop dword [rax]
cmp r12, rax
je 0x140003bf5
cmp qword [r12 + 0x60], 0
je 0x140003b17
mov rbx, qword [r12 + 0x30]
test rbx, rbx
je 0x140003b17
movsxd r13, dword [rbx + 0x3c]
add r13, rbx
mov r15d, dword [r13 + 0x88]
add r15, rbx
cmp word [rbx], r9w
jne 0x140003bd2
cmp word [r13 + 0x18], cx
jne 0x140003a13
cmp dword [r13 + 0x8c], 0
jbe 0x140003b12
mov r14d, dword [r15 + 0x18]
xor r11d, r11d
test r14d, r14d
je 0x140003b09
mov eax, dword [r15 + 0x20]
nop word [rax + rax]
lea rax, [rax + r11*4]
xor r9d, r9d
mov edi, dword [rax + rbx]
mov eax, r8d
add rdi, rbx
movzx r10d, byte [rdi]
test r10b, r10b
je 0x140003aaa
mov r14d, 0x2beaf37
nop
movzx r8d, r10b
sub r10b, 0x41
cmp r10b, 0x19
lea ecx, [r8 + 0x20]
movzx edx, cl
mov ecx, r9d
cmova edx, r8d
movsx r8d, dl
lea edx, [r9 + 0x2beaf37]
xor eax, r8d
imul edx, r8d
add eax, edx
test r9d, r9d
cmove ecx, r14d
inc r9d
xor ecx, r14d
imul eax, ecx
movzx r10d, byte [r9 + rdi]
add eax, r8d
test r10b, r10b
jne 0x140003a50
mov r14d, dword [r15 + 0x18]
mov r8d, 0x2beaf37
mov rdx, qword [rsp + 0x20]
mov ecx, eax
cmp rdx, rcx
je 0x140003ac3
mov eax, dword [r15 + 0x20]
inc r11d
cmp r11d, r14d
jb 0x140003a30
jmp 0x140003afe
mov ecx, dword [r15 + 0x24]
mov rax, qword [r13 + 0x88]
add rcx, rbx
movzx edx, word [rcx + r11*2]
mov ecx, dword [r15 + 0x1c]
add rcx, rbx
mov esi, dword [rcx + rdx*4]
mov ecx, eax
add rsi, rbx
add rcx, rbx
cmp rsi, rcx
jb 0x140003af9
shr rax, 0x20
add rax, rcx
cmp rsi, rax
jb 0x140003b20
mov rdx, qword [rsp + 0x20]
mov ecx, 0x20b
mov r9d, 0x5a4d
test rsi, rsi
jne 0x140003baf
mov rax, qword [rsp + 0x30]
mov r12, qword [r12]
jmp 0x1400039c0
movzx r8d, byte [rsi]
mov r10, rsi
test r8b, r8b
je 0x140003b4e
nop dword [rax]
inc rsi
cmp r8b, 0x2e
mov rax, rsi
cmovne rax, r10
movzx r8d, byte [rsi]
mov r10, rax
test r8b, r8b
jne 0x140003b30
movzx r8d, byte [rax]
xor r11d, r11d
mov ebx, 0x2beaf37
mov r9d, ebx
test r8b, r8b
je 0x140003ba7
nop
movzx edx, r8b
sub r8b, 0x41
cmp r8b, 0x19
lea eax, [rdx + 0x20]
movzx ecx, al
mov eax, r11d
cmova ecx, edx
movsx edx, cl
lea ecx, [r11 + 0x2beaf37]
xor r9d, edx
imul ecx, edx
add r9d, ecx
test r11d, r11d
cmove eax, ebx
inc r11d
xor eax, ebx
imul r9d, eax
movzx r8d, byte [r11 + r10]
add r9d, edx
test r8b, r8b
jne 0x140003b60
mov edx, r9d
jmp 0x14000398c
mov rbx, qword [rsp + 0x70]
mov rax, rsi
mov rsi, qword [rsp + 0x80]
mov rbp, qword [rsp + 0x78]
add rsp, 0x40
pop r15
pop r14
pop r13
pop r12
pop rdi
ret
lea rdx, str.DOS_header_e_magic_mismatch
lea rcx, [rsp + 0x28]
call fcn.1400012c0
lea rdx, [0x140007328]
lea rcx, [rsp + 0x28]
call sub.VCRUNTIME140.dll__CxxThrowException
int3
lea rdx, str.Cannot_find_desired_import.
lea rcx, [rsp + 0x28]
call fcn.1400012c0
lea rdx, [0x140007328]
lea rcx, [rsp + 0x28]
call sub.VCRUNTIME140.dll__CxxThrowException
int3