Function at 0x140017580
Capabilities:
Check os version
Get system information on windows
Query or enumerate registry value

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x1c8
mov rax, qword [0x140113040]
xor rax, rsp
mov qword [rsp + 0x1c0], rax
mov eax, dword [0x140124878]
mov ecx, dword [0x140121718]
mov rdx, qword gs:[0x58]
mov rcx, qword [rdx + rcx*8]
cmp eax, dword [rcx + 4]
jg 0x14001766c
lea rsi, [0x140124870]
mov rcx, qword [rsp + 0x1c0]
xor rcx, rsp
call fcn.1400931d0
mov rax, rsi
add rsp, 0x1c8
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
mov dword [r14 + 0x14], 0
mov qword [0x140124870], r14
lea rcx, [0x140124878]
call fcn.1400910f8
jmp 0x1400175ca
lea rcx, [0x1401248c0]
call fcn.140091164
cmp dword [0x1401248c0], 0xffffffff
jne 0x140017713
vxorps xmm0, xmm0, xmm0
vmovups ymmword [0x1401248a0], ymm0
vmovups ymmword [0x140124890], ymm0
lea rcx, [0x140124890]
vzeroupper
call qword [sym.imp.KERNEL32.dll_GetNativeSystemInfo]
lea rcx, [0x1401248c0]
call fcn.1400910f8
jmp 0x140017713
xor ecx, ecx
xor eax, eax
jmp 0x14001788d
lea rcx, [0x140124878]
call fcn.140091164
cmp dword [0x140124878], 0xffffffff
jne 0x1400175ca
lea rsi, [rsp + 0x98]
mov r8d, 0x118
mov rcx, rsi
xor edx, edx
call fcn.1400c3300
mov dword [rsi - 4], 0x11c
lea rsi, [rsp + 0x94]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetVersionExW]
lea rdi, [rsp + 0x3c]
mov dword [rdi], 0
mov ecx, dword [rsi + 4]
mov edx, dword [rsi + 8]
mov qword [rsp + 0x20], rdi
xor r8d, r8d
xor r9d, r9d
call qword [sym.imp.KERNEL32.dll_GetProductInfo]
mov ecx, 0x80
call fcn.1400910bc
mov rsi, rax
mov r14, rax
mov eax, dword [rdi]
mov qword [rsp + 0x30], rax
mov eax, dword [0x1401248c0]
mov ecx, dword [0x140121718]
mov rdx, qword gs:[0x58]
mov rcx, qword [rdx + rcx*8]
cmp eax, dword [rcx + 4]
jg 0x140017615
mov dword [r14], 0
vxorps xmm0, xmm0, xmm0
vmovups ymmword [r14 + 0x20], ymm0
vmovups ymmword [r14 + 0x30], ymm0
movabs rax, 0x300000004
mov qword [r14 + 0x60], rax
vxorps xmm0, xmm0, xmm0
vmovups xmmword [r14 + 0x68], xmm0
xor r13d, r13d
mov qword [r14 + 0x78], r13
mov ebp, dword [rsp + 0x98]
mov dword [r14 + 4], ebp
mov r12d, dword [rsp + 0x9c]
mov dword [r14 + 8], r12d
mov ebx, dword [rsp + 0xa0]
mov dword [r14 + 0xc], ebx
mov qword [rsp + 0x80], r13
vmovaps xmmword [rsp + 0x70], xmm0
movabs rax, 0xaaaaaaaa00000000
mov qword [rsp + 0x60], rax
mov qword [rsp + 0x58], r13
mov qword [rsp + 0x68], r13
lea rax, [rsp + 0x40]
mov qword [rax], r13
mov qword [rsp + 0x20], rax
lea rdx, str.SOFTWAREMicrosoftWindows_NTCurrentVersion
mov rcx, 0xffffffff80000002
xor r8d, r8d
mov r9d, 1
vzeroupper
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x140017663
lea r9, [rsp + 0x40]
mov rcx, qword [r9]
mov qword [rsp + 0x58], rcx
xor r13d, r13d
mov dword [rsp + 0x60], r13d
mov eax, 4
mov dword [r9], eax
lea rdx, [rsp + 0x1b0]
mov dword [rdx], eax
lea rax, [rsp + 0x90]
mov dword [rax], r13d
mov qword [rsp + 0x28], rdx
mov qword [rsp + 0x20], rax
lea rdx, [0x14010498c]
xor r8d, r8d
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x14001783e
mov eax, dword [rsp + 0x40]
add eax, 0xfffffffd
xor r13d, r13d
cmp dword [rsp + 0x1b0], 4
mov ecx, 0
jne 0x140017837
mov ecx, dword [rsp + 0x90]
cmp eax, 2
cmovb r13d, ecx
lea rdx, str.DisplayVersion
lea rcx, [rsp + 0x58]
lea rdi, [rsp + 0x70]
mov r8, rdi
call fcn.140017db0
movzx eax, byte [rdi + 0x17]
test al, al
mov rcx, qword [rdi + 8]
mov rdx, rax
cmovs rdx, rcx
test rdx, rdx
jne 0x14001788d
lea rdx, str.ReleaseId
lea rcx, [rsp + 0x58]
lea rdi, [rsp + 0x70]
mov r8, rdi
call fcn.140017db0
mov al, byte [rdi + 0x17]
mov rcx, qword [rdi + 8]
test al, al
movzx edx, al
cmovs rdx, rcx
lea rcx, [rsp + 0x70]
cmovs rcx, qword [rcx]
vxorps xmm0, xmm0, xmm0
lea rdi, [rsp + 0x40]
vmovaps xmmword [rdi], xmm0
mov qword [rdi + 0x10], 0
mov r8, rdi
call fcn.140018100
mov r15, qword [rdi]
mov rax, qword [rdi + 8]
mov qword [rsp + 0x1b0], rax
mov rax, qword [rdi + 0xf]
mov qword [rsp + 0x1b7], rax
mov dil, byte [rdi + 0x17]
mov rcx, qword [rsp + 0x58]
test rcx, rcx
je 0x1400178fc
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov qword [rsp + 0x58], 0
mov dword [rsp + 0x60], 0
mov rcx, qword [rsp + 0x68]
mov qword [rsp + 0x68], 0
test rcx, rcx
jne 0x140017b39
cmp byte [rsp + 0x87], 0
jns 0x140017927
mov rcx, qword [rsp + 0x70]
call fcn.1400910b4
mov dword [r14 + 0x10], r13d
mov qword [r14 + 0x20], r15
mov rax, qword [rsp + 0x1b0]
mov rcx, qword [rsp + 0x1b7]
mov qword [r14 + 0x28], rax
mov qword [r14 + 0x2f], rcx
mov byte [r14 + 0x37], dil
mov eax, 0x16
cmp ebp, 0xa
jne 0x140017cc2
cmp ebx, 0x585c
ja 0x140017c1d
cmp ebx, 0x55ef
ja 0x14001799c
cmp ebx, 0x4f7b
ja 0x140017c27
cmp ebx, 0x4a64
ja 0x140017c31
je 0x140017c3b
mov eax, 0x12
cmp ebx, 0x4a62
jbe 0x140017b1d
mov dword [r14], eax
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov rdi, rax
mov eax, dword [0x140124888]
mov ecx, dword [0x140121718]
mov rdx, qword gs:[0x58]
mov rcx, qword [rdx + rcx*8]
cmp eax, dword [rcx + 4]
jle 0x140017a0e
lea rcx, [0x140124888]
call fcn.140091164
cmp dword [0x140124888], 0xffffffff
jne 0x140017a0e
lea rcx, str.kernel32.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
lea rdx, str.IsWow64Process2
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov qword [0x140124880], rax
lea rcx, [0x140124888]
call fcn.1400910f8
add rsi, 0x38
mov rax, qword [0x140124880]
test rax, rax
je 0x140017c7f
xor ecx, ecx
lea rdx, [rsp + 0x70]
mov word [rdx], cx
lea r8, [rsp + 0x58]
mov word [r8], cx
mov rcx, rdi
call qword [0x1401093a8]
test eax, eax
je 0x140017a72
movzx eax, word [rsp + 0x70]
test eax, eax
jne 0x140017c45
mov dword [r14 + 0x60], eax
movzx eax, word [rsp + 0x58]
xor ecx, ecx
cmp eax, 0x8664
setne cl
inc ecx
xor edx, edx
cmp eax, 0xaa64
cmovne edx, ecx
mov dword [r14 + 0x64], edx
lea rdi, [rsp + 0xa8]
movzx eax, word [rdi + 0x100]
mov dword [r14 + 0x18], eax
movzx eax, word [rdi + 0x102]
mov dword [r14 + 0x1c], eax
mov rcx, rdi
call fcn.140091674
vxorps xmm0, xmm0, xmm0
lea rbx, [rsp + 0x70]
vmovaps xmmword [rbx], xmm0
mov qword [rbx + 0x10], 0
mov rcx, rdi
mov rdx, rax
mov r8, rbx
call fcn.140018100
mov rax, qword [rbx + 0x10]
mov qword [rsi + 0x10], rax
vmovaps xmm0, xmmword [rbx]
vmovups xmmword [rsi], xmm0
mov eax, dword [0x1401248b0]
mov dword [r14 + 0x50], eax
mov eax, dword [0x1401248b8]
mov qword [r14 + 0x58], rax
mov eax, dword [rdi - 0x10]
cmp eax, 5
je 0x140017b8c
cmp eax, 0xa
je 0x140017af9
cmp eax, 6
jne 0x1400175f8
mov rdx, qword [rsp + 0x30]
cmp edx, 0x30
ja 0x140017b63
mov eax, edx
mov ecx, 0x206f780
bt rcx, rax
jae 0x140017b48
mov dword [r14 + 0x14], 2
jmp 0x140017600
je 0x140017d1e
mov eax, 0x10
cmp ebx, 0x4a60
ja 0x14001799c
jmp 0x140017d28
mov edx, 1
call fcn.14001cb90
jmp 0x140017913
mov ecx, 0x8010050
bt rcx, rax
jb 0x140017b7f
movabs rcx, 0x1000000000002
bt rcx, rax
jb 0x140017bd7
lea eax, [rdx - 0x46]
cmp eax, 0x3c
ja 0x140017c01
movabs rcx, 0x1980000000004005
bt rcx, rax
jae 0x140017be4
mov dword [r14 + 0x14], 3
jmp 0x140017600
mov eax, dword [rsp + 0x9c]
cmp eax, 1
je 0x140017bc9
cmp eax, 2
jne 0x1400175f8
cmp byte [rsp + 0x1ae], 1
jne 0x140017bb5
cmp word [0x140124890], 9
je 0x140017bd7
cmp word [rsp + 0x1ac], 0
jns 0x140017b10
jmp 0x1400175f8
test byte [rsp + 0x1ad], 2
jne 0x1400175f8
mov dword [r14 + 0x14], 1
jmp 0x140017600
movabs rcx, 0x18000000000000
bt rcx, rax
jae 0x140017c01
mov dword [r14 + 0x14], 4
jmp 0x140017600
add edx, 0xffffff5c
cmp edx, 2
jae 0x1400175f8
mov dword [r14 + 0x14], 5
jmp 0x140017600
mov eax, 0x17
jmp 0x14001799c
mov eax, 0x15
jmp 0x14001799c
mov eax, 0x14
jmp 0x14001799c
mov eax, 0x13
jmp 0x14001799c
lea ecx, [rax - 0x1c0]
cmp ecx, 4
ja 0x140017c5a
mov edx, 0x15
bt edx, ecx
jb 0x140017c75
cmp eax, 0x14c
jne 0x140017c6b
mov eax, 1
jmp 0x140017a4f
mov eax, 3
jmp 0x140017a4f
mov eax, 2
jmp 0x140017a4f
lea rdx, [rsp + 0x70]
mov dword [rdx], 0
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_IsWow64Process]
test eax, eax
je 0x140017a72
cmp dword [rsp + 0x70], 0
je 0x140017cb5
movabs rax, 0x100000001
mov qword [r14 + 0x60], rax
jmp 0x140017a72
mov dword [r14 + 0x60], 0
jmp 0x140017a72
cmp ebp, 0xb
je 0x14001799c
cmp ebp, 7
jb 0x140017cdf
call fcn.1400c4780
mov eax, 0x18
jmp 0x14001799c
cmp ebp, 6
jne 0x140017cfa
lea ecx, [r12 + 3]
cmp r12d, 3
mov eax, 6
cmovb eax, ecx
jmp 0x14001799c
xor eax, eax
test r12d, r12d
je 0x14001799c
cmp ebp, 5
jne 0x14001799c
xor eax, eax
cmp r12d, 1
setne al
inc eax
jmp 0x14001799c
mov eax, 0x11
jmp 0x14001799c
mov eax, 0xf
cmp ebx, 0x47ba
ja 0x14001799c
mov eax, 0xe
je 0x14001799c
mov eax, 0xd
cmp ebx, 0x4562
ja 0x14001799c
mov eax, 0xc
cmp ebx, 0x42ed
ja 0x14001799c
mov eax, 0xb
cmp ebx, 0x3faa
ja 0x14001799c
mov eax, 0xa
cmp ebx, 0x3ad6
ja 0x14001799c
mov eax, 9
cmp ebx, 0x3838
ja 0x14001799c
cmp ebx, 0x295a
mov eax, 7
sbb eax, 0xffffffff
jmp 0x14001799c