Authentication at CUPS web interface

28,818

Solution 1

Comparing your cups.conf file, I only see a few differences:

  • You've replaced Port 631 by Listen localhost:631 to prevent remote administration
  • You've removed Allow @LOCAL three times:

     DefaultAuthType Basic
     <Location />
       Order allow,deny
    -  Allow @LOCAL
     </Location>
     <Location /admin>
       Order allow,deny
    -  Allow @LOCAL
     </Location>
     <Location /admin/conf>
       AuthType Default
       Require user @SYSTEM
       Order allow,deny
    -  Allow @LOCAL
     </Location>
    

Re-add those lines or you'll be unable to open CUPS. After adding yourself to the lpadmin group, you need to restart CUPS due to the way groups work. That can be done with:

sudo restart cups

Solution 2

According to this post: http://comments.gmane.org/gmane.comp.printing.cups.general/28081, it could come from the fact that you have several instances of CUPS running.

Check it by using this command:

ps -e | grep -U cups

If you find two instances, kill them using: (sudo is required since cups is run at the root level)

sudo kill -9 {pid}

With {pid} being number of the instances given by the ps command.

Then restart cups:

sudo restart cups

Hope this can help.

Share:
28,818

Related videos on Youtube

Vitali
Author by

Vitali

Updated on September 18, 2022

Comments

  • Vitali
    Vitali almost 2 years

    When I try to perform any administrative task on CUPS web interface I get pop-up window that requires me to authenticate at CUPS. Authenticating both as root and as a my user fail, even though my user is added to the lpadmin group as described in:

    CUPS Print Server guide

    Any idea what can be wrong or how I debug it?

    • Admin
      Admin almost 13 years
      Could you attach the /etc/cups/cupsd.conf file? Make sure that your user account has a password set.
    • Admin
      Admin almost 13 years
      cupsd.conf my account has a password set
  • Lekensteyn
    Lekensteyn almost 13 years
    If it's related to PAM, you should check /var/log/auth.log. Otherwise, CUPS logs are in /var/log/cups/
  • Gri Ma
    Gri Ma over 2 years
    sudo usermod -a -G lpadmin <myuser> helped me. (as mentioned by Lekensteyn)