l i n u x - u s e r s - g r o u p - o f - d a v i s
Next Meeting:
July 7: Social gathering
Next Installfest:
Latest News:
Jun. 14: June LUGOD meeting cancelled
Page last updated:
2004 Jan 12 16:43

The following is an archive of a post made to our 'vox-tech mailing list' by one of its subscribers.

Report this post as spam:

(Enter your email address)
Re: [vox-tech] Providing access to SSH on Kiosk?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [vox-tech] Providing access to SSH on Kiosk?

--On Monday, January 12, 2004 14:42:48 -0800 Bill Kendrick <nbs@sonic.net> wrote:

host='bar `xterm`'
xterm -e ssh $user@$host

Will pop up an xterm running ssh, and once you log in an xterm running
bash   :-)
That's a good one to be afraid of.  I'm sure there's some shell magic I
can do to get around this issue.  Probably some regexp some Unix guru
came up with back in the 70s? ;^)
Your best bet might be to avoid sh altogether and use perl, c, or something like that:

#!/usr/bin/perl -w
print "Host: ";
my $host = <STDIN>; chomp $host;
print "Username: ";
my $user = <STDIN>; chomp $user;
exec('/usr/bin/ssh', '-l', $user, $host);
exit 1;

Store this in a file, mark it executable, and run it as "xterm -e /path/to/script". The user can type any old garbage they like for the username or hostname. Ssh will just see it as a funny-looking username or hostname.

"Grand Funk Railroad paved the way for Jefferson Airplane, which cleared
the way for Jefferson Starship. The stage was now set for the Alan Parsons
Project, which I believe was some sort of hovercraft." - Homer Simpson

Kenneth Herron Kherron@newsguy.com 916-366-7338
vox-tech mailing list

LUGOD Group on LinkedIn
Sign up for LUGOD event announcements
Your email address:
LUGOD Group on Facebook
'Like' LUGOD on Facebook:

Hosting provided by:
Sunset Systems
Sunset Systems offers preconfigured Linux systems, remote system administration and custom software development.

LUGOD: Linux Users' Group of Davis
PO Box 2082, Davis, CA 95617
Contact Us

LUGOD is a 501(c)7 non-profit organization
based in Davis, California
and serving the Sacramento area.
"Linux" is a trademark of Linus Torvalds.

Sponsored in part by:
EDGE Tech Corp.
For donating some give-aways for our meetings.