Im using the <security-constraint> feature of Tomcat. Everything works well, but I dont know how to retrieve the login entered during authentication to use it throughout my application... Have you guys done this before ?
What you want is request.getUserPrincipal(). This will return a java.security.Principal object. You can get the name by calling getName() on that object.
Unfortunately, you can't get the role or roles for the user. You have to know the roles beforehand and then use request.isUserInRole to determine wether they are or are not in a given role. :(
-chris
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
