ipv3

package
v1.34.0-20240315201424... Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: unknown License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_envoy_extensions_matching_input_matchers_ip_v3_ip_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type Ip

type Ip struct {

	// Match if the IP belongs to any of these CIDR ranges.
	CidrRanges []*v3.CidrRange `protobuf:"bytes,1,rep,name=cidr_ranges,json=cidrRanges,proto3" json:"cidr_ranges,omitempty"`
	// The human readable prefix to use when emitting statistics for the IP input
	// matcher. Names in the table below are concatenated to this prefix.
	//
	// .. csv-table::
	//
	//	:header: Name, Type, Description
	//	:widths: 1, 1, 2
	//
	//	ip_parsing_failed, Counter, Total number of IP addresses the matcher was unable to parse
	StatPrefix string `protobuf:"bytes,2,opt,name=stat_prefix,json=statPrefix,proto3" json:"stat_prefix,omitempty"`
	// contains filtered or unexported fields
}

This input matcher matches IPv4 or IPv6 addresses against a list of CIDR ranges. It returns true if and only if the input IP belongs to at least one of these CIDR ranges. Internally, it uses a Level-Compressed trie, as described in the paper `IP-address lookup using LC-tries <https://www.nada.kth.se/~snilsson/publications/IP-address-lookup-using-LC-tries/>`_ by S. Nilsson and G. Karlsson. For "big" lists of IPs, this matcher is more efficient than multiple single IP matcher, that would have a linear cost.

func (*Ip) Descriptor deprecated

func (*Ip) Descriptor() ([]byte, []int)

Deprecated: Use Ip.ProtoReflect.Descriptor instead.

func (*Ip) GetCidrRanges

func (x *Ip) GetCidrRanges() []*v3.CidrRange

func (*Ip) GetStatPrefix

func (x *Ip) GetStatPrefix() string

func (*Ip) ProtoMessage

func (*Ip) ProtoMessage()

func (*Ip) ProtoReflect

func (x *Ip) ProtoReflect() protoreflect.Message

func (*Ip) Reset

func (x *Ip) Reset()

func (*Ip) String

func (x *Ip) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL