I am trying to unlock the Gnome Keyring Daemon from the command line, by directly passing it a password. I tried a few variations of --daemonize, --login, --start, but I can't get it to work.
echo $password | gnome-keyring-daemon --unlock returns
SSH_AUTH_SOCK=/run/user/1000/keyring/ssh but doesn't unlock anything.
Basically I want something along the lines of:
gnome-keyring-daemon unlock --pw $password
Not sure if it makes any difference, but I'm on Manjaro i3wm version, so not using a desktop environment.
I'm using KeePassXC to manage my keyring. The one downside to this is, that I can't automatically unlock the keyring on login. Since I don't want to enter two long passwords I came up with the following script as a workaround:
- Logging in automatically unlocks Gnome Keyring Daemon
- Gnome Keyring Daemon contains (a part of) the PW to KeePassXC as the only entry
- enter the last characters of the pw in a prompt
- kill Gnome Keyring Daemon
- use the combined pw to unlock KeePassXC
Now I want to do the opposite to lock KeePassXC again:
- Get PW to Gnome Keyring Daemon from KeePassXC
- Kill KeePassXC
- Unlock GnomeKeyringDaemon <- this is the part I can't get to work