How kritt29/ctf-website-current works
DDC CTF Platform combines a public event website with an authenticated participant portal. The main gameplay workflow is login → protected dashboard or challenge catalogue → server-assigned starting challenge; assignment and participant start time persist in D1. The public site presents the cinematic event journey, including the network globe and Page 02 vector experience. The README identifies submissions, leaderboard, and rules as placeholders, and scoring, challenge execution, and judging as future work. Some page and API internals were not sampled, so only documented or indexed relationships are shown.
Main entry points: auth.ts Session and auth · layout.tsx Participant routes · competition.ts Competition logic · page.tsx Event landing
Components 24
Public event experience
- Event landing
app/page.tsx - Event highlights
components/highlights/EventHighlights.tsx - Cinematic hero
components/hero/HeroScreen.tsx - Network globe
components/hero/NetworkGlobe.tsx - Hero choreography
components/hero/motion/useHeroMotion.ts - Page 02 vectors
components/vectors/ChallengeVectors.tsx
Participant experience
- Login route
app/login/page.tsx - Login screen
components/login/LoginScreen.tsx - Participant routes
app/(participant)/layout.tsx - Dashboard view
components/participant/Dashboard.tsx - Challenge catalogue
app/(participant)/challenges/page.tsx - Challenge detail
app/(participant)/challenges/[challengeId]/page.tsx - Portal placeholders
app/(participant)/submissions/page.tsx
Server platform
- Authentication API
app/api/auth/login/route.ts - Session and auth
lib/server/auth.ts - Challenge APIs
app/api/challenges/start/route.ts - Dashboard API
app/api/dashboard/route.ts - Competition logic
lib/server/competition.ts - HTTP safeguards
lib/server/http.ts - D1 access
lib/server/database.ts
Persistent state
- Cloudflare D1
- Database schema
db/schema.ts
Other components
- Event visitor
- Participant
Connections 30
- Event visitor → Event landing: visits
README.md - Event landing → Cinematic hero: renders
app/page.tsx - Event landing → Event highlights: renders
app/page.tsx - Event landing → Page 02 vectors: mounts
app/page.tsx - Cinematic hero → Network globe: renders
components/hero/HeroScreen.tsx - Cinematic hero → Hero choreography: uses
components/hero/HeroScreen.tsx - Hero choreography → Network globe: drives motion
- Participant → Login route: signs in
README.md - Login route → Login screen: renders
app/login/page.tsx - Login route → Session and auth: checks session
app/login/page.tsx - Participant → Participant routes: opens portal
README.md - Participant routes → Dashboard view: shows
- Participant routes → Challenge catalogue: routes to
README.md - Participant routes → Challenge detail: routes to
README.md - Participant routes → Portal placeholders: routes to
README.md - Challenge catalogue → Competition logic: loads challenges
app/(participant)/challenges/page.tsx - Challenge catalogue → Session and auth: requires participant
app/(participant)/challenges/page.tsx - Challenge detail → Session and auth: requires participant
app/(participant)/challenges/[challengeId]/page.tsx - Challenge detail → Competition logic: loads assignment
app/(participant)/challenges/[challengeId]/page.tsx - Authentication API → Session and auth: authenticates
app/api/auth/login/route.ts - Authentication API → HTTP safeguards: uses responses
app/api/auth/login/route.ts - Challenge APIs → Session and auth: requires participant
app/api/challenges/start/route.ts - Challenge APIs → Competition logic: starts challenge
app/api/challenges/start/route.ts - Challenge APIs → HTTP safeguards: checks origin
app/api/challenges/start/route.ts - Dashboard API → Session and auth: requires participant
app/api/dashboard/route.ts - Dashboard API → Competition logic: builds dashboard
app/api/dashboard/route.ts - Session and auth → D1 access: queries
lib/server/auth.ts - Competition logic → D1 access: queries and writes
lib/server/competition.ts - D1 access → Cloudflare D1: accesses
- Database schema → Cloudflare D1: defines tables