ossec/ossec-hids — pull request #94 by awiddersheim (2014-03-03 20:40:48+00:00)
Title: Fix win32 OS detection

This starts to add support for 2012. Change the log message to be
more flexible with what it spits back out to the user after the
checkVista() function is run.

Although this helps with 2012 detection it is not perfect. With the
addition of Windows 8.1/2012 R2 the documentation provided by
Microsoft indicates that the GetVersionEx APIs have been deprecated.
This means that if you are on an 8.1 machine and run GetVersionEx it
will return the Windows 8 version (6.2.0.0). In order to get the
correct version you must target your application for Windows 8.1.

I am just trying to fix installations on 2012 and 2012 R2 so this
code works well enough for now but should be revisited at some point
so that it will work with future Windows versions.

For more details on how to target your application for Windows 8.1 read
the following http://msdn.microsoft.com/en-us/library/windows/desktop/dn481241(v=vs.85).aspx.