Struct Advisory

Source
pub struct Advisory {
Show 21 fields pub id: u64, pub title: String, pub findings: Vec<Finding>, pub vulnerable_versions: Option<String>, pub module_name: Option<String>, pub severity: Severity, pub github_advisory_id: Option<String>, pub cves: Option<Vec<String>>, pub access: String, pub patched_versions: Option<String>, pub recommendation: String, pub cwe: Option<Vec<String>>, pub found_by: Option<String>, pub reported_by: Option<String>, pub created: OffsetDateTime, pub updated: Option<OffsetDateTime>, pub deleted: Option<OffsetDateTime>, pub references: Option<String>, pub npm_advisory_id: Option<String>, pub overview: String, pub url: String,
}
Expand description

advisory in report version 1

there is a field metadata in the output here but since I could not find information on its structure it is not parsed (was always null for me)

Fields§

§id: u64

numeric id

§title: String

human readable title

§findings: Vec<Finding>

where was the module affected by this advisory found in the dependency tree

§vulnerable_versions: Option<String>

which versions of the affected module are vulnerable

§module_name: Option<String>

name of the affected node module

§severity: Severity

how severe is the issue

§github_advisory_id: Option<String>

GitHub advisory Id

§cves: Option<Vec<String>>

CVE numbers

§access: String

if this advisory is public

§patched_versions: Option<String>

which versions of the affected package are patched

§recommendation: String

a human readable recommendation on how to fix this

§cwe: Option<Vec<String>>

a CWE (common weakness enumeration) identifier

§found_by: Option<String>

who found this security issue

§reported_by: Option<String>

who reported this security issue

§created: OffsetDateTime

when was this advisory created

§updated: Option<OffsetDateTime>

when was this advisory last updated

§deleted: Option<OffsetDateTime>

when was this deleted

§references: Option<String>

external references, all in one String, with newlines

§npm_advisory_id: Option<String>

npm advisory id

§overview: String

human-readable description

§url: String

URL to learn more

Trait Implementations§

Source§

impl Debug for Advisory

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for Advisory

Source§

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 Serialize for Advisory

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

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
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,