From 55d80199c8ed723c7607a09d5e628c1d7949316f Mon Sep 17 00:00:00 2001 From: Michał Górny Date: Mon, 18 Dec 2017 16:51:45 +0100 Subject: openpgp: Disable scdaemon when running GnuPG --- gemato/openpgp.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/gemato/openpgp.py b/gemato/openpgp.py index 0623e58..aadc9e5 100644 --- a/gemato/openpgp.py +++ b/gemato/openpgp.py @@ -4,6 +4,7 @@ # Licensed under the terms of 2-clause BSD license import errno +import os.path import shutil import subprocess import tempfile @@ -56,6 +57,13 @@ class OpenPGPEnvironment(object): self._home = tempfile.mkdtemp() self._impl = None + with open(os.path.join(self._home, 'gpg-agent.conf'), 'w') as f: + f.write('''# autogenerated by gemato + +# avoid any smartcard operations, we are running in isolation +disable-scdaemon +''') + def __enter__(self): return self -- cgit v1.2.3