关于 GitHub Advanced Security 产品
GitHub 有许多功能可帮助你改进和维护代码的质量。 其中一些功能包含在所有计划中,例如依赖项关系图和 Dependabot alerts。
其他安全功能要求你购买 GitHub 的 Advanced Security 产品之一:
- GitHub Secret Protection, which includes features that help you detect and prevent secret leaks, such as secret scanning and push protection.
- GitHub Code Security, which includes features that help you find and fix vulnerabilities, like code scanning, premium Dependabot features, and dependency review.
公共存储库默认启用了某些功能,例如 code scanning 和 secret scanning。 若要在专用或内部存储库上运行该功能,则必须购买相关的 GitHub Advanced Security 产品。
必须参加 GitHub Team 或 GitHub Enterprise 计划才能购买 GitHub Code Security 或 GitHub Secret Protection。 有关详细信息,请参阅 GitHub 的计划 和 关于 GitHub Advanced Security 的计费。
GitHub Code Security
可以使用 GitHub Code Security 获取以下功能:
-
Code scanning:使用 CodeQL 或第三方工具搜索代码中潜在的安全漏洞和编程错误****。
-
CodeQL CLI:对软件项目本地运行 CodeQL 进程,或生成 code scanning 结果以上传到 GitHub****。
-
Copilot Autofix:获取 code scanning 警报的自动生成修补程序****。
-
安全活动:大规模减少安全债务****。
-
Dependabot 的 自定义自动分类规则:通过自动处理要忽略、推迟或触发 Dependabot 安全更新的警报,大规模管理 Dependabot alerts****。
-
依赖关系评审: 显示更改对依赖项的完整影响,并在合并拉取请求之前查看全部有漏洞的版本的详细信息。
-
安全概览:了解整个组织的风险分布****。
下表总结了公共和私有存储库的 GitHub Code Security 功能的可用性。
公共存储库 无 GitHub Secret Protection | 专用存储库 无 GitHub Code Security | 公共或专用存储库 有 GitHub Code Security | |
---|---|---|---|
Code scanning | |||
CodeQL CLI | |||
Copilot Autofix | |||
安全活动 | |||
自定义自动分类规则 | |||
依赖项检查 | |||
安全概述 |
有关功能的详细信息,请参阅 GitHub 安全功能。
GitHub Secret Protection
可以使用 GitHub Secret Protection 获取以下功能:
-
Secret scanning****:检测已签入仓库的机密,例如密钥和令牌,并接收警报。
-
推送保护****:阻止包含机密的提交,防止发生机密泄漏。
-
Copilot 机密扫描****:利用 AI 检测已签入仓库的非结构化凭据(如密码)。
-
自定义模式****:检测和防止组织特定的机密泄漏。
-
推送保护委派绕过和委派警报解除********:实施审批流程,以便更好地控制企业中谁可以执行敏感操作,支持大规模治理。
-
安全概览****:了解整个组织的风险分布。
下表总结了公共和私有存储库的 GitHub Secret Protection 功能的可用性。
公共存储库 无 GitHub Secret Protection | 专用存储库 无 GitHub Secret Protection | 公共或专用存储库 有 GitHub Secret Protection | |
---|---|---|---|
机密扫描 | |||
推送保护 | |||
Copilot 机密扫描 | |||
自定义模式 | |||
推送保护委派绕过 | |||
安全概述 |
有关各个功能的详细信息,请参阅 GitHub 安全功能。
评估组织的机密泄漏情况
使用 GitHub Team 和 GitHub Enterprise 的组织可以免费运行报告,检查其组织中是否存在泄露的机密信息。 这有助于你了解组织中仓库当前面临的机密信息泄露风险,以及了解有多少现有的机密泄露本可以通过 GitHub Secret Protection 进行防止。 请参阅 关于机密风险评估。
在企业中部署 GitHub Code Security 和 GitHub Secret Protection
如需了解在高级别规划 GitHub Code Security 和 GitHub Secret Protection 部署的需知事项,以及若需查看我们推荐的推出阶段,请参阅 大规模采用 GitHub Advanced Security。
启用功能
可以使用 GitHub-recommended security configuration 快速大规模启用安全功能,这是一组可应用于组织中存储库的安全启用设置。 然后,可以使用 global settings 在组织级别进一步自定义 Advanced Security 功能。 请参阅“关于批量启用安全功能”。
如果你参与的是 GitHub Team 或 GitHub Enterprise 计划,则整个团队或企业的许可证使用将显示在许可证页上。 请参阅“查看和下载 Advanced Security 的许可使用情况”。
关于 GitHub Advanced Security 认证
通过 GitHub Certifications 获取 GitHub Advanced Security 证书,可以突出展示你的知识。 该认证可检验你在漏洞识别、工作流安全性和可靠的安全实现方面的专业知识。 请参阅 关于 GitHub Certifications。
关于使用 Azure Repos 的 GitHub Advanced Security
如果要将 GitHub Advanced Security 与 Azure Repos 配合使用,请参阅资源站点中的 GitHub Advanced Security 和 Azure DevOps。 有关文档,请参阅 Microsoft Learn 中的配置 GitHub Advanced Security for Azure DevOps。