You are here

[Fixed] PortableApps.com Installer could result in deleted files if user manually types an incorrect install location

6 posts / 0 new
Last post
romulous
Offline
Last seen: 6 years 8 months ago
Joined: 2009-10-23 03:58
[Fixed] PortableApps.com Installer could result in deleted files if user manually types an incorrect install location

I know this is my fault for not having a backup of the files, but I wanted to just warn people to be careful with the PAF installers, as they wipe a folder before they actually install the app, as I have just found out to my cost.

I downloaded the Java Portable installer, and ran it. It detected a PAF thumbdrive in my PC, and wanted to install there. I changed the install path to a folder on my C drive. Stupidly, I told it to install to the root of that folder, and not a new folder (such as Java or similar) that the installer could create inside that folder.

After the installation, I opened the folder in my file manager, to find that the installer had wiped every file and folder I had in that folder. Yes, Java was installed there, but I am a bit upset I have lost the data in that folder.

So, fair warning to everyone - if you're installing to anything other than the PortableApps folder on your thumb drive, be very careful about what you type in the path to install field. I can only imagine the carnage had I typed in C:\ or similar...

John T. Haller
John T. Haller's picture
Online
Last seen: 1 min 5 sec ago
AdminDeveloperModeratorTranslator
Joined: 2005-11-28 22:21
Manually Type Without Verifying + Plugin Installer

Sorry to hear about that. Sad If you manually type in a path, the installer (like most installers) assumes you know what you are doing. If you select a location using browse, the installer will append the directory it's going to actually install to (Java in this case) to the location you select. Note that only plugin installers will wipe everything in the directory you select whereas normal PAF installers will only wipe the App and Other sub-directories as well as any EXEs and help.html in the base directory.

You should NEVER select a path to install to that has other stuff in it for any app in any installer EVER (portable, local or anything in between). Even Mozilla Firefox had a long-standing bug that if you installed directly to PROGRAMFILES, it would remove all your apps when you uninstalled.

As it's never come up before and our installers have worked this way since we started using them (years now), I'd wager that it's rare that a user triggers it. You may even be the first, though I don't think congratulations are in order, sadly. I'll look into if there is some way to detect this scenario and warn users if there's other stuff already in a directory they manually type in as well.

Sometimes, the impossible can become possible, if you're awesome!

romulous
Offline
Last seen: 6 years 8 months ago
Joined: 2009-10-23 03:58
About ProgramFiles

I didn't append the Java folder to the path as it is late and I'm tired - typing was quicker than browsing a deep folder structure and I never for a moment expected it would wipe the folder. Still, my fault - even though there should be a clear warning that the installer will wipe the folder if you proceed.

So, with ProgramFiles, that means you can't use Program Files for any program, as any uninstaller may wipe the entire folder? That would mean that you would have to install every program onto your system into a totally new folder, as you could never be sure if the uninstaller will wipe everything else. Take that to the extreme, and you would have to use a different drive for every program, as C: will obviously have programs already on it, even if you use a separate folder.

I used to have a sig...until one of the mods ate it

John T. Haller
John T. Haller's picture
Online
Last seen: 1 min 5 sec ago
AdminDeveloperModeratorTranslator
Joined: 2005-11-28 22:21
Program Files

The Mozilla Firefox (local) installer/uninstaller bug was triggered if a user manually typed in C:\Program Files as their install location. Firefox would install there (C:\Program Files\firefox.exe) and work without issue. But, when you uninstalled, it would remove everything within C:\Program Files. ALL your software. This was probably back in 2004 or 2005.

So, yes, you need to be absolutely sure that you install every app to its own directory and that no apps share directory structures (like install app2 into a subdirectory of where you install app1) in every scenario. Lots of apps 'uninstall' just by wiping the folder they are installed in.

Sometimes, the impossible can become possible, if you're awesome!

romulous
Offline
Last seen: 6 years 8 months ago
Joined: 2009-10-23 03:58
Thanks

Thanks for clarifying John, I had misunderstood what you posted originally. I'm clear with it now though - installing into sub-folders is fine, installing into the root folder is risky.

I used to have a sig...until one of the mods ate it

John T. Haller
John T. Haller's picture
Online
Last seen: 1 min 5 sec ago
AdminDeveloperModeratorTranslator
Joined: 2005-11-28 22:21
Fixed in PortableApps.com Installer 3.3.1, all plugins updated

I added specific detection for this edge case in PortableApps.com Installer 3.3.1 which is now available: https://portableapps.com/news/2016-06-11--portableapps.com-installer-3.3...

The CommonFiles plugin installers that are affected by this issue (Ghostscript, GPG, jPortable) have all been repackaged with this updated installer to ensure the edge case is checked for and warned: https://portableapps.com/news/2016-06-11--installers-for-ghostscript-gpg...

Note that existing users of the plugins do not need to update as no plugin files within are being updated, just an updated version of the installer.

Sometimes, the impossible can become possible, if you're awesome!

Log in or register to post comments