Page MenuHome GnuPG

Gpg4win 3.0.0 passphrase prompt
Closed, ResolvedPublic

Description

Though we provide gpg command with passphrase, it is prompting for passphrase every time.
Correct me if i have typed the command wrongly.
gpg --yes --always-trust -o %1.asc -saeu <email> -r <email> --batch --passphrase <passphrase> %1

the same command worked perfectly fine with GPG 2.3.3 version without passphrase prompt.

Details

Version
3.0.0

Event Timeline

i am sorry what is 8 digit challenger?

imagine a 00000000 and the last digit is ON 00000001

You're saying you did not typed wrong

"Correct me if i have typed"

I mean correct me if there is anything wrong in the command

werner renamed this task from GPG 3.0.0 passphrase prompt to Gpg4win 3.0.0 passphrase prompt.Oct 11 2017, 8:53 AM
werner added a project: gpg4win.

The private key, which is protected by a passphrase, is handled by gpg-agent. If you really don't want a passphrase (you have it in a script or the command line history anyway) I suggest to remove the passphrase from that key. Other options are

  • Increase the cache timeout (e.g. put "default-cache-ttl 3600" into gpg-agent.conf
  • Use gpg-preset-passphrase
  • Use the loopback feature by adding "--pinentry-mode loopback" to the gpg invocation

Thanks Werner for your suggestion, but what I am wondering is , in the previous versions "--passphrase" option would be used to provide passphrase in the command line and thus prevent prompt to get input from us every time. This helped to automate the encryption process. But now in 3.0.0 regardless of option, it keeps prompting for passphrase.

aheinecke claimed this task.
aheinecke added a subscriber: aheinecke.

Nagi: The third suggestion (adding "--pinentry-mode loopback" to your command) should work in that case.

As this question is frequently asked I noted this in the wiki: https://wiki.gnupg.org/TroubleShooting#Passphrase_on_the_command_line