Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions ctf_setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -594,6 +594,11 @@ cat > /usr/local/bin/monitor_directory.sh << 'EOF'
#!/bin/bash
DIRECTORY="/home/ctf_user/ctf_challenges"
FLAG=$(cat /etc/ctf/flag_10)
# Wait for setup to complete before monitoring to avoid leaking flags during provisioning
while [ ! -f /var/log/setup_complete ]; do
sleep 5
done
sleep 10
# Pre-create the trigger file location
touch /tmp/.ctf_upload_triggered 2>/dev/null || true
chmod 666 /tmp/.ctf_upload_triggered 2>/dev/null || true
Expand Down