Skip to Content

GitHub Advanced Security: What Severity Level Causes Pull Request Check Failure in GitHub Code Scanning?

Discover the default severity level that triggers a pull request check failure during GitHub code scanning. Learn how to ensure your code meets the highest standards of security and quality.

Table of Contents

Question

By default, which severity level causes a pull-request check failure during code scanning?

A. Error
B. Warning
C. Medium

Answer

A. Error

Explanation

By default, only alerts that have a severity level of Error or a security severity level of Critical or High cause a pull-request check failure. A check still succeeds with alerts of lower severities.

By default, the severity level that causes a pull request check failure during code scanning in GitHub Advanced Security is A. Error.

When code scanning is enabled for a repository, GitHub automatically analyzes the code for potential security vulnerabilities and coding errors. If any issues are detected at the “Error” severity level, the pull request check will fail, preventing the merge of the code changes until the issues are resolved.

Error-level issues are considered critical and require immediate attention. They often indicate significant security vulnerabilities or severe coding flaws that could lead to exploitable weaknesses or system failures. Examples of error-level issues might include SQL injection vulnerabilities, cross-site scripting (XSS) vulnerabilities, or the use of known insecure libraries.

By setting the default severity level to “Error,” GitHub ensures that only code changes that meet the highest standards of security and quality are allowed to be merged into the main branch. This helps maintain the integrity and reliability of the codebase while reducing the risk of introducing vulnerabilities or bugs.

It’s important to note that while “Warning” and “Medium” severity issues are also flagged during code scanning, they do not cause a pull request check failure by default. However, repository administrators can configure the code scanning settings to adjust the severity levels that trigger pull request check failures based on their specific requirements and risk tolerance.

In summary, the default severity level that causes a pull request check failure during code scanning in GitHub Advanced Security is A. Error. This ensures that critical security vulnerabilities and severe coding issues are addressed before code changes are merged, promoting secure and high-quality code development practices.

GitHub Advanced Security certification exam assessment practice question and answer (Q&A) dump including multiple choice questions (MCQ) and objective type questions, with detail explanation and reference available free, helpful to pass the GitHub Advanced Security exam and earn GitHub Advanced Security certification.