FortiGate
FortiGate Next Generation Firewall utilizes purpose-built security processors and threat intelligence security services from FortiGuard labs to deliver top-rated protection and high performance, including encrypted traffic.
tino_p
Staff
Staff
Article Id 361571
Description This article explains the use of IPv6 link-local address (of BGP neighbor for example) in an IPv6 network.
Scope IPv6, FortiGate.
Solution
  1. This topology is used for demonstration:

 

Untitled.png

 

The remote device redistributes the connected network (loopback network 2402:800:6a00:24::100/64) to the local FortiGate, assuming that BGP was enabled on both IPv4 and IPv6 at its neighbor 2402:800:6a00:27::303 and 10.211.244.81.

 

The local FortiGate also has both neighbors 2402:800:6a00:27::301 and 10.211.244.82 activated BGP on IPv4 and IPv6.

 
1.png

 

2.png

 

  1. After establishing BGP with the  neighbor, FortiGate has the following outputs:

 

3.png

 

4.png

 

5.png

 

The above results showed that FortiGate learned the network 2402:800:6a00:24::100/64 with the next-hop 2402:800:6a00:27::301 from both neighbors, but neighbor 10.211.244.82 only advertised the IPv6 global address, while the neighbor 2402:800:6a00:27::301 advertised both global and link-local IPv6 address.

   

  1. Based on RFC2545, it is expected behavior for IPv6 routing in BGP: https://datatracker.ietf.org/doc/html/rfc2545 (Part 3 - Constructing the Next Hop field).
  2. If it is preferred to use only the IPv6 global address, there are several workarounds:
  • To use the different weight values under BGP neighbor settings, to prefer the route that was learnt from IPv4 neighbor 10.211.244.82:

 

6.png

 

As a result, next-hop shows the global address instead of the link-local address in the routing table, because the route with a higher weight was chosen:

 

7.png

 

  • To Use prefix list, route-map, and apply route-map-in6 in the neighbor setting. In the route map, the IPv6 global address of the neighbor is defined as ip6-nexthop-local address in local FortiGate:

  

8.png

  

9.png

 

10.png

 

11.png

As a result, next-hop shows the global address instead of the link-local address in the routing table:

 

12.png

 

13.png

  

  • Another workaround is to set ip6-nexthop-local to '::', which means unspecified. It then will not use a link-local address as nexthop while installing the route into the routing table. Currently, the feature is under development and will be updated here when available.
Contributors