contracts.rules_csrf_forms

Page actions AI-ready formats and sharing
Open LLM text
Share with AI
Ask Claude Ask ChatGPT Ask Gemini Ask Copilot

CSRF-related template checks.

CSRF-related template checks.

contracts.rules_csrf_forms

Name Type Default Description
type
qualified_name
element_type
description
source_file
line_number
is_autodoc
autodoc_element
_autodoc_template
_autodoc_url_path
_autodoc_page_type
title
doc_content_hash

Symbols on this page

check_csrf_form_tokens
function
def check_csrf_form_tokens(template_sources: dict[str, str], middleware_list: list[Any]) -> list[ContractIssue]

Warn when CSRFMiddleware is active but a static mutating form lacks a token.

Parameters

Name Type Default Description
template_sources dict[str, str]
middleware_list list[Any]

View source · /home/runner/work/chirp/chirp/site/../src/chirp/contracts/rules_csrf_forms.py:1