pub struct HookScanner { /* private fields */ }Implementations§
Source§impl HookScanner
impl HookScanner
Sourcepub fn with_skip_comments(self, skip: bool) -> Self
pub fn with_skip_comments(self, skip: bool) -> Self
Enables or disables comment skipping during scanning.
Sourcepub fn with_dynamic_rules(self, rules: Vec<DynamicRule>) -> Self
pub fn with_dynamic_rules(self, rules: Vec<DynamicRule>) -> Self
Adds dynamic rules loaded from custom YAML files.
Sourcepub fn with_strict_secrets(self, strict: bool) -> Self
pub fn with_strict_secrets(self, strict: bool) -> Self
Enables or disables strict secrets mode. When enabled, dummy key heuristics are disabled for test files.
Sourcepub fn with_inline_suppression(self, allow: bool) -> Self
pub fn with_inline_suppression(self, allow: bool) -> Self
Enables honoring of in-band suppression directives read from scanned content. Off by default (secure for untrusted scans).
Sourcepub fn with_recursive(self, recursive: bool) -> Self
pub fn with_recursive(self, recursive: bool) -> Self
Enables or disables recursive scanning. When disabled, only scans the immediate directory (max_depth = 1).
Sourcepub fn with_max_file_size(self, max_file_size: u64) -> Self
pub fn with_max_file_size(self, max_file_size: u64) -> Self
Overrides the maximum size (in bytes) of a file that will be read into memory. Files above the cap are refused before allocation.
Sourcepub fn with_progress_callback(self, callback: ProgressCallback) -> Self
pub fn with_progress_callback(self, callback: ProgressCallback) -> Self
Sets a progress callback that will be called for each scanned file.
Source§impl HookScanner
impl HookScanner
Trait Implementations§
Source§impl Default for HookScanner
impl Default for HookScanner
Auto Trait Implementations§
impl !RefUnwindSafe for HookScanner
impl !UnwindSafe for HookScanner
impl Freeze for HookScanner
impl Send for HookScanner
impl Sync for HookScanner
impl Unpin for HookScanner
impl UnsafeUnpin for HookScanner
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> 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