Compression used in an encrypted message
roam at ringlet.net
Fri Mar 11 19:30:30 CET 2011
On Fri, Mar 11, 2011 at 12:50:26PM -0500, Avi wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA512
> Forgive my ignorance, but is there a way to take a given
> encrypted message/file and determine which compression algorithm
> was used (and which level)? I know how to set compression
> algorithm and level prefs, but I'm curious to see what others
> use, if possible.
If the file has been encrypted to you (or, more specifically, to
one of the secret keys currently accessible to you), then, yes, you
most probably can - "gpg --list-packets filename" should tell you
what compression algorithm has been used, then it's just a matter of
looking it up in RFC 4880 :)
If the message has been encrypted to someone else's key, then you
most probably won't be able to examine it - at least GnuPG does
the compression before the encryption, so that the information about
the compression algorithm used is contained within the encrypted data.
You may still give it a shot with --list-packets, but don't expect
too much :)
Hope that helps.
Peter Pentchev roam at ringlet.net roam at FreeBSD.org peter at packetscale.com
PGP key: http://people.FreeBSD.org/~roam/roam.key.asc
Key fingerprint FDBA FD79 C26F 3C51 C95E DF9E ED18 B68D 1619 4553
This sentence contains exactly threee erors.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 836 bytes
Desc: Digital signature
More information about the Gnupg-users