Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
zardus committed Feb 2, 2025
1 parent 80a92e2 commit cd746e2
Show file tree
Hide file tree
Showing 96 changed files with 457 additions and 457 deletions.
8 changes: 4 additions & 4 deletions web-security/cmdi-env/_0/server
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import os
app = flask.Flask(__name__)


@app.route("/task", methods=["GET"])
@app.route("/activity", methods=["GET"])
def challenge():
arg = flask.request.args.get("tzid", "MST")
arg = flask.request.args.get("timezone-val", "MST")
command = f"TZ={arg} date"

print(f"DEBUG: {command=}")
Expand All @@ -24,7 +24,7 @@ def challenge():
return f"""
<html><body>
Welcome to the timezone service! Please choose a timezone to get the time there.
<form><input type=text name=tzid><input type=submit value=Submit></form>
<form action="/activity"><input type=text name=timezone-val><input type=submit value=Submit></form>
<hr>
<b>Output of {command}:</b><br>
<pre>{result}</pre>
Expand All @@ -35,5 +35,5 @@ def challenge():
os.setuid(os.geteuid())
os.environ["PATH"] = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
app.secret_key = os.urandom(8)
app.config["SERVER_NAME"] = f"challenge.localhost:80"
app.config["SERVER_NAME"] = "challenge.localhost:80"
app.run("challenge.localhost", 80)
8 changes: 4 additions & 4 deletions web-security/cmdi-env/_1/server
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import os
app = flask.Flask(__name__)


@app.route("/competition", methods=["GET"])
@app.route("/milestone", methods=["GET"])
def challenge():
arg = flask.request.args.get("timezone-value", "MST")
arg = flask.request.args.get("tzone", "MST")
command = f"TZ={arg} date"

print(f"DEBUG: {command=}")
Expand All @@ -24,7 +24,7 @@ def challenge():
return f"""
<html><body>
Welcome to the timezone service! Please choose a timezone to get the time there.
<form><input type=text name=timezone-value><input type=submit value=Submit></form>
<form action="/milestone"><input type=text name=tzone><input type=submit value=Submit></form>
<hr>
<b>Output of {command}:</b><br>
<pre>{result}</pre>
Expand All @@ -35,5 +35,5 @@ def challenge():
os.setuid(os.geteuid())
os.environ["PATH"] = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
app.secret_key = os.urandom(8)
app.config["SERVER_NAME"] = f"challenge.localhost:80"
app.config["SERVER_NAME"] = "challenge.localhost:80"
app.run("challenge.localhost", 80)
8 changes: 4 additions & 4 deletions web-security/cmdi-env/_10/server
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import os
app = flask.Flask(__name__)


@app.route("/adventure", methods=["GET"])
@app.route("/event", methods=["GET"])
def challenge():
arg = flask.request.args.get("timezone-val", "MST")
arg = flask.request.args.get("tzid", "MST")
command = f"TZ={arg} date"

print(f"DEBUG: {command=}")
Expand All @@ -24,7 +24,7 @@ def challenge():
return f"""
<html><body>
Welcome to the timezone service! Please choose a timezone to get the time there.
<form><input type=text name=timezone-val><input type=submit value=Submit></form>
<form action="/event"><input type=text name=tzid><input type=submit value=Submit></form>
<hr>
<b>Output of {command}:</b><br>
<pre>{result}</pre>
Expand All @@ -35,5 +35,5 @@ def challenge():
os.setuid(os.geteuid())
os.environ["PATH"] = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
app.secret_key = os.urandom(8)
app.config["SERVER_NAME"] = f"challenge.localhost:80"
app.config["SERVER_NAME"] = "challenge.localhost:80"
app.run("challenge.localhost", 80)
8 changes: 4 additions & 4 deletions web-security/cmdi-env/_11/server
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import os
app = flask.Flask(__name__)


@app.route("/milestone", methods=["GET"])
@app.route("/quest", methods=["GET"])
def challenge():
arg = flask.request.args.get("tz-region", "MST")
arg = flask.request.args.get("timezone", "MST")
command = f"TZ={arg} date"

print(f"DEBUG: {command=}")
Expand All @@ -24,7 +24,7 @@ def challenge():
return f"""
<html><body>
Welcome to the timezone service! Please choose a timezone to get the time there.
<form><input type=text name=tz-region><input type=submit value=Submit></form>
<form action="/quest"><input type=text name=timezone><input type=submit value=Submit></form>
<hr>
<b>Output of {command}:</b><br>
<pre>{result}</pre>
Expand All @@ -35,5 +35,5 @@ def challenge():
os.setuid(os.geteuid())
os.environ["PATH"] = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
app.secret_key = os.urandom(8)
app.config["SERVER_NAME"] = f"challenge.localhost:80"
app.config["SERVER_NAME"] = "challenge.localhost:80"
app.run("challenge.localhost", 80)
8 changes: 4 additions & 4 deletions web-security/cmdi-env/_12/server
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import os
app = flask.Flask(__name__)


@app.route("/level", methods=["GET"])
@app.route("/event", methods=["GET"])
def challenge():
arg = flask.request.args.get("timezone-val", "MST")
arg = flask.request.args.get("timezone", "MST")
command = f"TZ={arg} date"

print(f"DEBUG: {command=}")
Expand All @@ -24,7 +24,7 @@ def challenge():
return f"""
<html><body>
Welcome to the timezone service! Please choose a timezone to get the time there.
<form><input type=text name=timezone-val><input type=submit value=Submit></form>
<form action="/event"><input type=text name=timezone><input type=submit value=Submit></form>
<hr>
<b>Output of {command}:</b><br>
<pre>{result}</pre>
Expand All @@ -35,5 +35,5 @@ def challenge():
os.setuid(os.geteuid())
os.environ["PATH"] = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
app.secret_key = os.urandom(8)
app.config["SERVER_NAME"] = f"challenge.localhost:80"
app.config["SERVER_NAME"] = "challenge.localhost:80"
app.run("challenge.localhost", 80)
8 changes: 4 additions & 4 deletions web-security/cmdi-env/_13/server
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import os
app = flask.Flask(__name__)


@app.route("/problem", methods=["GET"])
@app.route("/stage", methods=["GET"])
def challenge():
arg = flask.request.args.get("timezone-id", "MST")
arg = flask.request.args.get("tzone", "MST")
command = f"TZ={arg} date"

print(f"DEBUG: {command=}")
Expand All @@ -24,7 +24,7 @@ def challenge():
return f"""
<html><body>
Welcome to the timezone service! Please choose a timezone to get the time there.
<form><input type=text name=timezone-id><input type=submit value=Submit></form>
<form action="/stage"><input type=text name=tzone><input type=submit value=Submit></form>
<hr>
<b>Output of {command}:</b><br>
<pre>{result}</pre>
Expand All @@ -35,5 +35,5 @@ def challenge():
os.setuid(os.geteuid())
os.environ["PATH"] = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
app.secret_key = os.urandom(8)
app.config["SERVER_NAME"] = f"challenge.localhost:80"
app.config["SERVER_NAME"] = "challenge.localhost:80"
app.run("challenge.localhost", 80)
8 changes: 4 additions & 4 deletions web-security/cmdi-env/_14/server
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import os
app = flask.Flask(__name__)


@app.route("/dare", methods=["GET"])
@app.route("/milestone", methods=["GET"])
def challenge():
arg = flask.request.args.get("tz-tag", "MST")
arg = flask.request.args.get("timezone", "MST")
command = f"TZ={arg} date"

print(f"DEBUG: {command=}")
Expand All @@ -24,7 +24,7 @@ def challenge():
return f"""
<html><body>
Welcome to the timezone service! Please choose a timezone to get the time there.
<form><input type=text name=tz-tag><input type=submit value=Submit></form>
<form action="/milestone"><input type=text name=timezone><input type=submit value=Submit></form>
<hr>
<b>Output of {command}:</b><br>
<pre>{result}</pre>
Expand All @@ -35,5 +35,5 @@ def challenge():
os.setuid(os.geteuid())
os.environ["PATH"] = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
app.secret_key = os.urandom(8)
app.config["SERVER_NAME"] = f"challenge.localhost:80"
app.config["SERVER_NAME"] = "challenge.localhost:80"
app.run("challenge.localhost", 80)
8 changes: 4 additions & 4 deletions web-security/cmdi-env/_15/server
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import os
app = flask.Flask(__name__)


@app.route("/initiative", methods=["GET"])
@app.route("/test", methods=["GET"])
def challenge():
arg = flask.request.args.get("time-region", "MST")
arg = flask.request.args.get("timezone-val", "MST")
command = f"TZ={arg} date"

print(f"DEBUG: {command=}")
Expand All @@ -24,7 +24,7 @@ def challenge():
return f"""
<html><body>
Welcome to the timezone service! Please choose a timezone to get the time there.
<form><input type=text name=time-region><input type=submit value=Submit></form>
<form action="/test"><input type=text name=timezone-val><input type=submit value=Submit></form>
<hr>
<b>Output of {command}:</b><br>
<pre>{result}</pre>
Expand All @@ -35,5 +35,5 @@ def challenge():
os.setuid(os.geteuid())
os.environ["PATH"] = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
app.secret_key = os.urandom(8)
app.config["SERVER_NAME"] = f"challenge.localhost:80"
app.config["SERVER_NAME"] = "challenge.localhost:80"
app.run("challenge.localhost", 80)
8 changes: 4 additions & 4 deletions web-security/cmdi-env/_2/server
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import os
app = flask.Flask(__name__)


@app.route("/assignment", methods=["GET"])
@app.route("/puzzle", methods=["GET"])
def challenge():
arg = flask.request.args.get("timezone-value", "MST")
arg = flask.request.args.get("tzid", "MST")
command = f"TZ={arg} date"

print(f"DEBUG: {command=}")
Expand All @@ -24,7 +24,7 @@ def challenge():
return f"""
<html><body>
Welcome to the timezone service! Please choose a timezone to get the time there.
<form><input type=text name=timezone-value><input type=submit value=Submit></form>
<form action="/puzzle"><input type=text name=tzid><input type=submit value=Submit></form>
<hr>
<b>Output of {command}:</b><br>
<pre>{result}</pre>
Expand All @@ -35,5 +35,5 @@ def challenge():
os.setuid(os.geteuid())
os.environ["PATH"] = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
app.secret_key = os.urandom(8)
app.config["SERVER_NAME"] = f"challenge.localhost:80"
app.config["SERVER_NAME"] = "challenge.localhost:80"
app.run("challenge.localhost", 80)
8 changes: 4 additions & 4 deletions web-security/cmdi-env/_3/server
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import os
app = flask.Flask(__name__)


@app.route("/competition", methods=["GET"])
@app.route("/step", methods=["GET"])
def challenge():
arg = flask.request.args.get("timezone-id", "MST")
arg = flask.request.args.get("timezone-value", "MST")
command = f"TZ={arg} date"

print(f"DEBUG: {command=}")
Expand All @@ -24,7 +24,7 @@ def challenge():
return f"""
<html><body>
Welcome to the timezone service! Please choose a timezone to get the time there.
<form><input type=text name=timezone-id><input type=submit value=Submit></form>
<form action="/step"><input type=text name=timezone-value><input type=submit value=Submit></form>
<hr>
<b>Output of {command}:</b><br>
<pre>{result}</pre>
Expand All @@ -35,5 +35,5 @@ def challenge():
os.setuid(os.geteuid())
os.environ["PATH"] = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
app.secret_key = os.urandom(8)
app.config["SERVER_NAME"] = f"challenge.localhost:80"
app.config["SERVER_NAME"] = "challenge.localhost:80"
app.run("challenge.localhost", 80)
8 changes: 4 additions & 4 deletions web-security/cmdi-env/_4/server
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import os
app = flask.Flask(__name__)


@app.route("/resource", methods=["GET"])
@app.route("/exercise", methods=["GET"])
def challenge():
arg = flask.request.args.get("tzone", "MST")
arg = flask.request.args.get("zone", "MST")
command = f"TZ={arg} date"

print(f"DEBUG: {command=}")
Expand All @@ -24,7 +24,7 @@ def challenge():
return f"""
<html><body>
Welcome to the timezone service! Please choose a timezone to get the time there.
<form><input type=text name=tzone><input type=submit value=Submit></form>
<form action="/exercise"><input type=text name=zone><input type=submit value=Submit></form>
<hr>
<b>Output of {command}:</b><br>
<pre>{result}</pre>
Expand All @@ -35,5 +35,5 @@ def challenge():
os.setuid(os.geteuid())
os.environ["PATH"] = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
app.secret_key = os.urandom(8)
app.config["SERVER_NAME"] = f"challenge.localhost:80"
app.config["SERVER_NAME"] = "challenge.localhost:80"
app.run("challenge.localhost", 80)
8 changes: 4 additions & 4 deletions web-security/cmdi-env/_5/server
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import os
app = flask.Flask(__name__)


@app.route("/test", methods=["GET"])
@app.route("/milestone", methods=["GET"])
def challenge():
arg = flask.request.args.get("tz-region", "MST")
arg = flask.request.args.get("time-area", "MST")
command = f"TZ={arg} date"

print(f"DEBUG: {command=}")
Expand All @@ -24,7 +24,7 @@ def challenge():
return f"""
<html><body>
Welcome to the timezone service! Please choose a timezone to get the time there.
<form><input type=text name=tz-region><input type=submit value=Submit></form>
<form action="/milestone"><input type=text name=time-area><input type=submit value=Submit></form>
<hr>
<b>Output of {command}:</b><br>
<pre>{result}</pre>
Expand All @@ -35,5 +35,5 @@ def challenge():
os.setuid(os.geteuid())
os.environ["PATH"] = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
app.secret_key = os.urandom(8)
app.config["SERVER_NAME"] = f"challenge.localhost:80"
app.config["SERVER_NAME"] = "challenge.localhost:80"
app.run("challenge.localhost", 80)
8 changes: 4 additions & 4 deletions web-security/cmdi-env/_6/server
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import os
app = flask.Flask(__name__)


@app.route("/adventure", methods=["GET"])
@app.route("/level", methods=["GET"])
def challenge():
arg = flask.request.args.get("region", "MST")
arg = flask.request.args.get("timezone", "MST")
command = f"TZ={arg} date"

print(f"DEBUG: {command=}")
Expand All @@ -24,7 +24,7 @@ def challenge():
return f"""
<html><body>
Welcome to the timezone service! Please choose a timezone to get the time there.
<form><input type=text name=region><input type=submit value=Submit></form>
<form action="/level"><input type=text name=timezone><input type=submit value=Submit></form>
<hr>
<b>Output of {command}:</b><br>
<pre>{result}</pre>
Expand All @@ -35,5 +35,5 @@ def challenge():
os.setuid(os.geteuid())
os.environ["PATH"] = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
app.secret_key = os.urandom(8)
app.config["SERVER_NAME"] = f"challenge.localhost:80"
app.config["SERVER_NAME"] = "challenge.localhost:80"
app.run("challenge.localhost", 80)
6 changes: 3 additions & 3 deletions web-security/cmdi-env/_7/server
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import os
app = flask.Flask(__name__)


@app.route("/quest", methods=["GET"])
@app.route("/challenge", methods=["GET"])
def challenge():
arg = flask.request.args.get("tz-value", "MST")
command = f"TZ={arg} date"
Expand All @@ -24,7 +24,7 @@ def challenge():
return f"""
<html><body>
Welcome to the timezone service! Please choose a timezone to get the time there.
<form><input type=text name=tz-value><input type=submit value=Submit></form>
<form action="/challenge"><input type=text name=tz-value><input type=submit value=Submit></form>
<hr>
<b>Output of {command}:</b><br>
<pre>{result}</pre>
Expand All @@ -35,5 +35,5 @@ def challenge():
os.setuid(os.geteuid())
os.environ["PATH"] = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
app.secret_key = os.urandom(8)
app.config["SERVER_NAME"] = f"challenge.localhost:80"
app.config["SERVER_NAME"] = "challenge.localhost:80"
app.run("challenge.localhost", 80)
Loading

0 comments on commit cd746e2

Please sign in to comment.