[jboss-user] [JBoss Portal] - Re: Calling JAAS

NM-156 do-not-reply at jboss.com
Tue Sep 25 12:29:02 EDT 2007


cpage - I too have a custom LoginModule involved here. I backtracked a little and the problem appears to be with my LoginModule.

Try deactivating your valve temporarily. Leave your LoginModule active, and see if you get the same results when you try the Dashboard link after login.

I vertified this by deactivating my valve first, then I activated my LoginModule (only). My LoginModule extends AbstractServerLoginModule. Here is the overridden getRoleSets() method (getIdentity() simply returns a Principal created with the login name). Anybody know what could be causing the 403 error on the dashboard link? Admin and Logout links still work fine. Thanks.


  | 	protected Group[] getRoleSets() throws LoginException 
  | 	{
  | 		logger.info("%%%%% - CALLING LoginModule.getRoleSets() method from PORTAL %%%%%");
  | 		
  | 		Group rolesGroup = new SimpleGroup("Roles");
  | 		rolesGroup.addMember(new SimplePrincipal("Authenticated"));			// Must add authenticated principle
  | 		rolesGroup.addMember(new SimplePrincipal("Users"));				// Gives user Users rites (Test)
  | 		rolesGroup.addMember(new SimplePrincipal("Admin"));				// Gives user Administrators rites (Test)
  | 		rolesGroup.addMember(new SimplePrincipal("testrole"));				// Custom test role
  | 		
  | 		// Note that the identity needs to exist as a user account inside the portal prior to login
  | 		
  | 		rolesGroup.addMember(getIdentity());								// Add login identity as role (Test)
  | 
  | 		return new Group[] { rolesGroup };
  | 	}

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4088514#4088514

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4088514



More information about the jboss-user mailing list