pub struct VulnerabilityRef {Show 13 fields
pub id: String,
pub source: VulnerabilitySource,
pub severity: Option<Severity>,
pub cvss: Vec<CvssScore>,
pub affected_versions: Vec<String>,
pub remediation: Option<Remediation>,
pub description: Option<String>,
pub cwes: Vec<String>,
pub published: Option<DateTime<Utc>>,
pub modified: Option<DateTime<Utc>>,
pub is_kev: bool,
pub kev_info: Option<KevInfo>,
pub vex_status: Option<VexStatus>,
}Expand description
Reference to a vulnerability affecting a component
Fields§
§id: StringVulnerability identifier (CVE, GHSA, etc.)
source: VulnerabilitySourceSource database
severity: Option<Severity>Severity level
cvss: Vec<CvssScore>CVSS scores
affected_versions: Vec<String>Affected version ranges
remediation: Option<Remediation>Remediation information
description: Option<String>Description
cwes: Vec<String>CWE identifiers
published: Option<DateTime<Utc>>Published date
modified: Option<DateTime<Utc>>Last modified date
is_kev: boolWhether this CVE is in CISA’s Known Exploited Vulnerabilities catalog
kev_info: Option<KevInfo>KEV-specific metadata if applicable
vex_status: Option<VexStatus>Per-vulnerability VEX status (from external VEX documents or embedded analysis)
Implementations§
Source§impl VulnerabilityRef
impl VulnerabilityRef
Sourcepub const fn new(id: String, source: VulnerabilitySource) -> Self
pub const fn new(id: String, source: VulnerabilitySource) -> Self
Create a new vulnerability reference
Sourcepub const fn is_actively_exploited(&self) -> bool
pub const fn is_actively_exploited(&self) -> bool
Check if this vulnerability is actively exploited (KEV)
Check if this is a ransomware-related KEV entry
Sourcepub fn with_vex_status(self, vex: VexStatus) -> Self
pub fn with_vex_status(self, vex: VexStatus) -> Self
Set per-vulnerability VEX status
Sourcepub fn max_cvss_score(&self) -> Option<f32>
pub fn max_cvss_score(&self) -> Option<f32>
Get the highest CVSS score
Trait Implementations§
Source§impl Clone for VulnerabilityRef
impl Clone for VulnerabilityRef
Source§fn clone(&self) -> VulnerabilityRef
fn clone(&self) -> VulnerabilityRef
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for VulnerabilityRef
impl Debug for VulnerabilityRef
Source§impl<'de> Deserialize<'de> for VulnerabilityRef
impl<'de> Deserialize<'de> for VulnerabilityRef
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Hash for VulnerabilityRef
impl Hash for VulnerabilityRef
Source§impl PartialEq for VulnerabilityRef
impl PartialEq for VulnerabilityRef
Source§impl Serialize for VulnerabilityRef
impl Serialize for VulnerabilityRef
impl Eq for VulnerabilityRef
Auto Trait Implementations§
impl Freeze for VulnerabilityRef
impl RefUnwindSafe for VulnerabilityRef
impl Send for VulnerabilityRef
impl Sync for VulnerabilityRef
impl Unpin for VulnerabilityRef
impl UnsafeUnpin for VulnerabilityRef
impl UnwindSafe for VulnerabilityRef
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more