Documentation ¶
Index ¶
Constants ¶
View Source
const ( // New indicates the rule needs to be created New ruleState = "new" // Modified indicates the rule needs to be modified Modified ruleState = "modified" )
Variables ¶
This section is empty.
Functions ¶
func ConvertSourceRangesMapToSlice ¶
ConvertSourceRangesMapToSlice Convert SourceRanges map to slice
func ConvertSourceRangesSliceToMap ¶
ConvertSourceRangesSliceToMap Convert SourceRanges slice to map
Types ¶
type AWSConfig ¶
type AWSConfig struct { Disabled bool `yaml:"disabled"` Region string `yaml:"region"` FirewallPolicy string `yaml:"firewall_policy"` Capacity int `yaml:"capacity"` RuleGroupPriority int64 `yaml:"priority"` // Endpoint is used for making calls to a mock server instead of the real AWS services endpoints. Endpoint string `yaml:"endpoint"` }
type AzureConfig ¶
type AzureConfig struct { Disabled bool `yaml:"disabled"` SubscriptionID string `yaml:"subscription_id"` ResourceGroup string `yaml:"resource_group"` Network string `yaml:"network"` Priority int64 `yaml:"priority"` MaxRules int `yaml:"max_rules"` Capacity int `yaml:"capacity"` UserAgent string `yaml:"user_agent"` // Endpoint is used for making calls to a mock server instead of the real Google services endpoints. Endpoint string `yaml:"endpoint"` }
type CloudArmorConfig ¶
type CloudArmorConfig struct { Disabled bool `yaml:"disabled"` ProjectID string `yaml:"project_id"` Policy string `yaml:"policy"` Priority int64 `yaml:"priority"` MaxRules int `yaml:"max_rules"` // Endpoint is used for making calls to a mock server instead of the real Google services endpoints. Endpoint string `yaml:"endpoint"` }
type CloudProviders ¶
type CloudProviders struct { GCP GCPConfig `yaml:"gcp"` Azure AzureConfig `yaml:"azure"` AWS AWSConfig `yaml:"aws"` CloudArmor CloudArmorConfig `yaml:"cloudarmor"` }
type FirewallRule ¶
type FirewallRule struct { // Name identifies the firewall rule name Name string // SourceRanges contains the source ranges defined in the firewall rule SourceRanges map[string]bool // State determines the operation when updating the firewall rule. // An empty State will result in noop when updating the rule at the cloud provider. State ruleState Priority int64 }
FirewallRule represents a cloud agnostic firewall rule
type GCPConfig ¶
type GCPConfig struct { Disabled bool `yaml:"disabled"` ProjectID string `yaml:"project_id"` Network string `yaml:"network"` Priority int64 `yaml:"priority"` MaxRules int `yaml:"max_rules"` // Endpoint is used for making calls to a mock server instead of the real Google services endpoints. Endpoint string `yaml:"endpoint"` }
Click to show internal directories.
Click to hide internal directories.