[imp] Decrypt SMIME Mails automatically (without 2 "clicks")
Harakiri
harakiri_23 at yahoo.com
Thu Jan 19 09:58:21 PST 2006
Hi,
if you want to open an encrypted message (i.e. from
inbox) at first only the information is displayed
("encrypted message - click here to view") - this is
rather annoying because you have to click two times
on each encrypted message to see its content and then
the content is rendered rather ugly (white background
with no original headers).
I do know that the reason for this is propably that
normally you would not download the whole message to
view the message - but for smime.p7m messages you
actually have to download the full content (actually
its only 1 BodyPart with the attachment p7m)...
Normally you will always download the first bodypart -
but only if it is text (i guess thats how IMP does it)
- but it would be a good idea to also download the
first bodypart when it is SMIME encrypted and
automatically decrypt the email and show it to the
user... since the passphrase and private key is
already in the session (after entering the password
once at least) it should be no problem.
Is it possible that this will be implemented ? If i
want to look at it for myself - where should i start ?
/lib/MIME/Viewer/partial.php ? or imp/message.php ?
I guess it should be something like this :
// pseudocode REALLY ugly
message = getMessageHeaderInformationFromIMAP();
headers = message.getAllContentHeaders();
if ( _firstBodyPartHeader(isSMIMEEncrypted) ) {
// converts bodypart to original mime message
message = decryptSMIME(
message->fetchFirstBodyFromIMAP() )
}
// render message normally
message.getText()
message.getAttachments()
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
More information about the imp
mailing list