Wil*_*ill 2 spring-security oauth-2.0
我正在使用spring-security-oauth-1.0.0.M3使用spring-security 3.0和oauth2的应用程序.它工作正常.但看起来迁移到spring-security 3.1看起来不会是微不足道的.我一直无法确认仍然支持oauth模块.
例如,oauth教程提到3.0而不是3.1:
https://github.com/SpringSource/spring-security-oauth/wiki/tutorial
当我尝试使用spring-security-oauth 1.0.0.M3或M4直接升级到3.1时,我在下面的讨论中遇到了类似于2012年3月4日评论的问题:
http://code.google.com/p/spring-security-social/wiki/Usage
具体来说,我在Tomcat日志中看到了这一点:
org.springframework.beans.factory.parsing.BeanDefinitionParsingException: Configuration
problem: Failed to import bean definitions from URL location ...
Offending resource: class path resource [spring/applicationContext.xml]; nested
exception is org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected
exception parsing XML document from URL ...; nested exception is
org.springframework.beans.FatalBeanException: Invalid NamespaceHandler class
[org.springframework.security.oauth2.config.OAuth2SecurityNamespaceHandler] for namespace
[http://www.springframework.org/schema/security/oauth2]: problem with handler class file or
dependent class; nested exception is java.lang.NoClassDefFoundError:
org/springframework/security/web/util/AntUrlPathMatcher
Run Code Online (Sandbox Code Playgroud)
有人可以建议上述问题的解决方案,或指向使用spring-security 3.1和spring-security-oauth的参考,或者建议使用spring-security 3.1实现oauth2的更好的替代方案?
或者,如果我错过了弹簧安全3.1的基本要点,那么知道也是有用的.
谢谢!
是的,Spring Security OAuth里程碑版本1.0.0.M6,特别是oauth2模块,支持Spring Security 3.1.0.它尚未被视为发布.该的OAuth 2.0规范本身并不是最终的.
该1.0.0.M6样品似乎是实现最准确,最完整的参考.完整的1.0.0.M6标签zipball就在这里.
该OAuth的2开发人员指南是一个很好的文本引用.它不是100%准确,至少相对于1.0.0.M6.例如,属性user-approval-page属于授权服务器而非授权代码.
Maven pom.xml必须引用artifactId spring-security-oauth2(而不是旧版本中的spring-security-oauth,如1.0.0.M3).
| 归档时间: |
|
| 查看次数: |
5031 次 |
| 最近记录: |