buji-pac4j integartion与Apache Shiro和identityServer3

时间:2016-12-14 13:28:23

标签: shiro identityserver3

我正在尝试学习buji-pac4j的集成。我已经尝试了在以下网址https://github.com/pac4j/buji-pac4j-demo上提供的演示版本,但它似乎对我有用。 (操作方面有一些问题给我正确的回拨网址)。

到目前为止,我可以注意到使用演示代码进行握手。

我现在正在尝试其他方式,因为它已在客户端的文档中提供。

根据文件: 客户端表示身份验证机制。它执行登录过程并返回(如果成功)用户配置文件。

我的课程现在有以下详细信息

OidcConfiguration oidcConfiguration = new OidcConfiguration();
oidcConfiguration.setClientId("someClientIDString");
oidcConfiguration.setSecret("someClientSecretString");
oidcConfiguration.setDiscoveryURI("https://development.domainName.com/projectName/idp/.well-known/openid-configuration");
oidcConfiguration.setScope("openid email hrauser hrainfo");
oidcConfiguration.setCallbackUrl("http://localhost:8080/callback"); 

OidcClient oidcClient = new OidcClient(oidcConfiguration);
Config config = new Config(oidcClient);
config.addAuthorizer("admin", new RequireAnyRoleAuthorizer("ROLE_ADMIN"));
OidcAuthenticator OidcAuthenticator = new  OidcAuthenticator(oidcConfiguration); 

以上主要是在课堂上设置变量, 无法想象的是上面将如何实际去和openID服务器交谈。

我缺少的是所有部分。

我正在阅读https://github.com/bujiio/buji-pac4j上提供的文档,但我不清楚这个流程。

任何形式的帮助或指示都将受到赞赏。

PS:我在这个领域很新,所以请求我承担。

0 个答案:

没有答案