LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 09-06-2010, 04:55 PM   #1
realwhz
LQ Newbie
 
Registered: Mar 2006
Distribution: Debian
Posts: 10

Rep: Reputation: 0
How to config CUPS to use alternative username


Hi all,

I am using a network printer through a local CUPS interface. Since the network printer requires a different account name from my local system user name, I have to use '-U' option of command line tools, lpr for example, to print documents.

Is there any way to config the CUPS system to user the alternative username so that I can print documents directly from, say gnome-print interface?

Thank you all very much.
 
Old 09-06-2010, 05:24 PM   #2
idoneous
LQ Newbie
 
Registered: Jul 2006
Location: York, PA
Distribution: Linux Mint 14
Posts: 27

Rep: Reputation: 0
Can you give us some more information on your set up? What protocol are you using to connect ( ipp, http, socket, samba, etc )? What kind of printer is it.
With a samba connection, I know that you can embed the user name and password in the uri when you set up the printer. After that, you will not see the user name and password in the string, but it will remain. With a socket connection, I believe it should be a setting you can put in. You will need the correct driver/ppd file for this. The same may be true for ipp, but I am not certain.
I've beaten my head against CUPs a few times, I'd be glad to add an extra Google bar to your efforts.
 
Old 09-06-2010, 07:39 PM   #3
realwhz
LQ Newbie
 
Registered: Mar 2006
Distribution: Debian
Posts: 10

Original Poster
Rep: Reputation: 0
Thank you for your reply.

The network printer is added to my system via IPP protocol and the model of the computer is HP LaserJet P4014. I have tried to put a user field in the Device URL, something like ipp://printer_authorized_username@xxx
But this settings doesn't work. When I print a document, the submit user name is still my local system user name rather than the printer_authorized_username. I still have to use command line tools to print it by using '-U printer_authorized_username' option.

Quote:
Originally Posted by idoneous View Post
Can you give us some more information on your set up? What protocol are you using to connect ( ipp, http, socket, samba, etc )? What kind of printer is it.
With a samba connection, I know that you can embed the user name and password in the uri when you set up the printer. After that, you will not see the user name and password in the string, but it will remain. With a socket connection, I believe it should be a setting you can put in. You will need the correct driver/ppd file for this. The same may be true for ipp, but I am not certain.
I've beaten my head against CUPs a few times, I'd be glad to add an extra Google bar to your efforts.
 
Old 09-17-2010, 10:15 PM   #4
idoneous
LQ Newbie
 
Registered: Jul 2006
Location: York, PA
Distribution: Linux Mint 14
Posts: 27

Rep: Reputation: 0
Sorry, I had a very busy week. I checked back several times and then got distracted. I'm not sure if ipp allows a user name or password in the URI. Have you tried connecting to the HP with socket? I think if you use the socket protocol over 9100 with the correct ppd file, it will allow you to enter a user name and password for the connection. Let me do some digging on this. I'll also check the ipp protocol in case socket connect has been disabled on your printer. I've had the most success with the socket connection for HP printers. Socket connection gives you access to the widest set of the printer's features.
 
Old 09-17-2010, 10:59 PM   #5
idoneous
LQ Newbie
 
Registered: Jul 2006
Location: York, PA
Distribution: Linux Mint 14
Posts: 27

Rep: Reputation: 0
Not having a lot of luck here. Printers I've connected to have been insecure other than printers I've hit over samba. The samba protocol includes entry of username and password in the URL. IPP specification does not include username or password. Neither, as far as I can see, does the socket protocol. I've downloaded the ppd files for several HP printers. None of them provides a place to enter username or password.

The only thing I can think of is to have an admin add the user from your client to the list of allowed users on the printer.
 
Old 09-18-2010, 10:07 AM   #6
realwhz
LQ Newbie
 
Registered: Mar 2006
Distribution: Debian
Posts: 10

Original Poster
Rep: Reputation: 0
Hi idoneous,

Thank you for your help. I completely agree with you. I have also done some research on this issue. I think a relatively easy way to achieve my goal is to use a wrapper. That is, I can setup a virtual printer and configure it to print by an execution of `lpr' command. CUPS itself currently does not provide a configurable equivalence to the `-U' option of commands interface.

Thank you very much indeed.

HZ

Quote:
Originally Posted by idoneous View Post
Not having a lot of luck here. Printers I've connected to have been insecure other than printers I've hit over samba. The samba protocol includes entry of username and password in the URL. IPP specification does not include username or password. Neither, as far as I can see, does the socket protocol. I've downloaded the ppd files for several HP printers. None of them provides a place to enter username or password.

The only thing I can think of is to have an admin add the user from your client to the list of allowed users on the printer.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
CUPS username and password ccin1492 Linux - Software 14 01-15-2021 11:37 AM
Username in printerhead with cups? dp81 Linux - Software 7 06-21-2006 10:27 PM
CUPS does not accept my username/password Robhogg Linux - Hardware 2 02-26-2006 01:50 PM
CUPS: What URI to use when a username is needed without a password elluva Linux - Networking 0 02-26-2005 11:19 AM
CUPS: Username and password. aliiscool Linux - Software 6 07-15-2004 06:51 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 05:00 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration