Hi,
a minor thing I've also found in the vrf static route code for ipv6, related to how ip6 addresses shortening works...
When I add a route with
set protocols vrf ivrf static route6 fe::0/64 next-hop fe:fe::1 interface eth0
it gets added into frr as:
vrf ivrf ipv6 route fe::/64 fe:fe::1 eth0 exit-vrf
but when trying to delete the route with:
delete protocols vrf ivrf static route6 fe::0/64
it errors:
delete protocols vrf ivrf static route6 fe::0/64 [edit] vyos@vyos# commit [ protocols vrf ivrf static route6 fe::0/64 next-hop fe:fe::1 ] % Command incomplete: no delete [ protocols vrf ivrf static route6 fe::0/64 ] failed Commit failed [edit]
most probably due to the way the deletion code works - looks very similar to https://phabricator.vyos.net/T2338, where issue was capital letters in the ipv6 address.
Worth noting is something that may be useful during developing a fix is that for the vyos cli fe:b::0/64 and fe:b::/64 are different routes, so potentially the logic should be in the subnet format validation, not in this node?
set protocols vrf ivrf static route6 fe:b::0/64 next-hop fe:fe::1 interface eth0 set protocols vrf ivrf static route6 fe:b::/64 next-hop fe:fe::1 interface eth0
gives the below output:
vyos@vyos# compare [edit protocols vrf ivrf static] +route6 fe:b::0/64 { + next-hop fe:fe::1 { + interface eth0 + } +} +route6 fe:b::/64 { + next-hop fe:fe::1 { + interface eth0 + } +}