matrixorigin / matrixorigin/matrixone

[Feature Request]: DB support of row/column access control

Open
#23,271 1 comment 0 reactions 1 assignee Claimed by @slyunnn View on GitHub
ai-light kind/feature phase/testing
Dominant language
Go
Stars
1.9k
Forks
311
Avg merge
1d 3h
Merged PRs (30d)
768

Description

### Is there an existing issue for the same feature request?

- [x] I have checked the existing issues.

### Is your feature request related to a problem?

```Markdown
We need to bring this feature in kernel.
```

### Describe the feature you'd like

First, record the row/column privilege. We can create a new table, mo_role_rowcol_priv. Store the query rewrite hint. (roleid, dbid, tableid) -> query hint.

Maybe add a syntax,

grant rowcol privilege 'the hint string' on table T to role R;
revoke ...
Or we simply create a function, add_rowcol_privilege(role, table, 'hint string');

Now, when user open a table, we attach this hint to the table -- same trick as before.
We can load all these mappings when user login/alter role, or, we can load at query compilation time.

### Describe implementation you've considered

_No response_

### Documentation, Adoption, Use Case, Migration Strategy

```Markdown

```

### Additional information

_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.