Update 2019-01-09: Please see answer below as there is a way to fix this with CUPS 2.2.8.
Update 2020-10-17: Upgrading from 18.04 LTS to 20.04 LTS will fix it as it upgrades the version of CUPS from 2.2.7 (which contains the bug) to version 2.3.1 which does not have the bug. Since some users may not be able to upgrade to 20.04 LTS right now this is still very valid for the 18.04 LTS users.
I have Ubuntu 18.04 LTS installed clean on this system. When I try to add a printer through CUPS 2.2.7 address of http://localhost:631 in the Chrome browser, I can't add the printer as I keep getting Unauthorized. It never asks for a login. How do I add my printer through CUPS using Google Chrome?
BTW, Firefox, Chromium and other browsers so far seem to work fine for adding a printer in CUPS 2.2.7. It appears to be a bug between CUPS 2.2.7 and Google Chrome.
Update 2019-01-09: I have found that CUPS 2.2.8 works without a problem with Google Chrome in Ubuntu 18.04. I downloaded and installed it from https://launchpad.net/ubuntu/+source/cups/2.2.8-5ubuntu1.2
Please note that the bug for CUPS 2.2.7 is filed at: https://bugs.launchpad.net/ubuntu/+source/cups/+bug/1769893
CUPS 2.2.8 installation steps
Run all the following from a terminal window.
Install the prerequisites:
Download CUPS 2.2.8 and extract it and enter the new directory created:
Run the
configure
,make
andmake install
:You might want to put a hold on CUPS so it doesn't update back to 2.2.7 which still has the issue with unauthorized:
Then all you should have to do is restart the
cups.service
:Check if the service is running:
If CUPS fails to restart, reinstall the daemon then restart the service again:
Then access in Google Chrome http://localhost:631
The CUPS homepage might show 2.2.7 still, but try clicking on Administration and it should show 2.2.8.
Hope this helps!
I came across this solution when I was having the problem "in general" (not a browser specific issue) and the thing that ended up working for me was to add my user to the lpadmin group:
and then reboot.
Update to latest Ubuntu.
For me,this issue was solved when I updated Ubuntu from 18.04 LTS to 20.04 LTS.
You may try Chromium which open-source version of Chrome:
It worked like a charm in my case.