Skip to content

Allow Keyword match with filename for custom detectors #3954

Open
@vexvec

Description

@vexvec

Description

Currently a custom detector needs at least 1 keyword defined. The detector is only executed if the keyword appears in the text. This is usually enough for most cases.
For custom detectors it would be a benefit if the detector would be executed if the keyword appears in the filename (full path) to make it possible to detect secrets that use a complete file and where there is no uniq keyword within the text that can be used to identify it.

Preferred Solution

Introduce an additional config option (keyword_in_filename) for custom detectors to enable that keywords are also checked against the filename.

Additional Context

References

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementpkg/sourcesPRs and Issues related to the `sources` package

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions