Bug 99089 - Cannot send inline OpenPGP-signed messages
Summary: Cannot send inline OpenPGP-signed messages
Status: RESOLVED FIXED
Alias: None
Product: kmail
Classification: Applications
Component: encryption (show other bugs)
Version: SVN (3.5 branch)
Platform: Compiled Sources Linux
: NOR normal (vote)
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
: 106837 (view as bug list)
Depends on:
Blocks:
 
Reported: 2005-02-11 03:05 UTC by Thiago Macieira
Modified: 2007-09-14 12:17 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Attempt at fixing the proble (592 bytes, patch)
2005-06-25 23:54 UTC, Thiago Macieira
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Thiago Macieira 2005-02-11 03:05:28 UTC
This has been going on since my build dated 20050104. I cannot send emails  
with inline PGP signing. No matter what my choice in the dropdown list is, the 
message is always sent using OpenPGP/MIME (that is, any choice except the 
S/MIME ones). 
 
Unfortunately, some mailing lists will not accept multipart/signed emails and 
I would rather send them signed if possible. 
 
I had been worried that pgpType was at fault here, since I had changed that 
value manually a long time ago. However, seeing the fix that went in for Bug 
#92619 making libkpgp not use that config key anymore, I had hoped my problem 
would be solved. 
 
It hasn't. 
 
Is there any other config you may want me to check? I am rebuilding kdepim 
right now with --enable-debug.
Comment 1 David Faure 2005-02-11 14:11:32 UTC
On Friday 11 February 2005 03:05, Thiago Macieira wrote:
> No matter what my choice in the dropdown list is, the 
> message is always sent using OpenPGP/MIME

Did you check for per-recipient crypto preference (in kaddressbook)? This overrides the toolbar choices.

> I had been worried that pgpType was at fault here
No - that problem was for the (not completely ported) *reader* code. 
The sending of encrypted/signed messages is completely independent from that.

Either there's a bug in keyresolver.cpp, or you have a per-contact crypto preference.

Comment 2 Thiago Macieira 2005-02-12 00:06:51 UTC
> Did you check for per-recipient crypto preference (in kaddressbook)? This
> overrides the toolbar choices.

Yes. There are no addressbook-contacts for those recipients.

I have tried creating a contact, selecting inline OpenPGP as the only allowed crypto protocol and sending an email to that address.

OpenPGP/MIME was used.
Comment 3 stomarti 2005-03-20 13:12:08 UTC
Using Kmail 1.8 I have a similar problem. Without having the contact in kadressbook and choosing inline PGP signing results in a multipart/signed email. Sending an email to somebody in the kadressbook the same happens, if I allow inline OpenPGP and OpenPGP/MIME in kadressbook.

> I have tried creating a contact, selecting inline OpenPGP as the only
> allowed crypto protocol and sending an email to that address.
> OpenPGP/MIME was used.

Contrary to this, I do get an inline-signed email, when I only allow inline OpenPGP in kadressbook.
Comment 4 Ian 2005-03-29 00:57:02 UTC
Using Kmail 1.8, I am seeing similar behaviour.  If I have an email address in kaddressbook, I can set inline OpenPGP and the mail will be signed in-line.

However, if the email address is not in kaddressbook, the signature and mail are sent as attachments even when Inline OpenPGP (deprecated) is selected.
Comment 5 Thiago Macieira 2005-06-08 04:39:57 UTC
*** Bug 106837 has been marked as a duplicate of this bug. ***
Comment 6 Thiago Macieira 2005-06-25 23:34:05 UTC
I think I have found the problem.

Kleo::KeyResolver::resolveSigningKeysForSigningOnly (kdepim/kmail/keyresolver.cpp) does not check for the option selected in the drop-down box in the toolbar. Instead, it simply relies on what the recipients' configuration is in kaddressbook.

It should be modified to try the chosen option only, unless that option is "Any".

The same is probably true for resolveSigningKeysFroEncryption and resolveEncryptionKeys, but I didn't analyse them.
Comment 7 Thiago Macieira 2005-06-25 23:54:32 UTC
Created attachment 11582 [details]
Attempt at fixing the proble

This simple two-line patch has fixed the problem for me.
Comment 8 Till Adam 2005-06-26 12:58:55 UTC
SVN commit 429061 by tilladam:

Fix by Thiago Macieira <thiago@kde.org> for ingored signature type
selections. 

Marc, this seems correct to me. How about
resolveSigningKeysFroEncryption and resolveEncryptionKeys? Do they have
the same problem?

BUG: 99089
CCMAIL: marc@kdab.net


 M  +4 -2      keyresolver.cpp  


--- trunk/KDE/kdepim/kmail/keyresolver.cpp #429060:429061
@@ -2,7 +2,7 @@
     keyresolver.cpp
 
     This file is part of libkleopatra, the KDE keymanagement library
-    Copyright (c) 2004 Klar
Comment 9 Michael Nottebrock 2005-11-10 07:29:52 UTC
It would have been *really* nice if somebody had remembered to commit this to branches/3.4 (the /bugfix/ branch back at that time ...) as well. Probably too late now.