Skip to content

Releases: jquast/telnetlib3

4.0.4

23 May 20:22

Choose a tag to compare

  • bugfix servers using robot_check=True+encoding=False by @jquast in #144

Full Changelog: 4.0.3...4.0.4

4.0.3

20 May 15:47

Choose a tag to compare

  • bugfix: long-running servers leaked memory through :class:~telnetlib3.server.Server _protocols list and _new_client asyncio.Queue. Both are now bounded and regularly pruned.

  • enhancement: telnetlib3.telnet now overlays std library module space, import telnetlib :ghissue:139.

  • enhancement: telnetlib3-fingerprint-server and telnetlib3-fingerprint client now also detect "telnet loops" and "wrong direction" errors in opposing IAC parser.

  • removed: telnetlib3-fingerprint-server no longer integrates with the (never released) tv-detect package for terminal vulnerability probing.

  • provide legacy 'import telnetlib' compatibility by @jquast in #141

  • Refactor and remove tv-detect by @jquast in #142

Full Changelog: 4.0.2...4.0.3

4.0.2

10 Apr 19:15

Choose a tag to compare

  • bugfix: MCCP2 decompression failed on MUD servers using raw deflate or gzip-wrapped compression,
    producing garbled banners. The client now auto-detects zlib/gzip format and falls back to raw
    deflate when needed.
  • bugfix: NEW_ENVIRON SEND requests that exceed the 256-byte subnegotiation buffer of some
    telnet clients (e.g. GNU inetutils) are now automatically split into multiple SB frames.
  • bugfix: telnetlib3-server argument --tls-auto deadlocked with plain telnet clients.
    Detection now uses a non-blocking with a configurable timeout.
  • enhancement: writer.get_extra_info("ssl_object") is available in shell callbacks to detect
    TLS-secured connections and query the negotiated protocol version and cipher.
  • enhancement: telnetlib3-fingerprint-server integrates with the optional tv-detect
    package for terminal vulnerability probing.

4.0.1

07 Mar 18:49
f508a5c

Choose a tag to compare

What's Changed

  • bugfix TypeError in request_charset() by @jquast in #129
  • Kludge mode fix (WILL SGA/DO SGA) by @jquast in #130
  • LINEMODE negotiation fixes by @jquast in #131
  • Remove color_filter module (Moving to Telix) by @jquast in #132
  • sort arguments alphabetically by @jquast in #133
  • Add --always-dont and --always-wont=TEL,OPTS by @jquast in #134
  • bugfix connection burst sometimes loses ECHO mode by @jquast in #135
  • New 'big5bbs' encoding! by @jquast in #136
  • Support Windows for telnetlib3-client by @jquast in #137

Full Changelog: 3.0.1...4.0.1

3.0.1

01 Mar 19:17

Choose a tag to compare

  • change: Unused client argument gmcp_log removed.
  • new: MCCP2 and MCCP3. Both client and server ends passively support if requested, and request support by --compression or deny support by --no-compression.

Full Changelog: 3.0.0...3.0.1

3.0.0

28 Feb 07:18
1bfd2b0

Choose a tag to compare

3.0.0

  • change: connect_minwait default now 0 (was 1.0 seconds in library API).
  • change: force_binary auto-enabled when CHARSET is negotiated (RFC 2066) or LANG/CHARSET received via NEW_ENVIRON (RFC 1572). SyncTERM font detection also enables it unconditionally.
  • change: --connect-timeout default changed from no limit to 10 seconds.
  • change: --reverse-video CLI option from 2.4.0 was removed.
  • change: CGA, EGA, and Amiga palettes removed from --colormatch; only vga is available at this time. ice_colors are now True by default.
  • bugfix: read_some() in synchronous API (TelnetConnection and ServerConnection) blocked until EOF instead of returning available data. Now returns as soon as any data is available.
  • new: TelnetSessionContext base class and writer.ctx attribute for per-connection session state. Subclass to add application-specific attributes (e.g. MUD client state).
  • new: --ice-colors (default on) treats SGR 5 (blink) as bright background for proper 16-color BBS/ANSI art display.
  • new: --typescript FILE records session output to a file, similar to the Unix script(1) command.
  • new: shared TelnetProtocolBase mixin extracted from duplicated server and client protocol code.
  • new: _atomic_json_write() and _BytesSafeEncoder helpers in _paths module for fingerprinting subsystem.
  • enhancement: Microsoft Telnet (telnet.exe) compatibility refined — server now sends DO NEW_ENVIRON but excludes USER variable instead of skipping the option entirely, #24.
  • enhancement: comprehensive pylint and mypy cleanup across the codebase.

2.6.1

28 Feb 01:15

Choose a tag to compare

Bugfix wcwidth dependency, #126

Full Changelog: 2.6.0...2.6.1

2.6.0

17 Feb 03:03
2902206

Choose a tag to compare

  • new: TLS support (TELNETS). open_connection() accepts an ssl parameter (True, or an ssl.SSLContext). create_server() accepts an ssl parameter (ssl.SSLContext). New CLI options: --ssl, --ssl-cafile, --ssl-no-verify for telnetlib3-client; --ssl-certfile, --ssl-keyfile and --tls-auto for telnetlib3-server.
  • new: the default server shell now displays Ready (secure: TLSv1.3). for TLS connections (the protocol version shown is negotiated dynamically).
  • bugfix: telnetlib3-client now sets terminal mode to the server's preference via WILL ECHO and WILL SGA negotiation. Use --raw-mode to restore legacy raw mode for servers that don't negotiate.
  • bugfix: telnetlib3-client declines MUD protocol options (GMCP, MSDP, MSSP, MSP, MXP, ZMP, AARDWOLF, ATCP) by default. Use --always-do or --always-will to opt in.
  • bugfix: log output "staircase text" in raw terminal mode.
  • bugfix: graceful EOF handling — connection close no longer prints a traceback.

Full Changelog: 2.5.0...2.6.0

2.5.0

14 Feb 23:55

Choose a tag to compare

  • change: telnetlib3-client now defaults to raw terminal mode (no line buffering, no local echo), which is correct for most servers. Use --line-mode to restore line-buffered local-echo behavior.
  • change: telnetlib3-server --pty-exec now defaults to raw PTY mode. Use --line-mode to restore cooked PTY mode with echo.
  • change: connect_minwait default reduced to 0 across BaseClient, open_connection(), and telnetlib3-client. Negotiation continues asynchronously. Use --connect-minwait to restore a delay if needed, or use TelnetWriter.wait_for() in server or client shells to await a specific negotiation state.
  • new: Color, keyboard input translation and --encoding support for ATASCII (ATARI ASCII) and PETSCII (Commodore ASCII).
  • new: SyncTERM/CTerm font selection sequence detection (CSI Ps1 ; Ps2 SP D). Both telnetlib3-fingerprint and telnetlib3-client detect font switching and auto-switch encoding to the matching codec (e.g. font 36 = ATASCII, 32-35 = PETSCII, 0 = CP437). Explicit --encoding takes precedence.
  • new: TRACE log level (5, below DEBUG) with hexdump style output for all sent and received bytes. Use --loglevel=trace.
  • bugfix: robot_check() now uses a narrow character (space) instead of a wide Unicode character, allowing retro terminal emulators to pass.
  • bugfix: ATASCII codec now maps bytes 0x0D and 0x0A to CR and LF instead of graphics characters, fixing garbled output when connecting to Atari BBS systems.
  • bugfix: ATASCII codec normalizes CR and CRLF to the native ATASCII EOL (0x9B) during encoding, so the Return key works correctly.
  • bugfix: PETSCII bare CR (0x0D) is now normalized to CRLF in raw terminal mode and to LF in telnetlib3-fingerprint banners.
  • bugfix: telnetlib3-fingerprint re-encodes prompt responses for retro encodings so servers receive the correct EOL byte.
  • bugfix: telnetlib3-fingerprint no longer crashes with LookupError when the server negotiates an unknown charset. Banner formatting falls back to latin-1.
  • bugfix: TelnetClient.send_charset() normalises non-standard encoding names (iso-8859-02 to iso-8859-2, cp-1250 to cp1250, etc.).
  • enhancement: telnetlib3-fingerprint responds more like a terminal and to more y/n prompts about colors, encoding, etc. to collect more banners for the https://bbs.modem.xyz/ project.
  • enhancement: telnetlib3-fingerprint banner formatting uses surrogateescape error handler, preserving raw high bytes (e.g. CP437 art) as surrogates instead of replacing them with U+FFFD.

Full Changelog: 2.4.0...2.5.0

2.4.0

10 Feb 15:48

Choose a tag to compare

  • change: wcwidth is now a required dependency!
  • bugfix: rare LINEMODE ACK loop with misbehaving servers that re-send unchanged MODE without ACK.
  • bugfix: unknown IAC commands no longer raise ValueError; treated as data.
  • bugfix: client no longer asserts on TTYPE IS from server.
  • bugfix: request_forwardmask() only called on server side.
  • enhancement: --banner-max-bytes option for telnetlib3-fingerprint; default raised from 1024 to 65536.
  • enhancement: new --encoding=petscii and --encoding=atarist
  • new: module telnetlib3.color_filter module — translates 16-color ANSI SGR codes to 24-bit RGB from hardware palettes (EGA, CGA, VGA, Amiga, xterm). Enabled by default. New client CLI options: --colormatch, --color-brightness, --color-contrast, --background-color, --reverse-video.
  • new: function telnetlib3.mud.zmp_decode, mud.atcp_decode, and mud.aardwolf_decode decode functions for ZMP (option 93), ATCP (option 200), and Aardwolf (option 102) MUD protocols.
  • new: methods telnetlib3.stream_writer.TelnetWriter.handle_zmp, handle_atcp, handle_aardwolf, handle_msp, and handle_mxp callbacks for receiving MUD extended protocol subnegotiations, with accumulated data stored in zmp_data, atcp_data, and aardwolf_data attributes.
  • new: COM-PORT-OPTION (rfc 2217) subnegotiation parsing with comport_data attribute and new method telnetlib3.stream_writer.TelnetWriter.request_comport_signature.
  • enhancement: telnetlib3-fingerprint now always probes extended MUD options (MSP, MXP, ZMP, AARDWOLF, ATCP) during server scans and captures ZMP, ATCP, Aardwolf, MXP, and COM-PORT data in session output.
  • enhancement: telnetlib3-fingerprint smart prompt detection — auto-answers yes/no, color, UTF-8 menu, who, and help prompts.