Page MenuHome GnuPG

notepad: Clipboard and filesystem integration
Open, LowPublic

Description

@alexk proposed that we add some integration with the clipboard and/or filesystem

For the clipboard:

  • proposing to the user to copy the result to their clipboard might save them some clicks
  • Fill the notepad from clipboard content

For the file system:

  • Fill the notepad from a file. Advantage is that the decrypted content doesn't end up in the filesystem but only in the notepad

Event Timeline

Note that Kleopatra already has clipboard integration via its tray icon, i.e. you can directly sign/encrypt/decrypt/import the clipboard content from there. Unfortunately, it uses a complete different UI for selecting the recipients. Lots of room for improvement/consolidation.

ebo edited projects, added gpd5x; removed Restricted Project.Oct 30 2024, 4:20 PM

Ctrl+A + Ctrl+C to copy to clipboard and Ctrl+V do paste isn't exactly super complicated for people who know how to use the clipboard. -> Low

The file system integration is orthogonal to the clipboard changes. I'd prefer a separate ticket.

Additionally permanently watching the clipboard for changes can cause some password managers to detect an "attack". As it is discoverable which application accesses the clipboard on windows we had the case where a password manager would not work when Kleopatras clipboard watcher was running. T6642

Since the decrypt / verify clipboard and sign/encrypt clipboard actions can be useful, maybe a good compromise would be to bring up the notepad as a result view and for certificate selection.

Yes, automatic scanning of the clipboard is not good. I withdraw the idea.

Even if CTRL-A/X/V are not complex, ‘Copy-All’ and ‘Paste’ buttons would be practical for mouse users.

In T7362#195689, @alexk wrote:

Yes, automatic scanning of the clipboard is not good. I withdraw the idea.

Maybe a command line options for decrypt verify could be helpful? "kleopatra --decrypt-clipboard" Which by default would then decrypt/verify the clipboard contents and put the result in the clipboard if the option --daemon is additionally used. Otherwise without --deamon or if the signature was not valiid how the notepad as a result view?
I noticed that the current clipboard actions are not accessible through the shortcut menu inside of kleopatra and also not through KDE Global shortcuts. With such a command line switch users would be able though to add a shortcut in platform independent way.

For the URL usecase I mentioned this would allow the user to just select the encrypted message, hit a keyboard combination and then paste a decrypted and verified login URL.