TCP/IP command. Server for the rexec routine, providing remote execution facilities with authentication based on usernames and passwords. rexecd is started by inetd and must have an entry in inetd’s configuration file, /etc/inetd.conf. When rexecd receives a service request, the following protocol is initiated:
The server reads characters from the socket up to a null byte. The resulting string is interpreted as an ASCII number, base 10.
If the number received in Step 1 is nonzero, it is interpreted as the port number of a secondary stream to be used for stderr. A second connection is then created to the specified port on the client’s machine.
A null-terminated username of at most 16 characters is retrieved on the initial socket.
A null-terminated, unencrypted password of at most 16 characters is retrieved on the initial socket.
A null-terminated command to be passed to a shell is retrieved on the initial socket. The length of the command is limited by the upper bound on the size of the system’s argument list.
rexecd then validates the user, as is done at login time. If the authentication was successful, rexecd changes to the user’s home directory and establishes the user and group protections of the user.
A null byte is returned on the connection associated with stderr, and the command line is passed to the normal login shell of the user. The shell inherits the network connections established by rexecd.
Name is longer ...