# A Hierarchical Mapping System for Flat Identifier to Locator Resolution Based on Active Degree
## 3 Mapping Items Flow Mechanism
### Mapping Item Initialization, Update, and PR Mechanism  
When an endpoint registers to an access router or moves to an area a new access router covers, it will be allocated a corresponding routing identifier (RID). The difference is that moving to a new access router will cause an update of the relevant copies, and the main process is described in Figure 3. The process includes six steps:  
* Endpoint with AIDi sends registration request packet to the access router;
* Access router verifies the legitimacy of the endpoint. If legitimate, sends registration request packet to the corresponding AMS. Otherwise, refuses service;
* AMS queries the AIDi item in LRMT.
* If no relevant mapping item, allocates a new routing locator RIDai for it, and turns to _Step 4_.
* Otherwise, using the original mapping item, sends a registration success message to AIDi and exits.
* The new mapping item of AIDi (AIDi:RIDai,) is stored in AMS and reported to the corresponding NMS;
* NMS queries the mapping item in NLMT using key AIDi. The process is divided into the following cases: _Case 1_: If there is not a relevant mapping item, then it generates an item (AIDi, RIDai, RIDa, T, M, Flag) and stores it in NLMT, and reports (AIDi, RIDai) to IMS. _Case 2_: If there is a relevant mapping item (AIDi, RIDai, T, M, Flag) related to AIDi, it judges if the (AIDi, RID) is valid through sending the verification message to RID.  
If valid, indicating that now the endpoint has two routing locators, that is, it is a multi-homing endpoint, then it adds a piece of mapping information for this item. If the Flag shows that the mappingitem reported to IMS is an access routing identifier, then it needs to report this mapping item to IMS. Invalid item conditions will be described in the PR mechanism next.  
We can set the reported mapping item as (AID\({}_{\text{i}}\):RID\({}_{\text{i}}\)).  
_Step 6_: Receiving the mapping table, IMS queries the mapping item with key AID\({}_{\text{i}}\) based on the relevant CHORD algorithms. If successful, assuming the mapping item is (AID\({}_{\text{i}}\), RID\({}_{\text{0}}\), (RID\({}_{\text{m}}\))), it firstly verifies the legitimacy of this mapping items. If legal, then it adds the item (AID\({}_{\text{i}}\), RID\({}_{\text{i}}\), (RID\({}_{\text{m}}\))), and notifies this item to (RID\({}_{\text{m}}\)). Otherwise, it stores it directly.  
In the second case of _Step 5_, that is, if invalid, it indicates that the endpoint has moved. Then, it replaces RID with RID\({}_{\text{ai}}\). To distinguish frequently mobile hosts and fixed hosts, apparently, the \(M\) in item is the key. In fact, for the mobile endpoint, its mobility is a long-time statistical result. Therefore, we use the number of that endpoint's leaps across two different access routers as the statistical value of \(M\). Then we judge an endpoint as a mobile terminal or fixed terminal in the following way. Supposing the current clock is \(T_{n}\), if \(M/(T_{n}-T)<\alpha\) (\(\alpha\) is a const), it is a fixed endpoint, and reports its access routing identifier. Otherwise, it is a frequently mobile endpoint, and assigns a mobile routing identifier and reports to IMS. We call this method the Policy Report (PR) mechanism mentioned above.