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

  1.  
  2.  
  3.  
  4.  
  5.  
  6. Request for Comments:  652                   D. Crocker (UCLA-NMC)
  7.                                                         25 Oct. 74
  8. NIC #31155
  9. Online file:  [ISI]<DCROCKER>NAOCRD.TXT
  10.  
  11.  
  12.  
  13.  
  14.       Telnet Output Carriage-Return Disposition Option
  15.  
  16.  
  17.  
  18. 1.  Command name and code
  19.  
  20.     NAOCRD     10   (Negotiate About Output Carriage-Return Disposition)
  21.  
  22. 2.  Command meanings
  23.  
  24.         In the following, we are discussing  a  simplex  connection,  as
  25.     described in the NAOL and NAOP Telnet options.
  26.  
  27.     IAC DO NAOCRD        The data sender requests or agrees to negotiate
  28.                          about    output    carriage-return    character
  29.                          disposition with the  data  receiver.   In  the
  30.                          case  where  agreement  has been reached and in
  31.                          the absence  of  further  subnegotiations,  the
  32.                          data  receiver is assumed to be handling output
  33.                          carriage-returns.
  34.  
  35.     IAC DON'T NAOCRD     The data  sender  refuses  to  negotiate  about
  36.                          output  carriage-return  disposition  with  the
  37.                          data receiver,  or  demands  a  return  to  the
  38.                          unnegotiated default mode.
  39.  
  40.     IAC WILL NAOCRD      The  data  receiver  requests  or   agrees   to
  41.                          negotiate    about    output    carriage-return
  42.                          disposition with the sender.  In the case where
  43.                          agreement  has  been reached and in the absence
  44.                          of further subnegotiations, the  data  receiver
  45.                          alone   is   assumed   to  be  handling  output
  46.                          carriage-returns.
  47.  
  48.     IAC WON'T NAOCRD     The data receiver refuses  to  negotiate  about
  49.                          output  carriage-return disposition, or demands
  50.                          a return to the unnegotiated default mode.
  51.  
  52.     IAC SB NAOCRD DS <8-bit value> IAC SE
  53.                          The  data  sender  specifies,  with  the  8-bit
  54.                          value,     which     party     should    handle
  55.                          carriage-returns  and  what  their  disposition
  56.                          should be.  The code for DS is 1.
  57.  
  58. Telnet NAOCRD Option                                Page   2
  59.  
  60.  
  61.  
  62.     IAC SB NAOCRD DR <8-bit value> IAC SE        The    data    receiver
  63.                          specifies,  with  the  8-bit value, which party
  64.                          should handle carriage-returns and  what  their
  65.                          disposition should be.  The code for DR is 0.
  66.  
  67.  
  68.  
  69. 3.  Default
  70.  
  71.  
  72.         DON'T NAOCRD/WON'T NAOCRD.    In   the   default   absence    of
  73.     negotiations  concerning  which party, data sender or data receiver,
  74.     is handling output carriage-returns, neither party  is  required  to
  75.     handle   carriage-returns  and  neither  party  is  prohibited  from
  76.     handling them; but it is appropriate if at least the  data  receiver
  77.     handles carriage-returns, albeit primitively.
  78.  
  79.  
  80. 4.  Motivation for the Option
  81.  
  82.         Please refer to section 4 of the NAOL and  of  the  NAOP  Telnet
  83.     option descriptions.
  84.  
  85.  
  86. 5.  Description of the Option
  87.  
  88.         The data sender and the data receiver use the 8-bit value  along
  89.     with the NAOCRD SB commands as follows:
  90.  
  91.     8-bit value          Meaning
  92.  
  93.     0                    Command sender  suggests  that  he  alone  will
  94.                          handle carriage-returns, for the connection. 
  95.  
  96.     1 to 250             Command sender suggests that  the  other  party
  97.                          alone   should   handle  carriage-returns,  but
  98.                          suggests that a delay of the indicated value be
  99.                          used.     The    value   is   the   number   of
  100.                          character-times to wait or number  of  NULs  to
  101.                          insert  in  the  data stream before sending the
  102.                          next  data  character.    (See   qualification,
  103.                          below.) 
  104.  
  105.     251                  Not allowed, in order  to  be  compatible  with
  106.                          related Telnet options.
  107.  
  108.     252                  Command sender suggests that  the  other  party
  109.                          alone  handle  carriage-returns,  but  suggests
  110.                          that they be discarded.
  111.  
  112.     253                  Not allowed, in order  to  be  compatible  with
  113.                          related Telnet options. 
  114.  
  115. Telnet NAOCRD Option                                Page   3
  116.  
  117.  
  118.  
  119.     254                  Command sender suggests that  the  other  party
  120.                          alone   should   handle   carriage-returns  but
  121.                          suggests  waiting  for  a   character   to   be
  122.                          transmitted  (on  the other simplex connection)
  123.                          before sending more data.  (See  qualification,
  124.                          below.)   Note  that, due to the assynchrony of
  125.                          the two simplex connections, phase problems can
  126.                          occur with this option. 
  127.  
  128.     255                  Command sender suggests that  the  other  party
  129.                          alone   should   handle   carriage-returns  and
  130.                          suggests nothing about how it should be done.
  131.  
  132.     The guiding rules are that:
  133.  
  134.         (1) if neither data receiver nor data  sender  wants  to  handle
  135.         carriage-returns, the data receiver must do it, and
  136.  
  137.         (2) if both  data  receiver  and  data  sender  want  to  handle
  138.         carriage-returns, the data sender gets to do it.
  139.  
  140.         The reasoning for the former rule is that if neither wants to do
  141.     it,  then  the default in the NAOCRD option dominates.  If both want
  142.     to do it, the sender, who is  presumed  to  have  special  knowledge
  143.     about  the data, should be allowed to do it, taking into account any
  144.     suggestions the receiver may make.
  145.  
  146.         Note that carriage-return delays, controlled by the data sender,
  147.     must  consist  of  NUL  characters  inserted  immediately  after the
  148.     character in question.  This is necessary due to the assynchrony  of
  149.     network  transmissions.   Due  to the Telnet end-of-line convention,
  150.     with carriage-returns followed by a linefeed, any  NULs  that  would
  151.     otherwise  be  placed after the carriage-return must be placed after
  152.     the linefeed, regardless of any modifications that may  additionally
  153.     be made to the line feed (see NAOLFD Telnet option). 
  154.  
  155.         As with all option negotiations, neither party should suggest  a
  156.     state  already  in  effect  except  to  refuse to negotiate; changes
  157.     should be acknowledged; and once refused, an option  should  not  be
  158.     resuggested   until   "something  changes"  (e.g.,  another  process
  159.     starts).
  160.  
  161.         At any time, either party can  disable  further  negotiation  by
  162.     giving the appropriate WON'T NAOCRD or DON'T NAOCRD command.