trufflehog 3.57 releases: Searches through git repositories for secrets, digging deep into commit history and branches
Truffle Hog
Searches through git repositories for secrets, digging deep into commit history and branches. This is effective at finding secrets accidentally committed.
NEW
Trufflehog previously functioned by running entropy checks on git diffs. This functionality still exists, but high signal regex checks have been added, and the ability to suppress entropy checking has also been added.
These features help cut down on noise and makes the tool easier to shove into a devops pipeline.
truffleHog –regex –entropy=False https://github.com/dxa4481/truffleHog.git
or
truffleHog file:///user/dxa4481/codeprojects/truffleHog/
How it works
This module will go through the entire commit history of each branch, check each diff from each commit, and check for secrets. This is both by regex and by entropy. For entropy checks, trufflehog will evaluate the Shannon entropy for both the base64 charset and hexadecimal charset for every blob of text greater than 20 characters comprised of those character sets in each diff. If at any point a high entropy string >20 characters is detected, it will print to the screen.
Changelog v3.57
- Update sonarcloud.go by @ankushgoel27 in #1784
- fixed rubygems detector by @ankushgoel27 in #1781
- Ability to update line number in link by @ahrav in #1788
- [bug] – fix link line by @ahrav in #1793
- Add ability to dynamically scale concurrently running sources by @mcastorina in #1790
- Bump github.com/mattn/go-isatty from 0.0.18 to 0.0.19 by @dependabot in #1794
- Bump cloud.google.com/go/storage from 1.31.0 to 1.33.0 by @dependabot in #1795
- Bump github.com/getsentry/sentry-go from 0.22.0 to 0.24.1 by @dependabot in #1797
- Bump github.com/charmbracelet/bubbletea from 0.24.1 to 0.24.2 by @dependabot in #1798
- Bump github.com/go-ldap/ldap/v3 from 3.4.5 to 3.4.6 by @dependabot in #1796
- Bump golang.org/x/oauth2 from 0.10.0 to 0.12.0 by @dependabot in #1799
- updating uri detector to use tri-state verification by @0x1 in #1791
- Adding new function SetProgressOngoing by @0x1 in #1802
- aggregate detector tests daily by @dustin-decker in #1800
- fix detector test action by @dustin-decker in #1805
- add line to link for azure repos by @ahrav in #1801
- Update protos image to use correct go version by @samdatkins in #1810
- examples folder by @zricethezav in #1734
- Use real url for custom generic detector example by @zricethezav in #1811
- adding support for new version of figma token by @0x1 in #1813
Install
pip install truffleHog
Usage
Customizing
Custom regexes can be added to the following file:
truffleHog/truffleHog/regexChecks.py
Things like subdomain enumeration, s3 bucket detection, and other useful regexes highly custom to the situation can be added.
Feel free to also contribute high signal regexes upstream that you think will benefit the community. Things like Azure keys, Twilio keys, Google Compute keys, are welcome, provided a high signal regex can be constructed.
Copyright (C) 2017 dxa4481
Source: https://github.com/dxa4481/