Skip to content

Fix access control issue for task group views in DAG UI #63382

Closed
SUCHNA24 wants to merge 1 commit intoapache:mainfrom
SUCHNA24:#62532
Closed

Fix access control issue for task group views in DAG UI #63382
SUCHNA24 wants to merge 1 commit intoapache:mainfrom
SUCHNA24:#62532

Conversation

@SUCHNA24
Copy link

This PR fixes DAG-level access control for task group views when using FAB-based authorization.

Previously, users with DAG-specific permissions like can_read on DAG:<dag_id> plus task-related permissions could still get a 404 when accessing task group and grid-related views, unless they were also granted the global can_read on DAGs (and often DAG Runs). This effectively forced over‑broad permissions just to view per‑DAG task group details.

With this change, the authorization logic correctly respects DAG-specific permissions for DAG-scoped sub-entities (task instances, runs, and task groups) so that:

  • A user with can read DAG:<dag_id> and the relevant task/run permissions can access:
    • Task group detail views (/dags/{dag_id}/tasks/group/{group_id})
    • Grid/structure views for that DAG
    • Other DAG detail pages for that DAG
  • The same user no longer needs global can read DAGs to reach those URLs, so DAG visibility remains restricted to the intended set.

The behavior for truly global permissions (e.g. full DAGs access) is unchanged.

Testing

  • Manual: Verified that a restricted role with only DAG-specific access and task/run read permissions can:
    • Open /dags/{specific_dag_id}/tasks/group/{group_id} without 404
    • Access the same DAG’s grid/structure views
    • Still not see DAGs they are not explicitly allowed to read.

@kaxil
Copy link
Member

kaxil commented Mar 11, 2026

What's the PR title: "Issue #59840 was resolved by me"!

@kaxil kaxil closed this Mar 11, 2026
@SUCHNA24
Copy link
Author

Thanks for pointing that out. I apologize for the incorrect PR title. I’m still learning the contribution guidelines and will make sure to use a proper descriptive title in future pull requests.

@SUCHNA24 SUCHNA24 changed the title Issue #59840 was resolved by me Fix access control issue for task group views in DAG UI (#59840) Mar 12, 2026
@SUCHNA24 SUCHNA24 changed the title Fix access control issue for task group views in DAG UI (#59840) Fix access control issue for task group views in DAG UI Mar 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:translations area:UI Related to UI/UX. For Frontend Developers. translation:default

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants