GitHub 的「Oops 提交」洩露的秘密

Back
Category : News

GitHub Archive 記錄晒所有公開嘅 commit,包括刪除咗嘅,當做「zero-commit」PushEvents 啦。Sharon Brizinov 掃描咗自2020年起嘅呢啲事件,發現咗價值25k美元嘅bug bounties秘密喎。
Force pushes 用嚟隱藏錯誤,好似洩露憑證咁,會留下 dangling commits 喺 GitHub 上仍然可以訪問到。
Brizinov 同 Truffle Security 合作,開發咗開源嘅 Force Push Scanner 嚟識別呢啲 commit 入面嘅秘密。
呢個工具用 GitHub Event API 同 GH Archive 嚟獲取同掃描刪除咗嘅 commit。
過程包括最小化 clone repo,獲取特定 commit,同用 TruffleHog 掃描秘密。
手動審查、分類平台同 AI 幫助識別有影響力嘅秘密,包括案例如防止供應鏈妥協透過洩露 GitHub PAT。
呢個項目突出咗刪除 commit 永遠唔會真正移除,強調需要立即撤銷受損秘密。
https://trufflesecurity.com/blog/guest-post-how-i-scanned-all-of-github-s-oops-commits-for-leaked-secrets