开发者

Is "isUserInRole" method related to JAAS?

开发者 https://www.devze.com 2023-02-24 16:42 出处:网络
I\'ve configured JAAS in glassfish 3.0 and used JDBCRealm for authenticating users. It\'s working properly and URL(s) are restricted. But the method

I've configured JAAS in glassfish 3.0 and used JDBCRealm for authenticating users. It's working properly and URL(s) are restricted. But the method #{facesContext.externalContext.isUserInRole('admin')} always returns false, even when the logged in user is admin.I've set "admin" for both "group name" in my database and f开发者_如何学Cor "role name" in the mapping file and the user is admin. What might be the problem?


In a servlet container, isUserInRole is just a call to the underlying servlet method. I would double-check the role mappings in the deployment descriptor.

0

精彩评论

暂无评论...
验证码 换一张
取 消