IPv4
- (IPv4 Header Structure)
- Overview
IPv4 is the first widely used version of the Internet Protocol, introduced in 1983, and is still the most common way to identify network devices.
It utilizes 32-bit addresses, resulting in approximately 4.3 billion unique addresses, although some are reserved.
Key characteristics :
- Historical Context: IPv4 was the first version of IP to be standardized and deployed on a large scale.
- Address Format: IPv4 uses 32-bit addresses, which are typically represented as four sets of numbers separated by periods (e.g., 192.168.1.1).
- Address Space: The 32-bit address space allows for roughly 4.3 billion unique addresses.
- Special Uses: Some address blocks within the 4.3 billion are reserved for specific purposes like private networks or multicast addresses.
- Prevalence: Despite the introduction of IPv6 with its larger address space, IPv4 remains widely used due to its simplicity and widespread deployment.
- Limitations: The limited address space of IPv4 has become a concern as the number of internet-connected devices has grown, leading to the development and adoption of IPv6.
Please refer to the following for more information:
- Wikipedia: IPv4
- IPv4 Addressing
IPv4, defined in RFC 791, is a connectionless protocol using a best-effort delivery model, meaning it doesn't guarantee packet delivery, sequencing, or duplicate avoidance. It utilizes 32-bit addresses represented in dot-decimal notation (e.g., 192.168.1.1) and is divided into five classes (A, B, C, D, and E) for addressing.
Key Aspects of IPv4:
- Connectionless: Data is transmitted in packets without a prior connection setup.
- Best-Effort Delivery: IPv4 doesn't guarantee packet delivery or proper sequencing.
- 32-bit Addressing: Each device is identified by a 32-bit address, allowing for approximately 4.3 billion unique addresses.
- Dot-Decimal Notation: Addresses are written as four decimal numbers separated by periods.
- Classful Addressing: Originally divided into classes A, B, C, D, and E, with different bit allocations for network and host portions.
- RFC 791: The official specification document for IPv4.
- Upper Layer Protocols: Protocols like TCP handle aspects like data integrity and error control, often alongside IPv4.
- IPv4 Datagram Header
The IPv4 datagram header is a crucial part of an IPv4 packet, containing metadata about the data being transmitted. It essentially acts as an address label and routing guide for the packet as it travels across a network. The header includes 13 mandatory fields, and an optional "Options" field, and varies in size from 20 to 60 bytes.
Here's a breakdown of the key fields:
1. Mandatory Fields:
- Version: Specifies the IP version (4 for IPv4).
- Internet Header Length (IHL): Indicates the length of the header in 32-bit words.
- Type of Service (TOS): (Now more commonly known as Differentiated Services Code Point (DSCP)) used for traffic prioritization.
- Total Length: Specifies the total length of the datagram (header + data) in bytes.
- Identification: Used to identify fragments of an original IP datagram.
- Flags: Used for fragmentation control.
- Fragment Offset: Indicates the position of a fragment within the original datagram.
- Time to Live (TTL): Limits the lifetime of a datagram to prevent it from endlessly circulating.
- Protocol: Identifies the protocol of the data carried in the payload (e.g., TCP, UDP).
- Header Checksum: Used for error detection in the header.
- Source Address: The IP address of the sending device.
- Destination Address: The IP address of the receiving device.
2. Optional Field:
- Options: Provides additional, less frequently used functionalities and can vary in length.
[More to come ...]