Command line decryption/encryption

john doe johndoe65534 at
Thu Jun 24 09:41:17 CEST 2021

On 6/23/2021 3:31 PM, Terry Pierce wrote:
> Hi,
> Let me start off with I am totally new to GPG/Kleopatra.  We use different encryption tools here and one of our clients uses GPG.  I have already automated the processing of files using our tool and now have a need to build in a call to handle the decryption of these files.
> Looking online, I get the basic usage:  gpg -d myfile.dat.gpg
> Two questions:
> *         I don't see the GPG (GGP4win?) executable anywhere in the GPG4Win folders.  How do I generate it?

The executable is in the subdirectory 'bin' as 'gpg.exe'.

> *         Is there a way to pass any passphrase/key to it on the command line?

I would not do that but If I'm not mistaking you could use a file
descripter instead of specifying a password on the command line.

A better idea is to use a file that contains the passthrase if you need
to automate d/encryption or to use the agent.

John Doe

More information about the Gnupg-users mailing list