Introducing Precursor: continuous client-side session verification
Key Points
- Session-scoped behavioral detection
- Privacy-first lightweight client-side JS
- Integrates with Turnstile and bot score
Summary
Precursor is a privacy-first, client-side, session-scoped verification system from Cloudflare that continuously collects lightweight behavioral signals (pointer, keyboard timing, focus, visibility) via an injected JavaScript bundle. Those signals are buffered on the client and evaluated at the edge to build session-level behavioral signatures that feed into Bot Management, Turnstile decisions, challenges, and security rules. The goal is higher-precision detection of automated or agentic traffic across an entire user journey while reducing unnecessary friction for legitimate users.
Key Points
-
Deployment and integration
- Precursor is injected automatically by Cloudflare into HTML responses—no code changes or third-party embeds required.
- Enable from the Cloudflare dashboard; run in low-friction (observe) or enforce modes.
- Feeds directly into existing bot score, challenge flows, and security rules.
-
How it works (engineer-focused)
- Lightweight, dynamically assembled JS attaches event listeners and serializes interaction events into compact buffers sent to edge evaluators at intervals.
- Edge evaluation runs multiple cross-referencing evaluators to consolidate signals into weighted session detections.
- Session-scoped state accumulates over the visitor’s session so behavior cannot be trivially reset by refreshes or new challenges.
-
Privacy & data model
- Signals capture timing/rhythm and aggregate patterns (e.g., keyboard timing, pointer motion shapes), not raw keystrokes or persistent identifiers.
- Behavioral data is consumed internally for detection and not exposed in customer dashboards or tied to persistent user profiles.
-
Observability and rollout
- New session-based views in Security Analytics let you inspect full visitor journeys and identify sessions that diverge from expected behavior.
- Precursor is rolling out now and is free until GA; enable per-zone in the dashboard to start enhancing existing protections immediately.
Practical engineering notes
- No client changes required; ensure your site allows the injected script to run (no restrictive CSP blocking the injection bundle).
- Use observe mode first to tune rules and verify analytics before enforcing challenges.
- Expect increased signal fidelity for long-lived flows (signup, checkout, multi-step forms); consider adjusting challenge thresholds accordingly.