Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 13 May 1995 05:10:11 +0400 (MSD)
From:      "Andrey A. Chernov, Black Mage" <ache@astral.msk.su>
To:        Charles Henrich <henrich@crh.cl.msu.edu>, Terry Lambert <terry@cs.weber.edu>
Cc:        freebsd-hackers@FreeBSD.org
Subject:   Re: REMOTE_HOST & REMOTE_USER
Message-ID:  <KQpR0jleE0@astral.msk.su>
In-Reply-To: <9505122302.AA04093@cs.weber.edu>; from Terry Lambert at Fri, 12 May 95 17:02:34 MDT
References:  <9505122302.AA04093@cs.weber.edu>

next in thread | previous in thread | raw e-mail | index | archive | help
In message <9505122302.AA04093@cs.weber.edu> Terry Lambert writes:

>> How do you folks feel about making inetd set the REMOTE_HOST variable to the
>> hostname/ip of the connected peer?  SGI's do this and it comes in quite handy.
>> 
>> Is inetd the right place (instead of login say?).  I keep debating between the
>> two, but for maximal benefit I think it should stay in inetd, and have login
>> preserve the value, or reset it..

>I think you want telnetd and rlogind to do this.  Neither one inherits
>environment from the inetd to the slave side of the pty.

>I think login would need to preserve the value; login itself would be
>incapable of running getpeername() since it would be on a slave side
>of a pty and would not get a valid response (besides which, login not
>on a network connection would get bogus values too).

Just a real example shows that it capable: tcsh set REMOTEHOST
environment variable. If even shell can set it, login can set it too.


-- 
Andrey A. Chernov        : And I rest so composedly,  /Now, in my bed,
ache@astral.msk.su       : That any beholder  /Might fancy me dead -
FidoNet: 2:5020/230.3    : Might start at beholding me,  /Thinking me dead.
RELCOM Team,FreeBSD Team :         E.A.Poe         From "For Annie" 1849



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?KQpR0jleE0>