JAAS additional LoginModules

强颜欢笑 提交于 2019-12-05 05:25:21

You should implement a LoginModule which in the login method you access the LDAP and check username/password and in the commit method you access the DB and fill the principals.
There is no need here to use multiple LoginModule

It is great! But implement the LoginModule give you more power to customize the way you interact with LDAP server.
I also struggle the same problem as you. But remember when implement the LoginModule, you should add the role in login() function , not in commit(), otherwise your subjet will not get the principal.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!