My Attendance
An anti-fraud QR attendance system with expiring signed tokens, device binding, layered bot defenses, and AES-256-GCM encryption of student data, red-teamed by 13 AI agents for 9 hours.













Technical highlights
- Signed, expiring QR tokens: codes rotate every 5 to 180 seconds and carry short-lived signed tokens validated at the moment the link opens; a student who scans in class gets about three minutes to submit, while a forwarded screenshot has already expired.
- Device binding: one sign-in per device per session, with the device ID carried inside the signed grant so clearing cookies cannot bypass it; handing a phone to a friend is blocked.
- Encryption at rest: student names, IDs, and notes are encrypted field by field with AES-256-GCM, with a separate-key HMAC blind index so matching and uniqueness still work in SQL.
- Layered bot defense: a honeypot field, per-device and per-IP rate limits, and burst detection (8 sign-ins in 15 seconds) that switches the session to a self-hosted visual challenge drawn as dot-matrix bitmaps, so it cannot be read from the page source.
- Hardened authentication: bcrypt-hashed passwords, emailed one-time codes (HMAC-hashed, 10-minute expiry, 5 attempts), and a passkey (WebAuthn) second factor for admins that stores only public keys.
- Adversarial testing: 13 AI agents spent 9 hours in a sandbox trying to bypass check-in; none succeeded.
Architecture
- Node.js and Express with server-rendered EJS views and a single-file SQLite database.
- Rules engine: configurable absence thresholds flag students as at risk and then on hold; enrollment closes manually or on a scheduled cut-off date.
- Deleting a class requires admin approval and is held for 14 days, cancellable, before data is purged.
- Attendance exports to Excel or CSV; security events are logged; strict security headers and no search indexing.
- Packaged with a Dockerfile and deploy configs for Fly.io and Render.
Features
- Live projector session with sign-ins arriving
- Roster: present, late, excused, absent
- Per-student history and corrections
- Weekly class schedules
- Professor accounts managed by an admin
- Absence warnings and on-hold screen