pub enum SecurityIssue {
Critical {
description: &'static str,
impact: &'static str,
remediation: &'static str,
},
High {
description: &'static str,
impact: &'static str,
remediation: &'static str,
},
Medium {
description: &'static str,
impact: &'static str,
remediation: &'static str,
},
Low {
description: &'static str,
impact: &'static str,
remediation: &'static str,
},
}Expand description
Security issue found during audit.
Variants§
Critical
Critical security vulnerability
Fields
High
High severity issue
Fields
Medium
Medium severity issue
Fields
Low
Low severity issue
Implementations§
Source§impl SecurityIssue
impl SecurityIssue
Sourcepub fn severity(&self) -> &'static str
pub fn severity(&self) -> &'static str
Returns the severity level of this security issue as a string.
The severity levels are ordered from most to least critical:
- CRITICAL: Immediate security risk requiring urgent attention
- HIGH: Significant security risk that should be addressed soon
- MEDIUM: Moderate security concern to be addressed in due course
- LOW: Minor security issue with limited impact
§Returns
A static string slice containing the severity level
§Examples
use clock_curve_math::ct::audit::SecurityIssue;
let issue = SecurityIssue::Critical {
description: "Timing vulnerability detected",
impact: "Keys may be recoverable",
remediation: "Implement constant-time operations"
};
assert_eq!(issue.severity(), "CRITICAL");Sourcepub fn description(&self) -> &str
pub fn description(&self) -> &str
Returns the description of this security issue.
The description provides details about what security problem was detected, including the specific vulnerability or issue found.
§Returns
A string slice containing the issue description
§Examples
use clock_curve_math::ct::audit::SecurityIssue;
let issue = SecurityIssue::High {
description: "Data-dependent operations detected",
impact: "Side-channel information leakage possible",
remediation: "Use constant-time primitives"
};
assert_eq!(issue.description(), "Data-dependent operations detected");Trait Implementations§
Source§impl Clone for SecurityIssue
impl Clone for SecurityIssue
Source§fn clone(&self) -> SecurityIssue
fn clone(&self) -> SecurityIssue
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 moreAuto Trait Implementations§
impl Freeze for SecurityIssue
impl RefUnwindSafe for SecurityIssue
impl Send for SecurityIssue
impl Sync for SecurityIssue
impl Unpin for SecurityIssue
impl UnwindSafe for SecurityIssue
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