Chapter 14

    Cards (69)

    • why is there a need for protocols?
      When communicating over networks, it is essential that some form ofprotocolis used by the sender and receiver of the data. Both parties need to agreethe protocol being used to ensure successful communication takes place. In Chapter 6, we discussed parity checking as a way of determining whetherdata was transmitted correctly. With this method, it was essential to agree the protocol: even or odd parity. Without agreeing this protocol, it would be impossible to use parity checking. Many different protocols exist since there are several activities taking place over the internet.
    • This is the four-layer structure for TCP/IP protocols:
      Using layers breaks the process down into manageable self-contained modules (this process is known asdecomposition), making it easier to develop and easier to make software and hardware compatible.When sending data across the internet (network), the layers are used in the order layer 4 to layer 1; when receiving data across the internet (network), the layers are used in the order layer 1 to layer 4. Each of the layers is implemented using software.
    • what is the application layer?
      The application layer contains all the programs that exchange data, such as web browsers or server software; it sends files to the transport layer. This layer allows applications to access the services used in other layers and also defines the protocols that any app uses to allow the exchange of data.
    • There are several protocols associated with the application layer:
      HTTP SMTP POP3/4 IMAP DNS FTP RIP SNMP
    • HTTP
      hypertext transfer protocol; this is a protocol responsible for correct transfer of files that make up web pages on the world wide web
    • SMTP
      simple mail transfer protocol; this handles the sending of emails
    • POP3/4
      post office protocol; this handles the receiving of emails
    • IMAP
      internet message access protocol; this handles the receiving of emails
    • DNS
      domain name service; protocol used to find the IP address, for example, when sending emails
    • FTP
      file transfer protocol; this is a protocol used when transferring messages and attachments
    • RIP
      routing information protocol; this is the protocol routers use to exchange routing information over an IP network
    • SNMP
      simple network management protocol; protocol used when exchanging network management information between network management and network devices (such as routers, servers and other network devices)
    • what does the term packets mean?
      Messages are split up into small groups of bits calledpackets(for example, a web page would be split up into a number of packets before sending over the network).
    • what does the term router mean?
      A router is used to transmit packets of data; routers contain connections to many other routers; when packets arrive at a router it decides where next to send them.
    • Hypertext transfer protocol (HTTP)

      HTTPis probably the most important application layer protocol. Essentially, this protocol underpins the world wide web. It is used when, for example, fetching an HTML document from a web server (Figure 14.2).
      This makes use of hyperlinks (rules for the transferring of data over the internet). HTTP is a client/server protocol: request messages are sent out to the web servers which then respond.
      HTTP protocols define the format of the messages sent and received. The web browser (which is part of the application layer) initiates the web page request and also converts HTML into a format which can be displayed on the user’s screen or can be played through their media player.
    • The following summarises what happens when a user requests a web page from a website.
      - The user keys the URL into their browser.
      - HTTP(s) transmits the request from the application layer to the transport layer (TCP).
      - The TCP creates data packets and sends them (via port 80) to the destination port(s).
      - The DNS server stores a database of URLs and matching IP addresses.
      - The DNS server uses the domain name typed into the browser to look up the IP address of the appropriate website.
      - The server TCP sends back an acknowledgement (see the section on host-to-host communication on page 333).
      - Once communication has been established, the web server sends the web page back in HTML format to the browser.
      - The browser interprets the page and displays it or sends the data in the correct format to the media player.
    • File transfer protocol (FTP)

      Thefile transfer protocol (FTP)is a network protocol used when transferring files from one computer/device to another via the internet or other networks. It is similar to HTTP and SMTP, but FTP’s only task is the application protocol for the transfer of files over a network. Web browsers can be used to connect to an FTP address in a way similar to HTTP, for example, ftp://username@ftp.example.gov/video serverweb serveradverts server
    • Additional features of FTP include:
      -anonymous ftp– this allows a user to access files without the need to identify who they are to the ftp server; for example, ‘331 Anonymous access allowed’ would be a message received to confirm anonymous access-ftp commands– a user is able to carry out actions that can change files stored on the ftp server; for example, delete, close, rename, cd (change directory on a remote machine), lcd (change directory on a local machine)-ftp server– this is where the files, which can be downloaded as required by a user, are stored.
    • how would a session start?
      A session would be started by typing in the ftp host_name (of remote system), followed by a user id and password. The user would then be able to use ftp commands to carry out a number of actions.
    • Simple mail transfer protocol (SMTP)
      Simple mail transfer protocol (SMTP)is a text-based (and connection-based) protocol used when sending emails. It is sometimes referred to as apush protocol(in other words, a client opens a connection to a server and keeps the connection active all the time; the client then uploads a new email to the server).Since SMTP is text-based only, it doesn’t handlebinary files(a binary file is a file containing media/images as well as text and is regarded as being computer- readable only). If an email contains attachments made up of, for example, images, video, music then it is necessary to use themulti-purpose internet mail extension (MIME)protocol instead. A MIME header is used at the beginning of the transmission; clients use this header to select which media player is needed when the attachment is opened.
    • POP3/4 and IMAP (post office protocol and internet message access protocol)

      Post office protocol (POP3/4)andinternet message access protocol (IMAP)are protocols used when receiving emails from the email server. These are known aspull protocols(the client periodically connects to a server; checks for and downloads new emails from the server – the connection is then closed; this process is repeated to ensure the client is updated). IMAP is a more a recent protocol than POP3/4, but both have really been superseded by the increasing use of HTTP protocols. However, SMTP is still used when transferring emails between email servers.
    • The main difference between POP3/4 and IMAP is synchronisation:
      POP3/4
      POP3/4 does not keep the server and client in synchronisation; when emails are downloaded by the client, they are then deleted from the server which means it is not further updated.
    • IMAP
      IMAP keeps the server and client in synchronisation; only a copy of the email is downloaded with the original remaining on the server until the client manually deletes it.
    • Transport layer
      The transport layer regulates the network connections; this is where data is broken up into packets which are then sent to the internet/network layer (IP protocol). The transport layer ensures that packets arrive in sequence, without errors, by swapping acknowledgements and retransmitting packets if they become lost or corrupted. The main protocols associated with the transport layer aretransmission control protocol (TCP), user datagram protocol (UDP) and SCTP. We will only consider TCP.
    • Transmission control protocol (TCP)
      TCP is responsible for the safe delivery of a message by creating sufficient packets for transmission. It uses positive acknowledgement with re- transmission (PAR) which means it automatically re-sends a data packet ifit has not received a positive acknowledgement. TCP is also connection- orientated since it establishes an end-to-end connection between two host computers using handshakes. For this last reason, TCP is often referred to as ahost-to-hosttransmission protocol.
    • what does the term host refer to?
      The termhosthas been used previously; this refers to a computer or device that can communicate with another computer/device (host). Hosts can include clients and servers that send/receive data, provide services or apps.
    • These are the steps taken when host computer 'X' communicates with another host 'Y' (this is an expansion of what happens during TCP involvement shown in the HTTP algorithm earlier on):
      - Host 'X' will first of all send host 'Y' a segment (packet) which will include synchronisation sequence bits so that segments will be received in the correct order.
      - Host 'Y' will now respond by sending back its own segment (containing an acknowledgement together with its own synchronisation sequence bits).
      - Host 'X' now sends out its own acknowledgement that the segment from 'Y' was received.
      - Transmission of data between 'X' and 'Y' can now take place.
    • Internet/network layer and network/data-link layer
      The internet layer identifies the intended network and host. The common protocol is IP (internet protocol). The concept of IPv4 and IPv6 was covered in depth in Chapter 2.
      The network/data-link layer identifies and moves traffic across local segments, encapsulates IP packets into frames for transmission, maps IP addresses to MAC (physical) addresses and ensures correct protocols are followed. The physical network layer specifies requirements of the hardware to be used for the network. The data-link layer identifies network protocols in the packet header (TCP/IP in the case here) and delivers packets to the network.
    • This is a summary of the IP functions:
      - Ensure correct routing of packets of data over the internet/network.
      - Responsible for protocols when communicating between networks.
      - Take a packet from the transport layer and add its own header which will
      include the IP addresses of both sender and recipient.
      - The IP packet (datagram) is sent to the data-link layer where it is assembles
      the datagrams into frames for transmission.
    • Ethernet protocols
      Ethernet is a system that connects a number of computers or devices together to form a LAN. It uses protocols to control the movement of frames between computers or devices and to avoid simultaneous transmission by two or more devices. It is a local protocol and does not provide any means to communicate with external devices; this requires the use of IP which sits on top of the Ethernet protocol.

      If VLAN is used, the Ethernet data size increases from 1539bytes to around
      9000bytes per frame.
    • The components that make up Ethernet data are:
      -destination -source -Ethernet type or length-frame check
    • destination
      this is the MAC address of the destination computer or device (it is possible to use the value FF:FF:FF:FF:FF:FF as the MAC address if the sender wishes to target every device (for example, to advertise services) or if they do not know the MAC address of the destination device)
    • source
      this is the MAC address of the source computer (using the usual
      MAC address format of 6bytes)
    • Ethernet type or length
      if the frame length <= 1539 then the value here is the length of the ethernet frame; if the frame length > 1539 then the value here is the Ethernet type (IPv4 or IPv6 in our example)
    • frame check
      this will include a checksum to provide a method of checking
      data integrity following transmission of the frame.
    • Wireless (WiFi) protocols
      Wireless LANs (standard IEEE 802.11 protocol) use a MAC protocol called carrier sense multiple access with collision avoidance (CSMA/CA) (not to be confused with CSMA/CD considered in Chapter 2, since this is a totally different concept).
      CSMA/CA uses distributed control function (DCF) to ensure a WiFi device can only transmit when there is a free channel available. Since all transmissions are acknowledged when using DCF, if a device does not receive an acknowledgement it will assume a collision will occur and waits for a random time interval before trying again. This is an important protocol to ensure the security and integrity of data being sent over a wireless network (such as WLAN).
    • Bluetooth protocols
      Bluetooth was considered in Chapter 2; it uses the standard IEEE 802.15 protocol for short-range data transmission/communication. There are numerous additional Bluetooth protocols due to the many applications that may use this wireless connectivity; this is outside the scope of this textbook.
    • WiMax
      Worldwide interoperability for microwave access (WiMax) runs under IEEE 802.16 protocol. This connectivity was designed originally for wireless MANs (WMAN). Fixed WiMax networks are based on the IEEE 802.16-2004 protocol, whereas mobile WiMax is based on IEEE 802.16-2005 protocol.
    • Peer-to-peer file sharing/BitTorrent protocol
      TheBitTorrentis a protocol which is based on the peer-to-peer networking concept (this was covered in Chapter 2). This allows for very fast sharing of files between computers (known aspeers). While peer-to-peer networks only work well with very small numbers of computers, the concept of sharing files using BitTorrent can be used by thousands of users who connect together over the internet. Because user computers are sharing files directly with each other (rather than using a web server) they are sharing files in a way similar to that used in a peer-to-peer network; the main difference is that the BitTorrent protocol allows many computers (acting as peers) to share files.
    • Suppose computer 'A' wishes to share a file with a number of other interested peers. How can we use the BitTorrent protocol to allow this file sharing?
      1:
      Initially, to share a file, the peer (computer ‘A’) creates a small file called a torrent (for example, MyVideoFile.torrent). The torrent contains meta data about the file about to be shared.
    See similar decks