对rbac理解笔记

来源:互联网 发布:it helpdesk 工作内容 编辑:程序博客网 时间:2024/06/08 15:00

1.数据库设计

user用户表id name email  is_admin status update_time create_time

role角色表 id name status update_time create_time

user_role用户角色关系表 id uid role_id create_time

access权限表 id title urls(页面对应url) status update_time create_time

role_access 角色权限表 id role_id access_id create_time

2.判断权限的逻辑

a)取出当前登陆用户所属角色

b)在通过角色 取出 所属 权限关系

c)在权限表中取出所有的权限链接

d)判断当前访问的链接 是否在 所拥有的权限列表中



rbac流程图




rbac模块功能



权限控制流程
原创粉丝点击