Skip to content

Commit 11cb3dc

Browse files
Fix lab format-strings
Add "hints:" (without the field name, it has no contents). Remove an example of a password in source code. That is a vulnerability all by itself, we do NOT want to show how to write *vulnerable* code. Signed-off-by: David A. Wheeler <[email protected]>
1 parent 74fae71 commit 11cb3dc

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

docs/labs/format-strings.html

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121

2222
<script id="info" type="application/yaml">
2323
---
24+
hints:
2425
- absent: "user_input"
2526
text: Make sure the user_input is included in the replacement fields passed to the format function
2627
examples:
@@ -100,10 +101,7 @@ <h2>Interactive Lab (<span id="grade"></span>)</h2>
100101
<p>
101102
<form id="lab">
102103
<pre><code
103-
> # Application configuration which should be kept secret from a user
104-
CONFIG = {
105-
'SECRET_KEY': 'super secret key'
106-
}
104+
> # CONFIG includes a secret key that must not be revealed
107105

108106
# A event object with a single attribute used by the malicious format string to gain access to the
109107
# secret application configuration below

0 commit comments

Comments
 (0)