man page(1) manual page
Table of Contents
protocol
The command is used for interactive communication with another
host using the protocol. It begins in command mode, where it prints a
telnet prompt ("telnet> "). If is invoked with a argument, it performs
an command implicitly; see the description below. Options: Request 8-bit
operation. This causes an attempt to negotiate the option for both input
and output. By default telnet is not 8-bit clean. Disables the escape character
functionality; that is, sets the escape character to ‘‘no character’’. Specifies
an 8-bit data path on output. This causes the option to be negotiated
on just output. Attempt automatic login. Currently, this sends the user
name via the variable of the option if supported by the remote system.
The username is retrieved via Sets the initial value of the toggle to
Emulate In this mode, the default escape character is a tilde. Also,
the interpretation of the escape character is changed: an escape character
followed by a dot causes to disconnect from the remote host. A ^Z instead
of a dot suspends and a ^] (the default escape character) generates a
normal telnet prompt. These codes are accepted only at the beginning of
a line. Sets the IP type-of-service (TOS) option for the telnet connection
to the value Sets the escape character to If no character is supplied,
no escape character will be used. Entering the escape character while connected
causes telnet to drop to command mode. Specify as the user to log in
as on the remote system. This is accomplished by sending the specified name
as the environment variable, so it requires that the remote system support
the option. This option implies the option, and may also be used with
the command. Opens for recording trace information. See the command below.
Specifies a host to contact over the network. Specifies a port number
or service name to contact. If not specified, the port (23) is used.
Protocol: Once a connection has been opened, will attempt to enable the
option. If this fails, then will revert to one of two input modes: either
qcharacter at a timeRq or qold line by lineRq depending on what the remote
system supports. When is enabled, character processing is done on the
local system, under the control of the remote system. When input editing
or character echoing is to be disabled, the remote system will relay that
information. The remote system will also relay changes to any special characters
that happen on the remote system, so that they can take effect on the local
system. In qcharacter at a timeRq mode, most text typed is immediately
sent to the remote host for processing. In qold line by lineRq mode, all
text is echoed locally, and (normally) only completed lines are sent to
the remote host. The qlocal echo characterRq (initially q^ERq) may be used
to turn off and on the local echo (this would mostly be used to enter passwords
without the password being echoed). If the option is enabled, or if the
toggle is (the default for qold line by lineq; see below), the user’s
and characters are trapped locally, and sent as protocol sequences
to the remote side. If has ever been enabled, then the user’s and are
also sent as protocol sequences, and is sent as a instead of There
are options (see and below) which cause this action to flush subsequent
output to the terminal (until the remote host acknowledges the sequence)
and flush previous terminal input (in the case of and Commands: The
following commands are available. Unique prefixes are understood as abbreviations.
The command controls the protocol option. If was compiled without
authentication, the command will not be supported. Valid arguments are
as follows: Disable the specified type of authentication. To obtain a
list of available types, use the command. Enable the specified type of
authentication. To obtain a list of available types, use the command.
List the current status of the various types of authentication. Note that
the current version of does not support authentication. Close the connection
to the remote host, if any, and return to command mode. Display all, or
some, of the and values (see below). The encrypt command controls the
protocol option. If was compiled without encryption, the command will
not be supported. Valid arguments are as follows: Disable the specified
type of encryption. If you do not specify input or output, encryption of
both is disabled. To obtain a list of available types, use ‘‘encrypt disable
?’’. Enable the specified type of encryption. If you do not specify input
or output, encryption of both is enabled. To obtain a list of available
types, use ‘‘encrypt enable ?’’. This is the same as ‘‘encrypt start input’’. This
is the same as ‘‘encrypt stop input’’. This is the same as ‘‘encrypt start output’’.
This is the same as ‘‘encrypt stop output’’. Attempt to begin encrypting.
If you do not specify input or output, encryption of both input and output
is started. Display the current status of the encryption module. Stop
encrypting. If you do not specify input or output, encryption of both is
stopped. Sets the default type of encryption to be used with later ‘‘encrypt
start’’ or ‘‘encrypt stop’’ commands. Note that the current version of does
not support encryption. The command is used to propagate environment variables
across the link using the protocol option. All variables exported from
the shell are defined, but only the and variables are marked to be sent
by default. The variable is marked to be sent if the or command-line
options were used. Valid arguments for the command are: Define the variable
to have a value of Any variables defined by this command are automatically
marked for propagation (‘‘exported’’). The may be enclosed in single or double
quotes so that tabs and spaces may be included. Remove any existing definition
of Mark the specified variable for propagation to the remote host. Do
not mark the specified variable for propagation to the remote host. The
remote host may still ask explicitly for variables that are not exported.
List the current set of environment variables. Those marked with a will
be propagated to the remote host. The remote host may still ask explicitly
for the rest. Prints out help information for the command. Send the
protocol option to the remote host. This command is similar to a command.
If the remote host does not support the option, nothing happens. But if
it does, this command should cause it to close the connection. If the remote
side also supports the concept of suspending a user’s session for later
reattachment, the logout command indicates that the session should be terminated
immediately. is one of several options, depending on the state of the
session. asks the remote host to go into the requested mode. If the remote
host says it can, that mode takes effect. Disable the option, or, if
the remote side does not understand the option, then enter qcharacter
at a timeq mode. Enable the option, or, if the remote side does not understand
the option, then attempt to enter qold-line-by-lineq mode. Attempt to enable
(disable) the mode of the option. This requires that the option be
enabled. Attempt to enable (disable) the mode of the option. This requires
that the option be enabled. Attempt to enable (disable) the mode of
the option. This requires that the option be enabled. Attempt to enable
(disable) the mode of the option. This requires that the option be
enabled. Prints out help information for the command. Open a connection
to the named host. If no port number is specified, will attempt to contact
a daemon at the standard port (23). The host specification may be a host
name or IP address. The option may be used to specify a user name to be
passed to the remote system, like the command-line option. When connecting
to ports other than the port, does not attempt protocol negotiations.
This makes it possible to connect to services that do not support the
protocol without making a mess. Protocol negotiation can be forced by placing
a dash before the port number. After establishing a connection, any commands
associated with the remote host in the user’s file are executed. The format
of the .telnetrc file is as follows: Lines beginning with a #, and blank
lines, are ignored. The rest of the file should consist of hostnames and
sequences of commands to use with that host. Commands should be one per
line, indented by whitespace; lines beginning without whitespace are interpreted
as hostnames. Upon connecting to a particular host, the commands associated
with that host are executed. Close any open session and exit An end of
file condition on input, when in command mode, will trigger this operation
as well. Send one or more special protocol character sequences to the
remote host. The following are the codes which may be specified (more than
one may be used in one command): Sends the (Abort Processes) sequence.
Sends the (Abort Output) sequence, which should cause the remote system
to flush all output the remote system the user’s terminal. Sends the
(Are You There?) sequence, to which the remote system may or may not choose
to respond. Sends the (Break) sequence, which may have significance to
the remote system. Sends the (Erase Character) sequence, which should
cause the remote system to erase the last character entered. Sends the
(Erase Line) sequence, which should cause the remote system to erase the
line currently being entered. Sends the (End Of File) sequence. Sends
the (End of Record) sequence. Sends the current escape character. Sends
the (Go Ahead) sequence, which likely has no significance to the remote
system. If the remote side supports the command, will send the subnegotiation
to request that the server send its current option status. Sends the (Interrupt
Process) sequence, which should cause the remote system to abort the currently
running process. Sends the (No Operation) sequence. Sends the (Suspend
Process) sequence. Sends the sequence. This sequence causes the remote
system to discard all previously typed (but not yet read) input. This sequence
is sent as urgent data (and may not work if the remote system is a system
-- if it doesn’t work, a lower case qrRq may be echoed on the terminal).
Sends the sequence. can be either a decimal number between 0 and 255,
or a symbolic name for a specific command. can also be either or to
print out help information, including a list of known symbolic names. Prints
out help information for the command. The command will set any one
of a number of variables to a specific value or to The special value
turns off the function associated with the variable. This is equivalent
to using the command. The command will disable or set to any of the specified
variables. The values of variables may be interrogated with the command.
The variables which may be set or unset, but not toggled, are listed here.
In addition, any of the variables for the command may be explicitly set
or unset. If is in localchars mode, or is enabled, and the status character
is typed, a sequence is sent to the remote host. The initial value for
the "Are You There" character is the terminal’s status character. This is
the value (initially q^ERq) which, when in qline by lineRq mode, toggles
between doing local echoing of entered characters (for normal processing),
and suppressing echoing of entered characters (for entering, say, a password).
If is operating in or qold line by lineRq mode, entering this character
as the first character on a line will cause this character to be sent to
the remote system. The initial value of the eof character is taken to be
the terminal’s character. If is in mode (see below), if is operating
in qcharacter at a timeRq mode, then when this character is typed, a sequence
(see above) is sent to the remote system. The initial value for the erase
character is taken to be the terminal’s character. This is the escape
character (initially q^[Rq) which causes entry into command mode (when
connected to a remote system). If is in mode (see below) and the character
is typed, a sequence (see above) is sent to the remote host. The initial
value for the flush character is taken to be the terminal’s character.
If is operating in these are the characters that, when typed, cause
partial lines to be forwarded to the remote system. The initial value for
the forwarding characters are taken from the terminal’s eol and eol2 characters.
If is in mode (see below) and the character is typed, a sequence
(see above) is sent to the remote host. The initial value for the interrupt
character is taken to be the terminal’s character. If is in mode (see
below), if is operating in qcharacter at a timeRq mode, then when this
character is typed, a sequence (see above) is sent to the remote system.
The initial value for the kill character is taken to be the terminal’s
character. If is operating in or qold line by lineq mode, then this character
is taken to be the terminal’s character. The initial value for the lnext
character is taken to be the terminal’s character. If is in mode (see
below) and the character is typed, a sequence (see above) is sent
to the remote host. The initial value for the quit character is taken to
be the terminal’s character. If is operating in or qold line by lineq
mode, then this character is taken to be the terminal’s character. The initial
value for the reprint character is taken to be the terminal’s character.
This is the rlogin mode escape character. Setting it enables rlogin mode,
as with the command-line option (q.v.) If the option has been enabled,
then this character is taken to be the terminal’s character. The initial
value for the kill character is taken to be the terminal’s character. If
the option has been enabled, then this character is taken to be the terminal’s
character. The initial value for the kill character is taken to be the
terminal’s character. If is in mode, or is enabled, and the character
is typed, a sequence (see above) is sent to the remote host. The initial
value for the suspend character is taken to be the terminal’s character.
This is the file to which the output, caused by or tracing being will
be written. If it is set to then tracing information will be written to
standard output (the default). If is operating in or qold line by lineq
mode, then this character is taken to be the terminal’s character. The initial
value for the worderase character is taken to be the terminal’s character.
Displays the legal commands. The command (Set Local Characters) is
used to set or change the state of the the special characters when the
option has been enabled. Special characters are characters that get mapped
to commands sequences (like or or line editing characters (like and
By default, the local special characters are exported. Verify the current
settings for the current special characters. The remote side is requested
to send all the current special character settings, and if there are any
discrepancies with the local side, the local side will switch to the remote
value. Switch to the local defaults for the special characters. The local
default characters are those of the local terminal at the time when was
started. Switch to the remote defaults for the special characters. The remote
default characters are those of the remote system at the time when the
connection was established. Prints out help information for the command.
Show the current status of This includes the name of the remote host,
if any, as well as the current mode. Toggle (between and various flags
that control how responds to events. These flags may be set explicitly
to or using the and commands. More than one flag may be toggled at once.
The state of these flags may be examined with the command. Valid flags
are: Turns on debugging for the authentication code. This flag only exists
if authentication support is enabled. If and are both then when the
or characters are recognized (and transformed into sequences; see above
for details), refuses to display any data on the user’s terminal until
the remote system acknowledges (via a option) that it has processed those
sequences. The initial value for this toggle is if the terminal user had
not done an "stty noflsh", otherwise (see When the option is negotiated,
by default the actual encryption (decryption) of the data stream does not
start automatically. The autoencrypt (autodecrypt) command states that
encryption of the output (input) stream should be enabled as soon as possible.
Note that this flag exists only if encryption support is enabled. If the
remote side supports the option, attempts to use it to perform automatic
authentication. If the option is not supported, the user’s login name is
propagated using the option. Setting this flag is the same as specifying
the option to the command or on the command line. If and are both
then when either the or characters is typed (see above for descriptions
of the and characters), the resulting sequence sent is followed by the
sequence. This procedure cause the remote system to begin throwing away
all previously typed input until both of the sequences have been read
and acted upon. The initial value of this toggle is Enable or disable
the option on both input and output. Enable or disable the option on
input. Enable or disable the option on output. If this is then carriage
returns will be sent as If this is then carriage returns will be send
as The initial value for this toggle is Toggle carriage return mode.
When this mode is enabled, most carriage return characters received from
the remote host will be mapped into a carriage return followed by a line
feed. This mode does not affect those characters typed by the user, only
those received from the remote host. This mode is not very useful unless
the remote host only sends carriage return, but never line feed. The initial
value for this toggle is Toggles socket level debugging (useful only
to the The initial value for this toggle is Turns on debugging information
for the encryption code. Note that this flag only exists if encryption support
is available. If this is then the and characters (see above) are
recognized locally, and transformed into (hopefully) appropriate control
sequences (respectively and see above). The initial value for this
toggle is in qold line by lineRq mode, and in qcharacter at a timeRq
mode. When the option is enabled, the value of is ignored, and assumed
to always be If has ever been enabled, then is sent as and suspend
are sent as see above). Toggles the display of all network data (in
hexadecimal format). The initial value for this toggle is Toggles the
display of some internal protocol processing (having to do with options).
The initial value for this toggle is When the toggle is enabled, if
is enabled the output from the command will be formatted in a more user-readable
format. Spaces are put between each character in the output, and the beginning
of escape sequences are preceded by a ’*’ to aid in locating them. When
the skiprc toggle is does not read the file. The initial value for
this toggle is Toggles the display of all terminal data (in hexadecimal
format). The initial value for this toggle is When the toggle is prints
out a message each time encryption is enabled or disabled. The initial
value for this toggle is This flag only exists if encryption support is
available. Displays the legal commands. Suspend This command only works
when the user is using the Execute a single command in a subshell on
the local system. If is omitted, then an interactive subshell is invoked.
Get help. With no arguments, prints a help summary. If a command is specified,
will print the help information for just that command.
ENVIRONMENT
uses
at least the and environment variables. Other environment variables
may be propagated to the other side via the option.
user customized
telnet startup values
The command appeared in
On some remote
systems, echo has to be turned off manually when in qold line by lineRq
mode. In qold line by lineRq mode or the terminal’s character is only
recognized (and sent to the remote system) when it is the first character
on a line.
BUGS
The source code is not comprehensible.
Table of Contents