Versions in this module Expand all Collapse all v2 v2.0.0 Sep 14, 2024 Changes in this version + func RuleBasePriority[ruleT ruleTypeKind](_ ruleT) int16 + func SeparateNetworks(nws []Network, scopeIPs ...net.IP) (netIPv4, netIPv6 []net.IPNet) + type CidrSgRules struct + Rules dict.RBDict[model.IECidrSgRuleIdenity, *model.IECidrSgRule] + func (rules *CidrSgRules) GetRulesForTrafficAndSG(tr model.Traffic, sg string) []*model.IECidrSgRule + func (rules *CidrSgRules) IsEq(other CidrSgRules) bool + func (rules *CidrSgRules) Load(ctx context.Context, client SGClient, locals SGs) (err error) + type IECidrSgIcmpRules struct + Rules dict.RBDict[model.IECidrSgIcmpRuleID, *model.IECidrSgIcmpRule] + func (o IECidrSgIcmpRules) IsEq(other IECidrSgIcmpRules) bool + func (rules *IECidrSgIcmpRules) GetRulesForTrafficAndSG(tr model.Traffic, sg string) (ret []*model.IECidrSgIcmpRule) + func (rules *IECidrSgIcmpRules) Load(ctx context.Context, client SGClient, locals SGs) (err error) + type LocalData struct + CidrSgRules CidrSgRules + IECidrSgIcmpRules IECidrSgIcmpRules + LocalSGs SGs + Networks SGsNetworks + ResolvedFQDN *ResolvedFQDN + SG2FQDNRules SG2FQDNRules + SG2SGRules SG2SGRules + SgIcmpRules SgIcmpRules + SgIeSgIcmpRules SgIeSgIcmpRules + SgIeSgRules SgIeSgRules + SgSgIcmpRules SgSgIcmpRules + SyncStatus model.SyncStatus + func (ld *LocalData) IsEq(other LocalData) bool + type LocalDataLoader struct + MaxLoadDiration time.Duration + SyncStatus model.SyncStatus + func (loader *LocalDataLoader) Load(ctx context.Context, client SGClient, ncnf host.NetConf) (res LocalData, err error) + type Network = model.Network + type Networks struct + func (nws *Networks) IsEq(other Networks) bool + type ResolvedFQDN struct + A dict.RBDict[model.FQDN, agent.DomainAddresses] + AAAA dict.RBDict[model.FQDN, agent.DomainAddresses] + func (r *ResolvedFQDN) Resolve(ctx context.Context, rules SG2FQDNRules, dnsRes agent.DomainAddressQuerier) + func (r *ResolvedFQDN) UpdA(domain model.FQDN, addr agent.DomainAddresses) + func (r *ResolvedFQDN) UpdAAAA(domain model.FQDN, addr agent.DomainAddresses) + type SG struct + LocalIPsV4 iplib.ByIP + LocalIPsV6 iplib.ByIP + func (loc *SG) IsLocal() bool + type SG2FQDNRules struct + FQDNs dict.RBSet[model.FQDN] + Rules []model.FQDNRule + func (rules *SG2FQDNRules) IsEq(other SG2FQDNRules) bool + func (rules *SG2FQDNRules) Load(ctx context.Context, SGSrv SGClient, sgs SGs) (err error) + func (rules SG2FQDNRules) RulesForSG(sgName string) []model.FQDNRule + type SG2SGRules struct + Rules dict.HDict[model.SGRuleIdentity, *model.SGRule] + func (rules *SG2SGRules) IsEq(other SG2SGRules) bool + func (rules *SG2SGRules) Load(ctx context.Context, client SGClient, locals SGs) (err error) + func (rules SG2SGRules) AllRules() []model.SGRule + func (rules SG2SGRules) In(sgTo string) (ret []model.SGRule) + func (rules SG2SGRules) Out(sgFrom string) (ret []model.SGRule) + type SGClient = sgAPI.SecGroupServiceClient + type SGs struct + func (loc *SGs) IsEq(other SGs) bool + func (loc *SGs) LoadFromIPs(ctx context.Context, client SGClient, localIPs []net.IP) error + func (loc *SGs) LoadFromNames(ctx context.Context, client SGClient, names []string) (err error) + func (loc SGs) Names() []SgName + type SGsNetworks struct + func (sgsNws *SGsNetworks) Add(sg SgName, nws ...Network) + func (sgsNws *SGsNetworks) IsEq(other SGsNetworks) bool + func (sgsNws *SGsNetworks) IterateNetworks(f func(SgName, []Network) bool) + func (sgsNws *SGsNetworks) Load(ctx context.Context, client SGClient, localSG SGs) error + func (sgsNws *SGsNetworks) LoadFromSGNames(ctx context.Context, client SGClient, sgNames []string) error + type SgIcmpRules struct + Rules dict.HDict[model.SgIcmpRuleID, *model.SgIcmpRule] + func (rules *SgIcmpRules) IsEq(other SgIcmpRules) bool + func (rules *SgIcmpRules) Load(ctx context.Context, client SGClient, locals SGs) (err error) + func (rules SgIcmpRules) Rules4Sg(sgName string) (ret []model.SgIcmpRule) + type SgIeSgIcmpRules struct + Rules dict.HDict[model.IESgSgIcmpRuleID, *model.IESgSgIcmpRule] + func (rules *SgIeSgIcmpRules) GetRulesForTrafficAndSG(tr model.Traffic, sg string) (ret []*model.IESgSgIcmpRule) + func (rules *SgIeSgIcmpRules) IsEq(other SgIeSgIcmpRules) bool + func (rules *SgIeSgIcmpRules) Load(ctx context.Context, client SGClient, locals SGs) (err error) + type SgIeSgRules struct + Rules dict.HDict[model.IESgSgRuleIdentity, *model.IESgSgRule] + func (rules *SgIeSgRules) GetRulesForTrafficAndSG(tr model.Traffic, sg string) (ret []*model.IESgSgRule) + func (rules *SgIeSgRules) IsEq(other SgIeSgRules) bool + func (rules *SgIeSgRules) Load(ctx context.Context, client SGClient, locals SGs) (err error) + type SgName = string + type SgSgIcmpRules struct + Rules dict.HDict[model.SgSgIcmpRuleID, *model.SgSgIcmpRule] + func (rules *SgSgIcmpRules) IsEq(other SgSgIcmpRules) bool + func (rules *SgSgIcmpRules) Load(ctx context.Context, client SGClient, locals SGs) (err error) + func (rules SgSgIcmpRules) In(sgTo string) (ret []model.SgSgIcmpRule) + func (rules SgSgIcmpRules) Out(sgFrom string) (ret []model.SgSgIcmpRule)