Skip to main content

此版本的 GitHub Enterprise 已停止服务 2022-10-12. 即使针对重大安全问题,也不会发布补丁。 为了获得更好的性能、更高的安全性和新功能,请升级到最新版本的 GitHub Enterprise。 如需升级帮助,请联系 GitHub Enterprise 支持

About CodeQL code scanning in your CI system

You can analyze your code with CodeQL in a third-party continuous integration system and upload the results to your GitHub Enterprise Server instance. The resulting code scanning alerts are shown alongside any alerts generated within GitHub Enterprise Server.

Code scanning is available for organization-owned repositories in GitHub Enterprise Server. This feature requires a license for GitHub Advanced Security. 有关详细信息,请参阅“关于 GitHub Advanced Security”。

Note: Your site administrator must enable code scanning for your GitHub Enterprise Server instance before you can use this feature. For more information, see "Configuring code scanning for your appliance."

About CodeQL code scanning in your CI system

Code scanning 是一项功能,可用于分析 GitHub 仓库中的代� �,以查找安全漏洞和编� �错误。 分析发现的任何问题都显示在 GitHub Enterprise Server 中。 For information, see "About code scanning with CodeQL."

You can run CodeQL code scanning within GitHub Enterprise Server using GitHub Actions. Alternatively, if you use a third-party continuous integration or continuous delivery/deployment (CI/CD) system, you can run CodeQL analysis in your existing system and upload the results to your GitHub Enterprise Server instance.

将 CodeQL CLI 添� 到第三方系统,然后调用工具分析代� �并将 SARIF 结果上� 到 GitHub Enterprise Server。 由此产生的 code scanning 警报与 GitHub Enterprise Server 内生成的任何警报一起显示。 有关详细信息,请参阅“关于 CI 系统中的 CodeQL 代� �扫描”。

注意:上�  SARIF 数据以显示为 GitHub Enterprise Server 中的 code scanning 结果适用于启用了 GitHub Advanced Security 的组织拥有的数据库 。 有关详细信息,请参阅“管理存储库库的安全和分析设置”。

About the CodeQL CLI

The CodeQL CLI is a standalone product that you can use to analyze code. Its main purpose is to generate a database representation of a codebase, a CodeQL database. Once the database is ready, you can query it interactively, or run a suite of queries to generate a set of results in SARIF format and upload the results to your GitHub Enterprise Server instance.

Use the CodeQL CLI to analyze:

  • Dynamic languages, for example, JavaScript and Python.
  • Compiled languages, for example, C/C++, C# and Java.
  • Codebases written in a mixture of languages.

For more information, see "Installing CodeQL CLI in your CI system."

Notes:

  • The CodeQL CLI is available to customers with an Advanced Security license.

  • The CodeQL CLI is currently not compatible with non-glibc Linux distributions such as (musl-based) Alpine Linux.

Since version 2.6.3, the CodeQL CLI has had full feature parity with the CodeQL runner.

注意:CodeQL runner 将被弃用。 对于 GitHub Enterprise Server 3.0及更高版本,可以安装 CodeQL CLI 版本 2.6.3 来替换 CodeQL runner。

有关详细信息,请参阅 CodeQL 运行器弃用。 有关迁移到 CodeQL CLI 的信息,请参阅从 CodeQL 运行器迁移到 CodeQL CLI