Function at 0x6d9e0390
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0xd8
mov esi, dword [r9]
mov r12, rcx
mov qword [rsp + 0x60], rdx
mov rax, qword [r9 + 0x18]
mov qword [rsp + 0x68], r8
mov r15d, dword [r9 + 4]
mov ebp, dword [r9 + 8]
cmp esi, 0xa
mov r14, qword [r9 + 0x10]
mov qword [rsp + 0x50], rax
jne 0x6d9e0b52
lea eax, [r15 - 0x400]
cmp eax, 0x7fc00
ja 0x6d9e0930
lea eax, [rbp - 8]
cmp eax, 0x18
ja 0x6d9e0930
lea r13d, [r15 - 1]
test r13d, r15d
jne 0x6d9e0930
cmp qword [rsp + 0x50], 0
jne 0x6d9e0927
mov rax, rbp
mov edx, r15d
shl rax, 7
imul rdx, rax
cmp esi, 5
mov qword [rsp + 0x48], rax
je 0x6d9e08fe
mov rax, qword [rsp + 0x48]
mov ebx, 0x18000
mov dword [rsp + 0xc0], 0x18000
mov dword [rsp + 0x70], 0xb
add rax, 0x40
mov qword [rsp + 0x58], rax
mov rax, qword [rsp + 0x48]
add rax, rdx
add rax, qword [rsp + 0x58]
add rbx, rax
cmp rbx, qword [r12 + 0x18]
jbe 0x6d9e08f4
mov rcx, qword [r12]
test rcx, rcx
je 0x6d9e047d
mov qword [rsp + 0x78], rdx
call fcn.6da41160
mov rdx, qword [rsp + 0x78]
lea rcx, [rbx + 0x3f]
mov qword [r12], 0
mov qword [r12 + 8], 0
cmp rbx, rcx
mov qword [r12 + 0x18], 0
mov qword [r12 + 0x10], 0
ja 0x6d9e0b1e
mov qword [rsp + 0x78], rdx
call sub.msvcrt.dll_malloc
test rax, rax
je 0x6d9e0b2a
lea rdi, [rax + 0x3f]
mov qword [r12], rax
and rdi, 0xffffffffffffffc0
mov qword [r12 + 0x10], rbx
test rdi, rdi
mov qword [r12 + 8], rdi
mov qword [r12 + 0x18], rbx
je 0x6d9e093c
mov rdx, qword [rsp + 0x78]
mov rax, qword [rsp + 0x48]
movzx ecx, byte [rsp + 0x70]
lea r12, [rdi + rax]
mov eax, 0x10
lea rbx, [r12 + rdx]
mov rdx, qword [rsp + 0x58]
shl eax, cl
cdqe
mov rcx, qword [rsp + 0x60]
mov qword [rsp + 0x78], rax
add rdx, rbx
lea r9, [rdx + rax]
mov qword [rsp + 0xa0], rdx
mov rdx, qword [rsp + 0x68]
lea rax, [rsp + 0x80]
mov qword [rsp + 0xa8], r9
mov r8, rax
mov qword [rsp + 0x70], r9
mov qword [rsp + 0x58], rax
call fcn.6d9e1e50
cmp esi, 5
mov r9, qword [rsp + 0x70]
mov rax, qword [rsp + 0x78]
je 0x6d9e096d
mov qword [rsp + 0xb8], 0
add rax, r9
test r14, r14
mov qword [rsp + 0xb0], rax
je 0x6d9e0b0b
mov r9, qword [rsp + 0x50]
mov r8, r14
mov edx, 0x20
mov rcx, qword [rsp + 0x58]
mov qword [rsp + 0x28], rdi
lea r14, [rbp + rbp]
mov qword [rsp + 0x30], pe_nt_image_headers64
mov qword [rsp + 0x20], 1
call fcn.6d9e1ff0
mov rax, qword [rdi]
mov edx, 0xaaaaaaab
mov r8d, dword [rsp + 0xc0]
mov rcx, rdi
mov r9, qword [rsp + 0xa0]
mov qword [rsp + 0x80], rax
mov rax, qword [rdi + 8]
shr r8d, 7
mov qword [rsp + 0x88], rax
mov rax, qword [rdi + 0x10]
mov qword [rsp + 0x90], rax
mov rax, qword [rdi + 0x18]
mov qword [rsp + 0x20], rbx
mov qword [rsp + 0x28], 0
mov qword [rsp + 0x98], rax
lea eax, [r15 + 2]
mul edx
shr edx, 1
lea esi, [rdx + 1]
mov edx, 1
call fcn.6d9dfb60
lea rax, [rsp + 0xa0]
mov r8d, r15d
mov qword [rsp + 0x28], rax
mov r9, r12
mov rdx, rbp
mov qword [rsp + 0x20], rbx
mov rcx, rdi
and esi, 0xfffffffe
mov qword [rsp + 0x50], rax
call fcn.6d9dfb60
mov rax, qword [rsp + 0x48]
xor r8d, r8d
xor r9d, r9d
lea r15, [rbx + rax]
nop word [rax + rax]
mov eax, r9d
shl r8, 6
xor edx, edx
lea r10, [rbx + r8]
shl eax, 6
add rax, rdi
movzx r8d, byte [rax + 1]
add rax, 4
movzx ecx, byte [rax - 2]
movzx r11d, byte [rax - 4]
shl r8d, 8
shl ecx, 0x10
add r8d, ecx
movzx ecx, byte [rax - 1]
add r8d, r11d
shl ecx, 0x18
add ecx, r8d
mov dword [r15 + rdx*4], ecx
add rdx, 1
cmp rdx, 0x10
jne 0x6d9e0673
mov eax, dword [r15 + 0x14]
add r9d, 1
mov edx, dword [r15]
mov r8d, r9d
shl rax, 0x20
or rax, rdx
mov qword [r10], rax
mov eax, dword [r15 + 0x3c]
mov edx, dword [r15 + 0x28]
shl rax, 0x20
or rax, rdx
mov qword [r10 + 8], rax
mov eax, dword [r15 + 0x24]
mov edx, dword [r15 + 0x10]
shl rax, 0x20
or rax, rdx
mov qword [r10 + 0x10], rax
mov eax, dword [r15 + 0xc]
mov edx, dword [r15 + 0x38]
shl rax, 0x20
or rax, rdx
mov qword [r10 + 0x18], rax
mov eax, dword [r15 + 0x34]
mov edx, dword [r15 + 0x20]
shl rax, 0x20
or rax, rdx
mov qword [r10 + 0x20], rax
mov eax, dword [r15 + 0x1c]
mov edx, dword [r15 + 8]
shl rax, 0x20
or rax, rdx
mov qword [r10 + 0x28], rax
mov eax, dword [r15 + 4]
mov edx, dword [r15 + 0x30]
shl rax, 0x20
or rax, rdx
mov qword [r10 + 0x30], rax
mov eax, dword [r15 + 0x2c]
mov edx, dword [r15 + 0x18]
shl rax, 0x20
or rax, rdx
cmp r14, r8
mov qword [r10 + 0x38], rax
ja 0x6d9e0660
mov rcx, qword [rsp + 0x48]
mov qword [rsp + 0x68], rdi
mov rdi, qword [rsp + 0x50]
mov qword [rsp + 0x60], r15
mov rax, rcx
mov r15, rcx
sub rax, 0x40
mov qword [rsp + 0x48], rax
mov eax, dword [rbx + rcx - 0x40]
and eax, r13d
nop word [rax + rax]
mov edx, eax
mov r9, rdi
mov r8, rbp
shl rdx, 6
mov rcx, rbx
imul rdx, r14
add rdx, r12
call fcn.6d9de3f0
mov r9, rdi
mov r8, rbp
and eax, r13d
mov rcx, rbx
imul rax, r15
mov rdx, rax
add rdx, r12
call fcn.6d9de3f0
and eax, r13d
sub esi, 2
jne 0x6d9e0780
mov r15, qword [rsp + 0x60]
xor esi, esi
xor r9d, r9d
mov rdi, qword [rsp + 0x68]
nop dword [rax]
mov r10d, esi
shl r9, 6
mov rax, r15
shl r10d, 6
add r9, rbx
xor ecx, ecx
add r10, rdi
nop word cs:[rax + rax]
mov edx, dword [r9 + rcx*4]
add rcx, 1
add rax, 4
mov r8d, edx
mov byte [rax - 4], dl
shr r8d, 8
mov byte [rax - 3], r8b
mov r8d, edx
shr edx, 0x18
shr r8d, 0x10
mov byte [rax - 1], dl
mov byte [rax - 2], r8b
cmp rcx, 0x10
jne 0x6d9e07f0
mov rax, qword [r15]
add esi, 1
mov r9d, esi
mov dword [r10], eax
mov rdx, qword [r15 + 0x30]
mov rax, rdx
shr rax, 0x20
mov dword [r10 + 4], eax
mov r8, qword [r15 + 0x28]
mov dword [r10 + 8], r8d
shr r8, 0x20
mov eax, dword [r15 + 0x1c]
mov dword [r10 + 0xc], eax
mov rax, qword [r15 + 0x10]
mov dword [r10 + 0x10], eax
mov rax, qword [r15]
shr rax, 0x20
mov dword [r10 + 0x14], eax
mov rcx, qword [r15 + 0x38]
mov dword [r10 + 0x1c], r8d
mov dword [r10 + 0x18], ecx
shr rcx, 0x20
mov rax, qword [r15 + 0x20]
mov dword [r10 + 0x20], eax
mov eax, dword [r15 + 0x14]
mov dword [r10 + 0x24], eax
mov rax, qword [r15 + 8]
mov dword [r10 + 0x2c], ecx
mov dword [r10 + 0x30], edx
mov dword [r10 + 0x28], eax
shr rax, 0x20
cmp r14, r9
mov edx, dword [r15 + 0x24]
mov dword [r10 + 0x34], edx
mov rdx, qword [r15 + 0x18]
mov dword [r10 + 0x3c], eax
mov dword [r10 + 0x38], edx
ja 0x6d9e07d0
mov rcx, qword [rsp + 0x48]
mov r9d, 0x20
mov edx, 0x40
mov rax, qword [rsp + 0x140]
mov r8, qword [rsp + 0x58]
add rcx, rdi
mov qword [rsp + 0x20], rax
call fcn.6d9e1f60
xor eax, eax
add rsp, 0xd8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov rdi, qword [r12 + 8]
jmp 0x6d9e04e9
mov rax, rbp
mov ebx, 0x2000
mov dword [rsp + 0x70], 8
mov dword [rsp + 0xc0], 0x2000
shl rax, 8
mov qword [rsp + 0x58], rax
jmp 0x6d9e044a
test r14, r14
jne 0x6d9e0408
call qword [sym.imp.msvcrt.dll__errno]
mov dword [rax], 0x16
mov rax, qword [rsp + 0x140]
mov qword [rax], 0xffffffffffffffff
mov qword [rax + 8], 0xffffffffffffffff
mov qword [rax + 0x10], 0xffffffffffffffff
mov qword [rax + 0x18], 0xffffffffffffffff
mov eax, 0xffffffff
jmp 0x6d9e08e0
mov rax, qword [rsp + 0x48]
mov edx, 0x20
mov qword [rsp + 0x28], rdi
mov r9, qword [rsp + 0x68]
lea r13, [rsp + 0xa0]
mov qword [rsp + 0x20], 1
mov r8, qword [rsp + 0x60]
mov rcx, qword [rsp + 0x58]
mov qword [rsp + 0x30], rax
call fcn.6d9e1ff0
mov rax, qword [rdi]
mov edx, 0xaaaaaaab
mov r8d, dword [rsp + 0xc0]
mov rcx, rdi
mov r9, qword [rsp + 0xa0]
mov qword [rsp + 0x80], rax
mov rax, qword [rdi + 8]
shr r8d, 7
mov qword [rsp + 0x88], rax
mov rax, qword [rdi + 0x10]
mov qword [rsp + 0x90], rax
mov rax, qword [rdi + 0x18]
mov qword [rsp + 0x20], rbx
mov qword [rsp + 0x28], 0
mov qword [rsp + 0x98], rax
lea eax, [r15 + 2]
mul edx
shr edx, 1
lea eax, [rdx + 1]
mov esi, edx
mov edx, 1
mov dword [rsp + 0x60], eax
and esi, 0xfffffffe
call fcn.6d9dff90
mov r9, r12
mov r8d, r15d
mov rdx, rbp
mov rcx, rdi
mov qword [rsp + 0x28], r13
mov qword [rsp + 0x20], rbx
call fcn.6d9dff90
mov qword [rsp + 0x30], r13
mov r9d, esi
mov qword [rsp + 0x28], rbx
mov r8d, r15d
mov rdx, rbp
mov qword [rsp + 0x20], r12
mov rcx, rdi
call fcn.6d9df840
mov eax, dword [rsp + 0x60]
and eax, 0xfffffffe
cmp eax, esi
jbe 0x6d9e0a86
mov qword [rsp + 0x30], r13
mov r9d, 2
mov r8d, r15d
mov qword [rsp + 0x28], rbx
mov rdx, rbp
mov rcx, rdi
mov qword [rsp + 0x20], r12
call fcn.6d9df840
mov rax, qword [rsp + 0x140]
mov r8, rdi
mov edx, 0x20
mov qword [rsp + 0x30], 0x20
mov rsi, qword [rsp + 0x58]
mov qword [rsp + 0x20], 1
mov r9, qword [rsp + 0x48]
mov qword [rsp + 0x28], rax
mov rcx, rsi
call fcn.6d9e1ff0
xor eax, eax
test r14, r14
je 0x6d9e08e0
mov r9, qword [rsp + 0x50]
mov r8, r14
mov edx, 0x20
mov rcx, qword [rsp + 0x140]
mov qword [rsp + 0x20], rsi
mov dword [rsp + 0x48], eax
call fcn.6d9e1f60
mov r8, qword [rsp + 0x140]
mov rcx, rsi
mov edx, 0x20
call fcn.6d9e1e50
mov eax, dword [rsp + 0x48]
jmp 0x6d9e08e0
mov qword [rsp + 0x50], 0
mov r14, qword [rsp + 0x60]
jmp 0x6d9e057c
call qword [sym.imp.msvcrt.dll__errno]
mov dword [rax], 0xc
mov qword [r12], 0
mov qword [r12 + 8], 0
mov qword [r12 + 0x10], 0
mov qword [r12 + 0x18], 0
jmp 0x6d9e093c
cmp esi, 5
je 0x6d9e03d1
jmp 0x6d9e0930