This is a small wrapper for Gittyleaks to add recursiveness and better output control.
I wrote this because I had a need to scan multiple Git repositories w/ Gittyleaks. This script will iterate through the target directory, assuming each nested directory is a Git repo, and run GL on them. The output will then be written to the output directory, with the following format: <output dir>/<scanned repo>_secrets.txt
If you couldn't tell, it requires Gittyleaks to be installed.
- ./secretScan.sh /repositories /repositories/secrets
-> repositories/
----> repo1
----> repo2
----> repo3
-> repositories/
----> repo1
----> repo2
----> repo3
----> secrets/
-------> repo1_secrets.txt
-------> repo2_secrets.txt
-------> repo3_secrets.txt