APIPA - Automatic Private IP Addressing ======================================== .. panels:: :container: container pb-4 :column: col-lg-12 p-2 :card: shadow .. panels:: :container: container pb-4 :column: col-lg-12 p-2 :card: shadow **What is APIPA?** APIPA stands for Automatic Private IP Addressing. It’s a feature in Windows and some other operating systems that automatically assigns an IP address to a device when a DHCP server is unavailable. .. panels:: :container: container pb-4 :column: col-lg-12 p-2 :card: shadow **Why is APIPA Useful?** * Allows basic network communication even when the DHCP server is down. * Provides a fallback mechanism for IP addressing. * Useful in peer-to-peer and troubleshooting environments. * Ensures devices can still talk locally when central IP management fails. .. panels:: :container: container pb-4 :column: col-lg-12 p-2 :card: shadow **How it works?** * **Device tries DHCP** – When a device joins a network, it first tries to get an IP address from a DHCP server. * **No DHCP response** – If no DHCP server responds, the device assigns itself an IP address from a reserved range. * **APIPA address assigned** – The device picks an IP from `169.254.0.1` to `169.254.255.254`. * **Local communication only** – The device can communicate with other devices using APIPA addresses on the same subnet. .. panels:: :container: container pb-4 :column: col-lg-12 p-2 :card: shadow **Where is APIPA used?** * **Small peer-to-peer networks** – Where there’s no DHCP server. * **Temporary fallback** – When DHCP fails, APIPA allows basic LAN communication. * **Troubleshooting** – Seeing an APIPA address helps identify DHCP-related issues. .. panels:: :container: container pb-4 :column: col-lg-12 p-2 :card: shadow **Which OSI Layer does this protocol belong to?** * **Network Layer (Layer 3)** * APIPA operates at the Network Layer because it involves IP address assignment and basic IP-based communication. * It does not interact with user applications directly. * It’s part of the operating system's IP configuration system, not application logic. .. panels:: :container: container pb-4 :column: col-lg-12 p-2 :card: shadow Topics in this section, * :ref:`Learnings in this section ` * :ref:`Terminology ` * :ref:`Version Info ` * :ref:`APIPA Version&RFC Details ` * :ref:`APIPA Basic Setup on Ubuntu using IPv4 ` * :ref:`APIPA Basic Setup on Ubuntu using IPv6 ` * :ref:`APIPA Protocol Packet Details ` * :ref:`APIPA Usecases ` * :ref:`APIPA Basic Features ` * :ref:`APIPA Feature : Automatic IP Assignment ` * :ref:`APIPA Feature : No Manual Configuration Needed ` * :ref:`APIPA Feature : Uses ARP for Conflict Detection ` * :ref:`APIPA Feature : Limited to Local Subnet ` * :ref:`APIPA Feature : Fallback Mechanism ` * :ref:`APIPA Feature : Zero-Configuration Networking ` * :ref:`APIPA Feature : IPv4 Only` * :ref:`Reference links ` .. _APIPA_step1: .. tab-set:: .. tab-item:: Learnings in this section * In this section, you are going to learn .. _APIPA_step2: .. tab-set:: .. tab-item:: Terminology * Terminology .. _APIPA_step3: .. tab-set:: .. tab-item:: Version Info * Version Info .. _APIPA_step5: .. tab-set:: .. tab-item:: APIPA Version&RFC Details .. csv-table:: :file: ./APIPA/APIPA_RFC_Details.csv :widths: 10,10,10,30,30 :header-rows: 1 .. _APIPA_step16: .. tab-set:: .. tab-item:: APIPA Basic Setup on Ubuntu using IPv4 * Setup .. _APIPA_step17: .. tab-set:: .. tab-item:: APIPA Basic Setup on Ubuntu using IPv6 * Setup .. _APIPA_step6: .. tab-set:: .. tab-item:: APIPA Protocol Packet Details **DHCP Discover Packet** .. csv-table:: :file: ./APIPA/APIPA_Protocol_Packet_1.csv :widths: 10,20,30,10 :header-rows: 1 **ARP Request Packet** .. csv-table:: :file: ./APIPA/APIPA_Protocol_Packet_2.csv :widths: 10,20,30,10 :header-rows: 1 **ARP Reply Packet** .. csv-table:: :file: ./APIPA/APIPA_Protocol_Packet_3.csv :widths: 10,20,30,10 :header-rows: 1 **ICMP Echo Request/Reply Packet** .. csv-table:: :file: ./APIPA/APIPA_Protocol_Packet_4.csv :widths: 10,20,30,10 :header-rows: 1 **Gratuitous ARP Packet** .. csv-table:: :file: ./APIPA/APIPA_Protocol_Packet_5.csv :widths: 10,20,30,10 :header-rows: 1 **DHCP Offer / ACK Packet** .. csv-table:: :file: ./APIPA/APIPA_Protocol_Packet_6.csv :widths: 10,20,30,10 :header-rows: 1 .. _APIPA_step7: .. tab-set:: .. tab-item:: APIPA Usecases APIPA Usecases .. _APIPA_step8: .. tab-set:: .. tab-item:: APIPA Basic Features .. csv-table:: :file: ./APIPA/APIPA_Features.csv :widths: 10,10,30 :header-rows: 1 .. _APIPA_step9: .. tab-set:: .. tab-item:: APIPA Feature : Automatic IP Assignment **Automatic IP Assignment - Testcases** .. csv-table:: :file: ./APIPA/APIPA_Feature-1_Automatic_IP_Assignment_Testcase.csv :widths: 10,10,30,20 :header-rows: 1 .. _APIPA_step10: .. tab-set:: .. tab-item:: APIPA Feature : No Manual Configuration Needed **No Manual Configuration Needed - Testcases** .. csv-table:: :file: ./APIPA/APIPA_Feature-2_No_Manual_Configuration_Needed_Testcase.csv :widths: 10,10,30,20 :header-rows: 1 .. _APIPA_step11: .. tab-set:: .. tab-item:: APIPA Feature : Uses ARP for Conflict Detection **Uses ARP for Conflict Detection - Testcases** .. csv-table:: :file: ./APIPA/APIPA_Feature-3_Uses_ARP_For_Conflict_Detection_Testcase.csv :widths: 10,10,30,20 :header-rows: 1 .. _APIPA_step12: .. tab-set:: .. tab-item:: APIPA Feature : Limited to Local Subnet **Limited to Local Subnet - Testcases** .. csv-table:: :file: ./APIPA/APIPA_Feature-4_Limited_to_Local_Subnet_Testcase.csv :widths: 10,10,30,20 :header-rows: 1 .. _APIPA_step13: .. tab-set:: .. tab-item:: APIPA Feature : Fallback Mechanism **Fallback Mechanism - Testcases** .. csv-table:: :file: ./APIPA/APIPA_Feature-5_Fallback_Mechanism_Testcase.csv :widths: 10,10,30,20 :header-rows: 1 .. _APIPA_step14: .. tab-set:: .. tab-item:: APIPA Feature : Zero-Configuration Networking **Zero-Configuration Networking - Testcases** .. csv-table:: :file: ./APIPA/APIPA_Feature-6_Zero-Configuration_Networking_Testcase.csv :widths: 10,10,30,20 :header-rows: 1 .. _APIPA_step15: .. tab-set:: .. tab-item:: APIPA Feature : IPv4 Only **IPv4 Only - Testcases** .. _APIPA_step18: .. tab-set:: .. tab-item:: Reference links * Reference links