home *** CD-ROM | disk | FTP | other *** search
/ The Hacker's Encyclopedia 1998 / hackers_encyclopedia.iso / rfc / 1 / rfc0098.txt < prev    next >
Encoding:
Text File  |  2003-06-11  |  24.0 KB  |  564 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7. Network Working Group
  8. Request for Comments #98
  9. Network Information Center #5744
  10.  
  11.                         Logger Protocol Proposal
  12.  
  13.                           Edwin W. Meyer, Jr.
  14.                            Thomas P. Skinner
  15.                            February 11, 1971
  16.  
  17.  
  18.         With the ARPA Network Host-to-Host  Protocol  specified  and  at
  19. least  partially  implemented at a number of sites, the question of what
  20. steps should be taken next arises. There  appears  to  be  a  widespread
  21. feeling  among  Network  participants  that the first step should be the
  22. specification and implementation of what has  been  called  the  "Logger
  23. Protocol";  the  Computer  Network Group at project MAC agrees. The term
  24. "logger" has been commonly used to indicate the basic mechanism to  gain
  25. access  (to  "login")  to  a  system from a console. A network logger is
  26. intended to specify how the existing logger of  a  network  host  is  to
  27. interface to the network so as to permit a login from a console attached
  28. to another host.
  29.  
  30.         To  implement  network  login   capability   now   seems   quite
  31. desirable.In  the first place, it is natural for Network participants to
  32. wish to learn more about the remote systems  in  the  immediate  fashion
  33. afforded  by  direct  use  of  those  systems.  In the second place, the
  34. technical problems introduced by remote logins are probably less complex
  35. than  those  involved  with  such  further  tasks  as  generalized  file
  36. transfer; thus,  a  Logger  Protocol  could  be  implemented  relatively
  37. quickly,  furnishing  additional  impetus  and  encouragement for taking
  38. still further steps.
  39.  
  40.         In order to furnish at least a basis for discussion (and at most
  41. an  initial  version  of  a  Logger  Protocol),  we  have  prepared this
  42. document, which attempts to present a  minimal  set  of  conditions  for
  43. basing  a  Logger  Protocol. This proposal covers only the mechanism for
  44. accomplishing login. What occurs following login is not discussed  here,
  45. because  we  feel  more experimentation is necessary before any protocol
  46. for general console communication can be established as standard. In its
  47. absence,  each  site  should  specify its own experimental standards for
  48. console communications following login.
  49.  
  50.  
  51.         Some of the points raised in this document have already  reached
  52. a  certain  level of consensus among network participants while at least
  53. one point is rather new. It should be clearly understood, however,  that
  54. we  feel  regardless  of  the disposal of particular issues, Networkwide
  55.  
  56.  
  57.  
  58.                                                                 [Page 1]
  59.  
  60. RFC 98                  Logger Protcol Proposal                 Feb 1971
  61.  
  62.  
  63. agreement should  be  reached  as  soon  as  possible  on  some  general
  64. protocol.  This is all the more desirable in view of the fact that it is
  65. quite likely that  certain  points  which  should  be  covered  in  this
  66. protocol  will only become apparent during the course of implementation;
  67. therefore, the sooner a common basis for implementation can be  reached,
  68. the sooner a more rigorous protocol can be enunciated.
  69.  
  70.         Before turning to 1) a discussion of the points  with  which  to
  71. decide  the  protocol should deal, and 2) specifications for the current
  72. state  of  the  protocolm  we  feel  that  we  should  acknowledge   the
  73. consideration  that  a  case could be made for avoidingthe difficulty of
  74. generating a Logger Protocol by simply  declaring  that  each  host  may
  75. specify  its  own, perhaps unique, preferences for being approached over
  76. the Network. Although such a course is certainly possible, it  does  not
  77. seem  to  us  to  be desirable. One reason for avoiding such a course is
  78. simply that following  it  hamper  general  Network  progress,  in  that
  79. adressing  the task of interfacing with some 20 systems is bound to more
  80. time-consuming than to interface with "one"  system,  even  though  each
  81. indivudual one of the former, multiple interfaces might be in some sense
  82. simpler than the latter, single interface. Another consideration is less
  83. pragmatic,  but  nonetheless  important:  agreement on a common protocol
  84. would tend to foster a sense of Network "community", which would tend to
  85. be  fragmented  by  the  local option route. After all, the Host-to-Host
  86. Protocol could have been handled on a per-host basis as well; assumedly,
  87. one  reason  why it has not had something to do with similar, admittedly
  88. abstract considerations.
  89.  
  90. Context
  91.  
  92.    Structurally, the mechanism serving to login a user over the  Network
  93. consists  of  two  parts,  one  part at the using host, the other at the
  94. serving host. The using or local host is the  one  to  which  the  users
  95. typewriter is directly connected; it contains a modulewhich channels and
  96. transforms  communications  between  the  Network  connection  and   the
  97. typewriter. The serving or foreign host provides the service to be used;
  98. it contains programming that adapts the logger and command system to use
  99. through the Network rather than a local typewriter.
  100.  
  101.       There are three different phases to a login through the network.
  102.  
  103.       1. During the connection phase the users console is connected to
  104.          the serving logger through the network. This is, of course,
  105.          the most important phase from the protocol viewpoint.
  106.  
  107.       2. The second or dialog phase consists of a sequence of exchange
  108.          between the user and the logger that serves to identify the
  109.          user and verify his right to use the system. In some hosts,
  110.          this phase may be minimal or non-existent.
  111.  
  112.  
  113.  
  114.                                                                 [Page 2]
  115.  
  116. RFC 98                  Logger Protcol Proposal                 Feb 1971
  117.  
  118.  
  119.       3. The admission phase occurs after the user has successfully
  120.          completed the login dialog. It consists of switching his
  121.          network typewriter connections from the logger to an entity
  122.          providing a command processor of some sort. In some hosts
  123.          this switching may be totally conceptual; in others there
  124.          may be a real internal switching between entities.
  125.  
  126.  
  127. The Connection Phase
  128.  
  129.         The issues involved in specifying a  protocol  for  implementing
  130. login  can  be  separatedintop  two  major  parts:  how to establish and
  131. maintain the network connection between the typewriter and  the  logger,
  132. and how to conduct a dialog after the connection is made. The first part
  133. is called the Initial Connection Protocol by Harlem and Heafner  in  RFC
  134. 80.  It  in turn consists of two subparts: how to establish a connection
  135. and how and when to destroy it.
  136.  
  137.         We endorse the proposal for establishing a  connection  made  in
  138. RFC  80,  which  we  summarize briefly for convenience. It is a two-step
  139. process utilizing the  NCP  control  messages  to  effect  a  connection
  140. between  the logger and the console of a potential user. First, the user
  141. causes the hosts NCP to send out  a  "request  for  connection"  control
  142. message  destined  for the serving hosts loggers contact socket. The two
  143. purposes of this message are to indicate to the logger  that  this  user
  144. wishes  to initiate a login dialog and to communicate the identifiers of
  145. the and send socket he wishes to operate for this  purpose.  The  logger
  146. rejects  this request to free its contact socket. As the second step the
  147. logger choses  two  sockets  to  connect  to  the  user's  sockets,  and
  148. dispatches  connection  requests  for  these.  If  the  user accepts the
  149. connection within a reasonable period, the connection phase is over, and
  150. the  dialog  phase can begin. If the user does not respond, the requests
  151. are aborted and the logger abandons this login attempt.
  152.  
  153.         There is another part to an NCP: when  and  how  to  disconnect.
  154. There  are  two  basic  situations  when a logger should disconnect. The
  155. first situation may arise of the serving host's volition. The logger may
  156. decide  to abandon a login attempt or a logged-in user may decide to log
  157. out. The second situation may be due to the  using  host's  volition  or
  158. network  difficulties.  This  situation  occurs  when  the  serving host
  159. receives a "close connection" control message  or  one  of  the  network
  160. error  messages signifying that further transmission is impossible. This
  161. may  happen  for  either  the  "read"   or   the   "write"   connection,
  162. Disconnecting  involves both the deletion of the network connections and
  163. the stoppage of any activity at the serving host related to  that  user.
  164. If  the  login  is  in  progress, it should be abandoned. If the user is
  165. already logged in, his process should be stopped, since he no longer has
  166. control over what it is doing. This is not intended to restrict absentee
  167.  
  168.  
  169.  
  170.                                                                 [Page 3]
  171.  
  172. RFC 98                  Logger Protcol Proposal                 Feb 1971
  173.  
  174.  
  175. (i.e. consoleless) jobs.
  176.  
  177. The Dialog Phase
  178.  
  179.         The second major part other than getting  connected  is  how  to
  180. conduct  the  login dialog. This resolves itself into two parts: what to
  181. say and in what form to say it. The login dialog generally consist of  a
  182. sequence  of  exchanges,  a  prompting  by the logger followed by a user
  183. reply specifying a name, a project, or password. However,  exactly  what
  184. information  is  desired in what sequence is idiosyncratic to each host.
  185. Rather than attempt to specify a standard sequence for this  dialog,  we
  186. have  taken the approach that each host may specify its own sequence, so
  187. long as it is  expressible  as  an  exchange  of  messages  in  a  basic
  188. transmission  format.  A  message is a set of information transmitted by
  189. one of the parties that is sufficient for the other  party  to  reply.By
  190. host  specification, either the logger or the user sends sends the first
  191. message of the dialog. After that, messages are  exchanged  sequentially
  192. until the dialog is completed. In this context "message" has no relation
  193. to "IMP message".
  194.  
  195.         The other issue involved in the login dialog is the  format  for
  196. transmitting  a message. We propose that it be transmitted as a sequence
  197. of ASCII characters (see Specificarions) in groupings calle  transaction
  198. blocks.
  199.  
  200.    1. Character Set, We feel that there should be a standard
  201.       character set for logging-in. The alternative, requiring a
  202.       using host to maintain different transformation between its set
  203.       and of each serving host, is a burden that can only narrow the
  204.       scope of interhost usage, The character set proposed, ASCII is
  205.       widely used standard. Each host must define a transformation
  206.       sufficient to transform an arbitrary character sequence in the
  207.       host's code into ASCII and back again, without any ambiguity,
  208.       The definition of ASCII sequences to express characters not
  209.       contained in ASCII is appropriate.
  210.  
  211.    2. Transaction Blocks. A message is transmitted as an arbitrary
  212.       integral number of transaction blocks. A transaction block
  213.       consists basically of a string of ASCII characters preceeded
  214.       by a character count. (It also contains a code field. See
  215.       below.) The count is included as an aid to efficiently
  216.       assembling a message. Some systems do not scan each character
  217.       as it is input from the console. Rather, such systems have
  218.       hardware IO controllers that place input characters into a
  219.       main memory buffer and interrupt the central processor only
  220.       when it receives an "action" character (such as "newline").
  221.       This reduces the load on the central processor. Because such
  222.       a hardware facility is not available for interpreting
  223.  
  224.  
  225.  
  226.                                                                 [Page 4]
  227.  
  228. RFC 98                  Logger Protcol Proposal                 Feb 1971
  229.  
  230.  
  231.       network messages this scheme is proposed as a substitute. It
  232.       helps in two ways. First, a system need take no action until
  233.       it receives all characters specified in the count. Second, it
  234.       need not scan each character to find the end of the message.
  235.       The message ends at the end of the of a transaction block.
  236.  
  237. Other Issues
  238.  
  239.         There are several other issues involved in the  area  of  remote
  240. logins   which  we  feel  should  be  raised,  although  most  need  not
  241. necessarily have firm agreements reached for an intial protocal.
  242.  
  243. 1.  "Echoplex". Echoplex is a mode of typewriter operation in which
  244.     all typed material is directed by the computer. A key struck by
  245.     a user does not print directly. Rather the code is sent to the
  246.     computer, which "echoes" it back to be printed on the typewriter.
  247.     To reduce complexity, there is to be no option for network
  248.     echoplexing (for the login only). A using system having its
  249.     typewriters operating in echoplex mode must generate a local
  250.     echo to its typewriters. However, a serving system operating
  251.     echoplexed should suppress the echo of the input during the login
  252.     phase.
  253.  
  254. 2.  Correction of Mistakes. During the login dialog the user may make
  255.     a typing mistake. There is no mistake correction ecplicitly
  256.     proposed here. If the message in error has not yet been
  257.     transmitted, the user can utilize the input editing conventions
  258.     of either the using or the serving host. In the first case, the
  259.     message is corrected before transmission; in the second, it is
  260.     corrected at the serving host. If the user has made an
  261.     uncorrectlable mistake, he should abort the login and try again.
  262.     To abort, he instructs the local (using) host to "close" one of
  263.     the connections. The connections are disconnected as specified in
  264.     the Initial Connection Protocol.
  265.  
  266. 3.  "Waiting". It may happen that the user may get into a login dialog
  267.     but for some reason does not complete it. The logger is left
  268.     waiting for a response by the user. The logger should not wait
  269.     indefinitely but after a reasonable interval (perhaps a minute)
  270.     abort the login and "close" the connections according to the
  271.     provisions of the Initial Connection Protocol.
  272.  
  273. 4.  Socket Assignments. The Initial Connection Protocol does not
  274.     specify the ownership of the sockets to be used by the logger in
  275.     connecting to the user. (The use code field of the socket
  276.     identifier determines ownership.) The sockets may belong to the
  277.     logger or may have an arbitraryuser code not used by another
  278.     process currently existing at the serving host. Under this initial
  279.  
  280.  
  281.  
  282.                                                                 [Page 5]
  283.  
  284. RFC 98                  Logger Protcol Proposal                 Feb 1971
  285.  
  286.  
  287.     scheme, it is not possible to implement administratively assigned
  288.     user codes, because the logger must assign permanent sockets
  289.     before the identity of the user is verified. A future connection
  290.     protocol can avoid this problem by implementing a socket
  291.     connection as a part of the admission phase. The logger would talk
  292.     to the user over the logger's sockets. Following identification it
  293.     would transfer the connections to the sockets belonging to the
  294.     user.
  295.  
  296. 5.  General Console Communications. A companion paper under
  297.     preparation outlines a protocol for general console communcations
  298.     between hosts. This paper will seek to adress most of the
  299.     problems associated with typewriter like communications. This
  300.     includes discussion of full and half duplex, character escapes,
  301.     action characters and other pertinent topics. Such a protocol
  302.     might not be suitable for all terminals and host systems but
  303.     would include solutions to problems for many. It is not
  304.     intended as a monolithic standard, but rather as a recommendation
  305.     for those sites who wish to implement a common protocol. The
  306.     important point is that we feel quite a bit of actual network
  307.     usage is required before all the problems are better understood.
  308.     This is a prerequisite for devising a standard.
  309.  
  310.  
  311.                              SPECIFICATIONS
  312.  
  313. Initial Connection Protocol - Connection Phase
  314.  
  315.       The following sequence is as presented in RFC 80. It  is  restated
  316.       here for completeness.
  317.  
  318. 1.  To intiate contact , the using process requests a connection of
  319.     his receive socket (US) to a socket (SERV) in the serving host.
  320.     By convention, this socket has the 24-bit user number field set
  321.     to zero. The 8-bit tag or AEN field is set to one indicating
  322.     the socket gender to be that of a sending socket. There is no
  323.     restriction on the choice of the socket US other than it be of
  324.     of the proper gender; in this case a receive socket. As a result
  325.     the using NCP sends:
  326.  
  327.                             User -> Server
  328.  
  329.                    8        32          32         8
  330.                 +-----+------------+------------+-----+
  331.                 | RTS |     US     |   SERV     |  P  |
  332.                 +-----+------------+------------+-----+
  333.  
  334.  
  335.  
  336.  
  337.  
  338.                                                                 [Page 6]
  339.  
  340. RFC 98                  Logger Protcol Proposal                 Feb 1971
  341.  
  342.  
  343.     over the control link one, where P is the receive link assigned
  344.     by the user's NCP.
  345.  
  346. 2.  The serving host now has the option of accepting the request for
  347.     connection or closing the the connection.
  348.  
  349.     a.  If he sends a close it is understood by the user that the
  350.         foreign host is unable to satisfy a request for service at
  351.         this time. The serving host's NCP would send:
  352.  
  353.                           Server -> User
  354.  
  355.                    8        32          32
  356.                 +-----+-----------+------------+
  357.                 | CLS |    SERV   |     US     |
  358.                 +-----+-----------+------------+
  359.  
  360.         with the user's NCP sending the echoing close:
  361.  
  362.                           User -> Server
  363.  
  364.                    8        32          32
  365.                 +-----+-----------+------------+
  366.                 | CLS |     US    |    SERV    |
  367.                 +-----+-----------+------------+
  368.  
  369.     b.  If the serving host is willing to provide service it will
  370.         accept the connection and immediately close the connection.
  371.         This results in the the serving host's NCP sending:
  372.  
  373.                           Server -> User
  374.  
  375.                    8        32          32
  376.                 +-----+-----------+------------+
  377.                 | STR |    SERV   |     US     |
  378.                 +-----+-----------+------------+
  379.  
  380.                    8        32          32
  381.                 +-----+-----------+------------+
  382.                 | CLS |    SERV   |     US     |
  383.                 +-----+-----------+------------+
  384.  
  385.  
  386.  
  387.  
  388.  
  389.  
  390.  
  391.  
  392.  
  393.  
  394.                                                                 [Page 7]
  395.  
  396. RFC 98                  Logger Protcol Proposal                 Feb 1971
  397.  
  398.  
  399.         with the user's NCP sending the echoing close. It sends:
  400.  
  401.                           User -> Server
  402.  
  403.                    8        32          32
  404.                 +-----+-----------+------------+
  405.                 | CLS |     US    |    SERV    |
  406.                 +-----+-----------+------------+
  407.  
  408.         It should be mentioned that the echoing closes are required
  409.         by the host-to-host protocol and not by the logger initial
  410.         connection protocol.
  411.  
  412. Character Set
  413.  
  414.         The character  set  used  in  conducting  the  login  dialog  is
  415. standard  ASCII  as  documented  in "American National Standard Code for
  416. Information Interchange", ANS X3,  4-1968,  American  National  Standard
  417. Institute, October, 1968. A logger at a serving host may demand any kind
  418. of input that can be  expressed  as  a  string  of  one  or  more  ASCII
  419. characters. It similarly, it may output any such string.
  420.  
  421.         All ASCII characters  are  legal,  including  the  graphics  and
  422. control  characters.  However, it is proposed that the only standard way
  423. of indicating the end of a console  line  be  the  line  feed  character
  424. (012).  This  is  in  accordance with an anticipated change to the ASCII
  425. standard.
  426.  
  427.        Currently the ASCII standard permits  two  methods  of  ending  a
  428. line.  One  method  defines  a  single  character,  line  feed (012), as
  429. incorporating the combined functions of line space and  carriage  return
  430. to  the  lefthand  margin.  The  second  method, implicitly permitted by
  431. ASCII, uses the two character sequence  line  feed  (012)  and  carriage
  432. return (015) to perform the same function.
  433.  
  434.         There is a proposal  that  the  ASCII  standard  be  changed  to
  435. include  a  return  to  the  left-hand  margin  in  all  vertical motion
  436. characters of at least one full space (line feed, vertical tab  and  new
  437. page). This will disallow the dual character sequence to end a line.
  438.  
  439.         It is suggested that a character in a hostst character  set  not
  440. having  any  ASCII  equivalnet be represented by the ASCII two character
  441. sequence ESC (033) and one of the ASCII  characters.  Each  host  should
  442. publish a list of the escape sequence it has defined.
  443.  
  444.  
  445.  
  446.  
  447.  
  448.  
  449.  
  450.                                                                 [Page 8]
  451.  
  452. RFC 98                  Logger Protcol Proposal                 Feb 1971
  453.  
  454.  
  455. Transaction Block Format
  456.  
  457.         All textual messages exchanged between user and  logger  are  to
  458. consist of one or more "transaction blocks". Each transaction block is a
  459. sequence of 8-bit elements in the following format:
  460.  
  461.                 <code> <count> <char1> ... <charn>
  462.  
  463. <code>     is an 8-bit element that is not interpreted in this
  464.            protocol. In the proposed general console communications
  465.            protocol, this field specifies communication modes or
  466.            special characteristics of this transaction block. Here
  467.            <code> is to be zero.
  468.  
  469. <count>    is an 8-bit element that specifies the number of character
  470.            elements that follow in this transaction block. It is
  471.            interpreted as a binary integer which has a permissible
  472.            range between 0 and 127. The most significant bit is zero.
  473.  
  474. <chari>    is an 8-bit element containing a standard 7-bit ASCII
  475.            character right-adjusted. The most significant bit is
  476.            zero. The number of <chari> in the transaction block is
  477.            governed by the <count> field. A maximum of 127 and
  478.            minimum of zero characters are permitted in a single
  479.            transaction block.
  480.  
  481.         The most significant bit of each  of  these  elements  is  zero,
  482. effectively   limiting   each   of  these  elements  to  seven  bits  of
  483. significance. The reason for doing this is twofold: the  eighth  bit  of
  484. the  <chari> elements is specifically reserved for future expansion, and
  485. it was desired to limit  all  the  elements  so  as  to  permit  certain
  486. implementations  to  convert  the incoming stream from 8-bit elements to
  487. 7-bit elements prior to decoding.
  488.  
  489.         With one exception, there  is  to  be  no  semantic  connotation
  490. attached  with  the  division  of a logger-user message into one or more
  491. transaction blocks. The character string comprising the  message  to  be
  492. transmitted  may  be  divided and apportioned among multiple transaction
  493. blocks according to the whim of the  sending  host.  If  less  than  128
  494. characters  in  length,  the message may be sent as a single transaction
  495. block. The exception is that separate messages may  not  appear  in  the
  496. same  transaction  block. That is, a message must start at the beginning
  497. of a transaction block and finish at the end  of  one.  Note  also  that
  498. there  is  no syntactic device for specifying the last transaction block
  499. of a message. It  is  presumed  that  the  logger  end  user  both  have
  500. sufficient  knowledge  of  the  format to know when all of a message has
  501. arrived
  502.  
  503.  
  504.  
  505.  
  506.                                                                 [Page 9]
  507.  
  508. RFC 98                  Logger Protcol Proposal                 Feb 1971
  509.  
  510.  
  511.         Note that the first 8-bits of data transmitted through  a  newly
  512. established  connection  must  be  a  type code as specified in Protocol
  513. Document 1. This type code must be sent prior to the  first  transaction
  514. block and should be discarded by the receiving host.
  515.  
  516.  
  517. Acknowledgments
  518.  
  519.         Robert Bressler,  Allen  Brown,  Robert  Metcalfe,  and  Michael
  520. Padlipsky  contributed  directly  to  the  establishment  of  the  ideas
  521. presented  here.  Thanks  are  due  Michael  Padlipsky  and  others  for
  522. editorial comments.
  523.  
  524.  
  525.        [ This RFC was put into machine readable form for entry ]
  526.           [ into the online RFC archives by Carl Moberg 1/98 ]
  527.  
  528.  
  529.  
  530.  
  531.  
  532.  
  533.  
  534.  
  535.  
  536.  
  537.  
  538.  
  539.  
  540.  
  541.  
  542.  
  543.  
  544.  
  545.  
  546.  
  547.  
  548.  
  549.  
  550.  
  551.  
  552.  
  553.  
  554.  
  555.  
  556.  
  557.  
  558.  
  559.  
  560.  
  561.  
  562.                                                                [Page 10]
  563.  
  564.