Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
how to print over network (lpd) with another user-id?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
all-inc.
Tux's lil' helper
Tux's lil' helper


Joined: 03 Jul 2004
Posts: 138
Location: Darmstadt.Germany.EU

PostPosted: Fri Nov 09, 2007 3:15 pm    Post subject: how to print over network (lpd) with another user-id? Reply with quote

hi,
I have my laptop connected to a network, in which i have access to a lpd printer. but it's sometimes necessary to change the username the printing job belongs to... and it's anoying to always change to the user via su to achieve another username to be displayed in the printer logs.
perhaps it is possible to send printing jobs with an userid which in fact doesn't exist on the notebook? let's say send jobs with virtual usernames? btw i have root-access on the notebook so i can play around ;)

thank you for ideas,
all-inc.
_________________
# make config; not war
registered linux user # 265707
Back to top
View user's profile Send private message
Neon Dude
n00b
n00b


Joined: 13 Jun 2004
Posts: 15
Location: London

PostPosted: Fri Nov 09, 2007 4:23 pm    Post subject: Reply with quote

It's a bit of a hack but you could try setting the LOGNAME variable to the required user

Code:
export LOGNAME=name_you_want
Back to top
View user's profile Send private message
all-inc.
Tux's lil' helper
Tux's lil' helper


Joined: 03 Jul 2004
Posts: 138
Location: Darmstadt.Germany.EU

PostPosted: Fri Nov 09, 2007 8:59 pm    Post subject: Reply with quote

well, doesn't work...it would have been a huge security hole! ...i'm glad it didn't work ;)
EDIT: I found a solution: lp's nice option '-U'
I'm a little bit confused that i can just use the -U option to specify the desired username...
_________________
# make config; not war
registered linux user # 265707
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum