Client: When uninstalling the client, the config file is preserved

Created on 29 Nov 2016  Â·  28Comments  Â·  Source: owncloud/client

After uninstalling/purging the client in any OS, owncloud.cfg file is preserved with all the accounts logged and folder sync connections created. Also, the account credentials, stored in the keychain/Password manager are kept there.

The most common scenario I can think of is the one where the sync client is uninstalled and reinstalled in the future: all the previous data is reused.

Proposed behavior

The user is prompted with the option to log out and remove the account(s) details and the password from the system.

Actual behavior

owncloud.cfg is preserved with the account information, if the user hasn't previously logged out in the account view, the sessions are preserved.

I agree that the local folders synced should stay there (or even it could ask the user what to do with them) but I believe it's unusual to keep user data after uninstalling.

Discussion Enhancement packaging

Most helpful comment

Here are instructions to remove it

https://doc.owncloud.com/desktop/removing.html

I am all for an automated solution.

All 28 comments

@SamuAlfageme
For Windows, there is as far I see it no owncloud.cfg file...
It would be great to have for Windows a clean uninstall possibility which is in the handling imho somewhat different to *unix.

BTW, last update before my FR, was a year ago. The current behaviour is a serious security issue!

@mmattel there's always a config file - located in %LOCALAPPDATA%\ownCloud\owncloud.cfg on Windows (ref. https://doc.owncloud.org/desktop/2.3/advancedusage.html#configuration-file) And yeah, clean uninstall is something I've craved for more than once before. Until this is implemented/planned you can take my wipe_config.bat

::  Remove user data from an ownCloud client intallation:
::    usage: wipe_config.bat APPLICATION_SHORTNAME USER URL

:: Delete .cfg, cookies and sync-exclude.lst
rd %LOCALAPPDATA%\%1\ /s/qz

:: To remove the credentials from the Windows Credential Store 
:: provide the script will all the 'USER's to delete.
cmdkey /delete:%2:%3

@SamuAlfageme thanks.
Sorry for my stupid question, I am not a Windows programmer... but is this really a big deal to implement a checkmark for uninstalling and asking to delete the credentials/settings in Windows? The data can be deleted manually, but the settings...

The current behaviour is a serious security issue!

The password is stored in Windows Vault / Credential Manager which we consider secure :)

the pwd stored in an secured env is not the problem!
you uninstall the client, someone else can reinstall it later, wants to use his credentials and has access to your data!
this is a security issue !
(or do we need to uninstall the windows user first...)

@mmattel But your windows account should only be used by you.
But I agree with @SamuAlfageme and you, the uninstall should delete the credentials. I'm just saying it's not as unsecure as you think :-)

@guruz I am coming from the business side. If I tell a company admin respectively security departement about this, they will immediately drive this as P1. It is not about what we think it is not, but what they think it is. And this can be a show stopper. I could describe you a couple of real world scenarios and you would wonder how strict actions in companies can be. To stay alive, we must always consider enterprise environments (and selling to). Just my 2c

2.5.0 Win client will come as *.MSI installer. @dschmidt Could you take care for the Win platform? I don't now a common use case to preserve the file. (except https://github.com/owncloud/client/issues/5369) If necessary, MSI could have an option.

@SamuAlfageme @guruz What options do we have on the macOS and Linux platforms? I think there was a request to document uninstallation. Should be added there too.

The uninstaller is running as a system process, so we can remove all or no configs from all users. (Selection is possible but probably very hard and time consuming to do)

ask, and if yes remove them all.

@michaelstingl for

What options do we have on the macOS and Linux platforms?

  • On macOS we could move the .cfg inside the .app's bundle (so it also gets in the trash when the bundle is dragged there, something like we did for different reasons on https://github.com/owncloud/client/pull/6219). I need to check if updates will overwrite whole bundle contents (and config with it) or just update the right binaries/libs.
  • On Linux, we need to go design a script to run on uninstall, collecting all the items that would need cleanup and ideally, the package manager will take care of running it when the user requests removal.

We also have https://github.com/owncloud/client/pull/5805 unfinished.

I don't now a common use case to preserve the file.

On Windows, we first run the uninstaller before updating to a new version.

On macOS we could move the .cfg inside the .app's bundle

I've never heard of any app doing this, please don't do this if others don't do this. (also permission issue on multi user systems etc).

I've never heard of any app doing this, please don't do this if others don't do this.

👍 Then let's add instructions for macOS uninstall to the docs…

won't fix :-)
Desinstalling an app usually does not remove the config file

won't fix --> :-(
It is astonishing me to not delete the config based on a question during uninstallation ...

@mmattel it just doesn't make much sense. On a single user system, this could easily be implemented - on a multi user system, it seems like a terrible idea to loop through all users and delete their data. We can add documentation how to achieve that... but making it available through a single click doesn't sound like a good idea to me.

Yes, documenting is a good idea.
Adding a note as part of the post deinstallation what/where to do it (maybe referencing to the docs)
Adding a note in the documetation, needs separation by OS

Dec 2019 and this is still an issue for Desktop Client Windows (10) production version 2.6.0.

And I'm now very annoyed the option is still not available to remove config, directory/ies in uninstall dialog! Basically it feels like I'm left with someone's dogpile on my lawn.

@noxidsoft please check @dschmidt 's comment in https://github.com/owncloud/client/issues/5342#issuecomment-442398241 . Maybe you have better ideas, point to some documentation or something like this…

@noxidsoft please check @dschmidt 's comment in #5342 (comment) . Maybe you have better ideas, point to some documentation or something like this…

>> RD /S /Q C:\Users\Username\ownCloud

But, only does half the job as it still doesn't remove the visual folder reference in Explorers sidebar/context-menu.

Here are instructions to remove it

https://doc.owncloud.com/desktop/removing.html

I am all for an automated solution.

As I have noted more than a year ago, see comment https://github.com/owncloud/client/issues/5342#issuecomment-442358635, any app which installs should have a proper uninstallation with a question if you want to have full uninstall or partial keeping some settings...

Yep, I ended up working that out. Thanks for the link (:

I'm a bit confused why this issue is closed if it is not in fact resolved? This is an issue for me right now. I can't even locate the configuration file to delete, as the folders pointed at in this issue do not actually exist.

Because it's nothing we can reasonably solve.

We should not keep the explorer folder, I agree. But that's a separate issue.

As I already said: uninstalling the client is a system process and not bound to the user, so we can't know which files to remove.

@sid3windr Which folder are you looking for?

Was this page helpful?
0 / 5 - 0 ratings