By applying filters of routing policies to routing protocols, you can filter the imported routes.
After defining a filter (such as the IP prefix list, ACL, or route-policy) of a routing policy, you need to apply the filter to routing protocols.
You can apply routing policies when you want to import external routes:
You can use the import-route command in the related protocol view, import the required external routes to the protocols, and apply a route-policy to filter imported routes.
After external routes are imported, you can run the filter-policy export command to filter the imported external routes. Only the routes that meet the matching rules are advertised.
BGP has the powerful filtering function. For the configuration of BGP routing policies, refer to "BGP Configuration."
For details of the filter-policy and import-route commands and their applications in RIP, OSPF, IS-IS, and BGP, refer to related configurations.