> From: Anthony Jay [mailto:anthony...@fastmail.fm] > Subject: Contexts and Path and Authentication > > I've had to split my perfectly working application into > two applications as the jsp now requires Form based > authentication and the XML components require Http Basic > authentication as before.
Why would the application know (or care) what authentication mechanism is being used? Why not just have one or the other and be done with it? Even if your form-based authentication has extra fields for the user to fill in, the basic authentication would just be a subset of that. > Which is not what I want, the application must work as before. Then it must be a single webapp, and you must decide which of the two authentication methods to use - or roll your own. (But see below for an alternative.) > I need to remove the /formauth/ and /basicauth/ directories > and my pain will subside. From everything that I have read > this SHOULD be possible when configuring the context element. Nope. > I can only get one war to work at at time (as default context) > using Server.xml > <Context docBase="formauth" path=""/> > when war is deployed in the webapps folder. The above will get you double deployment, besides the problem of putting <Context> elements in server.xml, which is highly inappropriate these days. What you could do is create a simple default (ROOT) webapp that analyzes each request URI and then forwards it to one of the two real apps, which would continue to be deployed as /formauth and /basicauth. A filter would seem appropriate here. - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org