MCPcopy Create free account
hub / github.com/FDio/vpp / create_ndp_req

Method create_ndp_req

test/vpp_pg_interface.py:572–584  ·  view source on GitHub ↗

Create NDP - NS applicable for this interface

(self, addr=None)

Source from the content-addressed store, hash-verified

570 )
571
572 def create_ndp_req(self, addr=None):
573 """Create NDP - NS applicable for this interface"""
574 if not addr:
575 addr = self.local_ip6
576 nsma = in6_getnsma(inet_pton(socket.AF_INET6, addr))
577 d = inet_ntop(socket.AF_INET6, nsma)
578
579 return (
580 Ether(dst=in6_getnsmac(nsma))
581 / IPv6(dst=d, src=self.remote_ip6)
582 / ICMPv6ND_NS(tgt=addr)
583 / ICMPv6NDOptSrcLLAddr(lladdr=self.remote_mac)
584 )
585
586 def resolve_arp(self, pg_interface=None):
587 """Resolve ARP using provided packet-generator interface

Callers 1

resolve_ndpMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected