Linux gpg encryption and decryption

Hi everyone,
I’m trying to encrypt a file using the gpg encryption.
They gave me a passphrase and keys(public and private).
When trying to encrypt, the prompt asked for the User-Id. But I don’t have it.
How can I encrypt the file without use User-Id option or how can I get the User-id?


It’s the email associated with the key at generation time.

Have a look at:

  2. Creating gpg keys non-interactively · GitHub