GitGuardian / ggshield

Find and fix 400+ types of hardcoded secrets and 70+ types of infrastructure-as-code misconfigurations.
https://gitguardian.com
MIT License
1.68k stars 150 forks source link

feat: add --no-mirror option #981

Closed guedou closed 1 week ago

guedou commented 3 weeks ago

Context

Cloning a repository with git clone --mirror may retrieve more git objects, and lead to more secrets being detected.

What has been done

By default ggshield now used --mirror. A new command line option could be used to disable this feature.

Validation

Clone https://github.com/nightwatchcybersecurity/gb_testrepo_delete?tab=readme-ov-filewith and without the new option.

codecov[bot] commented 1 week ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 91.90%. Comparing base (537dbb8) to head (b0a6765). Report is 4 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #981 +/- ## ======================================= Coverage 91.90% 91.90% ======================================= Files 181 181 Lines 7593 7593 ======================================= Hits 6978 6978 Misses 615 615 ``` | [Flag](https://app.codecov.io/gh/GitGuardian/ggshield/pull/981/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GitGuardian) | Coverage Δ | | |---|---|---| | [unittests](https://app.codecov.io/gh/GitGuardian/ggshield/pull/981/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GitGuardian) | `91.90% <ø> (ø)` | | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=GitGuardian#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.