apache / apache/kyuubi

Support checks for Iceberg system procudures in Authz

Open
#5,406 6 comments 1 reaction 1 assignee Claimed by @yabola View on GitHub
hacktoberfest
Dominant language
Scala
Stars
2.4k
Forks
1k
PR merge metrics
No merged PRs in 30d

Description

### Code of Conduct

- [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)

### Search before creating

- [X] I have searched in the [task list](https://github.com/orgs/apache/projects/296) and found no similar tasks.

### Mentor

- [x] I have sufficient knowledge and experience of this task, and I volunteer to be the mentor of this task to guide contributors to complete the task.

### Skill requirements

- Familiarize the Authz plugin, Ranger and Iceberg Spark plugin
- Familiarize the Authz testing

### Background and Goals

Iceberg provides a series of system procedures for lifecycle management, which are essential for the lakehouse's administrator and users. And multiple plans may be executed in single procedure.
Now the Authz plugin supports checking privileges for DMLs and DDLs on Iceberg tables, but system procedures are not in the range. It leaves a permission leaking to the Iceberg table management.

Doc reference: https://iceberg.apache.org/docs/latest/spark-procedures/
This task is targeted to ensure privilege checking on the Spark system procedures of Iceberg, including:
- [ ] Snapshot management #5407
- [x] rollback_to_snapshot
- [x] rollback_to_timestamp
- [x] set_current_snapshot
- cherrypick_snapshot
- fast_forward
- [ ] Metadata management
- expire_snapshots
- remove_orphan_files
- rewrite_data_files
- rewrite_manifests
- rewrite_position_delete_files
- [ ] Table migration
- snapshot
- migrate
- add_files
- register_table
- [ ] Metadata information (Optional)
- ancestors_of
- Change Data Capture
- create_changelog_view

### Implementation steps

1. Create e-2-e tests for Iceberg in Authz tests for each procedures
2. Prepare and provide proper test cases for positive and negative conditions in each procedure
3. Solve the unsupported logical plans of the procedures, which may have multiple plans in single procedure

### Additional context

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.