| title | CodeQL query suites | ||||||
|---|---|---|---|---|---|---|---|
| shortTitle | CodeQL query suites | ||||||
| intro | You can choose from different built-in {% data variables.product.prodname_codeql %} query suites to use in your {% data variables.product.prodname_codeql %} {% data variables.product.prodname_code_scanning %} setup. | ||||||
| product | {% data reusables.gated-features.codeql %} | ||||||
| versions |
|
||||||
| redirect_from |
|
||||||
| contentType | concepts | ||||||
| category |
|
Query suites allow you to pass multiple queries to {% data variables.product.prodname_codeql %} without having to specify the path to each query file individually. They provide a way of selecting queries based on their filename, metadata properties, or location on disk or in a {% data variables.product.prodname_codeql %} pack.
You should use query suites for the queries that you want to frequently use in your {% data variables.product.prodname_codeql %} analyses. You can use a built-in query suite available through {% data variables.product.github %}, or you can create your own.
The built-in {% data variables.product.prodname_codeql %} query suites, default and security-extended, are created and maintained by {% data variables.product.prodname_dotcom %}. Both of these query suites are available with default setup for every {% data variables.product.prodname_codeql %}-supported language.
Organization owners and security managers can recommend a query suite for use with default setup throughout their organization. For more information, see AUTOTITLE.
For a complete list of queries included in each query suite for every language, see AUTOTITLE.
- The
defaultquery suite is the group of queries run by default in {% data variables.product.prodname_codeql %} {% data variables.product.prodname_code_scanning %} on {% data variables.product.prodname_dotcom %}. - The queries in the
defaultquery suite are highly precise and return few false positive {% data variables.product.prodname_code_scanning %} results. Relative to thesecurity-extendedquery suite, thedefaultsuite returns fewer low-confidence {% data variables.product.prodname_code_scanning %} results. - This query suite is available for use with default setup for {% data variables.product.prodname_code_scanning %}.
- The
security-extendedquery suite consists of all the queries in thedefaultquery suite, plus additional queries with slightly lower precision and severity. - Relative to the
defaultquery suite, thesecurity-extendedsuite may return a greater number of false positive {% data variables.product.prodname_code_scanning %} results. - This query suite is available for use with default setup for {% data variables.product.prodname_code_scanning %}, and is referred to as the "Extended" query suite on {% data variables.product.prodname_dotcom %}.
To use a custom query suite, you must configure advanced setup for {% data variables.product.prodname_codeql %} {% data variables.product.prodname_code_scanning %}. For more information, see AUTOTITLE.
Query suite definitions are stored in YAML files with the extension .qls. A suite definition is a sequence of instructions, where each instruction is a YAML mapping with (usually) a single key. The instructions are executed in the order they appear in the query suite definition. After all the instructions in the suite definition have been executed, the result is a set of selected queries. For more information, see AUTOTITLE.