From owner-freebsd-hackers Fri Mar 17 12:08:41 1995 Return-Path: hackers-owner Received: (from majordom@localhost) by freefall.cdrom.com (8.6.10/8.6.6) id MAA08411 for hackers-outgoing; Fri, 17 Mar 1995 12:08:41 -0800 Received: from cs.weber.edu (cs.weber.edu [137.190.16.16]) by freefall.cdrom.com (8.6.10/8.6.6) with SMTP id MAA08404 for ; Fri, 17 Mar 1995 12:08:39 -0800 Received: by cs.weber.edu (4.1/SMI-4.1.1) id AA29797; Fri, 17 Mar 95 13:02:17 MST From: terry@cs.weber.edu (Terry Lambert) Message-Id: <9503172002.AA29797@cs.weber.edu> Subject: Re: Batch Telnet (Re: diskless and 3Com 509) To: mycroft@ai.mit.edu (Charles M. Hannum) Date: Fri, 17 Mar 95 13:02:16 MST Cc: peter@bonkers.taronga.com, hackers@FreeBSD.org, tech-net@NetBSD.ORG In-Reply-To: <199503171758.MAA28775@duality.gnu.ai.mit.edu> from "Charles M. Hannum" at Mar 17, 95 12:58:49 pm X-Mailer: ELM [version 2.4dev PL52] Sender: hackers-owner@FreeBSD.org Precedence: bulk > The message returned is "Connection closed by remote host.", not > "Connection closed." > > And you actually believed that message? It's wrong. Yep; silly me, it appears. 8-). > Not at all. If you actually look at the packets on the wire, you'll > see: > > 1) The client sends a FIN. > > 2) The server sends some data. > > 3) The client responds to the data with a RST. > > tcpdump(8) leaves no doubt that the problem, if any, is in the client. > > Actually, I misspoke about TCP. The client can close the write side > by sending a FIN. However, the telnet client is currently closing > both sides of the connection when it gets an EOF on stdin. This is > really easy to fix. In fact, I just did it. Charles wins the prize; apparently, I was misled by the message and foolishly believed telnet was describing the situation. I see a problem with the fix, however, in that an attempt to disconnect a telnet client from a remote server that has gone away may fail unless the fix was made to only apply to EOF on input instead of applying to both EOF on input and . I think you still want to cause the client program to exit immediately. Terry Lambert terry@cs.weber.edu --- Any opinions in this posting are my own and not those of my present or previous employers.