Ayan George | 21 May 2012 19:20

nail and gnupg/pgp


Hi!

Do what degree have you guys been able to integrate gnupg/pgp with nail?
 Does anyone automatically sign, verify, encrypt, and decrypt messages?

-ayan

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
Martin Neitzel | 22 May 2012 12:29
Picon
Favicon

Re: nail and gnupg/pgp

> Do what degree have you guys been able to integrate gnupg/pgp with nail?
>  Does anyone automatically sign, verify, encrypt, and decrypt messages?

With pgp, the simplest use with nail is using the ascii-armor format
and piping the mail body from nail or the editor through the various
gnupg or whatever commands.  I do none of that automatically.

The tricky part is when people send you mails with detached pgp signatures
(MIME Content-Type: multipart/signed).  Before I was using nail but
Solaris or Linux mailx (non-MIME-aware), I had a "metamail" setup for all
MIME-related things to able to read what mutt-users occasionally sent me:

	~/.mailcap:
	multipart/encrypted;    gpg -d %s
	multipart/signed; gpg-sign-check %{boundary}

These metamail configs would roughly(!) translate into

	set pipe-multipart/encrypted="gpg -d %s"
	set pipe-multipart/signed="gpg-sign-check ??your-problem??"

With nail, I still pipe things through metamail even though nail
could probably somehow interface to the commands/scripts directly.
(It's just a nice, portable interface to deal with MIME horrors,
pluggable into different mailers/contexts.)

At any rate, I'll attach the gpg-sign-check and another script required
for that.  The "%{boundary}/$tmp[12]" vars are all due to the metamail
rules.  If you don't want to use metamail, I guess you should interface to
something like mime-defang.  Perhaps they are some starting point for you.
(Continue reading)


Gmane