Skip to content

Commit f777f49

Browse files
committed
docs: update heading depth
1 parent 4913d7e commit f777f49

File tree

1 file changed

+16
-16
lines changed

1 file changed

+16
-16
lines changed

README.md

+16-16
Original file line numberDiff line numberDiff line change
@@ -23,20 +23,20 @@ Begin by [forking this repo](https://docs.github.com/en/free-pro-team@latest/git
2323
<summary>Enable Code Scanning</summary>
2424
<p>
2525

26-
#### Security tab
26+
### Security tab
2727

2828
Click on the `Security` tab.
2929

3030

3131
<img src="images/00-repo-security-tab.png" width="80%"/>
3232

33-
#### Set up code scanning
33+
### Set up code scanning
3434

3535
Click `Set up code scanning`.
3636

3737
<img src="images/01-repo-secruity-setup-code-scanning.png" width="80%"/>
3838

39-
#### Setup Workflow
39+
### Setup Workflow
4040

4141
Click the `Set up this workflow` button by CodeQL Analysis.
4242

@@ -53,7 +53,7 @@ See the [documentation](https://docs.github.com/en/free-pro-team@latest/github/f
5353
<summary>Actions Workflow file</summary>
5454
<p>
5555

56-
#### Actions Workflow
56+
### Actions Workflow
5757

5858
The Actions Workflow file contains a number of different steps including:
5959
1. Checking out the repository
@@ -75,7 +75,7 @@ Click `Start Commit` -> `Commit new file` to commit the changes to _main_ branch
7575
<summary>Workflow triggers</summary>
7676
<p>
7777

78-
#### Workflow triggers
78+
### Workflow triggers
7979

8080
There are a [number of events](https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows) that can trigger a GitHub Actions workflow. In this example, the workflow will be triggered on
8181

@@ -96,7 +96,7 @@ Setting up the new CodeQL workflow and committing it to _main_ branch in the ste
9696

9797
<p>
9898

99-
#### GitHub Actions Progress
99+
### GitHub Actions Progress
100100

101101
Click `Actions` tab -> `CodeQL`
102102

@@ -116,7 +116,7 @@ Once the Workflow has completed, click the `Security` tab -> `Code scanning aler
116116
<img src="images/06-security-code-scanning-alerts.png" width="80%"/>
117117

118118

119-
#### Security Alert View
119+
### Security Alert View
120120

121121
Clicking on a security alert will provide details about the security alert including: <br/>
122122
<ul>
@@ -127,13 +127,13 @@ Clicking on a security alert will provide details about the security alert inclu
127127
</ul>
128128
<img src="images/06-security-codeql-alert.png" width="80%"/>
129129

130-
#### Security Alert Description
130+
### Security Alert Description
131131

132132
Click `Show more` to view a full desciption of the alert including examples and links to additional information.
133133

134134
<img src="images/07-security-codeql-show-more.png" width="80%"/>
135135

136-
#### Security Full Description
136+
### Security Full Description
137137

138138
<img width="80%" src="images/08-security-codeql-full-desc.png">
139139

@@ -144,15 +144,15 @@ Click `Show more` to view a full desciption of the alert including examples and
144144
<summary>Show Paths</summary>
145145
<p>
146146

147-
#### Show Paths Button
147+
### Show Paths Button
148148

149149
CodeQL Analysis is able to trace the dataflow path from source to sink and gives you the ability to view the path traversal within the alert.
150150

151151
Click `Show paths` to see the dataflow path that resulted in this alert.
152152

153153
<img src="images/09-security-codeql-show-paths.png" width="80%"/>
154154

155-
#### Show Paths View
155+
### Show Paths View
156156

157157
<img src="images/10-security-codeql-show-paths-details.png" width="80%"/>
158158

@@ -174,33 +174,33 @@ Within `models.go`, the lines `38`, `57`, and `76` contain the SQL injections.
174174

175175
Click `Create a new branch for this commit and start a pull request`, name the branch `fix-sql-injection`, and create the Pull Request.
176176

177-
#### Pull Request Status Check
177+
### Pull Request Status Check
178178

179179
In the Pull Request, you will notice that the CodeQL Analysis has started as a status check. Wait until it completes.
180180

181181
<img src="images/12-fix-pr-in-progress.png" width="80%"/>
182182

183-
#### Security Alert Details
183+
### Security Alert Details
184184

185185
After the Workflow has completed click on `Details` by the `Code Scanning Results / CodeQL` status check.
186186

187187
<img src="images/13-fix-pr-done.png" width="80%"/>
188188

189-
#### Fixed Alert
189+
### Fixed Alert
190190

191191
Notice that Code Scanning has detected that this Pull Request will fix the SQL injection vulnerabilities which were detected before.
192192

193193
<img src="images/14-fix-detail.png" width="80%"/>
194194

195195
Merge the Pull Request. After the Pull Request has been merged, another Workflow will kick off to scan the repository for any vulnerabilties.
196196

197-
#### Closed Security Alerts
197+
### Closed Security Alerts
198198

199199
After the final Workflow has completed, navigate back to the `Security` tab and click `Closed`. Notice that the **Query built from user-controlled sources** security alert now shows up as a closed issue.
200200

201201
<img src="images/15-fixed-alert.png" width="80%"/>
202202

203-
#### Traceability
203+
### Traceability
204204

205205
Click on the security alert and notice that it details when the fix was made, by whom, and the specific commit. This provides full traceability to detail when and how a security alert was fixed and exactly what was changed to remediate the issue.
206206

0 commit comments

Comments
 (0)