]> Cypherpunks repositories - gostls13.git/commitdiff
syscall: add IPv6 socket options for Unix variants
authorMikio Hara <mikioh.mikioh@gmail.com>
Thu, 23 May 2013 07:22:05 +0000 (16:22 +0900)
committerMikio Hara <mikioh.mikioh@gmail.com>
Thu, 23 May 2013 07:22:05 +0000 (16:22 +0900)
This CL adds missing IPv6 socket options which are required
to control IPv6 as described in RFC 3493, RFC 3542.

Update #5538

R=golang-dev, dave, iant
CC=golang-dev
https://golang.org/cl/9373046

34 files changed:
src/pkg/syscall/mkerrors.sh
src/pkg/syscall/syscall_bsd.go
src/pkg/syscall/syscall_linux.go
src/pkg/syscall/types_darwin.go
src/pkg/syscall/types_freebsd.go
src/pkg/syscall/types_linux.go
src/pkg/syscall/types_netbsd.go
src/pkg/syscall/types_openbsd.go
src/pkg/syscall/zerrors_darwin_386.go
src/pkg/syscall/zerrors_darwin_amd64.go
src/pkg/syscall/zerrors_freebsd_386.go
src/pkg/syscall/zerrors_freebsd_amd64.go
src/pkg/syscall/zerrors_freebsd_arm.go
src/pkg/syscall/zerrors_linux_386.go
src/pkg/syscall/zerrors_linux_amd64.go
src/pkg/syscall/zerrors_linux_arm.go
src/pkg/syscall/zerrors_netbsd_386.go
src/pkg/syscall/zerrors_netbsd_amd64.go
src/pkg/syscall/zerrors_netbsd_arm.go
src/pkg/syscall/zerrors_openbsd_386.go
src/pkg/syscall/zerrors_openbsd_amd64.go
src/pkg/syscall/ztypes_darwin_386.go
src/pkg/syscall/ztypes_darwin_amd64.go
src/pkg/syscall/ztypes_freebsd_386.go
src/pkg/syscall/ztypes_freebsd_amd64.go
src/pkg/syscall/ztypes_freebsd_arm.go
src/pkg/syscall/ztypes_linux_386.go
src/pkg/syscall/ztypes_linux_amd64.go
src/pkg/syscall/ztypes_linux_arm.go
src/pkg/syscall/ztypes_netbsd_386.go
src/pkg/syscall/ztypes_netbsd_amd64.go
src/pkg/syscall/ztypes_netbsd_arm.go
src/pkg/syscall/ztypes_openbsd_386.go
src/pkg/syscall/ztypes_openbsd_amd64.go

index 5a39d707bf865e47ef8d61297b66bd727afc0066..66cb690c7a30407f465d78435a55acbed7cef1e7 100755 (executable)
@@ -71,6 +71,7 @@ includes_Linux='
 #include <sys/prctl.h>
 #include <sys/stat.h>
 #include <sys/types.h>
+#include <sys/socket.h>
 #include <linux/if_addr.h>
 #include <linux/if_ether.h>
 #include <linux/if_tun.h>
@@ -80,6 +81,7 @@ includes_Linux='
 #include <linux/rtnetlink.h>
 #include <linux/ptrace.h>
 #include <linux/wait.h>
+#include <linux/icmpv6.h>
 #include <net/if.h>
 #include <net/if_arp.h>
 #include <net/route.h>
@@ -200,7 +202,8 @@ ccflags="$@"
                $2 ~ /^O[CNPFP][A-Z]+[^_][A-Z]+$/ ||
                $2 ~ /^IN_/ ||
                $2 ~ /^LOCK_(SH|EX|NB|UN)$/ ||
-               $2 ~ /^(AF|SOCK|SO|SOL|IPPROTO|IP|IPV6|TCP|EVFILT|NOTE|EV|SHUT|PROT|MAP|PACKET|MSG|SCM|MCL|DT|MADV|PR)_/ ||
+               $2 ~ /^(AF|SOCK|SO|SOL|IPPROTO|IP|IPV6|ICMP6|TCP|EVFILT|NOTE|EV|SHUT|PROT|MAP|PACKET|MSG|SCM|MCL|DT|MADV|PR)_/ ||
+               $2 == "ICMPV6_FILTER" ||
                $2 == "SOMAXCONN" ||
                $2 == "NAME_MAX" ||
                $2 == "IFNAMSIZ" ||
index 560409a26202af2a11c49e2b95b848fed5a64da4..3e7870a0a5429ba8f21ecf83802137a59a1ad250 100644 (file)
@@ -414,6 +414,20 @@ func GetsockoptIPv6Mreq(fd, level, opt int) (*IPv6Mreq, error) {
        return &value, err
 }
 
+func GetsockoptIPv6MTUInfo(fd, level, opt int) (*IPv6MTUInfo, error) {
+       var value IPv6MTUInfo
+       vallen := _Socklen(SizeofIPv6MTUInfo)
+       err := getsockopt(fd, level, opt, uintptr(unsafe.Pointer(&value)), &vallen)
+       return &value, err
+}
+
+func GetsockoptICMPv6Filter(fd, level, opt int) (*ICMPv6Filter, error) {
+       var value ICMPv6Filter
+       vallen := _Socklen(SizeofICMPv6Filter)
+       err := getsockopt(fd, level, opt, uintptr(unsafe.Pointer(&value)), &vallen)
+       return &value, err
+}
+
 func SetsockoptByte(fd, level, opt int, value byte) (err error) {
        var n = byte(value)
        return setsockopt(fd, level, opt, uintptr(unsafe.Pointer(&n)), 1)
@@ -444,6 +458,10 @@ func SetsockoptIPv6Mreq(fd, level, opt int, mreq *IPv6Mreq) (err error) {
        return setsockopt(fd, level, opt, uintptr(unsafe.Pointer(mreq)), unsafe.Sizeof(*mreq))
 }
 
+func SetsockoptICMPv6Filter(fd, level, opt int, filter *ICMPv6Filter) error {
+       return setsockopt(fd, level, opt, uintptr(unsafe.Pointer(filter)), SizeofICMPv6Filter)
+}
+
 func SetsockoptString(fd, level, opt int, s string) (err error) {
        return setsockopt(fd, level, opt, uintptr(unsafe.Pointer(&[]byte(s)[0])), uintptr(len(s)))
 }
index 4f458be73d8073e7acd3a54ce8c69da554c54438..391d80e5fba2109b0fa44190edfe8ef040418249 100644 (file)
@@ -540,6 +540,20 @@ func GetsockoptIPv6Mreq(fd, level, opt int) (*IPv6Mreq, error) {
        return &value, err
 }
 
+func GetsockoptIPv6MTUInfo(fd, level, opt int) (*IPv6MTUInfo, error) {
+       var value IPv6MTUInfo
+       vallen := _Socklen(SizeofIPv6MTUInfo)
+       err := getsockopt(fd, level, opt, uintptr(unsafe.Pointer(&value)), &vallen)
+       return &value, err
+}
+
+func GetsockoptICMPv6Filter(fd, level, opt int) (*ICMPv6Filter, error) {
+       var value ICMPv6Filter
+       vallen := _Socklen(SizeofICMPv6Filter)
+       err := getsockopt(fd, level, opt, uintptr(unsafe.Pointer(&value)), &vallen)
+       return &value, err
+}
+
 func GetsockoptUcred(fd, level, opt int) (*Ucred, error) {
        var value Ucred
        vallen := _Socklen(SizeofUcred)
@@ -576,6 +590,9 @@ func SetsockoptIPv6Mreq(fd, level, opt int, mreq *IPv6Mreq) (err error) {
        return setsockopt(fd, level, opt, uintptr(unsafe.Pointer(mreq)), unsafe.Sizeof(*mreq))
 }
 
+func SetsockoptICMPv6Filter(fd, level, opt int, filter *ICMPv6Filter) error {
+       return setsockopt(fd, level, opt, uintptr(unsafe.Pointer(filter)), SizeofICMPv6Filter)
+}
 func SetsockoptString(fd, level, opt int, s string) (err error) {
        return setsockopt(fd, level, opt, uintptr(unsafe.Pointer(&[]byte(s)[0])), uintptr(len(s)))
 }
index 098bbff6f2bea06e3b9b2fa3e0b3e1081d83231f..a043071f261aaf3db751904f49242f3b5ed4553a 100644 (file)
@@ -45,6 +45,7 @@ package syscall
 #include <net/if_var.h>
 #include <net/route.h>
 #include <netinet/in.h>
+#include <netinet/icmp6.h>
 #include <netinet/tcp.h>
 
 enum {
@@ -154,6 +155,10 @@ type Inet4Pktinfo C.struct_in_pktinfo
 
 type Inet6Pktinfo C.struct_in6_pktinfo
 
+type IPv6MTUInfo C.struct_ip6_mtuinfo
+
+type ICMPv6Filter C.struct_icmp6_filter
+
 const (
        SizeofSockaddrInet4    = C.sizeof_struct_sockaddr_in
        SizeofSockaddrInet6    = C.sizeof_struct_sockaddr_in6
@@ -167,6 +172,8 @@ const (
        SizeofCmsghdr          = C.sizeof_struct_cmsghdr
        SizeofInet4Pktinfo     = C.sizeof_struct_in_pktinfo
        SizeofInet6Pktinfo     = C.sizeof_struct_in6_pktinfo
+       SizeofIPv6MTUInfo      = C.sizeof_struct_ip6_mtuinfo
+       SizeofICMPv6Filter     = C.sizeof_struct_icmp6_filter
 )
 
 // Ptrace requests
index 7d4923d5a52709a1f06447ec3dbb899c5807fbfd..ccf53d0adfa51203eab92c396282ec93ff36c381 100644 (file)
@@ -39,6 +39,7 @@ package syscall
 #include <net/if_dl.h>
 #include <net/route.h>
 #include <netinet/in.h>
+#include <netinet/icmp6.h>
 #include <netinet/tcp.h>
 
 enum {
@@ -159,6 +160,10 @@ type Cmsghdr C.struct_cmsghdr
 
 type Inet6Pktinfo C.struct_in6_pktinfo
 
+type IPv6MTUInfo C.struct_ip6_mtuinfo
+
+type ICMPv6Filter C.struct_icmp6_filter
+
 const (
        SizeofSockaddrInet4    = C.sizeof_struct_sockaddr_in
        SizeofSockaddrInet6    = C.sizeof_struct_sockaddr_in6
@@ -172,6 +177,8 @@ const (
        SizeofMsghdr           = C.sizeof_struct_msghdr
        SizeofCmsghdr          = C.sizeof_struct_cmsghdr
        SizeofInet6Pktinfo     = C.sizeof_struct_in6_pktinfo
+       SizeofIPv6MTUInfo      = C.sizeof_struct_ip6_mtuinfo
+       SizeofICMPv6Filter     = C.sizeof_struct_icmp6_filter
 )
 
 // Ptrace requests
index 1514cbc9518f60d83ed87a2860f209042b4d6194..fea09d1d7fb72477779d0dff94318de17e07071d 100644 (file)
@@ -49,6 +49,7 @@ package syscall
 #include <linux/filter.h>
 #include <linux/netlink.h>
 #include <linux/rtnetlink.h>
+#include <linux/icmpv6.h>
 #include <termios.h>
 #include <time.h>
 #include <unistd.h>
@@ -193,6 +194,10 @@ type Inet4Pktinfo C.struct_in_pktinfo
 
 type Inet6Pktinfo C.struct_in6_pktinfo
 
+type IPv6MTUInfo C.struct_ip6_mtuinfo
+
+type ICMPv6Filter C.struct_icmp6_filter
+
 type Ucred C.struct_ucred
 
 type TCPInfo C.struct_tcp_info
@@ -212,6 +217,8 @@ const (
        SizeofCmsghdr           = C.sizeof_struct_cmsghdr
        SizeofInet4Pktinfo      = C.sizeof_struct_in_pktinfo
        SizeofInet6Pktinfo      = C.sizeof_struct_in6_pktinfo
+       SizeofIPv6MTUInfo       = C.sizeof_struct_ip6_mtuinfo
+       SizeofICMPv6Filter      = C.sizeof_struct_icmp6_filter
        SizeofUcred             = C.sizeof_struct_ucred
        SizeofTCPInfo           = C.sizeof_struct_tcp_info
 )
index 4906a99ef69ba409e0eca65d1c05ec68cd24ed61..badaa1049a0572f91d644bba0fa6440f1dbbd3ba 100644 (file)
@@ -41,6 +41,7 @@ package syscall
 #include <net/if_dl.h>
 #include <net/route.h>
 #include <netinet/in.h>
+#include <netinet/icmp6.h>
 #include <netinet/tcp.h>
 
 enum {
@@ -138,6 +139,10 @@ type Cmsghdr C.struct_cmsghdr
 
 type Inet6Pktinfo C.struct_in6_pktinfo
 
+type IPv6MTUInfo C.struct_ip6_mtuinfo
+
+type ICMPv6Filter C.struct_icmp6_filter
+
 const (
        SizeofSockaddrInet4    = C.sizeof_struct_sockaddr_in
        SizeofSockaddrInet6    = C.sizeof_struct_sockaddr_in6
@@ -150,6 +155,8 @@ const (
        SizeofMsghdr           = C.sizeof_struct_msghdr
        SizeofCmsghdr          = C.sizeof_struct_cmsghdr
        SizeofInet6Pktinfo     = C.sizeof_struct_in6_pktinfo
+       SizeofIPv6MTUInfo      = C.sizeof_struct_ip6_mtuinfo
+       SizeofICMPv6Filter     = C.sizeof_struct_icmp6_filter
 )
 
 // Ptrace requests
index 2430a166b412a7af60cda87eab3ab27e5827e91a..6fe2af6e0a9d6d1c78a2d4053cc7ab91ef78d25b 100644 (file)
@@ -40,6 +40,7 @@ package syscall
 #include <net/if_dl.h>
 #include <net/route.h>
 #include <netinet/in.h>
+#include <netinet/icmp6.h>
 #include <netinet/tcp.h>
 
 enum {
@@ -154,6 +155,10 @@ type Cmsghdr C.struct_cmsghdr
 
 type Inet6Pktinfo C.struct_in6_pktinfo
 
+type IPv6MTUInfo C.struct_ip6_mtuinfo
+
+type ICMPv6Filter C.struct_icmp6_filter
+
 const (
        SizeofSockaddrInet4    = C.sizeof_struct_sockaddr_in
        SizeofSockaddrInet6    = C.sizeof_struct_sockaddr_in6
@@ -166,6 +171,8 @@ const (
        SizeofMsghdr           = C.sizeof_struct_msghdr
        SizeofCmsghdr          = C.sizeof_struct_cmsghdr
        SizeofInet6Pktinfo     = C.sizeof_struct_in6_pktinfo
+       SizeofIPv6MTUInfo      = C.sizeof_struct_ip6_mtuinfo
+       SizeofICMPv6Filter     = C.sizeof_struct_icmp6_filter
 )
 
 // Ptrace requests
index cdb8605435b2c556b3755e717d2a07bdb97a7b0e..29e6190a92ee5b99b8699af87047d968ffa81353 100644 (file)
@@ -273,6 +273,7 @@ const (
        F_WRLCK                           = 0x3
        HUPCL                             = 0x4000
        ICANON                            = 0x100
+       ICMP6_FILTER                      = 0x12
        ICRNL                             = 0x100
        IEXTEN                            = 0x400
        IFF_ALLMULTI                      = 0x200
index 8ffcbcc04b09d4542231a2fc3425239b5881800b..db02b6a541380995eeffda272706a3243c071409 100644 (file)
@@ -273,6 +273,7 @@ const (
        F_WRLCK                           = 0x3
        HUPCL                             = 0x4000
        ICANON                            = 0x100
+       ICMP6_FILTER                      = 0x12
        ICRNL                             = 0x100
        IEXTEN                            = 0x400
        IFF_ALLMULTI                      = 0x200
index 04868736103abc391882a9db26e9acfdf4c8f2e4..55f255a54b827f6f11747880d3fb29848238c373 100644 (file)
@@ -461,6 +461,7 @@ const (
        F_WRLCK                           = 0x3
        HUPCL                             = 0x4000
        ICANON                            = 0x100
+       ICMP6_FILTER                      = 0x12
        ICRNL                             = 0x100
        IEXTEN                            = 0x400
        IFAN_ARRIVAL                      = 0x0
index a45d7f495a23d4c77efa4551e214812dca37ff44..ab92a94920b1ca6a7271ecd1cc01cc33e301a274 100644 (file)
@@ -461,6 +461,7 @@ const (
        F_WRLCK                           = 0x3
        HUPCL                             = 0x4000
        ICANON                            = 0x100
+       ICMP6_FILTER                      = 0x12
        ICRNL                             = 0x100
        IEXTEN                            = 0x400
        IFAN_ARRIVAL                      = 0x0
index 82f30abc5687427eccd9775fc4adb0a01766e51b..29d92be2ecdc7e321f1c01272cfb96717cce1967 100644 (file)
@@ -466,6 +466,7 @@ const (
        F_WRLCK                           = 0x3
        HUPCL                             = 0x4000
        ICANON                            = 0x100
+       ICMP6_FILTER                      = 0x12
        ICRNL                             = 0x100
        IEXTEN                            = 0x400
        IFAN_ARRIVAL                      = 0x0
index a689942b872dbc33ef8161ba8ef2b6c2a6652cb0..9510cccd6daa4a5edb402fb63a101a4d64c3d59c 100644 (file)
@@ -276,6 +276,7 @@ const (
        F_ULOCK                          = 0x0
        F_UNLCK                          = 0x2
        F_WRLCK                          = 0x1
+       ICMPV6_FILTER                    = 0x1
        IFA_F_DADFAILED                  = 0x8
        IFA_F_DEPRECATED                 = 0x20
        IFA_F_HOMEADDRESS                = 0x10
index a1ac1773b2fa2e3a9e7717ca497d0e79ac5f8172..7435155e2057491d1e5c0ed9c6d6c78c64d7f95c 100644 (file)
@@ -276,6 +276,7 @@ const (
        F_ULOCK                          = 0x0
        F_UNLCK                          = 0x2
        F_WRLCK                          = 0x1
+       ICMPV6_FILTER                    = 0x1
        IFA_F_DADFAILED                  = 0x8
        IFA_F_DEPRECATED                 = 0x20
        IFA_F_HOMEADDRESS                = 0x10
index 0730f2140d2f9f72150c471dfda70b6b244cbec9..fe54fe72d9d3669e9547e8e5e0de0977d00423f2 100644 (file)
@@ -274,6 +274,7 @@ const (
        F_ULOCK                          = 0x0
        F_UNLCK                          = 0x2
        F_WRLCK                          = 0x1
+       ICMPV6_FILTER                    = 0x1
        IFA_F_DADFAILED                  = 0x8
        IFA_F_DEPRECATED                 = 0x20
        IFA_F_HOMEADDRESS                = 0x10
index 68051f9f8af938f2ed8566a84ce79f0ba9bac685..c0ef19fdda4bfebf7b0a234dd50188f396417b3c 100644 (file)
@@ -570,6 +570,7 @@ const (
        F_WRLCK                           = 0x3
        HUPCL                             = 0x4000
        ICANON                            = 0x100
+       ICMP6_FILTER                      = 0x12
        ICRNL                             = 0x100
        IEXTEN                            = 0x400
        IFAN_ARRIVAL                      = 0x0
index f719528a7f1a761c7fe15e6266d6061f43bd0a0d..e4f5a903f4c942172bb24757971e955e5c0a9c0c 100644 (file)
@@ -560,6 +560,7 @@ const (
        F_WRLCK                           = 0x3
        HUPCL                             = 0x4000
        ICANON                            = 0x100
+       ICMP6_FILTER                      = 0x12
        ICRNL                             = 0x100
        IEXTEN                            = 0x400
        IFAN_ARRIVAL                      = 0x0
index 3899f6ba638a9f9515a4017d3e25bbe96b5dbb07..3264cef89dd3297cce48105e729480cf8762a7aa 100644 (file)
@@ -560,6 +560,7 @@ const (
        F_WRLCK                           = 0x3
        HUPCL                             = 0x4000
        ICANON                            = 0x100
+       ICMP6_FILTER                      = 0x12
        ICRNL                             = 0x100
        IEXTEN                            = 0x400
        IFAN_ARRIVAL                      = 0x0
index 5330d15b15005b75c79b763205ea112a4968aeb1..003958efaf836b4c95a2021754dc24941a19c31e 100644 (file)
@@ -439,6 +439,7 @@ const (
        F_WRLCK                           = 0x3
        HUPCL                             = 0x4000
        ICANON                            = 0x100
+       ICMP6_FILTER                      = 0x12
        ICRNL                             = 0x100
        IEXTEN                            = 0x400
        IFAN_ARRIVAL                      = 0x0
index 5a7edd341b8dd4c87503b9607d85e0790145bc01..7c53ceca69bea97ad9e16af79c7e948462e14d2c 100644 (file)
@@ -445,6 +445,7 @@ const (
        F_WRLCK                           = 0x3
        HUPCL                             = 0x4000
        ICANON                            = 0x100
+       ICMP6_FILTER                      = 0x12
        ICRNL                             = 0x100
        IEXTEN                            = 0x400
        IFAN_ARRIVAL                      = 0x0
index 71346fbc12d8b0dce0c3a2f1b3bf9a9107ac632a..13724c3cc6c99e53ad03c8ccd61170348eae1489 100644 (file)
@@ -237,6 +237,15 @@ type Inet6Pktinfo struct {
        Ifindex uint32
 }
 
+type IPv6MTUInfo struct {
+       Addr RawSockaddrInet6
+       Mtu  uint32
+}
+
+type ICMPv6Filter struct {
+       Filt [8]uint32
+}
+
 const (
        SizeofSockaddrInet4    = 0x10
        SizeofSockaddrInet6    = 0x1c
@@ -250,6 +259,8 @@ const (
        SizeofCmsghdr          = 0xc
        SizeofInet4Pktinfo     = 0xc
        SizeofInet6Pktinfo     = 0x14
+       SizeofIPv6MTUInfo      = 0x20
+       SizeofICMPv6Filter     = 0x20
 )
 
 const (
index f0809fe4ac42269a79ee7f4a20ea87fd614baa51..65b02ae4f56d7d754b9cf80ea9b270a2026b42ae 100644 (file)
@@ -245,6 +245,15 @@ type Inet6Pktinfo struct {
        Ifindex uint32
 }
 
+type IPv6MTUInfo struct {
+       Addr RawSockaddrInet6
+       Mtu  uint32
+}
+
+type ICMPv6Filter struct {
+       Filt [8]uint32
+}
+
 const (
        SizeofSockaddrInet4    = 0x10
        SizeofSockaddrInet6    = 0x1c
@@ -258,6 +267,8 @@ const (
        SizeofCmsghdr          = 0xc
        SizeofInet4Pktinfo     = 0xc
        SizeofInet6Pktinfo     = 0x14
+       SizeofIPv6MTUInfo      = 0x20
+       SizeofICMPv6Filter     = 0x20
 )
 
 const (
index 89de58e53fbce8fcb9eab371abd9feee87e25912..e77bd4b4139ccf27dea167b6087ca0bbff205319 100644 (file)
@@ -236,6 +236,15 @@ type Inet6Pktinfo struct {
        Ifindex uint32
 }
 
+type IPv6MTUInfo struct {
+       Addr RawSockaddrInet6
+       Mtu  uint32
+}
+
+type ICMPv6Filter struct {
+       Filt [8]uint32
+}
+
 const (
        SizeofSockaddrInet4    = 0x10
        SizeofSockaddrInet6    = 0x1c
@@ -249,6 +258,8 @@ const (
        SizeofMsghdr           = 0x1c
        SizeofCmsghdr          = 0xc
        SizeofInet6Pktinfo     = 0x14
+       SizeofIPv6MTUInfo      = 0x20
+       SizeofICMPv6Filter     = 0x20
 )
 
 const (
index d5e87682da41b0a2f92c3ef6c8947ebf2f3a5222..922de2ce50d0d4a9238fcfc09430192c306ba3dd 100644 (file)
@@ -238,6 +238,15 @@ type Inet6Pktinfo struct {
        Ifindex uint32
 }
 
+type IPv6MTUInfo struct {
+       Addr RawSockaddrInet6
+       Mtu  uint32
+}
+
+type ICMPv6Filter struct {
+       Filt [8]uint32
+}
+
 const (
        SizeofSockaddrInet4    = 0x10
        SizeofSockaddrInet6    = 0x1c
@@ -251,6 +260,8 @@ const (
        SizeofMsghdr           = 0x30
        SizeofCmsghdr          = 0xc
        SizeofInet6Pktinfo     = 0x14
+       SizeofIPv6MTUInfo      = 0x20
+       SizeofICMPv6Filter     = 0x20
 )
 
 const (
index 4f67a39e60893effdafabe1c4fb34642d780e4d4..b1bf83b4c11e9565693ef8656b7984aaba47f499 100644 (file)
@@ -238,6 +238,15 @@ type Inet6Pktinfo struct {
        Ifindex uint32
 }
 
+type IPv6MTUInfo struct {
+       Addr RawSockaddrInet6
+       Mtu  uint32
+}
+
+type ICMPv6Filter struct {
+       Filt [8]uint32
+}
+
 const (
        SizeofSockaddrInet4    = 0x10
        SizeofSockaddrInet6    = 0x1c
@@ -251,6 +260,8 @@ const (
        SizeofMsghdr           = 0x1c
        SizeofCmsghdr          = 0xc
        SizeofInet6Pktinfo     = 0x14
+       SizeofIPv6MTUInfo      = 0x20
+       SizeofICMPv6Filter     = 0x20
 )
 
 const (
index e1c30b64948ceaa118a9910d9a2fec0156011c09..9abd647acfeebd200e4a3a42c9a9b2af66a62f06 100644 (file)
@@ -245,6 +245,15 @@ type Inet6Pktinfo struct {
        Ifindex uint32
 }
 
+type IPv6MTUInfo struct {
+       Addr RawSockaddrInet6
+       Mtu  uint32
+}
+
+type ICMPv6Filter struct {
+       Data [8]uint32
+}
+
 type Ucred struct {
        Pid int32
        Uid uint32
@@ -300,6 +309,8 @@ const (
        SizeofCmsghdr           = 0xc
        SizeofInet4Pktinfo      = 0xc
        SizeofInet6Pktinfo      = 0x14
+       SizeofIPv6MTUInfo       = 0x20
+       SizeofICMPv6Filter      = 0x20
        SizeofUcred             = 0xc
        SizeofTCPInfo           = 0x68
 )
index 5800c3c6cbd7b7b8c351643bcbb8b9728d62f645..32da4e4b5cfa78dd2302dd47b44bb5c4dc0c59b7 100644 (file)
@@ -247,6 +247,15 @@ type Inet6Pktinfo struct {
        Ifindex uint32
 }
 
+type IPv6MTUInfo struct {
+       Addr RawSockaddrInet6
+       Mtu  uint32
+}
+
+type ICMPv6Filter struct {
+       Data [8]uint32
+}
+
 type Ucred struct {
        Pid int32
        Uid uint32
@@ -302,6 +311,8 @@ const (
        SizeofCmsghdr           = 0x10
        SizeofInet4Pktinfo      = 0xc
        SizeofInet6Pktinfo      = 0x14
+       SizeofIPv6MTUInfo       = 0x20
+       SizeofICMPv6Filter      = 0x20
        SizeofUcred             = 0xc
        SizeofTCPInfo           = 0x68
 )
index 4a81d340cf237a3d74b4453c2d8d868a4b511b50..4a918a8a72d0d40ebe25f6078a436247d6edb302 100644 (file)
@@ -247,6 +247,15 @@ type Inet6Pktinfo struct {
        Ifindex uint32
 }
 
+type IPv6MTUInfo struct {
+       Addr RawSockaddrInet6
+       Mtu  uint32
+}
+
+type ICMPv6Filter struct {
+       Data [8]uint32
+}
+
 type Ucred struct {
        Pid int32
        Uid uint32
@@ -302,6 +311,8 @@ const (
        SizeofCmsghdr           = 0xc
        SizeofInet4Pktinfo      = 0xc
        SizeofInet6Pktinfo      = 0x14
+       SizeofIPv6MTUInfo       = 0x20
+       SizeofICMPv6Filter      = 0x20
        SizeofUcred             = 0xc
        SizeofTCPInfo           = 0x68
 )
index dd9cf221a2305a78d10b56608862adf057abe376..59314bad28400356792747b707a4dd2f868801fd 100644 (file)
@@ -185,6 +185,15 @@ type Inet6Pktinfo struct {
        Ifindex uint32
 }
 
+type IPv6MTUInfo struct {
+       Addr RawSockaddrInet6
+       Mtu  uint32
+}
+
+type ICMPv6Filter struct {
+       Filt [8]uint32
+}
+
 const (
        SizeofSockaddrInet4    = 0x10
        SizeofSockaddrInet6    = 0x1c
@@ -197,6 +206,8 @@ const (
        SizeofMsghdr           = 0x1c
        SizeofCmsghdr          = 0xc
        SizeofInet6Pktinfo     = 0x14
+       SizeofIPv6MTUInfo      = 0x20
+       SizeofICMPv6Filter     = 0x20
 )
 
 const (
index 89d1ef8168d5795271d9adb5e0bfdb2c8ebaf086..a021a573876af842e1b260ff09ce946fe6c6d94d 100644 (file)
@@ -191,6 +191,15 @@ type Inet6Pktinfo struct {
        Ifindex uint32
 }
 
+type IPv6MTUInfo struct {
+       Addr RawSockaddrInet6
+       Mtu  uint32
+}
+
+type ICMPv6Filter struct {
+       Filt [8]uint32
+}
+
 const (
        SizeofSockaddrInet4    = 0x10
        SizeofSockaddrInet6    = 0x1c
@@ -203,6 +212,8 @@ const (
        SizeofMsghdr           = 0x30
        SizeofCmsghdr          = 0xc
        SizeofInet6Pktinfo     = 0x14
+       SizeofIPv6MTUInfo      = 0x20
+       SizeofICMPv6Filter     = 0x20
 )
 
 const (
index dd9cf221a2305a78d10b56608862adf057abe376..59314bad28400356792747b707a4dd2f868801fd 100644 (file)
@@ -185,6 +185,15 @@ type Inet6Pktinfo struct {
        Ifindex uint32
 }
 
+type IPv6MTUInfo struct {
+       Addr RawSockaddrInet6
+       Mtu  uint32
+}
+
+type ICMPv6Filter struct {
+       Filt [8]uint32
+}
+
 const (
        SizeofSockaddrInet4    = 0x10
        SizeofSockaddrInet6    = 0x1c
@@ -197,6 +206,8 @@ const (
        SizeofMsghdr           = 0x1c
        SizeofCmsghdr          = 0xc
        SizeofInet6Pktinfo     = 0x14
+       SizeofIPv6MTUInfo      = 0x20
+       SizeofICMPv6Filter     = 0x20
 )
 
 const (
index 528e92c85daa4fd2f449ec50b727e7907b795d4d..3c9cdf28bfd954598d576c90641be64908a6aec6 100644 (file)
@@ -226,6 +226,15 @@ type Inet6Pktinfo struct {
        Ifindex uint32
 }
 
+type IPv6MTUInfo struct {
+       Addr RawSockaddrInet6
+       Mtu  uint32
+}
+
+type ICMPv6Filter struct {
+       Filt [8]uint32
+}
+
 const (
        SizeofSockaddrInet4    = 0x10
        SizeofSockaddrInet6    = 0x1c
@@ -238,6 +247,8 @@ const (
        SizeofMsghdr           = 0x1c
        SizeofCmsghdr          = 0xc
        SizeofInet6Pktinfo     = 0x14
+       SizeofIPv6MTUInfo      = 0x20
+       SizeofICMPv6Filter     = 0x20
 )
 
 const (
index 4b93930540ac90530ff712f84f0a6c45d42f138a..3a0ac96fabf394a6df251a160d2a94abf4312964 100644 (file)
@@ -231,6 +231,15 @@ type Inet6Pktinfo struct {
        Ifindex uint32
 }
 
+type IPv6MTUInfo struct {
+       Addr RawSockaddrInet6
+       Mtu  uint32
+}
+
+type ICMPv6Filter struct {
+       Filt [8]uint32
+}
+
 const (
        SizeofSockaddrInet4    = 0x10
        SizeofSockaddrInet6    = 0x1c
@@ -243,6 +252,8 @@ const (
        SizeofMsghdr           = 0x30
        SizeofCmsghdr          = 0xc
        SizeofInet6Pktinfo     = 0x14
+       SizeofIPv6MTUInfo      = 0x20
+       SizeofICMPv6Filter     = 0x20
 )
 
 const (