Skip to content
This repository was archived by the owner on May 11, 2025. It is now read-only.

Commit 566a457

Browse files
committed
hints done
1 parent 519e614 commit 566a457

File tree

3 files changed

+61
-15
lines changed

3 files changed

+61
-15
lines changed

flags.py

Lines changed: 55 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,65 @@
11
stages = { # Sample dictionary with flags and multiple hints
22
1: {
3-
"flag": "flag{stage1}",
3+
"flag": "{bit.ly/5P3CTR6R4M}",
44
"hints": [
5-
"This is the least revealing hint for stage 1.",
6-
"This is a more revealing hint for stage 1.",
7-
"This is the most revealing hint for stage 1.",
5+
"Blind in one eye, deaf in the other.",
6+
"Zoom in, zoom out, and you'll find what you seek.",
7+
"You have the audacity to ask for another hint, so soon?",
8+
"Spectro",
9+
"Linearity is a myth.",
810
],
9-
"notes": "This is a note for stage 1",
11+
"notes": "It doesn't get easier, you just get better.",
1012
},
1113
2: {
12-
"flag": "flag{stage2}",
14+
"flag": "{g00ddi66in65}",
1315
"hints": [
14-
"This is the least revealing hint for stage 2.",
15-
"This is a more revealing hint for stage 2.",
16-
"This is the most revealing hint for stage 2.",
16+
"Dig a little deeper.",
17+
"Are you using Any of the right tools?",
18+
"Try browsing a little more.",
19+
"CAA",
1720
],
18-
"notes": "This is a note for stage 2",
21+
"notes": "A bad workman always blames his tools.",
1922
},
20-
3: {"flag": "flag{stage3}", "hints": ["Almost there"]},
23+
3: {
24+
"flag": "{Its4m34Br0w53r}",
25+
"hints": [
26+
"This might be a site for sore eyes.",
27+
"If the past could be changed, it would not exist.",
28+
"We go way back"
29+
"Secrets often lie where robots tell you not to look.",
30+
"Every locked door has a key. Every problem has a solution."
31+
],
32+
"notes": "If the final site is not loading, refresh and wait... (or try to add alt. to the URL)",
33+
},
34+
4: {
35+
"flag": "{FamousZebraFumbles75}",
36+
"hints": [
37+
"Disguise is always a self portrait.",
38+
"You cannot reach the right destination by walking on the wrong path",
39+
"A path is a prior interpretation of the best way to traverse a landscape.",
40+
"One new notification",
41+
"Check the trash.",
42+
],
43+
"notes": "Some flags can unlock more than one door.",
44+
},
45+
5: {
46+
"flag": "{R3v3r5ing_i5_fun}",
47+
"hints": [
48+
"Freedom lies in being bold.",
49+
"Onions have layers. Ogres have layers... You get it?",
50+
"Love without attachment is light.",
51+
"Poetry is written with tears, fiction with blood, and history with invisible ink.",
52+
],
53+
"notes": "Just a little more to go.",
54+
},
55+
6: {
56+
"flag": "{s0ck3t5_4r3_4m4z1ng}",
57+
"hints": [
58+
"When one door closes, opportunity comes knocking on another",
59+
"Are we speaking the same language?",
60+
"What's in a name?",
61+
"Check all the windows.",
62+
],
63+
"notes": "Nearly there!",
64+
}
2165
}

hints/routes.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,9 @@ def flags():
4040
if not submitted_flag.isascii(): # make sure its ascii only and not invalid
4141
flash("Invalid flag. Please try again.", "danger")
4242
return redirect(url_for("ctf.flags"))
43-
43+
# everything before the first { can be case insensitive
44+
45+
4446
if submitted_flag in submitted_flags:
4547
flash("You already submitted this flag.", "info")
4648
elif submitted_flag == stages[current_stage]["flag"]:
@@ -71,7 +73,7 @@ def flags():
7173
for stage, stage_data in stages.items():
7274
if submitted_flag == stage_data["flag"]:
7375
flash(
74-
f"That's the flag for stage {stage}, but in the wrong order", "info", )
76+
f"That's the flag for stage {stage}, but in the wrong order", "info")
7577
current_stage = stage
7678
hint_index = 0
7779
found = True

hints/templates/flags.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@
1212
<h1 class="text-center">CTFlask</h1>
1313
<div class="mt-4">
1414
<h3>Stage {{ stage }}</h3>
15-
15+
<p>Do not submit anything that comes before the first "{", ie if it is ColaCo{flag}, just submit {flag}</p>
1616
<form method="POST">
1717
<div class="form-group">
1818
<label for="flag">Enter Flag:</label>
19-
<input type="text" id="flag" name="flag" class="form-control" placeholder="flag{...}" required>
19+
<input type="text" id="flag" name="flag" class="form-control" placeholder="{...}" required>
2020
</div>
2121
<button type="submit" name="submit_flag" class="btn btn-primary">Submit Flag</button>
2222
</form>

0 commit comments

Comments
 (0)