Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
INTERNAL_IPS = []string{
"0.0.0.0/8",
"127.0.0.0/8",
"100.64.0.0/10",
"10.0.0.0/8",
"172.16.0.0/12",
"192.168.0.0/16",
"169.254.0.0/16",
"192.0.0.0/24",
"192.0.2.0/24",
"192.18.0.0/15",
"198.51.100.0/24",
"203.0.113.0/24",
"224.0.0.0/4",
"192.88.99.0/24",
"240.0.0.0/4",
"fc00::/7",
"fe80::/10",
}
)
Functions ¶
This section is empty.
Types ¶
type CustomRule ¶
type CustomRuleSet ¶
type CustomRuleSet struct {
Applications []CustomRule `yaml:"applications"`
}
type IPAddressRules ¶
type IPAddressRules struct {
// contains filtered or unexported fields
}
IPAddressRules manages rules associated with IPAddresses
func NewIPAddressRules ¶
func NewIPAddressRules() *IPAddressRules
NewIPAddressRules returns a new IPAddressRules
func (*IPAddressRules) AddIPAddress ¶
func (r *IPAddressRules) AddIPAddress(ipAddress string, matchType Match) error
AddIPAddress adds a rule match by IP Address
type Match ¶
type Match uint32
Match holds IP/ASN match results in a bitmask - can match multiple types
var MatchNone Match = 0
MatchNone is a Match that represents no match
var MatchPrivateASN Match = 7
MatchPrivateASN is a Match that represents a match from a static list of private ASNs (non-cloud)
var MatchPrivateIP Match = 1
MatchPrivateIP is a Match that represents a match from a static list of private IPs
type RuleSet ¶
type RuleSet struct {
// contains filtered or unexported fields
}
RuleSet holds a list of network classification rules
func NewRuleSet ¶
NewRuleSet returns a new RuleSet
func (*RuleSet) GetService ¶
IP is for future proofing if there's demand.
Click to show internal directories.
Click to hide internal directories.