Function at 0x408260
Capabilities:
Check os version

Disassembly:
sub esp, 0x1a0
push ebx
push esi
push edi
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0xa9]
mov byte [esp + 0xa8], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, 0x25
xor eax, eax
lea edi, [esp + 0xc]
rep stosd dword es:[edi], eax
lea eax, [esp + 0xc]
mov dword [esp + 0xc], 0x94
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
jne 0x4082b2
pop edi
pop esi
pop ebx
add esp, 0x1a0
ret
mov eax, dword [esp + 0x1c]
sub eax, 0
je 0x408496
dec eax
je 0x408399
dec eax
je 0x4082d5
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x1a0
ret
mov eax, dword [esp + 0x10]
cmp eax, 4
ja 0x4082ef
lea edx, [esp + 0xa8]
mov edi, str.Microsoft_Windows_NT
jmp 0x4084a2
cmp eax, 5
jne 0x40833d
mov eax, dword [esp + 0x14]
test eax, eax
jne 0x40830d
lea edx, [esp + 0xa8]
mov edi, str.Microsoft_Windows_2000
jmp 0x4084a2
cmp eax, 1
jne 0x408323
lea edx, [esp + 0xa8]
mov edi, str.Microsoft_Windows_XP
jmp 0x4084a2
cmp eax, 2
jne 0x4084bf
lea edx, [esp + 0xa8]
mov edi, str.Microsoft_Windows_Server_2003
jmp 0x4084a2
cmp eax, 6
jne 0x408376
mov eax, dword [esp + 0x14]
test eax, eax
jne 0x40835b
lea edx, [esp + 0xa8]
mov edi, str.Microsoft_Windows_Vista
jmp 0x4084a2
cmp eax, 1
jne 0x408371
lea edx, [esp + 0xa8]
mov edi, str.Microsoft_Windows_7
jmp 0x4084a2
cmp eax, 2
jmp 0x408382
jbe 0x4084bf
mov eax, dword [esp + 0x14]
test eax, eax
jne 0x4084bf
lea edx, [esp + 0xa8]
mov edi, str.Microsoft_Windows_8
jmp 0x4084a2
mov eax, dword [esp + 0x14]
test eax, eax
jne 0x408412
mov edi, str.Windows_95
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0xa8]
mov eax, ecx
mov esi, edi
mov edi, edx
push 0x4132f4
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x24]
push ecx
call dword [sym.imp.MSVCRT.dll__strcmpi]
add esp, 8
test eax, eax
jne 0x4084bf
mov edi, str.OSR2
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0xa8]
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
jmp 0x4084ba
cmp eax, 0xa
jne 0x408483
mov edi, str.Windows_98
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0xa8]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 0x4132dc
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x24]
push ecx
call dword [sym.imp.MSVCRT.dll__strcmpi]
add esp, 8
test eax, eax
jne 0x4084bf
mov edi, str.Second_Edition
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0xa8]
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
jmp 0x4084ba
cmp eax, 0x5a
jne 0x4084bf
lea edx, [esp + 0xa8]
mov edi, str.Windows_Millennium_Edition
jmp 0x4084a2
lea edx, [esp + 0xa8]
mov edi, str.Windows_3.1
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0xa8]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x4084f9
lea edi, [esp + 0xa8]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov edi, dword [esp + 0x1b0]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
pop edi
pop esi
mov eax, 1
pop ebx
add esp, 0x1a0
ret