// Code generated by azure-service-operator-codegen. DO NOT EDIT.
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
package arm

import "github.com/Azure/azure-service-operator/v2/pkg/genruntime"

type AzureFirewall_Spec struct {
	// Location: Resource location.
	Location *string `json:"location,omitempty"`
	Name     string  `json:"name,omitempty"`

	// Properties: Properties of the azure firewall.
	Properties *AzureFirewallPropertiesFormat `json:"properties,omitempty"`

	// Tags: Resource tags.
	Tags map[string]string `json:"tags,omitempty"`

	// Zones: A list of availability zones denoting where the resource needs to come from.
	Zones []string `json:"zones,omitempty"`
}

var _ genruntime.ARMResourceSpec = &AzureFirewall_Spec{}

// GetAPIVersion returns the ARM API version of the resource. This is always "2024-03-01"
func (firewall AzureFirewall_Spec) GetAPIVersion() string {
	return "2024-03-01"
}

// GetName returns the Name of the resource
func (firewall *AzureFirewall_Spec) GetName() string {
	return firewall.Name
}

// GetType returns the ARM Type of the resource. This is always "Microsoft.Network/azureFirewalls"
func (firewall *AzureFirewall_Spec) GetType() string {
	return "Microsoft.Network/azureFirewalls"
}

// Properties of the Azure Firewall.
type AzureFirewallPropertiesFormat struct {
	// AdditionalProperties: The additional properties used to further config this azure firewall.
	AdditionalProperties map[string]string `json:"additionalProperties,omitempty"`

	// ApplicationRuleCollections: Collection of application rule collections used by Azure Firewall.
	ApplicationRuleCollections []AzureFirewallApplicationRuleCollection `json:"applicationRuleCollections,omitempty"`

	// AutoscaleConfiguration: Properties to provide a custom autoscale configuration to this azure firewall.
	AutoscaleConfiguration *AzureFirewallAutoscaleConfiguration `json:"autoscaleConfiguration,omitempty"`

	// FirewallPolicy: The firewallPolicy associated with this azure firewall.
	FirewallPolicy *SubResource `json:"firewallPolicy,omitempty"`

	// HubIPAddresses: IP addresses associated with AzureFirewall.
	HubIPAddresses *HubIPAddresses `json:"hubIPAddresses,omitempty"`

	// IpConfigurations: IP configuration of the Azure Firewall resource.
	IpConfigurations []AzureFirewallIPConfiguration `json:"ipConfigurations,omitempty"`

	// ManagementIpConfiguration: IP configuration of the Azure Firewall used for management traffic.
	ManagementIpConfiguration *AzureFirewallIPConfiguration `json:"managementIpConfiguration,omitempty"`

	// NatRuleCollections: Collection of NAT rule collections used by Azure Firewall.
	NatRuleCollections []AzureFirewallNatRuleCollection `json:"natRuleCollections,omitempty"`

	// NetworkRuleCollections: Collection of network rule collections used by Azure Firewall.
	NetworkRuleCollections []AzureFirewallNetworkRuleCollection `json:"networkRuleCollections,omitempty"`

	// Sku: The Azure Firewall Resource SKU.
	Sku *AzureFirewallSku `json:"sku,omitempty"`

	// ThreatIntelMode: The operation mode for Threat Intelligence.
	ThreatIntelMode *AzureFirewallThreatIntelMode `json:"threatIntelMode,omitempty"`

	// VirtualHub: The virtualHub to which the firewall belongs.
	VirtualHub *SubResource `json:"virtualHub,omitempty"`
}

// Application rule collection resource.
type AzureFirewallApplicationRuleCollection struct {
	// Name: The name of the resource that is unique within the Azure firewall. This name can be used to access the resource.
	Name *string `json:"name,omitempty"`

	// Properties: Properties of the azure firewall application rule collection.
	Properties *AzureFirewallApplicationRuleCollectionPropertiesFormat `json:"properties,omitempty"`
}

// Azure Firewall Autoscale Configuration parameters.
type AzureFirewallAutoscaleConfiguration struct {
	// MaxCapacity: The maximum number of capacity units for this azure firewall. Use null to reset the value to the service
	// default.
	MaxCapacity *int `json:"maxCapacity,omitempty"`

	// MinCapacity: The minimum number of capacity units for this azure firewall. Use null to reset the value to the service
	// default.
	MinCapacity *int `json:"minCapacity,omitempty"`
}

// IP configuration of an Azure Firewall.
type AzureFirewallIPConfiguration struct {
	// Name: Name of the resource that is unique within a resource group. This name can be used to access the resource.
	Name *string `json:"name,omitempty"`

	// Properties: Properties of the azure firewall IP configuration.
	Properties *AzureFirewallIPConfigurationPropertiesFormat `json:"properties,omitempty"`
}

// NAT rule collection resource.
type AzureFirewallNatRuleCollection struct {
	// Name: The name of the resource that is unique within the Azure firewall. This name can be used to access the resource.
	Name *string `json:"name,omitempty"`

	// Properties: Properties of the azure firewall NAT rule collection.
	Properties *AzureFirewallNatRuleCollectionProperties `json:"properties,omitempty"`
}

// Network rule collection resource.
type AzureFirewallNetworkRuleCollection struct {
	// Name: The name of the resource that is unique within the Azure firewall. This name can be used to access the resource.
	Name *string `json:"name,omitempty"`

	// Properties: Properties of the azure firewall network rule collection.
	Properties *AzureFirewallNetworkRuleCollectionPropertiesFormat `json:"properties,omitempty"`
}

// SKU of an Azure Firewall.
type AzureFirewallSku struct {
	// Name: Name of an Azure Firewall SKU.
	Name *AzureFirewallSku_Name `json:"name,omitempty"`

	// Tier: Tier of an Azure Firewall.
	Tier *AzureFirewallSku_Tier `json:"tier,omitempty"`
}

// The operation mode for Threat Intel.
// +kubebuilder:validation:Enum={"Alert","Deny","Off"}
type AzureFirewallThreatIntelMode string

const (
	AzureFirewallThreatIntelMode_Alert = AzureFirewallThreatIntelMode("Alert")
	AzureFirewallThreatIntelMode_Deny  = AzureFirewallThreatIntelMode("Deny")
	AzureFirewallThreatIntelMode_Off   = AzureFirewallThreatIntelMode("Off")
)

// Mapping from string to AzureFirewallThreatIntelMode
var azureFirewallThreatIntelMode_Values = map[string]AzureFirewallThreatIntelMode{
	"alert": AzureFirewallThreatIntelMode_Alert,
	"deny":  AzureFirewallThreatIntelMode_Deny,
	"off":   AzureFirewallThreatIntelMode_Off,
}

// IP addresses associated with azure firewall.
type HubIPAddresses struct {
	// PrivateIPAddress: Private IP Address associated with azure firewall.
	PrivateIPAddress *string `json:"privateIPAddress,omitempty"`

	// PublicIPs: Public IP addresses associated with azure firewall.
	PublicIPs *HubPublicIPAddresses `json:"publicIPs,omitempty"`
}

// Reference to another subresource.
type SubResource struct {
	// Id: Resource ID.
	Id *string `json:"id,omitempty"`
}

// Properties of the application rule collection.
type AzureFirewallApplicationRuleCollectionPropertiesFormat struct {
	// Action: The action type of a rule collection.
	Action *AzureFirewallRCAction `json:"action,omitempty"`

	// Priority: Priority of the application rule collection resource.
	Priority *int `json:"priority,omitempty"`

	// Rules: Collection of rules used by a application rule collection.
	Rules []AzureFirewallApplicationRule `json:"rules,omitempty"`
}

// Properties of IP configuration of an Azure Firewall.
type AzureFirewallIPConfigurationPropertiesFormat struct {
	// PublicIPAddress: Reference to the PublicIP resource. This field is a mandatory input if subnet is not null.
	PublicIPAddress *SubResource `json:"publicIPAddress,omitempty"`

	// Subnet: Reference to the subnet resource. This resource must be named 'AzureFirewallSubnet' or
	// 'AzureFirewallManagementSubnet'.
	Subnet *SubResource `json:"subnet,omitempty"`
}

// Properties of the NAT rule collection.
type AzureFirewallNatRuleCollectionProperties struct {
	// Action: The action type of a NAT rule collection.
	Action *AzureFirewallNatRCAction `json:"action,omitempty"`

	// Priority: Priority of the NAT rule collection resource.
	Priority *int `json:"priority,omitempty"`

	// Rules: Collection of rules used by a NAT rule collection.
	Rules []AzureFirewallNatRule `json:"rules,omitempty"`
}

// Properties of the network rule collection.
type AzureFirewallNetworkRuleCollectionPropertiesFormat struct {
	// Action: The action type of a rule collection.
	Action *AzureFirewallRCAction `json:"action,omitempty"`

	// Priority: Priority of the network rule collection resource.
	Priority *int `json:"priority,omitempty"`

	// Rules: Collection of rules used by a network rule collection.
	Rules []AzureFirewallNetworkRule `json:"rules,omitempty"`
}

// +kubebuilder:validation:Enum={"AZFW_Hub","AZFW_VNet"}
type AzureFirewallSku_Name string

const (
	AzureFirewallSku_Name_AZFW_Hub  = AzureFirewallSku_Name("AZFW_Hub")
	AzureFirewallSku_Name_AZFW_VNet = AzureFirewallSku_Name("AZFW_VNet")
)

// Mapping from string to AzureFirewallSku_Name
var azureFirewallSku_Name_Values = map[string]AzureFirewallSku_Name{
	"azfw_hub":  AzureFirewallSku_Name_AZFW_Hub,
	"azfw_vnet": AzureFirewallSku_Name_AZFW_VNet,
}

// +kubebuilder:validation:Enum={"Basic","Premium","Standard"}
type AzureFirewallSku_Tier string

const (
	AzureFirewallSku_Tier_Basic    = AzureFirewallSku_Tier("Basic")
	AzureFirewallSku_Tier_Premium  = AzureFirewallSku_Tier("Premium")
	AzureFirewallSku_Tier_Standard = AzureFirewallSku_Tier("Standard")
)

// Mapping from string to AzureFirewallSku_Tier
var azureFirewallSku_Tier_Values = map[string]AzureFirewallSku_Tier{
	"basic":    AzureFirewallSku_Tier_Basic,
	"premium":  AzureFirewallSku_Tier_Premium,
	"standard": AzureFirewallSku_Tier_Standard,
}

// Public IP addresses associated with azure firewall.
type HubPublicIPAddresses struct {
	// Addresses: The list of Public IP addresses associated with azure firewall or IP addresses to be retained.
	Addresses []AzureFirewallPublicIPAddress `json:"addresses,omitempty"`

	// Count: The number of Public IP addresses associated with azure firewall.
	Count *int `json:"count,omitempty"`
}

// Properties of an application rule.
type AzureFirewallApplicationRule struct {
	// Description: Description of the rule.
	Description *string `json:"description,omitempty"`

	// FqdnTags: List of FQDN Tags for this rule.
	FqdnTags []string `json:"fqdnTags,omitempty"`

	// Name: Name of the application rule.
	Name *string `json:"name,omitempty"`

	// Protocols: Array of ApplicationRuleProtocols.
	Protocols []AzureFirewallApplicationRuleProtocol `json:"protocols,omitempty"`

	// SourceAddresses: List of source IP addresses for this rule.
	SourceAddresses []string `json:"sourceAddresses,omitempty"`

	// SourceIpGroups: List of source IpGroups for this rule.
	SourceIpGroups []string `json:"sourceIpGroups,omitempty"`

	// TargetFqdns: List of FQDNs for this rule.
	TargetFqdns []string `json:"targetFqdns,omitempty"`
}

// AzureFirewall NAT Rule Collection Action.
type AzureFirewallNatRCAction struct {
	// Type: The type of action.
	Type *AzureFirewallNatRCActionType `json:"type,omitempty"`
}

// Properties of a NAT rule.
type AzureFirewallNatRule struct {
	// Description: Description of the rule.
	Description *string `json:"description,omitempty"`

	// DestinationAddresses: List of destination IP addresses for this rule. Supports IP ranges, prefixes, and service tags.
	DestinationAddresses []string `json:"destinationAddresses,omitempty"`

	// DestinationPorts: List of destination ports.
	DestinationPorts []string `json:"destinationPorts,omitempty"`

	// Name: Name of the NAT rule.
	Name *string `json:"name,omitempty"`

	// Protocols: Array of AzureFirewallNetworkRuleProtocols applicable to this NAT rule.
	Protocols []AzureFirewallNetworkRuleProtocol `json:"protocols,omitempty"`

	// SourceAddresses: List of source IP addresses for this rule.
	SourceAddresses []string `json:"sourceAddresses,omitempty"`

	// SourceIpGroups: List of source IpGroups for this rule.
	SourceIpGroups []string `json:"sourceIpGroups,omitempty"`

	// TranslatedAddress: The translated address for this NAT rule.
	TranslatedAddress *string `json:"translatedAddress,omitempty"`

	// TranslatedFqdn: The translated FQDN for this NAT rule.
	TranslatedFqdn *string `json:"translatedFqdn,omitempty"`

	// TranslatedPort: The translated port for this NAT rule.
	TranslatedPort *string `json:"translatedPort,omitempty"`
}

// Properties of the network rule.
type AzureFirewallNetworkRule struct {
	// Description: Description of the rule.
	Description *string `json:"description,omitempty"`

	// DestinationAddresses: List of destination IP addresses.
	DestinationAddresses []string `json:"destinationAddresses,omitempty"`

	// DestinationFqdns: List of destination FQDNs.
	DestinationFqdns []string `json:"destinationFqdns,omitempty"`

	// DestinationIpGroups: List of destination IpGroups for this rule.
	DestinationIpGroups []string `json:"destinationIpGroups,omitempty"`

	// DestinationPorts: List of destination ports.
	DestinationPorts []string `json:"destinationPorts,omitempty"`

	// Name: Name of the network rule.
	Name *string `json:"name,omitempty"`

	// Protocols: Array of AzureFirewallNetworkRuleProtocols.
	Protocols []AzureFirewallNetworkRuleProtocol `json:"protocols,omitempty"`

	// SourceAddresses: List of source IP addresses for this rule.
	SourceAddresses []string `json:"sourceAddresses,omitempty"`

	// SourceIpGroups: List of source IpGroups for this rule.
	SourceIpGroups []string `json:"sourceIpGroups,omitempty"`
}

// Public IP Address associated with azure firewall.
type AzureFirewallPublicIPAddress struct {
	// Address: Public IP Address value.
	Address *string `json:"address,omitempty"`
}

// Properties of the AzureFirewallRCAction.
type AzureFirewallRCAction struct {
	// Type: The type of action.
	Type *AzureFirewallRCActionType `json:"type,omitempty"`
}

// Properties of the application rule protocol.
type AzureFirewallApplicationRuleProtocol struct {
	// Port: Port number for the protocol, cannot be greater than 64000. This field is optional.
	Port *int `json:"port,omitempty"`

	// ProtocolType: Protocol type.
	ProtocolType *AzureFirewallApplicationRuleProtocolType `json:"protocolType,omitempty"`
}

// The action type of a NAT rule collection.
// +kubebuilder:validation:Enum={"Dnat","Snat"}
type AzureFirewallNatRCActionType string

const (
	AzureFirewallNatRCActionType_Dnat = AzureFirewallNatRCActionType("Dnat")
	AzureFirewallNatRCActionType_Snat = AzureFirewallNatRCActionType("Snat")
)

// Mapping from string to AzureFirewallNatRCActionType
var azureFirewallNatRCActionType_Values = map[string]AzureFirewallNatRCActionType{
	"dnat": AzureFirewallNatRCActionType_Dnat,
	"snat": AzureFirewallNatRCActionType_Snat,
}

// The protocol of a Network Rule resource.
// +kubebuilder:validation:Enum={"Any","ICMP","TCP","UDP"}
type AzureFirewallNetworkRuleProtocol string

const (
	AzureFirewallNetworkRuleProtocol_Any  = AzureFirewallNetworkRuleProtocol("Any")
	AzureFirewallNetworkRuleProtocol_ICMP = AzureFirewallNetworkRuleProtocol("ICMP")
	AzureFirewallNetworkRuleProtocol_TCP  = AzureFirewallNetworkRuleProtocol("TCP")
	AzureFirewallNetworkRuleProtocol_UDP  = AzureFirewallNetworkRuleProtocol("UDP")
)

// Mapping from string to AzureFirewallNetworkRuleProtocol
var azureFirewallNetworkRuleProtocol_Values = map[string]AzureFirewallNetworkRuleProtocol{
	"any":  AzureFirewallNetworkRuleProtocol_Any,
	"icmp": AzureFirewallNetworkRuleProtocol_ICMP,
	"tcp":  AzureFirewallNetworkRuleProtocol_TCP,
	"udp":  AzureFirewallNetworkRuleProtocol_UDP,
}

// The action type of a rule collection.
// +kubebuilder:validation:Enum={"Allow","Deny"}
type AzureFirewallRCActionType string

const (
	AzureFirewallRCActionType_Allow = AzureFirewallRCActionType("Allow")
	AzureFirewallRCActionType_Deny  = AzureFirewallRCActionType("Deny")
)

// Mapping from string to AzureFirewallRCActionType
var azureFirewallRCActionType_Values = map[string]AzureFirewallRCActionType{
	"allow": AzureFirewallRCActionType_Allow,
	"deny":  AzureFirewallRCActionType_Deny,
}

// The protocol type of a Application Rule resource.
// +kubebuilder:validation:Enum={"Http","Https","Mssql"}
type AzureFirewallApplicationRuleProtocolType string

const (
	AzureFirewallApplicationRuleProtocolType_Http  = AzureFirewallApplicationRuleProtocolType("Http")
	AzureFirewallApplicationRuleProtocolType_Https = AzureFirewallApplicationRuleProtocolType("Https")
	AzureFirewallApplicationRuleProtocolType_Mssql = AzureFirewallApplicationRuleProtocolType("Mssql")
)

// Mapping from string to AzureFirewallApplicationRuleProtocolType
var azureFirewallApplicationRuleProtocolType_Values = map[string]AzureFirewallApplicationRuleProtocolType{
	"http":  AzureFirewallApplicationRuleProtocolType_Http,
	"https": AzureFirewallApplicationRuleProtocolType_Https,
	"mssql": AzureFirewallApplicationRuleProtocolType_Mssql,
}
