Struct google_api_proto::google::cloud::compute::v1::FirewallPolicyRule
source · pub struct FirewallPolicyRule {Show 15 fields
pub action: Option<String>,
pub description: Option<String>,
pub direction: Option<String>,
pub disabled: Option<bool>,
pub enable_logging: Option<bool>,
pub kind: Option<String>,
pub match: Option<FirewallPolicyRuleMatcher>,
pub priority: Option<i32>,
pub rule_name: Option<String>,
pub rule_tuple_count: Option<i32>,
pub security_profile_group: Option<String>,
pub target_resources: Vec<String>,
pub target_secure_tags: Vec<FirewallPolicyRuleSecureTag>,
pub target_service_accounts: Vec<String>,
pub tls_inspect: Option<bool>,
}
Expand description
Represents a rule that describes one or more match conditions along with the action to be taken when traffic matches this condition (allow or deny).
Fields§
§action: Option<String>
The Action to perform when the client connection triggers the rule. Valid actions are “allow”, “deny” and “goto_next”.
description: Option<String>
An optional description for this resource.
direction: Option<String>
The direction in which this rule applies. Check the Direction enum for the list of possible values.
disabled: Option<bool>
Denotes whether the firewall policy rule is disabled. When set to true, the firewall policy rule is not enforced and traffic behaves as if it did not exist. If this is unspecified, the firewall policy rule will be enabled.
enable_logging: Option<bool>
Denotes whether to enable logging for a particular rule. If logging is enabled, logs will be exported to the configured export destination in Stackdriver. Logs may be exported to BigQuery or Pub/Sub. Note: you cannot enable logging on “goto_next” rules.
kind: Option<String>
[Output only] Type of the resource. Always compute#firewallPolicyRule for firewall policy rules
match: Option<FirewallPolicyRuleMatcher>
A match condition that incoming traffic is evaluated against. If it evaluates to true, the corresponding ‘action’ is enforced.
priority: Option<i32>
An integer indicating the priority of a rule in the list. The priority must be a positive value between 0 and 2147483647. Rules are evaluated from highest to lowest priority where 0 is the highest priority and 2147483647 is the lowest prority.
rule_name: Option<String>
An optional name for the rule. This field is not a unique identifier and can be updated.
rule_tuple_count: Option<i32>
[Output Only] Calculation of the complexity of a single firewall policy rule.
security_profile_group: Option<String>
A fully-qualified URL of a SecurityProfile resource instance. Example: https://networksecurity.googleapis.com/v1/projects/{project}/locations/{location}/securityProfileGroups/my-security-profile-group Must be specified if action = ‘apply_security_profile_group’ and cannot be specified for other actions.
target_resources: Vec<String>
A list of network resource URLs to which this rule applies. This field allows you to control which network’s VMs get this rule. If this field is left blank, all VMs within the organization will receive the rule.
A list of secure tags that controls which instances the firewall rule applies to. If targetSecureTag are specified, then the firewall rule applies only to instances in the VPC network that have one of those EFFECTIVE secure tags, if all the target_secure_tag are in INEFFECTIVE state, then this rule will be ignored. targetSecureTag may not be set at the same time as targetServiceAccounts. If neither targetServiceAccounts nor targetSecureTag are specified, the firewall rule applies to all instances on the specified network. Maximum number of target label tags allowed is 256.
target_service_accounts: Vec<String>
A list of service accounts indicating the sets of instances that are applied with this rule.
tls_inspect: Option<bool>
Boolean flag indicating if the traffic should be TLS decrypted. Can be set only if action = ‘apply_security_profile_group’ and cannot be set for other actions.
Implementations§
source§impl FirewallPolicyRule
impl FirewallPolicyRule
sourcepub fn tls_inspect(&self) -> bool
pub fn tls_inspect(&self) -> bool
Returns the value of tls_inspect
, or the default value if tls_inspect
is unset.
sourcepub fn rule_name(&self) -> &str
pub fn rule_name(&self) -> &str
Returns the value of rule_name
, or the default value if rule_name
is unset.
sourcepub fn direction(&self) -> &str
pub fn direction(&self) -> &str
Returns the value of direction
, or the default value if direction
is unset.
sourcepub fn action(&self) -> &str
pub fn action(&self) -> &str
Returns the value of action
, or the default value if action
is unset.
sourcepub fn security_profile_group(&self) -> &str
pub fn security_profile_group(&self) -> &str
Returns the value of security_profile_group
, or the default value if security_profile_group
is unset.
sourcepub fn disabled(&self) -> bool
pub fn disabled(&self) -> bool
Returns the value of disabled
, or the default value if disabled
is unset.
sourcepub fn enable_logging(&self) -> bool
pub fn enable_logging(&self) -> bool
Returns the value of enable_logging
, or the default value if enable_logging
is unset.
sourcepub fn rule_tuple_count(&self) -> i32
pub fn rule_tuple_count(&self) -> i32
Returns the value of rule_tuple_count
, or the default value if rule_tuple_count
is unset.
sourcepub fn description(&self) -> &str
pub fn description(&self) -> &str
Returns the value of description
, or the default value if description
is unset.
Trait Implementations§
source§impl Clone for FirewallPolicyRule
impl Clone for FirewallPolicyRule
source§fn clone(&self) -> FirewallPolicyRule
fn clone(&self) -> FirewallPolicyRule
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for FirewallPolicyRule
impl Debug for FirewallPolicyRule
source§impl Default for FirewallPolicyRule
impl Default for FirewallPolicyRule
source§impl Message for FirewallPolicyRule
impl Message for FirewallPolicyRule
source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
source§fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
source§fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
. Read moresource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
.source§impl PartialEq for FirewallPolicyRule
impl PartialEq for FirewallPolicyRule
source§fn eq(&self, other: &FirewallPolicyRule) -> bool
fn eq(&self, other: &FirewallPolicyRule) -> bool
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for FirewallPolicyRule
Auto Trait Implementations§
impl Freeze for FirewallPolicyRule
impl RefUnwindSafe for FirewallPolicyRule
impl Send for FirewallPolicyRule
impl Sync for FirewallPolicyRule
impl Unpin for FirewallPolicyRule
impl UnwindSafe for FirewallPolicyRule
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request