Hi Paul, I don't see the JSecurityFilter defined in your web.xml. Typically you'll need to define that first and then define the realms that JSecurity uses inside that definition.
Have a look at this: http://jsecurity.org/api/org/jsecurity/web/servlet/JSecurityFilter.html Also, look at the sample applications that come with JSecurity - most are set up as webapps with web.xml examples. Once you've added the filter, you'll want to define a JSecurity Realm inside the [main] .ini config section. Note that this is _different_ than what Tomcat calls a Realm (that you currently have defined). You'll need to write a JSecurity Realm implementation that effectively looks up the Tomcat Realm from JNDI, and wraps it. Then JSecurity calls to your JSecurity Realm implementation will just delegate to the Tomcat Realm in JNDI. - Les On Tue, Sep 23, 2008 at 2:53 AM, zog45 <[EMAIL PROTECTED]> wrote: > > > Hi - I'm new to jsecurity, > > I'm trying to get my first attempt at jsecurity working for my web > application. > > I'm getting this error using Tomcat 6 + eclipse plugin: > > > > 22-Sep-2008 14:26:24 org.apache.tomcat.util.digester.SetPropertiesRule begin > > WARNING: [SetPropertiesRule]{Server/Service/Engine/Realm} Setting property > 'debug' to '99' did not find a > > > matching property. > > > > So far all I've done is: > > 1) Created a users and user_roles database tables > > 2) Added into my conf/server.xml the following realm info: > > <Realm className="org.apache.catalina.realm.JDBCRealm" debug="99" > > driverName="oracle.jdbc.driver.OracleDriver" > > connectionURL="jdbc:oracle:thin:[USERNAME]/[EMAIL PROTECTED]:1521:XE" > > userTable="users" userNameCol="user_name" userCredCol="user_pass" > > userRoleTable="user_roles" roleNameCol="role_name"/> > > > 3) Added the following lines into my web.xml > > <security-constraint> > > <display-name>Paul Test</display-name> > > <web-resource-collection> > > <web-resource-name>MUMBO</web-resource-name> > > <url-pattern>/Control.do</url-pattern> > > <http-method>GET</http-method> > > <http-method>POST</http-method> > > </web-resource-collection> > > > > <auth-contraint> > > <role-name>ADMIN</role-name> > > <role-name>MEMBER</role-name> > > <role-name>GUEST</role-name> > > </auth-contraint> > > </security-constraint> > > > > <login-config> > > <auth-method>FORM</auth-method> > > <form-login-config> > > <form-login-page>/index.htm</form-login-page> > > <form-error-page>/errorPage.jsp</form-error-page> > > </form-login-config> > > </login-config> > > > web.xml > > <login-config> > > <auth-method>FORM</auth-method> > > </login-config> > > <security-role><role-name>ADMIN</role-name></security-role> > > <security-role><role-name>MEMBER</role-name></security-role> > > <security-role><role-name>GUEST</role-name></security-role> > > > PLEASE CAN ANYONE HELP????? > > > > > > > > -- > View this message in context: > http://n2.nabble.com/Problem-starting-tomcat-with-JDBCRealm---please-help%21-tp1111661p1111661.html > Sent from the JSecurity Developer mailing list archive at Nabble.com. > >
