Due: 10/10/2001 - Class Time
Write two C programs; one which will function as a 'server' and a second which
will function as a 'client'. You may execute the server on any machine that
you choose. You need to run at least 3 copies of the client, one on the same
machine as the server, one on a different machine and the third copy where ever.
The server and the clients must each log enough of their activity to document
what transpired.
The sockets may be either STREAM or DATAGRAM
The server may fork() or thr_create() or use the select() mechanism to handle
the multiple connections.
The server may just echo back what the client sent with that connection's SOCKET
DESCRIPTOR(fd) attached to the end of the message
The server should automatically exit() after all connect()s have been closed.
The client should print the message returned by the server including the descriptor
attached to the original message
The clients should terminate their sessions 'politely' (close the socket) and
not just break the connection via exit.
Each client should send/receive at least 3 messages
Use the 'script' command to capture all necessary information for handin.
You will have at least 4 scripts which may be combined with 'cat' for printing
with 'a2ps'.