Higher Level Protocols
3.1 INTRODUCTION
It is envisioned that the TCP will be able to support higher level protocols efficiently. It should be easy to interface existing ARPANET protocols like TELNET and FTP to the TCP.
3.2 WELL KNOWN SOCKETS
At some point, a set of well known 24 bit port numbers must be picked. The type of service associated with the well known ports might include:
(a) Logger
(b) FTP (File transfer protocol)
(c) RJE (Remote job entry)
(d) Host status
(e) TTY Test
(f) HELP - descriptive, interactive system documentation
WE RESERVE WELL KNOWN SOCKET 0 (24 bits of 0) for global messages destined for a particular TCP but not related to any particular connection. We imagine that this socket would be used for unusual TCP synchronization (e.g. RESET ALL) or for testing purposes (e.g. sending letters to TRASHCAN or ECHO). This does not conflict with the usage that if a socket is 0, it is unspecified, since no user can SEND, CLOSE, or INTERRUPT on socket 0.
3.3 RECONNECTION PROTOCOL (RCP)
Port identifiers fall into two categories: permanent and transient. For example, a Logger process is generally assigned a port identifier that is fixed and well known. Transient processes will in general have ID's which are dynamically assigned.
In the distributed processing environment of the network, two processes that don't have well known port identifiers may often wish to communicate. This can be achieved with the help of a well known process using a reconnection protocol. Such a protocol is briefly outlined using the communication facilities provided by the TCP. It essentially provides a mechanism by which port identifiers are exchanged in order to establish a connection between a pair of sockets.
Such a protoco1 can be used to achieve the dynamic establishment of new connections in order to have multiple processes solving a problem cooperatively, or to provide a user process access to a server process via a logger, when the logger's end of the connection can not be invisibly passed to the server process.
A paper on this subject by R. Schantz [SCHA74] discusses some of the issues associated with reconnection, and some of the ideas contained therein went into the design of the protocol outlined below.
In the ARPANET, a protocol was implemented which would allow a process to connect to a well known socket, thus making an implicit request for service, and then be switched to another socket so that the well known socket could be freed for use by others. Since sockets in our TCP are permitted to have connections with more than one foreign socket, this facility may not be explicitly needed (i.e. connections <A,B> and <A,C> are distinguishable).
However. the well known socket may be in one network and the actual service socket(s) may be in another network (or at least in another TCP). Thus, the invisible switching of a connection from one port to another within a TCP may not be sufficient as an "Initial Connection Protocol". We imagine that a process wishes to use socket N1.T1.Q to access well known socket N2.T2.P. However, the process associated with socket N2.T2.P will actually start up a new process somewhere which will use N3.T3.S as its server socket. The N(i) and T(i) may be distinct or the same. The user will send to N2.T2.P the relevant user information such as user name, password, and account. The server will start up the server process and send to N1.T1.Q the actual service socket ldentif1er: N3.T3.S. The connection (N1.TI.Q,N2.T2.P) can then be closed, and the user can do a RECEIVE on (N1.T1.Q,N3.T3.S). The serving process can SEND on (N3.T3.S,N1.T1.Q). There are many variations on this scheme, some involving the user process doing a RECEIVE on a different socket (e.g. (N1.T1.X,U.U.U)) with the server doing SEND on (N3.T3.S,N1.T1.X). Without showing all the detail of synchronization of sequence numbers and the like, we can illustrate the exchange as shown below.
USER SERVER
1. RECEIVE(N2.T2.P,U.U.U)
1. SEND (N1.T1.Q,N2.T2.P)==>
<== 2. SEND(N2.T2.P,N1.T1.Q)
With "N3.T3.S" as data
2. RECEIVE(N1.T1.Q,N2.T2.P)
3. CLOSE(N1.T1.Q,N2.T2.P)==>
<:= 3. CLOSE(N2.T2.P,N1.T1.Q)
4. RECEIVE(N1.T1.Q,N3.T3.S)
<== 4. SEND(N3.T3.S,N1.T1.Q)
At this point, a connection is open between N1.T1.Q and N3.T3.S. A variation might be to have the user do an extra RECEIVE on (N1.T1.X,U.U.U) and have the data "N1.T1.X" be sent in the first user SEND. Then, the server can start up the real serving process and do a SEND on (N3.T3.S,N1.T1.X) without having to send the "N3.T3.S" data to the user. Or perhaps both server and receiver exchange this data, to assure security of the ultimate connection (i.e. some wild process might try to connect to N1.T1.X if it is merely RECEIVING on foreign socket U.U.U.).
We do not propose any specific reconnection protocol here, but leave this to further deliberation, since it is really a user level protocol issue.