summaryrefslogtreecommitdiffstats
path: root/server/app.py
diff options
context:
space:
mode:
authorLouis Burda <quent.burda@gmail.com>2025-01-17 23:44:26 +0100
committerLouis Burda <quent.burda@gmail.com>2025-01-17 23:44:26 +0100
commite3c6fb69c782d51f9b0aeba493d9897c5e9f5c48 (patch)
treeadab60d1ab812b54fc12e67bcf5ba3c3fb4690cc /server/app.py
downloadnullcon2023-babyrand-master.tar.gz
nullcon2023-babyrand-master.zip
Add final challenge filesHEADmaster
Diffstat (limited to 'server/app.py')
-rw-r--r--server/app.py18
1 files changed, 18 insertions, 0 deletions
diff --git a/server/app.py b/server/app.py
new file mode 100644
index 0000000..f0418b0
--- /dev/null
+++ b/server/app.py
@@ -0,0 +1,18 @@
+#!/usr/bin/python3 -u
+
+import random
+import os
+
+max_retries = 100
+for _ in range(max_retries):
+ print("Hints:")
+ for i in range(9):
+ print(random.getrandbits(32))
+
+ real = random.getrandbits(32)
+ print("Guess:")
+ resp = input()
+ if int(resp) == real:
+ print("FLAG", os.getenv("FLAG"))
+
+print("No tries left, sorry!")