Introduce mixed mode NDP/ICMP6 echo reply

- Controller: NDP
- Switch: icmp6 echo reply
This commit is contained in:
Nico Schottelius 2019-03-06 17:23:01 +01:00
commit e0a9d28606
2 changed files with 34 additions and 20 deletions

View file

@ -175,13 +175,18 @@ class L2Controller(object):
self.controller.table_clear("v6_addresses")
for v6addr in self.v6_addresses[self.mode]:
log.debug("Adding v6 address: {}".format(v6addr))
icmp6_addr = self.gen_ndp_multicast_addr(v6addr)
another_addr = v6addr +1
another_addr_ns = self.gen_ndp_multicast_addr(another_addr)
self.controller.table_add("v6_addresses", "controller_reply", [str(v6addr)], [str(self.task['ICMP6_GENERAL'])])
self.controller.table_add("v6_addresses", "controller_reply", [str(icmp6_addr)], [str(self.task['ICMP6_NS'])])
# Experimental
# Experimental: controller does NDP, switch does ICMP6 echo reply
self.controller.table_add("v6_addresses", "controller_reply", [str(another_addr_ns)], [str(self.task['ICMP6_NS'])])
self.controller.table_add("v6_addresses", "icmp6_echo_reply", [str(another_addr)])
def config_hosts(self):