Enforce EXECUTE permission on data-running endpoints#2231
Closed
philipfweiss wants to merge 1 commit into
Closed
Conversation
Require the EXECUTE action on every node a query is run against, for the node and metrics data/stream endpoints. EXECUTE was modeled in the permission hierarchy but never checked, so running queries was gated only by build-time READ checks (and not at all on cache hits). Because EXECUTE implies READ, this also closes the cache-hit gap. No-op under the default permissive policy. Co-authored-by: Cursor <cursoragent@cursor.com>
✅ Deploy Preview for thriving-cassata-78ae72 canceled.
|
Contributor
Author
|
Closing as not strictly necessary for the RBAC enablement MVP. EXECUTE enforcement is an independent, optional gate on query execution; where the underlying query engine already enforces data access it is redundant. The plan now focuses on metadata/write governance (see #2234). Can revive this branch later if a DJ-level execute gate is wanted. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Tracking: #2234 (step 10, optional, of the RBAC enablement sequence).
EXECUTEis part of the RBAC permission hierarchy but was never checked anywhere, so running queries was gated only by build-timeREADchecks (and not at all on cache hits). This adds explicitEXECUTEenforcement on the query-running endpoints.GET /data/{node}/andGET /stream/{node}requireEXECUTEon the node.GET /data/andGET /stream/requireEXECUTEon each requested metric.EXECUTEimpliesREADin the hierarchy, this also closes the cache-hit gap where SQL isn't rebuilt and the build-timeREADcheck would be skipped.Note: this is an independent, optional gate. In deployments where the underlying query engine already enforces data access, a DJ-level
EXECUTEgate is a redundant second plane and can be left permissive. Semantics: a read-only user can view metadata/SQL but cannot run queries. No-op under the defaultpermissivepolicy, so nothing breaks today.