使用机密扫描和推送保护
Secret scanning scans for and detects secrets that have been checked into a repository. Push protection proactively secures you against leaking secrets by blocking pushes containing secrets.
谁可以使用此功能?
Secret scanning 可用于以下存储库:
- 启用了 GitHub Advanced Security 的组织拥有的存储库
- 启用了 GitHub Advanced Security 的企业的 用户拥有的存储库
从命令行使用推送保护
Secret scanning scans for and detects secrets that have been checked into a repository. Push protection proactively secures you against leaking secrets by blocking pushes containing secrets.
使用 GitHub UI 中的推送保护
了解 secret scanning 在更改中检测到机密时取消阻止提交的选项。