Prev Previous Post   Next Post Next
Old 22nd April 2016, 15:23   #1
Junior Member
Join Date: Apr 2016
Posts: 4
Security Setting prevent WinVer functions from working

I am trying to update my NSIS script for making an installer that we have been using for years. Recently, my company has implemented HIPS and this seems to have affected the installers attempt to check the Window's version on the computer.

The code I am using is:

; First off, make sure we're using a minimum of Windows XP SP2...
${If} ${AtMostWinXP}
${AndIf} ${AtMostServicePack} 1
MessageBox MB_OK "This installer requires a minimum of Windows XP Service Pack 2. Please upgrade and rerun the installer."

I am running the installer on a Windows 7 computer, but this check fails and I get the message about needing to upgrade to XP SP2 and then it Aborts.

Through investigation with my IT, they gave me a script to disable the HIPS and the installer works just fine.

So, what I am trying to figure out is:
1. Where is "AtMostWinXP" looking to get the current Windows version on the computer. (Registry, if so where?) How does "AtMostWinXP" work?

2. What is a work around to allow me to check the windows version since our HIPS is preventing me from getting to that information...other than turn off HIPS during install. That is not something that we can do for each user that is trying to install the program.

-- Side note: I saw many scripts online that talk about getting the windows version from the registry: HKLM/SOFTWARE/Microsoft/Windows/CurrentVersion. And then you can check yourself to determine what version is running. The examples showed "VersionNumber" as being a variable at this registry location, but our systems do not seem to have this "VersionNumber". Is it hidden somehow? Is it located somewhere else?

Thanks in advance for any help.
scottabogardus is offline   Reply With Quote
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

nsis, version, winver

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump