default Cipher and Pubkey algo

Andrew McDonald andrew@mcdonald.org.uk
Wed Mar 7 23:22:12 2001


On Wed, Mar 07, 2001 at 10:24:28PM +0100, Georg Wilckens wrote:

>
> The thing I am wondering about is, how I can find out which cipher
> algorithm is selected in the preferences of a given key. Is this
> implemented yet?
You can find out the preferences from the edit-key command, e.g. -X-X- admcd@bifrons:~$ gpg --edit-key 0xf2deed36 Secret key is available. pub 1024D/F2DEED36 created: 1999-11-01 expires: never trust: -/u sub 2048g/FA04439F created: 1999-11-01 expires: never (1) Andrew McDonald <andrew@mcdonald.org.uk> (2) Andrew McDonald <A.D.McDonald@bcs.org.uk> Command> pref pub 1024D/F2DEED36 created: 1999-11-01 expires: never trust: -/u (1) Andrew McDonald <andrew@mcdonald.org.uk> S7 S10 S3 S4 H3 H2 Z2 Z1 (2) Andrew McDonald <A.D.McDonald@bcs.org.uk> S7 S10 S3 S4 H3 H2 Z2 Z1 -X-X- The 'S' is the symmetric cipher preference. 'H' is hash algorithm. 'Z' is compression. You can find out what the numbers mean from RFC2440. e.g. for the symmetric encryption: [actually this is the list from the RFC2440-bis Internet Draft - algorithm 10 isn't specified in RFC2440] -X-X- 9.2. Symmetric Key Algorithms ID Algorithm -- --------- 0 - Plaintext or unencrypted data 1 - IDEA [IDEA] 2 - Triple-DES (DES-EDE, [SCHNEIER] - 168 bit key derived from 192) 3 - CAST5 (128 bit key, as per RFC2144) 4 - Blowfish (128 bit key, 16 rounds) [BLOWFISH] 5 - SAFER-SK128 (13 rounds) [SAFER] 6 - Reserved for DES/SK [AES] 7 - AES with 128-bit key 8 - AES with 192-bit key 9 - AES with 256-bit key 10 - Twofish with 256-bit key [TWOFISH] 100 to 110 - Private/Experimental algorithm. -X-X- So, for my key shown above the preferences are AES, Twofish, CAST5, Blowfish. Triple-DES is also implied as being at the end of the list, since support for it is required by an OpenPGP implementation. Andrew -- Andrew McDonald E-mail: andrew@mcdonald.org.uk http://www.mcdonald.org.uk/andrew/