Hi, I'm new to JAAS, but am using the JavaWorld JBoss JAAS paper to learn. I have the example from there working with JBoss 3.2.3.
Now I'm trying to apply it in my own application. So far I just have a servlet I want to restrict. When I try to access a restricted resource, I getanonymous wrote : | 2004-02-25 09:07:39,874 ERROR [org.jboss.web.tomcat.security.JBossSecurityMgrRealm] Error during authenticate | javax.naming.NamingException: Could not dereference object. Root exception is | javax.naming.NameNotFoundException: Test not bound | at org.jnp.server.NamingServer.getBinding(Ljava.lang.String;)Ljavax.naming.Binding;(NamingServer.java:495) | at org.jnp.server.NamingServer.getBinding(Ljavax.naming.Name;)Ljavax.naming.Binding;(NamingServer.java:503) | at org.jnp.server.NamingServer.getObject(Ljavax.naming.Name;)Ljava.lang.Object;(NamingServer.java:509) | at org.jnp.server.NamingServer.lookup(Ljavax.naming.Name;)Ljava.lang.Object;(NamingServer.java:282) | at org.jnp.interfaces.NamingContext.lookup(Ljavax.naming.Name;)Ljava.lang.Object;(NamingContext.java:528) | at org.jnp.interfaces.NamingContext.lookup(Ljava.lang.String;)Ljava.lang.Object;(NamingContext.java:507) | at javax.naming.InitialContext.lookup(Ljava.lang.String;)Ljava.lang.Object;(InitialContext.java:347) | at org.jnp.interfaces.NamingContext.resolveLink(Ljava.lang.Object;Ljava.util.Hashtable;)Ljava.lang.Object;(NamingContext.java:964) | at org.jnp.interfaces.NamingContext.lookup(Ljavax.naming.Name;)Ljava.lang.Object;(NamingContext.java:613) | at org.jnp.interfaces.NamingContext.lookup(Ljava.lang.String;)Ljava.lang.Object;(NamingContext.java:507) | at org.jboss.web.tomcat.security.JBossSecurityMgrRealm.authenticate(Ljava.lang.String;Ljava.lang.String;)Ljava.security.Principal;(JBossSecurityMgrRealm.java:276) | at org.jboss.web.tomcat.tc4.authenticator.FormAuthenticator.authenticate(Lorg.apache.catalina.HttpRequest;Lorg.apache.catalina.HttpResponse;Lorg.apache.catalina.deploy.LoginConfig;)Z(FormAuthenticator.java:320) I can't see the jndi entry for my security-domain / application-policy in jmx-console /JNDIView java:namespace. However I believe my login-config.xml is correct: anonymous wrote : | <application-policy name="Test"> | | <login-module code="org.jboss.security.auth.spi.DatabaseServerLoginModule" flag="required"> | <module-option name="dsJndiName">java:/testDS </module-option> | <module-option name="principalsQuery">select pwd from T_ACCOUNT where userId=?</module-option> | <module-option name="rolesQuery">select userRoles, roleGroup from T_ROLES where username=?</module-option> | </login-module> | | </application-policy> | Am I right in thinking I should see the JNDI entry as long as the application policy is in place? I've got the security-domain in web.xml also set to Test. TIA Martin View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3822827#3822827 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3822827 ------------------------------------------------------- SF.Net is sponsored by: Speed Start Your Linux Apps Now. Build and deploy apps & Web services for Linux with a free DVD software kit from IBM. Click Now! http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click _______________________________________________ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user