ELEC-E7321
daytime-cli.c: Shows basic operation of opening a socket and reading some data from it. Modified from W.R. Stevens’ Unix Network Programming book.
daytime-serv.c: Demonstrates a simple server socket, a counterpart of daytime-cli.c, that accepts a TCP connection and writes the current date and time to the accepted socket. Modified from W.R. Stevens’ Unix Network Programming book.
simple-client.c: Demonstrates socket connection and name resolution, then writes and reads something from the socket. Modified from W.R. Stevens’ Unix Network Programming book.
simple-client: Opens connection, then writes and reads a bit of data. Should be equivalent behavior to simple-client.c above.
tcpheader: Example of converting a struct consisting TCP header fields into byte stream that can be written to a socket, and conversely, filling the struct from data read from byte stream. Demonstrates structure packing and byte order conversions.
send-much: Contains both simple server and client implementation: server accepts connections, then waits for user input and reads all data someone sends to the socket, until the socket is closed. Client just sends the requested number of bytes. Used to demonstrate the effect of socket buffering on socket API behavior.
simple-server: Accepts a connection, then reads data from socket and writes some data back, then closes the connection. Handles only one connection at a time in a loop. Can be tested together with simple-client.
iterative-server: Accepts incoming connections, then waits for incoming data and echoes it back in all active connections. Keeps connections open until other end closes them. Can handle multiple connections in parallel. Demonstrates non-blocking sockets in an iterative single-threaded server using Rust’s mio crate.
threaded-server: Similar to iterative-server, but spawns a new thread for each active client.
async-server: Similar to threaded-server but applies collaborative multitasking using Rust’s tokio crate.