verdier opened a new pull request, #45214:
URL: https://github.com/apache/superset/pull/45214

   ### SUMMARY
   #40650 enforces datasource access in the RLS rule commands, and #41294 
extends the check to partial updates that omit `tables`. When the payload does 
carry `tables`, though, `UpdateRLSRuleCommand` only checks the submitted 
tables. A caller with access to dataset B but not to dataset A can therefore 
rebind a rule from A to B, which lifts the filter from A.
   
   The update now always checks the rule's current tables, then the submitted 
ones when `tables` is present.
   
   ### TESTING INSTRUCTIONS
   `pytest tests/unit_tests/commands/security/rls_test.py`
   
   The new test 
`test_update_rls_rule_forbidden_when_retargeting_away_from_denied_tables` fails 
on master and passes with this change.
   
   ### ADDITIONAL INFORMATION
   - [ ] Has associated issue:
   - [ ] Required feature flags:
   - [ ] Changes UI
   - [ ] Includes DB Migration (follow approval process in 
[SIP-59](https://github.com/apache/superset/issues/13351))
   - [ ] Introduces new feature or API
   - [ ] Removes existing feature or API
   
   Affects unreleased code only: #40650 is not in 6.1.
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)
   
   https://claude.ai/code/session_01Muk4ptfk2ka1wrxivBHH7U
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to