On Thu, Mar 24, 2005 at 12:56:36PM +0200, Livneh Ran wrote: > Hi. > I'm having problems at work, from time to time, with remote printers. > I'd like to create a script for windows users (Help-Desk) that would > check printer connectivity. > I want to open an account on Linux machine that would be able to print a > specified page only. > No regular login will be available for that user. For example: > ssh/rsh -l username Spool_Print_Host "lp -d chosen_printer /Path/To/Doc"
Maybe do this with your account or with root by using a ssh private/public key pair with the command defined in the authorized_keys file? Alternatively: why not a simple cgi script from the web server? > > Is there a way to specify "chosen_printer" in that script (i.e. $1)or is > it to late after logging in? > Is there a better way of doing that? One thing I can think of: allow telnet logins, but change the login command telnet uses so it would run a menu of operations. If this is Debian, pdmenu is quite useful for that task. Use the parameter -L to in.telnetd . No login is required and thus no sensitive information is passed on this insecure channel. Looking at a similar setting of mine, it seems I did use login afterall, to generate the pty and all. My 'alternative login command' simply runs: login -f oper and oper is a user whose shell is /usr/bin/pdmenu and whose home dir is not writable to itself. As its shell its shell is not in /etc/shells it cannot be used for normal logins. -- Tzafrir Cohen | New signature for new address and | VIM is http://tzafrir.org.il | new homepage | a Mutt's [EMAIL PROTECTED] | | best ICQ# 16849755 | Space reserved for other protocols | friend ================================================================= To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]
