Page MenuHome GnuPG
Feed Advanced Search

Jan 6 2017

werner added projects to T1255: No output on status-fd if user cancels: Info Needed, Too Old.
Jan 6 2017, 6:53 PM · Too Old, Info Needed, gnupg, Feature Request
werner added projects to T2267: Fix "Invalid Parameter passed to C runtime function" warnings on Windows: Windows, Restricted Project, Windows 32.
Jan 6 2017, 6:50 PM · Windows 32, Windows, gnupg, gpgagent, Feature Request
werner added a comment to T2267: Fix "Invalid Parameter passed to C runtime function" warnings on Windows.

Actually we do not need that function on Windows. It is on Unix called at
startup to get a list of files not to close. On Windows we do not need to close
the files before a CreateProcess and thus close_all_fds is a dummy anyway.

I removed calling this function under Windows. To go into 2.1.18.

Jan 6 2017, 6:50 PM · Windows 32, Windows, gnupg, gpgagent, Feature Request
werner added a project to T2398: finger support using SRV DNS records: gnupg (gpg22).
Jan 6 2017, 6:29 PM · gnupg, Feature Request, dirmngr
werner added a project to T1173: gpg has no easy way to view the reason and description of revocation sigs: gnupg (gpg22).
Jan 6 2017, 6:27 PM · gnupg, Debian, Feature Request
werner renamed T1173: gpg has no easy way to view the reason and description of revocation sigs from gnupg: has no easy way to view the reason and description of revocation sigs to gpg has no easy way to view the reason and description of revocation sigs.
Jan 6 2017, 6:27 PM · gnupg, Debian, Feature Request
werner added a comment to T1537: gpgv does not handle expired or revoked keys.

I do not think that an expired key should be ignored. The reason is that it
won't be possible to verify an old package because it is common that keys expire
at some time. This does not say anything on whether the key has been compromised.

However, if a key has been revoked, that might be be an indication that the key
has been comprimised and that old signature may have been replaced by faked
ones. I would agree to return failure in this case.

Jan 6 2017, 6:25 PM · Feature Request, gnupg
werner added a project to T1537: gpgv does not handle expired or revoked keys: gnupg (gpg22).
Jan 6 2017, 6:25 PM · Feature Request, gnupg
werner closed T1986: gpg-1 should fallback to ~/.gnupg/S.gpg-agent as Resolved.
Jan 6 2017, 6:16 PM · gnupg, Fedora, Feature Request
werner added a comment to T1986: gpg-1 should fallback to ~/.gnupg/S.gpg-agent.

I would suggest to add

gpgconf --launch gpg-agent
GPG_AGENT_INFO="$(gpgconf --list-dirs agent-socket):-1:1"
export GPG_AGENT_INFO

to your startup script. This starts gpg-agent and sets the correct socket name
into the envar.

Jan 6 2017, 6:16 PM · gnupg, Fedora, Feature Request
werner added a project to T2081: g10/keydb.c:maybe_create_keyring_or_box doesn't check for EACCESS: Restricted Project.
Jan 6 2017, 5:51 PM · gnupg, Feature Request
werner added a comment to T2081: g10/keydb.c:maybe_create_keyring_or_box doesn't check for EACCESS.

I recently di this change:

  • return 0;

+ return !access (filename, R_OK)? 0 : gpg_error (GPG_ERR_EACCES);

(commit 5d13581f4737c18430f6572dd4ef486d1ad80dd1)

Does that solve your problem?

Jan 6 2017, 5:51 PM · gnupg, Feature Request
werner added a project to T2106: Support SHA-256 fingerprints for ssh: gnupg (gpg22).
Jan 6 2017, 5:47 PM · gnupg (gpg22), gnupg, ssh, Feature Request
werner added a comment to T2106: Support SHA-256 fingerprints for ssh.

Adding %f does not help much because it is only used internally. I would be in
favor of adding an ssh-key-mode option so that the user can select the hash algo
and the output format.

Jan 6 2017, 5:47 PM · gnupg (gpg22), gnupg, ssh, Feature Request
werner lowered the priority of T2233: Missing feedback when sending key to key server from Normal to Wishlist.
Jan 6 2017, 5:41 PM · gnupg, Feature Request
werner added a project to T2381: Add more support for profiles in gpgconf: gnupg (gpg22).
Jan 6 2017, 5:39 PM · In Progress, gnupg (gpg22), gnupg, Feature Request
werner removed a project from T2381: Add more support for profiles in gpgconf: gnupg (gpg21).
Jan 6 2017, 5:39 PM · In Progress, gnupg (gpg22), gnupg, Feature Request
werner added a project to T2912: command line keytocard: gnupg (gpg22).
Jan 6 2017, 5:37 PM · gnupg (gpg23), Feature Request
neal added a comment to T2912: command line keytocard.

Also see: https://github.com/mabels/gnupg/tree/quick-keytocard

Jan 6 2017, 5:15 PM · gnupg (gpg23), Feature Request
werner added a project to T2907: make DNS look ups more parallel: Feature Request.
Jan 6 2017, 5:13 PM · gnupg, Feature Request
werner lowered the priority of T2907: make DNS look ups more parallel from Low to Wishlist.
Jan 6 2017, 5:13 PM · gnupg, Feature Request
neal added projects to T2912: command line keytocard: Feature Request, gnupg.
Jan 6 2017, 3:33 PM · gnupg (gpg23), Feature Request
aheinecke added a comment to T2906: read/parse pubkeys in gpgme without importing.

I think this is a dup of T2819

That issue also contains a possible implementation. I'm not sure anymore why we
didn't push it I think it was because we were under release pressure and wanted
do look into this later.

Jan 6 2017, 2:07 PM · Duplicate, gpgme, Feature Request
neal updated subscribers of T2906: read/parse pubkeys in gpgme without importing.
Jan 6 2017, 12:45 PM · Duplicate, gpgme, Feature Request
neal added projects to T2906: read/parse pubkeys in gpgme without importing: Feature Request, gpgme.
Jan 6 2017, 12:45 PM · Duplicate, gpgme, Feature Request
neal set External Link to https://lists.gnupg.org/pipermail/gnupg-devel/2016-October/031918.html on T2906: read/parse pubkeys in gpgme without importing.
Jan 6 2017, 12:45 PM · Duplicate, gpgme, Feature Request
neal set External Link to https://lists.gnupg.org/pipermail/gnupg-devel/2016-October/031807.html on T2905: EFL-based pinentry.
Jan 6 2017, 12:26 PM · pinentry, Feature Request
neal added projects to T2905: EFL-based pinentry: Feature Request, pinentry.
Jan 6 2017, 12:26 PM · pinentry, Feature Request
neal updated subscribers of T2905: EFL-based pinentry.
Jan 6 2017, 12:26 PM · pinentry, Feature Request

Jan 2 2017

RJVB added a comment to T2884: Qgpgme thoughts and issues.

Hi,

The patch works. There's 1 more issue that's been standing for a bit longer already,
and that you might want to tackle at the same time: there's no argp.h header on Mac.

On Linux it is only a problem with the headers (e.g. the -dev) Package as the

That's actually an orthogonal issue, and one that's probably easier to rectify as any
changes only become apparent when dependent software is being built.

libraries have different soversions

This is also the case on Mac, but the link library doesn't have a soversion. It's
called libqgpgme.so or libqgpgme.dylib .
There is of course the option to rename just that symlink. A bit of a hack, but one
that's relevant only during the link step, when dependent software is being rebuilt.

How does MacPorts handle this in general? IMO this is not a (q)gpgme(++)
specific problem as you will have this problem with each ABI break.

MacPorts does many things like they're done on more traditional *n*x desktops, i.e.
install libraries in a central, shared location (--prefix=/opt/local by default).
There is nothing specific it does to handle ABI breaks; they can hold up an upgrade,
or a patch is applied at some level, or a conflict is registered. Sadly there is no
central way to create -dev packages, which doesn't help here.

E.g. when we
break the ABI in QGpgME libqt5qgpgme.dylib may be incompatible and we would need
a new name.

That I don't see. The problem here isn't so much the ABI break compared to the
version shipped by kdepimlibs4, but the fact that an incompatible Qt version is used.
So no, a SOVERSION=8 upgrade doesn't impose a library name change. Cf. Poppler and
its Qt backends; they're called libpoppler-qt4 and libpoppler-qt5 .
An alternative would be to do like QCA: install the library wherever Qt's own
libraries are installed. That automatically resolves the conflict with the old
version included with kdepimlibs4, and might be less disruptive for existing
distribution packages.

It's not only the build system but the code using QGpgME / GpgME++ will be more
complex as they would need to have feature checks for both the QGpgME version

What I had in mind was a build system that refuses to do a mismatching build of QpgME
X.Y.Z against GpgME++ that's not X.Y.Z . If you don't do runtime checks there's no
guarantee anyway beyond what the dynamic linker can give, I think. Distributions can
build QpgME and only bundle the QpgME bits, and then install that against any GpgME
install. I've done that for a bit with QpgME 1.7.x against QpgME++ 1.8.0, and didn't
run into any issues.
You could probably even argue that people would be less likely to try this kind of
things if the build system gave off a big hint that they really shouldn't be doing
that. It's not like it's particularly difficult to install only QpgME, after all.

Jan 2 2017, 5:21 PM · gpgme, qt, Feature Request
aheinecke added a comment to T2884: Qgpgme thoughts and issues.

Hi,

thanks for your feedback.

Regarding library suffix in the cmake config files, sorry about that I forgot
MacOS ;-) can you please test the attached patch (macos-cmake-config-fix.diff)
that reintroduces libsuffix to distinguish between macos and linux?

QGpgME builds libqgpme, preserving the same name as the library that used to
be built by kdepimlibs4.

There was a discussion after the 1.7.0 release about this. In summary: I agree
that we should have changed the name to avoid this conflicts, but we think that
it's now too late to do that as we want to avoid additional hassle for packages.
On Linux it is only a problem with the headers (e.g. the -dev) Package as the
libraries have different soversions. On Windows it's not a problem at all as the
Application ships the library it requires.

Is this something that might be considered upstream, e.g. for 1.8.1, possibly as
a build option? I realise this may not be something that has already come up on
Linux desktops but it's likely to do so in other distribution systems; it is
blocking us in MacPorts at this moment, for instance.

How does MacPorts handle this in general? IMO this is not a (q)gpgme(++)
specific problem as you will have this problem with each ABI break. E.g. when we
break the ABI in QGpgME libqt5qgpgme.dylib may be incompatible and we would need
a new name.

On Linux we have soversion and on Windows and MacOS imo usally the libraries are
shipped with the Application. But on MacPorts how does this work?

It will probably a bit more complex to maintain the buildsystem because you'd
want to exclude builds against mismatching qgpgme versions, but when done that
should be all, no?

It's not only the build system but the code using QGpgME / GpgME++ will be more
complex as they would need to have feature checks for both the QGpgME version
and the GPGME version to determine which features are available. This was a huge
hassle in the old days and one of the reasons we wanted to move them closer
together so that you can rely on the API once you have a minimum required version.

See e.g.:
https://git.gnupg.org/cgi-bin/gitweb.cgi?p=gpgme.git;a=commitdiff;h=433bb8e84b2d1e50b5c5b9f7f2006b60cd7d7785
That removed lots of these feature checks.

Jan 2 2017, 2:57 PM · gpgme, qt, Feature Request
aheinecke added a comment to T2884: Qgpgme thoughts and issues.

D403: 936_macos-cmake-config-fix.diff

Jan 2 2017, 2:57 PM · gpgme, qt, Feature Request
werner removed a project from T2893: gnupg should used ccid card key material fingerprints and not serial number: Bug Report.
Jan 2 2017, 1:54 PM · yubikey, Feature Request, gnupg
werner added a project to T2893: gnupg should used ccid card key material fingerprints and not serial number: Feature Request.
Jan 2 2017, 1:54 PM · yubikey, Feature Request, gnupg
werner added projects to T2898: Option to ignore card serial number (to be able to use backup tokens containing same subkeys): Feature Request, gnupg.
Jan 2 2017, 1:51 PM · gnupg, Feature Request

Dec 21 2016

werner added a comment to T2884: Qgpgme thoughts and issues.

Aside from the required build system changes we wil run into problems evaluating
bug reports.

Dec 21 2016, 6:56 PM · gpgme, qt, Feature Request
RJVB added a comment to T2884: Qgpgme thoughts and issues.

It will probably a bit more complex to maintain the buildsystem because you'd
want to exclude builds against mismatching qgpgme versions, but when done that
should be all, no?

It's just a bit a pity that you have to build all of the cpp bindings again if
you just want to build the Qt bindings.

Dec 21 2016, 6:50 PM · gpgme, qt, Feature Request
werner closed T2880: Make jenkins.gnupg.org reachable via https as Resolved.
Dec 21 2016, 6:44 PM · gpgweb, Feature Request
werner removed a project from T2880: Make jenkins.gnupg.org reachable via https: Restricted Project.
Dec 21 2016, 6:44 PM · gpgweb, Feature Request
werner added a project to T2884: Qgpgme thoughts and issues: qt.
Dec 21 2016, 6:43 PM · gpgme, qt, Feature Request
werner assigned T2884: Qgpgme thoughts and issues to aheinecke.
Dec 21 2016, 6:42 PM · gpgme, qt, Feature Request
werner added projects to T2884: Qgpgme thoughts and issues: Feature Request, gpgme.
Dec 21 2016, 6:42 PM · gpgme, qt, Feature Request
werner updated subscribers of T2884: Qgpgme thoughts and issues.
Dec 21 2016, 6:42 PM · gpgme, qt, Feature Request
werner lowered the priority of T2884: Qgpgme thoughts and issues from Normal to Wishlist.
Dec 21 2016, 6:42 PM · gpgme, qt, Feature Request

Dec 20 2016

werner closed T1648: Missing step in instructions for verifying integrity as Resolved.
Dec 20 2016, 11:49 PM · gpgweb, Feature Request
werner removed a project from T1648: Missing step in instructions for verifying integrity: Restricted Project.
Dec 20 2016, 11:49 PM · gpgweb, Feature Request
werner closed T1597: IDEA page should mention incompatibility of idea.c with gpg2 as Resolved.
Dec 20 2016, 11:48 PM · gpgweb, Feature Request
werner added a comment to T1597: IDEA page should mention incompatibility of idea.c with gpg2.

The web page has been updated.

Dec 20 2016, 11:48 PM · gpgweb, Feature Request
werner added a project to T2880: Make jenkins.gnupg.org reachable via https: Restricted Project.
Dec 20 2016, 5:02 PM · gpgweb, Feature Request
werner added a comment to T2880: Make jenkins.gnupg.org reachable via https.

Done. Note that the https is only to the frontend the backend is reached
unencrypted. We can't easily change this.

Dec 20 2016, 5:02 PM · gpgweb, Feature Request
werner removed a project from T2866: gpg-wks-client should support --check: Restricted Project.
Dec 20 2016, 12:51 PM · gnupg, Feature Request
werner closed T2866: gpg-wks-client should support --check as Resolved.
Dec 20 2016, 12:51 PM · gnupg, Feature Request
justus added projects to T2880: Make jenkins.gnupg.org reachable via https: Feature Request, gpgweb.
Dec 20 2016, 11:13 AM · gpgweb, Feature Request
justus added projects to T2879: There is no way to selectively delete secret subkeys: Feature Request, gnupg.
Dec 20 2016, 11:06 AM · gnupg, Feature Request

Dec 19 2016

aheinecke added a comment to T2381: Add more support for profiles in gpgconf.

Ok profiles are now there and look workable, but it looks like they are only
supporting configuration values that are currently accessible through gpgconf:

[gpg]
trust-model tofu+pgp
keyserver-options auto-key-retrieve
auto-key-locate local,wkd,pka,cert,dane

Leads to:

gpgconf: /opt/gnupg/etc/gnupg/automated.profile:7:0: error: unknown option
'trust-model' in section 'gpg'
gpgconf: /opt/gnupg/etc/gnupg/automated.profile:8:0: error: unknown option
'keyserver-options' in section 'gpg'

So we need more options promoted to gpgconf. Which I think is ok, we can just
mark them as Expert / Invisible and GUI's should respect that.

Dec 19 2016, 6:41 PM · In Progress, gnupg (gpg22), gnupg, Feature Request

Dec 16 2016

justus removed a project from T2700: Clean up the command line interface (avoid abbreviated --long-options, consistency): In Progress.
Dec 16 2016, 2:46 PM · gnupg, Feature Request, gnupg (gpg22)
justus closed T2700: Clean up the command line interface (avoid abbreviated --long-options, consistency) as Resolved.
Dec 16 2016, 2:46 PM · gnupg, Feature Request, gnupg (gpg22)
justus added a comment to T2700: Clean up the command line interface (avoid abbreviated --long-options, consistency).

I went over the other programs, and did not see any glaring problems. I have
decided to ignore the socket configuration for now. I'm quite happy with the
changes, but feel free to reopen this bug.

Dec 16 2016, 2:46 PM · gnupg, Feature Request, gnupg (gpg22)

Dec 15 2016

justus closed T2359: Query which key will be used for a given mailbox as Resolved.
Dec 15 2016, 5:29 PM · gnupg (gpg22), gnupg, Feature Request
justus added a comment to T2700: Clean up the command line interface (avoid abbreviated --long-options, consistency).

Fixed for gpg as of 6b16b02109f4bb5b934e456667ff4c0ba7bc85fd.

Dec 15 2016, 5:27 PM · gnupg, Feature Request, gnupg (gpg22)
justus added a project to T2700: Clean up the command line interface (avoid abbreviated --long-options, consistency): In Progress.
Dec 15 2016, 5:27 PM · gnupg, Feature Request, gnupg (gpg22)

Dec 13 2016

justus set External Link to https://lists.gnupg.org/pipermail/gnupg-devel/2016-December/032298.html on T2701: Do not let users create keys without an expiration date.
Dec 13 2016, 4:53 PM · Feature Request, gnupg (gpg22)
justus closed T2701: Do not let users create keys without an expiration date as Resolved.
Dec 13 2016, 4:53 PM · Feature Request, gnupg (gpg22)
justus added a comment to T2701: Do not let users create keys without an expiration date.

--quick-keygen fixed in dd3dde07a9a46130ac01d849f8edf0566e44f11f.

The default expiration interval has been discussed on the mailing list. There
was a rough consensus on two years, which has been challenged by Neal who thinks
it is too short given the current state of the tools, but the ensuing discussion
did not revolve around the time span, so I'm keeping my two years for now. In
any case, it is easy to adjust.

I decided to not change the --full-key-gen, because a) the user asked for it, b)
changing that requires breaking up a large chunk of translated text, and I do
not want to do that right now (a release is imminent).

Dec 13 2016, 4:53 PM · Feature Request, gnupg (gpg22)

Dec 9 2016

justus added a comment to T2701: Do not let users create keys without an expiration date.

Partially addressed in d568a1561642ed9b7b7b6282b86c56786d10a956.

Dec 9 2016, 2:56 PM · Feature Request, gnupg (gpg22)
dkg added a comment to T2862: support session key extraction and overriding for gpgsm.

This would emit the "content-encryption key", as specified in
https://tools.ietf.org/html/rfc5652#section-6.3

Dec 9 2016, 5:18 AM · gnupg24, Feature Request, gnupg (gpg23)

Dec 8 2016

werner added a project to T2866: gpg-wks-client should support --check: Restricted Project.
Dec 8 2016, 5:59 PM · gnupg, Feature Request
werner added a comment to T2866: gpg-wks-client should support --check.

Okay, I implemented --status-fd for gpg-wks-client.

Dec 8 2016, 5:59 PM · gnupg, Feature Request
aheinecke added a comment to T2866: gpg-wks-client should support --check.

Regarding a return code as text lines: Do you need this due to the double-fork
we use in gpgme?

I think so, at least I did not find a way to return an exit code from
gpgme_op_spawn.

If we provide this we should resort to the GnuPG standard
which is to required --status-fd N to print
[GNUPG:] ERROR ....
okay?

Yes. In that case i could use op_spawn with status-fd 2 and would get the error
I think.

Dec 8 2016, 5:12 PM · gnupg, Feature Request
werner added a comment to T2866: gpg-wks-client should support --check.

Okay, try "gpg-wks-cleint --check ADDR" So see details use -v.

Regarding a return code as text lines: Do you need this due to the double-fork
we use in gpgme? If we provide this we should resort to the GnuPG standard which is
to required --status-fd N to print
[GNUPG:] ERROR ....
okay?

Dec 8 2016, 5:09 PM · gnupg, Feature Request
aheinecke added projects to T2866: gpg-wks-client should support --check: Feature Request, gnupg.
Dec 8 2016, 3:11 PM · gnupg, Feature Request
aheinecke updated subscribers of T2866: gpg-wks-client should support --check.
Dec 8 2016, 3:11 PM · gnupg, Feature Request

Dec 6 2016

werner added a comment to T2701: Do not let users create keys without an expiration date.

Would you mind to write to gnupg-devel and ask for comments on your proposal?
In particular on how long the default expiration time shall be. 12, 18, or 24
months?

Dec 6 2016, 9:55 PM · Feature Request, gnupg (gpg22)

Dec 5 2016

dkg added projects to T2862: support session key extraction and overriding for gpgsm: gnupg (gpg23), Feature Request, gnupg.
Dec 5 2016, 7:38 PM · gnupg24, Feature Request, gnupg (gpg23)
justus added a comment to T2701: Do not let users create keys without an expiration date.

Thanks!

Dec 5 2016, 1:44 PM · Feature Request, gnupg (gpg22)
werner added a comment to T2701: Do not let users create keys without an expiration date.

--quick-set-expire now available.

Dec 5 2016, 12:22 PM · Feature Request, gnupg (gpg22)
werner added a comment to T2701: Do not let users create keys without an expiration date.

I'll take the --quick-set-expire command. -wk

Dec 5 2016, 9:26 AM · Feature Request, gnupg (gpg22)
werner added a comment to T2359: Query which key will be used for a given mailbox.

That is becuase we consider a mail address to be a unique indentifier and thus
and algorithm to figure out the best matching makes sense. Other kinds of user
IDS not not need to be unique and should at best return an ambigious key error.
Well, expired keys and such should be sorted out, though.

Dec 5 2016, 9:03 AM · gnupg (gpg22), gnupg, Feature Request

Dec 1 2016

cpaelzer added a comment to T2858: way to not spawn (or despawn) gpg-agent and dirmngr.

On Thu, Dec 1, 2016 at 10:33 AM, Werner Koch via BTS <gnupg@bugs.g10code.com

wrote:

Dec 1 2016, 11:03 AM · gnupg, Feature Request, dirmngr
werner added a project to T2398: finger support using SRV DNS records: gnupg.
Dec 1 2016, 10:40 AM · gnupg, Feature Request, dirmngr
werner added a project to T2858: way to not spawn (or despawn) gpg-agent and dirmngr: gnupg.
Dec 1 2016, 10:34 AM · gnupg, Feature Request, dirmngr
werner added a comment to T2858: way to not spawn (or despawn) gpg-agent and dirmngr.

Can you please switch to 2.1.16? We fixed the inotify based socket removal
detection (issue2756).

Dec 1 2016, 10:33 AM · gnupg, Feature Request, dirmngr

Nov 30 2016

cpaelzer added a comment to T2858: way to not spawn (or despawn) gpg-agent and dirmngr.

On Wed, Nov 30, 2016 at 10:28 AM, Werner Koch via BTS <
gnupg@bugs.g10code.com> wrote:

Nov 30 2016, 1:07 PM · gnupg, Feature Request, dirmngr
werner added a comment to T2858: way to not spawn (or despawn) gpg-agent and dirmngr.

If you are on Linux you may simply remove the socket files and the daemons will
terminate.

Nov 30 2016, 10:28 AM · gnupg, Feature Request, dirmngr
cpaelzer added a comment to T2858: way to not spawn (or despawn) gpg-agent and dirmngr.

On Tue, Nov 29, 2016 at 7:14 PM, Werner Koch via BTS <gnupg@bugs.g10code.com>
wrote:

[...]
thanks for the clarifications, I was 95% there but that rounds it up to the full
picture.

   GNUPGHOME=$(pwd) gpg-agent --daemon -v MYSCRIPT

This starts the agents and runs MYSCRIPT (/bin/sh is nice for testing). After
MYSCRIPT terminates the agent will be terminated within the next minute.

We more or less do that already, and I can confirm it does "terminate the next
minute".
Unfortunately "the next minute" isn't soon enough for my umount.

So I thought for now I might have to rely on an extra call of "gpgconf --kill
dirmngr" to be sure. But I have found that this doesn't end it for me - maybe
related to our custom GNUPGHOME?
It doesn't seem to stop as intended via gpgconf: (neither with nor without
GNUPGHOME):

$ ps axlf | egrep 'gpg|dirmngr'
1 0 18021 1 20 0 176840 6236 - Ssl ? 0:00 dirmngr --
daemon --homedir /tmp/tmped9zl1ip
$ gpgconf --kill dirmngr
$ ps axlf | egrep 'gpg|dirmngr'
1 0 18021 1 20 0 176840 6236 - Ssl ? 0:00 dirmngr --
daemon --homedir /tmp/tmped9zl1ip
$ GNUPGHOME="/tmp/tmped9zl1ip" gpgconf --kill dirmngr
$ ps axlf | egrep 'gpg|dirmngr'
1 0 18021 1 20 0 176840 6236 -
(Also did the same as root without effect, but avoid filling this report only
with logs)

The more obvious but less graceful "sudo killall dirmngr |:" cleans it up.

The reason why your bind mount fails are likely the socket files created there.

via lsof I only found the following to be related (the /dev bind umount is what
fails).
dirmngr 6771 root 1r CHR LG,0x80000 1,9 0t0
11 /tmp/tmptmucmfm0/target/dev/urandom
dirmngr 6771 root 2w CHR W,LG 1,3 0t0
6 /tmp/tmptmucmfm0/target/dev/null
gpg-agent 6776 root 0r CHR LG 1,3 0t0
6 /tmp/tmptmucmfm0/target/dev/null
gpg-agent 6776 root 1w CHR W,LG 1,3 0t0
6 /tmp/tmptmucmfm0/target/dev/null
gpg-agent 6776 root 2w CHR W,LG 1,3 0t0
6 /tmp/tmptmucmfm0/target/dev/null

Not sure, but I'd not expect these are the sockets.
My assumption would be the open /dev/urandom - especially as I found that I only
need to get rid of dirmngr to proceed.

The solution to this are //run/user based sockets. If you create a directory
/run/user/UID gnupg will create a gnupg sub-directory and place the socket
files there.

gpg-conf --list-dirs

can be used to check that.

I created a log based on that check and lsof (the view from inside the chroot):
gpgconf --list-dirs
lsof +fg /dev
gpgconf --kill dirmngr
lsof +fg /dev
pkill gpg-agent
pkill dirmngr
lsof +fg /dev

I'll attach the full log with this post.
You can find there that the agent and dirmngr do not go away on the gpgconf --
kill.
The socket path OTOH looks ok with "agent-socket:/root/.gnupg/S.gpg-agent"

I added this as first command in chroot to give it a try at least:
$ mkdir -p /run/user/$(id -u)
It "worked" in the sense that the dirs changed e.g. from:
dirmngr-socket:/root/.gnupg/S.dirmngr
to
dirmngr-socket:/run/user/0/gnupg/S.dirmngr
But as I expected that did not change the behavior of blocking to umount the /dev

I really think it is not the sockets but e.g. the /dev/urandom it keeps open.

Is there any way to get the agent&dirmngr from "away next minute" to be "away
before exiting the calling command"?

BTW - I wondered if it would be enough if gpg-agent can stay and to only kill
dirmngr - but it seems I need both gone to let me umount.

Nov 30 2016, 9:38 AM · gnupg, Feature Request, dirmngr
cpaelzer added a comment to T2858: way to not spawn (or despawn) gpg-agent and dirmngr.

Nov 30 2016, 9:38 AM · gnupg, Feature Request, dirmngr

Nov 29 2016

werner added a comment to T2858: way to not spawn (or despawn) gpg-agent and dirmngr.

The agent is not directly involved in keyserver lookups. Instead the dirmngr is
spawned and does this for you. In fact, all network access goes through dirmngr.
However the agent is a mandatory part of gnupg-2 - all private keys are
processed solely by the agent. Thus removing the agent is not an option.
In your case the agent is launched to check whether a private key is available
for an imported public key.

You can stop the agent or the dirmngr using "gpgconf --kill dirmngr"
("gpg-agent"). For your use case a better solution will be to run your script
under the control of the agent (ie. explicily starting the agent):

  GNUPGHOME=$(pwd) gpg-agent --daemon -v MYSCRIPT

This starts the agents and runs MYSCRIPT (/bin/sh is nice for testing). After
MYSCRIPT terminates the agent will be terminated within the next minute.

The reason why your bind mount fails are likely the socket files created there.
I had the same problem with my g13 based disk encryption. The solution to this
are //run/user based sockets. If you create a directory /run/user/UID gnupg
will create a gnupg sub-directory and place the socket files there.

gpg-conf --list-dirs

can be used to check that.

Nov 29 2016, 7:14 PM · gnupg, Feature Request, dirmngr
werner added a project to T2858: way to not spawn (or despawn) gpg-agent and dirmngr: Feature Request.
Nov 29 2016, 7:01 PM · gnupg, Feature Request, dirmngr
werner lowered the priority of T2858: way to not spawn (or despawn) gpg-agent and dirmngr from Normal to Wishlist.
Nov 29 2016, 7:01 PM · gnupg, Feature Request, dirmngr
lorenz added a comment to T1854: Problems with same encryption and signing key on smartcard.

Anything I can do to help?

Nov 29 2016, 4:57 PM · gnupg, Feature Request, scd

Nov 28 2016

werner added a project to T2850: auto-key-locate is annoying: gnupg (gpg23).
Nov 28 2016, 10:26 AM · gnupg (gpg23), gnupg, Feature Request
werner added a comment to T2850: auto-key-locate is annoying.

The major trouble we have here is that dirmngr is not abale to detect network
failures. This is due to ADNS which keeps on trying to send UDP packets for 30
sesonds desipte a ENETUNREACH. I tried with a patched ADNS versions and did
not anymore suffer from these problems.

However, when a keyserver is not answering in time, there is indeed a problem.
A problem we may be able so solve with queuing the requests after a short
timeout. gpg already tells dirmngr that it is prepared for such a "soft
failure" but we need to implement this in dirmngr.

The whole thing is not new (except for ADNS) and has been with us since the
introduction of --auto-key-locate and --auto-key-retrive. WHich is a LONG time ago.

Nov 28 2016, 10:25 AM · gnupg (gpg23), gnupg, Feature Request
werner removed a project from T2825: WKS: Encrypt submission / confirmation also with the users key: Unreleased.
Nov 28 2016, 10:20 AM · gnupg, Feature Request

Nov 23 2016

neal updated subscribers of T2850: auto-key-locate is annoying.
Nov 23 2016, 3:25 PM · gnupg (gpg23), gnupg, Feature Request
neal added projects to T2850: auto-key-locate is annoying: Feature Request, gnupg.
Nov 23 2016, 3:25 PM · gnupg (gpg23), gnupg, Feature Request

Nov 20 2016

werner added a project to T2811: please compare the timestamps of secring.gpg and .gpg-v21-migrated and consider re-migration: Won't Fix.
Nov 20 2016, 5:23 PM · Won't Fix, Feature Request, gnupg
werner added a comment to T1805: gpg-agent: Wakes up periodically.

Note that gpg-agent has been changed years ago to make up at the full second so
that all daemons with a need to wakeup are running at the same time.

Nov 20 2016, 5:22 PM · Feature Request, gnupg
werner removed a project from T2754: provide mechanism to retrieve (and send?) session key in gpgme: Restricted Project.
Nov 20 2016, 5:20 PM · gpgme, Feature Request
werner closed T2754: provide mechanism to retrieve (and send?) session key in gpgme as Resolved.
Nov 20 2016, 5:20 PM · gpgme, Feature Request
werner added a comment to T2754: provide mechanism to retrieve (and send?) session key in gpgme.

Released with 1.8.0

Nov 20 2016, 5:20 PM · gpgme, Feature Request