From owner-freebsd-hackers Fri May 12 18:30:37 1995 Return-Path: hackers-owner Received: (from majordom@localhost) by freefall.cdrom.com (8.6.10/8.6.6) id SAA16245 for hackers-outgoing; Fri, 12 May 1995 18:30:37 -0700 Received: from sequent.kiae.su (sequent.kiae.su [144.206.136.6]) by freefall.cdrom.com (8.6.10/8.6.6) with SMTP id SAA16234 for ; Fri, 12 May 1995 18:30:33 -0700 Received: by sequent.kiae.su id AA00272 (5.65.kiae-2 ); Sat, 13 May 1995 05:26:56 +0400 Received: by sequent.KIAE.su (UUMAIL/2.0); Sat, 13 May 95 05:26:55 +0400 Received: (from ache@localhost) by astral.msk.su (8.6.8/8.6.6) id FAA00259; Sat, 13 May 1995 05:10:12 +0400 To: Charles Henrich , Terry Lambert Cc: freebsd-hackers@FreeBSD.org References: <9505122302.AA04093@cs.weber.edu> In-Reply-To: <9505122302.AA04093@cs.weber.edu>; from Terry Lambert at Fri, 12 May 95 17:02:34 MDT Message-Id: Organization: Olahm Ha-Yetzirah Date: Sat, 13 May 1995 05:10:11 +0400 (MSD) X-Mailer: Mail/@ [v2.35 FreeBSD] From: "Andrey A. Chernov, Black Mage" X-Class: Fast Subject: Re: REMOTE_HOST & REMOTE_USER Lines: 26 Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Content-Length: 1260 Sender: hackers-owner@FreeBSD.org Precedence: bulk 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