-- [Configure and Use Code Scanning]
After investigating a code scanning alert related to injection, you determine that the input is properly sanitized using custom logic. What should be your next step?
When you identify that a code scanning alert is a false positive---such as when your code uses a custom sanitization method not recognized by the analysis---you should dismiss the alert with the reason 'false positive.' This action helps improve the accuracy of future analyses and maintains the relevance of your security alerts.
As per GitHub's documentation:
'If you dismiss a CodeQL alert as a false positive result, for example because the code uses a sanitization library that isn't supported, consider contributing to the CodeQL repository and improving the analysis.'
By dismissing the alert appropriately, you ensure that your codebase's security alerts remain actionable and relevant.
-- [Configure and Use Secret Scanning]
Which of the following secret scanning features can verify whether a secret is still active?
Validity checks, also called secret validation, allow GitHub to check if a detected secret is still active. If verified as live, the alert is marked as 'valid', allowing security teams to prioritize the most critical leaks.
Push protection blocks secrets but does not check their validity. Custom patterns are user-defined and do not include live checks.
-- [Use Code Scanning with CodeQL]
How would you build your code within the CodeQL analysis workflow? (Each answer presents a complete solution. Choose two.)
Comprehensive and Detailed Explanation:
When setting up CodeQL analysis for compiled languages, there are two primary methods to build your code:
GitHub Docs
Autobuild: CodeQL attempts to automatically build your codebase using the most likely build method. This is suitable for standard build processes.
GitHub Docs
Custom Build Steps: For complex or non-standard build processes, you can implement custom build steps by specifying explicit build commands in your workflow. This provides greater control over the build process.
GitHub Docs
The init action initializes the CodeQL analysis but does not build the code. The jobs.analyze.runs-on specifies the operating system for the runner but is not directly related to building the code. Uploading compiled binaries is not a method supported by CodeQL for analysis.
-- [Configure and Use Dependency Management]
If notification and alert recipients are not customized, which users receive notifications about new Dependabot alerts in an affected repository?
By default, users with Write, Maintain, or Admin permissions will receive notifications for new Dependabot alerts. However, Write permission is the minimum level needed to be automatically notified. Users with only Read access do not receive alerts unless added explicitly.
-- [Configure and Use Secret Scanning]
Which of the following secret scanning features can verify whether a secret is still active?
Validity checks, also called secret validation, allow GitHub to check if a detected secret is still active. If verified as live, the alert is marked as 'valid', allowing security teams to prioritize the most critical leaks.
Push protection blocks secrets but does not check their validity. Custom patterns are user-defined and do not include live checks.
Slyvia
13 days agoBilli
26 days agoMaybelle
27 days agoEmogene
2 months agoDorathy
2 months agoWilletta
2 months agoMerilyn
3 months agoStevie
3 months ago