When multiple versions of Firefox use the same uninstall path and command, how can I uninstall just the older version?
For security reasons, I've been asked to remove older versions of web browsers on our company computers. Some have multiple versions of the software installed. For instance Firefox 78.0.2 and 91.0.2 both show up in the software inventory in KACE. I created an uninstall script using the Windows Uninstaller Configuration Policy in the K1000 for v78.0.2 but when I run the script it uninstalls the more recent version instead.
The install script created by KACE appears to look for a specific registry uninstall key but if the key isn't found it creates it then runs the uninstaller, and since both versions have the same path to the helper.exe file, it uninstalls the newer one. I've attached a screenshot of the script settings. What do I need to change to make it uninstall the version I actually created the script for?
There are several ways to accomplish what you are trying to do. You could create a dynamic label that looks for old versions of Firefox and then run that script only against that label. However, this will require an inventory for it to update the label and then you have another label.
So I'm going to share another way to accomplish this, using the Script itself.
First, get rid of the Verify line in what you have now and instead add a Verify a file version is greater than or equal to:
For Directory: C:\Program Files\Mozilla Firefox
For File: firefox.exe
Equal to: 188.8.131.5205 (or whatever the current version is as of when you read this)
Then you can leave Remediation as-is.
Also note that you could also do "Verify a product version is greater than or equal to..." instead of the above. In that case you'd just use 91.0.2 for the equal to section. I pulled this information from the Details of the exe.
Hope this helps.