Skip to main content

Module cloudflare_interstitial

Module cloudflare_interstitial 

Source
Expand description

Cloudflare Bot Manager interstitial (“Just a moment…”) solver.

Distinct from the Turnstile widget: this is the JavaScript-only 5-second challenge page Cloudflare puts in front of protected sites BEFORE the actual application loads. Common shape:

  1. Page loads with title “Just a moment…” or “Attention Required!”
  2. CF runs an obfuscated JS challenge measuring browser features (canvas, WebGL, audio, performance timing, etc.) for ~5s
  3. On pass, CF sets the cf_clearance cookie and navigates to the protected URL (or to /cdn-cgi/challenge-platform/h/g/orchestrate which then redirects)
  4. The site is reachable for the cookie’s lifetime (typically 30 minutes)

CloudflareInterstitialSolver doesn’t reverse-engineer the challenge, that’s a moving target Cloudflare actively defends against. Instead, it leans on the fact that with proper stealth (which captchaforge applies via crate::stealth), the challenge actually PASSES from a real-looking chromium session. We just need to wait for it to complete and harvest the cookie.

Without stealth this solver returns failure within the timeout and the chain falls through. With stealth applied (and a real Chrome UA) the success rate against test sites is very high.

Structs§

CloudflareInterstitialSolver
Solver for the Cloudflare interstitial challenge.

Enums§

CfClearance
Validity classification of a cf_clearance cookie value.

Functions§

classify_cf_clearance
Pure classifier for the cf_clearance cookie value. A valid clearance is the authoritative “we passed” signal for every Cloudflare variant (IUAM JS challenge, managed challenge, Turnstile-backed interstitial), regardless of what page phase the DOM probe reports.