Great, you saved my week. I was too upset to read the release. I thought it was only an explanation about the new "features".
Thanks, Luis. ----- Original Message ----- From: "Hans Bergsten" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, October 18, 2002 9:49 PM Subject: Re: Question on documentation... > Luis A wrote: > > Hans, maybe you can help me, > > > > Is there a way to restore the unsecure mode? The students have different > > Servlet names, the broadband access ones have burned CDs for the others, and > > they have a deadline. I do not think I will have the time needed to read the > > documentation and instruct a simple patch or mod. What do you think? > > Didn't I say "see the [Tomcat 4.1.12] release notes for details"? If > you do, you find this: > > Starting with Tomcat 4.1.12, the invoker servlet is no longer > available by default in all webapp. Enabling it for all webapps is > possible by editing $CATALINA_HOME/conf/web.xml to uncomment the > "/servlet/*" servlet-mapping definition. > > Hans > > > ----- Original Message ----- > > From: "Hans Bergsten" <[EMAIL PROTECTED]> > > To: <[EMAIL PROTECTED]> > > Sent: Friday, October 18, 2002 8:33 PM > > Subject: Re: Question on documentation... > > > > > > > >>Luis A wrote: > >> > >>>Man, you must be kidding. So the tutorial I just wrote and emailed to my > >> > > 32 > > > >>>students will not work without the web.xml changes? Are you sure? > >> > >>Yes, I'm sure. URL mapping has been in the Servlet spec since 2.0 (and > >>was an option in JWS before the API was formally specified, I believe), > >>while the "/servlet" default mapping has _never_ been in the spec (even > >>though most web containers have supported it for a long time). The > >>behavior of an "invoker" mapped to a "/servlet" URL was first identified > >>as a security risk back in the Servlet 2.0/2.1 days. > >> > >>Hans > >> > >> > >>>----- Original Message ----- > >>>From: "Hans Bergsten" <[EMAIL PROTECTED]> > >>>To: <[EMAIL PROTECTED]> > >>>Sent: Thursday, October 17, 2002 2:58 PM > >>>Subject: Re: Question on documentation... > >>> > >>> > >>> > >>> > >>>>Paul Toyn wrote: > >>>> > >>>> > >>>>>The following is a snippet from the Jakarta-Tomcat configuration and > >>>>>testing documentation: > >>>>> > >>>>>Once you compile HelloServlet.java, put HelloServlet.class in > >>>>>install_dir/webapps/ROOT/WEB-INF/classes. After compiling the code, > >>>>>access the servlet with the URL http://localhost/servlet/HelloServlet > >>>>>... You should get a simple HTML page that says "Hello". If this URL > >>>>>fails but the test of the server itself succeeded, you probably put the > >>>>>class file in the wrong directory. > >>>>> > >>>>>I've followed the example and everything is working up to the point > >>>>>above. I compiled the java code and it compiled without a hitch, but > >>>> > > I > > > >>>>>do get a 404 error when I try the URL. The test of the server did > >>>>>succeed. I placed the class file into the folder as indicated. Is > >>>> > > the > > > >>>>>documentation correct? Where does the folder "servlet" get involved? > >>>>>What am I doing wrong? > >>>> > >>>>Is this with Tomcat 4.1.12? If so, it's because the "invoker" (the > >>>>servlet mapped to the "/servlet/*" path) is disabled by default starting > >>>>with this version due to security concerns. See the release notes for > >>>>details. > >>>> > >>>>In general, you should use explicit mappings for all servlets instead > >>>>of using the "invoker". Add this to the web.xml file for the application > >>>>(e.g. webapps/ROOT/WEB-INF/web.xml for the Tomcat default application): > >>>> > >>>> <servlet> > >>>> <servlet-name>hello</servlet-name> > >>>> <servlet-class>HelloServlet</servlet-class> > >>>> </servlet> > >>>> ... > >>>> <servlet-mapping> > >>>> <servlet-name>hello</servlet-name> > >>>> <url-pattern>/hello/*</url-pattern> > >>>> </servlet-mapping> > >>>> > >>>>After restarting the web container (Tomcat), you can use a URL like > >>>>this to invoke it: > >>>> > >>>> http://localhost:8080/hello > > -- > Hans Bergsten [EMAIL PROTECTED] > Gefion Software http://www.gefionsoftware.com > JavaServer Pages http://TheJSPBook.com > > =========================================================================== > To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST". > For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST". > Some relevant FAQs on JSP/Servlets can be found at: > > http://archives.java.sun.com/jsp-interest.html > http://java.sun.com/products/jsp/faq.html > http://www.esperanto.org.nz/jsp/jspfaq.jsp > http://www.jguru.com/faq/index.jsp > http://www.jspinsider.com > =========================================================================== To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST". For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST". Some relevant FAQs on JSP/Servlets can be found at: http://archives.java.sun.com/jsp-interest.html http://java.sun.com/products/jsp/faq.html http://www.esperanto.org.nz/jsp/jspfaq.jsp http://www.jguru.com/faq/index.jsp http://www.jspinsider.com