-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Ignored file extensions can now be configured in the PII scanner (
#559) secureli-558 I'm on a Go project, and need the ability to add additional file extensions, as the default set doesn't include them. Within the project, go.mod and go.sum were including entries that appeared to be phone numbers. There was no way to configure PII Scanner to ignore these files, as any practical contents of these files would not be PII. Rather than simply add them to the growing set of excluded extensions, I thought I would make the set configurable. As the set contains language-agnostic files, I also elected NOT to include the go-specific files in that set. A good follow-up work would be to also lay out, and selectively activate, additional extensions to ignore based on the languages configured in the repo. ## Changes <!-- A detailed list of changes --> * `pii_scanner` is added to the .secureli-config.yaml file structure * within that, `ignored_extensions` is a list of extensions that can be added to the default set * PII scanner will now ignore all files in its default set of excluded files, as well as anything provided in the PII-scanner's specific config. ## Testing I tested with a repo containing only some go-based package files (specifically go.mod and go.sum), which were appearing to the PII scanner to contain phone numbers. ## Clean Code Checklist <!-- This is here to support you. Some/most checkboxes may not apply to your change --> - [ ] Meets acceptance criteria for issue (n/a) - [ ] New logic is covered with automated tests - [x] Appropriate exception handling added - [x] Thoughtful logging included - [x] Documentation is updated - [ ] Follow-up work is documented in TODOs - [ ] TODOs have a ticket associated with them - [x] No commented-out code included <!-- Github-flavored markdown reference: https://docs.github.com/en/get-started/writing-on-github -->
- Loading branch information
1 parent
b30cfb0
commit 482cd57
Showing
6 changed files
with
51 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters