Skip to content

Commit

Permalink
Fix Honeycomb detector with both key formats (#777)
Browse files Browse the repository at this point in the history
  • Loading branch information
MNThomson committed Sep 2, 2022
1 parent 65a7855 commit d7123c6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkg/detectors/honeycomb/honeycomb.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@ var (
client = common.SaneHttpClient()

// Make sure that your group is surrounded in boundary characters such as below to reduce false positives.
keyPat = regexp.MustCompile(detectors.PrefixRegex([]string{"Honeycomb"}) + `\b([0-9a-zA-Z]{22})\b`)
// Older + Newer API key format. See pull#687 for discussion
keyPat = regexp.MustCompile(detectors.PrefixRegex([]string{"Honeycomb"}) + `\b([0-9a-f]{32}|[0-9a-zA-Z]{22})\b`)
)

// Keywords are used for efficiently pre-filtering chunks.
Expand Down

0 comments on commit d7123c6

Please sign in to comment.