Technical data

Gateway Routing Daemon (GATED) Configuration Reference
A.18 Control Statements
A.18.4.2 Route Filters
All the formats allow route filters as shown in the following example. See the
section on route filters for a detailed explaination of how they work. When no
route filtering is specified (that is, when
restrict
is specified on the first line of a
statement), all routes from the specfied source will match that statement. If any
filters are specified, only routes that match the specified filters will be exported.
That is, if any filters are specified, a
all restrict ;
statement is assumed at the
end of the list.
network [ exact | refines | between number and number ]
network mask mask [exact | refines | between number and number ]]
network masklen number [ exact | refines | between number and number ]]
default
host host
A.18.4.3 Specifying the Destination
As mentioned above, the syntax of the export statement varies depending on
the protocol it is being applied to. One thing that applies in all cases is the
specification of a metric. All protocols define a default metric to be used for routes
being exported, in most cases this can be overridden at several levels of the export
statement.
The specification of the source of the routing information being exported (the
export_list
) is described below.
Exporting to EGP and BGP
export proto bgp | egp as autonomous system
restrict ;
export proto bgp | egp as autonomous system [ aspath-opt ]
[ metric metric ]{
export_list ;
};
Exportation to EGP and BGP is controlled by an autonomous system. The same
policy is applied to all routers in the AS. EGP metrics range from 0 to 255
inclusive, with zero being the most attractive.
BGP metrics are 16 bit unsigned quantities; that is, they range from 0 to 65535
inclusive with 0 being the most attractive. While BGP version 4 actually supports
32 bit unsigned quantities, GATED does not yet support this. In BGP version 4,
the metric is otherwise known as the Multi-Exit Discriminator, or MED.
In BGP, the
aspath-opt
option may be used to send the BGP
community
attribute.
Any communities specified with the
aspath-opt
option are sent in addition to any
received with the route or specified in the
group
statement.
If no export policy is specified, only routes to attached interfaces will be exported.
If any policy is specified the defaults are overridden; it is necessary to explicitly
specify everything that should be exported.
Note that EGP and BGP versions 2 and 3 only support the propagation of natural
networks, so the host and default route filters are meaningless. BGP version
4 supports the propagation of any destination along with a contiguous network
mask.
A–38 Gateway Routing Daemon (GATED) Configuration Reference