From mi@ALDAN.algebra.com  Wed Feb 21 07:26:44 1996
Received: from aldan (PPP-84-17.BU.EDU [128.197.8.133])
          by freefall.freebsd.org (8.7.3/8.7.3) with SMTP id HAA08602
          for <FreeBSD-gnats-submit@freebsd.org>; Wed, 21 Feb 1996 07:26:39 -0800 (PST)
Received: (from mi@localhost) by aldan (8.6.12/8.6.12) id KAA03420; Wed, 21 Feb 1996 10:27:22 -0500
Message-Id: <199602211527.KAA03420@aldan>
Date: Wed, 21 Feb 1996 10:27:22 -0500
From: mi@ALDAN.algebra.com
Reply-To: mi@ALDAN.algebra.com
To: FreeBSD-gnats-submit@freebsd.org
Subject: TERM-type inconsitency
X-Send-Pr-Version: 3.2

>Number:         1038
>Category:       bin
>Synopsis:       telnet gives ANSI80X30; rlogin gives (correct) cons30
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:
>Keywords:
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Feb 21 07:30:02 PST 1996
>Closed-Date:    Fri Mar 1 12:08:06 PST 1996
>Last-Modified:  Fri Mar  1 12:17:34 PST 1996
>Originator:     Mishutka k&
>Release:        FreeBSD 2.1-STABLE i386
>Organization:
>Environment:

	$TERM is cons30

>Description:

	When connecting to other machines via telnet, telnet-client
	tells the whatever server, that my TERM-type is ANSI80X30 .
	In case of rlogin, it is reported correctly as cons30 .

>How-To-Repeat:

	See description

>Fix:
	
	Manually 
		setenv TERM cons30
	after connection is established.
>Release-Note:
>Audit-Trail:

From: Bill Fenner <fenner@parc.xerox.com>
To: mi@aldan.algebra.com
Cc: FreeBSD-gnats-submit@freebsd.org
Subject: Re: bin/1038: TERM-type inconsitency 
Date: Wed, 21 Feb 1996 16:34:00 PST

 In message <199602211527.KAA03420@aldan>you write:
 >	When connecting to other machines via telnet, telnet-client
 >	tells the whatever server, that my TERM-type is ANSI80X30 .
 
 Can you do the following:
 
 % telnet
 telnet> set option
 telnet> open (wherever)
 
 It is likely that your whatever server is asking for a different name for your 
 terminal type, like so:
 
 RCVD IAC SB TERMINAL-TYPE SEND
 SENT IAC SB TERMINAL-TYPE IS "CONS30"
 RCVD IAC SB TERMINAL-TYPE SEND
 SENT IAC SB TERMINAL-TYPE IS "ANSI80X30"
 RCVD IAC SB TERMINAL-TYPE SEND
 SENT IAC SB TERMINAL-TYPE IS "ANSI80X30"
 RCVD IAC SB TERMINAL-TYPE SEND
 SENT IAC SB TERMINAL-TYPE IS "CONS30"
 
 It looks like the whatever server keeps asking until it gets either a terminal 
 type that it recognizes or the first terminal type that I sent.  The FreeBSD 
 client seems to be behaving as specified in RFC1091, perhaps it is your 
 whatever server that is behaving incorrectly?
 
 ("cons30" and "ansi80x30" are synonyms in /usr/share/misc/termcap)
 
   Bill
 
State-Changed-From-To: open->closed 
State-Changed-By: fenner 
State-Changed-When: Fri Mar 1 12:08:06 PST 1996 
State-Changed-Why:  
The option negotiation 

SENT WILL TERMINAL TYPE 
RCVD DO TERMINAL TYPE 
RCVD IAC SB TERMINAL-TYPE SEND 
SENT IAC SB TERMINAL-TYPE IS "CONS25" 
RCVD IAC SB TERMINAL-TYPE SEND 
SENT IAC SB TERMINAL-TYPE IS "ANSIS" 
RCVD IAC SB TERMINAL-TYPE SEND 
SENT IAC SB TERMINAL-TYPE IS "ANSI80X25" 
RCVD IAC SB TERMINAL-TYPE SEND 
SENT IAC SB TERMINAL-TYPE IS "ANSI80X25" 

is correct RFC-1091 behavior on the part of the telnet client. 
The telnet server is apparently either not RFC-1091 compliant or 
chooses not to pick the first-reported terminal type. 

The easiest way to work around this is to remove all aliases 
in your /usr/share/misc/termcap file; change it from 

cons25|ansis|ansi80x25: 

to 

cons25: 

and if you still want to have the ansis and ansi80x25 aliases, add entries 
like 

ansis:tc=cons25: 
ansi80x25:tc=cons25: 
>Unformatted:
