File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JBoss/WildFly and the fly likes Jboss and Jaas: where do I go wrong? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » JBoss/WildFly
Bookmark "Jboss and Jaas: where do I go wrong?" Watch "Jboss and Jaas: where do I go wrong?" New topic

Jboss and Jaas: where do I go wrong?

erika santo

Joined: Sep 14, 2011
Posts: 1
Hi everybody

I'm new in this forum and I'm a newby. I'm stuck from a couple of days and really need some help.

I am using Jboss 5.1, java 1.6 and I'm developing a web application that needs login.
I'd like to uso JAAS functionality so this is what I have done:

- I wrote my own LoginModule and my own Principal
- Modified the jboss-web.xml as follows:

- Modified the login-conf.xml in jbossdirectory/server/default/conf as follows:
<application-policy name="LoginModuleRDS">
<login-module code="security.HibernateLoginModule"
<module-option name="restore-login-identity">true</module-option>


and deployed.

When I run the application I correctly see the log-in page.
My LoginModule is correctly called and correctly executed but then I get the following error:

The first 5 lines are logs that i'll delete as soon as i get this working.

17:02:52,671 INFO [HibernateLoginModule] MyLoginModule-initialize
17:02:52,671 INFO [HibernateLoginModule] MyLoginModule-dentro al login
17:02:52,671 INFO [HibernateLoginModule] MyLoginModule-dentro a validate2
17:02:52,692 INFO [HibernateLoginModule] MyLoginModule-dentro a validate
17:02:52,693 INFO [HibernateLoginModule] MyLoginModule-dentro a commit
17:02:52,708 ERROR [CoyoteAdapter] An exception or error occurred in the container during the request processing
at java.util.Hashtable.put(
at org.apache.catalina.session.StandardSession.setNote(
at org.apache.catalina.authenticator.FormAuthenticator.authenticate(
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(
at org.apache.catalina.core.StandardHostValve.invoke(
at org.apache.catalina.valves.ErrorReportValve.invoke(
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(
at org.apache.catalina.core.StandardEngineValve.invoke(
at org.apache.catalina.connector.CoyoteAdapter.service(
at org.apache.coyote.http11.Http11Processor.process(
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(

Can anybody please give an hint of where am I going wrong... Any help woud truly be appriciated!!!
I agree. Here's the link:
subject: Jboss and Jaas: where do I go wrong?
jQuery in Action, 3rd edition