Page MenuHome GnuPG

GPGOL Moving mails is not possible if the decrypted / verified content is loaded
Closed, ResolvedPublic

Description

I have installed GPG4WIN 3.0.0 (GPGOL 2.0.1) on 6.10.2017. I used earlier version before. When I receive a signed email from a colleague I see that the mail is security level 4 because it is accepted by myself (no official key)

The problem is: When I try to move the mail it won't work. It just stays in the Inbox (removiong works, though).

GPG4OL runs in an company environment with a Zimbra collaboration server backend (MAPI). We have different Outlook clients, I use Outlook 2010 with newest updates on Win10/x64 (also up-to-date).

When I activate logging I see the following trace when clicking on an signed mail from a colleague (clicking on it for the second time):

`wagner@winwagner MINGW32 /C/TEMP
$ tail -f gpgol.log
[...]
11:10:16/3148/windowmessages.cpp:gpgol_window_proc: Recieved user msg: 1
11:10:16/3148/windowmessages.cpp:gpgol_window_proc: Invalidating UI
11:10:16/3148/gpgoladdin.cpp:gpgoladdin_invalidate_ui: Invalidating ribbon: 149EE358
11:10:16/3148/windowmessages.cpp:gpgol_window_proc: Invalidation done
11:10:16/3148/gpgoladdin.cpp:GetIDsOfNames: GetIDsOfNames for: getSigLabel
11:10:16/3148/gpgoladdin.cpp:Invoke: enter with dispid: 1b
11:10:16/3148/ribbon-callbacks.cpp:getContext: contextObj: _Explorer
11:10:16/3148/oomhelp.cpp:get_unique_id: Found uid '8264760c-d457-411f-b083-ad15efae30c0' for '02F45CD0'
11:10:16/3148/mail.cpp:level_4_check: classified SebXXXXXX WaXXXX <SebXXXXXX .WaXXXX@XXXXXXXXXXXXXX> as ultimate because it was signed by uid SebXXXXXX WaXXXX <SebXXXXXX.WaXXXX@XXXXXXXXXXXXXX> of key XXXXXXXXXXXX
11:10:16/3148/gpgoladdin.cpp:GetIDsOfNames: GetIDsOfNames for: btnSigstateLarge
11:10:16/3148/gpgoladdin.cpp:Invoke: enter with dispid: 1d
11:10:16/3148/ribbon-callbacks.cpp:getContext: contextObj: _Explorer
11:10:16/3148/oomhelp.cpp:get_unique_id: Found uid '8264760c-d457-411f-b083-ad15efae30c0' for '02F469B0'
11:10:16/3148/mail.cpp:level_4_check: classified SebXXXXXX WaXXXX <SebXXXXXX.WaXXXX@XXXXXXXXXXXXXX> as ultimate because it was signed by uid SebXXXXXX WaXXXX <SebXXXXXX.WaXXXX@XXXXXXXXXXXXXX> of key XXXXXXXXXXXXXX
11:10:16/3148/gpgoladdin.cpp:GetIDsOfNames: GetIDsOfNames for: getIsDetailsEnabled
11:10:16/3148/gpgoladdin.cpp:Invoke: enter with dispid: 13
11:10:16/3148/ribbon-callbacks.cpp:getContext: contextObj: _Explorer
11:10:16/3148/oomhelp.cpp:get_unique_id: Found uid '8264760c-d457-411f-b083-ad15efae30c0' for '02F45CD0'

`
When I am trying to move the mail to another folder /drag and drop or via context-menu) I get only (nothing more):
11:14:07/3148/mailitem-events.cpp:Invoke: Canceling write event.

Btw. Side-findings: when a logfile is set up in registry in a nonexisting directory, the plugin will crash and Outlook asks for disabeling it.

Details

Version
3.0.0

Event Timeline

I don't have access to this description. I used official, newest releases. I searched for this issue on the web, on the gpg4win page but did not find a solution. Is there any accessible information?

There is just another person experiencing the same problem with an Exchange based account on Win10pro x64, Outlook 2016 x86.

We will investigate in this issue.

Same here: I can confirm the bug. I can move an email, if i unselect it before an then use its context menu to move it.
This behaviour is already mentioned in the readme:
c:\Program Files (x86)\Gpg4win\share\gpg4win\README.en.txt

Here is the link to the wald report by John Mrkva:
https://wald.intevation.org/forum/forum.php?thread_id=1785&forum_id=21&group_id=11

Note that it is reported to work fine with beta299.

Hey @pkoevesdi, Gpg4win Version 3.0.1 was just released. Can you may download and install it and check if this issue still exists?

aheinecke added a project: Stalled.
aheinecke added a subscriber: aheinecke.

Hi, sorry this is a known issue. To quote the README:

It is not possible to modify mails (e.g. moving / flagging the mail)
while they are shown decrypted.
To workaround this: unselect the crypto mail and then make changes
through the right click context menu or move it with drag and drop.

There already was a bug for this T2883 but as that bug had some more communication I close it and keep this open for the Problem.

The problem with priority, I would give this the highest priority if I had any idea how to fix it in a manner that would not create worse problems (e.g. Plaintext leaks). For now I mark it as high but stalled. I already spent days experimenting on this problem. The big problem is that for the addon a move looks like a "Save" and we abort that save to avoid plaintext leaks. We could restore the Crypto Mail and then Save. But this would then lead to Sync problems as outlook would treat this mail as modified and would reupload that to the server. And when we do that when Outlook closes we get an endless sync loop. Sometimes Mails are broken etc. very bad :-/

So for now we have to live with the workaround from the README. Sorry.

Btw. Side-findings: when a logfile is set up in registry in a nonexisting directory, the plugin will crash and Outlook asks for disabeling it.

I can't reproduce this and the codepath looks ok. If you can reproduce this with Gpg4win 3.0.1 or a current gpgol please open a new issue about this. Thanks.

aheinecke renamed this task from GPGOL prevents Outlook 2010 to move mails from Inbox to another folder to GPGOL Moving mails is not possible if the decrypted / verified content is loaded.Mar 2 2018, 8:34 AM
aheinecke claimed this task.
aheinecke added a subscriber: cdeibert.

I got an Idea how to improve the situation here. But its very complex and might break Outlook even for unencrypted mails. So it's very invasive.

The idea is to replace the GUI Elements in Fluent UI that do not work with crypto mails (e.g. Setting a Flag or Moving a Mail) with our own implementation that mimics the behavior but works with crypto mail.

The problem is that I don't see a way to only replace the buttons for crypto mails, so we would globally affect all mails.

As I link this Ticket often when talking about this limitation. Here is a short animation to show what is meant by moving but not opening a mail:

You can close the message view if you press crtl while clicking on the mail.

A new Idea which I'll have to test:
Register an event handler for each folder in which a decrypted item is read. "Mailitem->parent" In this event handler listen to the beforeitemmove event. In that event then close the mail / discard the decrypted contents.

aheinecke changed the task status from Open to Testing.Jun 26 2018, 4:29 PM
aheinecke removed a project: Stalled.

The new idea worked! It is now possible to move mails even while their decrypted content is shown!

Gpg4win-3.1.3 was released. This issue can be closed. Hurray!