Re: [Pkg-utopia-maintainers] Bug#800032: pinentry-gnome3: Pinentry hangs for ~30s before asking for passphrase when invoked by Enigmail

2016-11-01 Thread Daniel Kahn Gillmor
On Tue 2016-11-01 11:49:29 -0400, Ondřej Kuzník wrote:
> On 17/10/16 21:01, Simon McVittie wrote:
>> On Mon, 17 Oct 2016 at 12:35:21 -0400, Daniel Kahn Gillmor wrote:
>>> On Mon 2016-10-17 09:27:14 -0400, Ondřej Kuzník wrote:
 Hmm, for some reason I have two dbus-daemons running and the one started
 by ck-launch-session is the one where pinentry is having problems.
>> 
>> What is in their argv? (/proc/*/cmdline)
>> 
>> Is ck-launch-session something to do with ConsoleKit? If so, it's probably
>> a bad idea at this point.
>
> Yes, this comes from a time when suspending the system and
> network-manager operations wouldn't work otherwise since the session
> wouldn't know how to authenticate me. Apparently that hack is not
> necessary anymore.
>
>> Is there anything interesting in syslog (or equivalently the systemd
>> Journal)? Recent dbus versions log a lot more there than they used to.
>> 
>> I hope something here has pointed you in an informative direction.
>
> Thanks for the hints, making sure that I don't start the second daemon
> lets everything use the right one and pinentry comes up immediately.
>
> This was then self-inflicted and not a problem in any software involved.

Thanks for the followup here, Ondřej.  I'm closing this bug report, but
feel free to re-open it if you have any suggestions for how any of the
involved software could be improved to avoid similar problems in the
future.

Regards,

--dkg


signature.asc
Description: PGP signature
___
Pkg-utopia-maintainers mailing list
Pkg-utopia-maintainers@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-utopia-maintainers

Re: [Pkg-utopia-maintainers] Bug#800032: pinentry-gnome3: Pinentry hangs for ~30s before asking for passphrase when invoked by Enigmail

2016-11-01 Thread Ondřej Kuzník
On 17/10/16 21:01, Simon McVittie wrote:
> On Mon, 17 Oct 2016 at 12:35:21 -0400, Daniel Kahn Gillmor wrote:
>> On Mon 2016-10-17 09:27:14 -0400, Ondřej Kuzník wrote:
>>> Hmm, for some reason I have two dbus-daemons running and the one started
>>> by ck-launch-session is the one where pinentry is having problems.
> 
> What is in their argv? (/proc/*/cmdline)
> 
> Is ck-launch-session something to do with ConsoleKit? If so, it's probably
> a bad idea at this point.

Yes, this comes from a time when suspending the system and
network-manager operations wouldn't work otherwise since the session
wouldn't know how to authenticate me. Apparently that hack is not
necessary anymore.

> Is there anything interesting in syslog (or equivalently the systemd
> Journal)? Recent dbus versions log a lot more there than they used to.
> 
> I hope something here has pointed you in an informative direction.

Thanks for the hints, making sure that I don't start the second daemon
lets everything use the right one and pinentry comes up immediately.

This was then self-inflicted and not a problem in any software involved.

Cheers,
Ondrej



signature.asc
Description: OpenPGP digital signature
___
Pkg-utopia-maintainers mailing list
Pkg-utopia-maintainers@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-utopia-maintainers

Re: [Pkg-utopia-maintainers] Bug#800032: pinentry-gnome3: Pinentry hangs for ~30s before asking for passphrase when invoked by Enigmail

2016-10-17 Thread Simon McVittie
On Mon, 17 Oct 2016 at 12:35:21 -0400, Daniel Kahn Gillmor wrote:
> On Mon 2016-10-17 09:27:14 -0400, Ondřej Kuzník wrote:
> > For all of the above I'd say yes, maybe apart from the query,
> > dbus-monitor doesn't say anything even though I can see dbus-daemon
> > starting new processes. It might be that I'm not passing it the options
> > to actually show that, do you know how to get it to display them?

Which dbus-daemon? In a correct configuration with a single login
session, you can usually have up to three:

* The system bus: runs as uid messagebus, is a system service like
  NetworkManager or logind, is how you communicate with such things
  (look for uid messagebus, or /proc/*/cmdline mentioning --system)

* The session bus: runs as your own uid, is part of your own
  personal environment like gnome-settings-daemon, gvfs or gpg-agent
  (look for /proc/*/cmdline mentioning --session)

* The accessibility bus: runs as your own uid, is a weird accessibility
  thing, 1 per X11 DISPLAY, every accessibility-enabled GUI talks to it
  (look for /proc/*/cmdline mentioning
  --config-file=/usr/share/defaults/at-spi2/accessibility.conf)

Confusingly, at-spi-bus-launcher is a session bus service (like gvfs or
gnome-keyring or whatever), and at-spi-bus-launcher is responsible
for starting the accessibility bus; so it's tied up with two separate
buses.

If you use systemd as pid 1, systemd-cgls is a nice way to get an overview
of how your processes relate to each other, which isn't fooled by the
"double-fork to daemonize" idiom.

All of the dbus-monitor commands below can be stopped by Ctrl+C:

To monitor the session bus: dbus-monitor --session

To monitor the system bus: sudo dbus-monitor --system (Debian >= stretch)

To monitor the accessibility bus:
* dbus-send --session --dest=org.a11y.Bus --print-reply /org/a11y/bus 
org.a11y.Bus.GetAddress
* it should promptly report something like
  string 
"unix:abstract=/tmp/dbus-11,guid="
* copy/paste it into a command like
  dbus-monitor --address 
unix:abstract=/tmp/dbus-11,guid=
* watch in despair as vast amounts of accessibility spam goes past,
  reporting every mouse movement, keypress, etc.
* wonder why the authors of AT-SPI thought D-Bus was the right hammer for
  this particular nail

> > Hmm, for some reason I have two dbus-daemons running and the one started
> > by ck-launch-session is the one where pinentry is having problems.

What is in their argv? (/proc/*/cmdline)

Is ck-launch-session something to do with ConsoleKit? If so, it's probably
a bad idea at this point.

Is there anything interesting in syslog (or equivalently the systemd
Journal)? Recent dbus versions log a lot more there than they used to.

I hope something here has pointed you in an informative direction.

Regards,
S

___
Pkg-utopia-maintainers mailing list
Pkg-utopia-maintainers@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-utopia-maintainers

Re: [Pkg-utopia-maintainers] Bug#800032: pinentry-gnome3: Pinentry hangs for ~30s before asking for passphrase when invoked by Enigmail

2016-10-17 Thread Daniel Kahn Gillmor
Control: affects 800032 dbus

Hi Ondřej--

I'm cc'ing d...@packages.debian.org in the hops that someone there can
take a look at the combination of pinentry-gtk2 and dbus that might be
causing the hangs seens in https://bugs.debian.org/800032

I copy your note below in full for anyone coming newly to this
discussion.

Out of curiosity: do you have dbus-user-session installed?

Regards,

--dkg

On Mon 2016-10-17 09:27:14 -0400, Ondřej Kuzník wrote:
> On 12/10/16 08:26, Daniel Kahn Gillmor wrote:
>> Control: tags 800032 + moreinfo unreproducible
>> 
>> Hi Ondřej--
>> 
>> Sorry for taking so long to respond to this.  A few questions below:
>
> Hi Daniel,
> thanks for looking into this, although I'm not sure yet what exactly is
> going on there yet, I think you're onto something.
>
>> [...]
>> 
>> Is this still happening for you?  Do you have dbus installed?  is there
>> a dbus session running?  Is there a query on the dbus user session for
>> any particular service?
>
> For all of the above I'd say yes, maybe apart from the query,
> dbus-monitor doesn't say anything even though I can see dbus-daemon
> starting new processes. It might be that I'm not passing it the options
> to actually show that, do you know how to get it to display them?
>
>> I've seen reports of timeouts of ~30s before
>> waiting for some "org.a11y.Bus" service to respond.  Some of those
>> reports were cleared up with the installation or removal of the
>> at-spi2-core package, but i haven't been able to reproduce it myself.
>> Do you have at-spi2-core installed?  if so, what version?
>
> The package at-spi2-core is installed (the version currently in
> stretch), as it is depended on by gnome-core, I've not tried
> uninstalling it yet and hitting reinstall in aptitude has not changed
> the behaviour.
>
> One thing that does come up, though, is when I run process monitoring,
> pinentry-gtk-2 is started by gpg-agent, then dbus-daemon starts
> /usr/lib/at-spi2-core/at-spi-bus-launcher, that exits, then dbus starts
> gnome-keyring-daemon. Will try to change the monitor to give timings as
> well but kworker storms tend to fill the netlink socket before I get to
> the timeout so I'm trying to keep the monitoring tool as simple as I can
> at the moment.
>
> Hmm, for some reason I have two dbus-daemons running and the one started
> by ck-launch-session is the one where pinentry is having problems.
>
> Thanks,
> Ondrej


signature.asc
Description: PGP signature
___
Pkg-utopia-maintainers mailing list
Pkg-utopia-maintainers@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-utopia-maintainers