Function at 0x180001700
Capabilities:
Get system information on windows
Parse pe header

Disassembly:
push rbx
push r14
sub rsp, 0x58
mov eax, 0x5a4d
xor ebx, ebx
xor r14d, r14d
cmp word [0x1800175a0], ax
je 0x180001730
mov ecx, 0xc1
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
add rsp, 0x58
pop r14
pop rbx
ret
movsxd rcx, dword [0x1800175dc]
lea rax, [rcx + 0x108]
cmp rax, 0x25000
jbe 0x18000175b
mov ecx, 0xd
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
add rsp, 0x58
pop r14
pop rbx
ret
mov qword [rsp + 0x70], rbp
mov qword [rsp + 0x88], r13
lea r13, [0x1800175a0]
cmp dword [rcx + r13], 0x4550
lea rbp, [rcx + r13]
jne 0x180001790
mov eax, 0x8664
cmp word [rbp + 4], ax
jne 0x180001790
mov ecx, dword [rbp + 0x38]
test cl, 1
je 0x1800017a2
mov ecx, 0xc1
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x1800019a8
movzx eax, word [rbp + 0x14]
lea rdx, [rbp + 0x24]
mov qword [rsp + 0x80], rdi
add rdx, rax
movzx eax, word [rbp + 6]
mov r9, rcx
test eax, eax
je 0x1800017e5
mov r8d, eax
mov ecx, dword [rdx + 4]
test ecx, ecx
jne 0x1800017d1
mov eax, dword [rdx]
add rax, r9
jmp 0x1800017d5
mov eax, dword [rdx]
add eax, ecx
cmp rax, rbx
cmova rbx, rax
add rdx, 0x28
dec r8
jne 0x1800017c3
lea rcx, [rsp + 0x20]
call qword [sym.imp.KERNEL32.dll_GetNativeSystemInfo]
mov edx, dword [rsp + 0x24]
mov eax, dword [rbp + 0x50]
lea rdi, [rdx - 1]
lea rcx, [rdx - 1]
add rdi, rax
add rcx, rbx
lea rax, [rdx - 1]
not rax
and rdi, rax
lea rax, [rdx - 1]
not rax
and rcx, rax
cmp rdi, rcx
je 0x180001830
mov ecx, 0xc1
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x1800019a0
mov rcx, qword [rbp + 0x30]
mov r9d, 4
mov r8d, 0x3000
mov rdx, rdi
mov qword [rsp + 0x78], rsi
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rsi, rax
test rax, rax
jne 0x180001883
lea r9d, [rax + 4]
mov r8d, 0x3000
mov rdx, rdi
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rsi, rax
test rax, rax
jne 0x180001883
lea ecx, [rax + 0xe]
call qword [sym.imp.KERNEL32.dll_SetLastError]
xor eax, eax
jmp 0x18000199b
lea rcx, [rsi + rdi]
mov qword [rsp + 0x50], r15
movabs r15, 0xffffffff00000000
mov rax, rsi
and rcx, r15
and rax, r15
cmp rax, rcx
jae 0x1800018f6
mov ecx, 0x10
call fcn.180004068
mov rbx, rax
test rax, rax
je 0x1800019dc
mov qword [rax], r14
mov r9d, 4
mov r8d, 0x3000
mov rdx, rdi
xor ecx, ecx
mov qword [rax + 8], rsi
mov r14, rax
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rsi, rax
test rax, rax
je 0x1800019bd
lea rcx, [rax + rdi]
and rax, r15
and rcx, r15
cmp rax, rcx
jb 0x1800018a4
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov edx, 8
lea r8d, [rdx + 0x70]
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rdi, rax
test rax, rax
je 0x1800019dc
mov qword [rax + 8], rsi
movzx eax, word [rbp + 0x16]
mov qword [rdi + 0x58], 0
shr eax, 0xd
and eax, 1
mov dword [rdi + 0x20], eax
lea rax, [0x1800016b0]
mov qword [rdi + 0x28], rax
lea rax, [0x1800016c0]
mov qword [rdi + 0x30], rax
lea rax, [0x1800016d0]
mov qword [rdi + 0x38], rax
lea rax, [0x1800016e0]
mov qword [rdi + 0x40], rax
lea rax, [0x1800016f0]
mov qword [rdi + 0x48], rax
mov eax, dword [rsp + 0x24]
mov qword [rdi + 0x70], r14
mov dword [rdi + 0x68], eax
mov edx, dword [rbp + 0x54]
cmp rdx, 0x25000
jbe 0x1800019f2
mov ecx, 0xd
call qword [sym.imp.KERNEL32.dll_SetLastError]
mov rcx, rdi
call fcn.180001b20
xor eax, eax
mov r15, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x78]
mov rdi, qword [rsp + 0x80]
mov rbp, qword [rsp + 0x70]
mov r13, qword [rsp + 0x88]
add rsp, 0x58
pop r14
pop rbx
ret
mov rcx, rbx
lea rdx, [0x1800016c0]
xor r8d, r8d
call fcn.180001010
mov ecx, 0xe
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x180001994
xor edx, edx
mov r8d, 0x8000
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_VirtualFree]
mov rcx, r14
jmp 0x1800019c0
mov r9d, 4
mov r8d, 0x1000
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov r8d, dword [rbp + 0x54]
mov rdx, r13
mov rcx, rax
mov rbx, rax
call fcn.1800086c0
movsxd rax, dword [0x1800175dc]
mov r9, rdi
add rax, rbx
mov r8, rbp
mov qword [rdi], rax
mov qword [rax + 0x30], rsi
call fcn.180001080
test eax, eax
je 0x18000198c
mov rax, qword [rdi]
mov rdx, qword [rax + 0x30]
sub rdx, qword [rbp + 0x30]
je 0x180001a57
mov rcx, rdi
call fcn.180001430
mov dword [rdi + 0x24], eax
jmp 0x180001a5e
mov dword [rdi + 0x24], 1
mov rcx, rdi
call fcn.180001500
test eax, eax
je 0x18000198c
mov rcx, rdi
call fcn.1800011c0
test eax, eax
je 0x18000198c
mov rax, qword [rdi]
mov rbp, qword [rdi + 8]
mov ecx, dword [rax + 0xd0]
test ecx, ecx
je 0x180001aba
mov rbx, qword [rcx + rbp + 0x18]
test rbx, rbx
je 0x180001aba
mov rax, qword [rbx]
test rax, rax
je 0x180001aba
xor r8d, r8d
mov rcx, rbp
lea edx, [r8 + 1]
call rax
mov rax, qword [rbx + 8]
lea rbx, [rbx + 8]
test rax, rax
jne 0x180001aa1
mov rax, qword [rdi]
mov ecx, dword [rax + 0x28]
test ecx, ecx
je 0x180001b03
cmp dword [rdi + 0x20], 0
lea rax, [rsi + rcx]
je 0x180001af7
xor r8d, r8d
mov rcx, rsi
lea edx, [r8 + 1]
call rax
test eax, eax
jne 0x180001ae8
mov ecx, 0x45a
jmp 0x180001986
mov dword [rdi + 0x1c], 1
mov rax, rdi
jmp 0x180001996
mov qword [rdi + 0x60], rax
mov rax, rdi
jmp 0x180001996
mov qword [rdi + 0x60], 0
mov rax, rdi
jmp 0x180001996