Defined by the IETF in RFC 2702 (1999) as a labelswapping framework with Network Layer (Layer 3) routing, MPLS integrates Data Link Layer (Layer 2) information about network links into Layer 3 routing logic. MPLS enables routers to make packet forwarding decisions very quickly on the basis of short labels, rather than making complex routing decisions after analyzing lengthy packet headers. MPLS is designed to work through routers at even higher speed than ATM switches, while realizing much of the flexibility of an Internet Protocol (IP) network. MPLS works on the basis of forwarding equivalence classes (FECs) and flows. A flow consists of packets between common endpoints identified by features such as network addresses and port numbers.An FEC is a class of packets, all of which are treated the same in terms of destination, priority level, and so on.At the ingress edge of the carrier network, a label edge router (LER) identifies the flow based on the IP header, the interface through which the packet arrives, the packet type (unicast, multicast, or anycast), or perhaps information in the IPv4 Type of Service (ToS) field. The LER attaches a 32-bit MPLS header that includes a 20-bit label, or tag, to that packet and to each subsequent packet of the flow. The LER uses a Label Distribution Protocol (LDP) to distribute the labels or tags to each intervening Label Switching Router (LSR) in the network core, identifying the treatment that should be afforded all packets in the flows on that particular Label Switched Path (LSP). If the traffic engineering options are exercised, traffic is balanced between optimum and non-optimum paths, and congestion is minimized. Otherwise, the traffic takes the same paths that IP packets would take, as MPLS nodes use IP routing protocols, such as the Border Gateway Protocol (BGP), Open Shortest Path First (OSPF), and Routing Information Protocol (RIP) to distribute the labels. From edge-to-edge through the core of the network, each LSR makes note of the incoming port number and analyzes the label associated with each packet in order to select the appropriate Label Switched Path (LSP) over which the packet is to be forwarded on its way to the next LSR. The LSR then switches the existing label for a new one, and forwards it. Thereby, and through a series of links, the end-to-end path is set up and maintained for a given traffic flow. The more complex processes of complete header analysis and routing table lookup are performed only at the ingress edge of the network. In the core of the network, only the abbreviated MPLS label is analyzed in order to make a relatively simple and straightforward packet forwarding decision. All in all, MPLS simplifies the routing process and reduces latency. At the egress LER, the tag is stripped away, as it no longer has any purpose. The structure of the 32-bit MPLS header, as illustrated in Figure M-5, is as follows.