Skip to content

Commit 12a2568

Browse files
authored
Wording tweaks
1 parent 27e35d3 commit 12a2568

File tree

4 files changed

+18
-17
lines changed

4 files changed

+18
-17
lines changed

.github/steps/1-step.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,27 @@
1-
## Step 1: Enable CodeQL
1+
## Step 1: Enable Code Scanning
22

3-
In this first step, we'll be learning more about [CodeQL](https://codeql.github.com/) and how to use it to secure your source code.
3+
Let's start by learning a bit about code scanning with [CodeQL](https://codeql.github.com/) and how it helps secure your code.
44

55
### What is GitHub Code Scanning?
66

7-
[Code scanning](https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/about-code-scanning) is part of the [GitHub Advanced Security (GHAS)](https://docs.github.com/en/get-started/learning-about-github/about-github-advanced-security) product suite. It allows development teams to integrate security testing tools directly into the same process you already use for shipping code. It supports many types such as SAST, container, and infrastructure as code. And the best part is that the results can also live directly in GitHub next to your code. No need for context switching! 🎉
7+
[Code scanning](https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/about-code-scanning) is part of the [GitHub Advanced Security (GHAS)](https://docs.github.com/en/get-started/learning-about-github/about-github-advanced-security) product suite. It allows development teams to integrate security testing tools directly into the same process you already use for shipping code. It supports many types such as SAST, container, and infrastructure as code. And, the best part is that the results can also live directly in GitHub next to your code. No need for context switching! 🎉
88

99
> [!TIP]
10-
> All of the features of GitHub Advanced Security are 100% free for public repositories.
10+
> All features of GitHub Advanced Security are free for public repositories. However, private repositories require a compatible [paid account](https://docs.github.com/en/billing/managing-billing-for-your-products/managing-billing-for-github-advanced-security/about-billing-for-github-advanced-security).
1111
1212
### What is CodeQL?
1313

1414
[CodeQL](https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/about-code-scanning-with-codeql) is a static analysis testing tool that helps you identify security weaknesses such as SQL injection, cross-site scripting, and code injection issues.
1515

16-
Typically CodeQL patterns are collected into [query suites](https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/about-code-scanning-with-codeql#about-codeql-queries) of patterns. When combined well, this can be a very powerful! To help with this, teams of security experts have pre-populated suites for many common scenarios and programming languages.
16+
Typically CodeQL [queries](https://codeql.github.com/docs/writing-codeql-queries/about-codeql-queries/) are collected into [query suites](https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/about-code-scanning-with-codeql#about-codeql-queries) to cover multiple patterns. When combined well, this can be a very powerful! To help with this, teams of security experts have pre-populated suites for many common scenarios and programming languages.
1717

1818
In many cases, taking advantage of CodeQL is as simple as accepting the default suite, but you can also select the extended suite or customize your own with [GitHub Actions]().
1919

2020
<img width="200" align="right" alt="codeql default configuration box" src="https://github.com/user-attachments/assets/cf5ba96b-98bb-4db5-b743-bd31bceaabac"/>
2121

22-
Here are some options the default configuration provides:
22+
Here are some of the options the default configuration provides:
2323

24-
- **Languages:** The languages automatically detected in your repository that CodeQL will scan.
24+
- **Languages:** Supported languages will automatically detected in your repository and scanning will be enabled.
2525

2626
- **Query suites:** A list of the available suites of patterns that will be used. The **Default** or **Extended** are provided automatically.
2727

.github/steps/2-step.md

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
## Step 2: Detect Vulnerabilities in a Pull Request
22

3-
In this step, we will introduce a vulnerability into the `routes.py` file to trigger an alert.
3+
To see how Code Scanning works, we will introduce a vulnerability into the `routes.py` file to trigger an alert.
44

55
### ⌨️ Activity: Create a vulnerability
66

@@ -10,17 +10,17 @@ In this step, we will introduce a vulnerability into the `routes.py` file to tri
1010

1111
1. In the top right of the preview, click the **Edit** button.
1212

13-
<img width="400" alt="edit button" src="https://github.com/user-attachments/assets/19462cc5-a360-4dae-a97b-ecfd571aa403"/>
13+
<img width="500" alt="edit button" src="https://github.com/user-attachments/assets/19462cc5-a360-4dae-a97b-ecfd571aa403"/>
1414

1515
1. Navigate to about **line 16** and modify it to the below.
1616

1717
```py
1818
"SELECT * FROM books WHERE name LIKE '%" + name + "%'"
1919
```
2020

21-
1. Above the editor in the top-right, click the **Commit changes...** button. Select the radio button next to **Create a new branch** option. **DO NOT commit to the main branch.**
21+
1. Above the editor in the top-right, click the **Commit changes...** button. In the prompt window, select the radio button for the **Create a new branch** option. **DO NOT commit to the main branch.**
2222

23-
1. Click the **Propose changes** option and click **Create pull request**. Use the following branch name.
23+
1. Click the **Propose changes** option and click **Create pull request**. Use the below branch name.
2424

2525
```txt
2626
learning-codeql
@@ -58,5 +58,4 @@ In this step, we will introduce a vulnerability into the `routes.py` file to tri
5858
> [!TIP]
5959
> Check out the [Triage code scanning alerts in pull requests](https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/triaging-code-scanning-alerts-in-pull-requests) page to learn more about integration of code scanning into pull requests.
6060
61-
62-
<!-- > 💡 Tip: Clicking the **Show paths** link will provide additional insights about the alert's data flow from user input (source), through the application, and when it is acted on (sink). -->
61+
<!-- > 💡 Tip: Clicking the **Show paths** link will provide additional insights about the alert's data flow from user input (source), through the application, and when it is acted on (sink). -->

.github/steps/3-step.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
## Step 3: Review and Triage CodeQL Alerts
22

3-
With our pull request changes now reviewed by CodeQL, let's take a moment to learn about managing alerts.
3+
With our pull request changes now reviewed by CodeQL, we now have some results to view.Let's learn about managing alerts.
44

55
GitHub provides a dedicated **Security** tab for securely managing all security related issues. CodeQL saves alerts using the same standard as many other analysis tools with the results showing up under the **Code scanning** area.
66

@@ -10,13 +10,15 @@ GitHub provides a dedicated **Security** tab for securely managing all security
1010

1111
The main area of an alert provides the resolution status, affected branch, code location, and classification information like severity and [CVE identification number](https://docs.github.com/en/code-security/security-advisories/working-with-repository-security-advisories/about-repository-security-advisories#cve-identification-numbers).
1212

13+
After the status information, a detailed description of the issue, recommended solutions, and suggested code changes are provided.
14+
1315
<img width="600" alt="additional information" src="https://github.com/user-attachments/assets/9a5aaf3f-e063-4d07-8cdd-6272eec8a411"/>
1416

1517
### What is CWE?
1618

17-
Many of the patterns CodeQL scans for come from existing databases of vulnerabilities.
19+
Many of the patterns CodeQL scans for come from existing databases of vulnerabilities, which are categorized for easier understanding.
1820

19-
The Common Weakness Enumeration (CWE) is a category system for hardware and software weaknesses and vulnerabilities. Think of it as a way to describe and categorize security issues in an application's source code. For more information on CWEs, see the Wikipedia article [Common Weakness Enumeration](https://en.wikipedia.org/wiki/Common_Weakness_Enumeration).
21+
The **Common Weakness Enumeration (CWE)** is a category system for hardware and software weaknesses and vulnerabilities. Think of it as a way to describe and categorize security issues in an application's source code. For more information on CWEs, see the Wikipedia article [Common Weakness Enumeration](https://en.wikipedia.org/wiki/Common_Weakness_Enumeration).
2022

2123
### ⌨️ Activity: Review an Alert
2224

.github/steps/4-step.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
## Step 4: Fix Security Vulnerabilities
22

3-
Let's fix the security vulnerability we introduced that CodeQL identified.
3+
Finally, let's use the information provided by CodeQL to better understand the vulnerability and fix it.
44

55
### ⌨️ Activity: Resolve an open alert
66

0 commit comments

Comments
 (0)