Skip to content

Releases: gitleaks/gitleaks

v8.23.0

13 Jan 15:04
db8e5e6
Compare
Choose a tag to compare

Changelog

READ THIS!!! The default gitleaks config now uses [[rules.allowlists]]

    # ⚠️ In v8.21.0 `[rules.allowlist]` was replaced with `[[rules.allowlists]]`.
    # This change was backwards-compatible: instances of `[rules.allowlist]` still  work.
    #
    # You can define multiple allowlists for a rule to reduce false positives.
    # A finding will be ignored if _ANY_ `[[rules.allowlists]]` matches.
    [[rules.allowlists]]
    description = "ignore commit A"
    # When multiple criteria are defined the default condition is "OR".
    # e.g., this can match on |commits| OR |paths| OR |stopwords|.
    condition = "OR"
    commits = [ "commit-A", "commit-B"]
    paths = [
      '''go\.mod''',
      '''go\.sum'''
    ]
    # note: stopwords targets the extracted secret, not the entire regex match
    # like 'regexes' does. (stopwords introduced in 8.8.0)
    stopwords = [
      '''client''',
      '''endpoint''',
    ]

    [[rules.allowlists]]
    # The "AND" condition can be used to make sure all criteria match.
    # e.g., this matches if |regexes| AND |paths| are satisfied.
    condition = "AND"
    # note: |regexes| defaults to check the _Secret_ in the finding.
    # Acceptable values for |regexTarget| are "secret" (default), "match", and "line".
    regexTarget = "match"
    regexes = [ '''(?i)parseur[il]''' ]
    paths = [ '''package-lock\.json''' ]

v8.22.1

30 Dec 16:25
b69b515
Compare
Choose a tag to compare

Changelog

v8.22.0

20 Dec 16:12
a91c671
Compare
Choose a tag to compare

Changelog

  • a91c671 replace std library regex engine with go-re2 (#1669)

This bumps the gitleaks binary size from around 8.5MB to 15MB but yields 2-4x speedup. Worth it imo. If you feel strongly against this change feel free to open an issue where we can discuss the tradeoffs in more depth. Credit to @ahrav

v8.21.4

20 Dec 15:36
906085f
Compare
Choose a tag to compare

Changelog

v8.21.3

19 Dec 20:38
Compare
Choose a tag to compare

Changelog

v8.21.2

28 Oct 13:32
43fae35
Compare
Choose a tag to compare

Changelog

v8.21.1

18 Oct 11:37
cf5334f
Compare
Choose a tag to compare

Changelog

v8.21.0

15 Oct 02:13
aabe381
Compare
Choose a tag to compare

Changelog

respect @rgmz @9999years

⚠️ Note: you may find some findings that were previously ignored if using .gitleaksignore pop up in your scans. This is due to a fix for a long standing bug where gitleaks would incorrectly report merge commit SHAs instead of the actual commit where a secret was introduced. See the following issues for more context:

v8.20.1

07 Oct 16:56
b2fbaeb
Compare
Choose a tag to compare

Changelog

v8.20.0

03 Oct 15:06
bf8a49f
Compare
Choose a tag to compare

Changelog

Huge huge thanks to @bplaxco for supporting b64 decoding, @recreator66 for bug fixes, and to @rgmz for his continued support of the project in the form of PRs and reviews. Thanks you!

New Feature: Decoding

Sometimes secrets are encoded in a way that can make them difficult to find
with just regex. Now you can tell gitleaks to automatically find and decode
encoded text. The flag --max-decode-depth enables this feature (the default
value "0" means the feature is disabled by default).

Recursive decoding is supported since decoded text can also contain encoded
text. The flag --max-decode-depth sets the recursion limit. Recursion stops
when there are no new segments of encoded text to decode, so setting a really
high max depth doesn't mean it will make that many passes. It will only make as
many as it needs to decode the text. Overall, decoding only minimally increases
scan times.

The findings for encoded text differ from normal findings in the following
ways:

  • The location points the bounds of the encoded text
    • If the rule matches outside the encoded text, the bounds are adjusted to
      include that as well
  • The match and secret contain the decoded value
  • Two tags are added decoded:<encoding> and decode-depth:<depth>

Currently supported encodings:

  • base64 (both standard and base64url)