1
votes

I have create a web application in eclipse which I am deploying to Tomcat 7 (through eclipse).

I use NTLM authentication (using waffle 1.5) to log in to the application and I want to supply the necessary jars with the application that I am building (and not in the Tomcat 7 lib directory).

To start using waffle I put the following in my META-INF/context.xml

<Valve className="waffle.apache.NegotiateAuthenticator" />

<Realm className="waffle.apache.WindowsRealm" />

When I start the application from eclipse I get a ClassNotFoundException on the waffle.apache.NegotiateAuthenticator

I have the relevant jars in the deployment assembly settings in eclipse as as well in the Order and Export settings. Nothing seems to help.

Update: When I place the files in Tomcat's lib directory then I have no problems and can use the authentication. However, I want to keep the jar files in the web application.

What is necessary to make sure that context.xml has access to the correct jars?

1

1 Answers

2
votes

I would start by putting those files manually in tomcat's lib and getting your configuration to work. Then you can move them into your application. You need jna.jar, platform.jar and commons-logging-1.1.1.jar as well, maybe you have an error above this one or an error in Tomcat's catalina.log. Depending on what you're using you may need to place those files in the parent classloader (tomcat/lib) anyway. Usually all but waffle-jna.jar go in the parent classloader (Tomcat).