Hello,
First I need to say I’m new with gpg so maybe I miss something somewhere in my research.
Help me understand something :
every where on internet we can read, SHA1 and AES128 is deprecated, and that since a long time now. We can also read that AES256 and SHA512 are the actual cipcher and digest all should use for security reason, ok until here I can understand.
So I modify gpg.conf to don’t use SHA1 and AES128 and always prefer AES256 and SHA512 I also set S2K to use SHA512 and AES256. So here my settings should be OK, let’s create a keypair with gpg --full-generate-key…
My key is finally created it’s a RSA 4096 keypair great now I want to know if my settings are applied correctly to that keypair
So I export public and private key and execute PGPDUMP on both.
In the output of the private key surprise me a bit I obtain this:
Secret Key Packet
Pub alg - RSA Encrypt or Sign(pub 1)
RSA n(4096 bits) - ...
RSA e(17 bits) - ...
Sym alg - AES with 128-bit key(sym 7)
Iterated and salted string-to-key(s2k 3):
Hash alg - SHA1(hash 2)
Why the S2K hash use SHA1 and sym-alg use AES128 even with gpg.conf set to not use it and why gpg use these algo are deprecated???
why gpg use the wrong algo cipher and digest for my secret key?
why gpg finally use the right algo in Signature Packet on the same private key(yes in signature packet I can read SHA512 and AES256 as prefered order
why the public key of that same gpg key use AES256 and SHA512 if the private use SHA1 and AES128 ???
and last question how can I “force” gpg to use the algo I choose on the private key when generate a new keypair?
I hope my question is understandable English is not my first language so don’t hesitate to ask me more details or whatever you need to understand what I ask for thanks for those who will respond to me =)