Caolan McNamara:

telnetlib is unable to connect to a few telnet daemons because of
improper IAC handling, heres an attached oneliner to reject WILL
messages which will allow many more telnet daemons to work with it,
namely FreeBSD.
This commit is contained in:
Guido van Rossum 2000-05-02 14:32:11 +00:00
parent ce33eb3ee8
commit 823eb4ba81
1 changed files with 1 additions and 0 deletions

View File

@ -329,6 +329,7 @@ class Telnet:
opt = self.rawq_getchar()
self.msg('IAC %s %d',
c == WILL and 'WILL' or 'WONT', ord(c))
self.sock.send(IAC + DONT + opt)
else:
self.msg('IAC %s not recognized' % `c`)
except EOFError: # raised by self.rawq_getchar()