Protocols
standards/rules used to define how devices communicate. They govern the transmission of data.
Each protocol has its own method to determine:
Handshaking
the client requests access, the server grants it and the protocols are agreed
Packets
collections of data forming part of a message
Packet switching
As well, it improves the reliability of sending messages because if one route is busy, another can be found.
TCP/IP model
Application layer
Encodes the data being sent so that it will be understood by the recipient.
This means formatting data and adding an appropriate header according to a protocol being used, such as HTTP or FTP.
Transport layer
Splits the data into packets and adds packet information such as, packet number specifying that packet’s order and the total number of packets so they can be reassembled correctly.
Internet layer
Attaches the IP address of the sender so the recipient will know who sent it. It also attaches the address of the host that is sending the data and the destination IP address.
Link layer
Attaches the Media Access Control (MAC) addresses of the sender and the recipient, allowing the packet to be directed to a specific device on a local area network.
At the receiving end, these data packets are passed back up the protocol stack.
Protocols – application layer:
HTTP FTP/SFTP SMTP POP3 SNMP
Hyper Text Transfer Protocol - HTTP
File Transfer Protocol - FTP/SFTP
Simple Mail Transfer Protocol – SMTP
Post Office Protocol - POP3
Simple Network Management Protocol – SNMP
Protocols – transport layer:
TCP
UDP
Transmission Control Protocol – TCP
TCP Process
How does TCP ensure packets reach their destination?
by numbering them, messages are sent confirming the delivery, if these confirmation messages don’t reach the sender, the packets are resent to ensure delivery
How is TCP reliable?
because packets are checked for errors, packets are tracked so data is not lost or corrupted in transit
User Datagram Protocol – UDP
What happens if UDP packets aren’t received?
the recipient can’t request the missing packets, no guarantee that all packets have been received. Means that computers communicate at a faster speed.
When is UDP best used?
when communication needs to take place quickly