基于Identity的Role-Permission管理 VS2013 ASP.NET MVC模板只提供基础的权限管理,如:账号管理Account,登录注册等,为提高实用性,从四个方面展开实验,1)增加自定义属性,User增加用户名与密码明文,Role增加角色说明;2)开启角色管理、用户管理、用户-角色管理,增加权限管理与角色-权限管理;3)使用FilterAttribute的基于AOP的权限验证;4)展示ASP.NET MVC客户端与服务端的典型应用场景,如EF数据存储、自定义比较器、Application和Session缓存、Client数据Post、Ignite Grid数据展示、跨站点攻击处理等。 本文组织结构如下:
- 自定义属性
- 授权管理
- 验证管理
- 典型应用场景