I'm trying to encrypt a file using AES algo and sign it using my private key in GPG. The command I'm using is
gpg --encrypt --symmetric --cipher-algo aes256 --armor --sign input-file
It asks me for the symmetric key and then the passphrase to unlock my secret key for signing. Perfectly fine until now. It further asks the public key of the recipient and if I do not enter any, the whole step fails. Since I'm using symmetric encryption, why do i still need to provide the recipients identity. That should have been asked when I use only the --encrypt
option.
The man page of gpg
states that when using --symmetric
option, the recipient could decrypt the contents using either the symmetric key or his private key. This sounds like there is an option here. In this case, if i do not provide any recipients identity, the process should ignore that part and should proceed. But the whole process fails.
Someone please clarify.