From kmail-devel Thu Oct 24 23:36:02 2002 From: Marc Mutz Date: Thu, 24 Oct 2002 23:36:02 +0000 To: kmail-devel Subject: Re: KMail OpenPGP/MIME HOWTO X-MARC-Message: https://marc.info/?l=kmail-devel&m=103550377209414 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--Boundary-03=_lPIu9pAV/uS6+Y0" --Boundary-03=_lPIu9pAV/uS6+Y0 Content-Type: multipart/mixed; boundary="Boundary-01=_kPIu9T4sZeQu3m3" Content-Transfer-Encoding: 7bit Content-Description: signed data Content-Disposition: inline --Boundary-01=_kPIu9T4sZeQu3m3 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Description: body text Content-Disposition: inline On Tuesday 22 October 2002 19:35, Daniel Naber wrote: > On Tuesday 22 October 2002 14:17, Marc Mutz wrote: > > @Daniel Naber > > Can you add this to the KMail HP (with all the KDE CI added)? > > Sure, if you attach it :-) Arrgh ;-) Marc -- 'When you see the ping of death, duck and cover.' -- Bruce Schneier, Crypto-Gram Oct 2002 --Boundary-01=_kPIu9T4sZeQu3m3 Content-Type: text/html; charset="us-ascii"; name="kmail-pgpmime-howto.html" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="kmail-pgpmime-howto.html" KMail OpenPGP/MIME HOWTO

Using OpenPGP/MIME with KMail

KMail has long been criticized for it's lack of "compatible" OpenPGP/MIME support. Not any longer! KMail 1.5 and the Ägypten Project make OpenPGP/MIME available to KMail users.

Prerequisites

You need KDE 3.1 (a Beta version suffices) and GnuPG 1.0.7 or 1.2.x. You should be able to get those in pre-compiled form from your distribution vendor.

Installing Ägypten

You'll find all the gory details on the development page of the Ägypten Project. Here, we concentrate on a minimal install that gives you only the OpenPGP part of Ägypten.

First, get the following packages (min. version in (parantheses))

  1. libgcrypt (>= 1.1.10)
  2. libksba (>= 0.4.5)
  3. newpg (>= 0.9.2)
  4. gpgme 0.3.x (>= 0.3.12)
  5. pinentry (>= 0.6.5)
and unpack them in a directory with tar xfz file.tar.gz.

Now, compile and install them (note that you need much stuff here only to make newpg's configure script happy):

cd libgcrypt && ./configure --enable-maintainer-mode && make && su -c "make install"
cd libksba && ./configure --enable-maintainer-mode && make && su -c "make install"
cd newpg  && ./configure --enable-maintainer-mode && make && cd gpg-agent && su -c "make install"
cd gpgme  && ./configure --enable-maintainer-mode --enable-gpgmeplug && make && su -c "make install"
cd pinentry && ./configure --enable-maintainer-mode && make && su -c "make install"

That's it!

Configure GnuPG to use gpg-agent

If you updated gpg from 1.0.6 or earlier, please make sure to set your own key to ultimate trust yourself and run

gpg --rebuild-keydb-caches

Add this to your ~/.gnupg/option (GnuPG 1.0.7) or ~/.gnupg/gpg.conf (GnuPG 1.2.x):

use-agent

Add a file ~/.gnupg/gpg-agent.conf with the following contents:

pinentry-program /usr/local/bin/pinentry-gtk
no-grab
default-cache-ttl 1800
(replace the path to pinentry-gtk depending on the prefix you gave to the ./configure above). pinentry-qt might also work, but pinentry-gtk is confirmed to work.

Before using gpg, you need to start gpg-agent:

eval "$(gpg-agent --daemon)"
(gpg-agent outputs a little shell script that sets the environment variable GNUPG_AGENT_INFO). You may want to add this to your ~/.xsession so that all programs see the environment variable.

Configure KMail to use CryptPlugs

Make sure you can work with gpg on the command line (should use gpg-agent and pinentry-gtk).

Configure KMail's GnuPG support until it works for you (KMail from older betas will not be aware of gpg-agent running, so it will ask for a passphrase itself. Enter a bogus one and hit OK, then pinentry will come up to ask for the passphrase).

Start KMail, go to Settings->Configure Kmail->Security->Crypto Plugins and add the gpgme-openpgp.so plugin. Leave the update URL empty and set a name of OpenPGP.

You should now be able to choose the OpenPGP plugin for signing/encrypting in KMail's composer.

--Boundary-01=_kPIu9T4sZeQu3m3-- --Boundary-03=_lPIu9pAV/uS6+Y0 Content-Type: application/pgp-signature Content-Description: signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.0 (GNU/Linux) iD8DBQA9uIPl3oWD+L2/6DgRAuNUAJ9SGAiAgIVvIsajPVYPS2UirsSNrACgj/g+ cH2BYwK4dI07uBo+NU14Ma4= =kTdS -----END PGP SIGNATURE----- --Boundary-03=_lPIu9pAV/uS6+Y0-- _______________________________________________ KMail Developers mailing list kmail@mail.kde.org http://mail.kde.org/mailman/listinfo/kmail