Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Part 2- How role gets assigned to user in JAAS?

 
Lavan Adgaonkar
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Ranchers,

I am currently working on the Part 2 assignment. Have been pondering about using JAAS in the solution.

In case of a web application, users would do self-registration (and thereby create their own userids).From what I understand, I can write my call back handlers in JAAS, and can accordingly even authenticate the users, against the userid information persisted in the application database.

However, what I am not able to figure out is , how does this user, get a particular role assigned. In case of both web/ EJB security, i can define the roles, that would access protected resources/methods.. The contents on the net, give an idea that you define the roles, for specific user ids.. in the j2ee server. In this case, the userids are self-created (by users during registration with the sithe) and cannot be fixed by the administrator in the server.

Does that mean, I cant go for JAAS authentication, if i have self registration or am i missing something totally?

Please help.

Thanks.
Lavan.
 
Lavan Adgaonkar
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Any help?
 
Marcin Nowak
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try to read something about "LoginModule".

I hope it will help you.

Martin.
 
Lavan Adgaonkar
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Read some documentation on those lines and figured out the Subject/Principals.. exactly what I was looking for.

Thanks Martin.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic