From owner-freebsd-questions Mon Feb 10 2:32:21 2003 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9529937B401 for ; Mon, 10 Feb 2003 02:32:18 -0800 (PST) Received: from smtp.infracaninophile.co.uk (ns0.infracaninophile.co.uk [81.2.69.218]) by mx1.FreeBSD.org (Postfix) with ESMTP id DFC2443F93 for ; Mon, 10 Feb 2003 02:32:16 -0800 (PST) (envelope-from m.seaman@infracaninophile.co.uk) Received: from happy-idiot-talk.infracaninophile.co.uk (localhost [IPv6:::1]) by smtp.infracaninophile.co.uk (8.12.6/8.12.6) with ESMTP id h1AAWCnZ049551 for ; Mon, 10 Feb 2003 10:32:12 GMT (envelope-from matthew@happy-idiot-talk.infracaninophile.co.uk) Received: (from matthew@localhost) by happy-idiot-talk.infracaninophile.co.uk (8.12.6/8.12.6/Submit) id h1AAWCpp049550 for FreeBSD-questions@FreeBSD.ORG; Mon, 10 Feb 2003 10:32:12 GMT Date: Mon, 10 Feb 2003 10:32:12 +0000 From: Matthew Seaman To: FreeBSD-questions@FreeBSD.ORG Subject: Re: How to change Telnet Prelogin message? Message-ID: <20030210103212.GB49154@happy-idiot-talk.infracaninophi> Mail-Followup-To: Matthew Seaman , FreeBSD-questions@FreeBSD.ORG References: <1461.192.168.1.10.1044505050.squirrel@email.unixhideout.com> <20030206044512.GR87743@sub21-156.member.dsl-only.net> <20030206092721.GB53194@happy-idiot-talk.infracaninophi> <20030206192321.GA538@sub21-156.member.dsl-only.net> <20030206194716.GC58257@happy-idiot-talk.infracaninophi> <20030206215512.GB538@sub21-156.member.dsl-only.net> <20030206223453.GD58257@happy-idiot-talk.infracaninophi> <20030206225954.GC538@sub21-156.member.dsl-only.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20030206225954.GC538@sub21-156.member.dsl-only.net> User-Agent: Mutt/1.5.3i X-Spam-Status: No, hits=-3.0 required=5.0 tests=IN_REP_TO,QUOTED_EMAIL_TEXT,REFERENCES,SPAM_PHRASE_02_03, USER_AGENT,USER_AGENT_MUTT version=2.44 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Feb 06, 2003 at 02:59:54PM -0800, Nathan Kinkade wrote: > On Thu, Feb 06, 2003 at 10:34:53PM +0000, Matthew Seaman wrote: > > On Thu, Feb 06, 2003 at 01:55:12PM -0800, Nathan Kinkade wrote: > > > On Thu, Feb 06, 2003 at 07:47:16PM +0000, Matthew Seaman wrote: > > > > > > Interesting. The source code seems pretty clear in that it only looks > > > > at the 'im' property: > > > > > > Looks like it's time to send-pr. > > > > > Thanks Matthew. I did a bit of searching and couldn't find this problem > > > mentioned anywhere else. I have submitted a PR with id "docs/48018". > > > > Ah. Beat me to it. I'm just working up a patch to telnetd to make it > > work the way the manual says. Just testing now before I submit it. > > > > Oh no, I didn't submit a patch! I just pointed to issue out, suggesting > that someone may like to remove the incorrect text from the telnetd(8) > manpage, or possibly update the telnetd sources to match the manpage. > By all means, please do submit a patch! I do a good bit of work with > PHP, but I've never programmed with C, so I didn't even think about > trying to patch. Thanks for all of your help on this issue. This was > the first PR that I have ever submitted, maybe I shouldn't have > submitted the PR at all if I didn't have the capability to fix the > problem. Is there any way that you can send in a patch relating to the > PR that I already submitted. Hmmm... Having spent some time looking at this over the weekend, I've come to the conclusion that adding support for having telnetd display the /etc/issue file before prompting for a login is impractical when combined with the SRA encryption used in FreeBSDs standard telnet setup. It's certainly beyond my extremely rusty C programming skills. Furthermore, the display of the IM gettytab property is somewhat dubious as well: Consider this entry in the standard /etc/gettytab: default:\ :cb:ce:ck:lc:fd#1000:im=\r\n%s/%m (%h) (%t)\r\n\r\n:sp#1200:\ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :if=/etc/issue: which means you should see a banner like: FreeBSD/i386 (hostname.example.com) (ttyp0) when you attempt to log in either via telnet or on the console. However, it's conspicuously absent *before* the login prompt in a FreeBSD to FreeBSD telnet sesssion: % telnet localhost Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. Trying SRA secure login: User (matthew): Password: [ SRA accepts you ] FreeBSD/i386 (happy-idiot-talk.infracaninophi) (ttyp4) Those 'User' and 'Password' prompts originate from the client machine, and occur as a necessary pre-requisite before the encrypted channel between the client and server can be set up. So you've got to log in before you can see any pre-login messages. I'm not sure what would appear given an older telnet client that doesn't support encryption, not having any older telnet clients around to test with. Cheers, Matthew -- Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks Savill Way PGP: http://www.infracaninophile.co.uk/pgpkey Marlow Tel: +44 1628 476614 Bucks., SL7 1TH UK To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message