26 lines
640 B
Python
26 lines
640 B
Python
from solve import main
|
|
from gen_files import generate_scrambled_qrcode
|
|
import random
|
|
from pathlib import Path
|
|
import string
|
|
|
|
visible_chars = string.ascii_letters + string.digits
|
|
random_bytes = "".join(random.choice(visible_chars) for _ in range(10))
|
|
|
|
test_flag = f"h4tum{{healthy_healthy_healthchecks_{random_bytes}}}"
|
|
|
|
|
|
generate_scrambled_qrcode(
|
|
seed=test_flag,
|
|
output_dir=Path("/tmp/health_check"),
|
|
decoy=True,
|
|
name=f"{random_bytes}.png"
|
|
)
|
|
|
|
output = main(f"/tmp/health_check/{random_bytes}.png", False)
|
|
|
|
if output and test_flag in output:
|
|
print(output)
|
|
else:
|
|
print("Oh oh somethings wrong :()")
|