#[non_exhaustive]pub struct Cvssv3 {
pub base_score: f64,
pub attack_vector: AttackVector,
pub attack_complexity: AttackComplexity,
pub privileges_required: PrivilegesRequired,
pub user_interaction: UserInteraction,
pub scope: Scope,
pub confidentiality_impact: Impact,
pub integrity_impact: Impact,
pub availability_impact: Impact,
/* private fields */
}Expand description
Common Vulnerability Scoring System version 3.
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.base_score: f64The base score is a function of the base metric scores.
attack_vector: AttackVectorBase Metrics Represents the intrinsic characteristics of a vulnerability that are constant over time and across user environments. This metric reflects the context by which vulnerability exploitation is possible.
attack_complexity: AttackComplexityThis metric describes the conditions beyond the attacker’s control that must exist in order to exploit the vulnerability.
privileges_required: PrivilegesRequiredThis metric describes the level of privileges an attacker must possess before successfully exploiting the vulnerability.
user_interaction: UserInteractionThis metric captures the requirement for a human user, other than the attacker, to participate in the successful compromise of the vulnerable component.
scope: ScopeThe Scope metric captures whether a vulnerability in one vulnerable component impacts resources in components beyond its security scope.
confidentiality_impact: ImpactThis metric measures the impact to the confidentiality of the information resources managed by a software component due to a successfully exploited vulnerability.
integrity_impact: ImpactThis metric measures the impact to integrity of a successfully exploited vulnerability.
availability_impact: ImpactThis metric measures the impact to the availability of the impacted component resulting from a successfully exploited vulnerability.
Implementations§
Source§impl Cvssv3
impl Cvssv3
pub fn new() -> Self
Sourcepub fn set_base_score<T: Into<f64>>(self, v: T) -> Self
pub fn set_base_score<T: Into<f64>>(self, v: T) -> Self
Sourcepub fn set_attack_vector<T: Into<AttackVector>>(self, v: T) -> Self
pub fn set_attack_vector<T: Into<AttackVector>>(self, v: T) -> Self
Sets the value of attack_vector.
§Example
use google_cloud_securitycenter_v2::model::cvssv_3::AttackVector;
let x0 = Cvssv3::new().set_attack_vector(AttackVector::Network);
let x1 = Cvssv3::new().set_attack_vector(AttackVector::Adjacent);
let x2 = Cvssv3::new().set_attack_vector(AttackVector::Local);Sourcepub fn set_attack_complexity<T: Into<AttackComplexity>>(self, v: T) -> Self
pub fn set_attack_complexity<T: Into<AttackComplexity>>(self, v: T) -> Self
Sets the value of attack_complexity.
§Example
use google_cloud_securitycenter_v2::model::cvssv_3::AttackComplexity;
let x0 = Cvssv3::new().set_attack_complexity(AttackComplexity::Low);
let x1 = Cvssv3::new().set_attack_complexity(AttackComplexity::High);Sourcepub fn set_privileges_required<T: Into<PrivilegesRequired>>(self, v: T) -> Self
pub fn set_privileges_required<T: Into<PrivilegesRequired>>(self, v: T) -> Self
Sets the value of privileges_required.
§Example
use google_cloud_securitycenter_v2::model::cvssv_3::PrivilegesRequired;
let x0 = Cvssv3::new().set_privileges_required(PrivilegesRequired::None);
let x1 = Cvssv3::new().set_privileges_required(PrivilegesRequired::Low);
let x2 = Cvssv3::new().set_privileges_required(PrivilegesRequired::High);Sourcepub fn set_user_interaction<T: Into<UserInteraction>>(self, v: T) -> Self
pub fn set_user_interaction<T: Into<UserInteraction>>(self, v: T) -> Self
Sets the value of user_interaction.
§Example
use google_cloud_securitycenter_v2::model::cvssv_3::UserInteraction;
let x0 = Cvssv3::new().set_user_interaction(UserInteraction::None);
let x1 = Cvssv3::new().set_user_interaction(UserInteraction::Required);Sourcepub fn set_confidentiality_impact<T: Into<Impact>>(self, v: T) -> Self
pub fn set_confidentiality_impact<T: Into<Impact>>(self, v: T) -> Self
Sets the value of confidentiality_impact.
§Example
use google_cloud_securitycenter_v2::model::cvssv_3::Impact;
let x0 = Cvssv3::new().set_confidentiality_impact(Impact::High);
let x1 = Cvssv3::new().set_confidentiality_impact(Impact::Low);
let x2 = Cvssv3::new().set_confidentiality_impact(Impact::None);Sourcepub fn set_integrity_impact<T: Into<Impact>>(self, v: T) -> Self
pub fn set_integrity_impact<T: Into<Impact>>(self, v: T) -> Self
Sets the value of integrity_impact.
§Example
use google_cloud_securitycenter_v2::model::cvssv_3::Impact;
let x0 = Cvssv3::new().set_integrity_impact(Impact::High);
let x1 = Cvssv3::new().set_integrity_impact(Impact::Low);
let x2 = Cvssv3::new().set_integrity_impact(Impact::None);Sourcepub fn set_availability_impact<T: Into<Impact>>(self, v: T) -> Self
pub fn set_availability_impact<T: Into<Impact>>(self, v: T) -> Self
Sets the value of availability_impact.
§Example
use google_cloud_securitycenter_v2::model::cvssv_3::Impact;
let x0 = Cvssv3::new().set_availability_impact(Impact::High);
let x1 = Cvssv3::new().set_availability_impact(Impact::Low);
let x2 = Cvssv3::new().set_availability_impact(Impact::None);