After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 630295 - Inline GPG encrypted message is not always recognized
Inline GPG encrypted message is not always recognized
Status: RESOLVED FIXED
Product: evolution
Classification: Applications
Component: Mailer
2.30.x (obsolete)
Other Linux
: Normal normal
: ---
Assigned To: evolution-mail-maintainers
Evolution QA team
: 613075 615419 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2010-09-21 21:31 UTC by Paul Menzel
Modified: 2010-12-13 12:13 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
evo patch (1.17 KB, patch)
2010-10-05 11:55 UTC, Milan Crha
committed Details | Review

Description Paul Menzel 2010-09-21 21:31:55 UTC
I received a GPG encrypted and signed message which is not decoded by Evolution.

The following is displayed.

	-----BEGIN PGP MESSAGE-----
	Charset: UTF-8
	Version: GnuPG v2.0.14 (MingW32)

	[encrypted things]

	-----END PGP MESSAGE-----

The dialogue to enter the passphrase is not displayed. Entering my passphrase for another encrypted message does not change anything either.

Saving this section to a file and decrypting it with `gpg --decrypt` works as expected.

The strange thing is that another GPG encrypted and signed message from the same person is displayed correctly. I compared the message source and could not find any difference in the message header besides of course the subject, date, message id and so on. But this message is even in the same thread as the working messages.

	[…]
	User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; de; rv:1.9.2.9)
	 Gecko/20100915 Thunderbird/3.1.4
	MIME-Version: 1.0
	To: […]
	Subject: […]
	References: […]
	
	In-Reply-To: <…>
	X-Enigmail-Version: 1.1.1
	Content-Type: text/plain; charset=UTF-8
	Sender: […]
	X-Sender: […]
	X-Provags-ID: […]
	Content-Transfer-Encoding: quoted-printable
	X-Evolution-Source: […]
	
	-----BEGIN PGP MESSAGE-----
	Charset: UTF-8
	Version: GnuPG v2.0.14 (MingW32)
	
	[…]
	
	-----END PGP MESSAGE-----

So far this just happened with one message. I have no idea how to proceed to debug this. I appreciate any suggestion.
Comment 1 Milan Crha 2010-09-27 19:06:46 UTC
Thanks for a bug report. What is your exact evolution and evolution-data-server version please? I'm asking because I'm wondering whether it can be related to bug #531912, which was fixed in time for 2.30.2.

With respect of debugging, maybe try to save the "bad" message to a file and then import it to On This Computer/Inbox or elsewhere under On This Computer, and check whether it'll be still non-functioning.
Comment 2 Paul Menzel 2010-09-27 19:40:35 UTC
(In reply to comment #1)
> Thanks for a bug report. What is your exact evolution and evolution-data-server
> version please? I'm asking because I'm wondering whether it can be related to
> bug #531912, which was fixed in time for 2.30.2.

I am sorry. I am using the versions in Debian Sid/unstable [1][2].

    evolution 2.30.3-2
    evolution-data-server 2.30.3-2 

> With respect of debugging, maybe try to save the "bad" message to a file and
> then import it to On This Computer/Inbox or elsewhere under On This Computer,
> and check whether it'll be still non-functioning.

I saved it to mbox and imported this to Computer/Inbox. It is still malfunctioning.


[1] http://packages.debian.org/sid/evolution
[2] http://packages.debian.org/sid/evolution-data-server
Comment 3 Milan Crha 2010-09-29 07:06:02 UTC
Could you upload here the offending message for testing, please? You can remove/replace everything sensitive, like server names, email addresses from there, even the body between BEGIN and END PGP MESSAGE can be mangled, as the preview panel will claim it was unable to decrypt it anyway.
Comment 4 Milan Crha 2010-09-29 09:38:30 UTC
Thanks for the test message, I received it and evolution really doesn't recognize inline PGP on it for some reason. I'll investigate more soon.
Comment 5 Milan Crha 2010-10-05 11:55:47 UTC
Created attachment 171757 [details] [review]
evo patch

for evolution;

This is a very nice bug. Your message exhibits a very nice thing:
The EMInlineFilter properly recognized the "-----BEGIN PGP MESSAGE-----" line, but because the CamelMimeFilter parses messages in junks of 4096 bytes, and your message is 4098 bytes long (two bytes more), then the ending line for the PGP message "-----END PGP MESSAGE-----" was divided into two chunks, the beginning of it without the last two dashes, and those two dashes in the second chunk, thus the inline parser didn't recognize the ending line and behaved like when no PGP message was included in the email.

Backing up the last line and continuing with it when the next chunk is received is fixing this bug.
Comment 6 Milan Crha 2010-10-05 12:00:59 UTC
Created commit a2b2b88 in evo master (2.91.1+)
Created commit 36abdbd in evo gnome-2-32 (2.32.1+)
Comment 7 Yves-Alexis Perez 2010-10-07 10:29:27 UTC
*** Bug 613075 has been marked as a duplicate of this bug. ***
Comment 8 Paul Menzel 2010-10-07 11:00:09 UTC
This is #599403 in the Debian BTS [1].

[1] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=599403
Comment 9 Milan Crha 2010-12-13 12:13:48 UTC
*** Bug 615419 has been marked as a duplicate of this bug. ***