181

In Google Chrome, when I go to a login page, a window pops up asking to "Enter password for keyring 'default' to unlock". In most cases, whether I click Cancel or enter my password, the login form gets auto filled anyway.

How do I get rid of the popup? I want it to auto login each time, not ask for my system password. The dialog box never appears for any other apps.

muru
  • 197,895
  • 55
  • 485
  • 740
  • 38
    You can start chrome with the command line google-chrome --password-store=basic so that it won't ask use the gnome keyring. See: http://code.google.com/p/chromium/wiki/LinuxPasswordStorage Because there is a workaround that is specific to Chrome, this question should not be a duplicate. – Stephen Ostermiller Mar 25 '14 at 12:48
  • 24
    rm ~/.local/share/keyrings/* Now open Chrome, if it asks you for your password, do not enter one choose Continue each time and ignore any warnings. – xinthose Apr 24 '17 at 18:54
  • Agree with @StephenOstermiller, a detailed answer is https://ubuntuforums.org/showthread.php?t=2377036&p=13708937#post13708937 – new2cpp Feb 24 '18 at 18:57
  • Only way that worked is to edit gedit file command: sudo gedit /usr/share/applications/google-chrome.desktop find out the line starts with Exec and add : --password-store=basic it will be Exec=/usr/bin/google-chrome-stable --password-store=basic %U Save and done . source https://tipsonubuntu.com/2017/12/20/google-chrome-asks-password-unlock-login-keyring/ – Bassem Oct 19 '20 at 05:52
  • 2
    Thank you @xinthose. this was annoying me so much! your answer helped. – Amir Dora. Apr 04 '22 at 10:55

15 Answers15

88

From the manpage:

--password-store=<basic|gnome|kwallet>
Set the password store to use. The default is to automatically detect based on the desktop environment. basic selects the built in, unencrypted password store. gnome selects Gnome keyring. kwallet selects (KDE) KWallet. (Note that KWallet may not work reliably outside KDE.)

The easiest way to fix that in the launcher is to copy the .desktop file to your home folder and edit it (google chrome users should copy the appropriate file):

cp /usr/share/applications/chromium-browser.desktop ~/.local/share/applications

Then edit the new file such that the Exec line reads like this:

Exec=chromium-browser --password-store=basic %U

If you have any other Chromium app installed, their .desktop files should also be in ~/.local/share/applications, edit them accordingly.

  • 3
    Great, thanks! Except, the file I needed to edit was google-chrome.desktop rather than chromium-browser.desktop. – njlarsson Dec 31 '17 at 13:54
  • 5
    Has to be the most elegant solution on the page -- works for me in 18.04 (pre-release). – Dɑvïd Jan 16 '18 at 09:31
  • 4
    It works, but you need to do this every time chrome updates. – Pietro Coelho Apr 19 '18 at 13:36
  • 2
    does not work on ubuntu 19.04 – tatsu Apr 21 '19 at 13:13
  • It does appear to work on ubuntu 19.04 as of this date and Chrome 74 -- there are three Exec entries: [Desktop Entry], [Desktop Action new-window] and [Desktop Action new-private-window], and it is chrome-browser.desktop. Plus, since I did this, Brave stopped keyring prompting as well. And I changed updates from Automatically to Display in Software Updates so I don't have to do play this how-to-make-simple-things-hard game again for a while. – VanAlbert May 29 '19 at 10:59
  • Edit: This action didn't affect Brave at all -- it still prompts for keyring. Just wishful thinking, I guess. – VanAlbert May 30 '19 at 08:07
  • Did not work on 19.04. still prompts for password when chromium browser launches. – Norman Bird Jun 21 '19 at 21:14
  • @tatsu Does chromium-browser --password-store=basic work when run on terminal on 19.04? – jarno Sep 19 '19 at 15:42
  • @NormanBird even if you run it from terminal with the altered command line? – jarno Sep 19 '19 at 15:44
  • @PietroCoelho I wonder why. Do udpates change files in "~/.local/share/applications"? – jarno Sep 19 '19 at 15:45
  • The downside of this method is that you have to insert passwords again for different services, if you previously stored them in the keyring. – jarno Sep 21 '19 at 19:46
  • 1
    @jarno the downside of not using the keyring is you're not using the keyring. – Capi Etheriel Sep 21 '19 at 21:33
  • You should also modify ~/.local/share/xfce4/helpers/chromium-browser.desktop, if you use chromium-browser as default Web browser in Xfce. – jarno Sep 21 '19 at 22:54
  • Enabling chrome://flags/#passwords-migrate-linux-to-login-db might work for copying credentials from a keyring to '~/.config/chromium/Default/Login Data'. – jarno Sep 22 '19 at 13:32
  • The second command didn't work for me so I did sed -i 's/Exec=chromium-browser/& --password-store=basic/g' ~/.local/share/applications/chromium-browser.desktop – Joachim Bsh Jan 31 '20 at 16:48
  • So annoying. And I am not even using Chrome except for testing. Thanks for the fix. – nachtigall Mar 25 '20 at 15:05
  • 4
    Note that as of early-mid 2020, if you use this option, you will not be able to login gmail or other google services. They will claim your browser is insecure and it won't work. This happened first for my home chrome profile a few months back, and today for my work profile. It was also the reason that I was unable to screenshare in google meet/hangouts. If this isn't happening to you yet, it's because google A/B test phases features like this in, so it will soon. – Scott May 18 '20 at 15:10
  • 1
    For Chrome, $ cp /usr/share/applications/google-chrome.desktop ~/.local/share/applications, and Then, $ vim ~/.local/share/applications/google-chrome.desktop

    Edit from: Exec=/usr/bin/google-chrome-stable %U To: Exec=/usr/bin/google-chrome-stable --password-store=basic %U

    – Smile.Hunter Aug 12 '21 at 16:28
  • Works on Debian Jessie (Chromium ver. 73.0). I made the change only to the pertinent file in /usr/share/applications, since I always launch the subject browser from the Xfce Menu. – Digger Dec 15 '21 at 19:09
61

First make sure libpam-gnome-keyring is installed then log out and back in.

When you open Chrome again it will ask for the password for the keyring but will give you an option to unlock the keyring every time you login. Make sure this is selected and enter your password to unlock the keyring.

Peachy
  • 7,117
  • 10
  • 38
  • 46
user91930
  • 635
  • 18
    This is a better solution than the accepted answer. One shouldn't have to set an empty password just to avoid some inconvenience. – Kevin Apr 20 '15 at 07:46
  • 1
    This option is not available on Mint 16 – tomrozb Jun 09 '15 at 05:34
  • 5
    FYI, this option did not work for Chromium 37.0.2062.120 (running Debian 7 (Wheezy)). However, for this case, the workaround, presented in the selected answer here (passing the --password-store=basic option so that Chrome uses it's own password store rather than attempting to use the GNOME keyring) still works a treat! – Digger Sep 04 '16 at 02:20
  • 2
    Not available in Mint 17 either, even with the specified package installed. – Highly Irregular Sep 08 '16 at 08:13
  • 4
    This did not work in Xubuntu 17. no unlock the keyring option presented. same old dialog. – Norman Bird Jul 27 '17 at 16:16
  • 1
    This is not the right answer either. If you don't want to have a password keyring at all, just disable the Chrome password store. See my answer for more details. – Capi Etheriel Oct 23 '17 at 16:49
  • 1
    How does this even answer the question? – mchid Jul 07 '18 at 02:49
  • 5
    I don't have an option to unlock the keyring. It asks for password again next time when I start the PC. – ROMANIA_engineer Dec 08 '18 at 15:02
  • 1
    does not work for ubuntu 19.04 – tatsu Apr 21 '19 at 13:12
  • 1
    "Make sure this is selected and enter your password to unlock the keyring." Yes, but I don't want to do that after every restart. – Csaba Toth Jul 11 '19 at 15:27
31

As described here you can set the keyring password to blank.

Go to System/Preferences/Password and Encryption keys, right click the appropriate folder and click Change Password. Put in your old password and leave the new one blank.

sebikul
  • 1,931
12

You can remove this annoying message by

  1. Go to (Unity button)/Passwords and Keys
  2. On tab Passwords choose the proper key (I'd got only one, so you may need to find proper key). Right-click on it and Delete.
  3. Restart Chromium
  4. It'll ask for password --- do not type any and continue.
  5. Choose "Use unsafe storage"

Ready for now!

As to popups Chromium asks for password to encrypt your passwords for websites. With no password (as it said) someone will have access to your passwords having read access to some files.

Justislav
  • 145
5

Edit: In fact, you might as well get rid of the keyring popup and the "your computer is old" flag at the same time.

sudo sed -i '/^Exec=/s/$/ --disable-infobars --password-store=basic %U/' /usr/share/applications/google-chrome.desktop


Original answer

I made this one-liner to make disabling the password pop-up simple for when I am setting up Ubuntu VMs. I just tested it on an Ubuntu 16.04 system which had Chrome installed (not Chromium).

sudo sed -i '/^Exec=/s/$/ --password-store=basic %U/' /usr/share/applications/google-chrome.desktop

This command adds --password-store=basic %U to the end of any line in /usr/share/applications/google-chrome.desktop that begins with Exec=.

Credit to Capi Etheriel, who's answer I used to develop mine.

omikes
  • 361
  • 5
  • 10
  • It might be better to copy the .desktop files to ~/.local/share/applications and edit them there. No need to use sudo then. – jarno Sep 21 '19 at 20:00
5

Setting your keyring password to your login password should resolve the issue. If you completely remove the password, your keyring will be accessible without a password (i.e. by everybode who has read access).

ChrisiPK
  • 345
  • This is maybe the best answer for me. It will store a securely all your passwords, compared to all other answers! As an addition I would add also to un-check the option for allowing everyone to connect to the network to the security http://superuser.com/a/115737 – Aleks Jan 16 '15 at 12:20
3

Google Chrome uses Gnome 'login' keyring to securely store passwords. It is usually protected by a password that matches your login password. Gnome keyring can automatically unlock it when the user logs in. When you login normally, the system gives the password you just entered to gnome-keyring, which then unlocks the login keyring.

So, why am I being asked to unlock a "keyring"?

The 'login' keyring password does not match your login password

When the user changes their password, the PAM module changes the password of the 'login' keyring to match.

If root changes the password, or /etc/shadow is directly edited then due to the lack of the old password, the 'login' keyring cannot be updated.

You have to update the 'login' keyring password manually.

You did not enter your password when logging in

When you have auto-login enabled or use another passwordless authentication method (for example 'fingerprint' device), you don't enter any password, and gnome-keyring cannot unlock the keyring automatically. So it asks you to unlock it.

If you have enabled disk encryption, LUKS passphrase can be reused to decrypt GNOME keyring even with auto-login. This works in Fedora out of box, but propably requires additional configuration tweaks in Ubuntu and Arch to configure initramfs to use systemd (and, therefore, systemd-cryptsetup).

Overwise, if you want to have auto-login and auto-unlock, you need to remove the keyring's password (set it to a blank one).

Links:

3

Ubuntu 12.10

  1. Goto Keyring and password
  2. then, View>By Keyring
  3. The window will change and will show a left pane. now select Login under Passwords in the left pane. Right click & select'change password'
  4. Enter the old password and when it prompts the new password just leave it blank.

Hope this helps

huchein
  • 31
  • This also works on Ubuntu 20.04 so it also (presumably) should work for all version in-between as well. – apokryfos Feb 01 '21 at 06:59
3

First of all, I'm by no means an Ubuntu nor a security expert. I'm just an average user / programmer that wanted to install Chrome on my Ubuntu 16.04 VM running under Parallels.

I installed Chrome, and was prompted with this annoying keyring password popup, and tried to put in my user's password to no avail.

The solution I got to work quite accidently was to:

  1. Go to Passwords and Keys
  2. Under "Passwords" just delete the Login keyring underneath that
  3. Ubuntu now will prompt you to create the new password
  4. Now when you launch Chrome, it won't bother you with the keyring popup anymore! (Well, at least for mine, it didn't.)
sivabudh
  • 131
1

This happened to me when I wanted to clone an entire user profile. Turns out not all apps store settings with relative pathnames.

In my case, I had to dump the dconf section for apps/seahorse/listing, replace the original directory name and reimport.

Writing here the solution as I will most likely forget when I will hit this again:

dconf dump /apps/seahorse/listing/ > dconf.txt

delete wrong pathnames in dconf.txt

(in my case, it was this line:
keyrings-selected=['secret-service://login', 'openssh:///home/OLDUSERNAME/.ssh', 'openssh:///home/NEWUSERNAME/.ssh']
)

dconf reset -f /apps/seahorse/listing/
cat dconf.txt | dconf load /apps/seahorse/listing/

1

I wrote a script that you can run whenever Google Chrome is updated.

Copy and paste the following script into your favorite text editor:

#!/bin/bash
sed -i 's/@\"/@ --password-store=basic"/g' /opt/google/chrome/google-chrome

Save the file with the name fixchrome in your home directory and then run the following command to make the file executable:

chmod +x ~/fixchrome

Now, you can run the following command to fix Google Chrome whenever it is updated:

sudo ~/fixchrome
mchid
  • 43,546
  • 8
  • 97
  • 150
1

As the problem came up on my computer just now, I think I've got a better solution.

  1. Go to Accessories -> Password

  2. Right click the 'login' folder

  3. Choose 'Change password'

  4. Choose 'unlock' and type in the new password.

Thus, the pops-up never turn out again.

Seth
  • 58,122
vicklin
  • 11
1

Easy Solution

1.Goto Keyring and password

2.Right Click on Login and delete.

3.Open Chrome It will ask for enter new password leave it blank and continue. thats it

0

If you have forgotten that major password, just delete all your local passwords on Chrome and restart again

  1. rm ~/.local/share/keyrings/*
  2. Restart Chrome
  • Thank you for this. In my case the issue was different, but close enough to figure out: the keyrings directory didn't exist and the question popup would come back over and over. mkdir ~/.local/share/keyrings solved the problem. – salmin Nov 25 '22 at 17:50
0

On Xubuntu (Xfce), fixing this problem may require enabling "Launch GNOME services on startup" in Settings -> Session and Startup -> Advanced, and then logging out and in again.

ʇsәɹoɈ
  • 944
  • 9
  • 12