LD is tigger forever,CG are not brothers forever, throw the pot and shine forever.
Modesty is not false, solid is not naive, treacherous but not deceitful, stay with good people, and stay away from poor people.
talk is cheap, show others the code and KPI, Keep progress,make a better result.
Survive during the day and develop at night。
目录
概 述
naos 的权限模块:
授权过滤器和控制器缓存
nacos 权限模块只定义了两种操作类型,读和写:
核心逻辑是:
首先判断是否开启权限控制
然后判断了是否开启白名单
第三个判断就判断了是否含有授权Key,如果请求头里面含有授权
接下来就是权限控制了。
如果使用了权限注解,获取操作类型,和资源类型,然后比较权限,符合就服务,不符合就抛异常
小结
参考资料和推荐阅读
1.链接: link