Secret scanner never scans anything #9068
Closed
felix-barz-brickmakers
started this conversation in
Bugs
Replies: 2 comments 1 reply
-
|
Hello @felix-barz-brickmakers
your secret contains trivy/pkg/fanal/secret/builtin-allow-rules.go Lines 16 to 21 in 3adfd98 example: ➜ echo 'AWS_SECRET_ACCESS_KEY = "AKIAIOSFODNN7EXAMPLE' > 1.txt
➜ trivy -q fs --scanners secret ./1.txt
Report Summary
┌────────┬──────┬─────────┐
│ Target │ Type │ Secrets │
├────────┼──────┼─────────┤
│ - │ - │ - │
└────────┴──────┴─────────┘
Legend:
- '-': Not scanned
- '0': Clean (no security findings detected)
➜ echo 'AWS_SECRET_ACCESS_KEY = "AKIAIOSFODNN7ASDFGHJ' > 2.txt
➜ trivy -q fs --scanners secret ./2.txt
Report Summary
┌────────┬──────┬─────────┐
│ Target │ Type │ Secrets │
├────────┼──────┼─────────┤
│ /2.txt │ text │ 1 │
└────────┴──────┴─────────┘
Legend:
- '-': Not scanned
- '0': Clean (no security findings detected)
/2.txt (secrets)
Total: 1 (UNKNOWN: 0, LOW: 0, MEDIUM: 0, HIGH: 0, CRITICAL: 1)
CRITICAL: AWS (aws-access-key-id)
════════════════════════════════════════════════════════════════════════════════
AWS Access Key ID
────────────────────────────────────────────────────────────────────────────────
/2.txt:1
────────────────────────────────────────────────────────────────────────────────
1 [ AWS_SECRET_ACCESS_KEY = "********************
2
────────────────────────────────────────────────────────────────────────────────
|
Beta Was this translation helpful? Give feedback.
1 reply
-
|
Missunderstanding of exclusions on my side |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Description
The secret scanner simply seems to not work at all. I have tried multiple combinations and variations, none do work.
The following issue could be related, but I think are not the same thing:
Desired Behavior
The scanner finds a secret.
Actual Behavior
It reports no files scanned.
Reproduction Steps
The result will look something like this:
Target
Filesystem
Scanner
Secret
Output Format
Table
Mode
Standalone
Debug Output
Operating System
macOS 15.5, but also happens in docker containers
Version
Checklist
trivy clean --allBeta Was this translation helpful? Give feedback.
All reactions