Secrets scanner
Last updated: Oct 28, 2026
Quick scan vs. configuration file
The secrets scanner has two modes of operation.
Quick scan: Scan a file or directory directly from the command line, without a configuration file. The scanner applies only the verified rules:
ss scan /path/to/repositoryBy default, this command shows the findings in the console.
To exit with a non-zero status code when the scanner finds secrets, use --strict.
This option helps in CI/CD pipelines:
ss scan /path/to/repository --strictConfiguration file: Use a YAML configuration file when a quick scan is not sufficient. With a configuration file, you can:
- Include or exclude paths
- Use preview rules
- Write the results to a file
Use this command:
ss scan --config config.yamlThe remaining part of this page shows the configuration file options.
For the common configuration file keys of all the scanners, read Use a configuration file.
Specific configuration file keys
The secrets scanner has this key. Use it to configure the secret detection in a repository.
ss
This key sets the files that the scanner scans and how the detection works. All the options are optional:
include: The paths to the files or directories to scan, relative toworking_dir. If you do not use it, the scanner scans the fullworking_dir.exclude: Gitignore-style patterns for the files or directories to exclude. The scanner always excludes the.git/directory automatically.feature_preview: When you set it totrue, the scanner uses the detection rules that are in beta and that wait for approval. The default value isfalse.
For example:
ss:
include:
- src/
- config/
exclude:
- vendor/
- "**/*.lock"
feature_preview: falseOutput configuration
Use the top-level output key to write the results to a file:
file_path(optional): The path of the report. The scanner gets the format from the file extension: use.sariffor a SARIF 2.1.0 report, or.csvfor a CSV report. If you do not use it, the scanner shows the findings only in the console.
output:
file_path: /results/fluid-attacks-results.sarifConfiguration file examples
Scanning a repository
language: EN
working_dir: /path/to/repository
output:
file_path: /results/fluid-attacks-results.sarif
ss:
include:
- src/Excluding paths
language: EN
working_dir: .
output:
file_path: /results/fluid-attacks-results.sarif
ss:
include:
- src/
- config/
exclude:
- vendor/
- "**/*.lock"
- "**/node_modules/"Enabling preview rules
language: EN
working_dir: .
output:
file_path: /results/fluid-attacks-results.sarif
ss:
feature_preview: trueFailing the pipeline on findings
language: EN
strict: true
working_dir: .
output:
file_path: /results/fluid-attacks-results.sarif
ss:
include:
- src/Exporting results as CSV
language: EN
working_dir: .
output:
file_path: /results/fluid-attacks-results.csv
ss:
include:
- src/Do you have a question about the scanner, or did you find a problem? Read "Scanner FAQ".
Search for vulnerabilities in your apps for free with Fluid Attacks' automated security testing! Start your 21-day free trial and discover the benefits of the Essential plan. If you prefer the Advanced plan, which includes the expertise of Fluid Attacks' pentesting team, complete this contact form.