noc.core.script.cli.telnet

Module Contents

noc.core.script.cli.telnet._logger
noc.core.script.cli.telnet.IAC
noc.core.script.cli.telnet.DONT
noc.core.script.cli.telnet.DO
noc.core.script.cli.telnet.WONT
noc.core.script.cli.telnet.WILL
noc.core.script.cli.telnet.SB
noc.core.script.cli.telnet.SE
noc.core.script.cli.telnet.NAWS =
noc.core.script.cli.telnet.AO
noc.core.script.cli.telnet.AYT
noc.core.script.cli.telnet.IAC_CMD
noc.core.script.cli.telnet.IGNORED_CMD
noc.core.script.cli.telnet.TELNET_OPTIONS
noc.core.script.cli.telnet.ACCEPTED_TELNET_OPTIONS = 
class noc.core.script.cli.telnet.TelnetParser(logger=None, writer=None, naws='x00x80x00x80')

Bases: object

Telnet protocol state and commands processing

feed(self, chunk)

Feed chunk of data to parser

Parameters:chunk – String
Returns:Parsed data
send_iac(self, cmd, opt)

Send IAC response

send_iac_sb(self, opt, data=None)
process_iac(self, cmd, opt)

Process IAC command.

process_iac_sb(self, sb)
static iac_repr(cmd, opt)

Human-readable IAC sequence :param cmd: :param opt: :return:

static escape(data)
class noc.core.script.cli.telnet.TelnetIOStream(sock, cli, *args, **kwargs)

Bases: tornado.iostream.IOStream

startup(self)
read_from_fd(self)
write(self, data, callback=None)
class noc.core.script.cli.telnet.TelnetCLI

Bases: noc.core.script.cli.base.CLI

name = telnet
default_port = 23
iostream_class