1.6b1 precedes 1.6.0, so the version of CUPS in Quantal should have the feature. I haven't tested this myself.
The question now is, since CUPS has underlying support for this, have the user interfaces in Ubuntu been updated to take advantage of it? The areas that should be updated are, at minimum:
1. The popup username/password dialog that is displayed when AuthInfoRequired requires a username. Currently the username that is entered appears to be completely ignored (in 12.04 LTS at least).
2. The Job tab or Advanced tab in the standard print dialog.
3. Anywhere else a user configures client.conf.
4. The Add Printer dialog should ask for the username/password to be used for all jobs sent to the printer. The method of doing so may be different than what is needed for 1-3 though, since this one would be attached to the printer, and that might mean modifying printers.conf instead of client.conf. I really don't know what the conceptual separation is for those, so someone who knows the system better can chime in on that.
I'll be upgrading just for this. For those stuck on 12.04 LTS like I currently am, using "lp -U username" is the only way I've found to get the username to be sent. pseudobot's findings above were the same as mine. Adding "job-originating-user-name" and "requesting-user-name" in /etc/cups/printers.conf had no effect. Also, whether or not there was a user account on the system with that username had no effect.
If you really can't leave 12.04 LTS and are willing to repackage cups for local use, the function to change appears to be cupsUser() in cups/usersys.c. That is used everywhere to decide what the current username is, including when sending "requesting-user-name".
Apparently CUPS added support for specifying a username in CUPS 1.6b1 (May 24, 2012):
* CUPS now supports a User directive in client.conf and the CUPS_USER environment variable for overriding the default username (STR #3114)
http:// www.cups. org/documentati on.php/ doc-1.6/ relnotes. html www.cups. org/str. php?L3114
http://
The version of CUPS in Ubuntu releases:
precise (12.04LTS) 1.5.3-0ubuntu5.1 0ubuntu5. 2
precise-updates 1.5.3-0ubuntu8
quantal (12.10) 1.6.1-0ubuntu11.5
raring (13.04) 1.6.2-1ubuntu8
saucy (13.10) 1.7.0~rc1-
trusty 1.7.1-4
1.6b1 precedes 1.6.0, so the version of CUPS in Quantal should have the feature. I haven't tested this myself.
The question now is, since CUPS has underlying support for this, have the user interfaces in Ubuntu been updated to take advantage of it? The areas that should be updated are, at minimum:
1. The popup username/password dialog that is displayed when AuthInfoRequired requires a username. Currently the username that is entered appears to be completely ignored (in 12.04 LTS at least).
2. The Job tab or Advanced tab in the standard print dialog.
3. Anywhere else a user configures client.conf.
4. The Add Printer dialog should ask for the username/password to be used for all jobs sent to the printer. The method of doing so may be different than what is needed for 1-3 though, since this one would be attached to the printer, and that might mean modifying printers.conf instead of client.conf. I really don't know what the conceptual separation is for those, so someone who knows the system better can chime in on that.
I'll be upgrading just for this. For those stuck on 12.04 LTS like I currently am, using "lp -U username" is the only way I've found to get the username to be sent. pseudobot's findings above were the same as mine. Adding "job-originatin g-user- name" and "requesting- user-name" in /etc/cups/ printers. conf had no effect. Also, whether or not there was a user account on the system with that username had no effect.
If you really can't leave 12.04 LTS and are willing to repackage cups for local use, the function to change appears to be cupsUser() in cups/usersys.c. That is used everywhere to decide what the current username is, including when sending "requesting- user-name" .