Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disable copy to clipboard after generate #667

Closed
samuelallan72 opened this issue Feb 23, 2018 · 2 comments
Closed

Disable copy to clipboard after generate #667

samuelallan72 opened this issue Feb 23, 2018 · 2 comments
Labels
help-wanted ux User experience / User Interface related

Comments

@samuelallan72
Copy link

The current behaviour (version 1.6.10) seems to be that it copies the generated password to the clipboard after generating it with gopass generate <name>. This behaviour is undesirable because it gets picked up and stored by most clipboard managers.

Some alternatives could be:

  • only copy to primary selection which most password managers don't (or can be configured to not) store.
  • disable copying to clipboard altogether and let the user manage it
@dominikschulz dominikschulz added help-wanted ux User experience / User Interface related labels Feb 23, 2018
@dominikschulz
Copy link
Member

Thanks for bringing this up.

Unfortunately I'm not sure what to do about this. There are different opinions about the default behavior wrt. the clipboard. Personally I don't really care too much, but I don't want to change this back and forth.

In #410 there was the justified request to not display the password by default and we implemented that.
If we now change it back the reporter will probably complain. If we neither copy it to the clipboard nor display it others (including me) will complain because it would be a lot more annoying.

Unfortunately copying the password to the primary area would only work on Linux and the libs we're currently using don't support it (see #477).

So actually I'm in favor of keeping the default as-is. You can either use the --print flag or we could consider adding a config option for this.

Also please note that gopass at least tries to erase the clipboard managers history.

@samuelallan72
Copy link
Author

samuelallan72 commented Feb 23, 2018

Agreed, I don't mind that as the default behaviour. But a configuration option would be nice (either flag or config), because at the moment, I'm going to end up with passwords sitting around in my plaintext clipboard manager's history (clipster) if I forget to manually delete them....

I'm also happy to work on a pr sometime. :)

kpitt pushed a commit to kpitt/gopass that referenced this issue Jul 21, 2022
* Fixes gopasspw#667 and correct a few details

This primarily adds the config option requested in gopasspw#667.
I've added back the notion or erroring in case of a show action on an
entry with only a password and the safe content option enabled
Also I've fixed the way the String() function of the StoreConfig forgot
to display the Notification value in its output.

* Adding tests for autoclip

* adding a clip flag back

* correcting an old copy-paste mistake

* trying to correct the problem

* Correcting the error caused by gopasspw#701
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help-wanted ux User experience / User Interface related
Projects
None yet
Development

No branches or pull requests

2 participants