Function at 0x40a630
Capabilities:
Check for peb beingdebugged flag
Check os version
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x432262
mov eax, dword fs:[0]
push eax
sub esp, 0x3f0
mov eax, dword [0x43fe28]
xor eax, esp
mov dword [esp + 0x3e8], eax
push ebx
push esi
push edi
mov eax, dword [0x43fe28]
xor eax, esp
push eax
lea eax, [esp + 0x400]
mov dword fs:[0], eax
xor edi, edi
xor eax, eax
mov word [esp + 0x20], ax
mov eax, 0x445378
mov dword [esp + 0x34], 7
mov dword [esp + 0x30], edi
lea edx, [eax + 2]
lea ecx, [ecx]
mov cx, word [eax]
add eax, 2
cmp cx, di
jne 0x40a690
sub eax, edx
sar eax, 1
push eax
mov eax, 0x445378
lea esi, [esp + 0x20]
call fcn.004087d0
mov dword [esp + 0x408], edi
mov eax, dword [esp + 0x30]
push 0x438210
xor edi, edi
mov ecx, esi
call fcn.00409010
test eax, eax
setne bl
mov dword [esp + 0x408], 0xffffffff
cmp dword [esp + 0x34], 8
jb 0x40a6eb
mov ecx, dword [esp + 0x20]
push ecx
call fcn.0040f4cb
add esp, 4
test bl, bl
jne 0x40abfe
xor edx, edx
xor edi, edi
push 7
mov eax, str.Windows
lea esi, [esp + 0xe4]
mov dword [esp + 0xfc], 7
mov dword [esp + 0xf8], edi
mov word [esp + 0xe8], dx
call fcn.004087d0
lea eax, [esp + 0xfc]
mov esi, 1
mov dword [esp + 0x408], esi
push eax
mov dword [esp + 0x100], 0x9c
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
mov ebx, dword [esp + 0x194]
mov al, byte [esp + 0x196]
and ebx, 0x200
cmp al, 3
je 0x40a769
mov dword [esp + 0x18], edi
cmp al, 2
jne 0x40a76d
mov dword [esp + 0x18], esi
push 0x256
lea edx, [esp + 0x1a2]
xor ecx, ecx
push edi
push edx
mov word [esp + 0x1a8], cx
call fcn.0041dcd0
add esp, 0xc
lea eax, [esp + 0x10]
push eax
push esi
push edi
push str.SOFTWAREMicrosoftWindows_NTCurrentVersion
push 0x80000002
mov dword [esp + 0x28], 0x258
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x40a7ee
mov eax, dword [esp + 0x10]
lea ecx, [esp + 0x14]
push ecx
lea edx, [esp + 0x1a0]
push edx
push edi
push edi
push str.ProductName
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x40a7d9
cmp dword [esp + 0x14], esi
jae 0x40a7e3
xor ecx, ecx
mov word [esp + 0x19c], cx
mov edx, dword [esp + 0x10]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [0x445374]
add eax, 0xfffffff9
cmp eax, 6
ja case.default.0x40a7ff
jmp dword [eax*4 + 0x40ac28]
lea eax, [esp + 0xe0]
push eax
mov eax, str.2000
call fcn.00408370
jmp 0x40a969
lea ecx, [esp + 0xe0]
push ecx
mov eax, 0x438308
call fcn.00408370
mov eax, str._Home
cmp ebx, edi
jne 0x40a83d
mov eax, str._Professional
lea edx, [esp + 0xe0]
push edx
call fcn.00408370
jmp 0x40a969
lea eax, [esp + 0xe0]
push eax
mov eax, str.2003
call fcn.00408370
jmp 0x40a969
lea ecx, [esp + 0xe0]
push ecx
mov eax, str.Vista
call fcn.00408370
jmp 0x40a969
lea edx, [esp + 0xe0]
push edx
mov eax, str.2008
call fcn.00408370
jmp 0x40a969
lea eax, [esp + 0xe0]
push eax
mov eax, 0x43835c
call fcn.00408370
jmp 0x40a969
lea ecx, [esp + 0x54]
push ecx
call fcn.0040b090
mov byte [esp + 0x408], 2
mov edx, dword [0x44536c]
mov eax, dword [0x445368]
push edx
push ecx
push 0x43820c
push ecx
push eax
lea ecx, [esp + 0x70]
push ecx
call fcn.0040af00
add esp, 4
push eax
call fcn.0040d5f0
add esp, 0xc
push eax
call fcn.0040af00
lea ecx, [esp + 0x1c]
lea eax, [esp + 0x54]
call fcn.0040b1c0
push edi
push eax
or eax, 0xffffffff
lea esi, [esp + 0xe8]
mov byte [esp + 0x410], 3
call fcn.00408d70
cmp dword [esp + 0x34], 8
jb 0x40a927
mov edx, dword [esp + 0x20]
push edx
call fcn.0040f4cb
add esp, 4
xor eax, eax
lea ecx, [esp + 0xa8]
mov dword [esp + 0x34], 7
mov dword [esp + 0x30], edi
mov word [esp + 0x20], ax
mov byte [esp + 0x408], 1
call fcn.0040b130
lea ecx, [esp + 0xa8]
push ecx
mov dword [esp + 0xac], vtable.std::ios_base.0
call fcn.00430052
add esp, 4
cmp dword [esp + 0x18], edi
je 0x40a982
push 7
mov eax, 0x438360
lea ecx, [esp + 0xe4]
call fcn.00408640
mov edx, dword [0x445368]
shl edx, 8
or edx, dword [0x44536c]
shl edx, 8
or edx, dword [0x445370]
cmp edx, 0x60000
jl 0x40aab9
cmp ebx, edi
je 0x40a9c2
push 5
mov eax, str._Home
lea ecx, [esp + 0xe4]
call fcn.00408640
jmp 0x40aab9
lea eax, [esp + 0x19c]
push str.Standard
push eax
call fcn.0041d17e
add esp, 8
test eax, eax
je 0x40a9f3
push 9
mov eax, str._Standard
lea ecx, [esp + 0xe4]
call fcn.00408640
jmp 0x40aab9
lea ecx, [esp + 0x19c]
push str.Professional
push ecx
call fcn.0041d17e
add esp, 8
test eax, eax
je 0x40aa1e
lea edx, [esp + 0xe0]
push edx
mov eax, str._Professional
jmp 0x40aab4
lea eax, [esp + 0x19c]
push str.Business
push eax
call fcn.0041d17e
add esp, 8
test eax, eax
je 0x40aa3e
mov eax, str._Business
jmp 0x40aaac
lea edx, [esp + 0x19c]
push str.Enterprise
push edx
call fcn.0041d17e
add esp, 8
test eax, eax
je 0x40aa66
lea eax, [esp + 0xe0]
push eax
mov eax, str._Enterprise
jmp 0x40aab4
lea ecx, [esp + 0x19c]
push str.Datacenter
push ecx
call fcn.0041d17e
add esp, 8
test eax, eax
je 0x40aa8e
lea edx, [esp + 0xe0]
push edx
mov eax, str._Datacenter
jmp 0x40aab4
lea eax, [esp + 0x19c]
push str.Ultimate
push eax
call fcn.0041d17e
add esp, 8
test eax, eax
je 0x40aab9
mov eax, str._Ultimate
lea ecx, [esp + 0xe0]
push ecx
call fcn.00408370
push 0x58
call dword [sym.imp.USER32.dll_GetSystemMetrics]
test eax, eax
je 0x40aace
push 8
mov eax, str._Starter
jmp 0x40aaee
lea edx, [esp + 0x19c]
push str.Basic
push edx
call fcn.0041d17e
add esp, 8
test eax, eax
je 0x40aafa
push 6
mov eax, str._Basic
lea ecx, [esp + 0xe4]
call fcn.00408640
call fcn.0040a5e0
test eax, eax
je 0x40ab16
push 4
mov eax, str._X64
lea ecx, [esp + 0xe4]
call fcn.00408640
cmp dword [0x445370], edi
jle 0x40abbd
lea eax, [esp + 0x54]
push eax
call fcn.0040b090
mov byte [esp + 0x408], 4
mov ecx, dword [0x445370]
push ecx
push ecx
lea edx, [esp + 0x64]
push 0x4384a0
push edx
call fcn.0040d5f0
add esp, 0xc
push eax
call fcn.0040af00
lea ecx, [esp + 0x38]
lea eax, [esp + 0x54]
call fcn.0040b1c0
push edi
push eax
or eax, 0xffffffff
lea esi, [esp + 0xe8]
mov byte [esp + 0x410], 5
call fcn.00408d70
cmp dword [esp + 0x50], 8
jb 0x40ab8e
mov eax, dword [esp + 0x3c]
push eax
call fcn.0040f4cb
add esp, 4
lea ecx, [esp + 0xa8]
mov byte [esp + 0x408], 1
call fcn.0040b130
lea ecx, [esp + 0xa8]
push ecx
mov dword [esp + 0xac], vtable.std::ios_base.0
call fcn.00430052
add esp, 4
mov eax, dword [esp + 0xe4]
mov esi, 8
cmp dword [esp + 0xf8], esi
jae 0x40abd9
lea eax, [esp + 0xe4]
push eax
push 0x445378
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
cmp dword [esp + 0xf8], esi
jb 0x40abfe
mov edx, dword [esp + 0xe4]
push edx
call fcn.0040f4cb
add esp, 4
mov eax, 0x445378
mov ecx, dword [esp + 0x400]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x3e8]
xor ecx, esp
call fcn.0041baef
mov esp, ebp
pop ebp
ret