Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added packagecloud scanner #404

Merged
merged 10 commits into from
Apr 21, 2022
Merged

Added packagecloud scanner #404

merged 10 commits into from
Apr 21, 2022

Conversation

roxanne-tampus
Copy link
Contributor

No description provided.

Copy link
Collaborator

@ahrav ahrav left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 small suggestion otherwise lgtm. 👍

client = common.SaneHttpClient()

//Make sure that your group is surrounded in boundry characters such as below to reduce false positives
keyPat = regexp.MustCompile(detectors.PrefixRegex([]string{"packagecloud"}) + `\b([0-9a-z]{48})\b`)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: this regex can be made a bit stricter \b([0-9a-f]{48})\b You can only look for a-z since this is an encoded.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I just pushed the enhancement.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some extra context: it's hex encoding that uses the a-f characters rather than a-z

@dustin-decker dustin-decker merged commit bbff984 into trufflesecurity:main Apr 21, 2022
bill-rich pushed a commit that referenced this pull request May 2, 2022
* added new protos

* added new detectors

* added packagecloud scanner

* updated regex
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants