The officially official Devuan Forum!

You are not logged in.

#1 2022-09-25 12:34:34

Altoid
Member
Registered: 2017-05-07
Posts: 1,583  

How many keyrings?

Hello:

I am still dealing with an issue already reported upstream and with BackinTime.

https://dev1galaxy.org/viewtopic.php?pid=30374

Unsurprisingly, no news from upstream but it is now being worked on by the BiT people.
Under new management (so to speak) as the package's maintainance had been severely neglected/abandoned for more than a couple of years.

I have recently come across a post which would apparently suggest that gnome-keyring could be having something to do with it.
Can't find it now.  8^/

It happens that I do have gnome-keyring installed ...

[root@devuan ~]# apt list | grep keyring | grep gnome | grep installed
--- snip ---
gir1.2-gnomekeyring-1.0/now 3.12.0-1+b2 amd64 [installed,local]
gnome-keyring-pkcs11/oldstable,now 3.28.2-5 amd64 [installed,automatic]
gnome-keyring/oldstable,now 3.28.2-5 amd64 [installed,automatic]
libgnome-keyring-common/now 3.12.0-1 all [installed,local]
libgnome-keyring0/now 3.12.0-1+b2 amd64 [installed,local]
libpam-gnome-keyring/oldstable,now 3.28.2-5 amd64 [installed,automatic]
[root@devuan ~]# 

... and when I ask aptitude I get this:

[root@devuan ~]# aptitude why gnome-keyring
i   pcmanfm       Recommends gvfs-backends
i A gvfs-backends Recommends gnome-keyring
[root@devuan ~]# 

So I also asked about gvfs-backends:

[root@devuan ~]# aptitude why gvfs-backends 
i   pcmanfm Recommends gvfs-backends
[root@devuan ~]# 

Does not seem like I need one or the other.
Does it?

Q: can I safely get rid of both gnome-keyring and gvfs-backends without screwing up something else?

Thanks in advance.

Best,

A.

Edit: format, spelling.

Last edited by Altoid (2022-09-25 14:38:25)

Offline

#2 2022-09-25 13:05:06

delgado
Member
Registered: 2022-07-14
Posts: 213  

Re: How many keyrings?

Hi,
the gvfs-* packages are useful for the mounting features in pcmanfm, e.g. disk partitions, usb drives when connecting, MTP devices / androd cell phones. Not strictly needed, but quite handy. Taste is different of course.

Offline

#3 2022-09-25 14:51:21

Altoid
Member
Registered: 2017-05-07
Posts: 1,583  

Re: How many keyrings?

Hello:

delgado wrote:

... gvfs-* packages are useful for the mounting features ...

I see.
Yes, I have pcmanfm installed.

delgado wrote:

Not strictly needed, but quite handy.

It is only suggested by pcmanfm and not a dependency.
But I do depend on cron and backintime to work properly.

I'll have to look into that some more.

Thanks for  your input.

Best,

A.

Offline

#4 2022-09-25 21:59:12

Altoid
Member
Registered: 2017-05-07
Posts: 1,583  

Re: How many keyrings?

Hello:

Altoid wrote:

... look into that some more.

I have thought about it and have not found reason (save the pcmanfm recomends) for having gnome-keyring installed.
Same for gvfs-backends for that matter.

ie: my basic reasoning is that they are not dependencies, just pcmanfm recommends.
And I have seen that recommends can sometimes be silently problematic.

On a hunch, I wondered if this problem isn't being caused by having too many ***-keyring instances?

user@devuan:~$ apt list | grep installed | grep keyring
--- snip ---
debian-archive-keyring/oldstable,oldstable,now 2019.1+deb10u1 all [installed]
devuan-keyring/oldstable,oldstable,now 2022.09.04 all [installed]
gir1.2-gnomekeyring-1.0/now 3.12.0-1+b2 amd64 [installed,local]
libgnome-keyring-common/now 3.12.0-1 all [installed,local]
libgnome-keyring0/now 3.12.0-1+b2 amd64 [installed,local]
python-keyring/oldstable,oldstable,now 17.1.1-1 all [installed,automatic]
python-keyrings.alt/oldstable,oldstable,now 3.1.1-1 all [installed,automatic]
python3-keyring/oldstable,oldstable,now 17.1.1-1 all [installed,automatic]
python3-keyrings.alt/oldstable,oldstable,now 3.1.1-1 all [installed,automatic]
user@devuan:~$ 

There's one sure way to find out: purge both gnome-keyring and gvfs-backends, which I did at noon today.

I have observed no ill effects after three or four reboots, mounting/unmounting of Palm T|Xs, external USB HDs and six hours uptime.
Now I'll just wait to see if I get any more mail in my mbox regarding BiT or whatever keyring.

Any suggestions?
Tests to do?

I'll post back if I get another message or in a fortnight, whatever comes first.

Best,

A.

Last edited by Altoid (2022-09-25 22:02:40)

Offline

#5 2022-09-26 12:41:20

Altoid
Member
Registered: 2017-05-07
Posts: 1,583  

Re: How many keyrings?

Hello:

Altoid wrote:

I'll post back if I get another message or in a fortnight, whatever comes first.

BiT is apparently working properly and cron has not sent me any mails.
But to check, I ran it manually and this is what I got:

user@devuan:~$ backintime backup
Gkr-Message: 08:42:53.971: secret service operation failed: The name org.freedesktop.secrets was not provided by any .service files

Back In Time
Version: 1.1.24

Back In Time comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to redistribute it
under certain conditions; type `backintime --license' for details.

INFO: Lock
WARNING: Inhibit Suspend failed.
WARNING: import keyring failed
INFO: Take a new snapshot. Profile: 1 Main profile
INFO: [qt4systrayicon] begin loop
INFO: Call rsync to take the snapshot
INFO: Save config file
INFO: Create info file
INFO: Remove backups older than: 20220117-000000
INFO: Keep min free disk space: 40960 MiB
INFO: Keep min 5% free inodes
INFO: Unlock
user@devuan:~$ INFO: [qt4systrayicon] end loop

The terminal output shows the import keyring failed warning is still there.
ie: whether gnome-keyring is installed or not, so it does not seem to be the what causes the BiT problem.

Then I tried checking the keyring:

user@devuan:~$ keyring get system username
Gkr-Message: 09:17:24.950: secret service operation failed: The name org.freedesktop.secrets was not provided by any .service files
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/dbus/bus.py", line 175, in activate_name_owner
    return self.get_name_owner(bus_name)
  File "/usr/lib/python3/dist-packages/dbus/bus.py", line 361, in get_name_owner
    's', (bus_name,), **keywords)
  File "/usr/lib/python3/dist-packages/dbus/connection.py", line 651, in call_blocking
    message, timeout)
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.NameHasNoOwner: Could not get owner of name 'org.freedesktop.secrets': no such name

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/secretstorage/util.py", line 55, in bus_get_object
    return bus.get_object(name, object_path, introspect=False)
  File "/usr/lib/python3/dist-packages/dbus/bus.py", line 241, in get_object
    follow_name_owner_changes=follow_name_owner_changes)
  File "/usr/lib/python3/dist-packages/dbus/proxies.py", line 248, in __init__
    self._named_service = conn.activate_name_owner(bus_name)
  File "/usr/lib/python3/dist-packages/dbus/bus.py", line 180, in activate_name_owner
    self.start_service_by_name(bus_name)
  File "/usr/lib/python3/dist-packages/dbus/bus.py", line 278, in start_service_by_name
    'su', (bus_name, flags)))
  File "/usr/lib/python3/dist-packages/dbus/connection.py", line 651, in call_blocking
    message, timeout)
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.secrets was not provided by any .service files

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/keyring/backends/SecretService.py", line 35, in priority
    list(secretstorage.get_all_collections(bus))
  File "/usr/lib/python3/dist-packages/secretstorage/collection.py", line 144, in get_all_collections
    service_obj = bus_get_object(bus, SS_PATH)
  File "/usr/lib/python3/dist-packages/secretstorage/util.py", line 59, in bus_get_object
    raise SecretServiceNotAvailableException(e.get_dbus_message())
secretstorage.exceptions.SecretServiceNotAvailableException: The name org.freedesktop.secrets was not provided by any .service files

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/bin/keyring", line 11, in <module>
    load_entry_point('keyring==17.1.1', 'console_scripts', 'keyring')()
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 489, in load_entry_point
    return get_distribution(dist).load_entry_point(group, name)
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 2793, in load_entry_point
    return ep.load()
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 2411, in load
    return self.resolve()
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 2417, in resolve
    module = __import__(self.module_name, fromlist=['__name__'], level=0)
  File "/usr/lib/python3/dist-packages/keyring/__init__.py", line 3, in <module>
    from .core import (
  File "/usr/lib/python3/dist-packages/keyring/core.py", line 189, in <module>
    init_backend()
  File "/usr/lib/python3/dist-packages/keyring/core.py", line 97, in init_backend
    or load_config()
  File "/usr/lib/python3/dist-packages/keyring/core.py", line 176, in load_config
    return load_keyring(keyring_name)
  File "/usr/lib/python3/dist-packages/keyring/core.py", line 137, in load_keyring
    class_.priority
  File "/usr/lib/python3/dist-packages/keyring/util/properties.py", line 26, in __get__
    return self.fget.__get__(None, owner)()
  File "/usr/lib/python3/dist-packages/keyring/backends/SecretService.py", line 38, in priority
    "Unable to initialize SecretService: %s" % e)
RuntimeError: Unable to initialize SecretService: The name org.freedesktop.secrets was not provided by any .service files
user@devuan:~$ 

What the ...
Not expected.

But if I check as root I get this:

[root@devuan ~]# keyring get system username
[root@devuan ~]# 

It seems the keyring has some sort of issue with my user or vice-versa.
But not with root.

Looking up the first error ie: org.freedesktop.DBus.Error.NameHasNoOwner here just gets me a rather obvious answer:

freedesktop.org/sd-bus-errors wrote:

Description

In addition to the error names user programs define, D-Bus knows a number of generic, standardized error names that are listed below.

In addition to this list, in sd-bus, the special error namespace "System.Error." is used to map arbitrary Linux system errors (as defined by errno(3)) to D-Bus errors and back. For example, the error EUCLEAN is mapped to "System.Error.EUCLEAN" and back.

--- snip ---
SD_BUS_ERROR_NAME_HAS_NO_OWNER
    The specified bus service name currently has no owner.
--- snip ---

That this does not happen as root makes sense as root owns the rig/OS and everything that goes on in it.

Is this a permissions issue for my user?
Is it a phython script problem?

eg: File "/usr/lib/python3/dist-packages/dbus/bus.py", line 175, in activate_name_owner

Any ideas as to how I can troubleshoot this?

Thanks in advance.

Best,

A.

Last edited by Altoid (2022-09-26 12:41:57)

Offline

#6 2022-09-26 13:40:22

MLEvD
Member
Registered: 2021-02-14
Posts: 141  

Re: How many keyrings?

I find gnome-keyring useful. Logging in automatically to desktop, gnome-keyring asks for login password when launching google-chrome. I like this because potential thieves can enjoy my music and video collection but not my online stuff, hopefully?

Offline

#7 2022-09-26 13:49:11

Altoid
Member
Registered: 2017-05-07
Posts: 1,583  

Re: How many keyrings?

Hello:

MLEvD wrote:

Logging in automatically to desktop ...

No, not for me.

MLEvD wrote:

... asks for login password when launching google-chrome.

Don't use that one, at least for the time being.

Thanks for your input.

Best,

A.

Offline

#8 2022-09-26 14:49:15

Altoid
Member
Registered: 2017-05-07
Posts: 1,583  

Re: How many keyrings?

Hello:

Altoid wrote:

Any ideas as to how I can troubleshoot this?

I rolled back and reinstalled gnome-keyring.
The same gnome-keyring that, along with gvfs-backends is a recommends of pcmanfm.

And that fixed it:

groucho@devuan:~$ keyring get system username
groucho@devuan:~$ 

keyring get system username opens up a window asking for a PW.

Edit:

The window name is Unlock Login Keyring and the contents reads:

------
Enter password to unlock your login keyring
The login keyring did not get unlocked when you logged in to your computer.
Password: .              . 
------

I had previously tried using the gnome-disks application without gnome-keyring installed and it worked perfectly well: I was asked for a PW to mount a drive.

There were no problems with gnome-keyring not being installed.

But why is this so?
Anyone has a clue about this?

Why isn't gnome-keyring a dependency if it is needed?

Which would beg the question: why is gnome-keyring needed if there are a few other keyrings installed?

debian-archive-keyring
devuan-keyring
python-keyring
python-keyrings.alt
python3-keyring
python3-keyrings.alt

I searched yet some more and found a lead here:

Admin at gbe0.com wrote:

... realized that the problem was not limited just to Docker, any services using libsecret were broken. As I use KeePassXC with libsecret integration I took a look in the settings and it turns out the integration was disabled. I purged the gnome-keyring package again, killed the gnome-keyring service and enabled the KeePassXC integration and it all worked as usual.

I'd appreciate some insight on this.
ie: why must I have gnome-keyring installed.

Thanks in advance.

Best,

A.

Last edited by Altoid (2022-09-27 00:27:42)

Offline

#9 2022-09-27 06:41:04

MLEvD
Member
Registered: 2021-02-14
Posts: 141  

Re: How many keyrings?

From what I can see from installing debian on a day to day laptop and over a dozen eee pc;

Gnome keyring optionally protects you from lazy login security risk on regular laptop.

On the eee pc, there is no browser to secure, having only 3.5GB ssd and half a gig of ram, the savings in space and resources are worth having and there appears to be no advantage in using gnome-keyring.

On a modern desktop or laptop, the eee pc argument is irrelevant.

If gnome-keyring bothers you, remove it but stay safe. If if doesn't bother you, just leave it.

Offline

#10 2022-09-27 06:59:04

ralph.ronnquist
Administrator
From: Battery Point, Tasmania, AUS
Registered: 2016-11-30
Posts: 1,256  

Re: How many keyrings?

Well, "gnome-keyring" is a program, not a collection of keys.

Online

#11 2022-09-27 12:27:36

Altoid
Member
Registered: 2017-05-07
Posts: 1,583  

Re: How many keyrings?

Hello:

MLEvD wrote:

... from installing debian on a day to day laptop and over a dozen eee ...

The same stuff I have.
A Sun Ultra24 and an Asus 1000HE with 2Gb RAM and 500Gb HDD.

MLEvD wrote:

Gnome keyring optionally protects you from lazy login security risk on regular laptop.

I see.

Please excuse my ignorance in this specific matter (there are others but I digress ...)

I have gnome-keyring in my U24's Devuan installation but I see that I also have a few other keyrings.

debian-archive-keyring
devuan-keyring
python-keyring
python-keyrings.alt
python3-keyring
python3-keyrings.alt

Until my issues with Back-in-Time, all this keyring thing had always been transparent to me, to the extent that I don't really know what it does.

The cron job running BiT sends a warning every so often (can't reproduce) but the job gets done with no problems and that is why I'm looking at gnome-keyring now.

I have read that BiT has to see at least one of these is installed: python-keyring-kwallet, python-secretstorage and python-gnomekeyring.

Of those three, my installation has python-secretstorage but has a problem if gnome-keyring is not there. 

Maybe I should purge gnome-keyring and install python-gnomekeyring?

MLEvD wrote:

If gnome-keyring bothers you, remove it ...

Not really bother, just that with the exception of gnome-disks which I use every so often, I am sort of allergic to gnome so I'd rather avoid it.
But gnome-disks does not depend on gnome-keyring.

Thank you for your input.

Best,

A.

Offline

Board footer