pub struct SecurityAnalysisConfig {Show 27 fields
pub include_low_severity: bool,
pub include_info_level: bool,
pub check_secrets: bool,
pub check_code_patterns: bool,
pub check_infrastructure: bool,
pub check_compliance: bool,
pub javascript_enabled: bool,
pub python_enabled: bool,
pub rust_enabled: bool,
pub frameworks_to_check: Vec<String>,
pub ignore_patterns: Vec<String>,
pub include_patterns: Vec<String>,
pub skip_gitignored_files: bool,
pub downgrade_gitignored_severity: bool,
pub check_git_history: bool,
pub check_env_files: bool,
pub warn_on_public_env_vars: bool,
pub sensitive_env_keywords: Vec<String>,
pub check_package_json: bool,
pub check_node_modules: bool,
pub framework_env_prefixes: Vec<String>,
pub max_findings_per_file: Option<usize>,
pub deduplicate_findings: bool,
pub group_by_severity: bool,
pub max_file_size_mb: Option<usize>,
pub parallel_analysis: bool,
pub analysis_timeout_seconds: Option<u64>,
}Expand description
Configuration for security analysis
Fields§
§include_low_severity: bool§include_info_level: bool§check_secrets: bool§check_code_patterns: bool§check_infrastructure: bool§check_compliance: bool§javascript_enabled: bool§python_enabled: bool§rust_enabled: bool§frameworks_to_check: Vec<String>§ignore_patterns: Vec<String>§include_patterns: Vec<String>§skip_gitignored_files: bool§downgrade_gitignored_severity: bool§check_git_history: bool§check_env_files: bool§warn_on_public_env_vars: bool§sensitive_env_keywords: Vec<String>§check_package_json: bool§check_node_modules: bool§framework_env_prefixes: Vec<String>§max_findings_per_file: Option<usize>§deduplicate_findings: bool§group_by_severity: bool§max_file_size_mb: Option<usize>§parallel_analysis: bool§analysis_timeout_seconds: Option<u64>Implementations§
Source§impl SecurityAnalysisConfig
impl SecurityAnalysisConfig
Sourcepub fn for_javascript() -> Self
pub fn for_javascript() -> Self
Create a configuration optimized for JavaScript/TypeScript projects
Sourcepub fn for_python() -> Self
pub fn for_python() -> Self
Create a configuration optimized for Python projects
Sourcepub fn high_security() -> Self
pub fn high_security() -> Self
Create a high-security configuration with strict settings
Sourcepub fn should_analyze_file(&self, file_path: &Path) -> bool
pub fn should_analyze_file(&self, file_path: &Path) -> bool
Check if a file should be analyzed based on patterns
Sourcepub fn is_sensitive_env_var(&self, var_name: &str) -> bool
pub fn is_sensitive_env_var(&self, var_name: &str) -> bool
Check if an environment variable name appears sensitive
Sourcepub fn is_public_env_var(&self, var_name: &str) -> bool
pub fn is_public_env_var(&self, var_name: &str) -> bool
Check if an environment variable should be public (safe for client-side)
Sourcepub fn max_file_size_bytes(&self) -> Option<usize>
pub fn max_file_size_bytes(&self) -> Option<usize>
Get the maximum file size to analyze in bytes
Trait Implementations§
Source§impl Clone for SecurityAnalysisConfig
impl Clone for SecurityAnalysisConfig
Source§fn clone(&self) -> SecurityAnalysisConfig
fn clone(&self) -> SecurityAnalysisConfig
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 SecurityAnalysisConfig
impl Debug for SecurityAnalysisConfig
Source§impl Default for SecurityAnalysisConfig
impl Default for SecurityAnalysisConfig
Source§impl<'de> Deserialize<'de> for SecurityAnalysisConfig
impl<'de> Deserialize<'de> for SecurityAnalysisConfig
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 From<SecurityConfigPreset> for SecurityAnalysisConfig
impl From<SecurityConfigPreset> for SecurityAnalysisConfig
Source§fn from(preset: SecurityConfigPreset) -> Self
fn from(preset: SecurityConfigPreset) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for SecurityAnalysisConfig
impl RefUnwindSafe for SecurityAnalysisConfig
impl Send for SecurityAnalysisConfig
impl Sync for SecurityAnalysisConfig
impl Unpin for SecurityAnalysisConfig
impl UnwindSafe for SecurityAnalysisConfig
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<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