Function at 0x140076140
Capabilities:
Check os version

Disassembly:
mov rax, rsp
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x1c0
mov qword [rsp + 0x60], 0xfffffffffffffffe
mov qword [rax + 8], rbx
mov qword [rax + 0x10], rbp
mov qword [rax + 0x18], rsi
mov rax, qword [0x1401787a0]
xor rax, rsp
mov qword [rsp + 0x1b0], rax
xor esi, esi
mov dword [0x14017ada0], esi
mov dword [0x14017ad78], esi
mov byte [0x14017ada8], sil
mov dword [0x14017ad94], esi
mov dword [0x14017ada4], esi
mov dword [0x14017ad7c], esi
mov dword [0x14017ad88], esi
mov dword [0x14017adac], esi
mov dword [0x14017ad80], esi
mov rax, qword [0x14017adb0]
lea rdx, [rax - 0x18]
mov rdi, qword [rdx]
cmp dword [rdx + 8], esi
je 0x140076215
cmp dword [rdx + 0x10], esi
jge 0x1400761ea
cmp dword [rax - 0xc], esi
jge 0x1400761db
mov ecx, 0x80070057
call fcn.140001a00
int3
mov dword [rax - 0x10], esi
mov rax, qword [0x14017adb0]
mov byte [rax], sil
jmp 0x140076215
or eax, 0xffffffff
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x140076201
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x18]
add rax, 0x18
mov qword [0x14017adb0], rax
mov dword [rsp + 0x70], 0x94
lea rcx, [rsp + 0x70]
call qword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
jne 0x140076247
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
lea rcx, str.CEnvironment::kGetOsVersionCheck___return_FALSE__1__LastError_u_GetVersionEx_fail._n
call fcn.140062f80
xor eax, eax
jmp 0x140076b0a
mov r14d, dword [rsp + 0x80]
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [rsp + 0x84]
repne scasb al, byte [rdi]
not rcx
lea r8d, [rcx - 1]
lea rdx, [rsp + 0x84]
lea rcx, [0x14017adb0]
call fcn.1400017b0
mov edx, dword [rsp + 0x80]
lea rcx, str.os.dwPlatformId___d__n
call fcn.140062f80
mov edx, dword [rsp + 0x74]
lea rcx, str.os.dwMajorVersion___d__n
call fcn.140062f80
mov edx, dword [rsp + 0x78]
lea rcx, str.os.dwMinorVersion___d__n
call fcn.140062f80
mov edx, dword [rsp + 0x80]
mov ebx, 0x80
mov r15d, 1
lea r13d, [rbx - 0x40]
sub edx, r15d
je 0x140076595
cmp edx, r15d
je 0x1400762f4
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r8d, dword [rsp + 0x80]
mov edx, eax
lea rcx, str.CEnvironment::kGetOsVersionCheck___return_FALSE__3__LastError_u_unknowen_dwPlatformId___d_._n
call fcn.140062f80
xor eax, eax
jmp 0x140076b0a
mov eax, dword [rsp + 0x74]
cmp eax, 4
jne 0x140076565
mov dword [0x14017adac], 8
call fcn.140097090
mov rdx, rax
mov ecx, esi
test rax, rax
setne cl
test ecx, ecx
jne 0x14007632a
mov ecx, 0x80004005
call fcn.140001a00
int3
mov rax, qword [rax]
mov rcx, rdx
call qword [rax + 0x18]
lea rbx, [rax + 0x18]
mov qword [rsp + 0x20], rbx
lea rcx, [rsp + 0x84]
lea rax, [rsp + 0x84]
test rax, 0xffffffffffff0000
jne 0x140076381
movzx edi, cx
mov ecx, edi
call fcn.1400a2710
test rax, rax
je 0x140076475
mov r8d, edi
mov rdx, rax
lea rcx, [rsp + 0x20]
call fcn.140002a70
mov rbx, qword [rsp + 0x20]
jmp 0x140076475
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [rsp + 0x84]
repne scasb al, byte [rdi]
not rcx
dec rcx
mov rdi, rcx
test ecx, ecx
jne 0x1400763f8
lea rdx, [rbx - 0x18]
mov rdi, qword [rdx]
cmp dword [rdx + 8], eax
je 0x140076475
cmp dword [rdx + 0x10], eax
jge 0x1400763cd
cmp dword [rbx - 0xc], eax
jge 0x1400763c3
mov ecx, 0x80070057
call fcn.140001a00
int3
mov dword [rbx - 0x10], esi
mov byte [rbx], al
jmp 0x140076475
or eax, 0xffffffff
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x1400763e4
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x18]
lea rbx, [rax + 0x18]
mov qword [rsp + 0x20], rbx
jmp 0x140076475
mov ebp, dword [rbx - 0x10]
lea r12, [rsp + 0x84]
sub r12, rbx
mov ecx, r15d
sub ecx, dword [rbx - 8]
mov eax, dword [rbx - 0xc]
sub eax, edi
or eax, ecx
jge 0x140076426
mov edx, edi
lea rcx, [rsp + 0x20]
call fcn.1400015a0
mov rbx, qword [rsp + 0x20]
cmp r12, rbp
ja 0x140076443
movsxd rbp, edi
lea r8, [r12 + rbx]
movsxd rdx, dword [rbx - 0xc]
mov r9, rbp
mov rcx, rbx
call fcn.1400c6510
jmp 0x14007645d
movsxd rbp, edi
movsxd rdx, dword [rbx - 0xc]
mov r9, rbp
lea r8, [rsp + 0x84]
mov rcx, rbx
call fcn.1400c6478
test edi, edi
js 0x14007655a
cmp edi, dword [rbx - 0xc]
jg 0x14007655a
mov dword [rbx - 0x10], edi
mov byte [rbx + rbp], 0
cmp dword [rbx - 0x10], 0
je 0x14007651f
mov r8d, r15d
lea rdx, [rsp + 0x28]
lea rcx, [rsp + 0x20]
call fcn.140003300
nop
mov rdx, qword [rax]
lea rcx, [rdx - 0x18]
add rbx, 0xffffffffffffffe8
cmp rcx, rbx
je 0x1400764ec
cmp dword [rbx + 0x10], 0
jl 0x1400764dd
mov rax, qword [rbx]
cmp qword [rcx], rax
jne 0x1400764dd
call fcn.140001a90
mov rdi, rax
or ecx, 0xffffffff
lock xadd dword [rbx + 0x10], ecx
dec ecx
test ecx, ecx
jg 0x1400764d2
mov rcx, qword [rbx]
mov rax, qword [rcx]
mov rdx, rbx
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
lea rax, [rdi + 0x18]
mov qword [rsp + 0x20], rax
jmp 0x1400764ec
mov r8d, dword [rdx - 0x10]
lea rcx, [rsp + 0x20]
call fcn.1400017b0
nop
mov rdx, qword [rsp + 0x28]
add rdx, 0xffffffffffffffe8
or eax, 0xffffffff
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x14007650c
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rbx, qword [rsp + 0x20]
mov rcx, rbx
call fcn.1400c9d88
mov dword [0x14017ad80], eax
lea rdx, [rbx - 0x18]
or eax, 0xffffffff
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x14007654a
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov edx, dword [0x14017adac]
mov ebx, 0x80
jmp 0x1400765dc
mov edx, dword [0x14017adac]
mov ebx, 0x80
jmp 0x1400765dc
mov ecx, 0x80070057
call fcn.140001a00
nop
cmp eax, 5
ja 0x140076584
mov edx, 0x10
mov eax, 0x20
cmp dword [rsp + 0x78], r15d
cmovae edx, eax
mov dword [0x14017adac], edx
jmp 0x1400765dc
mov edx, ebx
cmp eax, 6
cmovbe edx, r13d
mov dword [0x14017adac], edx
jmp 0x1400765dc
mov eax, dword [rsp + 0x78]
test eax, eax
jne 0x1400765af
mov edx, r15d
mov dword [0x14017adac], edx
mov dword [0x14017ad8c], r15d
jmp 0x1400765dc
cmp eax, 0xa
jne 0x1400765c7
mov edx, 2
mov dword [0x14017adac], edx
mov dword [0x14017ad8c], edx
jmp 0x1400765dc
mov edx, 4
mov dword [0x14017adac], edx
mov dword [0x14017ad8c], 3
test dl, 0x10
jne 0x14007661e
test dl, 0x20
jne 0x14007661e
test dl, 0x40
jne 0x14007661e
test dl, dl
js 0x14007661e
lea rcx, str.CEnvironment::kIsWin2k___return_FALSE__2___n
call fcn.1400631f0
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r8d, dword [rsp + 0x80]
mov edx, eax
lea rcx, str.CEnvironment::kGetOsVersionCheck___return_FALSE__4__LastError_u_detect_not_2k_OS._n
call fcn.140062f80
xor eax, eax
jmp 0x140076b0a
lea rcx, str.CEnvironment::kIsWin2k___return_TRUE__1___n
call fcn.1400631f0
cmp dword [0x14017adac], 1
je 0x1400767bd
mov dword [rsp + 0x110], 0x9c
lea rcx, [rsp + 0x110]
call qword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
jne 0x14007666f
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
lea rcx, str.CEnvironment::kGetOsVersionCheck_GetVersionEx_2__Error_:_d_n
call fcn.140062f80
xor eax, eax
jmp 0x140076b0a
mov eax, dword [rsp + 0x114]
mov dword [0x14017ada0], eax
mov eax, dword [rsp + 0x118]
mov dword [0x14017ad78], eax
movzx eax, byte [rsp + 0x1aa]
mov byte [0x14017ada8], al
xor eax, eax
or rcx, 0xffffffffffffffff
lea rdi, [rsp + 0x124]
repne scasb al, byte [rdi]
not rcx
lea r8d, [rcx - 1]
lea rdx, [rsp + 0x124]
lea rcx, [0x14017adb0]
call fcn.1400017b0
mov r14d, dword [rsp + 0x80]
movzx r9d, byte [0x14017ada8]
mov r8d, dword [0x14017ad78]
mov edx, dword [0x14017ada0]
lea rcx, str.CEnvironment::kGetOsVersionCheck_MajorVersion:_d__MinorVersion:_d__ProductType:_d_n
call fcn.140062f80
cmp dword [rsp + 0x120], 2
jne 0x14007679b
mov eax, dword [rsp + 0x114]
cmp eax, 5
jne 0x140076730
mov eax, dword [0x14017ad94]
cmp dword [rsp + 0x118], 1
cmovae eax, r15d
mov dword [0x14017ad94], eax
cmp byte [rsp + 0x1aa], 1
je 0x14007679b
mov dword [0x14017ad7c], r15d
jmp 0x14007679b
cmp eax, 6
jne 0x14007676e
mov dword [0x14017ad94], r15d
mov dword [0x14017ada4], r15d
mov eax, dword [0x14017ad88]
cmp dword [rsp + 0x118], 1
cmovae eax, r15d
mov dword [0x14017ad88], eax
cmp byte [rsp + 0x1aa], 1
je 0x1400767ab
mov dword [0x14017ad7c], r15d
jmp 0x1400767ab
cmp eax, 6
jbe 0x14007679b
mov dword [0x14017ad94], r15d
mov dword [0x14017ada4], r15d
mov dword [0x14017ad88], r15d
cmp byte [rsp + 0x1aa], 1
je 0x1400767ab
mov dword [0x14017ad7c], r15d
jmp 0x1400767ab
cmp dword [0x14017ada4], 1
je 0x1400767ab
mov r13d, dword [0x14017adac]
cmp dword [0x14017ad88], 1
cmove r13d, ebx
mov dword [0x14017adac], r13d
mov dword [0x14017ad90], r15d
mov dword [0x14017ad84], r15d
mov dword [0x14017ad9c], esi
mov dword [0x14017ad98], esi
lea rax, str.TRUE
lea rdx, str.FALSE
cmp dword [0x14017ad94], 1
cmove rdx, rax
lea rcx, str.kCheckOSVersion_m_bXP_s_n
call fcn.140062f80
call fcn.140075570
cmp eax, 1
jne 0x140076906
xor eax, eax
mov qword [rsp + 0x30], rax
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x48], rax
mov qword [rsp + 0x50], rax
mov qword [rsp + 0x58], rax
lea rcx, [rsp + 0x30]
call fcn.140075c30
test eax, eax
jne 0x14007685b
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r8d, dword [rsp + 0x80]
mov edx, eax
lea rcx, str.CEnvironment::kGetOsVersionCheck___return_FALSE__5__LastError_u_kGetNativeSystemInfo_fail._n
call fcn.140062f80
xor eax, eax
jmp 0x140076b0a
movzx edx, word [rsp + 0x30]
test edx, edx
je 0x1400768b2
cmp edx, 9
je 0x14007688b
lea rcx, str.CEnvironment::kGetOsVersionCheck_wProcessorArchitecture___d_n
call fcn.140062f80
mov dword [0x14017ad90], esi
mov dword [0x14017ad84], esi
mov edx, esi
mov dword [0x14017ad9c], edx
jmp 0x1400768d4
lea rcx, str.CEnvironment::kGetOsVersionCheck_wProcessorArchitecture__PROCESSOR_ARCHITECTURE_AMD64_n
call fcn.140062f80
mov dword [0x14017ad90], 2
mov dword [0x14017ad84], esi
mov edx, r15d
mov dword [0x14017ad9c], edx
jmp 0x1400768d4
lea rcx, str.CEnvironment::kGetOsVersionCheck_wProcessorArchitecture__PROCESSOR_ARCHITECTURE_INTEL_n
call fcn.140062f80
mov dword [0x14017ad90], r15d
mov dword [0x14017ad84], r15d
mov edx, esi
mov dword [0x14017ad9c], edx
lea rcx, str.CEnvironment::kIsAMD64___return___d___1__n
call fcn.1400631f0
cmp dword [0x14017ad9c], 1
jne 0x140076906
call fcn.140076020
cmp eax, 1
jne 0x140076906
lea rcx, str.CEnvironment::kGetOsVersionCheck_detected_a_WOW64_process._n
call fcn.140062f80
xor eax, eax
jmp 0x140076b0a
cmp r14d, 1
jne 0x14007694f
cmp dword [0x14017ada0], 4
jne 0x140076943
mov eax, dword [0x14017ad78]
cmp eax, 0x5a
jne 0x14007692f
mov dword [0x14017ad8c], 3
jmp 0x140076ae5
cmp eax, 0xa
jne 0x140076943
mov dword [0x14017ad8c], 2
jmp 0x140076ae5
mov dword [0x14017ad8c], r15d
jmp 0x140076ae5
cmp r14d, 2
jne 0x140076ae5
mov edx, dword [0x14017ad84]
lea rcx, str.CEnvironment::kIsX86___return___d___1__n
call fcn.1400631f0
cmp dword [0x14017ad84], 1
jne 0x140076a47
mov eax, dword [0x14017ada0]
cmp eax, 4
jne 0x14007698e
mov dword [0x14017ad8c], eax
jmp 0x140076ae5
cmp eax, 5
jne 0x1400769d4
mov eax, dword [0x14017ad78]
test eax, eax
jne 0x1400769ac
mov dword [0x14017ad8c], 5
jmp 0x140076ae5
cmp eax, 1
jne 0x1400769c0
mov dword [0x14017ad8c], 6
jmp 0x140076ae5
cmp eax, 2
jne 0x140076a3c
mov dword [0x14017ad8c], 7
jmp 0x140076ae5
cmp eax, 6
jne 0x140076a1e
mov eax, dword [0x14017ad78]
test eax, eax
jne 0x1400769fc
cmp byte [0x14017ada8], 1
setne sil
add esi, 8
mov dword [0x14017ad8c], esi
jmp 0x140076ae5
cmp eax, 1
jb 0x140076ae5
cmp byte [0x14017ada8], 1
setne sil
add esi, 0xa
mov dword [0x14017ad8c], esi
jmp 0x140076ae5
cmp eax, 6
jbe 0x140076a3c
cmp byte [0x14017ada8], 1
setne sil
add esi, 0xa
mov dword [0x14017ad8c], esi
jmp 0x140076ae5
mov dword [0x14017ad8c], esi
jmp 0x140076ae5
mov eax, dword [0x14017ada0]
cmp eax, 5
jne 0x140076a84
mov eax, dword [0x14017ad78]
cmp eax, 1
jne 0x140076a69
mov dword [0x14017ad8c], 0x65
jmp 0x140076ae5
cmp eax, 2
jne 0x140076adf
cmp byte [0x14017ada8], 1
setne sil
add esi, 0x65
mov dword [0x14017ad8c], esi
jmp 0x140076ae5
cmp eax, 6
jne 0x140076ac4
mov eax, dword [0x14017ad78]
test eax, eax
jne 0x140076aa9
cmp byte [0x14017ada8], 1
setne sil
add esi, 0x67
mov dword [0x14017ad8c], esi
jmp 0x140076ae5
cmp eax, 1
jb 0x140076ae5
cmp byte [0x14017ada8], 1
setne sil
add esi, 0x69
mov dword [0x14017ad8c], esi
jmp 0x140076ae5
cmp eax, 6
jbe 0x140076adf
cmp byte [0x14017ada8], 1
setne sil
add esi, 0x69
mov dword [0x14017ad8c], esi
jmp 0x140076ae5
mov dword [0x14017ad8c], esi
call fcn.140075eb0
test eax, eax
je 0x140076af6
bts dword [0x14017adac], 0x18
call fcn.140075630
test eax, eax
je 0x140076b07
bts dword [0x14017adac], 0x10
mov eax, r15d
mov rcx, qword [rsp + 0x1b0]
xor rcx, rsp
call fcn.1400c6ac0
lea r11, [rsp + 0x1c0]
mov rbx, qword [r11 + 0x30]
mov rbp, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret