Skip to content

Avoid verifying the same key multiple times in a session #2262

Open
@bugbaba

Description

@bugbaba

Hello Team,

Description

Verify a key only once even if it is found multiple times in the same or different files.

For example, in the below screenshot, we can see that the same gitlab key(revoked) is getting verified twice as it's mentioned twice in the file.

image

Preferred Solution

To avoid wasting resources on re-verification and hitting detectors with the same keys multiple times, it is ideal to check if the given key has already been verified.

Maybe a check before the if verify block? to confirm if the key has not been verified previously.

--
Best Regards,
@bugbaba

Metadata

Metadata

Labels

enhancementpkg/detectorsPRs and Issues related to the `detectors` package

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions