diff --git a/pkg/detectors/atlassian/v1/atlassian.go b/pkg/detectors/atlassian/v1/atlassian.go
index a1d45830c..689c33b8a 100644
--- a/pkg/detectors/atlassian/v1/atlassian.go
+++ b/pkg/detectors/atlassian/v1/atlassian.go
@@ -35,7 +35,7 @@ var _ detectors.Versioner = (*Scanner)(nil)
var (
defaultClient = 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{"atlassian"}) + `\b([a-zA-Z-0-9]{24})\b`)
+ keyPat = regexp.MustCompile(detectors.PrefixRegex([]string{"atlassian"}) + `\b([a-zA-Z0-9]{24})\b`)
)
// Keywords are used for efficiently pre-filtering chunks.
diff --git a/pkg/detectors/atlassian/v1/atlassian_test.go b/pkg/detectors/atlassian/v1/atlassian_test.go
index 335f4bdaa..3724bde41 100644
--- a/pkg/detectors/atlassian/v1/atlassian_test.go
+++ b/pkg/detectors/atlassian/v1/atlassian_test.go
@@ -41,6 +41,15 @@ func TestAtlassian_Pattern(t *testing.T) {
`,
want: []string{"r6RkiQao3PgqY9MOKtonpJdU"},
},
+ {
+ name: "confluence macro-id near atlassian url - no match",
+ input: `
+ link
+
+
+ `,
+ want: nil,
+ },
}
for _, test := range tests {