TCP is a fundamental networking protocol. It's the most commonly used across the entrei Internet. It's going to be the most common protocol you work with - not directly, so to speak, but you'll be configuring firewalls and other work appliances to work with TCP related packets.
- Client/Server Model
The client/server model is a classic networking model. It involves some (remote) server listening for connections on a particular IP address and port. Clients then connect over the network to this IP and the particular port for that service.
The server is capable, in virtually all cases, of handling multiple inbound clients at the same time.
- The Handshake
The TCP "Three-Way Handshake" is fundamental to how TCP connections are established between the client and the server. All TCP connections go through this handshake.
- Port Numbers
TCP (and other networking protocols) use ports to identify particular processes or services. For example, a web server that talks HTTPS to connecting clients would listen on port
443. No other service or process can bind to that port on the same IP address. Port numbers have special ranges, with everything between
0 - 1023being privileged;
1024 - 49151being registered ports; and
49152 - 65535being dynamic ports.
TCP is a stateful protocol. A TCP connection is maintained and kept open until one of the sides of the connection (the client or the server) closes the connection. The stateful nature of a TCP connection means each packet sent contains information that affects future packets. Being stateful also means firewalls will keep track of the TCP connection and all future packets through for the same connection (provided it was authorised in the first place.)
- The Header
Every protocol has a "header" - a table like structure that defines what a single "instance" of that protocol looks like. TCP is no different:
Understanding the TCP header can help diagnose issues, but for now it's only important for you to know of its existence.
Now progress through to the self-assessment and check your understanding.