You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit a73ffae
Browse filesBrowse the repository at this point in the historyBrowse files
Add scoped Execution API access for Dag processors (#74370)
* Add scoped Execution API access for Dag processors
Dag processors need credentials tied to their registered Job and granted bundles before they can communicate with a remote Execution API. Keep this foundation independently reviewable while the processor command retains its existing database-backed behavior.
* Fix documentation build for task-token revocation
The heading warning prevents the security documentation from building successfully.
* Allow parsing-time queries before a Dag is first stored
New Dags can query execution state while parsing, before they have a DagModel row. Rejecting those requests prevents their initial parse from completing.
* Enforce scoped Dag processor token claims and expiry
Task and processor credentials need distinct validation so task-only routes cannot receive processor identities. Expired provisioning credentials must not leave a registered Job behind, while trusted in-process task identities must remain usable without JWT expiry.
* Fix Dag processor token rotation and registration failures
Provisioner restarts and transient write failures must not interrupt running processors. Failed registration must not leave an incomplete Job that a retry can adopt.
* Fix Dag processor token docs and renewal test flakiness
Slow CI responses can exceed the best-effort renewal deadline, while the authentication guidance must reflect the scoped Execution API contract.
Copy file name to clipboardExpand all lines: airflow-core/src/airflow/api_fastapi/execution_api/AGENTS.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -77,4 +77,4 @@ Adding a new Execution API feature touches multiple packages. All of these must
77
77
78
78
## Token Scope Infrastructure
79
79
80
-
Token types (`"execution"`, `"workload"`), route-level enforcement via `ExecutionAPIRoute` + `require_auth`, and the `ti:self` path-parameter validation are documented in the module docstring of `security.py`.
80
+
Token types (`"execution"`, `"workload"`, `"callback"`, `"dag_processor_session"`, `"dag_processor"`, `"dag_parse"`), route-level enforcement via `ExecutionAPIRoute` + `require_auth`, and the `ti:self` path-parameter validation are documented in the module docstring of `security.py`. A route that admits `dag_processor` or `dag_parse` tokens for Connection, Variable, XCom, Dag run or task-instance reads must also bind the request to a granted Dag bundle (`SelectedDagBundle` or `DagInGrantedBundle`); the `/jobs` routes bind to the `job_id` claim instead. `test_token_scope_boundaries.py` lists the bundle-bound routes and the parse-time messages that use them.
0 commit comments