Follow-up to Crashes with gpg-agent 2.1.18
Matthew Summers
matthew.summers at syapse.com
Fri Apr 21 18:55:01 CEST 2017
On Fri, Apr 21, 2017 at 10:27 AM, Matthew Summers
<matthew.summers at syapse.com> wrote:
> On Thu, Apr 20, 2017 at 8:19 PM, NIIBE Yutaka <gniibe at fsij.org> wrote:
>>
>> Thank you for your information.
>>
>> GnuPG doesn't use nettle and glib, so, I wonder if it's related.
>>
>> Recently, after 2.1.20, I fixed a race in gpg-agent, which is
>> possible to cause double free (and crash).
>>
>> https://dev.gnupg.org/T3027
>>
>> This may be related.
>
>
> That explanation in https://dev.gnupg.org/T3027#95879 sounds very
> accurate based on what I have seen. I'll give the patch a shot!
Testing that patch in the ticket above, I am still encountering
failures with parallelism greater than the number of CPU "cores" on my
machine (8 cores). The behavior is somewhat interesting.
On occasions I can force an error that looks like:
gpg-agent[15942] failed to build S-Exp (off=0): Cannot allocate memory
gpg-agent[15942] failed to read the secret key
gpg-agent[15942] command 'PKDECRYPT' failed: Cannot allocate memory <gcrypt>
gpg-agent[15942] DBG: chan_16 -> ERR 16810070 Cannot allocate memory <gcrypt>
in this case, decryption totally fails. Whereas on other occasions I
just get a new pin-entry pop up, with decryption succeeding in the
end.
It seems like there is a race for the socket, somehow, but I am not
sure how to verify this.
More information about the Gnupg-devel
mailing list