[Python-modules-commits] [python-gnupg] 01/08: use --pinentry-mode loopback for 2.1.x and later
Elena Grandi
valhalla-guest at moszumanska.debian.org
Sat Apr 8 06:44:43 UTC 2017
This is an automated email from the git hooks/post-receive script.
valhalla-guest pushed a commit to branch gpg2
in repository python-gnupg.
commit 9f3c15b8990970e91aa33779ba03a26fdd94b115
Author: Daniel Kahn Gillmor <dkg at fifthhorseman.net>
Date: Fri Feb 17 17:23:04 2017 -0500
use --pinentry-mode loopback for 2.1.x and later
If the user specifies an explicit passphrase rather than relying on
the gpg-agent for granting access, then we should try to pass the
passphrase to the agent. In 2.1.x, passing a passphrase to the agent
is done with "--pinentry-mode loopback", so we add that here.
---
gnupg.py | 2 ++
1 file changed, 2 insertions(+)
diff --git a/gnupg.py b/gnupg.py
index 2a08d96..0412531 100644
--- a/gnupg.py
+++ b/gnupg.py
@@ -783,6 +783,8 @@ class GPG(object):
cmd.extend(['--secret-keyring', no_quote(fn)])
if passphrase:
cmd.extend(['--batch', '--passphrase-fd', '0'])
+ if self.version >= (2,1):
+ cmd.extend(['--pinentry-mode', 'loopback'])
if self.use_agent: # pragma: no cover
cmd.append('--use-agent')
if self.options:
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/python-gnupg.git
More information about the Python-modules-commits
mailing list