Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CLI: Error getting password from keyring #722

Open
31ank opened this issue Jan 26, 2024 · 9 comments
Open

CLI: Error getting password from keyring #722

31ank opened this issue Jan 26, 2024 · 9 comments
Labels
--cli Platform is CLI help wanted Extra attention is needed

Comments

@31ank
Copy link

31ank commented Jan 26, 2024

I'm running a headless Ubuntu 22.04.3 server and tried installing the deb package from the release tab. When I try to execute a ente command I get the error error getting password from keyring: failed to unlock correct collection '/org/freedesktop/secrets/collection/login'.
I installed the gnome-keyring-daemon since that seems to be required but that didn't fix the problem.

I'm out of ideas since you don't find much information online regarding this error, does someone know what the issue could be?

@sarunaskas
Copy link

Same issue here on an ubuntu server after install the .deb package.

I installed gnome-keyring and the error changed to error getting password from keyring: failed to unlock correct collection '/org/freedesktop/secrets/aliases/default'

@31ank
Copy link
Author

31ank commented Feb 20, 2024

@sarunaskas if you find a solution please post it here, I didn't find one yet ☹️

@mnvr mnvr transferred this issue from ente-io/cli Mar 6, 2024
@mnvr mnvr added help wanted Extra attention is needed --cli Platform is CLI labels Mar 6, 2024
@mnvr mnvr changed the title error getting password from keyring CLI: Error getting password from keyring Mar 6, 2024
@RappyTV
Copy link

RappyTV commented Mar 13, 2024

+1

@AlexandarY
Copy link

I encountered the error from #1328, but at one point it evolves into the error above. The steps described here helped me fix the error. TL;DR on steps:

eval "$(dbus-launch --sh-syntax)"

mkdir -p ~/.cache
mkdir -p ~/.local/share/keyrings # where the automatic keyring is created

# 1. Create the keyring manually with a dummy password in stdin
eval "$(printf '\n' | gnome-keyring-daemon --unlock)"

# 2. Start the daemon, using the password to unlock the just-created keyring:
eval "$(printf '\n' | /usr/bin/gnome-keyring-daemon --start)"

@RappyTV
Copy link

RappyTV commented Apr 9, 2024

I encountered the error from #1328, but at one point it evolves into the error above. The steps described here helped me fix the error. TL;DR on steps:


eval "$(dbus-launch --sh-syntax)"



mkdir -p ~/.cache

mkdir -p ~/.local/share/keyrings # where the automatic keyring is created



# 1. Create the keyring manually with a dummy password in stdin

eval "$(printf '\n' | gnome-keyring-daemon --unlock)"



# 2. Start the daemon, using the password to unlock the just-created keyring:

eval "$(printf '\n' | /usr/bin/gnome-keyring-daemon --start)"

doesn't work for me unfortunately

@RxnNode
Copy link

RxnNode commented Jul 4, 2024

The workaround doesn't work for me either.

@pinpox
Copy link
Contributor

pinpox commented Jul 11, 2024

Same here, gnome-keyring is running but the ente CLI refuses to do anything:

❯ ./cli account list
2024/07/11 18:20:20 error getting password from keyring: failed to unlock correct collection '/org/freedesktop/secrets/collection/login'

❯ gnome-keyring version
gnome-keyring: 46.1

@pinpox
Copy link
Contributor

pinpox commented Jul 11, 2024

For anyone running into this and wanting to use the cli without gnome-keyring, see my PR #2426

ua741 added a commit that referenced this issue Jul 24, 2024
## Description

Adds a new enviroment variable `ENTE_CLI_SECRETS_PATH`, that allows
specifying the path to a `secrets.txt` like the one used in the
dockerized version. If no path is provided, the old behaviour is
maintained.

The configuration variable and behaviour is analog to the already
present `ENTE_CONFIG_PATH` variable, which allows specifying a
configuration.

This provides a solution for people running without gnome-keyring
(#722 and
#1328)
@reorx
Copy link

reorx commented Aug 6, 2024

Since the CLI is an HTTP client of the Ente server, running it in a desktop environment can likely avoid keyring issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
--cli Platform is CLI help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

8 participants