UNIT 3: TCP/IP, ARP, RARP and ICMP, TCP vs UDP, DNS, Email, FTP

Ques) Define IP Address. Explain three typical formats of IP Address?

Ans: IP address: It is a unique address specified in the TCP/IP used to identify the host in a computer network. It can be a 32 bit address (IPv4) or a 128 bit address (IPv6).

There are five different classes or formats of IP address are as given below:

Class A: Class A type of IP addresses have First byte consisting of Network address with first bit as 0 and the next 3 bytes with host id. Hence, number of hosts are more when compared to number of networks.

Class B: This type has first two bytes specifying network ID with starting two bits as 10 and last two bytes referring to host ID.

Class C: This class has first three bytes referring to network with starting bits as 110 and last byte signifies Host ID. Here, number of networks are more when compared to number of hosts in each network.

Class D: Class D is used for multicasting and its starting bits are 1110

Class E: Class E is reserved for future use and its starting bits are 1111

Untitled

Fig: Formats of classes of IP address 

Ques) Describe ICMP Datagram?

Ans: The Internet Control Message Protocol (ICMP) is a mechanism used by hosts and gateways to send notification of datagram problems back to the sender. ICMP sends query and error reporting messages.  The error-reporting messages report problems that a router or a host (destination) may encounter when it processes an IP packet.

The query messages, which occur in pairs, help a host or a network manager get specific information from a router or another host. For example, nodes can discover their neighbors. Also, hosts can discover and learn about routers on their network, and routers can help a node redirect its messages.

Untitled

An ICMP message has an 8-byte header and a variable-size data section. Although the general format of the header is different for each message type, the first 4 bytes are common to all.

As Figure shows:

  • First field, ICMP type, defines the type of the message.
  • The code field specifies the reason for the particular message type.
  • The last common field is the checksum field and it has 2 bytes.
  • The data section in error messages carries information for finding the original packet that had the error. In query messages, the data section carries extra information based on the type of the query.

Ques) Define Protocol. Explain any three protocols related with Data Communication?

Ans: Protocol:

A protocol is a set of rules that govern data communications. A protocol defines what is communicated, how it is communicated, and when it is communicated. The key elements of a protocol are syntax, semantics, and timing.

Following are the protocols related to data communication:

TCP: The Transmission Control Protocol (TCP) provides full transport-layer services to applications. TCP is a reliable and connection-oriented stream transport protocol. A connection must be established between both ends of a transmission before either can transmit data.

UDP: User Datagram Protocol is a connectionless, unreliable transport layer protocol with no embedded flow or error control mechanism except the checksum for error detection. The UDP packet is called a user datagram. A user datagram is encapsulated in the data field of an IP datagram.

FTP: File Transfer Protocol (FTP) is a standard network protocol is used to transfer files from one host to another host over a TCP based network such as a internet.

TFTP: Trivial File Transfer Protocol (TFTP) is a file transfer protocol notable for simplicity. It is generally used for automated transfer of configuration or boot files between machines.

SMTP: Simple Mail Transfer Protocol (SMTP) is an internet standard for electronic mail (e-mail) transmission across Internet.

IMAP: Internet Message Access Protocol allows and e-mail client to access e-mail on a remote mail server.

Telnet: Telnet is a network protocol used on the Internet or local area networks to provide a bidirectional interactive text-oriented communication facility using a virtual terminal connection.

Ques) Write short note on FTP. OR Function of TFTP Protocol?

ANS:

  •  FTP is a high level application layer protocol that is aimed at providing a very simple interface for any user of the internet to transfer files.
  •  FTP presents the user with a prompt and allows entering of various commands for accessing and downloading files that physically exists on a remote compute.
  • The user identifies a remote computer and instructs FTP to establish a connection with it. FTP contacts the remote computer using the TCP/IP software.
  •  Once the connection is established, the user can choose to download a file from the remote computer or the user can send the file from the user end to be stored on remote computer.
  •  FTP uses two connections between a client and server.
  • Data transfer
  • Control information – for commands and responses
  •  This makes FTP more efficient
  •  The client has three components
  • User interface
  • Client control process
  • Client data transfer process
  •  FTP uses two well-known TCP ports: port 21 is used for the control connection and port 20 is used for the data connection.

Untitled

Fig:FTP basics Architecture

Ques) Write short note on TFTP?

ANS:

  • Trivial File Transfer Protocol, is a simple high-level protocol for transferring data servers use to boot diskless workstations, X-terminals, and routers by using User Data Protocol (UDP).
  • Although TFTP is also based in FTP technology.
  • TFTP is an entirely different protocol. Among the differences is that TFTP’s transport protocol uses UDP which is not secure while FTP uses Transmission Control Protocol (TCP) to secure information.
  • TFTP was primarily designed to read or write files by using a remote server.
  • TFTP Configuration Uses
  • Transferring files
  • Remote-booting without hard drives
  • Upgrading codes
  • Backing up network configurations
  • Backing up router configuration files
  • Saving IOS images
  • Booting PCs without a disk
  • TFTP Protocol Transfer Modes
  • netascii
  • octet
  • mail

Ques) Difference between FTP & TFTP ?

ANS:

Sr No. Parameter FTP TFTP
          1 Operation Transferring Files Transferring Files
          2 Authentication Yes No
          3 Control & Data Separated Not Separated
          4 Protocol TCP UDP
          5 Ports 21-Control,20-Data Port 3214,69,4012
          6 Data Transfer Reliable Unreliable

Ques)Explain Function of ARP Protocol?

ANS:

  •  Mapping high level address to hardware address is called as Address Resolution.
  •  ARP stands for Address Resolution Protocol.
  •  ARP is a protocol for mapping an Internet Protocol address (IP)to a physical machine address.
  •  It operates at layer 2 of the OSI model.
  •  It provides the interface between the IP addressing system used by IP and the Hardware addresses used by the data link layer protocol.
  •  ARP broadcasts an IP address in an effort to discover its equivalent hardware address
  • ARP Converts an IP address to its corresponding physical network address.
  •  ARP is a low-level network protocol. Operating at layer 2

Ques)Explain Function of RARP Protocol?

ANS:

  • 1 Reverse address resolution protocol is a network protocol used to resolve a data link layer address to the corresponding network layer address.
  • 2 It is the RARP which designed for diskless workstations that have no means of permanently storing their TCP/IP configuration information or TCP/ IP settings.
  • 3 RARP does the opposite of ARP. While ARP broadcasts an IP address in an effort to discover its equivalent hardware address, RARP broadcasts the systems hardware address.
  • 4 RARP server responds by transmitting the IP address assigned to that client computer.
  • 5 RARP can supply IP address to all the systems on a network segment.
  • 6 The client broadcasts the request, and does not need prior knowledge of the network topology or the identities of servers capable of fulfilling its request.
  • 7 RARP requires one or more server hosts to maintain a database of mappings of Link Layer addresses to their respective protocol addresses.

Ques) Draw & explain ARP Message format?

ANS:

Untitled

Hardware type: 2 octets—This field identifies the specific data-link protocol being used. For Ethernet, the value of this field is 1.

Protocol type: 2 octets—As the hardware type identified the data-link protocol, this field identifies the network protocol. For IP, the value of this field is 2048.

Hardware address size: 1 octet—This field specifies the length, in octets, of a MAC address in fields 5 and 7 of the ARP packet. For Ethernet, the value of this field is 6

Protocol address size: 1 octet—Analogous to the hardware address size, this field specifies the length, in octets, of the protocol addresses in fields 6 and 8 of the ARP packet.

Addresses: varying—The next four fields are the source hardware, and protocol addresses, and the destination hardware and protocol addresses, respectively. The two hardware addresses are the length specified in the Hardware address size field, and the protocol addresses are the length specified in the Protocol address field. In the case of IP over Ethernet, this corresponds to two 6-octet fields, and two 4-octet fields, for a total of 20 octets.

Ques) Draw & explain RARP Message format?

 Ans:Untitled

Ques) Explain DNS with neat sketch diagram?

ANS:

  • A domain name server is simply a computer that contains the database and the software of mapping between domain names and IP addresses.
  •  Every domain has a domain name server. It handles request coming to computers owned by it and also maintains the various domain entries.
  •  The DNS is completely distributed throughout the world on millions of computers.
  •  Accept request from programs for converting domain names into IP addresses.
  •  Accept request from other DNS servers to convert domain names into IP addresses

Generic Domain Name Table:

Untitled

How it works:

Untitled

  •  When such request comes in, a DNS server has the following options:
  •  It can supply the IP address because it already knows the IP address for the domain.
  •  It can contact another DSN server and try to locate the IP address for the name requested.
  •  It may have to do this more than once. Every DNS server has an entry called alternate DNS server, which is the DNS server it should get in touch with for unresolved domains.
  •  The DNS hierarchy specifies how the chains between the various DNS servers should be established for this purpose.
  •  It can simple say, “I do not know the IP addresses for the domains name you have requested, but here is the IP addresses for a name server that knows more than I do”.
  •  In other word, it suggests the name of another DNS server. It can return an error message because the requested domain name is invalid or does not exist.

User Datagram Protocol (UDP):

Thin wrapper around IP services

  • Service Model

– Unreliable unordered datagram service

– Addresses multiplexing of multiple connections

  • Multiplexing

– 16-bit port numbers (some are “well-known”)

  • Checksum

– Validate header

– Optional in IPv4

– Mandatory in IPv6
Untitled

Fig: UDP Packet Format

Function of Transmission Control Protocol (TCP):

  • Guaranteed delivery:
    • Messages delivered in the order they were sent
    • Messages delivered at most once
  • No limit on message size
  • Synchronization between sender and receiver
  • Multiple connections per host
  • Flow control
  • Connection oriented:
    • Explicit setup and teardown required
  • Byte stream abstraction:
    • No boundaries in data
    • App writes bytes, TCP send segments, App receives bytes
  • Full duplex:
    • Data flows in both directions simultaneously
    • Point-to-point connection
  • Implements congestion control:
    • Flow control: receiver controls sender rate
    • Congestion control: network indirectly controls sender rate

Untitled

IP Datagram Format:
Untitled

Leave a Reply

Your email address will not be published. Required fields are marked *