I can run my web app using jetty-maven-plugin by setting the following: <plugin> <groupId>org.mortbay.jetty</groupId> <artifactId>jetty-maven-plugin</artifactId> <configuration> ...... <systemProperties> <systemProperty> <name>java.security.auth.login.config</name> <value>src/main/resources/jetty/jaas.conf</value> </systemProperty> </systemProperties> <dependencies> <dependency> <groupId>org.planner</groupId> <artifactId>org.planner.security</artifactId> <version>${project.version}</version> </dependency> </dependencies> .... </plugin>
But the above is only for the development. I want to test how it works in a production environment, so I run the following from the command line in jetty-distribution-8.0.1.v20110908 and got the login module class not found exception: java -Djava.security.auth.login.config=file://D:/projects/ap/jetty-distribution-8.0.1.v20110908/conf/jaas.conf -jar start.jar here I copied my login moduel jar to jetty-distribution-8.0.1.v20110908/lib. JAASLoginService is configured in jetty-web.xml packaged in the war, so it should be well because it runs well with jetty-maven-plugin. If I put my login module jar in jetty-distribution-8.0.1.v20110908/lib/ext, the login module is founded when I did the log in operation on the web UI, but maybe it is the system class path, so I got Credential class not found exception. It should be a class loader issue, but I am newer to Jetty, so I do not know where to put the jar in the jetty distribution. Thanks for your response! On Mon, Sep 12, 2011 at 8:43 PM, Jesse McConnell <je...@intalio.com> wrote: > This is generally a classloader issue so make sure that your login > class in available where it should be. > > as thomas said, how are you starting up jetty? > > cheers, > jesse > > On Mon, Sep 12, 2011 at 07:40, Thomas Becker <tbec...@intalio.com> wrote: > > Hi, > > > > I just recently setup a JAAS setup using the same tutorial as you did: > > http://wiki.eclipse.org/Jetty/Tutorial/JAAS > > > > I remember I've had the same exception and I did resolve it by starting > from > > scratch and recreating all config files. So I don't know exactly what my > > problem was. > > > > However could you please paste: > > > > - All JAAS config files you've created > > - The commandline you use to start jetty > > - jetty-plus.xml > > - web.xml > > > > It's crucial that you don't have any typos in the loginModuleNames, etc. > as > > described in the tutorial. > > > > Cheers, > > Thomas > > > > On 9/12/11 8:19 AM, Guofeng Zhang wrote: > > > > Hi, > > I developed a login module and configure it following > Jetty/Tutorial/JAAS. > > When I try to log in from my web login page, i got the following error > and > > my page is directed to the login error page: > > WARN:oejpj.JAASLoginService: > > javax.security.auth.login.LoginException: unable to find LoginModule > class: > > <my login module class> > > at > > javax.security.auth.login.LoginContext.invoke(LoginContext.java:808) > > at > > javax.security.auth.login.LoginContext.access$000(LoginContext.java:186) > > at > > javax.security.auth.login.LoginContext$4.run(LoginContext.java:683) > > at java.security.AccessController.doPrivileged(Native Method) > > at > > javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:680) > > at > > javax.security.auth.login.LoginContext.login(LoginContext.java:579) > > at > > > org.eclipse.jetty.plus.jaas.JAASLoginService.login(JAASLoginService.java:217) > > at > > > org.eclipse.jetty.security.authentication.FormAuthenticator.validateRequest(FormAuthenticator.java:184) > > at > > > org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:442) > > .... > > I tried to deploy my login module to ${jetty_home/lib, but not succeed. > > Your help is appreciated. > > Jetty version: jetty-distribution-8.0.1.v20110908 > > > > > > _______________________________________________ > > jetty-users mailing list > > jetty-users@eclipse.org > > https://dev.eclipse.org/mailman/listinfo/jetty-users > > > > -- > > thomas becker > > tbec...@intalio.com > > > > http://webtide.com / http://intalio.com > > (the folks behind jetty and cometd) > > > > _______________________________________________ > > jetty-users mailing list > > jetty-users@eclipse.org > > https://dev.eclipse.org/mailman/listinfo/jetty-users > > > > > _______________________________________________ > jetty-users mailing list > jetty-users@eclipse.org > https://dev.eclipse.org/mailman/listinfo/jetty-users >
_______________________________________________ jetty-users mailing list jetty-users@eclipse.org https://dev.eclipse.org/mailman/listinfo/jetty-users