dropwizard-authorization:Dropwizard框架的授权扩展

时间:2021-05-13 16:20:30
【文件属性】:
文件名称:dropwizard-authorization:Dropwizard框架的授权扩展
文件大小:100KB
文件格式:ZIP
更新时间:2021-05-13 16:20:30
Groovy Dropwizard的授权 For Dropwizard 0.8.x use 0.1.4 version from jCenter: group: 'com.stansvec', name: 'dropwizard-authorization', version: '0.1.4' 此扩展使用自定义@Auth批注进行主体身份验证和授权。 @Principal批注可用于主体注入。 验证由dropwizard-auth模块执行。 有几种方法可以定义授权规则: 通过定义角色。 主体需要具有@Auth批注元素指定的角色,才能被授予访问资源的权限。 通过定义表达式。 为了允许委托人访问资源,必须将@Auth注释元素指定的表达式评估为true。 角色和表情可以结合使用。 定义角色 角色是通过实现Role接口定义的。 public class Roles { public static
【文件预览】:
dropwizard-authorization-master
----.gitignore(25B)
----settings.gradle(45B)
----build.gradle(2KB)
----src()
--------main()
--------test()
----.travis.yml(36B)
----gradlew(5KB)
----add-license.sh(95B)
----LICENSE.txt(1KB)
----README.md(7KB)
----gradlew.bat(2KB)
----license-short.txt(175B)
----gradle()
--------wrapper()

网友评论