1. Definition the viable path set between domain x and the domain y .
2. Found the optimal routing path in all feasible routing paths to minimize the maximum rule set and between domain x and the domain y .
3. Insert the optimal routing path to the Gt .
The pseudo code of the HAF algorithm is shown in Figure 2.