Cannot control GnuPG from shell (IPC parameter error)

2017-11-04 Thread Seby
Hello,

I have a script that interacts with GnuPG in an automated / unattended
way, but it cannot control the keyring. I keep getting this:

gpg: key generation failed: IPC parameter error

I am running 2.3.0-beta82. I tried to search for this error and I
could only find clues that lead to gpg-agent, but # gpg-agent --help
doesn't allow me to disable it. What is the good approach here?

Thanks in advance.

___
Gnupg-users mailing list
Gnupg-users@gnupg.org
http://lists.gnupg.org/mailman/listinfo/gnupg-users


Re: Efficent batch fetching with verification?

2017-11-04 Thread Werner Koch
On Sat,  4 Nov 2017 06:06, robb...@gentoo.org said:

> Yes, the older versions do perform much worse, but even with gnupg2.2,
> each exec of gpg is still at least 100ms, which adds up over time.

I doubt that, let's see:

  $ time sh -c 'seq 1 1 | xargs -n 1 gpg --version >/dev/null'
  
  real0m0.010s
  user0m0.004s
  sys 0m0.004s
  $ time sh -c 'seq 1 100 | xargs -n 1 gpg --version >/dev/null'
  
  real0m0.361s
  user0m0.068s
  sys 0m0.024s

This is less than 4ms per exec.  So you problem is for sure not the
fork/exec.


Salam-Shalom,

   Werner

-- 
Die Gedanken sind frei.  Ausnahmen regelt ein Bundesgesetz.


pgpgiYrylJG41.pgp
Description: PGP signature
___
Gnupg-users mailing list
Gnupg-users@gnupg.org
http://lists.gnupg.org/mailman/listinfo/gnupg-users


Re: Efficent batch fetching with verification?

2017-11-04 Thread Peter Lebbing
On 03/11/17 21:06, Robin H. Johnson wrote:
> You missed xargs itself,

Actually, I did not :-).

> this mostly centers around the command-line
> length limit. I can get in about ~3200 fingerprints per GPG call.

I asked "what is exec'ing much". I don't see one exec every 3200
fingerprints as overhead at all.

In your other reply, you say the 100 ms exec overhead for these 3200
keyserver fetches is significant. But I see a lot of round trips to the
keyserver; I didn't check the docs, but it must not be fetching many
keys in every HKP request. Perhaps even just a single key per request.
That is 3200 round trips to a remote server. And then the data will be
checked: this means running expensive asymmetric crypto.

So how long does this one gpg with 3200 key fetches run for you, as wall
time, and as cpu time? TBH, I'm having a hard time believing the
starting up of gpg.exe is relevant.

Cheers,

Peter.

-- 
I use the GNU Privacy Guard (GnuPG) in combination with Enigmail.
You can send me encrypted mail if you want some privacy.
My key is available at 



signature.asc
Description: OpenPGP digital signature
___
Gnupg-users mailing list
Gnupg-users@gnupg.org
http://lists.gnupg.org/mailman/listinfo/gnupg-users