Cisco \ Fortigate Policy based routing

we sometimes encounter a situations when simple routing is not enough,
for instance we have several gateways and we need to load-balance between them based on the source/destination IP port or protocol.
Needless to say that can be achieved best by using a dedicated load-balancer device, but let's say we don’t have one ( and not eager to parches ).

In my opinion the simplest way of achieving this is PBR ( policy based routing), the concept is pretty basic – when a packet matches the condition I provide pass it to the gateway I provide ( off course pass can be replaced with other options).

In the Cisco world it's a route-map, for example:
route-map PBR permit 10
 match ip address ACL1
 set ip next-hop
route-map PBR permit 20
If we get a packet that matches access-list "ACL1" pass it to the ip, all other traffic passed according to the routing table (there is no match statement so anything is being matched, and no set basically so nothing is being performed).

In case of a Fortinet firewall, its Policy Route:
CLI version:
config router policy
    edit 1
        set input-device "port4"
        set src
        set dst
        set protocol 6
        set start-port 443
        set end-port 443
        set gateway
        set output-device "port3"
or gui version:

In both cases packet with the source "" and destination "" TCP (protocol 6) port 443 pass it to interface "Port3" with as the next-hop.

Hope this post was helpful, If it was please consider a donation:
BTC Address: 1CnyMpjd1RntRDxSus2hu2aDMyzL4Kj29N
LTC Address: LUqrKbzGihTU2GEnL3EwsuuLHCsxCJMdtR


  1. Such routing are used by and large in the USA and each money related foundation has at any rate one bank. usaa routing number

  2. Another type of private networking uses the link-local address range. The validity of link-local addresses is limited to a single link; e.g. to all computers connected to a switch, or to one wireless network. Hosts on different sides of a network bridge are also on the same link, whereas hosts on different sides of a network router are on different links.