409

Whenever Ubuntu boots up, a dialogue pops up asking me to unlock my default keyring.

Is there some way this can unlock automatically through PAM or some other magical way?

unlock login keyring

Lorenz Keel
  • 8,905
Oli
  • 293,335
  • 3
    See also: http://askubuntu.com/q/495957/178596 – Wilf Dec 31 '14 at 07:49
  • 1
    This seems dangerous, is there not a way to hook into PAM to unlock via ssh-key? – MrMesees May 09 '17 at 17:39
  • 15
    I can't believe the top answers just amount to "remove your password". For real!? – pattivacek Apr 30 '18 at 08:58
  • 2
    @patrickvacek If you allow automated login, and want to automatically unlock the keyring, what use is a password? – Oli Apr 30 '18 at 09:24
  • 1
    The question does not specify automatic login, and using it is not something I'd recommend! But you are right, if you are using it, the rest of your passwords are worthless. – pattivacek Apr 30 '18 at 10:02
  • 1
    WARNING! Don't remove the password! The secure way is to use the login keyring as default instead! This way, the keys won't be stored unprotected. If you already type your user password to login in the OS, you won't be asked for the password again. If you auto-login, you will be asked for your password. This should be the accepted answer. Using empty password is only OK if your home folder is already under an encrypted filesystem, like with LUKS, but I still wouldn't recommend it, because any program running can still see the file. – geekley Aug 04 '20 at 05:50
  • This prevents my screen from turning off – endolith Mar 15 '21 at 03:59
  • You may just run keyring --disable in terminal and it will not bother you again – Enkum Sep 21 '22 at 09:31
  • How can you disable this nagging me? I dont want to disable passwords, it is just super annoying it popping up every 4 minutes after I closed it without giving the password. It is also some kind of stupid dialog that blocks the whole screen, I can't do anything else, so that makes it super annoying. This is on Debian 11 stable. – Markus Bawidamann May 07 '23 at 05:21

12 Answers12

182

Be warned that this will make your keyring accessible without a password. Period. You don't have to be logged in to view it

With that being said,

I think the simplest way is to set the password for the keyring to an empty password -- you will not be prompted for a password then:

  1. Open Applications -> Accessories -> Password and Encryption Keys
  2. Right-click on the "login" keyring
  3. Select "Change password"
  4. Enter your old password and leave the new password blank
  5. Press ok, read the security warning, think about it and if you still want to get rid of this dialog, choose "use unsafe storage".

Again, as the message says: This will expose all your passwords (e.g. email passwords) that you chose to save in the default keyring to anyone using your computer or having access to your files and is therefore not recommended.

Addendum for Ubuntu 11.04:

  • In the default Unity session, you can start the application by clicking on the Ubuntu logo in the top left corner, then typing Password, and selecting Password and Encryption Keys from the search result.

  • In the classic session the path to start the application has changed to System → Preferences → Password and Encryption Keys

Addendum for Ubuntu 11.10:

  • In the default Unity session, you can start the application by clicking on the Ubuntu launcher (the first item) in the Unity launcher bar on the left side, then typing Password, and selecting Password and Encryption Keys from the search result.

  • In the classic session (from the gnome-session-fallback package) the path to start the application has again changed to Applications → Other → Password and Encryption Keys

htorque
  • 64,798
  • 1
    Thanks for the tip, also Password and Encryption keys have moved to System > Preferences in 11.04 – Drew Jun 30 '11 at 15:54
  • 1
    how to on 12.04? – Fanoy Apr 05 '12 at 19:00
  • 2
    Mac OSX encrypts the passwords, but still manages to auto-login. Keys are protected 'as usual' when logged in. The only additional threat is loosing physical access to your computer. Will Ubuntu provide a similar feature in the future? –  May 11 '12 at 08:12
  • Thank you, @Fanoy go to The Menu and type password & Keys. And delete the Deafult one, after this - it'll ask you a new password . just leave it blank. And Click OK – hardianto May 27 '12 at 12:18
  • Sadly doesn't work on 12.10 because of a bug. When you try to change the password it says: GDBus.Error:org.freedesktop.Secret.Error.NoSuchObject: The collection does not exist But it is apparently fixed in the latest version. – Timmmm Dec 23 '12 at 22:52
  • in 12.10 did the steps as above (except it's moved to system preferences as Drew says) and now for any admin changes I don't know the password - it's not my old password and it's not nothing. So now I have to find out how to reset my password. Brilliant. – dez93_2000 Jan 22 '13 at 22:27
  • @dez93_2000: The password for "admin changes" has nothing to do with the keyring that this answer is about. If an application (e.g. software center) asks for your password to do adminstrative tasks, it is using essentially the sudo mechanism, asking for the password of a user with admin privileges. sudo does not care about the keyrings. So your user password (given that this user has admin rights) should work. – Marcel Stimberg Jan 23 '13 at 13:29
  • While login I chose some other Desktop Environment (Ex) Enlightenment, instead Gnome. A quick short ugly temporary work around. – ganesh Dec 03 '14 at 15:14
  • i just click "Cancel". There does not seem to be any drawback to clicking cancel instead of entering the password. Ubuntu still asks me for the keyring later during the session for other stuff that needs it. – johny why May 22 '15 at 22:23
  • 9
    After a few restarts the popup comes back again.. I have changed the password to blank about 100 times by now.. but after every few restarts this idiotic and annoying popup comes up again.. I hate it.. – Muhammad bin Yusrat Aug 21 '15 at 11:57
  • Person that use my computer will have physical access, though he can access to my passwords in either case. – Nusrat Nuriyev Dec 25 '17 at 22:39
  • 2
    doesn't work... where is "Applications -> Accessories -> Password and Encryption Keys"???? it doesn't exist – Nicolas S.Xu Mar 15 '19 at 14:20
  • 1
    Where can you do that on KDE Plasma? – xeruf Feb 04 '20 at 14:56
  • 1
    in Linux-Mint v20 is no 'Right-click on the "login" keyring' in my machine :( – SL5net Sep 03 '20 at 04:33
  • Go to "Applications" > "Password and Encryption Keys", and use right-click you can see the "change password" button – p3nchan Jun 23 '21 at 03:15
  • The application is actually called "seahorse" – robertspierre Jan 21 '23 at 15:47
  • On Ubuntu 22.04: search for 'seahorse' and open. Right click on 'Login' under ' Passwords' (might need to do a few times, didn't work at first). In the context menu pick 'Change Password'. Enter the current password and leave the new password fields blank. Accept 'Store passwords unencrypted?' – SaeX Mar 16 '24 at 19:01
82

For Ubuntu 12.10 and onwards

The interface of the "Password and Keys" manager changed slightly in 12.10. When you open it, you won't immediately see the "Login" keyring as described in other answers. The interface will look like this:

screenshot

In order to view the Login keyring, you need to open the View menu, and choose By Keyring. Once that's done, your interface will look like this:

screenshot

Right-click on the "Login" entry at the top and pick Change Password. You'll need to enter the current password, which should be your user account password, before continuing. When you do that, you'll get a dialog where you will be asked to enter the new password twice:

screenshot

Leave this blank, choose "Continue", and choose it again to confirm your desire to continue without a password.

Pablo Bianchi
  • 15,657
  • 2
    Perfect, this applies to 13.04. – Gabriel May 05 '13 at 22:47
  • "Right-click on the "Login" entry at the top and choose Change Password. You'll need to enter the current password, which should be your user account password, before continuing. When you do that, you'll get a dialog where you will be asked to enter the new password twice:" Bold font to highlight the query i have which is how to if can not do as described due to seahorse using different password from the one which is used to log on desktop session. Asked this q http://askubuntu.com/q/328347/102029. Vote to reopen please... – geezanansa Aug 10 '13 at 02:41
  • 1
    Worked Ok for 13.10 – netimen Feb 05 '14 at 13:17
  • Setting a blank password causes gnome-shell to crash. – Jamie Jan 11 '17 at 18:51
  • did this in 18 and re-entered my password to fix unlocking on login with my password! – Chad Jun 30 '20 at 19:30
  • in Linux-Mint v20 it ask me anyway – SL5net Sep 03 '20 at 05:02
  • Helped me in 20.10 with KDE session. This keyring was very annoying if take into account that I've already had KDE keyring. For comparison - KDE keyring could be easily disabled in settings. Don't like GNOME even more now. – Dmitriy Vinokurov Jul 25 '21 at 17:04
  • Doesnt work no login keyring. I want login password I dont want keyrings – Philip Rego Feb 23 '22 at 13:36
  • 1
    Is this scriptable? – whirlywhale Oct 25 '23 at 12:50
  • @whirlywhale - What I do is save the the keyring file in a tar file an untar it for each new VM: tar cf .local/share/keyrings/login.keyring. YMMV, and no warranties expressed or implied. – Jeff Learman Mar 07 '24 at 15:23
50

For versions up to 12.04: (for 12.10 onwards, see this answer)

The method is similar to previous Ubuntu versions, but I also include a command-line alternative at the end.

1. Using the Gnome Keyring Manager (Seahorse)

  • Press Alt+F2, type seahorse and press Enter to start the Gnome Keyring Manager:

    enter image description here

  • Alternately, open a terminal with Ctrl+F2+T, type seahorse & and press Enter.

  • The "Passwords and Keys" window should come up as shown below. Under the Passwords tab, select login, right-click on it, and then click on Change Password:

    enter image description here

  • The "Change Keyring Password" box will come up. Type your old password, and then leave the new/confirm password fields blank. Then press OK, and the information box shown below will pop-up; read it, and then click on Use Unsafe Storage to not have to enter your password at each login:

    enter image description here

  • Close the keyring manager. After you log out/reboot, you won't be asked for your password any more.

2. Disable the login keyring password from the command-line

As an alternative to all the above steps, simply open a terminal, and type/paste the below, changing MYPASSWORD to whatever your current password is; that's it!

python -c "import gnomekeyring;gnomekeyring.change_password_sync('login', 'MYPASSWORD', '');"
ish
  • 139,926
  • 3
    For the 1st part this is my "seahorse" application window !! No sign of any passwords tabs. So the 1st part is not valid

    However, for the 2nd part. This was the amazing soultion. No more annoying "keyring" Thanks :)

    – Suhaib Sep 15 '12 at 00:30
  • Command-line is a workaround on Ubuntu 14.04 since it make gnome crash when trying to set an empty password to Login keyring. – Giovanni Toraldo Nov 09 '14 at 08:49
  • +1 for cli example. I'm on Xbuntu and this was the only applicable fix. While Xbuntu was able to shed all the weirdo GUI stuff, the keyring clung still... – Krista K Dec 10 '14 at 03:49
  • Thanks. After I installed seahorse and followed your instructions the pop-up stopped to appear. It appeared each time I ran remmina. Using Ubuntu 18.04.2 LTS – ka3ak Jul 18 '19 at 18:42
  • For pything method is says no module named gnomekeyring I have tried pip install gnomekeyring, nothing happens... Ubuntu 22.04 though – Aleksandar Pavić Feb 01 '23 at 10:22
30

Simply delete your default keyring. (Backup the passwords first!) You don't need it. You can keep all your keys in the login keyring.

The login keyring is unlocked when you login. All keys in it will be available, you don't have to enter more passwords again.

If you are using auto-login, then when you want to access something that needs a key from the login keyring you will be prompted for the password, of course, but only once.

(As many answers already pointed out) your keyrings are in System / Preferences / Passwords and Encryption Keys

janos
  • 4,888
  • 4
    This helped me and is the correct answer if the problem is that you have two keyrings. I had two, and the one named "default" did not get unlocked at login. I would add that after deleting the second keyring, you must make the login keyring the default – Organic Marble Mar 21 '20 at 00:21
  • 4
    To do this, go into ~/.local/share/keyrings/ and delete Default_keyring.keyring. Then, to make login.keyring default, open default in a text editor and change its text to login. – geekley Aug 04 '20 at 05:29
  • This seems to be the best answer. At least for my problem. I don't want a computer without security but once I have logged in, I don't really want to be bothered again. – Alexandre Neto Apr 18 '21 at 09:25
  • I only have login keyring, but I still get keyring prompt when I first open chrome. – Philip Rego Feb 22 '22 at 06:15
  • This is great. Any way to copy over all passwords/secrets from Default keyring to login before I delete the Default? – Radix Salvilines May 24 '23 at 10:59
18

Use this if you have forgotten the old password and is ok to delete items in the old keyring, but want to safeguard new keyring with matching password.

For Ubuntu 14.04, I used the following.

Remove old keyring:

cd .local/share/keyrings/
rm *.keyring

Restart the system to have the new keyring created:

sudo shutdown -r now

Verify the new keyring exists:

cd .local/share/keyrings/
ls -ltr *.keyring
muru
  • 197,895
  • 55
  • 485
  • 740
Kingsly
  • 361
  • It works for me. – yAnTar Aug 31 '17 at 12:32
  • "Nuke 'em from orbit. It's the only way to be sure" - Sad that I had to read so far down to find a working solution. In other news, I still haven't figured out a way to change the login password the way gnome apparently REQUIRES it to be done or else we'll continually pester you with popups that can't be shut off without googling this question. Asshats. Seriously, it's been going on for YEARS and it's still an annoyance every time I change the password!!!! WHY!?!? I never use the damned thing, and there's no way to shut it off. – John Gilmore Mar 15 '23 at 20:36
16

You need to get the password for your login key ring to be the same as your normal login password.

To do this follow the path:

Open Applications > Accessories > Passwords and Encryption Keys

You will see under the passwords tab a list of keyrings. One should be called

"Passwords: login"

Click on the + and you should see a list of accounts that require passwords such as you Gwibber details, Evolution passwords etc.

This means when you log in all of these accounts will be unlocked by this login keyring.

To get the keyring to unlock when you log into Ubuntu, right click on "Passwords: login" and choose "Change Password"

You will then need to enter your current keyring password and set your new keyring password to be the same as your normal login password.

To test: Log out, log back in and open Evolution to prove that this has worked.

andrew.46
  • 38,003
  • 27
  • 156
  • 232
  • 2
    I think this only works when you're not set to automatically log in. – Matthew Aug 13 '10 at 19:37
  • 2
    It didn't work for me. Deleting the default keyring neither. It really sucks. – Bite code Oct 15 '10 at 11:07
  • 3
    Just to note that on Ubuntu 14.04 you can get to the Passwords and Encryption Keys window mentioned above by running the command seahorse from the command line (or searching for seahorse and then clicking on "passwords and keys") – eric Nov 12 '15 at 11:27
  • I tried multiple times and when I'm about to run back to windows, I decided to try putting different password on "login" and the "default" keyring. Then I just tip the "unlock the keyring every time you login" – egotopia Jan 24 '16 at 23:51
  • They're already the same. They still ask for keyring – Philip Rego Feb 23 '22 at 13:37
9

For Ubuntu 21.04 If your error is like

WARNING: Keyring is skipped due to an exception: Failed to unlock the keyring!

A popup will show on the screen everytime click on classic encrypted then finish. It will ask you the password Please type no password and confirm it will again ask you syntax must be filled something.

If you created you password and it will prompted every time.then do like this Step

  1. Go and search for password, keyring or seahorse:

    screenshot

    screenshot

    screenshot

    You will find like this Password and Keys.

  2. Click on Login and click right mouse buton select Change password.

    screenshot

    screenshot

  3. Type your login user password

    screenshot

  4. Leave Blank

    screenshot

  5. Click Continue.

  6. Again Continue.

    screenshot

Pablo Bianchi
  • 15,657
9

Using Ubuntu 11.10 with Unity:

  1. Open "Passwords and Keys" application
  2. In the Passwords tab, right click on the password icon
  3. Select "Change Password"
  4. Enter your current password as the "Old Password"
  5. Leave the "New Password" and "Confirm" fields empty
  6. Click "Ok"
  7. Confirm to "Use Unsafe Storage"

Hope that works for you

Yi Jiang
  • 1,206
3

As the other answers say, disable auto-login and ensure that the keyring password is the same as the login password.

If it still doesn't work then you may be missing the required package. On Ubuntu 19_10 I had to run

sudo apt-get install libpam-gnome-keyring
AdamS
  • 605
2

For Ubuntu 13.10:

  1. Open Applications -> Accessories -> Password and Encryption Keys

  2. Click View -> "By keyring"

  3. Right-click on the "login" keyring

  4. Select "Change password"

  5. Enter your old password and leave the new password blank
  6. Press ok, read the security warning, think about it and if you still want to get rid of this dialog, choose "use unsafe storage".
Eric Leschinski
  • 2,221
  • 1
  • 20
  • 24
0

I have solved this problem through terminal.There is a directory under /usr/lib , called gnome-keyring. Under that directory there are a directory 'devel' and two files gnome-keyring-prompt and gnome-keyring-prompt-3.I don't know much about the directory 'devel'.So I removed only the two files and solved the problem.The corresponding commands are here-

cd /usr/lib/gnome-keyring

Then

sudo rm gnome-keyring-prompt gnome-keyring-prompt-3

And then reboot your computer to see the effect.

  • What are those files you deleted? – Severo Raz Jan 19 '21 at 20:51
  • Disables the prompt by removing the code that creates it! Nice! Too bad it will be re-created when that component is upgraded. If only there was some way to configure stuff in your home directory so it would NEVER do that to start with. (I haven't found any) – John Gilmore Mar 15 '23 at 20:39
-2

open passwords and keys then

enter image description here

enter image description here

Then you need to enter your current password (old password). Don't enter any password for your new one, or leave it blank.

You need to confirm that you will store unencrypted password. If you are sure that it is what you want, then just click "Use Unsafe Storage" button.