1 // Code generated by GoVPP's binapi-generator. DO NOT EDIT.
3 // binapi-generator: v0.5.0-dev
5 // source: .vppapi/core/ipip.api.json
7 // Package ipip contains generated bindings for API file ipip.api.
24 api "git.fd.io/govpp.git/api"
25 codec "git.fd.io/govpp.git/codec"
28 // This is a compile-time assertion to ensure that this generated file
29 // is compatible with the GoVPP api package it is being compiled against.
30 // A compilation error at this line likely means your copy of the
31 // GoVPP api package needs to be updated.
32 const _ = api.GoVppAPIPackageIsVersion2
37 VersionCrc = 0xf108649c
40 // AddressFamily defines enum 'address_family'.
41 type AddressFamily uint32
44 ADDRESS_IP4 AddressFamily = 0
45 ADDRESS_IP6 AddressFamily = 1
49 AddressFamily_name = map[uint32]string{
53 AddressFamily_value = map[string]uint32{
59 func (x AddressFamily) String() string {
60 s, ok := AddressFamily_name[uint32(x)]
64 return "AddressFamily(" + strconv.Itoa(int(x)) + ")"
67 // IfStatusFlags defines enum 'if_status_flags'.
68 type IfStatusFlags uint32
71 IF_STATUS_API_FLAG_ADMIN_UP IfStatusFlags = 1
72 IF_STATUS_API_FLAG_LINK_UP IfStatusFlags = 2
76 IfStatusFlags_name = map[uint32]string{
77 1: "IF_STATUS_API_FLAG_ADMIN_UP",
78 2: "IF_STATUS_API_FLAG_LINK_UP",
80 IfStatusFlags_value = map[string]uint32{
81 "IF_STATUS_API_FLAG_ADMIN_UP": 1,
82 "IF_STATUS_API_FLAG_LINK_UP": 2,
86 func (x IfStatusFlags) String() string {
87 s, ok := IfStatusFlags_name[uint32(x)]
91 str := func(n uint32) string {
92 s, ok := IfStatusFlags_name[uint32(n)]
96 return "IfStatusFlags(" + strconv.Itoa(int(n)) + ")"
98 for i := uint32(0); i <= 32; i++ {
108 return str(uint32(x))
113 // IfType defines enum 'if_type'.
117 IF_API_TYPE_HARDWARE IfType = 1
118 IF_API_TYPE_SUB IfType = 2
119 IF_API_TYPE_P2P IfType = 3
120 IF_API_TYPE_PIPE IfType = 4
124 IfType_name = map[uint32]string{
125 1: "IF_API_TYPE_HARDWARE",
126 2: "IF_API_TYPE_SUB",
127 3: "IF_API_TYPE_P2P",
128 4: "IF_API_TYPE_PIPE",
130 IfType_value = map[string]uint32{
131 "IF_API_TYPE_HARDWARE": 1,
132 "IF_API_TYPE_SUB": 2,
133 "IF_API_TYPE_P2P": 3,
134 "IF_API_TYPE_PIPE": 4,
138 func (x IfType) String() string {
139 s, ok := IfType_name[uint32(x)]
143 return "IfType(" + strconv.Itoa(int(x)) + ")"
146 // IPDscp defines enum 'ip_dscp'.
150 IP_API_DSCP_CS0 IPDscp = 0
151 IP_API_DSCP_CS1 IPDscp = 8
152 IP_API_DSCP_AF11 IPDscp = 10
153 IP_API_DSCP_AF12 IPDscp = 12
154 IP_API_DSCP_AF13 IPDscp = 14
155 IP_API_DSCP_CS2 IPDscp = 16
156 IP_API_DSCP_AF21 IPDscp = 18
157 IP_API_DSCP_AF22 IPDscp = 20
158 IP_API_DSCP_AF23 IPDscp = 22
159 IP_API_DSCP_CS3 IPDscp = 24
160 IP_API_DSCP_AF31 IPDscp = 26
161 IP_API_DSCP_AF32 IPDscp = 28
162 IP_API_DSCP_AF33 IPDscp = 30
163 IP_API_DSCP_CS4 IPDscp = 32
164 IP_API_DSCP_AF41 IPDscp = 34
165 IP_API_DSCP_AF42 IPDscp = 36
166 IP_API_DSCP_AF43 IPDscp = 38
167 IP_API_DSCP_CS5 IPDscp = 40
168 IP_API_DSCP_EF IPDscp = 46
169 IP_API_DSCP_CS6 IPDscp = 48
170 IP_API_DSCP_CS7 IPDscp = 50
174 IPDscp_name = map[uint8]string{
175 0: "IP_API_DSCP_CS0",
176 8: "IP_API_DSCP_CS1",
177 10: "IP_API_DSCP_AF11",
178 12: "IP_API_DSCP_AF12",
179 14: "IP_API_DSCP_AF13",
180 16: "IP_API_DSCP_CS2",
181 18: "IP_API_DSCP_AF21",
182 20: "IP_API_DSCP_AF22",
183 22: "IP_API_DSCP_AF23",
184 24: "IP_API_DSCP_CS3",
185 26: "IP_API_DSCP_AF31",
186 28: "IP_API_DSCP_AF32",
187 30: "IP_API_DSCP_AF33",
188 32: "IP_API_DSCP_CS4",
189 34: "IP_API_DSCP_AF41",
190 36: "IP_API_DSCP_AF42",
191 38: "IP_API_DSCP_AF43",
192 40: "IP_API_DSCP_CS5",
193 46: "IP_API_DSCP_EF",
194 48: "IP_API_DSCP_CS6",
195 50: "IP_API_DSCP_CS7",
197 IPDscp_value = map[string]uint8{
198 "IP_API_DSCP_CS0": 0,
199 "IP_API_DSCP_CS1": 8,
200 "IP_API_DSCP_AF11": 10,
201 "IP_API_DSCP_AF12": 12,
202 "IP_API_DSCP_AF13": 14,
203 "IP_API_DSCP_CS2": 16,
204 "IP_API_DSCP_AF21": 18,
205 "IP_API_DSCP_AF22": 20,
206 "IP_API_DSCP_AF23": 22,
207 "IP_API_DSCP_CS3": 24,
208 "IP_API_DSCP_AF31": 26,
209 "IP_API_DSCP_AF32": 28,
210 "IP_API_DSCP_AF33": 30,
211 "IP_API_DSCP_CS4": 32,
212 "IP_API_DSCP_AF41": 34,
213 "IP_API_DSCP_AF42": 36,
214 "IP_API_DSCP_AF43": 38,
215 "IP_API_DSCP_CS5": 40,
216 "IP_API_DSCP_EF": 46,
217 "IP_API_DSCP_CS6": 48,
218 "IP_API_DSCP_CS7": 50,
222 func (x IPDscp) String() string {
223 s, ok := IPDscp_name[uint8(x)]
227 return "IPDscp(" + strconv.Itoa(int(x)) + ")"
230 // IPEcn defines enum 'ip_ecn'.
234 IP_API_ECN_NONE IPEcn = 0
235 IP_API_ECN_ECT0 IPEcn = 1
236 IP_API_ECN_ECT1 IPEcn = 2
237 IP_API_ECN_CE IPEcn = 3
241 IPEcn_name = map[uint8]string{
242 0: "IP_API_ECN_NONE",
243 1: "IP_API_ECN_ECT0",
244 2: "IP_API_ECN_ECT1",
247 IPEcn_value = map[string]uint8{
248 "IP_API_ECN_NONE": 0,
249 "IP_API_ECN_ECT0": 1,
250 "IP_API_ECN_ECT1": 2,
255 func (x IPEcn) String() string {
256 s, ok := IPEcn_name[uint8(x)]
260 return "IPEcn(" + strconv.Itoa(int(x)) + ")"
263 // IPProto defines enum 'ip_proto'.
267 IP_API_PROTO_HOPOPT IPProto = 0
268 IP_API_PROTO_ICMP IPProto = 1
269 IP_API_PROTO_IGMP IPProto = 2
270 IP_API_PROTO_TCP IPProto = 6
271 IP_API_PROTO_UDP IPProto = 17
272 IP_API_PROTO_GRE IPProto = 47
273 IP_API_PROTO_AH IPProto = 50
274 IP_API_PROTO_ESP IPProto = 51
275 IP_API_PROTO_EIGRP IPProto = 88
276 IP_API_PROTO_OSPF IPProto = 89
277 IP_API_PROTO_SCTP IPProto = 132
278 IP_API_PROTO_RESERVED IPProto = 255
282 IPProto_name = map[uint32]string{
283 0: "IP_API_PROTO_HOPOPT",
284 1: "IP_API_PROTO_ICMP",
285 2: "IP_API_PROTO_IGMP",
286 6: "IP_API_PROTO_TCP",
287 17: "IP_API_PROTO_UDP",
288 47: "IP_API_PROTO_GRE",
289 50: "IP_API_PROTO_AH",
290 51: "IP_API_PROTO_ESP",
291 88: "IP_API_PROTO_EIGRP",
292 89: "IP_API_PROTO_OSPF",
293 132: "IP_API_PROTO_SCTP",
294 255: "IP_API_PROTO_RESERVED",
296 IPProto_value = map[string]uint32{
297 "IP_API_PROTO_HOPOPT": 0,
298 "IP_API_PROTO_ICMP": 1,
299 "IP_API_PROTO_IGMP": 2,
300 "IP_API_PROTO_TCP": 6,
301 "IP_API_PROTO_UDP": 17,
302 "IP_API_PROTO_GRE": 47,
303 "IP_API_PROTO_AH": 50,
304 "IP_API_PROTO_ESP": 51,
305 "IP_API_PROTO_EIGRP": 88,
306 "IP_API_PROTO_OSPF": 89,
307 "IP_API_PROTO_SCTP": 132,
308 "IP_API_PROTO_RESERVED": 255,
312 func (x IPProto) String() string {
313 s, ok := IPProto_name[uint32(x)]
317 return "IPProto(" + strconv.Itoa(int(x)) + ")"
320 // IpipTunnelFlags defines enum 'ipip_tunnel_flags'.
321 type IpipTunnelFlags uint8
324 IPIP_TUNNEL_API_FLAG_NONE IpipTunnelFlags = 0
325 IPIP_TUNNEL_API_FLAG_ENCAP_COPY_DF IpipTunnelFlags = 1
326 IPIP_TUNNEL_API_FLAG_ENCAP_SET_DF IpipTunnelFlags = 2
327 IPIP_TUNNEL_API_FLAG_ENCAP_COPY_DSCP IpipTunnelFlags = 4
328 IPIP_TUNNEL_API_FLAG_ENCAP_COPY_ECN IpipTunnelFlags = 8
329 IPIP_TUNNEL_API_FLAG_DECAP_COPY_ECN IpipTunnelFlags = 16
333 IpipTunnelFlags_name = map[uint8]string{
334 0: "IPIP_TUNNEL_API_FLAG_NONE",
335 1: "IPIP_TUNNEL_API_FLAG_ENCAP_COPY_DF",
336 2: "IPIP_TUNNEL_API_FLAG_ENCAP_SET_DF",
337 4: "IPIP_TUNNEL_API_FLAG_ENCAP_COPY_DSCP",
338 8: "IPIP_TUNNEL_API_FLAG_ENCAP_COPY_ECN",
339 16: "IPIP_TUNNEL_API_FLAG_DECAP_COPY_ECN",
341 IpipTunnelFlags_value = map[string]uint8{
342 "IPIP_TUNNEL_API_FLAG_NONE": 0,
343 "IPIP_TUNNEL_API_FLAG_ENCAP_COPY_DF": 1,
344 "IPIP_TUNNEL_API_FLAG_ENCAP_SET_DF": 2,
345 "IPIP_TUNNEL_API_FLAG_ENCAP_COPY_DSCP": 4,
346 "IPIP_TUNNEL_API_FLAG_ENCAP_COPY_ECN": 8,
347 "IPIP_TUNNEL_API_FLAG_DECAP_COPY_ECN": 16,
351 func (x IpipTunnelFlags) String() string {
352 s, ok := IpipTunnelFlags_name[uint8(x)]
356 str := func(n uint8) string {
357 s, ok := IpipTunnelFlags_name[uint8(n)]
361 return "IpipTunnelFlags(" + strconv.Itoa(int(n)) + ")"
363 for i := uint8(0); i <= 8; i++ {
378 // LinkDuplex defines enum 'link_duplex'.
379 type LinkDuplex uint32
382 LINK_DUPLEX_API_UNKNOWN LinkDuplex = 0
383 LINK_DUPLEX_API_HALF LinkDuplex = 1
384 LINK_DUPLEX_API_FULL LinkDuplex = 2
388 LinkDuplex_name = map[uint32]string{
389 0: "LINK_DUPLEX_API_UNKNOWN",
390 1: "LINK_DUPLEX_API_HALF",
391 2: "LINK_DUPLEX_API_FULL",
393 LinkDuplex_value = map[string]uint32{
394 "LINK_DUPLEX_API_UNKNOWN": 0,
395 "LINK_DUPLEX_API_HALF": 1,
396 "LINK_DUPLEX_API_FULL": 2,
400 func (x LinkDuplex) String() string {
401 s, ok := LinkDuplex_name[uint32(x)]
405 return "LinkDuplex(" + strconv.Itoa(int(x)) + ")"
408 // MtuProto defines enum 'mtu_proto'.
412 MTU_PROTO_API_L3 MtuProto = 1
413 MTU_PROTO_API_IP4 MtuProto = 2
414 MTU_PROTO_API_IP6 MtuProto = 3
415 MTU_PROTO_API_MPLS MtuProto = 4
416 MTU_PROTO_API_N MtuProto = 5
420 MtuProto_name = map[uint32]string{
421 1: "MTU_PROTO_API_L3",
422 2: "MTU_PROTO_API_IP4",
423 3: "MTU_PROTO_API_IP6",
424 4: "MTU_PROTO_API_MPLS",
425 5: "MTU_PROTO_API_N",
427 MtuProto_value = map[string]uint32{
428 "MTU_PROTO_API_L3": 1,
429 "MTU_PROTO_API_IP4": 2,
430 "MTU_PROTO_API_IP6": 3,
431 "MTU_PROTO_API_MPLS": 4,
432 "MTU_PROTO_API_N": 5,
436 func (x MtuProto) String() string {
437 s, ok := MtuProto_name[uint32(x)]
441 return "MtuProto(" + strconv.Itoa(int(x)) + ")"
444 // RxMode defines enum 'rx_mode'.
448 RX_MODE_API_UNKNOWN RxMode = 0
449 RX_MODE_API_POLLING RxMode = 1
450 RX_MODE_API_INTERRUPT RxMode = 2
451 RX_MODE_API_ADAPTIVE RxMode = 3
452 RX_MODE_API_DEFAULT RxMode = 4
456 RxMode_name = map[uint32]string{
457 0: "RX_MODE_API_UNKNOWN",
458 1: "RX_MODE_API_POLLING",
459 2: "RX_MODE_API_INTERRUPT",
460 3: "RX_MODE_API_ADAPTIVE",
461 4: "RX_MODE_API_DEFAULT",
463 RxMode_value = map[string]uint32{
464 "RX_MODE_API_UNKNOWN": 0,
465 "RX_MODE_API_POLLING": 1,
466 "RX_MODE_API_INTERRUPT": 2,
467 "RX_MODE_API_ADAPTIVE": 3,
468 "RX_MODE_API_DEFAULT": 4,
472 func (x RxMode) String() string {
473 s, ok := RxMode_name[uint32(x)]
477 return "RxMode(" + strconv.Itoa(int(x)) + ")"
480 // SubIfFlags defines enum 'sub_if_flags'.
481 type SubIfFlags uint32
484 SUB_IF_API_FLAG_NO_TAGS SubIfFlags = 1
485 SUB_IF_API_FLAG_ONE_TAG SubIfFlags = 2
486 SUB_IF_API_FLAG_TWO_TAGS SubIfFlags = 4
487 SUB_IF_API_FLAG_DOT1AD SubIfFlags = 8
488 SUB_IF_API_FLAG_EXACT_MATCH SubIfFlags = 16
489 SUB_IF_API_FLAG_DEFAULT SubIfFlags = 32
490 SUB_IF_API_FLAG_OUTER_VLAN_ID_ANY SubIfFlags = 64
491 SUB_IF_API_FLAG_INNER_VLAN_ID_ANY SubIfFlags = 128
492 SUB_IF_API_FLAG_MASK_VNET SubIfFlags = 254
493 SUB_IF_API_FLAG_DOT1AH SubIfFlags = 256
497 SubIfFlags_name = map[uint32]string{
498 1: "SUB_IF_API_FLAG_NO_TAGS",
499 2: "SUB_IF_API_FLAG_ONE_TAG",
500 4: "SUB_IF_API_FLAG_TWO_TAGS",
501 8: "SUB_IF_API_FLAG_DOT1AD",
502 16: "SUB_IF_API_FLAG_EXACT_MATCH",
503 32: "SUB_IF_API_FLAG_DEFAULT",
504 64: "SUB_IF_API_FLAG_OUTER_VLAN_ID_ANY",
505 128: "SUB_IF_API_FLAG_INNER_VLAN_ID_ANY",
506 254: "SUB_IF_API_FLAG_MASK_VNET",
507 256: "SUB_IF_API_FLAG_DOT1AH",
509 SubIfFlags_value = map[string]uint32{
510 "SUB_IF_API_FLAG_NO_TAGS": 1,
511 "SUB_IF_API_FLAG_ONE_TAG": 2,
512 "SUB_IF_API_FLAG_TWO_TAGS": 4,
513 "SUB_IF_API_FLAG_DOT1AD": 8,
514 "SUB_IF_API_FLAG_EXACT_MATCH": 16,
515 "SUB_IF_API_FLAG_DEFAULT": 32,
516 "SUB_IF_API_FLAG_OUTER_VLAN_ID_ANY": 64,
517 "SUB_IF_API_FLAG_INNER_VLAN_ID_ANY": 128,
518 "SUB_IF_API_FLAG_MASK_VNET": 254,
519 "SUB_IF_API_FLAG_DOT1AH": 256,
523 func (x SubIfFlags) String() string {
524 s, ok := SubIfFlags_name[uint32(x)]
528 str := func(n uint32) string {
529 s, ok := SubIfFlags_name[uint32(n)]
533 return "SubIfFlags(" + strconv.Itoa(int(n)) + ")"
535 for i := uint32(0); i <= 32; i++ {
545 return str(uint32(x))
550 // AddressWithPrefix defines alias 'address_with_prefix'.
551 type AddressWithPrefix Prefix
553 func ParseAddressWithPrefix(s string) (AddressWithPrefix, error) {
554 prefix, err := ParsePrefix(s)
556 return AddressWithPrefix{}, err
558 return AddressWithPrefix(prefix), nil
561 func (x AddressWithPrefix) String() string {
562 return Prefix(x).String()
565 func (x *AddressWithPrefix) MarshalText() ([]byte, error) {
566 return []byte(x.String()), nil
569 func (x *AddressWithPrefix) UnmarshalText(text []byte) error {
570 prefix, err := ParseAddressWithPrefix(string(text))
578 // InterfaceIndex defines alias 'interface_index'.
579 type InterfaceIndex uint32
581 // IP4Address defines alias 'ip4_address'.
582 type IP4Address [4]uint8
584 func ParseIP4Address(s string) (IP4Address, error) {
585 ip := net.ParseIP(s).To4()
587 return IP4Address{}, fmt.Errorf("invalid IP address: %s", s)
589 var ipaddr IP4Address
590 copy(ipaddr[:], ip.To4())
594 func (x IP4Address) ToIP() net.IP {
595 return net.IP(x[:]).To4()
598 func (x IP4Address) String() string {
599 return x.ToIP().String()
602 func (x *IP4Address) MarshalText() ([]byte, error) {
603 return []byte(x.String()), nil
606 func (x *IP4Address) UnmarshalText(text []byte) error {
607 ipaddr, err := ParseIP4Address(string(text))
615 // IP4AddressWithPrefix defines alias 'ip4_address_with_prefix'.
616 type IP4AddressWithPrefix IP4Prefix
618 // IP6Address defines alias 'ip6_address'.
619 type IP6Address [16]uint8
621 func ParseIP6Address(s string) (IP6Address, error) {
622 ip := net.ParseIP(s).To16()
624 return IP6Address{}, fmt.Errorf("invalid IP address: %s", s)
626 var ipaddr IP6Address
627 copy(ipaddr[:], ip.To16())
631 func (x IP6Address) ToIP() net.IP {
632 return net.IP(x[:]).To16()
635 func (x IP6Address) String() string {
636 return x.ToIP().String()
639 func (x *IP6Address) MarshalText() ([]byte, error) {
640 return []byte(x.String()), nil
643 func (x *IP6Address) UnmarshalText(text []byte) error {
644 ipaddr, err := ParseIP6Address(string(text))
652 // IP6AddressWithPrefix defines alias 'ip6_address_with_prefix'.
653 type IP6AddressWithPrefix IP6Prefix
655 // Address defines type 'address'.
656 type Address struct {
657 Af AddressFamily `binapi:"address_family,name=af" json:"af,omitempty"`
658 Un AddressUnion `binapi:"address_union,name=un" json:"un,omitempty"`
661 func ParseAddress(s string) (Address, error) {
664 return Address{}, fmt.Errorf("invalid address: %s", s)
666 return AddressFromIP(ip), nil
669 func AddressFromIP(ip net.IP) Address {
672 addr.Af = ADDRESS_IP6
674 copy(ip6[:], ip.To16())
677 addr.Af = ADDRESS_IP4
679 copy(ip4[:], ip.To4())
685 func (x Address) ToIP() net.IP {
686 if x.Af == ADDRESS_IP6 {
688 return net.IP(ip6[:]).To16()
691 return net.IP(ip4[:]).To4()
695 func (x Address) String() string {
696 return x.ToIP().String()
699 func (x *Address) MarshalText() ([]byte, error) {
700 return []byte(x.String()), nil
703 func (x *Address) UnmarshalText(text []byte) error {
704 addr, err := ParseAddress(string(text))
712 // IP4Prefix defines type 'ip4_prefix'.
713 type IP4Prefix struct {
714 Address IP4Address `binapi:"ip4_address,name=address" json:"address,omitempty"`
715 Len uint8 `binapi:"u8,name=len" json:"len,omitempty"`
718 func ParseIP4Prefix(s string) (prefix IP4Prefix, err error) {
719 hasPrefix := strings.Contains(s, "/")
721 ip, network, err := net.ParseCIDR(s)
723 return IP4Prefix{}, fmt.Errorf("invalid IP %s: %s", s, err)
725 maskSize, _ := network.Mask.Size()
726 prefix.Len = byte(maskSize)
727 prefix.Address, err = ParseIP4Address(ip.String())
729 return IP4Prefix{}, fmt.Errorf("invalid IP %s: %s", s, err)
733 defaultMaskSize, _ := net.CIDRMask(32, 32).Size()
735 defaultMaskSize, _ = net.CIDRMask(128, 128).Size()
737 prefix.Len = byte(defaultMaskSize)
738 prefix.Address, err = ParseIP4Address(ip.String())
740 return IP4Prefix{}, fmt.Errorf("invalid IP %s: %s", s, err)
746 func (x IP4Prefix) ToIPNet() *net.IPNet {
747 mask := net.CIDRMask(int(x.Len), 32)
748 ipnet := &net.IPNet{IP: x.Address.ToIP(), Mask: mask}
752 func (x IP4Prefix) String() string {
753 ip := x.Address.String()
754 return ip + "/" + strconv.Itoa(int(x.Len))
757 func (x *IP4Prefix) MarshalText() ([]byte, error) {
758 return []byte(x.String()), nil
761 func (x *IP4Prefix) UnmarshalText(text []byte) error {
762 prefix, err := ParseIP4Prefix(string(text))
770 // IP6Prefix defines type 'ip6_prefix'.
771 type IP6Prefix struct {
772 Address IP6Address `binapi:"ip6_address,name=address" json:"address,omitempty"`
773 Len uint8 `binapi:"u8,name=len" json:"len,omitempty"`
776 func ParseIP6Prefix(s string) (prefix IP6Prefix, err error) {
777 hasPrefix := strings.Contains(s, "/")
779 ip, network, err := net.ParseCIDR(s)
781 return IP6Prefix{}, fmt.Errorf("invalid IP %s: %s", s, err)
783 maskSize, _ := network.Mask.Size()
784 prefix.Len = byte(maskSize)
785 prefix.Address, err = ParseIP6Address(ip.String())
787 return IP6Prefix{}, fmt.Errorf("invalid IP %s: %s", s, err)
791 defaultMaskSize, _ := net.CIDRMask(32, 32).Size()
793 defaultMaskSize, _ = net.CIDRMask(128, 128).Size()
795 prefix.Len = byte(defaultMaskSize)
796 prefix.Address, err = ParseIP6Address(ip.String())
798 return IP6Prefix{}, fmt.Errorf("invalid IP %s: %s", s, err)
804 func (x IP6Prefix) ToIPNet() *net.IPNet {
805 mask := net.CIDRMask(int(x.Len), 128)
806 ipnet := &net.IPNet{IP: x.Address.ToIP(), Mask: mask}
810 func (x IP6Prefix) String() string {
811 ip := x.Address.String()
812 return ip + "/" + strconv.Itoa(int(x.Len))
815 func (x *IP6Prefix) MarshalText() ([]byte, error) {
816 return []byte(x.String()), nil
819 func (x *IP6Prefix) UnmarshalText(text []byte) error {
820 prefix, err := ParseIP6Prefix(string(text))
828 // IpipTunnel defines type 'ipip_tunnel'.
829 type IpipTunnel struct {
830 Instance uint32 `binapi:"u32,name=instance" json:"instance,omitempty"`
831 Src Address `binapi:"address,name=src" json:"src,omitempty"`
832 Dst Address `binapi:"address,name=dst" json:"dst,omitempty"`
833 SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
834 TableID uint32 `binapi:"u32,name=table_id" json:"table_id,omitempty"`
835 Flags IpipTunnelFlags `binapi:"ipip_tunnel_flags,name=flags" json:"flags,omitempty"`
836 Dscp IPDscp `binapi:"ip_dscp,name=dscp" json:"dscp,omitempty"`
839 // Mprefix defines type 'mprefix'.
840 type Mprefix struct {
841 Af AddressFamily `binapi:"address_family,name=af" json:"af,omitempty"`
842 GrpAddressLength uint16 `binapi:"u16,name=grp_address_length" json:"grp_address_length,omitempty"`
843 GrpAddress AddressUnion `binapi:"address_union,name=grp_address" json:"grp_address,omitempty"`
844 SrcAddress AddressUnion `binapi:"address_union,name=src_address" json:"src_address,omitempty"`
847 // Prefix defines type 'prefix'.
849 Address Address `binapi:"address,name=address" json:"address,omitempty"`
850 Len uint8 `binapi:"u8,name=len" json:"len,omitempty"`
853 func ParsePrefix(ip string) (prefix Prefix, err error) {
854 hasPrefix := strings.Contains(ip, "/")
856 netIP, network, err := net.ParseCIDR(ip)
858 return Prefix{}, fmt.Errorf("invalid IP %s: %s", ip, err)
860 maskSize, _ := network.Mask.Size()
861 prefix.Len = byte(maskSize)
862 prefix.Address, err = ParseAddress(netIP.String())
864 return Prefix{}, fmt.Errorf("invalid IP %s: %s", ip, err)
867 netIP := net.ParseIP(ip)
868 defaultMaskSize, _ := net.CIDRMask(32, 32).Size()
869 if netIP.To4() == nil {
870 defaultMaskSize, _ = net.CIDRMask(128, 128).Size()
872 prefix.Len = byte(defaultMaskSize)
873 prefix.Address, err = ParseAddress(netIP.String())
875 return Prefix{}, fmt.Errorf("invalid IP %s: %s", ip, err)
881 func (x Prefix) ToIPNet() *net.IPNet {
883 if x.Address.Af == ADDRESS_IP4 {
884 mask = net.CIDRMask(int(x.Len), 32)
886 mask = net.CIDRMask(int(x.Len), 128)
888 ipnet := &net.IPNet{IP: x.Address.ToIP(), Mask: mask}
892 func (x Prefix) String() string {
893 ip := x.Address.String()
894 return ip + "/" + strconv.Itoa(int(x.Len))
897 func (x *Prefix) MarshalText() ([]byte, error) {
898 return []byte(x.String()), nil
901 func (x *Prefix) UnmarshalText(text []byte) error {
902 prefix, err := ParsePrefix(string(text))
910 // PrefixMatcher defines type 'prefix_matcher'.
911 type PrefixMatcher struct {
912 Le uint8 `binapi:"u8,name=le" json:"le,omitempty"`
913 Ge uint8 `binapi:"u8,name=ge" json:"ge,omitempty"`
916 // AddressUnion defines union 'address_union'.
917 type AddressUnion struct {
918 // AddressUnion can be one of:
921 XXX_UnionData [16]byte
924 func AddressUnionIP4(a IP4Address) (u AddressUnion) {
928 func (u *AddressUnion) SetIP4(a IP4Address) {
929 buf := codec.NewBuffer(u.XXX_UnionData[:])
930 buf.EncodeBytes(a[:], 4)
932 func (u *AddressUnion) GetIP4() (a IP4Address) {
933 buf := codec.NewBuffer(u.XXX_UnionData[:])
934 copy(a[:], buf.DecodeBytes(4))
938 func AddressUnionIP6(a IP6Address) (u AddressUnion) {
942 func (u *AddressUnion) SetIP6(a IP6Address) {
943 buf := codec.NewBuffer(u.XXX_UnionData[:])
944 buf.EncodeBytes(a[:], 16)
946 func (u *AddressUnion) GetIP6() (a IP6Address) {
947 buf := codec.NewBuffer(u.XXX_UnionData[:])
948 copy(a[:], buf.DecodeBytes(16))
952 // Ipip6rdAddTunnel defines message 'ipip_6rd_add_tunnel'.
953 type Ipip6rdAddTunnel struct {
954 IP6TableID uint32 `binapi:"u32,name=ip6_table_id" json:"ip6_table_id,omitempty"`
955 IP4TableID uint32 `binapi:"u32,name=ip4_table_id" json:"ip4_table_id,omitempty"`
956 IP6Prefix IP6Prefix `binapi:"ip6_prefix,name=ip6_prefix" json:"ip6_prefix,omitempty"`
957 IP4Prefix IP4Prefix `binapi:"ip4_prefix,name=ip4_prefix" json:"ip4_prefix,omitempty"`
958 IP4Src IP4Address `binapi:"ip4_address,name=ip4_src" json:"ip4_src,omitempty"`
959 SecurityCheck bool `binapi:"bool,name=security_check" json:"security_check,omitempty"`
960 TcTos uint8 `binapi:"u8,name=tc_tos" json:"tc_tos,omitempty"`
963 func (m *Ipip6rdAddTunnel) Reset() { *m = Ipip6rdAddTunnel{} }
964 func (*Ipip6rdAddTunnel) GetMessageName() string { return "ipip_6rd_add_tunnel" }
965 func (*Ipip6rdAddTunnel) GetCrcString() string { return "56e93cc0" }
966 func (*Ipip6rdAddTunnel) GetMessageType() api.MessageType {
967 return api.RequestMessage
970 func (m *Ipip6rdAddTunnel) Size() (size int) {
974 size += 4 // m.IP6TableID
975 size += 4 // m.IP4TableID
976 size += 1 * 16 // m.IP6Prefix.Address
977 size += 1 // m.IP6Prefix.Len
978 size += 1 * 4 // m.IP4Prefix.Address
979 size += 1 // m.IP4Prefix.Len
980 size += 1 * 4 // m.IP4Src
981 size += 1 // m.SecurityCheck
985 func (m *Ipip6rdAddTunnel) Marshal(b []byte) ([]byte, error) {
987 b = make([]byte, m.Size())
989 buf := codec.NewBuffer(b)
990 buf.EncodeUint32(m.IP6TableID)
991 buf.EncodeUint32(m.IP4TableID)
992 buf.EncodeBytes(m.IP6Prefix.Address[:], 16)
993 buf.EncodeUint8(m.IP6Prefix.Len)
994 buf.EncodeBytes(m.IP4Prefix.Address[:], 4)
995 buf.EncodeUint8(m.IP4Prefix.Len)
996 buf.EncodeBytes(m.IP4Src[:], 4)
997 buf.EncodeBool(m.SecurityCheck)
998 buf.EncodeUint8(m.TcTos)
999 return buf.Bytes(), nil
1001 func (m *Ipip6rdAddTunnel) Unmarshal(b []byte) error {
1002 buf := codec.NewBuffer(b)
1003 m.IP6TableID = buf.DecodeUint32()
1004 m.IP4TableID = buf.DecodeUint32()
1005 copy(m.IP6Prefix.Address[:], buf.DecodeBytes(16))
1006 m.IP6Prefix.Len = buf.DecodeUint8()
1007 copy(m.IP4Prefix.Address[:], buf.DecodeBytes(4))
1008 m.IP4Prefix.Len = buf.DecodeUint8()
1009 copy(m.IP4Src[:], buf.DecodeBytes(4))
1010 m.SecurityCheck = buf.DecodeBool()
1011 m.TcTos = buf.DecodeUint8()
1015 // Ipip6rdAddTunnelReply defines message 'ipip_6rd_add_tunnel_reply'.
1016 type Ipip6rdAddTunnelReply struct {
1017 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1018 SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1021 func (m *Ipip6rdAddTunnelReply) Reset() { *m = Ipip6rdAddTunnelReply{} }
1022 func (*Ipip6rdAddTunnelReply) GetMessageName() string { return "ipip_6rd_add_tunnel_reply" }
1023 func (*Ipip6rdAddTunnelReply) GetCrcString() string { return "5383d31f" }
1024 func (*Ipip6rdAddTunnelReply) GetMessageType() api.MessageType {
1025 return api.ReplyMessage
1028 func (m *Ipip6rdAddTunnelReply) Size() (size int) {
1032 size += 4 // m.Retval
1033 size += 4 // m.SwIfIndex
1036 func (m *Ipip6rdAddTunnelReply) Marshal(b []byte) ([]byte, error) {
1038 b = make([]byte, m.Size())
1040 buf := codec.NewBuffer(b)
1041 buf.EncodeInt32(m.Retval)
1042 buf.EncodeUint32(uint32(m.SwIfIndex))
1043 return buf.Bytes(), nil
1045 func (m *Ipip6rdAddTunnelReply) Unmarshal(b []byte) error {
1046 buf := codec.NewBuffer(b)
1047 m.Retval = buf.DecodeInt32()
1048 m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
1052 // Ipip6rdDelTunnel defines message 'ipip_6rd_del_tunnel'.
1053 type Ipip6rdDelTunnel struct {
1054 SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1057 func (m *Ipip6rdDelTunnel) Reset() { *m = Ipip6rdDelTunnel{} }
1058 func (*Ipip6rdDelTunnel) GetMessageName() string { return "ipip_6rd_del_tunnel" }
1059 func (*Ipip6rdDelTunnel) GetCrcString() string { return "f9e6675e" }
1060 func (*Ipip6rdDelTunnel) GetMessageType() api.MessageType {
1061 return api.RequestMessage
1064 func (m *Ipip6rdDelTunnel) Size() (size int) {
1068 size += 4 // m.SwIfIndex
1071 func (m *Ipip6rdDelTunnel) Marshal(b []byte) ([]byte, error) {
1073 b = make([]byte, m.Size())
1075 buf := codec.NewBuffer(b)
1076 buf.EncodeUint32(uint32(m.SwIfIndex))
1077 return buf.Bytes(), nil
1079 func (m *Ipip6rdDelTunnel) Unmarshal(b []byte) error {
1080 buf := codec.NewBuffer(b)
1081 m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
1085 // Ipip6rdDelTunnelReply defines message 'ipip_6rd_del_tunnel_reply'.
1086 type Ipip6rdDelTunnelReply struct {
1087 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1090 func (m *Ipip6rdDelTunnelReply) Reset() { *m = Ipip6rdDelTunnelReply{} }
1091 func (*Ipip6rdDelTunnelReply) GetMessageName() string { return "ipip_6rd_del_tunnel_reply" }
1092 func (*Ipip6rdDelTunnelReply) GetCrcString() string { return "e8d4e804" }
1093 func (*Ipip6rdDelTunnelReply) GetMessageType() api.MessageType {
1094 return api.ReplyMessage
1097 func (m *Ipip6rdDelTunnelReply) Size() (size int) {
1101 size += 4 // m.Retval
1104 func (m *Ipip6rdDelTunnelReply) Marshal(b []byte) ([]byte, error) {
1106 b = make([]byte, m.Size())
1108 buf := codec.NewBuffer(b)
1109 buf.EncodeInt32(m.Retval)
1110 return buf.Bytes(), nil
1112 func (m *Ipip6rdDelTunnelReply) Unmarshal(b []byte) error {
1113 buf := codec.NewBuffer(b)
1114 m.Retval = buf.DecodeInt32()
1118 // IpipAddTunnel defines message 'ipip_add_tunnel'.
1119 type IpipAddTunnel struct {
1120 Tunnel IpipTunnel `binapi:"ipip_tunnel,name=tunnel" json:"tunnel,omitempty"`
1123 func (m *IpipAddTunnel) Reset() { *m = IpipAddTunnel{} }
1124 func (*IpipAddTunnel) GetMessageName() string { return "ipip_add_tunnel" }
1125 func (*IpipAddTunnel) GetCrcString() string { return "ef93caab" }
1126 func (*IpipAddTunnel) GetMessageType() api.MessageType {
1127 return api.RequestMessage
1130 func (m *IpipAddTunnel) Size() (size int) {
1134 size += 4 // m.Tunnel.Instance
1135 size += 4 // m.Tunnel.Src.Af
1136 size += 1 * 16 // m.Tunnel.Src.Un
1137 size += 4 // m.Tunnel.Dst.Af
1138 size += 1 * 16 // m.Tunnel.Dst.Un
1139 size += 4 // m.Tunnel.SwIfIndex
1140 size += 4 // m.Tunnel.TableID
1141 size += 1 // m.Tunnel.Flags
1142 size += 1 // m.Tunnel.Dscp
1145 func (m *IpipAddTunnel) Marshal(b []byte) ([]byte, error) {
1147 b = make([]byte, m.Size())
1149 buf := codec.NewBuffer(b)
1150 buf.EncodeUint32(m.Tunnel.Instance)
1151 buf.EncodeUint32(uint32(m.Tunnel.Src.Af))
1152 buf.EncodeBytes(m.Tunnel.Src.Un.XXX_UnionData[:], 16)
1153 buf.EncodeUint32(uint32(m.Tunnel.Dst.Af))
1154 buf.EncodeBytes(m.Tunnel.Dst.Un.XXX_UnionData[:], 16)
1155 buf.EncodeUint32(uint32(m.Tunnel.SwIfIndex))
1156 buf.EncodeUint32(m.Tunnel.TableID)
1157 buf.EncodeUint8(uint8(m.Tunnel.Flags))
1158 buf.EncodeUint8(uint8(m.Tunnel.Dscp))
1159 return buf.Bytes(), nil
1161 func (m *IpipAddTunnel) Unmarshal(b []byte) error {
1162 buf := codec.NewBuffer(b)
1163 m.Tunnel.Instance = buf.DecodeUint32()
1164 m.Tunnel.Src.Af = AddressFamily(buf.DecodeUint32())
1165 copy(m.Tunnel.Src.Un.XXX_UnionData[:], buf.DecodeBytes(16))
1166 m.Tunnel.Dst.Af = AddressFamily(buf.DecodeUint32())
1167 copy(m.Tunnel.Dst.Un.XXX_UnionData[:], buf.DecodeBytes(16))
1168 m.Tunnel.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
1169 m.Tunnel.TableID = buf.DecodeUint32()
1170 m.Tunnel.Flags = IpipTunnelFlags(buf.DecodeUint8())
1171 m.Tunnel.Dscp = IPDscp(buf.DecodeUint8())
1175 // IpipAddTunnelReply defines message 'ipip_add_tunnel_reply'.
1176 type IpipAddTunnelReply struct {
1177 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1178 SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1181 func (m *IpipAddTunnelReply) Reset() { *m = IpipAddTunnelReply{} }
1182 func (*IpipAddTunnelReply) GetMessageName() string { return "ipip_add_tunnel_reply" }
1183 func (*IpipAddTunnelReply) GetCrcString() string { return "5383d31f" }
1184 func (*IpipAddTunnelReply) GetMessageType() api.MessageType {
1185 return api.ReplyMessage
1188 func (m *IpipAddTunnelReply) Size() (size int) {
1192 size += 4 // m.Retval
1193 size += 4 // m.SwIfIndex
1196 func (m *IpipAddTunnelReply) Marshal(b []byte) ([]byte, error) {
1198 b = make([]byte, m.Size())
1200 buf := codec.NewBuffer(b)
1201 buf.EncodeInt32(m.Retval)
1202 buf.EncodeUint32(uint32(m.SwIfIndex))
1203 return buf.Bytes(), nil
1205 func (m *IpipAddTunnelReply) Unmarshal(b []byte) error {
1206 buf := codec.NewBuffer(b)
1207 m.Retval = buf.DecodeInt32()
1208 m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
1212 // IpipDelTunnel defines message 'ipip_del_tunnel'.
1213 type IpipDelTunnel struct {
1214 SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1217 func (m *IpipDelTunnel) Reset() { *m = IpipDelTunnel{} }
1218 func (*IpipDelTunnel) GetMessageName() string { return "ipip_del_tunnel" }
1219 func (*IpipDelTunnel) GetCrcString() string { return "f9e6675e" }
1220 func (*IpipDelTunnel) GetMessageType() api.MessageType {
1221 return api.RequestMessage
1224 func (m *IpipDelTunnel) Size() (size int) {
1228 size += 4 // m.SwIfIndex
1231 func (m *IpipDelTunnel) Marshal(b []byte) ([]byte, error) {
1233 b = make([]byte, m.Size())
1235 buf := codec.NewBuffer(b)
1236 buf.EncodeUint32(uint32(m.SwIfIndex))
1237 return buf.Bytes(), nil
1239 func (m *IpipDelTunnel) Unmarshal(b []byte) error {
1240 buf := codec.NewBuffer(b)
1241 m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
1245 // IpipDelTunnelReply defines message 'ipip_del_tunnel_reply'.
1246 type IpipDelTunnelReply struct {
1247 Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1250 func (m *IpipDelTunnelReply) Reset() { *m = IpipDelTunnelReply{} }
1251 func (*IpipDelTunnelReply) GetMessageName() string { return "ipip_del_tunnel_reply" }
1252 func (*IpipDelTunnelReply) GetCrcString() string { return "e8d4e804" }
1253 func (*IpipDelTunnelReply) GetMessageType() api.MessageType {
1254 return api.ReplyMessage
1257 func (m *IpipDelTunnelReply) Size() (size int) {
1261 size += 4 // m.Retval
1264 func (m *IpipDelTunnelReply) Marshal(b []byte) ([]byte, error) {
1266 b = make([]byte, m.Size())
1268 buf := codec.NewBuffer(b)
1269 buf.EncodeInt32(m.Retval)
1270 return buf.Bytes(), nil
1272 func (m *IpipDelTunnelReply) Unmarshal(b []byte) error {
1273 buf := codec.NewBuffer(b)
1274 m.Retval = buf.DecodeInt32()
1278 // IpipTunnelDetails defines message 'ipip_tunnel_details'.
1279 type IpipTunnelDetails struct {
1280 Tunnel IpipTunnel `binapi:"ipip_tunnel,name=tunnel" json:"tunnel,omitempty"`
1283 func (m *IpipTunnelDetails) Reset() { *m = IpipTunnelDetails{} }
1284 func (*IpipTunnelDetails) GetMessageName() string { return "ipip_tunnel_details" }
1285 func (*IpipTunnelDetails) GetCrcString() string { return "7f7b5b85" }
1286 func (*IpipTunnelDetails) GetMessageType() api.MessageType {
1287 return api.ReplyMessage
1290 func (m *IpipTunnelDetails) Size() (size int) {
1294 size += 4 // m.Tunnel.Instance
1295 size += 4 // m.Tunnel.Src.Af
1296 size += 1 * 16 // m.Tunnel.Src.Un
1297 size += 4 // m.Tunnel.Dst.Af
1298 size += 1 * 16 // m.Tunnel.Dst.Un
1299 size += 4 // m.Tunnel.SwIfIndex
1300 size += 4 // m.Tunnel.TableID
1301 size += 1 // m.Tunnel.Flags
1302 size += 1 // m.Tunnel.Dscp
1305 func (m *IpipTunnelDetails) Marshal(b []byte) ([]byte, error) {
1307 b = make([]byte, m.Size())
1309 buf := codec.NewBuffer(b)
1310 buf.EncodeUint32(m.Tunnel.Instance)
1311 buf.EncodeUint32(uint32(m.Tunnel.Src.Af))
1312 buf.EncodeBytes(m.Tunnel.Src.Un.XXX_UnionData[:], 16)
1313 buf.EncodeUint32(uint32(m.Tunnel.Dst.Af))
1314 buf.EncodeBytes(m.Tunnel.Dst.Un.XXX_UnionData[:], 16)
1315 buf.EncodeUint32(uint32(m.Tunnel.SwIfIndex))
1316 buf.EncodeUint32(m.Tunnel.TableID)
1317 buf.EncodeUint8(uint8(m.Tunnel.Flags))
1318 buf.EncodeUint8(uint8(m.Tunnel.Dscp))
1319 return buf.Bytes(), nil
1321 func (m *IpipTunnelDetails) Unmarshal(b []byte) error {
1322 buf := codec.NewBuffer(b)
1323 m.Tunnel.Instance = buf.DecodeUint32()
1324 m.Tunnel.Src.Af = AddressFamily(buf.DecodeUint32())
1325 copy(m.Tunnel.Src.Un.XXX_UnionData[:], buf.DecodeBytes(16))
1326 m.Tunnel.Dst.Af = AddressFamily(buf.DecodeUint32())
1327 copy(m.Tunnel.Dst.Un.XXX_UnionData[:], buf.DecodeBytes(16))
1328 m.Tunnel.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
1329 m.Tunnel.TableID = buf.DecodeUint32()
1330 m.Tunnel.Flags = IpipTunnelFlags(buf.DecodeUint8())
1331 m.Tunnel.Dscp = IPDscp(buf.DecodeUint8())
1335 // IpipTunnelDump defines message 'ipip_tunnel_dump'.
1336 type IpipTunnelDump struct {
1337 SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1340 func (m *IpipTunnelDump) Reset() { *m = IpipTunnelDump{} }
1341 func (*IpipTunnelDump) GetMessageName() string { return "ipip_tunnel_dump" }
1342 func (*IpipTunnelDump) GetCrcString() string { return "f9e6675e" }
1343 func (*IpipTunnelDump) GetMessageType() api.MessageType {
1344 return api.RequestMessage
1347 func (m *IpipTunnelDump) Size() (size int) {
1351 size += 4 // m.SwIfIndex
1354 func (m *IpipTunnelDump) Marshal(b []byte) ([]byte, error) {
1356 b = make([]byte, m.Size())
1358 buf := codec.NewBuffer(b)
1359 buf.EncodeUint32(uint32(m.SwIfIndex))
1360 return buf.Bytes(), nil
1362 func (m *IpipTunnelDump) Unmarshal(b []byte) error {
1363 buf := codec.NewBuffer(b)
1364 m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
1368 func init() { file_ipip_binapi_init() }
1369 func file_ipip_binapi_init() {
1370 api.RegisterMessage((*Ipip6rdAddTunnel)(nil), "ipip_6rd_add_tunnel_56e93cc0")
1371 api.RegisterMessage((*Ipip6rdAddTunnelReply)(nil), "ipip_6rd_add_tunnel_reply_5383d31f")
1372 api.RegisterMessage((*Ipip6rdDelTunnel)(nil), "ipip_6rd_del_tunnel_f9e6675e")
1373 api.RegisterMessage((*Ipip6rdDelTunnelReply)(nil), "ipip_6rd_del_tunnel_reply_e8d4e804")
1374 api.RegisterMessage((*IpipAddTunnel)(nil), "ipip_add_tunnel_ef93caab")
1375 api.RegisterMessage((*IpipAddTunnelReply)(nil), "ipip_add_tunnel_reply_5383d31f")
1376 api.RegisterMessage((*IpipDelTunnel)(nil), "ipip_del_tunnel_f9e6675e")
1377 api.RegisterMessage((*IpipDelTunnelReply)(nil), "ipip_del_tunnel_reply_e8d4e804")
1378 api.RegisterMessage((*IpipTunnelDetails)(nil), "ipip_tunnel_details_7f7b5b85")
1379 api.RegisterMessage((*IpipTunnelDump)(nil), "ipip_tunnel_dump_f9e6675e")
1382 // Messages returns list of all messages in this module.
1383 func AllMessages() []api.Message {
1384 return []api.Message{
1385 (*Ipip6rdAddTunnel)(nil),
1386 (*Ipip6rdAddTunnelReply)(nil),
1387 (*Ipip6rdDelTunnel)(nil),
1388 (*Ipip6rdDelTunnelReply)(nil),
1389 (*IpipAddTunnel)(nil),
1390 (*IpipAddTunnelReply)(nil),
1391 (*IpipDelTunnel)(nil),
1392 (*IpipDelTunnelReply)(nil),
1393 (*IpipTunnelDetails)(nil),
1394 (*IpipTunnelDump)(nil),