A separate Pydantic AI advisory identifies a quadratic JWT-pattern redaction expression reachable through untrusted prompt, tool or output text, allowing CPU exhaustion or a shared event-loop stall. The maintainers list affected versions from 0.16.0 through 0.69.0 and fixed release 0.70.0. Turning off JWT detection without an equivalent replacement can…
Inspect the ClaimsCase · DiggingBeagle record
Pydantic AI JWT-redaction regex allowed untrusted content to stall an agent event loop
A separate Pydantic AI advisory identifies a quadratic JWT-pattern redaction expression reachable through untrusted prompt, tool or output text, allowing CPU exhaustion or a shared event-loop stall.
Published by DiggingBeagle:
Turning off JWT detection without an equivalent replacement can remove secret-redaction protection, and the advisory does not document successful in-the-wild exploitation. A separate Pydantic AI advisory identifies a quadratic JWT-pattern redaction expression reachable through untrusted prompt, tool or output text, allowing CPU exhaustion or a shared event-loop stall.
Assessment profile
Assessment method- Setting
- research demonstration
- Exploitation
- demonstrated
- Evidence
- Grade B
- Remediation
- patch available
- AI role
- AGAINST AI
Basis and provenance
Maintainer advisory documents quadratic JWT redaction and a 0.70.0 patch; there is no verified population of exploited deployments. Impact grade is left null rather than converting a vendor statistic, controlled attack result or unmeasured installed-base exposure into a standardized realized-harm score.
Assessed Nov 19, 2026 using diggingbeagle.assessment/1.
Evidence basis: CLM-DB264-PYDANTIC-JWT-REGEX-BOUNDARY · CLM-DB264-PYDANTIC-JWT-REGEX-MECHANISM · GHSA-5m5q-5qj4-gx9h: Pydantic AI JWT secret-redaction denial of service
At a glance
Agent-secret filtering must be both bounded in computational cost and effective at protecting the secrets it is intended to remove.
Read the implicationsRate and duration of practical stalls under deployment-sized payload limits. Whether unaffected redaction configurations preserve confidentiality.
Limits and uncertaintyFull account
A separate Pydantic AI advisory identifies a quadratic JWT-pattern redaction expression reachable through untrusted prompt, tool or output text, allowing CPU exhaustion or a shared event-loop stall.
The maintainers list affected versions from 0.16.0 through 0.69.0 and fixed release 0.70.0. Turning off JWT detection without an equivalent replacement can remove secret-redaction protection, and the advisory does not document successful in-the-wild exploitation.
Agent-secret filtering must be both bounded in computational cost and effective at protecting the secrets it is intended to remove.
This bug is independent of the ANSI stripping option: the security-oriented JWT masking expression can process untrusted prompt or tool content with pathological runtime before handing results to the agent. A mitigation that turns off JWT redaction may restore availability at the cost of exposing secrets in traces. Version repair and resource limits should preserve confidentiality rather than treating every redaction disablement as a harmless workaround.
Claims & evidence
CLM-DB264-PYDANTIC-JWT-REGEX-BOUNDARYThe maintainers list affected versions from 0.16.0 through 0.69.0 and fixed release 0.70.0. Turning off JWT detection without an equivalent replacement can remove secret-redaction protection, and the advisory does not document successful in-the-wild exploitation.supported
Basis: reported finding
- supportsGHSA-5m5q-5qj4-gx9h: Pydantic AI JWT secret-redaction denial of serviceprimary disclosure
JWT redaction regex and affected paths; version and patch guidance
CLM-DB264-PYDANTIC-JWT-REGEX-MECHANISMA separate Pydantic AI advisory identifies a quadratic JWT-pattern redaction expression reachable through untrusted prompt, tool or output text, allowing CPU exhaustion or a shared event-loop stall.supported
Basis: reported finding
- supportsGHSA-5m5q-5qj4-gx9h: Pydantic AI JWT secret-redaction denial of serviceprimary disclosure
JWT redaction regex and affected paths; version and patch guidance
Implications
Agent-secret filtering must be both bounded in computational cost and effective at protecting the secrets it is intended to remove.
Controls and mitigations
- Upgrade to patched pydantic-ai-harness and keep safe, bounded secret redaction active; measure worst-case input processing under adversarial lengths.
Unknowns and contradictions
- Rate and duration of practical stalls under deployment-sized payload limits.
- Whether unaffected redaction configurations preserve confidentiality.
Sources and citation
Material revision history
- Nov 19, 2026 · Published version · first publication · revision 266