Skip to content

Commit 4ad9d40

Browse files
committed
fix: add support for artifactory identity tokens
1 parent 63375ed commit 4ad9d40

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

detect_secrets/plugins/artifactory.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ class ArtifactoryDetector(RegexBasedDetector):
1515
re.compile(r'(?:(?<==|:|")|(?<=\s)|(?<=^))AKC[a-zA-Z0-9]{10,}'), # api token
1616
# artifactory encrypted passwords begin with AP[A-Z]
1717
re.compile(r'(?:(?<==|:|")|(?<=\s)|(?<=^))AP[\dABCDEF][a-zA-Z0-9]{8,}'), # password
18+
# artifactory identity tokens are different (base64 encoded reftkn:) and 64 chars
19+
re.compile(r'(?:(?<==|:|")|(?<=\s)|(?<=^))cmVmdGtuOg{54,54}'), #identity token
1820
]
1921

2022
artifactory_url = 'na.artifactory.swg-devops.com/artifactory'

0 commit comments

Comments
 (0)