#[non_exhaustive]pub struct FirewallPolicyRuleMatcher {Show 17 fields
pub dest_address_groups: Vec<String>,
pub dest_fqdns: Vec<String>,
pub dest_ip_ranges: Vec<String>,
pub dest_network_context: Option<DestNetworkContext>,
pub dest_network_type: Option<DestNetworkType>,
pub dest_region_codes: Vec<String>,
pub dest_threat_intelligences: Vec<String>,
pub layer_4_configs: Vec<FirewallPolicyRuleMatcherLayer4Config>,
pub src_address_groups: Vec<String>,
pub src_fqdns: Vec<String>,
pub src_ip_ranges: Vec<String>,
pub src_network_context: Option<SrcNetworkContext>,
pub src_network_type: Option<SrcNetworkType>,
pub src_networks: Vec<String>,
pub src_region_codes: Vec<String>,
pub src_secure_tags: Vec<FirewallPolicyRuleSecureTag>,
pub src_threat_intelligences: Vec<String>,
/* private fields */
}firewall-policies or instances or network-firewall-policies or networks or region-network-firewall-policies only.Expand description
Represents a match condition that incoming traffic is evaluated against. Exactly one field must be specified.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.dest_address_groups: Vec<String>Address groups which should be matched against the traffic destination. Maximum number of destination address groups is 10.
dest_fqdns: Vec<String>Fully Qualified Domain Name (FQDN) which should be matched against traffic destination. Maximum number of destination fqdn allowed is 100.
dest_ip_ranges: Vec<String>CIDR IP address range. Maximum number of destination CIDR IP ranges allowed is 5000.
dest_network_context: Option<DestNetworkContext>Network context of the traffic destination. Allowed values are:
- UNSPECIFIED
- INTERNET
- NON_INTERNETdest_network_type: Option<DestNetworkType>Network type of the traffic destination. Allowed values are:
- UNSPECIFIED
- INTERNET
- NON_INTERNETdest_region_codes: Vec<String>Region codes whose IP addresses will be used to match for destination of traffic. Should be specified as 2 letter country code defined as per ISO 3166 alpha-2 country codes. ex.“US” Maximum number of dest region codes allowed is 5000.
dest_threat_intelligences: Vec<String>Names of Network Threat Intelligence lists. The IPs in these lists will be matched against traffic destination.
layer_4_configs: Vec<FirewallPolicyRuleMatcherLayer4Config>Pairs of IP protocols and ports that the rule should match.
src_address_groups: Vec<String>Address groups which should be matched against the traffic source. Maximum number of source address groups is 10.
src_fqdns: Vec<String>Fully Qualified Domain Name (FQDN) which should be matched against traffic source. Maximum number of source fqdn allowed is 100.
src_ip_ranges: Vec<String>CIDR IP address range. Maximum number of source CIDR IP ranges allowed is 5000.
src_network_context: Option<SrcNetworkContext>Network context of the traffic source. Allowed values are:
- UNSPECIFIED
- INTERNET
- INTRA_VPC
- NON_INTERNET
- VPC_NETWORKSsrc_network_type: Option<SrcNetworkType>Network type of the traffic source. Allowed values are:
- UNSPECIFIED
- INTERNET
- INTRA_VPC
- NON_INTERNET
- VPC_NETWORKSsrc_networks: Vec<String>Networks of the traffic source. It can be either a full or partial url.
src_region_codes: Vec<String>Region codes whose IP addresses will be used to match for source of traffic. Should be specified as 2 letter country code defined as per ISO 3166 alpha-2 country codes. ex.“US” Maximum number of source region codes allowed is 5000.
List of secure tag values, which should be matched at the source of the traffic. For INGRESS rule, if all the srcSecureTag are INEFFECTIVE, and there is no srcIpRange, this rule will be ignored. Maximum number of source tag values allowed is 256.
src_threat_intelligences: Vec<String>Names of Network Threat Intelligence lists. The IPs in these lists will be matched against traffic source.
Implementations§
Source§impl FirewallPolicyRuleMatcher
impl FirewallPolicyRuleMatcher
pub fn new() -> Self
Sourcepub fn set_dest_address_groups<T, V>(self, v: T) -> Self
pub fn set_dest_address_groups<T, V>(self, v: T) -> Self
Sets the value of dest_address_groups.
§Example
let x = FirewallPolicyRuleMatcher::new().set_dest_address_groups(["a", "b", "c"]);Sourcepub fn set_dest_fqdns<T, V>(self, v: T) -> Self
pub fn set_dest_fqdns<T, V>(self, v: T) -> Self
Sets the value of dest_fqdns.
§Example
let x = FirewallPolicyRuleMatcher::new().set_dest_fqdns(["a", "b", "c"]);Sourcepub fn set_dest_ip_ranges<T, V>(self, v: T) -> Self
pub fn set_dest_ip_ranges<T, V>(self, v: T) -> Self
Sets the value of dest_ip_ranges.
§Example
let x = FirewallPolicyRuleMatcher::new().set_dest_ip_ranges(["a", "b", "c"]);Sourcepub fn set_dest_network_context<T>(self, v: T) -> Selfwhere
T: Into<DestNetworkContext>,
pub fn set_dest_network_context<T>(self, v: T) -> Selfwhere
T: Into<DestNetworkContext>,
Sets the value of dest_network_context.
§Example
use google_cloud_compute_v1::model::firewall_policy_rule_matcher::DestNetworkContext;
let x0 = FirewallPolicyRuleMatcher::new().set_dest_network_context(DestNetworkContext::IntraVpc);
let x1 = FirewallPolicyRuleMatcher::new().set_dest_network_context(DestNetworkContext::NonInternet);
let x2 = FirewallPolicyRuleMatcher::new().set_dest_network_context(DestNetworkContext::Unspecified);Sourcepub fn set_or_clear_dest_network_context<T>(self, v: Option<T>) -> Selfwhere
T: Into<DestNetworkContext>,
pub fn set_or_clear_dest_network_context<T>(self, v: Option<T>) -> Selfwhere
T: Into<DestNetworkContext>,
Sets or clears the value of dest_network_context.
§Example
use google_cloud_compute_v1::model::firewall_policy_rule_matcher::DestNetworkContext;
let x0 = FirewallPolicyRuleMatcher::new().set_or_clear_dest_network_context(Some(DestNetworkContext::IntraVpc));
let x1 = FirewallPolicyRuleMatcher::new().set_or_clear_dest_network_context(Some(DestNetworkContext::NonInternet));
let x2 = FirewallPolicyRuleMatcher::new().set_or_clear_dest_network_context(Some(DestNetworkContext::Unspecified));
let x_none = FirewallPolicyRuleMatcher::new().set_or_clear_dest_network_context(None::<DestNetworkContext>);Sourcepub fn set_dest_network_type<T>(self, v: T) -> Selfwhere
T: Into<DestNetworkType>,
pub fn set_dest_network_type<T>(self, v: T) -> Selfwhere
T: Into<DestNetworkType>,
Sets the value of dest_network_type.
§Example
use google_cloud_compute_v1::model::firewall_policy_rule_matcher::DestNetworkType;
let x0 = FirewallPolicyRuleMatcher::new().set_dest_network_type(DestNetworkType::IntraVpc);
let x1 = FirewallPolicyRuleMatcher::new().set_dest_network_type(DestNetworkType::NonInternet);
let x2 = FirewallPolicyRuleMatcher::new().set_dest_network_type(DestNetworkType::Unspecified);Sourcepub fn set_or_clear_dest_network_type<T>(self, v: Option<T>) -> Selfwhere
T: Into<DestNetworkType>,
pub fn set_or_clear_dest_network_type<T>(self, v: Option<T>) -> Selfwhere
T: Into<DestNetworkType>,
Sets or clears the value of dest_network_type.
§Example
use google_cloud_compute_v1::model::firewall_policy_rule_matcher::DestNetworkType;
let x0 = FirewallPolicyRuleMatcher::new().set_or_clear_dest_network_type(Some(DestNetworkType::IntraVpc));
let x1 = FirewallPolicyRuleMatcher::new().set_or_clear_dest_network_type(Some(DestNetworkType::NonInternet));
let x2 = FirewallPolicyRuleMatcher::new().set_or_clear_dest_network_type(Some(DestNetworkType::Unspecified));
let x_none = FirewallPolicyRuleMatcher::new().set_or_clear_dest_network_type(None::<DestNetworkType>);Sourcepub fn set_dest_region_codes<T, V>(self, v: T) -> Self
pub fn set_dest_region_codes<T, V>(self, v: T) -> Self
Sets the value of dest_region_codes.
§Example
let x = FirewallPolicyRuleMatcher::new().set_dest_region_codes(["a", "b", "c"]);Sourcepub fn set_dest_threat_intelligences<T, V>(self, v: T) -> Self
pub fn set_dest_threat_intelligences<T, V>(self, v: T) -> Self
Sets the value of dest_threat_intelligences.
§Example
let x = FirewallPolicyRuleMatcher::new().set_dest_threat_intelligences(["a", "b", "c"]);Sourcepub fn set_layer_4_configs<T, V>(self, v: T) -> Self
pub fn set_layer_4_configs<T, V>(self, v: T) -> Self
Sets the value of layer_4_configs.
§Example
use google_cloud_compute_v1::model::FirewallPolicyRuleMatcherLayer4Config;
let x = FirewallPolicyRuleMatcher::new()
.set_layer_4_configs([
FirewallPolicyRuleMatcherLayer4Config::default()/* use setters */,
FirewallPolicyRuleMatcherLayer4Config::default()/* use (different) setters */,
]);Sourcepub fn set_src_address_groups<T, V>(self, v: T) -> Self
pub fn set_src_address_groups<T, V>(self, v: T) -> Self
Sets the value of src_address_groups.
§Example
let x = FirewallPolicyRuleMatcher::new().set_src_address_groups(["a", "b", "c"]);Sourcepub fn set_src_fqdns<T, V>(self, v: T) -> Self
pub fn set_src_fqdns<T, V>(self, v: T) -> Self
Sourcepub fn set_src_ip_ranges<T, V>(self, v: T) -> Self
pub fn set_src_ip_ranges<T, V>(self, v: T) -> Self
Sets the value of src_ip_ranges.
§Example
let x = FirewallPolicyRuleMatcher::new().set_src_ip_ranges(["a", "b", "c"]);Sourcepub fn set_src_network_context<T>(self, v: T) -> Selfwhere
T: Into<SrcNetworkContext>,
pub fn set_src_network_context<T>(self, v: T) -> Selfwhere
T: Into<SrcNetworkContext>,
Sets the value of src_network_context.
§Example
use google_cloud_compute_v1::model::firewall_policy_rule_matcher::SrcNetworkContext;
let x0 = FirewallPolicyRuleMatcher::new().set_src_network_context(SrcNetworkContext::IntraVpc);
let x1 = FirewallPolicyRuleMatcher::new().set_src_network_context(SrcNetworkContext::NonInternet);
let x2 = FirewallPolicyRuleMatcher::new().set_src_network_context(SrcNetworkContext::Unspecified);Sourcepub fn set_or_clear_src_network_context<T>(self, v: Option<T>) -> Selfwhere
T: Into<SrcNetworkContext>,
pub fn set_or_clear_src_network_context<T>(self, v: Option<T>) -> Selfwhere
T: Into<SrcNetworkContext>,
Sets or clears the value of src_network_context.
§Example
use google_cloud_compute_v1::model::firewall_policy_rule_matcher::SrcNetworkContext;
let x0 = FirewallPolicyRuleMatcher::new().set_or_clear_src_network_context(Some(SrcNetworkContext::IntraVpc));
let x1 = FirewallPolicyRuleMatcher::new().set_or_clear_src_network_context(Some(SrcNetworkContext::NonInternet));
let x2 = FirewallPolicyRuleMatcher::new().set_or_clear_src_network_context(Some(SrcNetworkContext::Unspecified));
let x_none = FirewallPolicyRuleMatcher::new().set_or_clear_src_network_context(None::<SrcNetworkContext>);Sourcepub fn set_src_network_type<T>(self, v: T) -> Selfwhere
T: Into<SrcNetworkType>,
pub fn set_src_network_type<T>(self, v: T) -> Selfwhere
T: Into<SrcNetworkType>,
Sets the value of src_network_type.
§Example
use google_cloud_compute_v1::model::firewall_policy_rule_matcher::SrcNetworkType;
let x0 = FirewallPolicyRuleMatcher::new().set_src_network_type(SrcNetworkType::IntraVpc);
let x1 = FirewallPolicyRuleMatcher::new().set_src_network_type(SrcNetworkType::NonInternet);
let x2 = FirewallPolicyRuleMatcher::new().set_src_network_type(SrcNetworkType::Unspecified);Sourcepub fn set_or_clear_src_network_type<T>(self, v: Option<T>) -> Selfwhere
T: Into<SrcNetworkType>,
pub fn set_or_clear_src_network_type<T>(self, v: Option<T>) -> Selfwhere
T: Into<SrcNetworkType>,
Sets or clears the value of src_network_type.
§Example
use google_cloud_compute_v1::model::firewall_policy_rule_matcher::SrcNetworkType;
let x0 = FirewallPolicyRuleMatcher::new().set_or_clear_src_network_type(Some(SrcNetworkType::IntraVpc));
let x1 = FirewallPolicyRuleMatcher::new().set_or_clear_src_network_type(Some(SrcNetworkType::NonInternet));
let x2 = FirewallPolicyRuleMatcher::new().set_or_clear_src_network_type(Some(SrcNetworkType::Unspecified));
let x_none = FirewallPolicyRuleMatcher::new().set_or_clear_src_network_type(None::<SrcNetworkType>);Sourcepub fn set_src_networks<T, V>(self, v: T) -> Self
pub fn set_src_networks<T, V>(self, v: T) -> Self
Sets the value of src_networks.
§Example
let x = FirewallPolicyRuleMatcher::new().set_src_networks(["a", "b", "c"]);Sourcepub fn set_src_region_codes<T, V>(self, v: T) -> Self
pub fn set_src_region_codes<T, V>(self, v: T) -> Self
Sets the value of src_region_codes.
§Example
let x = FirewallPolicyRuleMatcher::new().set_src_region_codes(["a", "b", "c"]);Sets the value of src_secure_tags.
§Example
use google_cloud_compute_v1::model::FirewallPolicyRuleSecureTag;
let x = FirewallPolicyRuleMatcher::new()
.set_src_secure_tags([
FirewallPolicyRuleSecureTag::default()/* use setters */,
FirewallPolicyRuleSecureTag::default()/* use (different) setters */,
]);Sourcepub fn set_src_threat_intelligences<T, V>(self, v: T) -> Self
pub fn set_src_threat_intelligences<T, V>(self, v: T) -> Self
Sets the value of src_threat_intelligences.
§Example
let x = FirewallPolicyRuleMatcher::new().set_src_threat_intelligences(["a", "b", "c"]);Trait Implementations§
Source§impl Clone for FirewallPolicyRuleMatcher
impl Clone for FirewallPolicyRuleMatcher
Source§fn clone(&self) -> FirewallPolicyRuleMatcher
fn clone(&self) -> FirewallPolicyRuleMatcher
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more