preferred compression types with multiple recipients

David Shaw dshaw at jabberwocky.com
Wed May 24 14:01:07 CEST 2006


On Tue, May 23, 2006 at 10:09:35PM -0700, Jonathan Wellons wrote:
> Good day everyone,
> 
> How does gpg reconcile conflicting preferred compression types?  I've 
> switched mine to bzip2 to save space, but it occurs to me that it may 
> not be of much effect until a significant number of other people I 
> communicate with also switch from zlib.

Not switch from zlib, necessarily, but at least advertise they have
the ability to handle bzip2 also.

> My understanding of encrypted mail to multiple recipients is that
> 	* a session key is generated
> 	* the message is encrypted symmetrically with the session key
> 	* the session key is encrypted asymmetrically with each recipient's 
> public key.
> 
> It seems that a message is only compressed once.

That is correct.  Conflicting compression algorithms are handled the
same way conflicting cipher algorithms are:

 1) Make a list of all compression algorithms supported by all
    recipients.
 2) Add "uncompressed" to the list even if nobody requested it (by
    definition, all OpenPGP implementations can handle uncompressed
    data).
 3) We now have a list of algorithms, any of which are usable
    (i.e. compatible with everyone).  If
    --personal-compress-preferences is set, try those algorithms in
    order.  If it isn't set, walk the list supplied by the last user.
 4) If we still don't have an algorithm, use "uncompressed".

The cipher selection algorithm is essentially the same if you
substitute "3DES" for "uncompressed".

David



More information about the Gnupg-users mailing list