summaryrefslogtreecommitdiffhomepage
path: root/pkg/tcpip/header/ipv6.go
diff options
context:
space:
mode:
authorgVisor bot <gvisor-bot@google.com>2019-10-22 14:29:06 +0000
committergVisor bot <gvisor-bot@google.com>2019-10-22 14:29:06 +0000
commit1e55a0ef32ae01e56ec07c660468039d2ab4288b (patch)
tree362bfefd2f90e38b93b7d1c127232148981f4536 /pkg/tcpip/header/ipv6.go
parent91c723c00b95d5b62a47b4c662246648a5aec741 (diff)
parentfb69de696be5d5ebfd427867fe387c2f93845bfa (diff)
Merge release-20190806.1-299-gfb69de6 (automated)
Diffstat (limited to 'pkg/tcpip/header/ipv6.go')
-rw-r--r--pkg/tcpip/header/ipv6.go9
1 files changed, 9 insertions, 0 deletions
diff --git a/pkg/tcpip/header/ipv6.go b/pkg/tcpip/header/ipv6.go
index b125bbea5..f1e60911b 100644
--- a/pkg/tcpip/header/ipv6.go
+++ b/pkg/tcpip/header/ipv6.go
@@ -101,6 +101,15 @@ var IPv6EmptySubnet = func() tcpip.Subnet {
return subnet
}()
+// IPv6LinkLocalPrefix is the prefix for IPv6 link-local addresses, as defined
+// by RFC 4291 section 2.5.6.
+//
+// The prefix is fe80::/64
+var IPv6LinkLocalPrefix = tcpip.AddressWithPrefix{
+ Address: "\xfe\x80\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00",
+ PrefixLen: 64,
+}
+
// PayloadLength returns the value of the "payload length" field of the ipv6
// header.
func (b IPv6) PayloadLength() uint16 {