home *** CD-ROM | disk | FTP | other *** search
/ Unix System Administration Handbook 1997 October / usah_oct97.iso / rfc / 700s / rfc726.txt < prev    next >
Text File  |  1992-10-14  |  39KB  |  944 lines

  1.  
  2.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  3.      Remote Controlled Transmission & Echoing Telnet Option
  4.  
  5.  
  6.  
  7.      Network Working Group             Jon Postel & Dave Crocker
  8.      Request for Comments: 726            SRI-ARC      UC Irvine
  9.      NIC: 39237                                     8 March 1977
  10.  
  11.      
  12.      
  13.        Remote Controlled Transmssion and Echoing Telnet Option
  14.  
  15.  
  16.                                                                        1
  17.  
  18.      1.  Command name and code:                                        2
  19.  
  20.        RCTE 7                                                         2a
  21.  
  22.      2.  Command meanings:                                             3
  23.  
  24.        IAC WILL RCTE                                                  3a
  25.  
  26.          The sender of this command REQUESTS or AGREES to use
  27.          the RCTE option, and will send instructions for
  28.          controlling the other side's terminal printer.              3a1
  29.  
  30.        IAC WON'T RCTE                                                 3b
  31.  
  32.          The sender of this option REFUSES to send instructions
  33.          for controlling the other side's terminal printer.          3b1
  34.  
  35.        IAC DO RCTE                                                    3c
  36.  
  37.          The sender REQUEST or AGREES to have the other side
  38.          (sender of WILL RCTE) issue commands which will control
  39.          his (sender of the DO) output to the terminal printer.      3c1
  40.  
  41.        IAC DON'T RCTE                                                 3d
  42.  
  43.          The sender of this command REFUSES to allow the other
  44.          side to control his (sender of DON'T) terminal printer.     3d1
  45.  
  46.        IAC SB RCTE <cmd> [BC1 BC2] [TC1 TC2] IAC SE                   3e
  47.  
  48.          where:                                                      3e1
  49.  
  50.            <cmd> is one 8-bit byte having the following flags
  51.            (bits are counted from the right):                       3e1a
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.                                                                 [page 1]
  60.  
  61.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  62.      Remote Controlled Transmission & Echoing Telnet Option
  63.  
  64.  
  65.  
  66.            Bit  Meaning                                             3e1b
  67.  
  68.             0   0 = Ignore all other bits in this byte and
  69.                     repeat the last <cmd> that was sent. Equals
  70.                     a 'continue what you have been doing'.
  71.                 1 = Perform actions as indicated by other bits
  72.                     in this byte.                                   3e1c
  73.  
  74.             1   0 = Print (echo) break character
  75.                 1 = Skip (don't echo) break character               3e1d
  76.  
  77.             2   0 = Print (echo) text up to break character
  78.                 1 = Skip (don't echo) text up to break character    3e1e
  79.  
  80.             3   0 = Continue using same classes of break
  81.                     characters.
  82.                 1 = The two 8-bit bytes following this byte
  83.                     contain flags for the new break classes.        3e1f
  84.  
  85.             4   0 = Continue using same classes of transmit
  86.                     characters.
  87.                 1 = Reset transmit classes according to the two
  88.                     bytes following 1) the break classes bytes,
  89.                     if the break classes are also being reset,
  90.                     or 2) this byte, if the break classes are
  91.                     NOT also being reset.                           3e1g
  92.  
  93.            Value (decimal) of the <cmd> byte and its meaning:       3e1h
  94.  
  95.            0 = Continue what you have been doing                    3e1i
  96.  
  97.            Even numbers greater than zero (i.e. numbers with the
  98.            right most bit off) are in error and should be
  99.            interpreted as equal to zero. When the <cmd> is an
  100.            even number greater than zero, classes bytes TC1 &
  101.            TC2 and/or BC1 & BC2 must not be sent.                   3e1j
  102.  
  103.            1 = Print (echo) up to AND INCLUDING break character     3e1k
  104.  
  105.            3 = Print up to break character and SKIP (don't echo)
  106.                break character                                      3e1l
  107.  
  108.            5 = Skip text (don't echo) up to break character, but
  109.                PRINT break character                                3e1m
  110.  
  111.            7 = Skip up to and including break character             3e1n
  112.  
  113.            Add one of the previous non-zero values to one of the
  114.            following values, to get the total decimal value for
  115.  
  116.  
  117.  
  118.                                                                 [page 2]
  119.  
  120.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  121.      Remote Controlled Transmission & Echoing Telnet Option
  122.  
  123.  
  124.  
  125.            the byte (Note that classes may not be reset without
  126.            also resetting the printing action; so an odd number
  127.            is guaranteed):                                          3e1o
  128.  
  129.            8 = Set break classes (using the next two bytes [BC1
  130.                BC2])                                                3e1p
  131.  
  132.            16 = Set transmission classes (using the next two
  133.                bytes [TC1 TC2])                                     3e1q
  134.  
  135.            24 = Set break classes (using the next two bytes [BC1
  136.                BC2]) and the transmission classes (using the two
  137.                bytes after that [TC1 TC2]).                         3e1r
  138.  
  139.          Sub-commands (IAC SB RCTE...) are only sent by the
  140.          controlling host and, in addition to other functions,
  141.          functionally replace the Go-Ahead (IAC GA) Telnet
  142.          feature. RCTE also functionally replaces the Echo (IAC
  143.          ECHO) Telnet option. That is the Suppress Go-Ahead
  144.          option should be in force and the Echo option should
  145.          not be in force while the RCTE option is in use. The
  146.          echo mode on terminating use of the RCTE option should
  147.          be the default state, that is DON'T ECHO, WON'T ECHO.       3e2
  148.  
  149.          Classes for break and transmission (the right-most bit
  150.          of the second byte (TC2 or BC2) represents class 1; the
  151.          left-most bit of the first byte (TC1 or BC1) represents
  152.          the currently undefined class 16:                           3e3
  153.  
  154.            1: Upper-Case Letter (A-Z)                               3e3a
  155.  
  156.            2: Lower-case Letters (a-z)                              3e3b
  157.  
  158.            3: Numbers (0-9)                                         3e3c
  159.  
  160.            4: Format Effectors (<BS> <CR> <LF> <FF> <HT> <VT>)      3e3d
  161.  
  162.              The sequence <cr><lf> counts as one character when
  163.                 processed as the Telnet end of line, and is a
  164.                 single break character when class 4 is set. The
  165.                 sequence <cr><nul> counts as one character and
  166.                 is a break character if and only if <cr> is a
  167.                 break character (i.e. class 4 is set).
  168.  
  169.            5: Non-format Effector Control Characters including
  170.               <DEL> and <ESC>                                       3e3e
  171.  
  172.            6: . , ; : ? !                                           3e3f
  173.  
  174.  
  175.  
  176.  
  177.                                                                 [page 3]
  178.  
  179.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  180.      Remote Controlled Transmission & Echoing Telnet Option
  181.  
  182.  
  183.  
  184.            7: { [ ( < > ) ] }                                       3e3g
  185.  
  186.            8: ' "  / \ % @ $ & # + - * = ^ _ | ~                    3e3h
  187.  
  188.            9: <Space>                                               3e3i
  189.  
  190.            And Telnet commands (IAC . . .) sent by the user are
  191.            always to have the effect of a break character. That
  192.            is, every instance of an IAC is to be treated as a
  193.            break character, except the sequence IAC IAC.            3e3j
  194.  
  195.          The representation to be displayed when printing is
  196.          called for is the obvious one for the visible
  197.          characters (classes 1, 2, 3, 6, 7, and 8). Space (class
  198.          9) is represented by a blank space. The format
  199.          effectors (class 4) by their format effect. The
  200.          non-format effector controls (class 5) print nothing
  201.          (no space).                                                 3e4
  202.  
  203.          Initially no break classes or transmission classes are
  204.          in effect.                                                  3e5
  205.  
  206.          Please note that if all the bits are set in a Telnet
  207.          subcommand argument byte such as TC2 or BC2 then that
  208.          byte must be preceeded by an <IAC> flag byte. This is
  209.          the common convention of doubling the escape character
  210.          to use its value as data.                                   3e6
  211.  
  212.          Sub-commands (IAC SB RCTE...) are refered to as "break
  213.          reset commands".                                            3e7
  214.  
  215.      3.  Default:                                                      4
  216.  
  217.        WON'T RCTE -- DON'T RCTE                                       4a
  218.  
  219.          Neither host asserts special control over the other
  220.          host's terminal printer.                                    4a1
  221.  
  222.      4.  Motivation for the option:                                    5
  223.  
  224.        RFC's 1, 5 and 51 discuss Network and process efficiency
  225.        and smoothness.                                                5a
  226.  
  227.        RFC 357, by John Davidson, introduces the problem of
  228.        echoing delay that occurs when a remote user accesses a
  229.        full-duplex host, thru a satellite link. In order to save
  230.        the many thousands of miles of transit time for each
  231.        echoed character, while still permitting full server
  232.        responsiveness and clean terminal output, an echo control
  233.  
  234.  
  235.  
  236.                                                                 [page 4]
  237.  
  238.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  239.      Remote Controlled Transmission & Echoing Telnet Option
  240.  
  241.  
  242.  
  243.        similar to that used by some time-sharing systems is
  244.        suggested for the entire Network.                              5b
  245.  
  246.          In effect, the option described in this document
  247.          involves making a using host carefully regulate the
  248.          local terminal printer according to explicit
  249.          instructions from the remote (serving) host.                5b1
  250.  
  251.        An important additional issue is efficient Network
  252.        transmission. Implementation of the Davidson Echoing
  253.        Scheme will eliminate almost all server-to-user echoing.       5c
  254.  
  255.          The option described in this document also requests
  256.          using hosts to buffer a terminal's input to the serving
  257.          host until it forms a useful unit (with "useful unit"
  258.          delimited by break or transmission characters as
  259.          described below). Therefore, fewer messages are sent on
  260.          the user-to-server path.                                    5c1
  261.  
  262.        N.B.:  This option is only intended for use with
  263.        full-duplex hosts. The Go-Ahead Telnet feature is
  264.        completely adequate for half-duplex server hosts. Also,
  265.        RCTE should be used in place of the ECHO Telnet option.
  266.        That is the Suppress Go-Ahead option should be in force
  267.        and the Echo option should not be in force while the RCTE
  268.        option is in use.                                              5d
  269.  
  270.  
  271.  
  272.  
  273.  
  274.  
  275.  
  276.  
  277.  
  278.  
  279.  
  280.  
  281.  
  282.  
  283.  
  284.  
  285.  
  286.  
  287.  
  288.  
  289.  
  290.  
  291.  
  292.  
  293.  
  294.  
  295.                                                                 [page 5]
  296.  
  297.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  298.      Remote Controlled Transmission & Echoing Telnet Option
  299.  
  300.  
  301.  
  302.      5.  Explicit description of control mechanism:                    6
  303.  
  304.        User Terminal Printing Action & Control Procedure              6a
  305.  
  306.          Negotiate the use of the RCTE option. Once the option
  307.          is in force the user Telnet follows the following
  308.          procedure.                                                  6a1
  309.  
  310.          1) Read an item from the network.                           6a2
  311.  
  312.            If the item is data, then print it and go to 1.          6a2a
  313.  
  314.            If the item is a command, then set the classes and go
  315.            to 2.                                                    6a2b
  316.  
  317.          2) If the terminal input buffer is empty, then go to 3,
  318.          else go to 4.                                               6a3
  319.  
  320.          3) Wait for an item to appear either from the terminal
  321.          or from the network.                                        6a4
  322.  
  323.            If an item appears from the terminal, then go to 4.      6a4a
  324.  
  325.            If a data item appears from the network, then print
  326.            it and go to 3.                                          6a4b
  327.  
  328.            If a command appears from the network, then an error
  329.            has occured.                                             6a4c
  330.  
  331.          4) Read an item from the terminal input buffer.             6a5
  332.  
  333.            If the item is not a break, then print/skip it and go
  334.            to 2.                                                    6a5a
  335.  
  336.            If the item is a break, then print/skip it and go to
  337.            1.                                                       6a5b
  338.  
  339.          Note:  Output from the server host may occur at any
  340.          time, such "spontaneous output" is printed in step 3.       6a6
  341.  
  342.  
  343.  
  344.  
  345.  
  346.  
  347.  
  348.  
  349.  
  350.  
  351.  
  352.  
  353.  
  354.                                                                 [page 6]
  355.  
  356.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  357.      Remote Controlled Transmission & Echoing Telnet Option
  358.  
  359.  
  360.  
  361.        Explanation:                                                   6b
  362.  
  363.          Both Hosts agree to use the RCTE option. After that,
  364.          the using host (IAC DO RCTE) merely acts upon the
  365.          controlling (serving) host's commands and does not
  366.          issue any RCTE commands unless and until it (using
  367.          host) decides to stop allowing use of the option (by
  368.          sending IAC DON'T RCTE).                                    6b1
  369.  
  370.          1)  The using host is synchronized with the server by
  371.          initially and when ever it returns to step 1 suspending
  372.          terminal echo printing until it receives a command from
  373.          the server.                                                 6b2
  374.  
  375.          The server may send either output to the terminal
  376.          printer or a command, and usually sends a both.             6b3
  377.  
  378.          The server may send output to the terminal printer
  379.          either in response to user input or spontaneously. In
  380.          the former case, the output is processed in step 1. In
  381.          the latter case, the output is processed in step 3.         6b4
  382.  
  383.          Server sends an RCTE command. The command may redefine
  384.          break and transmission classes, action to be performed
  385.          on break characters, and action to be performed on
  386.          text. Each of these independent functions is controlled
  387.          by separate bits in the <cmd> byte.                         6b5
  388.  
  389.            A transmission character is one which RECOMMENDS that
  390.            the using host transmit all text accumulated up to
  391.            and including its occurrence. (For network
  392.            efficiency, using hosts are DISCOURAGED (but not
  393.            prohibited) from sending before the occurrence of a
  394.            transmission character, as defined at the moment the
  395.            character is typed).                                     6b5a
  396.  
  397.              If the transmission classes bit (bit 4) is on, the
  398.              two bytes following the two break classes bytes (or
  399.              immediately following the <cmd> byte, if the break
  400.              classes bit is not on) will indicate what classes
  401.              are to be enabled.
  402.  
  403.              If the bit is OFF, the transmission classes remain
  404.              unchanged. When the RCTE option is first initiated,
  405.              NO CLASSES are in effect. That is, no character
  406.              will be considered a transmission character. (As if
  407.              both TC1 and TC2 are zero.)
  408.  
  409.            A break character REQUIRES that the using host
  410.  
  411.  
  412.  
  413.                                                                 [page 7]
  414.  
  415.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  416.      Remote Controlled Transmission & Echoing Telnet Option
  417.  
  418.  
  419.  
  420.            transmit all text accumulated up to and including its
  421.            occurrence and also causes the using host to stop its
  422.            print/discard action upon the user's input text,
  423.            until directed to do otherwise by another IAC SB RCTE
  424.            <cmd> IAC SE command from the serving host. Break
  425.            characters therefore define printing units. "Break
  426.            character" as used in this document does NOT mean
  427.            Telnet Break character.                                  6b5b
  428.  
  429.              If the break classes bit (bit 3) is on, the two
  430.              bytes following <cmd> will indicate what classes
  431.              are to be enabled. There are currently nine (9)
  432.              classes defined, with room for expansion.
  433.  
  434.              If the bit is OFF, the break classes remain
  435.              unchanged. When the RCTE option is initiated, NO
  436.              CLASSES are to be in effect. That is, no
  437.              transmission will take place in the user to server
  438.              direction until the first break reset command is
  439.              received by the user from the server.
  440.  
  441.            The list of character classes, used to define break
  442.            and transmission classes are listed at the end of
  443.            this document, in the Tables Section.                    6b5c
  444.  
  445.            Because break characters are special, the
  446.            print/discard action that should be performed upon
  447.            them is not always the same as should be performed
  448.            upon the rest of the input text.                         6b5d
  449.  
  450.              For example, while typing a filename to TENEX, I
  451.              want the text of the filename to be printed
  452.              (echoed); but I do not want the <escape> (if I use
  453.              the name completion feature) to be printed.
  454.  
  455.              If bit 1 is ON the break character is NOT to be
  456.              printed.
  457.  
  458.            A separate bit (bit 2) signals whether or not the
  459.            text itself should be printed (echoed) to the
  460.            terminal. If bit 2 = 0, then the text IS to be
  461.            printed.                                                 6b5e
  462.  
  463.            Yet another bit (bit 0 - right-most bit) signals
  464.            whether or not any of the other bits of the command
  465.            should be checked. If this bit is OFF, then the
  466.            command should be interpreted to mean "continue
  467.            whatever echoing strategy you have been following,
  468.            using the same break and transmission classes."          6b5f
  469.  
  470.  
  471.  
  472.                                                                 [page 8]
  473.  
  474.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  475.      Remote Controlled Transmission & Echoing Telnet Option
  476.  
  477.  
  478.  
  479.          2)  The user Telnet now checks the terminal input
  480.          buffer, if it contains data it is processed in step 4,
  481.          otherwise the user Telnet waits in step 3 for further
  482.          developments.                                               6b6
  483.  
  484.          3)  The user Telnet waits until either the human user
  485.          enters some data in which case Telnet proceeeds to step
  486.          4, or an item is received from the network. If the item
  487.          from the network is data it is spontaneous output and
  488.          is printed, Telnet then continues to wait. If the item
  489.          from the network is a command then an error has
  490.          occured. In this case the user Telnet may attempt to
  491.          resynchronize the use of RCTE as indicated below.           6b7
  492.  
  493.          4)  Items from the terminal are processed with printing
  494.          controlled by the settings of the latest break reset
  495.          command. When a break character is processed, the cycle
  496.          of control is complete and action re-commences at step
  497.          1.                                                          6b8
  498.  
  499.          Input from the terminal is (hopefully) buffered into
  500.          units ending with a transmission or break character;
  501.          and echoing of input text is suspended after the
  502.          occurrence of a break character and until receipt of a
  503.          break reset command from the serving host. The most
  504.          recent break reset command determines the break
  505.          actions.                                                    6b9
  506.  
  507.          In summary, what is required is that for every break
  508.          character sent in the user to server direction there be
  509.          a break reset command sent in the server to user
  510.          direction. The user host initially has no knowledge of
  511.          which characters are break characters and so starts in
  512.          a state that assumes that there are no break characters
  513.          and also that no echoing is to be provided. The server
  514.          host is expected to send a break reset command to
  515.          establish the break classes and the echoing mode before
  516.          it receives any data from the user.                        6b10
  517.  
  518.        Synchronization and Resynchronization:                         6c
  519.  
  520.          The serving and using hosts must carefully synchronize
  521.          break reset commands with the transmission of break
  522.          characters. Except at the beginning of an interaction,
  523.          the serving host may only send a break reset command in
  524.          response to the Using host's having sent a break
  525.          character as defined at that time. This should
  526.          establish a one-to-one correspondence between them.  (A
  527.          <cmd> value of zero, in this context, is interpreted as
  528.  
  529.  
  530.  
  531.                                                                 [page 9]
  532.  
  533.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  534.      Remote Controlled Transmission & Echoing Telnet Option
  535.  
  536.  
  537.  
  538.          a break classes reset to the same class(es) as before.)
  539.          The break reset command may be preceded by terminal
  540.          output.                                                     6c1
  541.  
  542.          The re-synchronization of the break characters and the
  543.          break reset commands is done via the exchange of the
  544.          Telnet signal Abort Output (AO) in the server to user
  545.          direction and the SYNCH in the user to server
  546.          direction.                                                  6c2
  547.  
  548.          Suppose the server wants to resynchronize the break
  549.          characters and the break reset commands.                    6c3
  550.  
  551.            a.  The server should be sure all output to the
  552.            terminal has been printed by using, for example, the
  553.            Timing Mark Option.                                      6c3a
  554.  
  555.            b.  The server sends the AO signal.                      6c3b
  556.  
  557.            c.  The user receives the AO signal. The user flushes
  558.            all user to server data wheather it has been echoed
  559.            or not. The user sends a SYNCH to the server. [The
  560.            SYNCH consists of the Telnet Data Mark (DM) and the
  561.            host-to-host interrupt (INS).] The user now enters
  562.            the initial state at step 1.                             6c3c
  563.  
  564.            d.  The server receives the SYNCH and flushes any
  565.            data preceeding the DM (as always). The server now
  566.            sends a break reset command. (Actually the break
  567.            reset command could be sent at any time following the
  568.            AO.)                                                     6c3d
  569.  
  570.          Suppose the user wants to resynchronize the break
  571.          characters and the break reset commands.                    6c4
  572.  
  573.            a.  The user should discard all user to server data
  574.            wheather it has been echoed or not.                      6c4a
  575.  
  576.            b.  The user sends the AO signal. The user now enters
  577.            the algorithm at step 1.                                 6c4b
  578.  
  579.            c.  The server receives the AO signal. The server
  580.            discards all data buffered but not yet sent to the
  581.            user. The server sends a SYNCH to the user. The
  582.            server sends a break reset command to the user.          6c4c
  583.  
  584.  
  585.  
  586.  
  587.  
  588.  
  589.  
  590.                                                                [page 10]
  591.  
  592.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  593.      Remote Controlled Transmission & Echoing Telnet Option
  594.  
  595.  
  596.  
  597.        Notes and Comments:                                            6d
  598.  
  599.          Even-numbered commands, greater than zero, are in
  600.          error, since they will have the low-order bit off. The
  601.          command should be interpreted as equal to zero, which
  602.          means that any classes reset bytes ([TC1 TC2] [BC1
  603.          BC2]) will be in error. (The IAC SE, at the end of the
  604.          command, eliminates any parsing problems due to this
  605.          error.)                                                     6d1
  606.  
  607.          Serving hosts will generally instruct using hosts not
  608.          to echo break characters, even though it might be
  609.          alright to echo most break characters. For example,
  610.          <cr> is usually a safe character to echo but <esc> is
  611.          not. TENEX Exec is willing to accept either, during
  612.          filename specification. Therefore, the using host must
  613.          be instructed not to echo any break characters.             6d2
  614.  
  615.            This is generally a tolerable problem, since the
  616.            serving host has to send an RCTE command at this
  617.            point, anyhow. Adding an echo for the break character
  618.            to the message will not cause any extra network
  619.            traffic.                                                 6d2a
  620.  
  621.          The RCTE Option entails a rather large overhead. In a
  622.          true character-at-a-time situation, this overhead is
  623.          not justified. But on the average, it should result in
  624.          significant savings, both in network traffic and host
  625.          wake-ups.                                                   6d3
  626.  
  627.          Buffering Problems and Transmission vs. Printing
  628.          Constraints:                                                6d4
  629.  
  630.            There are NO mandatory transmission constraints. The
  631.            using host is allowed to send a character a time,
  632.            though this would be a waste of RCTE. The
  633.            transmission classes commands are GUIDELINES, so
  634.            deviating from them, as when the user's buffer gets
  635.            full, is allowed.                                        6d4a
  636.  
  637.            Additionally, the using host may send a break class
  638.            character, without knowing that it is one (as with
  639.            type-ahead).                                             6d4b
  640.  
  641.              If the user implementation is clever it may send
  642.              the user entered data to the server before it is
  643.              actually needed. This type ahead data may contain
  644.              break characters.
  645.  
  646.  
  647.  
  648.  
  649.                                                                [page 11]
  650.  
  651.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  652.      Remote Controlled Transmission & Echoing Telnet Option
  653.  
  654.  
  655.  
  656.              Assume that only space is a break character (that
  657.              is the last break reset command specified print up
  658.              to and including the break characters and set the
  659.              break classes to class 9). Suppose the user had
  660.              typed "abc<space>def<esc>ghi<cr>". The user side
  661.              RCTE could send it all to the server, but it could
  662.              print only "abc<space>", and would have to buffer
  663.              "def<esc>ghi<cr>" at least until a break reset
  664.              command was received from the server. That break
  665.              reset command could change the break ckasses
  666.              requiring rescanning the buffered string.
  667.  
  668.              For example suppose the break reset command set the
  669.              break characters to class 5 and the action to print
  670.              up to but not including the break character. The
  671.              user RCTE could then print "def" and discard the
  672.              <esc>, but whould have to continue to buffer the
  673.              "ghi<cr>".
  674.  
  675.            The problem with buffering occurs when printing on
  676.            the user's terminal must be suspended, after the user
  677.            has typed a currently valid break character and until
  678.            a break reset command is received from the serving
  679.            host. During this time, the user may be typing
  680.            merrily along. The text being typed may be SENT, but
  681.            may not yet be PRINTED.                                  6d4c
  682.  
  683.            The more common problem of filling the transmission
  684.            buffer, while awaiting a host to host allocate from
  685.            the serving host, may also occur, but this problem is
  686.            well known to implementors and in no way special to
  687.            RCTE.                                                    6d4d
  688.  
  689.            In any case, when the buffer does fill and further
  690.            text typed by the user will be lost, the user should
  691.            be notified (perhaps by ringing the terminal bell).      6d4e
  692.  
  693.          Text should be buffered by the using host until the
  694.          user types a character which belongs to the
  695.          transmission class in force at the moment the character
  696.          is typed.                                                   6d5
  697.  
  698.          Transmission class reset commands may be sent by the
  699.          serving host at any time. If they are frequently sent
  700.          separate from break class reset commands, it will
  701.          probably be better to exit from RCTE and enter regular
  702.          character at a time transmission.                           6d6
  703.  
  704.          It is not immediately clear what the using host should
  705.  
  706.  
  707.  
  708.                                                                [page 12]
  709.  
  710.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  711.      Remote Controlled Transmission & Echoing Telnet Option
  712.  
  713.  
  714.  
  715.          do with currently buffered text, when a transmission
  716.          classes reset command is received. The buffering is
  717.          according to the previous transmission classes scheme.      6d7
  718.  
  719.            The using host clearly should not simply wait until a
  720.            transmission character (according to the new scheme)
  721.            is typed.                                                6d7a
  722.  
  723.            Either the buffered text should be rescanned, under
  724.            the new scheme;                                          6d7b
  725.  
  726.            Or the buffered text should simply be sent as a
  727.            group. This is the simpler approach, and probably
  728.            quite adequate.                                          6d7c
  729.  
  730.          It is possible to define NO BREAK CHARACTERS except
  731.          Telnet commands (IAC ...). This seems undesirable and
  732.          should not be done.                                         6d8
  733.  
  734.            If this situation were to occur the using host should
  735.            send a Telnet command to allow the server to know
  736.            when he may reset the break classes, but the
  737.            mechanism is awkward and this case should be avoided.    6d8a
  738.  
  739.      6.  Sample Interaction:                                           7
  740.  
  741.        "S:" is sent from serving (WILL RCTE) host to using host.
  742.        "U:" is sent from using (DO RCTE) host to serving host.
  743.        "T:" is entered by the terminal user.
  744.        "P:" is printed on the terminal.
  745.        
  746.        Text surrounded by square brackets ([]) is commentary.
  747.        Text surrounded by angle brackets (<>) is to be taken as
  748.        a single unit. E.g., carriage return is <cr>, and the
  749.        decimal value 27 is represented <27>.                          7a
  750.  
  751.        The following interaction shows a logon to a Tenex,
  752.        initiation of the DED editor, insertion of some text and
  753.        the return to the Exec level.                                  7b
  754.  
  755.          An attempt has been made to give some flavor of the
  756.          asynchrony of network I/O and the user's terminal
  757.          input. Many other possible combinations, using the same
  758.          set of actions listed below, could be devised. The
  759.          actual order of events will depend upon network and
  760.          hosts' load and the user's typing speed.                    7b1
  761.  
  762.        We assume that the user's Telnet is also in an "insert
  763.        linefeed" mode. That is, whenever the user types carriage
  764.  
  765.  
  766.  
  767.                                                                [page 13]
  768.  
  769.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  770.      Remote Controlled Transmission & Echoing Telnet Option
  771.  
  772.  
  773.  
  774.        return <cr> the user Telnet sends both carriage return
  775.        and linefeed <cr><lf> (the Telnet end of line signal).
  776.        When space character occurs at the end of a line in the
  777.        example description it is shown explicitly by <sp> to
  778.        avoid confusion. Other uses of the space character are
  779.        not so marked to avoid destroying the readability of the
  780.        example.                                                       7c
  781.  
  782.        A Telnet connection has already been opened, but the
  783.        TENEX prompt has not yet been issued. The hosts first
  784.        discuss using the RCTE option:                                 7d
  785.  
  786.          S: <IAC><WILL><RCTE>                                        7d1
  787.  
  788.          U: <IAC><DO><RCTE>                                          7d2
  789.  
  790.          S: TENEX 1.31.18, TENEX EXEC 1.50.2<cr><lf>@
  791.             <IAC><SB><RCTE><11><1><24><IAC><SE>                      7d3
  792.  
  793.            [Print the herald and echo input text up to a break
  794.            character, but do not echo the break character.
  795.            Classes 4 (Format Effectors), 5 (Non-format Effector
  796.            Controls and <DEL>), and 9 (<sp>) act as break
  797.            characters.]                                             7d3a
  798.  
  799.          P: TENEX 1.31.18, TENEX EXEC 1.50.2<cr><lf>@                7d4
  800.  
  801.          T: LOGIN ARPA<cr>                                           7d5
  802.  
  803.          P: LOGIN                                                    7d6
  804.  
  805.          U: LOGIN<sp>                                                7d7
  806.  
  807.          U: ARPA<cr><lf>                                             7d8
  808.  
  809.          S: <sp><IAC><SB><RCTE><0><IAC>SE>                           7d9
  810.  
  811.          P: <sp>ARPA                                                7d10
  812.  
  813.          S: <cr><lf>(PASSWORD): <IAC><SB><RCTE><7><IAC><SE>         7d11
  814.  
  815.          P: <cr><lf>(PASSWORD):<sp>                                 7d12
  816.  
  817.          T: WASHINGTON 1000<cr>                                     7d13
  818.  
  819.            [The password "WASHINGTON" is not echoed. Printing of
  820.            "1000<cr>" is withheld]                                 7d13a
  821.  
  822.          U: WASHINGTON<sp>                                          7d14
  823.  
  824.  
  825.  
  826.                                                                [page 14]
  827.  
  828.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  829.      Remote Controlled Transmission & Echoing Telnet Option
  830.  
  831.  
  832.  
  833.          U: 1000<cr><lf>                                            7d15
  834.  
  835.          S: <sp><IAC><SB><RCTE><3><IAC><SE>                         7d16
  836.  
  837.          S: <cr><lf>JOB 17 ON TTY41 7-JUN-73 14:13<cr><lf>@
  838.             <IAC><SB><RCTE><0><IAC><SE>                             7d17
  839.  
  840.          P: <sp>1000                                                7d18
  841.  
  842.            [Printing is slow at this point; so the account
  843.            number is not printed as soon as the server's command
  844.            for it is received.]                                    7d18a
  845.  
  846.          P: <cr><lf>JOB 17 ON TTY41 7-JUN-73 14:13<cr><lf>@         7d19
  847.  
  848.          T: DED<esc><cr>                                            7d20
  849.  
  850.          P: DED                                                     7d21
  851.  
  852.          U: DED<esc>                                                7d22
  853.  
  854.          S: .SAV;1<IAC><SB><RCTE><0><IAC><SE>                       7d23
  855.  
  856.          P: .SAV;1                                                  7d24
  857.  
  858.          U: <cr><lf>                                                7d25
  859.  
  860.          S: <cr><lf><lf>DED    3/14/73 DRO,KRK<cr><lf>:
  861.             <IAC><SB><RCTE><15><1><IAC><255><IAC><SE>               7d26
  862.  
  863.            [The program is started and the DED prompt ":" is
  864.            sent. At the command level, DED responds to every
  865.            character. The server sets the break classes to all
  866.            classes.]                                               7d26a
  867.  
  868.          P: <cr><lf><lf>DED    3/14/73 DRO,KRK<cr><lf>:             7d27
  869.  
  870.          T: IThis is a test line.<cr>This is another test
  871.             line.<^Z>Q                                              7d28
  872.  
  873.            ["I" means Insert Text. The text follows, terminated
  874.            by a Control-Z. The "Q" instructs DED to Quit.]         7d28a
  875.  
  876.          U: I                                                       7d29
  877.  
  878.          U: This is a test line.<cr><lf>                            7d30
  879.  
  880.          S: I<cr><lf>*<IAC><SB><RCTE><11><0><24><IAC><SE>           7d31
  881.  
  882.  
  883.  
  884.  
  885.                                                                [page 15]
  886.  
  887.      NWG/RFC# 726                          JBP DHC 8-MAR-77 08:29  39237
  888.      Remote Controlled Transmission & Echoing Telnet Option
  889.  
  890.  
  891.  
  892.            [DED prompts the user, during text input, with an
  893.            asterisk at the beginning of every line. The server
  894.            sets the break classes to classes 4 and 5, the format
  895.            effectors and the non-format effector controls.]        7d31a
  896.  
  897.          P: I<cr><lf>*This is a test line.                          7d32
  898.  
  899.          S: <cr><lf>*<IAC><SB><RCTE><0><IAC><SE>                    7d33
  900.  
  901.          P: <cr><lf>*This is another test line.                     7d34
  902.  
  903.          U: This is another test line.<^Z>                          7d35
  904.  
  905.          U: Q                                                       7d36
  906.  
  907.            [Note that the "Q" will not immediately be printed on
  908.            the terminal, since it must wait for authorization.]    7d36a
  909.  
  910.          S: ^Z<cr><lf>:<IAC><SB><RCTE><15><1><IAC><255><IAC><SE>    7d37
  911.  
  912.            [The returned "^Z" is two characters, not the ASCII
  913.            Control-Z or <sub>.]                                    7d37a
  914.  
  915.          S: Q<cr><lf>@<IAC><SB><RCTE><11><1><24><IAC><SE>           7d38
  916.  
  917.          P: Q<cr><lf>@                                              7d39
  918.  
  919.          And the user is returned to the Exec level.                7d40
  920.  
  921.  
  922.  
  923.  
  924.  
  925.  
  926.  
  927.  
  928.  
  929.  
  930.  
  931.  
  932.  
  933.  
  934.  
  935.  
  936.  
  937.  
  938.  
  939.  
  940.  
  941.  
  942.  
  943.  
  944.                                                                [page 16]