Skip to content

Commit 8a9777c

Browse files
committed
[sea-orm-pro] edit
1 parent a4df35a commit 8a9777c

File tree

3 files changed

+16
-16
lines changed

3 files changed

+16
-16
lines changed

sea-orm-pro/docs/01-index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626

2727
3.4 [Navbar](03-site-config/04-navbar.md)
2828

29-
3.5 [Role Based Access Control](03-site-config/05-rbac.md)
29+
3.5 [RBAC](03-site-config/05-rbac.md)
3030

3131
4. Raw Table Config
3232

sea-orm-pro/docs/03-site-config/05-rbac.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Role Based Access Control
1+
# RBAC
22

33
![](../../static/img/site-config-rbac.png#light)
44
![](../../static/img/site-config-rbac-dark.png#dark)
Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,53 +1,53 @@
11
# Overview
22

3-
Here is a high level overview of the design and the requirements that shaped them:
3+
:::tip
4+
5+
Read more on [Role Based Access Control in SeaORM 2.0](https://www.sea-ql.org/blog/2025-09-30-sea-orm-rbac/) blog post.
6+
7+
:::
8+
9+
Here is a high level overview of the design of SeaORM's RBAC:
410

5-
### 1. Table‑level access control
11+
#### 1. Table‑level access control
612

713
Different user groups can only read or modify certain tables, e.g. customers can only read invoices, but not modify them.
814

915
Design: RBAC engine is table‑scoped so permissions can be expressed directly in terms of CRUD on tables.
1016

11-
### 2. Simplicity of user assignment
17+
#### 2. Simplicity of user assignment
1218

1319
Each user should have a clear, unambiguous role to avoid confusion.
1420

1521
Design: one user = one role. This prevents complexity of multiple roles per user.
1622

17-
### 3. Role hierarchy and inheritance
23+
#### 3. Role hierarchy and inheritance
1824

1925
We want to create roles that inherit from multiple roles like A = B + C where A will have the union of permissions from B and C.
2026

2127
We want to avoid duplicating permission sets across roles. For example, a 'Manager' should automatically get all 'Employee' permissions, plus extras.
2228

2329
Design: Hierarchical roles with multiple inheritance.
2430

25-
### 4. Granular, composable permissions
31+
#### 4. Granular, composable permissions
2632

2733
We need to allow fine‑grained control like 'read customers but not update them'. We want permission grant to be easy to reason about.
2834

2935
Design: Role can be assigned set of permissions (CRUD) on resources (tables). Permissions are additive, once granted, cannot be taken away (but can be overridden on a per user basis).
3036

31-
### 5. Extensibility
37+
#### 5. Extensibility
3238

3339
We want to extend beyond tables (e.g. application specific actions, or even non‑DB resources).
3440

3541
Design: Engine is generic - resource + permission abstraction can be applied to more than just CRUD operations on SQL tables.
3642

37-
### 6. Wildcard for convenience
43+
#### 6. Wildcard for convenience
3844

3945
Sometimes we need to grant superusers full access without enumerating every resource/permission.
4046

4147
Design: Opt‑in `*` wildcard for 'all permissions' or 'all resources.'
4248

43-
### 7. Per‑user overrides
49+
#### 7. Per‑user overrides
4450

4551
Occasionally, a single user needs an exception (e.g. a contractor who can only read one table, or a manager who should be denied one sensitive table).
4652

4753
Design: User‑level overrides to grant/deny permissions.
48-
49-
:::tip
50-
51-
Read more on [Role Based Access Control in SeaORM 2.0](https://www.sea-ql.org/blog/2025-09-30-sea-orm-rbac/) blog post.
52-
53-
:::

0 commit comments

Comments
 (0)