#760237 GPA fails obscurely when no gpg-agent is running

Package:
gpa
Source:
gpa
Description:
GNU Privacy Assistant (GPA)
Submitter:
Daniel Kahn Gillmor
Date:
2015-07-06 18:30:10 UTC
Severity:
normal
#760237#5
Date:
2011-07-21 00:36:36 UTC
From:
To:
When started GPA gives the following sequence of errors:

        GnuPG is rebuilding the trust database.
        This might take a few seconds.

and

        GPA Error
        The GPGME library returned an unexpected error.  The error was:
        General Assuan error
        This is probably a bug in GPA
        GPA will now try to recover from this error

I also was unable to generate keys due to the same error messages appearing
every time

FYI - I found the following here:
http://forums.debian.net/viewtopic.php?f=6&t=64515

        Problem has been solved by installing older version of GPA (GNU Privacy
Assistent) from Ubuntu repository (in Debian).

thanks!

#760237#10
Date:
2011-12-09 08:56:30 UTC
From:
To:
For debugging info - I do run into this problem when running GPA on sid,
but for some reason the problem is gone on my Debian installations that
run testing - I believe the real problem is in a library that GPA uses
instead of the GPA package itself.

I hope this might help finding the real cause of the problem.

best regards

#760237#15
Date:
2012-01-19 05:04:44 UTC
From:
To:
I was able to compile my own version that works fine. Here is how
Debian -- or anyone else that wants to -- can fix the error. There are
two options:

Option 1:
* Debian / Ubuntu need to reintroduce gpa into the repos again, but
make gpa depend on libassuan-dev (v1 only -- not v2).
* libassuan-dev was recently upgraded to v2, so this broke gpa.
* To build properly, the config script MUST be set to assuan API v1,
not v2 (should be already).

Option 2:
* Allow gpa to depend on libassuan-dev v2.
* However, to do this, gpa MUST use the new assuan v2 API and change a
few function call stubs which violate the new v2 API (using v1 API
call stubs).
* Then gpa should build fine using the new assuan v2 API.

Cheers,

#760237#20
Date:
2012-03-21 04:25:35 UTC
From:
To:
What is the status of this bug? gpa is essentially useless how is the
severity only normal?

#760237#25
Date:
2012-06-23 16:17:10 UTC
From:
To:
We believe that the bug you reported is fixed in the latest version of
gpa, which is due to be installed in the Debian FTP archive:

gpa_0.9.0-2.debian.tar.gz
  to main/g/gpa/gpa_0.9.0-2.debian.tar.gz
gpa_0.9.0-2.dsc
  to main/g/gpa/gpa_0.9.0-2.dsc
gpa_0.9.0-2_amd64.deb
  to main/g/gpa/gpa_0.9.0-2_amd64.deb



A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 634930@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Daniel Leidert (dale) <daniel.leidert@wgdd.de> (supplier of updated gpa package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)
Format: 1.8
Date: Sat, 23 Jun 2012 17:04:46 +0200
Source: gpa
Binary: gpa
Architecture: source amd64
Version: 0.9.0-2
Distribution: unstable
Urgency: low
Maintainer: Michael Banck <mbanck@debian.org>
Changed-By: Daniel Leidert (dale) <daniel.leidert@wgdd.de>
Description:
 gpa        - GNU Privacy Assistant (GPA)
Closes: 448765 614698 625513 628305 634930
Changes:
 gpa (0.9.0-2) unstable; urgency=low
 .
   * Acknowledge NMU (closes: #628305, #634930).
   * debian/compat: Increased debhelper compatibility level to 7.
   * debian/control: Set DM-Upload-Allowed.
     (Standards-Version): Bumped to 3.9.3.
     (Build-Depends): Increased required debhelper and autotools-dev versions.
     (Vcs-Browser): Point to real location.
   * debian/gpa.1: Fixed typos. Fixed syntax (arguments may contain files).
   * debian/gpa.dirs: Dropped (useless).
   * debian/gpa.docs: Removed NEWS (closes: #614698).
   * debian/rules: Rewritten for debhelper 7. Enabled hardening flags.
   * debian/source/format: Added for source format 3.0 (quilt).
   * debian/patches/628305_build_with_libassuan_v2.patch: Added.
     - Includes patch to fix #628305, #634930.
   * debian/patches/448765_grammar_fixes.patch: Added.
     - Fix grammar issues (closes: #448765).
   * debian/patches/625513_fix_expiration_date.patch: Added.
     - Fix bases for the month (closes: #625513).
   * debian/patches/series: Added.
Checksums-Sha1:
 718d24e212a293e86c0200afa0b859c94871897f 1424 gpa_0.9.0-2.dsc
 3435b5953f8f3850ac63496b1e2f191f559bef24 9978 gpa_0.9.0-2.debian.tar.gz
 0c904dec7adff3e0e482b47a7d40ca3e58b87bee 348068 gpa_0.9.0-2_amd64.deb
Checksums-Sha256:
 9a00e6d6e77d8ae830af18f504d5dd87a898fb1b7f47061107ce0bc5de65f408 1424 gpa_0.9.0-2.dsc
 0384dcfad26416538f1d81b5cf32075e26c7f48b7b9f0ba80e348655a37d24b0 9978 gpa_0.9.0-2.debian.tar.gz
 a1230e52721be98e256f56ee834d640815f827c73c0076bd300854e6f2dbd048 348068 gpa_0.9.0-2_amd64.deb
Files:
 35391a565fc339184ab8e5aca8b43eea 1424 utils optional gpa_0.9.0-2.dsc
 4af0134c23edff5f5ceccd48211a4153 9978 utils optional gpa_0.9.0-2.debian.tar.gz
 cdc317ebe2b38162dd2c543d43453710 348068 utils optional gpa_0.9.0-2_amd64.deb
iEYEARECAAYFAk/l6PcACgkQmHaJYZ7RAb8fygCfSaq0GQTPzBVDIdyhuMO1ZYO5
ZuEAoKvmMikUv2tTM5S0Av9t2Z004+ja
=dg1n
-----END PGP SIGNATURE-----

#760237#30
Date:
2012-07-01 07:18:23 UTC
From:
To:
Dear Maintainer,

I was hoping to really have this bug solved but I upgraded from a working
0.7.0-1.1 old version this 0.9.0-2 and still get the "General Assuan Error"
that was first described here.

Of course, as usual, reverting once again to the older version solves the
problem.

#760237#35
Date:
2012-07-01 14:12:39 UTC
From:
To:
Am Sonntag, den 01.07.2012, 09:18 +0200 schrieb Lionel Gamay:
you please try the following (depends on how many keys you have in your
keyring).

Probably try this only with a newly created user account: Run gpa on
this new user and import one key after another from the keyring of your
usual user account to check, if one of your keys causes the issue.

Regards, Daniel

#760237#38
Date:
2012-07-01 14:12:39 UTC
From:
To:
Am Sonntag, den 01.07.2012, 09:18 +0200 schrieb Lionel Gamay:
you please try the following (depends on how many keys you have in your
keyring).

Probably try this only with a newly created user account: Run gpa on
this new user and import one key after another from the keyring of your
usual user account to check, if one of your keys causes the issue.

Regards, Daniel

#760237#45
Date:
2012-07-02 07:27:03 UTC
From:
To:
I had this error displayed in three existing profiles on this machine,
even with no gpg key stored in one of these profiles. So I created a
fresh new profile as you suggested. The result are:

- there is not any problem with any of the reimported keys in the new profile
- in the new profile, there is no "General Assuan error" when starting gpa

In one of the profiles where the "bug" is present and gnupg is already
configured and working with the old version of gpa, I moved away the
.gnupg directory in order to have it recreated when starting again the newer
gpa. And the error was however still displayed.

So this error message seems to be related to something else stored
in the currently existing user profiles that I can't figure for now. If you
ever have any clue...

All my apologies.

Lionel

#760237#50
Date:
2012-07-02 19:45:27 UTC
From:
To:
Dear gnupg/gpa developers,

There is some strange issue with gpa on a Debian users system. See

http://bugs.debian.org/634930

and the mail below. gpa has no debug switch. What do you suggest to
debug the issue?

Regards, Daniel


Am Montag, den 02.07.2012, 09:27 +0200 schrieb Lionel Gamay:

#760237#55
Date:
2012-07-06 18:36:57 UTC
From:
To:
I have this bug now for over an year and it is not possible to fix it. I tried everything. Even other OS. The only solution which helps is to use a very old verssion of GPA but I don't like this solution at all. I want to use the newest version.

I have found out that this bug happens not only on Debian, The same happens on FreeBSD 9.0-RELEASE. So it is for sure not a Debian bug or gpa bug.

I am 100% sure this bug has something to do with GNOME. Because the newest gpa version works on XFCE without any problems.

This bug happens with Gnome 2 and Gnome 3, On Debian Testing and Debian Sid and on FreeBSD 9.0-RELEASE.

I hope the GNOME developers will do something ... gpa is unusable for over an year now. This is really a shame.

#760237#60
Date:
2012-07-07 01:38:01 UTC
From:
To:
Am Freitag, den 06.07.2012, 14:36 -0400 schrieb davemas@Safe-mail.net:

The newest version is 0.9.2, which is in experimental. Can you try, if
your problem still occurs?

See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=634930#35 ff. I've
already wrote to the gpa developers (but Werner Koch is absent atm
AFAIK).

Regards, Daniel

#760237#65
Date:
2012-07-07 11:41:07 UTC
From:
To:
Hello Lionel,

Can you please check the package in experimental (gpa 0.9.2.) if your
problem still exists?

TIA and regards, Daniel


Am Montag, den 02.07.2012, 09:27 +0200 schrieb Lionel Gamay:

#760237#70
Date:
2012-07-07 16:49:23 UTC
From:
To:
Yes. I tried it already, It doesn't help at all. Still the same problem. I even tried to compile it, same problem. I really tried nearly every version.

There are no problems in other Desktop Environments, only in GNOME.

I think someone in FreeBSD forums wrorte it has to do something with Seahorse. And  some certificates. But I don't know for sure what it was.

I'm sure it's a GNOME bug though.

#760237#75
Date:
2012-07-08 02:39:50 UTC
From:
To:
I have found that the problem is the expired X.509 certificates.

Here is my easy workaround to solve this bug.

1. Remove the file where the X.509 certificates are stored.

rm usr/share/gnupg2/com-certs.pem

2. Remove your gnupg configuration folder.

rm home/benutzer/.gnupg/

That's all. Should work for every version. Enjoy.

#760237#80
Date:
2012-07-08 09:35:56 UTC
From:
To:
The problem was not solved with this experimental version :(

However the hack given above does work: I removed "com-certs.pem",
made a backup of my keys,
deleted my ~/.gnupg, reimported the keys and everything works again
with the current 0.9.0-2.

I then tested with the version from experimental (0.9.2-1) but this
one crashes when trying to open
the embedded file manager.

NB: gpa didn't work either for me under Xfce since months ago. So I
didn't think it was related only
to Gnome 3 but more generally to gtk internal changes introduced since
the move from the old 2.x.

Regards,
Lionel

2012/7/7 Daniel Leidert <daniel.leidert@wgdd.de>:

#760237#85
Date:
2012-07-08 11:38:45 UTC
From:
To:
CCing gpa-dev
BCCing affected users

Am Sonntag, den 08.07.2012, 02:39 +0000 schrieb mnmnmnmn@tormail.org:

How did you find out?
--disable-x509 instead?

Is the second step really necessary?

It works locally without removing this file. [1] proves this too.

[1] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=634930#45

Regards, Daniel

#760237#90
Date:
2012-07-08 13:42:07 UTC
From:
To:
Tested and works with 'gpa --disable-x509'

Worked for me with just the option.

Greetz
Bernd

#760237#95
Date:
2012-07-09 10:07:20 UTC
From:
To:
Trying to run "gpa --disable-x509" issues an error in either 0.7.x or
0.9.0 versions:

v 0.7.x: gpa: unrecognized option '--disable-x509'

v 0.9.0: option parsing failed: Option inconnue --disable-x509

Either version was purged and reinstalled multiple times.

Regards,
Lionel

#760237#100
Date:
2012-07-09 14:27:09 UTC
From:
To:
Should "--disable-x509" be run only with the version 0.9.2 from
experimental ? I didn't think so.

However, this option works and does solve the problem. Then deleting
~/.gnupg is not necessary.

Regards,
Lionel

#760237#105
Date:
2012-07-13 13:30:15 UTC
From:
To:
Hi,

I tried to replicate the problem with the current stable versions of GPA
0.9.2 and GPGME (well, my working copy).  I was not able to do that.  I
don't have a clean squeeze installation right now available thus I can't
check 0.9.0 easily.

Lionel, would you mind to run another test with GPA 0.9.2, GPGME 1.3.2,
and GnuPG 2.0.19 (or 2.1-beta).


Salam-Shalom,

   Werner

#760237#110
Date:
2012-07-13 15:38:17 UTC
From:
To:
On Fri, 13 Jul 2012 15:30, wk@gnupg.org said:

Sorry, Lionel, it was meant to be sent the other Lionel.

#760237#115
Date:
2012-07-13 16:13:38 UTC
From:
To:
Am Freitag, den 13.07.2012, 15:30 +0200 schrieb Werner Koch:
outdated gpgme in Debian. I've built packages for the latest gpgme
release. However, if you install them, you probably need to downgrade
these packages after you've tested, how gpa behaves!

GPGME 1.3.2 packages built for unstable are here:
http://debian.wgdd.de/debian/incoming/packages/

Regards, Daniel

#760237#120
Date:
2012-07-28 19:20:01 UTC
From:
To:
One rather disconcerting thing about gpa is that it has both gnupg and
gnupg2 in its dependency graph.  I wonder if that might account for some
of the weird problems.

What is the purpose of having gnupg v1 around anyway?  Can the remaining
packages depending on it not be ported over?

#760237#125
Date:
2012-07-29 10:14:53 UTC
From:
To:
Am Samstag, den 28.07.2012, 12:20 -0700 schrieb Ian Zimmerman:

I don't think so. However, I'm planning to drop the gnupg1 dependency
and let gpa depend on gnupg2 and its toolchain.

GnuPG is an important tool in the Debian toolchain. The 1.x series is
much smaller, has lesser dependencies than the 2.x series; further it
doesn't need a running agent, it is stable and upstream still actively
supports it. IMO it is better suited for terminal-based systems.
Therefor I'm currently not in favor of dropping it.

But there is one thing, that should IMO be changed in Debian. ATM gnupg
1.x and 2.x series provide different binaries. It has already been
requested to introduce a diversion instead, so both packages provide a
gpg binary (and both can still provide gpgX (X=1,2) binaries). This step
can IMO improve the situation.

Regards, Daniel

#760237#130
Date:
2012-10-04 21:22:08 UTC
From:
To:
Dear Maintainer,

Some info on the status of this bug on a fresh wheezy.

- Install wheezy with the installer beta2
- Install gpa
- Start gpa
- I get three dialogs. I can't click/close any of them

1. GPA error

    The GPGME library returned an unexpected error. The error was:

        General Assuan error

    This is probably a bug in GPA.
    GPA will now try to recover from this error.

2.

    You do not have a private key yet. Do you want to generate one now
    (recommanded) or do it later?

3.

    GnuPG is rebuilding the trust database. This might take a few
    seconds.

- On the terminal, I get the following message:

    ** Message: switched engine to `/usr/bin/gpg2'

- I had to kill gpa from a terminal to close it
- I installed 0.9.3-1 from experimental and I got the same behaviour.
- I created a public/private key pair using the commandline, then start GPA: I
  still get the "General Assuan error" but I can click close, and then
  use the GPA interface. However, most actions throws "General Assuan
  error" and fail

Thanks by advance for your work,

Kjö

#760237#135
Date:
2012-10-05 10:01:42 UTC
From:
To:
severity 634930 grave
thanks

Hi,

Daniel Leidert wrote (08 Jul 2012 11:38:45 GMT) :

On my up-to-date Wheezy system:

* gpa 0.9.0-2 from Debian Wheezy:
  same error messages as reported on Debian bug #634930
* gpa 0.9.3-1 from Debian experimental:
  same error messages as reported on Debian bug #634930
* gpa 0.9.3-1 from Debian experimental, --disable-x509:
  works fine

I'm bumping the severity to "grave", as the version currently in
testing/sid looks "clearly unusable or mostly so" to me.

Thank you for maintaining GnuPG tools in Debian!

#760237#142
Date:
2012-10-06 23:05:27 UTC
From:
To:
Just to let you know that I can confirm this bug on a Ubuntu 12.04 amd64
setup. Since gpa is not available in the Ubuntu repositories, I
downloaded the 0.9.3 sources and compiled. The result is this same
error. I removed the home-compiled version and instead installed the
0.9.3 amd64 .deb version from the debian website
(http://ftp.ca.debian.org/debian/pool/main/g/gpa/gpa_0.9.3-1_amd64.deb),
and it fails with the same error.

Upon finding this thread I tried launching gpa from command line with
the --disable-x509 option, and the error disappears.

#760237#147
Date:
2012-11-10 18:22:40 UTC
From:
To:
Dear Maintainer,

I have v0.9.3 of GPA and am getting this error also, so I'm adding myself to
the bug report.

#760237#152
Date:
2012-11-24 17:53:39 UTC
From:
To:
Hi,

Not sure this is related, but "gpa -d" segfaults in libassuan for me on
a wheezy system.  See the attached backtrace, maybe it helps.


Cheers,

Michael

#760237#157
Date:
2012-11-30 09:30:50 UTC
From:
To:
I think this is not related.

The crash you are observing is due to a missing call to
assuan_sock_init() and was fixed upstream in
http://git.gnupg.org/cgi-bin/gitweb.cgi?p=gpa.git;a=commitdiff;h=de5ed61012cfc76d8ef0ebff81625331d43b8b28#patch1

I think you should open a separate bugreport for that.

#760237#164
Date:
2013-02-28 22:13:30 UTC
From:
To:
wheezy-ignore tag added.

Cheers,
Julien

#760237#171
Date:
2013-07-11 20:01:59 UTC
From:
To:
Dear Sir or Madam,

I just wanted to inform you that the below (message #75)from the thread
bug #634930 solved it. And that it _was_ necessary to delete .gnupg as well.

I did it on 2 different computers, both Ubuntu 13.04 64 bit.

Kind regards,
Markus


Message #75 received at 634930@bugs.debian.org (full text, mbox):
From: mnmnmnmn@tormail.org
To: 634930@bugs.debian.org
Subject: gpa: GPA unusable due to "General Assuan error"
Date: Sun, 8 Jul 2012 02:39:50 -0000
I have found that the problem is the expired X.509 certificates.
Here is my easy workaround to solve this bug.
1. Remove the file where the X.509 certificates are stored.
rm usr/share/gnupg2/com-certs.pem
2. Remove your gnupg configuration folder.
rm home/benutzer/.gnupg/
That's all. Should work for every version. Enjoy.

#760237#178
Date:
2014-01-07 18:38:17 UTC
From:
To:
Hello!

At first: I have Debian Wheezy (amd64) installed. And I have two users:
one user (joo) cannot use gpa, but the other user (adjoo) have no problem!
So I have tried to find the reason for this difference and I have found
this:

Found with "set" command as user "joo":
  GPG_AGENT_INFO=/home/joo/.cache/keyring-wrhM5J/gpg:0:1

But found with "set" command as user "adjoo":
  GPG_AGENT_INFO=/tmp/gpg-3z7tmb/S.gpg-agent:19715:1

Then I have tested in the terminal of "joo" other values with success:
  GPG_AGENT_INFO=/tmp/gpg-KEKPrV/S.gpg-agent:338:2
  GPG_AGENT_INFO=/home/joo/.cache/keyring-wrhM5J/gpg
  GPG_AGENT_INFO=/home/joo/.cache/keyring-wrhM5J/gpg:0:2
All this values can be used for starting gpa successfully!

Why gives the first value an error, but the other values not?
Especially the last value seems to be interesting?

Perhaps someone know the next step of analysis?
--- Have a nice day. Joachim (Germany)
#760237#183
Date:
2014-01-27 17:06:37 UTC
From:
To:
The following solution worked for me on wheezy (stable). Thanks, Joachim
Wiedorn, for the hint.

$ gpa # => "General Assuan error" + other messages as said in [1]
$ echo $GPG_AGENT_INFO
/home/user/.cache/keyring-kDmTeC/gpg:0:1
$ unset GPG_AGENT_INFO
$ gpa # => no error

According to the gpg manpage it appears safe to unset this value.

       GPG_AGENT_INFO
              Used to locate the gpg-agent.  This is only honored when
       --use-agent is set.  The value consists of 3 colon delimited
       fields: The first  is the  path  to  the Unix Domain Socket, the
       second the PID of the gpg-agent and the protocol version which
       should be set to 1. When starting the gpg-agent as described in
       its documentation, this variable is set to the correct value.
       The option  --gpg-agent-info  can  be  used  to override it.

Thanks for your work!

[1] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=634930#130

#760237#188
Date:
2014-08-31 12:45:05 UTC
From:
To:
I just installed a fresh Debian unstable VM, and installing
GPA from the repositories (0.9.4-1) on this fresh system doesn't give
the error.

Fresh machine, and a newly generated key (which took forever to
generate), doesn't give any problems, neither when using --disable-x509
or without it.

#760237#193
Date:
2014-08-31 21:08:04 UTC
From:
To:
Hi Andreas--

[cc'ing 634930@bugs.debian.org]

Thank you for stepping up to offer to look into this further!

It would be great to have more attention paid to GPA -- i just tried
testing it and i didn't get the errors reported, but i got different
errors and found that i couldn't use it.

I tried from a user account that doesn't have

The two dialogs i saw were:
------------------------------------------------------------------ The GPGME library returned an unexpected error. The error was: Unknown option This is probably a bug in GPA. GPA will now try to recover from this error. [ Close ] ------------------------------------------------------------------
------------------------------------------------------------------ You do not have a private key yet. Do you want to generate one now (recommended) or do it later? [ Generate key now ] [ Do it later ] ------------------------------------------------------------------ This last dialog box just stays up, no matter what buttons i click. Some possible questions that might make things clearer: * Have you tested it with from a new, clean user account? * What version of gnupg2 do you have installed? * What architecture are you using? * What desktop environment are you using? * What version of libassuan? If you can figure out how to reproduce some of these problems, you might consider looking into source. I just moved the gpa debian packaging source to git. You can clone it with: git clone git://git.debian.org/pkg-gnupg/gpa.git Feel free to send patches to the list if you figure out needed fixes: git config sendemail.to pkg-gnupg-maint@lists.alioth.debian.org thanks for the offer of help! hopefully we can get gpa more cleaned up together.
#760237#198
Date:
2014-09-01 13:29:39 UTC
From:
To:
-------------------------- 8< --------------------------

I am testing on a fresh unstable VM, running Xfce on amd64 -

gnupg2 - 2.0.26-2
libgpgme11 - 1.5.1-2
libassuan0 - 2.1.2-2
libgpg-error0 - 1.13-4

And now there was a new release of GPA - 0.9.5 -
Which contains

+ * Fixed several bugs leading to crashs.

in the changelog :)

Could you please try that one out and see if your problems are solved
by that? It compiles fine on my unstable VM, but gives some
warnings about deprecated functions (gpgme_op_assuan_result and
gpgme_op_assuan_transact)

I would gladly import that version into the git repo of pkg-gnupg.

#760237#203
Date:
2014-09-01 23:54:16 UTC
From:
To:
Control: clone -1 -2
Control: retitle -2 GPA fails obscurely when no gpg-agent is running
Control: severity -2 normal

Further testing reveals that the two dialog boxes show only when no
gpg-agent is present.

Instead of these behavior, GPA should probably detect the absence of an
agent, and either warn the user of its absence or start one up
automatically.

#760237#218
Date:
2015-07-04 13:59:52 UTC
From:
To:
#760237#223
Date:
2015-07-06 18:26:49 UTC
From:
To:
hi,

I prepared a patch for the above problem ; it is patch n 3 in
http://mennucc1.debian.net/gpa/

Patch 2 adds a dependency on gnupg-agent ... it makes sense since gpa
does not work w/o

Patch 1 is a minor fix for what I proposed in 791416

patch 4 is a changelog, so that I compiled two versions for jessie i386
and jessie amd64 ; I am using them, it seems to work fine

 bye,
    a.