1

I have my own installer program which I use to install several applications I have written.

I have been updating this program to avoid the application's data file updates going to the user's VirtualStore, as I read this was a "bad thing". I am doing this by storing the program and common data files separately in their correct locations, instead of sticking everything in Program Files like we used to do in the days of XP.

I am also now using SHGetFolderPath (yes, it's deprecated, but I still need to support my XP users), to get known folders instead of trawling the registry, which is another "bad thing" (I read).

The next thing I was trying to do was rewrite the installer code to avoid registry redirection to Wow6432Node when writing stuff to HKLM, as I thought this was another "bad thing".

However, although I could put the application specific stuff that goes there (like the install folder, if the user decides to install in other than the default), the killer is the need to put the uninstall info in HKLM\Software\Microsoft\Windows\CurrentVersion\Uninstall. For 32-bit stuff running on a 64-bit system, this is redirected to Wow6432Node. I don't see any way round this - is it in fact possible?

Jeff G
  • 1,830
  • 1
  • 16
  • 17
  • 1
    Writing your own installer and not using MSI is *very* unwise. – Hans Passant Jun 24 '12 at 14:05
  • Why? I have used this for years with great success. It is very lightweight and specific to what I want. Would you like to answer my question? – Jeff G Jun 24 '12 at 15:36
  • @JeffG: MSI is also very lightweight. It's some of the MSI builder programs (InstallShield, for example) that are very clumsy. – Ben Voigt Jun 24 '12 at 20:03
  • Thanks to both, but this is really a different discussion. I just happened to mention an "installer" - my question could equally apply to any program. Before you mentioned InstallShield, I was going to suggest that all the programs using that and nsis as alternatives to MSI could also be called unwise. – Jeff G Jun 25 '12 at 02:54

2 Answers2

2

UAC registry redirection could reasonably be described as a "bad thing" because it is designed specifically to provide compatibility with improperly written software, i.e., software that assumes it is going to be run with administrator privilege.

WOW64 registry redirection is a different beast; it's designed to provide compatibility with properly written 32-bit software. If your software is 32-bit, and has no specific need to be 64-bit aware, there's nothing wrong with letting it run in the emulation environment as-is, including allowing registry settings to be redirected to Wow6432Node.

You can bypass WOW64 registry redirection if necessary, but you shouldn't do this arbitrarily, only if there is a specific reason. If WOW64 redirection worries you, the only good alternative is to provide a 64-bit version of your program.

Harry Johnston
  • 35,639
  • 6
  • 68
  • 158
  • 1
    Right... Wow6432Node is the right place for listing uninstallers for 32-bit software. – Ben Voigt Jun 24 '12 at 20:04
  • Many thanks. Great answer. WOW64 registry redirection doesn't bother me per se - I just wanted to be told it was the "right thing", and not just an avoidable fix-up like VirtualStore. – Jeff G Jun 25 '12 at 03:00
-1

This is a very "BAD THING" ! Microsoft solves a security problem by hiding thing at another place ! I've created a programm to ask the user for some additional parameters (language, directory for lessons) during installation of the app. I tested the programm profoundly, and the registry entries were made perfectly. However during setup the entries were hidden at some strange place! If Microsoft wants to redirect these enties it should at least be some option to be set. Never hide things, and think they will not notice, because it's transparant. Doing this properly would involve an option to be set, so users are aware of the redirection !

  • 1
    Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Jan 31 '22 at 09:36