Access violation using gpgme

Daniel Lo Nigro d at d.sb
Tue Feb 5 19:21:45 CET 2019


 I'm trying to track down an access violation I'm encountering while using
GPGME to encrypt and decrypt data from within a C# app. This is the error
I'm hitting: "Exception thrown at 0x0057E018 in dotnet.exe: 0xC0000005:
Access violation executing location 0x0057E018". Unfortunately I have not
been successful in getting debug symbols working in neither gdb on Windows
nor Visual Studio, so I haven't been able to look at a native stack trace
to work out where it's coming from :(

I'm using gpgme_set_pinentry_mode to set the pinentry mode to "loopback",
and the access violation is being encountered after my pinentry callback
returns. It works fine if I don't use loopback, and instead use the
system's pinentry mechanism.

Windows 10 version 1809
gpg version 2.2.11
gpgme 1.12.1

I can post the full code if needed, but basically it's a modified version
of the PgpEncryptDecrypt sample from gpgme-sharp:
https://github.com/Daniel15/gpgme-sharp/blob/master/Examples/PgpEncryptDecrypt/Program.cs

Log from when I call gpgme_op_encrypt until the app crashes:
https://gist.github.com/Daniel15/925ed7346933e95c47830fae635c6b1c
Log for the entire session (finds a key, encrypts some data, then tries to
decrypt it):
https://gist.github.com/Daniel15/59d95a3bbb75a94aa6fd8e419fc21588

Thanks!
--
Regards,
Daniel Lo Nigro
https://d.sb/ | Twitter <http://twitter.com/Daniel15> | Facebook
<http://www.facebook.com/daaniel>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gnupg.org/pipermail/gnupg-devel/attachments/20190205/8f611429/attachment-0001.html>


More information about the Gnupg-devel mailing list