The attached patch adds baud rate support setting in telnet so I can login to console servers with a predefined baud rate, per RFC2217, like so: $ telnet -B 115200 CS624 8007 Trying 10.7.191.113... Connected to cs-624.west.isilon.com. Escape character is '^]'. Isilon OneFS/amd64 (dem-nodes-2) (ttyd0) login: Or like so: $ telnet telnet> set baudrate 115200 baudrate set to "115200". telnet> telnet CS624 8007 Trying 10.7.191.113... Connected to cs-624.west.isilon.com. Escape character is '^]'. Isilon OneFS/amd64 (dem-nodes-2) (ttyd0) This work is based on a local modification to telnet made by Sujal Patel at Isilon, with additional modifications made by other Isilon employees. Fix: Patch attached with submission follows:
This patch also needs a mod to usage() e.g. Index: telnet/main.c =================================================================== --- telnet/main.c (revision 423450) +++ telnet/main.c (working copy) @@ -84,24 +84,24 @@ tninit(void) init_sys(); } static void usage(void) { fprintf(stderr, "usage: %s %s%s%s%s\n", prompt, #ifdef AUTHENTICATION - "[-4] [-6] [-8] [-E] [-K] [-L] [-N] [-S tos] [-X atype] [-c] [-d]", + "[-4] [-6] [-8] [-B baud] [-E] [-K] [-L] [-N] [-S tos] [-X atype] [-c] [-d]", "\n\t[-e char] [-k realm] [-l user] [-f/-F] [-n tracefile] ", #else - "[-4] [-6] [-8] [-E] [-L] [-N] [-S tos] [-c] [-d]", + "[-4] [-6] [-8] [-B baud] [-E] [-L] [-N] [-S tos] [-c] [-d]", "\n\t[-e char] [-l user] [-n tracefile] ", #endif "[-r] [-s src_addr] [-u] ", #if defined(IPSEC) && defined(IPSEC_POLICY_IPSEC) "[-P policy] " #endif #ifdef ENCRYPTION "[-y] [host-name [port]]" #else /* ENCRYPTION */ "[host-name [port]]"
A commit references this bug: Author: ngie Date: Tue Nov 11 04:06:09 UTC 2014 New revision: 274364 URL: https://svnweb.freebsd.org/changeset/base/274364 Log: Add baud rate support to telnet(1) This implements part of RFC-2217 It's based off a patch originally written by Sujal Patel at Isilon, and contributions from other Isilon employees. PR: 173728 Phabric: D995 Reviewed by: markj, markm MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Division Changes: head/contrib/telnet/arpa/telnet.h head/contrib/telnet/telnet/baud.h head/contrib/telnet/telnet/commands.c head/contrib/telnet/telnet/externs.h head/contrib/telnet/telnet/main.c head/contrib/telnet/telnet/sys_bsd.c head/contrib/telnet/telnet/telnet.1 head/contrib/telnet/telnet/telnet.c head/contrib/telnet/telnet/types.h head/contrib/telnet/telnetd/sys_term.c head/contrib/tzcode/stdtime/localtime.c head/libexec/telnetd/Makefile
A commit references this bug: Author: ngie Date: Fri Dec 5 12:23:32 UTC 2014 New revision: 275508 URL: https://svnweb.freebsd.org/changeset/base/275508 Log: MFC r274364: Add baud rate support to telnet(1) This implements part of RFC-2217 It's based off a patch originally written by Sujal Patel at Isilon, and contributions from other Isilon employees. PR: 173728 Phabric: D995 Reviewed by: markj, markm Sponsored by: EMC / Isilon Storage Division Changes: _U stable/10/ stable/10/contrib/telnet/arpa/telnet.h stable/10/contrib/telnet/telnet/baud.h stable/10/contrib/telnet/telnet/commands.c stable/10/contrib/telnet/telnet/externs.h stable/10/contrib/telnet/telnet/main.c stable/10/contrib/telnet/telnet/sys_bsd.c stable/10/contrib/telnet/telnet/telnet.1 stable/10/contrib/telnet/telnet/telnet.c stable/10/contrib/telnet/telnet/types.h stable/10/contrib/telnet/telnetd/sys_term.c stable/10/contrib/tzcode/stdtime/localtime.c stable/10/libexec/telnetd/Makefile
A commit references this bug: Author: ngie Date: Fri Dec 5 21:37:31 UTC 2014 New revision: 275525 URL: https://svnweb.freebsd.org/changeset/base/275525 Log: MFstable/10 r275508,r275509: r275508: MFC r274364: Add baud rate support to telnet(1) This implements part of RFC-2217 It's based off a patch originally written by Sujal Patel at Isilon, and contributions from other Isilon employees. PR: 173728 Phabric: D995 Reviewed by: markj, markm Sponsored by: EMC / Isilon Storage Division r275509: MFC r274365: Revert WiP to contrib/tzcode accidentally committed with r274364 Changes: _U stable/9/ _U stable/9/contrib/ _U stable/9/contrib/telnet/ stable/9/contrib/telnet/arpa/telnet.h stable/9/contrib/telnet/telnet/baud.h stable/9/contrib/telnet/telnet/commands.c stable/9/contrib/telnet/telnet/externs.h stable/9/contrib/telnet/telnet/main.c stable/9/contrib/telnet/telnet/sys_bsd.c stable/9/contrib/telnet/telnet/telnet.1 stable/9/contrib/telnet/telnet/telnet.c stable/9/contrib/telnet/telnet/types.h stable/9/contrib/telnet/telnetd/sys_term.c _U stable/9/contrib/tzcode/ _U stable/9/contrib/tzcode/stdtime/ stable/9/libexec/telnetd/Makefile