rlogin kludge: using TERM to pass other envariables?

Robert Maier rsm at amethyst.ma.arizona.edu
Sun Dec 18 07:34:31 AEST 1988


In article <899 at cmx.npac.syr.edu> jerryp at cmx.npac.syr.edu (Jerry Peek)
writes:

> One thing bugs me about "rlogin":  the only environment variable it'll pass
> to the remote machine is TERM.  I want to pass more.
> ... like this:
> 
> 	TERM="VARSET:REAL_BAUD=2400:SUNVIEW=no:LOGIN=quick:TERM=sun-cmd"
> 

The undocumented RLOGIN protocol apparently made (makes?) some
provision for this.  After rlogin opens the connection to the rlogin
daemon, the first bytes sent across to the daemon are:

	\0
	remote_username\0
	local_username\0
	terminal_info\0

i.e., a null followed by three null-terminated strings.  The
terminal_info string is of the form

	terminal_type[/speed][/something]

i.e. the desired TERM variable, optionally followed by a literal slash
and the line speed, optionally followed by a literal slash and some
further string of characters.

In the BSD4.3 rlogind.c the terminal_info string is stored in a
64-byte buffer.  So there's lots of room left for the "something".
But whatever it is, it's ignored.  And the BSD4.3 rlogin.c doesn't
send the optional "/something" at all.

Is it possible that "/something" was put into the protocol as a way of
propagating more terminal characteristics?  Comments, anyone?

--
Robert S. Maier
SNAIL: Dept. of Math.; Univ. of Arizona; Tucson, AZ 85721; USA
VOICE: +1 602 621 6893 / +1 602 621 2617
UUCP: ..{allegra,cmcl2,hao!noao}!arizona!amethyst!rsm
BITNET: maier at arizrvax          INTERNET: rsm at amethyst.ma.arizona.edu



More information about the Comp.unix.questions mailing list