Page MenuHome GnuPG

Improved Sign/Encrypt/Decrypt/Verify from clipboard
Open, NormalPublic

Description

In its system tray item, kleopatra has actions for doing cryptograhpic operations with the clipboard as data.

  • "Decrypt/Verify": UI-wise, this seems mostly fine. It opens a dialog showing the results in the same way as when decrypting/verifying a file. The only problem here is that it shows a message "Successfully decrypted and verified 'Clipboard contents' as 'Clipboard'", which doesn't really make sense. We need similar special logic here to what is done for the notepad
  • "S/MIME-Sign", "OpenPGP-Sign", and "Encrypt": These use dialogs that look very different from those used for the notepad and for signing/encrypting files. These actions should be unified into a single Sign/Encrypt action, which uses the recipient/signer selection component as in the notepad (with the same limitations of allowing either s/mime or pgp and for s/mime, either encrypting or signing). Since it needs to be wrapped in a widget, it might make sense to reuse the entire file encryption/signing dialog with some options for removing irrelevant things from the UI

Event Timeline

TobiasFella created this task.

I'm not sure what we need for the clipboard that's not already in the SignEncryptWidget. I think the SignEncryptFilesDialog mostly adds functionality for the file handling. It might make more sense to try to share code that's implemented for the Notepad and then wrap this in a simple dialog.

ikloecker changed the task status from Open to Testing.Tue, Jan 13, 10:11 AM
ikloecker moved this task from Backlog to QA on the gpd5x board.

Should be ready for testing. This is available in 5.0.0-beta479.

timegrid changed the task status from Testing to Open.EditedWed, Jan 14, 12:02 PM
timegrid moved this task from QA to WIP on the gpd5x board.
timegrid added a subscriber: timegrid.

Mostly looks good to me on gpg4win-5.0.0-beta479 @ win11.

Issues found:

  • If pgp is preselected, the "Sign..." operation will also check "Encrypt for others":
  • If pgp is preselected and the "Sign..." operation is selected, switching to "S/MIME" will result in only "Encrypt for others" checked (probably connected to the last issue):
  • if smime is preselected, the "Sign/Encrypt..." operation will not check "Encrypt for others":
  • The "Finish" button in the "Sign/Encrypt" dialog turns to "Sign/Encrypt" sometimes after successful execution:
  • The verification message for signed only clipboard is: Verified ‘Clipboard’ with signature in ‘Clipboard contents’., which is better than before but still not makes that much sense. The other messages are fine:
    • signed/encrypted clipboard: Successfully decrypted and verified the clipboard
    • encrypted clipboard: Successfully decrypted the clipboard

Done:

  • Certificate Import
  • Encrypt...
  • Sign...
  • Sign/Encrypt...
    • pgp preselected
    • smime preselected (checking "Sign as" deactivates both "Encrypt for" correctly)
  • Decrypt/Verify...

Notes:

  • The "Encrypt..." and "Sign..." operations might not be needed anymore now, that "Sign/Encrypt ..." is available?
  • The "Decrypt/Verify" dialog
    • still looks quite different (blue font on white background)
    • the verification feedback (most important part) is cut
    • the arrow on top suggests, that "going back" somewhere is possible

Notes:

  • The "Encrypt..." and "Sign..." operations might not be needed anymore now, that "Sign/Encrypt ..." is available?

Those operations are explicitly there so that one doesn't have to uncheck useless checkboxes if one knows beforehand that one wants to sign only (or encrypt only). Especially, with Sign ideally one can simply press Return without changing anything in the dialog. (Pity that this is currently blocked by the bug that Encrypt for others is checked.)

  • The "Decrypt/Verify" dialog
    • still looks quite different (blue font on white background)
    • the verification feedback (most important part) is cut
    • the arrow on top suggests, that "going back" somewhere is possible

Changing this wasn't part of this ticket. But, yes, it should be unified with the other decrypt/verify operations.