forked from mirrors/kingfisher
Added baseline feature with --baseline-file and --manage-baseline flags. Introduced --exclude option for skipping paths
This commit is contained in:
parent
0ab21ace99
commit
3520c5fba5
20 changed files with 401 additions and 21 deletions
|
|
@ -111,9 +111,13 @@ pub struct ContentFilteringArgs {
|
|||
#[arg(long("max-file-size"), default_value_t = 25.0)]
|
||||
pub max_file_size_mb: f64,
|
||||
|
||||
/// Use custom path-based ignore rules from the given file(s)
|
||||
#[arg(long, short, value_hint = ValueHint::FilePath)]
|
||||
pub ignore: Vec<PathBuf>,
|
||||
// /// Use custom path-based ignore rules from the given file(s)
|
||||
// #[arg(long, short, value_hint = ValueHint::FilePath)]
|
||||
// pub ignore: Vec<PathBuf>,
|
||||
/// Skip any file or directory whose path matches this glob pattern. Multiple
|
||||
/// patterns may be provided by repeating the flag.
|
||||
#[arg(long, value_name = "PATTERN")]
|
||||
pub exclude: Vec<String>,
|
||||
|
||||
/// If true, do NOT extract archive files
|
||||
#[arg(long("no-extract-archives"), default_value_t = false)]
|
||||
|
|
|
|||
|
|
@ -106,6 +106,14 @@ pub struct ScanArgs {
|
|||
/// Bytes of context before and after each match
|
||||
#[arg(long, default_value_t = 256, value_name = "BYTES")]
|
||||
pub snippet_length: usize,
|
||||
|
||||
/// Baseline file to filter known secrets
|
||||
#[arg(long, value_name = "FILE")]
|
||||
pub baseline_file: Option<std::path::PathBuf>,
|
||||
|
||||
/// Create or update the baseline file with current findings
|
||||
#[arg(long, default_value_t = false)]
|
||||
pub manage_baseline: bool,
|
||||
}
|
||||
|
||||
/// Confidence levels for findings
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue