Function at 0x140001780
Capabilities:
Access peb ldr_data
Encode data using xor
Get ntdll base address
Resolve function by parsing pe exports

Disassembly:
push r14
sub rsp, 0x20
cmp dword [0x1400097c0], 0
jne 0x140001a2f
mov rax, qword gs:[0x60]
xor edx, edx
mov rcx, qword [rax + 0x18]
mov r8, qword [rcx + 0x10]
mov rax, qword [r8 + 0x30]
test rax, rax
je 0x140001a3b
nop dword [rax]
nop word [rax + rax]
mov r14, rax
movsxd rax, dword [rax + 0x3c]
mov ecx, dword [rax + r14 + 0x88]
test ecx, ecx
je 0x1400017fd
lea rdx, [r14 + rcx]
mov ecx, dword [r14 + rcx + 0xc]
mov eax, dword [rcx + r14]
or eax, 0x20202020
cmp eax, 0x6c64746e
jne 0x1400017fd
mov eax, dword [rcx + r14 + 4]
or eax, 0x20202020
cmp eax, 0x6c642e6c
je 0x140001809
mov r8, qword [r8]
mov rax, qword [r8 + 0x30]
test rax, rax
jne 0x1400017c0
test rdx, rdx
je 0x140001a3b
mov r11d, dword [rdx + 0x18]
mov qword [rsp + 0x38], rbx
mov qword [rsp + 0x40], rbp
mov ebp, dword [rdx + 0x24]
mov qword [rsp + 0x18], rsi
add rbp, r14
mov esi, dword [rdx + 0x1c]
mov qword [rsp + 0x10], rdi
add rsi, r14
mov edi, dword [rdx + 0x20]
mov qword [rsp + 8], r12
add rdi, r14
mov qword [rsp], r15
lea r12, [0x1400097c0]
xor edx, edx
mov r15d, 0x775a
nop dword [rax]
nop dword [rax + rax]
lea eax, [r11 - 1]
mov r10d, dword [rdi + rax*4]
mov r11d, eax
add r10, r14
mov ebx, eax
cmp word [r10], r15w
jne 0x1400018bf
xor r9d, r9d
mov r8d, 0x1337c0de
mov rax, r10
movzx eax, word [rax]
mov ecx, r8d
ror ecx, 8
inc r9d
add ecx, eax
mov eax, r9d
add rax, r10
xor r8d, ecx
cmp byte [rax], 0
jne 0x140001882
mov ecx, edx
inc edx
add rcx, rcx
mov dword [r12 + rcx*8 + 8], r8d
movzx eax, word [rbp + rbx*2]
mov eax, dword [rsi + rax*4]
mov dword [r12 + rcx*8 + 0xc], eax
cmp edx, 0x226
je 0x1400018c4
test r11d, r11d
jne 0x140001860
xor r8d, r8d
mov dword [0x1400097c0], edx
lea eax, [rdx - 1]
test eax, eax
je 0x14000193c
mov eax, edx
xor ecx, ecx
sub eax, r8d
cmp eax, 1
je 0x140001931
lea r9d, [rcx + 1]
mov r11d, ecx
add r11, r11
mov r10d, r9d
add r10, r10
mov edi, dword [r12 + r11*8 + 0xc]
mov ebx, dword [r12 + r10*8 + 0xc]
cmp edi, ebx
jbe 0x140001922
mov ecx, dword [r12 + r11*8 + 8]
mov eax, dword [r12 + r10*8 + 8]
mov dword [r12 + r11*8 + 8], eax
mov dword [r12 + r10*8 + 8], ecx
mov dword [r12 + r11*8 + 0xc], ebx
mov dword [r12 + r10*8 + 0xc], edi
mov edx, dword [0x1400097c0]
mov eax, edx
mov ecx, r9d
sub eax, r8d
dec eax
cmp r9d, eax
jb 0x1400018e0
inc r8d
lea eax, [rdx - 1]
cmp r8d, eax
jb 0x1400018d4
mov edi, dword [0x1400097dc]
lea eax, [rdx - 1]
sub edi, dword [0x1400097cc]
xor ebp, ebp
test eax, eax
je 0x140001a12
mov word [rsp + 0x30], 0x50f
lea edx, [rdi - 2]
movzx r11d, word [rsp + 0x30]
mov r15b, 0xc3
nop dword [rax + rax]
mov esi, ebp
xor ecx, ecx
add rsi, rsi
mov r9d, dword [r12 + rsi*8 + 0xc]
add r9, r14
test edx, edx
je 0x14000199a
mov eax, ecx
add rax, r9
cmp r11w, word [rax]
jne 0x140001994
cmp r15b, byte [rax + 2]
je 0x1400019fb
inc ecx
cmp ecx, edx
jb 0x140001983
mov ebx, 1
nop
mov r8d, edi
xor ecx, ecx
imul r8d, ebx
test edx, edx
je 0x1400019ea
mov r10d, r8d
mov eax, ecx
add rax, r10
add rax, r9
cmp r11w, word [rax]
jne 0x1400019c4
cmp r15b, byte [rax + 2]
je 0x1400019fb
inc ecx
cmp ecx, edx
jb 0x1400019b0
xor ecx, ecx
mov r10d, r8d
nop
mov eax, ecx
sub rax, r10
add rax, r9
cmp r11w, word [rax]
jne 0x1400019e4
cmp r15b, byte [rax + 2]
je 0x1400019fb
inc ecx
cmp ecx, edx
jb 0x1400019d0
inc ebx
cmp ebx, 0x226
jb 0x1400019a0
lea rax, [0x140001ae0]
mov qword [r12 + rsi*8 + 0x10], rax
inc ebp
mov eax, dword [0x1400097c0]
dec eax
cmp ebp, eax
jb 0x140001970
mov r12, qword [rsp + 8]
mov rdi, qword [rsp + 0x10]
mov rsi, qword [rsp + 0x18]
mov rbp, qword [rsp + 0x40]
mov rbx, qword [rsp + 0x38]
mov r15, qword [rsp]
mov eax, 1
add rsp, 0x20
pop r14
ret
xor eax, eax
add rsp, 0x20
pop r14
ret