The forked one at https://github.com/keybase/go.dbus has issues that make it incompatible with current systems, causing "authentication failed" errors. This is likely caused by using the user name instead of the user id in the auth.go in the custom dbus package, which https://github.com/godbus/dbus fixes, likely among other fixes.
$ go run _examples/list-names.go
Currently owned names on the session bus:
org.freedesktop.DBus
:1.7
org.freedesktop.Notifications
org.keepassxc.KeePassXC.MainWindow
:1.8
org.papill0n.Healthy
<more output here>
The forked one at https://github.com/keybase/go.dbus has issues that make it incompatible with current systems, causing "authentication failed" errors. This is likely caused by using the user name instead of the user id in the
auth.go
in the custom dbus package, which https://github.com/godbus/dbus fixes, likely among other fixes.With the switch the connection to DBus works again on several Linux-based systems with various DBus versions running.
To see the exact error, you can run https://github.com/keybase/go.dbus/blob/master/_examples/list-names.go which does not work anymore on modern Linux systems.
(
GO111MODULE
is necessary because go.dbus does not have a go.mod file.)In contrast, https://github.com/godbus/dbus/blob/master/_examples/list-names.go works: