Function at 0x1400018e0
Capabilities:
Enumerate pe sections
Get system information on windows
Parse pe header

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x88
cmp word [rcx], 0x5a4d
mov rdi, rcx
mov r15, rdx
mov rbp, r8
mov rbx, r9
jne 0x140001a60
movsxd rsi, dword [rcx + 0x3c]
add rsi, rcx
cmp dword [rsi], 0x4550
jne 0x140001a60
cmp word [rsi + 4], 0x8664
jne 0x140001a60
test byte [rsi + 0x38], 1
jne 0x140001a60
mov edx, dword [rsi + 0x50]
mov r9d, 4
mov r8d, 0x3000
mov rcx, qword [rsi + 0x30]
mov r12, qword [sym.imp.KERNEL32.dll_VirtualAlloc]
call r12
test rax, rax
mov r13, rax
je 0x140001eb0
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8d, 0x58
mov edx, 8
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
test rax, rax
mov r14, rax
je 0x140001f26
mov qword [rax + 8], r13
movzx eax, word [rsi + 0x16]
lea rcx, [rsp + 0x50]
mov qword [r14 + 0x28], r15
mov qword [r14 + 0x38], rbx
mov qword [r14 + 0x30], rbp
shr ax, 0xd
and eax, 1
mov dword [r14 + 0x20], eax
mov rax, qword [rsp + 0xf0]
mov qword [r14 + 0x40], rax
call qword [sym.imp.KERNEL32.dll_GetNativeSystemInfo]
mov eax, dword [rsp + 0x54]
mov rcx, r13
mov r9d, 4
mov edx, dword [rsi + 0x54]
mov r8d, 0x1000
mov dword [r14 + 0x50], eax
call r12
mov r8d, dword [rsi + 0x54]
mov rdx, rdi
mov rcx, rax
call sub.msvcrt.dll_memcpy
mov rbx, qword [r14 + 8]
mov r10, rax
movsxd rax, dword [rdi + 0x3c]
add r10, rax
movzx eax, word [r10 + 0x14]
mov qword [r14], r10
cmp word [r10 + 6], 0
mov qword [r10 + 0x30], r13
lea r15, [r10 + rax + 0x18]
je 0x140001ad9
xor ebp, ebp
mov edx, dword [r15 + 0x10]
test edx, edx
jne 0x140001a88
mov eax, dword [rsi + 0x38]
test eax, eax
jle 0x140001abe
mov ecx, dword [r15 + 0xc]
movsxd rdx, eax
mov r9d, 4
mov r8d, 0x1000
mov qword [rsp + 0x28], rdx
add rcx, rbx
call r12
test rax, rax
jne 0x140001c90
mov rcx, r14
xor r14d, r14d
call fcn.140001820
jmp 0x140001a6e
mov ecx, 0xc1
xor r14d, r14d
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rax, r14
add rsp, 0x88
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov ecx, dword [r15 + 0xc]
mov r9d, 4
mov r8d, 0x1000
add rcx, rbx
call r12
test rax, rax
je 0x140001a4b
mov ecx, dword [r15 + 0xc]
mov edx, dword [r15 + 0x14]
mov r8d, dword [r15 + 0x10]
add rcx, rbx
add rdx, rdi
call sub.msvcrt.dll_memcpy
mov dword [r15 + 8], eax
mov r10, qword [r14]
add ebp, 1
add r15, 0x28
movzx eax, word [r10 + 6]
cmp ebp, eax
jl 0x140001a11
mov rbx, qword [r14 + 8]
mov edx, dword [r10 + 0xb4]
xor eax, eax
test edx, edx
je 0x140001b78
mov r9d, dword [r10 + 0xb0]
add r9, rbx
mov r8d, dword [r9]
test r8d, r8d
je 0x140001b73
mov r11, r13
sub r11, qword [rsi + 0x30]
nop dword [rax + rax]
mov esi, dword [r9 + 4]
add r8, rbx
lea eax, [rsi - 8]
shr eax, 1
je 0x140001b68
xor edx, edx
jmp 0x140001b3a
cmp cx, 0xa
jne 0x140001b2d
movzx eax, ax
add qword [r8 + rax], r11
add rdx, 1
lea eax, [rsi - 8]
shr eax, 1
cmp eax, edx
jbe 0x140001b68
movzx eax, word [r9 + rdx*2 + 8]
mov ecx, eax
and ax, 0xfff
shr cx, 0xc
cmp cx, 3
jne 0x140001b20
movzx eax, ax
add rdx, 1
add dword [r8 + rax], r11d
mov esi, dword [r9 + 4]
lea eax, [rsi - 8]
shr eax, 1
cmp eax, edx
ja 0x140001b3a
add r9, rsi
mov r8d, dword [r9]
test r8d, r8d
jne 0x140001b08
mov eax, 1
mov r8d, dword [r10 + 0x94]
mov dword [r14 + 0x24], eax
test r8d, r8d
je 0x140001caf
mov esi, dword [r10 + 0x90]
mov rdi, qword [sym.imp.KERNEL32.dll_IsBadReadPtr]
add rsi, rbx
nop dword [rax]
mov edx, 0x14
mov rcx, rsi
call rdi
test eax, eax
jne 0x140001cac
mov ecx, dword [rsi + 0xc]
test ecx, ecx
je 0x140001cac
add rcx, rbx
mov rdx, qword [r14 + 0x40]
call qword [r14 + 0x28]
test rax, rax
mov r12, rax
je 0x140001f16
mov eax, dword [r14 + 0x18]
mov rcx, qword [r14 + 0x10]
lea edx, [rax + 1]
movsxd rdx, edx
shl rdx, 3
call sub.msvcrt.dll_realloc
test rax, rax
je 0x140001f57
movsxd rdx, dword [r14 + 0x18]
mov qword [r14 + 0x10], rax
mov ebp, dword [rsi]
mov r15d, dword [rsi + 0x10]
lea ecx, [rdx + 1]
mov dword [r14 + 0x18], ecx
mov qword [rax + rdx*8], r12
mov rax, rbp
add r15, rbx
add rbp, rbx
test eax, eax
cmove rbp, r15
mov rdx, qword [rbp]
test rdx, rdx
jne 0x140001c57
jmp 0x140001e18
lea rdx, [rbx + rdx + 2]
mov rcx, r12
call rax
test rax, rax
mov qword [r15], rax
je 0x140001c74
mov rdx, qword [rbp + 8]
add rbp, 8
add r15, 8
test rdx, rdx
je 0x140001e18
test rdx, rdx
mov rax, qword [r14 + 0x30]
mov r8, qword [r14 + 0x40]
jns 0x140001c30
movzx edx, dx
mov rcx, r12
call rax
test rax, rax
mov qword [r15], rax
jne 0x140001c42
mov rcx, r12
mov rdx, qword [r14 + 0x40]
call qword [r14 + 0x38]
mov ecx, 0x7f
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x140001a4b
mov ecx, dword [r15 + 0xc]
xor edx, edx
mov r8, qword [rsp + 0x28]
add rcx, rbx
mov dword [r15 + 8], ecx
call sub.msvcrt.dll_memset
jmp 0x140001abe
mov r10, qword [r14]
movabs r8, 0xffffffff00000000
movzx eax, word [r10 + 0x14]
mov esi, dword [r14 + 0x50]
and r8, qword [r10 + 0x30]
lea rbp, [r10 + rax + 0x18]
mov edx, dword [rbp + 8]
mov eax, esi
mov ecx, dword [rbp + 0x10]
neg eax
mov r9d, dword [rbp + 0x24]
or rdx, r8
and rax, rdx
test ecx, ecx
mov qword [rsp + 0x30], rdx
mov qword [rsp + 0x38], rax
je 0x140001dfe
mov dword [rsp + 0x40], ecx
add rbp, 0x28
cmp word [r10 + 6], 1
mov dword [rsp + 0x44], r9d
mov dword [rsp + 0x48], 0
lea r12, [rsp + 0x30]
jbe 0x140001e21
lea r12, [rsp + 0x30]
mov r15d, 1
jmp 0x140001d81
mov rdx, r12
mov rcx, r14
mov qword [rsp + 0x28], r8
call fcn.140001480
test eax, eax
je 0x140001a4b
mov eax, dword [rbp + 0x24]
mov qword [rsp + 0x30], rbx
mov r8, qword [rsp + 0x28]
mov qword [rsp + 0x38], rsi
mov dword [rsp + 0x40], edi
mov dword [rsp + 0x44], eax
mov r10, qword [r14]
add r15d, 1
add rbp, 0x28
movzx eax, word [r10 + 6]
cmp r15d, eax
jge 0x140001e21
mov esi, dword [r14 + 0x50]
mov rax, qword [rsp + 0x38]
mov rdx, qword [rsp + 0x30]
mov ebx, dword [rbp + 8]
neg esi
mov edi, dword [rbp + 0x10]
or rbx, r8
and rsi, rbx
test edi, edi
jne 0x140001da0
mov edi, dword [rbp + 0x24]
test dil, 0x40
je 0x140001df0
mov edi, dword [r10 + 0x20]
cmp rsi, rax
je 0x140001db5
mov eax, dword [rsp + 0x40]
add rax, rdx
cmp rsi, rax
jae 0x140001d28
mov ecx, dword [rbp + 0x24]
mov r9d, dword [rsp + 0x44]
mov eax, ecx
or eax, r9d
and ecx, 0x2000000
je 0x140001dd3
and r9d, 0x2000000
jne 0x140001dd8
and eax, 0xfdffffff
sub ebx, edx
mov dword [rsp + 0x44], eax
add ebx, edi
mov dword [rsp + 0x40], ebx
jmp 0x140001d5a
and edi, 0x80
je 0x140001da0
mov edi, dword [r10 + 0x24]
jmp 0x140001da0
test r9b, 0x40
je 0x140001ef5
mov ecx, dword [r10 + 0x20]
jmp 0x140001cf1
add rsi, 0x14
jmp 0x140001ba0
mov rdx, r12
mov rcx, r14
mov dword [rsp + 0x48], 1
call fcn.140001480
test eax, eax
je 0x140001a4b
mov rdx, qword [r14]
mov eax, dword [rdx + 0xd0]
test eax, eax
je 0x140001e7c
mov rsi, qword [r14 + 8]
mov rbx, qword [rsi + rax + 0x18]
test rbx, rbx
je 0x140001e7c
mov rax, qword [rbx]
test rax, rax
je 0x140001e7c
nop
add rbx, 8
xor r8d, r8d
mov edx, 1
mov rcx, rsi
call rax
mov rax, qword [rbx]
test rax, rax
jne 0x140001e60
mov rdx, qword [r14]
mov eax, dword [rdx + 0x28]
test eax, eax
je 0x140001ee8
mov ecx, dword [r14 + 0x20]
add rax, r13
test ecx, ecx
je 0x140001f0d
xor r8d, r8d
mov edx, 1
mov rcx, r13
call rax
test eax, eax
je 0x140001f47
mov dword [r14 + 0x1c], 1
jmp 0x140001a6e
xor ecx, ecx
mov edx, dword [rsi + 0x50]
mov r9d, 4
mov r8d, 0x3000
call r12
test rax, rax
mov r13, rax
jne 0x14000195c
mov ecx, 0xe
xor r14d, r14d
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x140001a6e
mov qword [r14 + 0x48], 0
jmp 0x140001a6e
mov ecx, r9d
and ecx, 0x80
je 0x140001cf1
mov ecx, dword [r10 + 0x24]
jmp 0x140001cf1
mov qword [r14 + 0x48], rax
jmp 0x140001a6e
mov ecx, 0x7e
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x140001a4b
mov rcx, r13
mov r8d, 0x8000
xor edx, edx
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov ecx, 0xe
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x140001a6e
mov ecx, 0x45a
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x140001a4b
mov rcx, r12
mov rdx, qword [r14 + 0x40]
call qword [r14 + 0x38]
mov ecx, 0xe
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x140001a4b