Re: Restarting tomcat from web page
hi, could u please give an example ? - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Friday, December 05, 2003 4:09 PM Subject: RE: Restarting tomcat from web page Howdy, It does matter from a practicality perspective: tomcat comes with built-in features to restart individual webapps, so you don't have to do any work. O restart all of tomcat externally is much more work, you'll have to write a script, or use an external tool, etc. Yoav Shapira Millennium ChemInformatics -Original Message- From: Altug B. Altintas [mailto:[EMAIL PROTECTED] Sent: Friday, December 05, 2003 4:21 AM To: Tomcat Users List Subject: Re: Restarting tomcat from web page it doesn't matter, but restarting all of tomcat much better. - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Thursday, December 04, 2003 6:03 PM Subject: RE: Restarting tomcat from web page Howdy, Restarting all of tomcat or just selected webapps? Yoav Shapira Millennium ChemInformatics -Original Message- From: Altug B. Altintas [mailto:[EMAIL PROTECTED] Sent: Thursday, December 04, 2003 10:57 AM To: Tomcat Users List Subject: Restarting tomcat from web page Hi How can i restart Tomcat which is running as service, from a web page 1 - calling bat file ? (not working) 2 - calling http://localhost:8080/manager/html/start?path=/engine (asking password) any clean way ? Regards Altug. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Mod_jk2 and load balancing
Hi all, I try to find information about load balancing (and fail over) using the mod jk2. I cannot find an example with the files workers2.properties and jk2.properties. My configuration is: Tomcat 4.1.24 JDK 1.4.2 IIS 6 Windows 2003 Thanks for any help, even if it is to tell me that mod_jk is better! Jean-Daniel - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[OT] Some questions on Java,Servlet, JSP and Tomcat.
Hi all , I have some questions for which I was unable to find answers by Googling. So I am asking it here. It is quite long. 1, Is there any security threat for Tomcat 4.1 series. I am using Tomcat 4.1.27 for development. What is the history of Tomcat in this regard. Is Tomcat vulnerable to any remote exploitation issues provided that the application is well written. I want to collect some arguments to favour Java and Tomcat. 2, Any documentation on how servlet container is creating multiple instances of same HttpServlet without implementing Runnable interface. At least provide some links to docs or books which teaches threading issues in servlet. It is only for a curiousity. I am only an application developer. I want to improve my knowledge in servlet technology. 3, How to test a servlet for threading issues. 3, Is there anything wrong in implementing logic in service method in a class which extends HttpServlet. What will happen if a doHead and other requests are send to it. How to simulate a doHead,doTrace etc.. request ?. I got some info at http://www.jguru.com/faq/view.jsp?EID=8824 4, Is it possible to synchronise a block of code in a servlet. I mean only one thread of the same servlet execute the same portion of code at a time and completes execution. I dont want to implement SingleThreadModel and there is only one name in web.xml pointing to same servlet class. I have an idea. Is this right. Create a synchronised block which synchronised on the class. synchronized(AlertServlet.class){ --- } My purpose is to synchronize database access. The application dont have a heavy load. 5, Is it secure to transfer a request and response to another object which is created in the service method of a servlet ?. I believe it is a safe approach. I think Struts is doing this. 6, I have seen that Tomcat not shutting down the threads which are active when shut down command is issued. I used to kill Tomcat in such conditions. Does Tomcat will ever kill this threads if they are not completed execution. What criteria is used in such cases. 7, In Tomcat 4.0.x series there is one file catalina.out which prints the number of active Httpprocessor active(I think it is number of threads) ut it is not found in 4.1 series. Is there any way to get this log file in 4.1. I also want to writing to this log mailed to me when the no. of HttpProcessors exceeds a limit without tweaking Tomcat code. rgds Antony Paul. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Connection Refused
When I tried to shutdown tomcat, I got the following message. Please help. Thank you. Mike [EMAIL PROTECTED] bin] % ./shutdown.sh Using CATALINA_BASE: /opt/jakarta-tomcat-5.0.16Using CATALINA_HOME: /opt/jakarta-tomcat-5.0.16Using CATALINA_TMPDIR: /opt/jakarta-tomcat-5.0.16/tempUsing JAVA_HOME: /usr/j2seCatalina.stop: java.net.ConnectException: Connection refusedjava.net.ConnectException: Connection refused at java.net.PlainSocketImpl.socketConnect(Native Method) at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:295) at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:161) at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:148) at java.net.Socket.connect(Socket.java:425) at java.net.Socket.connect(Socket.java:375) at java.net.Socket.init(Socket.java:290) at java.net.Socket.init(Socket.java:118) at org.apache.catalina.startup.Catalina.stopServer(Catalina.java:436) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at org.apache.catalina.startup.Bootstrap.stopServer(Bootstrap.java:322) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:400) IncrediMail - Email has finally evolved - Click Here
Re: newbie help please, localhost not found
Tomcat is now working for me. Thanks to everyone for the suggestions. It turned out to be the firewall as Doug suggested. When I turned off Norton Firewall it worked straight away. I don't understand why a firewall would affect it though, when its not trying to access the internet, but perhaps thats too far off topic. Thanks again, Dave - Original Message - From: Doug Parsons [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Saturday, December 06, 2003 4:25 PM Subject: Re: newbie help please, localhost not found You may want to go even more basic than that. Open a command prompt and try pinging localhost and then try 127.0.0.1 Unless you are running some type of firewall you should get a response. If not, do you have a personal firewall enabled? No you don't have to be connected to a lan, but the TCP/IP stack must be running. The above test will help you determine that. If the ping fails you can contact me off list for more help. I know this veered off topic, but often it is the little things that get ya. - Original Message - From: Jan Behrens [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Saturday, December 06, 2003 11:00 AM Subject: RE: newbie help please, localhost not found Hi there, have you tried http://127.0.0.1:8080 instead? That is the IP usually bound to localhost and it might be that localhost is not resolved correctly to same. If not, try to provide further info. For example, have you installed Tomcat in a path containing spaces such as c:\Program Files\Tomcat. If so, reinstall to a path without spaces. Cheers, Jan -Original Message- From: D. Gilbert [mailto:[EMAIL PROTECTED] Sent: Saturday, December 06, 2003 4:56 PM To: Tomcat Users List Subject: newbie help please, localhost not found When I type http://localhost:8080 in Internet Explorer it says The page cannot be displayed. I've looked through the archives but couldn't find anything. The running.txt file that comes with Tomcat lists only 3 possibilites for why it doesn't work. I've tried changing the port number, I'm using Windows XP so the environment issue doesn't apply and I'm pretty sure that I'm not behind a proxy as I am using my own PC at home. I'm pretty sure the JDK is installed ok as I can run javac. I tried changing JAVA_HOME and CATALINA_HOME to incorrect values and that made things worse so I'm sure they are set correctly. I've tried 2 versions of Tomcat 4.0.1 and 4.1.29. When I startup 4.0.1 I get the messages Starting service Tomcat-Standalone Apache Tomcat/4.0.1 Starting service Tomcat-Apache Apache Tomcat/4.0.1 which are correct according to my book. Can anyone say what the problem is, or any ways to debug it? It should run on a standalone home PC shouldn't it? I don't need to be connected to a LAN or anything do I? I've been trying to solve this for 2 weeks now so I would really appreciate any help please. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat-4.1.24 Hangs
Hi David, the process itself is alive, because there are some log messages, the server just cannot be connected neither by a browser nor by telnet. Zsolt -Original Message- From: David Rees [mailto:[EMAIL PROTECTED] Sent: Sunday, December 07, 2003 8:23 PM To: Tomcat Users List Subject: Re: Tomcat-4.1.24 Hangs Zsolt Koppany wrote: after two days my tomcat-4.1.24 hangs. I cannot connect to the server not even with telnet localhost 8080. The Process (JVM) is not big, it is approx 100Mb. Any ideas why? TC is running under RedHat-9.0 with Sun Jre-1.4.2_02. Send the process a QUIT signal to see where it is hung. Also try upgrading to 4.1.29, it fixes an issue where Tomcat can hang under high load patterns. -Dave - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat-4.1.24 Hangs
Hi, Probably has to do with NPTL in RedHat 9. Try setting the following environment variable: LD_ASSUME_KERNEL=2.4.1 That should stop the hanging. Search the list for further details. Ryan -Original Message- From: Zsolt Koppany [mailto:[EMAIL PROTECTED] Sent: 07 December 2003 17:30 To: Tomcat Users List Subject: Tomcat-4.1.24 Hangs Hi, after two days my tomcat-4.1.24 hangs. I cannot connect to the server not even with telnet localhost 8080. The Process (JVM) is not big, it is approx 100Mb. Any ideas why? TC is running under RedHat-9.0 with Sun Jre-1.4.2_02. Zsolt - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: 2 instances of Tomcat
Thanks for the tips, I'll be trying this all out next week. Iain - Original Message - From: Dan Johnsson [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Friday, December 05, 2003 11:46 PM Subject: Re: 2 instances of Tomcat what about having two JDK? Iain As you have identified, this all falls back on having multiple production environments (with its own set of installed software of specific versions) deployed on the same machine. The good new is that java is multiple-deploy-enabled. I e, the java binaries does not in any way crave a specific install point, a specific set of (system global) environment variables being set or anything like that. When consulting enterprising running Java I consistently give this piece of advice regarding install-points and environment variables: * If you have a single production environment on one machine: - Prefer a version-dependent install-point (e g c:\j2sdk1.4.2_02 on windows) and create a version-independent virtual install-point (short-cut c:\j2se). - Use a version-independent install-point if you have to - Set JAVA_HOME on system level to the version-independent virtual install-point. - When updating: install the new version at a ('nother) version-dependent install-point, redirect your virtual install-point, and you're ready to go. You will (of course) have to restart your services that use java, but nothing more drastical then that. * If you have multiple production environments on the same machine - Use version-dependent install-points for your different versions - Never use version-independent install-points - Do not set JAVA_HOME on system level. Instead, set it in the scripts that start your different services. - When updating: install the new version (at its on install-point), and change the service-start scripts. OK: now you have your JVMs set up. Time to install Tomcat. Good news: Tomcat is also multiple-deploy enabled. So, just follow the same rules (this time the rule referring to CATALINA_HOME). [An interesting note: by setting CATALINA_BASE to an external directory, you can easily update tomcat and reuse your configurations and logs (as long as the format of server.xml have not changed, that is).] Reboot your machine; start your services; take off Good luck Dan Johnsson, System Architect and Security Consultant __ Dan Johnsson | Säkerhetsarkitekt [EMAIL PROTECTED] | www.omegapoint.se tel 0709-15 88 43 | fax 08-517 008 29 Omegapoint AB - din säkra punkt i tillvaron - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat-4.1.27 is WebDAV application stable?
Hello, I got error during access to the Tomcat WebDAV via Windows Active Directory. Do I need to install some binaries on Windows to use WebDAV demo application on Tomcat? Thanks for ideas, Pranas Error log: 12/08/2003 10:56:34 HTTP 404 /_vti_bin/shtml.exe/_vti_rpc htmlheadtitleApache Tomcat/4.1.27 - Error report/titleSTYLE!--H1{font-family : sans-serif,Arial,Tahoma;color : white;background-color : #0086b2;} H3{font-family : sans-serif,Arial,Tahoma;color : white;background-color : #0086b2;} BODY{font-family : sans-serif,Arial,Tahoma;color : black;background-color : white;} B{color : white;background-color : #0086b2;} HR{color : #0086b2;} --/STYLE /headbodyh1HTTP Status 404 - /_vti_bin/shtml.exe/_vti_rpc/h1HR size=1 noshadepbtype/b Status report/ppbmessage/b u/_vti_bin/shtml.exe/_vti_rpc/u/ppbdescription/b uThe requested resource (/_vti_bin/shtml.exe/_vti_rpc) is not available./u/pHR size=1 noshadeh3Apache Tomcat/4.1.27/h3/body/html - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
AW: newbie help please, localhost not found
Hi Dave, your firewall should normally try to restrict ALL connections to and from your maschine. That even applies to connections that originate on your maschine, to the system those are handled basicaly on the same basis that an external request would be handled. I would suggest to tell your firewall that it can safely allow all connections from localhost and 127.0.0.1 and then switch your firewall back on. In Norton you should be able to easily do this by adding those addresses to the trusted zones defined within Norton. HTH, Jan -Ursprüngliche Nachricht- Von: D. Gilbert [mailto:[EMAIL PROTECTED] Gesendet: Montag, 8. Dezember 2003 09:26 An: Tomcat Users List Betreff: Re: newbie help please, localhost not found Tomcat is now working for me. Thanks to everyone for the suggestions. It turned out to be the firewall as Doug suggested. When I turned off Norton Firewall it worked straight away. I don't understand why a firewall would affect it though, when its not trying to access the internet, but perhaps thats too far off topic. Thanks again, Dave - Original Message - From: Doug Parsons [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Saturday, December 06, 2003 4:25 PM Subject: Re: newbie help please, localhost not found You may want to go even more basic than that. Open a command prompt and try pinging localhost and then try 127.0.0.1 Unless you are running some type of firewall you should get a response. If not, do you have a personal firewall enabled? No you don't have to be connected to a lan, but the TCP/IP stack must be running. The above test will help you determine that. If the ping fails you can contact me off list for more help. I know this veered off topic, but often it is the little things that get ya. - Original Message - From: Jan Behrens [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Saturday, December 06, 2003 11:00 AM Subject: RE: newbie help please, localhost not found Hi there, have you tried http://127.0.0.1:8080 instead? That is the IP usually bound to localhost and it might be that localhost is not resolved correctly to same. If not, try to provide further info. For example, have you installed Tomcat in a path containing spaces such as c:\Program Files\Tomcat. If so, reinstall to a path without spaces. Cheers, Jan -Original Message- From: D. Gilbert [mailto:[EMAIL PROTECTED] Sent: Saturday, December 06, 2003 4:56 PM To: Tomcat Users List Subject: newbie help please, localhost not found When I type http://localhost:8080 in Internet Explorer it says The page cannot be displayed. I've looked through the archives but couldn't find anything. The running.txt file that comes with Tomcat lists only 3 possibilites for why it doesn't work. I've tried changing the port number, I'm using Windows XP so the environment issue doesn't apply and I'm pretty sure that I'm not behind a proxy as I am using my own PC at home. I'm pretty sure the JDK is installed ok as I can run javac. I tried changing JAVA_HOME and CATALINA_HOME to incorrect values and that made things worse so I'm sure they are set correctly. I've tried 2 versions of Tomcat 4.0.1 and 4.1.29. When I startup 4.0.1 I get the messages Starting service Tomcat-Standalone Apache Tomcat/4.0.1 Starting service Tomcat-Apache Apache Tomcat/4.0.1 which are correct according to my book. Can anyone say what the problem is, or any ways to debug it? It should run on a standalone home PC shouldn't it? I don't need to be connected to a LAN or anything do I? I've been trying to solve this for 2 weeks now so I would really appreciate any help please. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat5 close to production?
Philip Busby wrote: Is there any word, or any place where I could check the status of Tomcat5 to move to production? My host would rather not go through with a Tomcat5 install until it comes out of beta, but I like all of the new things in JSP2. Will Tomcat5 be going production within a month or two or four or eight? Tomcat 5.0.16 is STABLE version (read: non-beta, non-alpha = GOLD). There will be bugs, those bugs will be removed in future releases, but such is life. For the time being, if Tomcat is your choice of production environment, then 5.0.16 is a production version. Nix. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Antwort: Re: JAASRealm Tomcat 5.x - Tomcat 4.1.x
Ah OK. I am using JAASRealm too but I wrote my own implementation of LoginModule. I think JAASMemoryLoginModule.java is merely a demo class to show how it is done in the simplest way. Adam On 12/05/2003 04:24 PM Oliver Wulff wrote: I saw the following note in JAASMemoryLoginModule.java: // Validate the username and password we have received principal = null; // FIXME - look up and check password That's why I thought that it is not finished yet. Oliver On 12/04/2003 07:00 PM Oliver Wulff wrote: AFAIK, the JAASRealm in Tomcat 4.1.29 is a beta version. Is the JAASRealm in Tomcat 5.x for production? If yes, can I use the JAASRealm of Tomcat 5.x in Tomcat 4.1.29? Hi Oliver, where does it say that JAASRealm is beta? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE : Tomcat-4.1.24 Hangs
Do you have something like: waiting for xx instances to be deallocated in the log file ? Tareq ABED RABBO DSI/IS Transverse Orascom Telecom Tunisie (Tunisiana) Tel. +216 22 12 18 46 Fax. +216 71 806 909 Email : [EMAIL PROTECTED] -Message d'origine- De : Ryan Lissack [mailto:[EMAIL PROTECTED] Envoyé : lundi 8 décembre 2003 09:59 À : 'Tomcat Users List' Objet : RE: Tomcat-4.1.24 Hangs Hi, Probably has to do with NPTL in RedHat 9. Try setting the following environment variable: LD_ASSUME_KERNEL=2.4.1 That should stop the hanging. Search the list for further details. Ryan -Original Message- From: Zsolt Koppany [mailto:[EMAIL PROTECTED] Sent: 07 December 2003 17:30 To: Tomcat Users List Subject: Tomcat-4.1.24 Hangs Hi, after two days my tomcat-4.1.24 hangs. I cannot connect to the server not even with telnet localhost 8080. The Process (JVM) is not big, it is approx 100Mb. Any ideas why? TC is running under RedHat-9.0 with Sun Jre-1.4.2_02. Zsolt - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Installing Manager tool
Hi, I installed Tomcat 4.1 to test the Manager interface. I followed the manual step (add a user in the tomcat-users.xml file, add context ...). I use the default port and when I enter http://localhost:8080/manager, I get a 404 error (reported by tomcat). I saw in the list archive the same trouble, but no solution was found :-( May I be more lucky ? Thanks a lot !
RE: Installing Manager tool
Did you set the privileged=true attribute in the context definition? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 2:44 AM To: [EMAIL PROTECTED] Subject: Installing Manager tool Hi, I installed Tomcat 4.1 to test the Manager interface. I followed the manual step (add a user in the tomcat-users.xml file, add context ...). I use the default port and when I enter http://localhost:8080/manager, I get a 404 error (reported by tomcat). I saw in the list archive the same trouble, but no solution was found :-( May I be more lucky ? Thanks a lot ! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat-4.1.24 Hangs
Hi Ryan, thank you. What is NPTL? Zsolt -Original Message- From: Ryan Lissack [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 9:59 AM To: 'Tomcat Users List' Subject: RE: Tomcat-4.1.24 Hangs Hi, Probably has to do with NPTL in RedHat 9. Try setting the following environment variable: LD_ASSUME_KERNEL=2.4.1 That should stop the hanging. Search the list for further details. Ryan -Original Message- From: Zsolt Koppany [mailto:[EMAIL PROTECTED] Sent: 07 December 2003 17:30 To: Tomcat Users List Subject: Tomcat-4.1.24 Hangs Hi, after two days my tomcat-4.1.24 hangs. I cannot connect to the server not even with telnet localhost 8080. The Process (JVM) is not big, it is approx 100Mb. Any ideas why? TC is running under RedHat-9.0 with Sun Jre-1.4.2_02. Zsolt - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat-4.1.24 Hangs
Hi Zsolt, It stands for Native POSIX Threading Library, it is a new form of threading introduced in RedHat with version 9.0 There is a complete description with links to other information in a previous thread. If I remember correctly the subject was Tomcat jitters then hangs, search the list archives for further information. Regards Ryan -Original Message- From: Zsolt Koppany [mailto:[EMAIL PROTECTED] Sent: 08 December 2003 09:51 To: Tomcat Users List Subject: RE: Tomcat-4.1.24 Hangs Hi Ryan, thank you. What is NPTL? Zsolt -Original Message- From: Ryan Lissack [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 9:59 AM To: 'Tomcat Users List' Subject: RE: Tomcat-4.1.24 Hangs Hi, Probably has to do with NPTL in RedHat 9. Try setting the following environment variable: LD_ASSUME_KERNEL=2.4.1 That should stop the hanging. Search the list for further details. Ryan -Original Message- From: Zsolt Koppany [mailto:[EMAIL PROTECTED] Sent: 07 December 2003 17:30 To: Tomcat Users List Subject: Tomcat-4.1.24 Hangs Hi, after two days my tomcat-4.1.24 hangs. I cannot connect to the server not even with telnet localhost 8080. The Process (JVM) is not big, it is approx 100Mb. Any ideas why? TC is running under RedHat-9.0 with Sun Jre-1.4.2_02. Zsolt - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Problem in rtexprvalue-attributes with taglibs in Tomcat 5.0.16
String typed rtexprvalue-taglib-attributes worked well with tomcat 4.1xx. Running same taglibs with tomcat 5.0.16 gives an error like org.apache.jasper.JasperException: /ksite/index.jsp(91,4) Unknown attribute type (String) for attribute lan. Is there any workaround to this Thanks in advance, -George-
Cookies.
Hi All, Im working with Tomcat5.0. I have problem in working with cookies. My requirement is to save the user login info in browser cookie so that for next time login will make easier for user to avoid entering again, like usual login in other system. So, I have added the cookies value in servlet, and I can get the cookie value in jsp. When I work with the same browser fine working. But when close and open the new browser window I cant get the cookie values. Setting cookie, res.addCookie(new Cookie(entID,eID)); res.addCookie(new Cookie(lgnId,lgnId)); After setting dispatching request and respond to the JSP page. Cookie[] cookies=request.getCookies(); for (int i=0; icookies.length; i++) { hm.put(cookies[i].getName(), cookies[i].getValue()); } -- this is how i get the value in same browser. When browse this jsp in new browser getting fail to retrieve.. Can you help me to solve this issue. Thanks. Wahab. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat command line console
Hello, We have used few tomcat instances in our production environment. Since number of our Tomcats grew, we are looking for better approach to manage it. Especially we are looking for something like - lets say - command line tomcat console - something simillar to manager webapp, but as a regular command line application (since we use ssh, and some of tomcats are hidden behind firewalls we can't use GUIs), rather than deployed manager webapp. We found a bit insecure to run tomcat manager in an production environment, but, of course, it would be great to get a manager's functionality anyway. Unfortunatelly I haven't seen something usable yet. Maybe someone has seen something like this? Sugestions would be greatly appreciated. regards, Artur -- Artur Karazniewicz - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat5 close to production?
I highly recommend everyone to subscribe to the announcement list. [EMAIL PROTECTED] -Tim Philip Busby wrote: Is there any word, or any place where I could check the status of Tomcat5 to move to production? My host would rather not go through with a Tomcat5 install until it comes out of beta, but I like all of the new things in JSP2. Will Tomcat5 be going production within a month or two or four or eight? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Enforce no cache
Write a filter that adds all the no-cacheing headers. (Google) (Or to be lazy, use ssl - since I think cacheing is not allowed in ssl) -Tim Jerald Powel wrote: Hello, How do I enforce no caching for a particular context under TC? Sites/doco welcome G. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [OT] Some questions on Java,Servlet, JSP and Tomcat.
[inline] Antony Paul wrote: 1, Is there any security threat for Tomcat 4.1 series. I am using Tomcat 4.1.27 for development. What is the history of Tomcat in this regard. Is Tomcat vulnerable to any remote exploitation issues provided that the application is well written. I want to collect some arguments to favour Java and Tomcat. None that anyone is aware of. 2, Any documentation on how servlet container is creating multiple instances of same HttpServlet without implementing Runnable interface. At least provide some links to docs or books which teaches threading issues in servlet. It is only for a curiousity. I am only an application developer. I want to improve my knowledge in servlet technology. See the Servlet spec. I can't recommend any books. 3, How to test a servlet for threading issues. 3, Is there anything wrong in implementing logic in service method in a class which extends HttpServlet. What will happen if a doHead and other requests are send to it. How to simulate a doHead,doTrace etc.. request ?. I got some info at http://www.jguru.com/faq/view.jsp?EID=8824 You are supposed to extend HttpServlet, then implement doHead(...), doGet(...) or appropriate. If a method is not implemented, an NOT IMPLEMENTED should get returned. 4, Is it possible to synchronise a block of code in a servlet. I mean only one thread of the same servlet execute the same portion of code at a time and completes execution. I dont want to implement SingleThreadModel and there is only one name in web.xml pointing to same servlet class. I have an idea. Is this right. Create a synchronised block which synchronised on the class. synchronized(AlertServlet.class){ --- } My purpose is to synchronize database access. The application dont have a heavy load. Yes - but this may cause bad side effects. For concurrent programming, many like Doug Lea's books. 5, Is it secure to transfer a request and response to another object which is created in the service method of a servlet ?. I believe it is a safe approach. I think Struts is doing this. Secure - sure. Wise - depends. (On too many variables based on the writeup) If using some MVC models, like struts, turbine, - then all is OK. 6, I have seen that Tomcat not shutting down the threads which are active when shut down command is issued. I used to kill Tomcat in such conditions. Does Tomcat will ever kill this threads if they are not completed execution. What criteria is used in such cases. Tomcat is a JVM process. Like any JVM, it only terminates when only daemon threads are running. 7, In Tomcat 4.0.x series there is one file catalina.out which prints the number of active Httpprocessor active(I think it is number of threads) ut it is not found in 4.1 series. Is there any way to get this log file in 4.1. I also want to writing to this log mailed to me when the no. of HttpProcessors exceeds a limit without tweaking Tomcat code. This may be in the catalina_XXX files. Not sure about this one. -Tim - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Database pool problem
Of course he has a choice, download MySQL in development machine and he will make his tests. This i´d choose. -- De: Dan Johnsson[SMTP:[EMAIL PROTECTED] Responder:Tomcat Users List Enviada: sexta-feira, 5 de dezembro de 2003 20:46 Para: Tomcat Users List Assunto: Re: Database pool problem I understand that you do not have a choice, but please not that the JDBC-ODBC bridge is *not for production* [according to Sun], it is *solely* for development and evaluation. The bridge contains identified bugs that will not be addressed [i e support is EOLed]. So, you are using this at your own risk. Check out the bug parade of the bridge; you might have encountered a well-known, documented bug. It that case, there might be a published work-around. Otherwise: I am sorry to say that you are out in the wilderness alone. Dan Johnsson, System Architect and Security Consultant Chaikin, Yaakov Y (US SSA) wrote: Hi, I am having the following problem and how someone can point out to me what I am doing wrong. I am trying to configure Tomcat to have a database connection pool for my database, but when I try to access the database through a jsp, it gives me wrong password for the database... BUT it IS the right password. I am using MS Access as the database (not much choice right now) and have set up a System DNS. The weird part is that I am using the same values for a Realm I defined and I know that it DOES create a connection to the database and authentication works. The Realm that I have is this: Realm className=org.apache.catalina.realm.JDBCRealm connectionName=default connectionPassword=afecrelease2003 connectionURL=jdbc:odbc:afec debug=0 driverName=sun.jdbc.odbc.JdbcOdbcDriver roleNameCol=UserRole userCredCol=UserPassword userNameCol=UserName userRoleTable=TestUsers userTable=TestUsers validate=true/ My server.xml file has this context: !--*** BEGIN AFECWEB Context ***-- Context className=org.apache.catalina.core.StandardContext cachingAllowed=true charsetMapperClass=org.apache.catalina.util.CharsetMapper cookies=true crossContext=true debug=0 displayName=AFECWEB docBase=c:/corej2ee/stage/wls/afecWebApp/afecWEB.war mapperClass=org.apache.catalina.core.StandardContextMapper path=/afecWEB privileged=false reloadable=true swallowOutput=false useNaming=true wrapperClass=org.apache.catalina.core.StandardWrapper Logger className=org.apache.catalina.logger.FileLogger debug=0 directory=logs prefix=localhost_afecWEB_log. suffix=.txt timestamp=true verbosity=99/ Resource name=jdbc/afecWEBDB auth=Container description=AFEC database; stores info about documents, login type=javax.sql.DataSource scope=Shareable / ResourceParams name=jdbc/afecWEBDB parameter namefactory/name valueorg.apache.commons.dbcp.BasicDataSourceFactory/value /parameter parameter namemaxActive/name value1/value /parameter parameter namemaxIdle/name value1/value /parameter parameter namemaxWait/name value1/value /parameter parameter namedriverClassName/name valuesun.jdbc.odbc.JdbcOdbcDriver/value /parameter parameter nameurl/name valuejdbc:odbc:afec/value /parameter parameter nameuser/name valuedefault/value /parameter parameter namepassword/name valueafecrelease2003/value /parameter parameter nameconnectionName/name valuedefault/value /parameter parameter nameconnectionPassword/name valueafecrelease2003/value /parameter parameter nameconnectionURL/name valuejdbc:odbc:afec/value /parameter parameter namedriverName/name valuesun.jdbc.odbc.JdbcOdbcDriver/value /parameter /ResourceParams /Context !--*** END AFECWEB Context ***-- Any help would be greatly appreciated. Thanks. Yaakov Chaikin Software Engineer BAE SYSTEMS 301-838-6899 (phone) 301-838-6802 (fax) [EMAIL PROTECTED] - To unsubscribe, e-mail:
RE: Database pool problem
Why not go the extra mile and get a database that supports cutting edge features like views? PostgreSQL -Original Message- From: Edson Alves Pereira [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 6:06 AM To: 'Tomcat Users List' Subject: RE: Database pool problem Of course he has a choice, download MySQL in development machine and he will make his tests. This i´d choose. -- De: Dan Johnsson[SMTP:[EMAIL PROTECTED] Responder:Tomcat Users List Enviada: sexta-feira, 5 de dezembro de 2003 20:46 Para: Tomcat Users List Assunto: Re: Database pool problem I understand that you do not have a choice, but please not that the JDBC-ODBC bridge is *not for production* [according to Sun], it is *solely* for development and evaluation. The bridge contains identified bugs that will not be addressed [i e support is EOLed]. So, you are using this at your own risk. Check out the bug parade of the bridge; you might have encountered a well-known, documented bug. It that case, there might be a published work-around. Otherwise: I am sorry to say that you are out in the wilderness alone. Dan Johnsson, System Architect and Security Consultant Chaikin, Yaakov Y (US SSA) wrote: Hi, I am having the following problem and how someone can point out to me what I am doing wrong. I am trying to configure Tomcat to have a database connection pool for my database, but when I try to access the database through a jsp, it gives me wrong password for the database... BUT it IS the right password. I am using MS Access as the database (not much choice right now) and have set up a System DNS. The weird part is that I am using the same values for a Realm I defined and I know that it DOES create a connection to the database and authentication works. The Realm that I have is this: Realm className=org.apache.catalina.realm.JDBCRealm connectionName=default connectionPassword=afecrelease2003 connectionURL=jdbc:odbc:afec debug=0 driverName=sun.jdbc.odbc.JdbcOdbcDriver roleNameCol=UserRole userCredCol=UserPassword userNameCol=UserName userRoleTable=TestUsers userTable=TestUsers validate=true/ My server.xml file has this context: !--*** BEGIN AFECWEB Context ***-- Context className=org.apache.catalina.core.StandardContext cachingAllowed=true charsetMapperClass=org.apache.catalina.util.CharsetMapper cookies=true crossContext=true debug=0 displayName=AFECWEB docBase=c:/corej2ee/stage/wls/afecWebApp/afecWEB.war mapperClass=org.apache.catalina.core.StandardContextMapper path=/afecWEB privileged=false reloadable=true swallowOutput=false useNaming=true wrapperClass=org.apache.catalina.core.StandardWrapper Logger className=org.apache.catalina.logger.FileLogger debug=0 directory=logs prefix=localhost_afecWEB_log. suffix=.txt timestamp=true verbosity=99/ Resource name=jdbc/afecWEBDB auth=Container description=AFEC database; stores info about documents, login type=javax.sql.DataSource scope=Shareable / ResourceParams name=jdbc/afecWEBDB parameter namefactory/name valueorg.apache.commons.dbcp.BasicDataSourceFactory/value /parameter parameter namemaxActive/name value1/value /parameter parameter namemaxIdle/name value1/value /parameter parameter namemaxWait/name value1/value /parameter parameter namedriverClassName/name valuesun.jdbc.odbc.JdbcOdbcDriver/value /parameter parameter nameurl/name valuejdbc:odbc:afec/value /parameter parameter nameuser/name valuedefault/value /parameter parameter namepassword/name valueafecrelease2003/value /parameter parameter nameconnectionName/name valuedefault/value /parameter parameter nameconnectionPassword/name valueafecrelease2003/value /parameter parameter nameconnectionURL/name valuejdbc:odbc:afec/value /parameter parameter namedriverName/name valuesun.jdbc.odbc.JdbcOdbcDriver/value /parameter /ResourceParams /Context !--*** END AFECWEB Context
connection refused, localhost not found
Hi Listers I'm sceptical whether anybody else has ever suffered this bizarre problem so I'm not expecting anybody to be able to help, but this is seriously damaging my enjoyment of Monday morning. I have tomcat 5.0.14 set up on one computer and it works fine mostly, i.e. root context, JSP examples, manager apps are working fine. The problem is with the app I'm developing. On Friday night last week I did loads of debugging to sort out the JNDI connection pool, e.g. configuring the app context, the web.xml etc. Now when I try to call up http://localhost:8080/myapp/ the browser zooms off to find http://www.localhost.net.au! When I try http://127.0.0.1:8080/myapp/ I get a 'connection refused' pop-up from the browsers - on my machine and on others. (root context still works as I said). Obviously I tried restarting tomcat, redeploying the app, taking out all the filters, changing the context name, checked server.xml. Anybody care to take a wild guess about what I need to do? Tx Adam - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: connection refused, localhost not found
Well, I got this problem with MLDonkey (not really java, I know but hey.. :P) This simply means your program crashes on startup and that nothing listens on port 8080. Now.. dunno what browser you use but I had this with Mozilla. I tried to connect to http://localhost:4080/ it didnt find anything on that port so it went on with resolving random/known by mozilla things, till it found localhost.net.au which actually is an existing page. Motto of this story is: your app is not running or not on port 8080 :-) Patrick Ale System administrator Freeler B.V Muda o mundo, começe com você mesmo -Oorspronkelijk bericht- Van: Adam Hardy [mailto:[EMAIL PROTECTED] Verzonden: maandag 8 december 2003 13:29 Aan: Tomcat Users List Onderwerp: connection refused, localhost not found Hi Listers I'm sceptical whether anybody else has ever suffered this bizarre problem so I'm not expecting anybody to be able to help, but this is seriously damaging my enjoyment of Monday morning. I have tomcat 5.0.14 set up on one computer and it works fine mostly, i.e. root context, JSP examples, manager apps are working fine. The problem is with the app I'm developing. On Friday night last week I did loads of debugging to sort out the JNDI connection pool, e.g. configuring the app context, the web.xml etc. Now when I try to call up http://localhost:8080/myapp/ the browser zooms off to find http://www.localhost.net.au! When I try http://127.0.0.1:8080/myapp/ I get a 'connection refused' pop-up from the browsers - on my machine and on others. (root context still works as I said). Obviously I tried restarting tomcat, redeploying the app, taking out all the filters, changing the context name, checked server.xml. Anybody care to take a wild guess about what I need to do? Tx Adam - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: connection refused, localhost not found
The app is not running, yup, guess I can't argue with that. Unfortunately it's not logging any exceptions. I see that tomcat starts a session for the context, and it logs the request in localhost_access_log, but otherwise, it's dead as a dodo. It's definitely on 8080 - the other contexts are obviously on 8080 and still run fine. On 12/08/2003 01:41 PM Patrick Ale wrote: Well, I got this problem with MLDonkey (not really java, I know but hey.. :P) This simply means your program crashes on startup and that nothing listens on port 8080. Now.. dunno what browser you use but I had this with Mozilla. I tried to connect to http://localhost:4080/ it didnt find anything on that port so it went on with resolving random/known by mozilla things, till it found localhost.net.au which actually is an existing page. Motto of this story is: your app is not running or not on port 8080 :-) Patrick Ale System administrator Freeler B.V Muda o mundo, começe com você mesmo -Oorspronkelijk bericht- Van: Adam Hardy [mailto:[EMAIL PROTECTED] Verzonden: maandag 8 december 2003 13:29 Aan: Tomcat Users List Onderwerp: connection refused, localhost not found Hi Listers I'm sceptical whether anybody else has ever suffered this bizarre problem so I'm not expecting anybody to be able to help, but this is seriously damaging my enjoyment of Monday morning. I have tomcat 5.0.14 set up on one computer and it works fine mostly, i.e. root context, JSP examples, manager apps are working fine. The problem is with the app I'm developing. On Friday night last week I did loads of debugging to sort out the JNDI connection pool, e.g. configuring the app context, the web.xml etc. Now when I try to call up http://localhost:8080/myapp/ the browser zooms off to find http://www.localhost.net.au! When I try http://127.0.0.1:8080/myapp/ I get a 'connection refused' pop-up from the browsers - on my machine and on others. (root context still works as I said). Obviously I tried restarting tomcat, redeploying the app, taking out all the filters, changing the context name, checked server.xml. Anybody care to take a wild guess about what I need to do? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: connection refused, localhost not found
what happens when you do: telnet localhost 8080 GET /myapp/ HTTP/1.1enter host: localhostenter enter enter Patrick Ale System administrator Freeler B.V Email: [EMAIL PROTECTED] Tel.: +31 320 267678 Muda o mundo, começe com você mesmo -Oorspronkelijk bericht- Van: Adam Hardy [mailto:[EMAIL PROTECTED] Verzonden: maandag 8 december 2003 14:16 Aan: Tomcat Users List Onderwerp: Re: connection refused, localhost not found The app is not running, yup, guess I can't argue with that. Unfortunately it's not logging any exceptions. I see that tomcat starts a session for the context, and it logs the request in localhost_access_log, but otherwise, it's dead as a dodo. It's definitely on 8080 - the other contexts are obviously on 8080 and still run fine. On 12/08/2003 01:41 PM Patrick Ale wrote: Well, I got this problem with MLDonkey (not really java, I know but hey.. :P) This simply means your program crashes on startup and that nothing listens on port 8080. Now.. dunno what browser you use but I had this with Mozilla. I tried to connect to http://localhost:4080/ it didnt find anything on that port so it went on with resolving random/known by mozilla things, till it found localhost.net.au which actually is an existing page. Motto of this story is: your app is not running or not on port 8080 :-) Patrick Ale System administrator Freeler B.V Muda o mundo, começe com você mesmo -Oorspronkelijk bericht- Van: Adam Hardy [mailto:[EMAIL PROTECTED] Verzonden: maandag 8 december 2003 13:29 Aan: Tomcat Users List Onderwerp: connection refused, localhost not found Hi Listers I'm sceptical whether anybody else has ever suffered this bizarre problem so I'm not expecting anybody to be able to help, but this is seriously damaging my enjoyment of Monday morning. I have tomcat 5.0.14 set up on one computer and it works fine mostly, i.e. root context, JSP examples, manager apps are working fine. The problem is with the app I'm developing. On Friday night last week I did loads of debugging to sort out the JNDI connection pool, e.g. configuring the app context, the web.xml etc. Now when I try to call up http://localhost:8080/myapp/ the browser zooms off to find http://www.localhost.net.au! When I try http://127.0.0.1:8080/myapp/ I get a 'connection refused' pop-up from the browsers - on my machine and on others. (root context still works as I said). Obviously I tried restarting tomcat, redeploying the app, taking out all the filters, changing the context name, checked server.xml. Anybody care to take a wild guess about what I need to do? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: connection refused, localhost not found
I changed the web.xml and have now managed to get tomcat to generate a status 404. This is also what comes thro to telnet. Strange because the context appears in tomcat manager as running, with sessions. I'm thinking about upgrading to 5.0.16 on this machine but I wanted to solve this problem before tackling the upgrade. On 12/08/2003 02:19 PM Patrick Ale wrote: what happens when you do: telnet localhost 8080 GET /myapp/ HTTP/1.1enter host: localhostenter enter enter Patrick Ale System administrator Freeler B.V Email: [EMAIL PROTECTED] Tel.: +31 320 267678 Muda o mundo, começe com você mesmo -Oorspronkelijk bericht- Van: Adam Hardy [mailto:[EMAIL PROTECTED] Verzonden: maandag 8 december 2003 14:16 Aan: Tomcat Users List Onderwerp: Re: connection refused, localhost not found The app is not running, yup, guess I can't argue with that. Unfortunately it's not logging any exceptions. I see that tomcat starts a session for the context, and it logs the request in localhost_access_log, but otherwise, it's dead as a dodo. It's definitely on 8080 - the other contexts are obviously on 8080 and still run fine. On 12/08/2003 01:41 PM Patrick Ale wrote: Well, I got this problem with MLDonkey (not really java, I know but hey.. :P) This simply means your program crashes on startup and that nothing listens on port 8080. Now.. dunno what browser you use but I had this with Mozilla. I tried to connect to http://localhost:4080/ it didnt find anything on that port so it went on with resolving random/known by mozilla things, till it found localhost.net.au which actually is an existing page. Motto of this story is: your app is not running or not on port 8080 :-) Patrick Ale System administrator Freeler B.V Muda o mundo, começe com você mesmo -Oorspronkelijk bericht- Van: Adam Hardy [mailto:[EMAIL PROTECTED] Verzonden: maandag 8 december 2003 13:29 Aan: Tomcat Users List Onderwerp: connection refused, localhost not found Hi Listers I'm sceptical whether anybody else has ever suffered this bizarre problem so I'm not expecting anybody to be able to help, but this is seriously damaging my enjoyment of Monday morning. I have tomcat 5.0.14 set up on one computer and it works fine mostly, i.e. root context, JSP examples, manager apps are working fine. The problem is with the app I'm developing. On Friday night last week I did loads of debugging to sort out the JNDI connection pool, e.g. configuring the app context, the web.xml etc. Now when I try to call up http://localhost:8080/myapp/ the browser zooms off to find http://www.localhost.net.au! When I try http://127.0.0.1:8080/myapp/ I get a 'connection refused' pop-up from the browsers - on my machine and on others. (root context still works as I said). Obviously I tried restarting tomcat, redeploying the app, taking out all the filters, changing the context name, checked server.xml. Anybody care to take a wild guess about what I need to do? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: connection refused, localhost not found
Now when I try to call up http://localhost:8080/myapp/ the browser zooms off to find http://www.localhost.net.au! When I try http://127.0.0.1:8080/myapp/ I get a 'connection refused' pop-up from the browsers - on my machine and on others. (root context still works as I said). My instant reaction was - start tomcat. Then I read: Obviously I tried restarting tomcat, redeploying the app, taking out all the filters, changing the context name, checked server.xml. I had this when I was developing. I closed tomcat but because I had Lynx open I assumed that the dos window was the tomcat instance. Took me about 10 minutes to figure my error. I wonder how many hits that guy gets due to the localhost error? Hope he pays by the megabyte because that is a big page to serve up:-) G. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: connection refused, localhost not found
On 12/08/2003 02:41 PM Graham Reeds wrote: Obviously I tried restarting tomcat, redeploying the app, taking out all the filters, changing the context name, checked server.xml. I had this when I was developing. I closed tomcat but because I had Lynx open I assumed that the dos window was the tomcat instance. Took me about 10 minutes to figure my error. I wonder how many hits that guy gets due to the localhost error? Hope he pays by the megabyte because that is a big page to serve up:-) Cheesy internet marketing rubbish - guess he reckons the traffic will someday turn into dollars! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[OT] Quality of open source code - not a survey.
Hi, I am not questioning quality of opens source projects. My intention is to learn from looking at the source code of open source projects. I want to know whether it is good to learn from looking at the source code of this kind of projects. I want to develop best coding practices and know how things work and how to implement it. To learn it, the cheap way available to me is looking at code written by some experts. I believe people who wrote Tomcat,JSTL and other have godd knowledge of Java. Is there anything wrong in doing such things ? rgds Antony Paul. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: connection refused, localhost not found
Oops, sorry being a plonker. Had the ports in my config for the sslext (ssl redirect) module set up for the production box to 80 443 instead of 8080 8443 for development. Sorry for the waste of time bandwidth! On 12/08/2003 02:32 PM Adam Hardy wrote: I changed the web.xml and have now managed to get tomcat to generate a status 404. This is also what comes thro to telnet. Strange because the context appears in tomcat manager as running, with sessions. I'm thinking about upgrading to 5.0.16 on this machine but I wanted to solve this problem before tackling the upgrade. On 12/08/2003 02:19 PM Patrick Ale wrote: what happens when you do: telnet localhost 8080 GET /myapp/ HTTP/1.1enter host: localhostenter enter enter Patrick Ale System administrator Freeler B.V Email: [EMAIL PROTECTED] Tel.: +31 320 267678 Muda o mundo, começe com você mesmo -Oorspronkelijk bericht- Van: Adam Hardy [mailto:[EMAIL PROTECTED] Verzonden: maandag 8 december 2003 14:16 Aan: Tomcat Users List Onderwerp: Re: connection refused, localhost not found The app is not running, yup, guess I can't argue with that. Unfortunately it's not logging any exceptions. I see that tomcat starts a session for the context, and it logs the request in localhost_access_log, but otherwise, it's dead as a dodo. It's definitely on 8080 - the other contexts are obviously on 8080 and still run fine. On 12/08/2003 01:41 PM Patrick Ale wrote: Well, I got this problem with MLDonkey (not really java, I know but hey.. :P) This simply means your program crashes on startup and that nothing listens on port 8080. Now.. dunno what browser you use but I had this with Mozilla. I tried to connect to http://localhost:4080/ it didnt find anything on that port so it went on with resolving random/known by mozilla things, till it found localhost.net.au which actually is an existing page. Motto of this story is: your app is not running or not on port 8080 :-) Patrick Ale System administrator Freeler B.V Muda o mundo, começe com você mesmo -Oorspronkelijk bericht- Van: Adam Hardy [mailto:[EMAIL PROTECTED] Verzonden: maandag 8 december 2003 13:29 Aan: Tomcat Users List Onderwerp: connection refused, localhost not found Hi Listers I'm sceptical whether anybody else has ever suffered this bizarre problem so I'm not expecting anybody to be able to help, but this is seriously damaging my enjoyment of Monday morning. I have tomcat 5.0.14 set up on one computer and it works fine mostly, i.e. root context, JSP examples, manager apps are working fine. The problem is with the app I'm developing. On Friday night last week I did loads of debugging to sort out the JNDI connection pool, e.g. configuring the app context, the web.xml etc. Now when I try to call up http://localhost:8080/myapp/ the browser zooms off to find http://www.localhost.net.au! When I try http://127.0.0.1:8080/myapp/ I get a 'connection refused' pop-up from the browsers - on my machine and on others. (root context still works as I said). Obviously I tried restarting tomcat, redeploying the app, taking out all the filters, changing the context name, checked server.xml. Anybody care to take a wild guess about what I need to do? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: connection refused, localhost not found
It's my boss' bandwith, who's carring? :P And atleast noone has to worry about our friend localhost.net.au anymore when it appears ;-) Patrick Ale System administrator Freeler B.V Email: [EMAIL PROTECTED] Tel.: +31 320 267678 Muda o mundo, começe com você mesmo -Oorspronkelijk bericht- Van: Adam Hardy [mailto:[EMAIL PROTECTED] Verzonden: maandag 8 december 2003 15:39 Aan: Tomcat Users List Onderwerp: Re: connection refused, localhost not found Oops, sorry being a plonker. Had the ports in my config for the sslext (ssl redirect) module set up for the production box to 80 443 instead of 8080 8443 for development. Sorry for the waste of time bandwidth! On 12/08/2003 02:32 PM Adam Hardy wrote: I changed the web.xml and have now managed to get tomcat to generate a status 404. This is also what comes thro to telnet. Strange because the context appears in tomcat manager as running, with sessions. I'm thinking about upgrading to 5.0.16 on this machine but I wanted to solve this problem before tackling the upgrade. On 12/08/2003 02:19 PM Patrick Ale wrote: what happens when you do: telnet localhost 8080 GET /myapp/ HTTP/1.1enter host: localhostenter enter enter Patrick Ale System administrator Freeler B.V Email: [EMAIL PROTECTED] Tel.: +31 320 267678 Muda o mundo, começe com você mesmo -Oorspronkelijk bericht- Van: Adam Hardy [mailto:[EMAIL PROTECTED] Verzonden: maandag 8 december 2003 14:16 Aan: Tomcat Users List Onderwerp: Re: connection refused, localhost not found The app is not running, yup, guess I can't argue with that. Unfortunately it's not logging any exceptions. I see that tomcat starts a session for the context, and it logs the request in localhost_access_log, but otherwise, it's dead as a dodo. It's definitely on 8080 - the other contexts are obviously on 8080 and still run fine. On 12/08/2003 01:41 PM Patrick Ale wrote: Well, I got this problem with MLDonkey (not really java, I know but hey.. :P) This simply means your program crashes on startup and that nothing listens on port 8080. Now.. dunno what browser you use but I had this with Mozilla. I tried to connect to http://localhost:4080/ it didnt find anything on that port so it went on with resolving random/known by mozilla things, till it found localhost.net.au which actually is an existing page. Motto of this story is: your app is not running or not on port 8080 :-) Patrick Ale System administrator Freeler B.V Muda o mundo, começe com você mesmo -Oorspronkelijk bericht- Van: Adam Hardy [mailto:[EMAIL PROTECTED] Verzonden: maandag 8 december 2003 13:29 Aan: Tomcat Users List Onderwerp: connection refused, localhost not found Hi Listers I'm sceptical whether anybody else has ever suffered this bizarre problem so I'm not expecting anybody to be able to help, but this is seriously damaging my enjoyment of Monday morning. I have tomcat 5.0.14 set up on one computer and it works fine mostly, i.e. root context, JSP examples, manager apps are working fine. The problem is with the app I'm developing. On Friday night last week I did loads of debugging to sort out the JNDI connection pool, e.g. configuring the app context, the web.xml etc. Now when I try to call up http://localhost:8080/myapp/ the browser zooms off to find http://www.localhost.net.au! When I try http://127.0.0.1:8080/myapp/ I get a 'connection refused' pop-up from the browsers - on my machine and on others. (root context still works as I said). Obviously I tried restarting tomcat, redeploying the app, taking out all the filters, changing the context name, checked server.xml. Anybody care to take a wild guess about what I need to do? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [OT] Quality of open source code - not a survey.
I don't think that looking at code will help you to develop a sense of best practices. There are books written on the subject that will help much more than attempting to glean such information from code. Especially since code is the end-product of the practices, not the other way around. Justin -Original Message- From: Antony Paul [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 9:39 AM To: Tomcat Users List Subject: [OT] Quality of open source code - not a survey. Hi, I am not questioning quality of opens source projects. My intention is to learn from looking at the source code of open source projects. I want to know whether it is good to learn from looking at the source code of this kind of projects. I want to develop best coding practices and know how things work and how to implement it. To learn it, the cheap way available to me is looking at code written by some experts. I believe people who wrote Tomcat,JSTL and other have godd knowledge of Java. Is there anything wrong in doing such things ? rgds Antony Paul. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [OT] Quality of open source code - not a survey.
From a style point of view - tomcat is not very strict on style. Thats not saying that the style is bad, but we concentrate on code quality, not programming style. But if a patch has bad programming style, hindering the code readability and intent, then someone will complain. So in a nutshell, tomcat committers makes every attempt to ensure the code is readable, but its style may not be consistent. IIRC, the projects which are most strict with respect to style is Maven and Avalon related projects. -Tim Antony Paul wrote: Hi, I am not questioning quality of opens source projects. My intention is to learn from looking at the source code of open source projects. I want to know whether it is good to learn from looking at the source code of this kind of projects. I want to develop best coding practices and know how things work and how to implement it. To learn it, the cheap way available to me is looking at code written by some experts. I believe people who wrote Tomcat,JSTL and other have godd knowledge of Java. Is there anything wrong in doing such things ? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
updated Tomcat ISAPI filter available
This is the isapi_redirector2.dll built from the latest source snapshot as of Dec 8, 2003. As usual, I have no environment in which to test this, so I can not vouch for the functionality or stability, or verify the effectiveness of any bug fixes in the latest source. http://web.bvu.edu/staff/david/index.jsp?section=softwaresubsection=isapipage=overview
RE: [OT] Quality of open source code - not a survey.
Howdy, I would caution you to look at the code of small, focused projects first. It's easier to keep to best practices and consistent style in smaller projects. Tomcat does a whole lot, has many features, lots of pluggable entities, so the design would appear overly complex to anyone not aware of the many nuances. That said, tomcat code is excellent IMHO. Yoav Shapira Millennium ChemInformatics -Original Message- From: Tim Funk [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 9:55 AM To: Tomcat Users List Subject: Re: [OT] Quality of open source code - not a survey. From a style point of view - tomcat is not very strict on style. Thats not saying that the style is bad, but we concentrate on code quality, not programming style. But if a patch has bad programming style, hindering the code readability and intent, then someone will complain. So in a nutshell, tomcat committers makes every attempt to ensure the code is readable, but its style may not be consistent. IIRC, the projects which are most strict with respect to style is Maven and Avalon related projects. -Tim Antony Paul wrote: Hi, I am not questioning quality of opens source projects. My intention is to learn from looking at the source code of open source projects. I want to know whether it is good to learn from looking at the source code of this kind of projects. I want to develop best coding practices and know how things work and how to implement it. To learn it, the cheap way available to me is looking at code written by some experts. I believe people who wrote Tomcat,JSTL and other have godd knowledge of Java. Is there anything wrong in doing such things ? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [OT] Writing methods in servlets
Howdy, There's nothing wrong with methods in servlets per se. A servlet is just another class in Java. Yoav Shapira Millennium ChemInformatics -Original Message- From: Antony Paul [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 1:13 AM To: Tomcat Users List Subject: [OT] Writing methods in servlets Hi all, Is there any issues associated with writing methods in servlets other than the morality of it( I dont use methods in JSP pages). My application uses controller servlets for redirecting requests to different pages based on the parameter(action) passed to it. Application is designed in a way that it will have one controller servlet for a group of actions on same entity. Earlier I used to check the action in if else blocks. Now the servlet is becoming cluttered with lots of if else blocks. So I want to move this to methods and I must do it in Servlets itself (The application design dont allow to move this to another class). I know that container creates multiple threads of servlce method of (I dont know how) same servlet to service multiple requests. Then what about other custom methods in servlets. I dont use any instance variables. rgds Antony Paul. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat command line console
Howdy, You can use the ant tasks that connect to the manager webapp in conjunction with a filter/valve to deny non-localhost requests to the manager webapp. What did you find insecure about the manager webapp? Yoav Shapira Millennium ChemInformatics -Original Message- From: Artur Karazniewicz [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 6:38 AM To: [EMAIL PROTECTED] Subject: Tomcat command line console Hello, We have used few tomcat instances in our production environment. Since number of our Tomcats grew, we are looking for better approach to manage it. Especially we are looking for something like - lets say - command line tomcat console - something simillar to manager webapp, but as a regular command line application (since we use ssh, and some of tomcats are hidden behind firewalls we can't use GUIs), rather than deployed manager webapp. We found a bit insecure to run tomcat manager in an production environment, but, of course, it would be great to get a manager's functionality anyway. Unfortunatelly I haven't seen something usable yet. Maybe someone has seen something like this? Sugestions would be greatly appreciated. regards, Artur -- Artur Karazniewicz - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Cookies.
Abdul, So, I have added the cookies value in servlet, and I can get the cookie value in jsp. When I work with the same browser fine working. But when close and open the new browser window I cant get the cookie values. Setting cookie, res.addCookie(new Cookie(entID,eID)); res.addCookie(new Cookie(lgnId,lgnId)); I checked the javadoc documentation for the Cookie class, and it doesn't seem to mention the default life of a Cookie object once sent to the browser. I'm inclined to think that the default is that it will live as long as the browser session does (especially because of your evidence). Try this: Cookie cookie = new Cookie(entId, eID); cookie.setMaxAge(cookie_life_in_seconds); res.addCookie(cookie); cookie = new Cookie(ognId, ignId); cookies.setMaxAge(cookie_life_in_seconds); res.addCookie(cookie); This is likely to extend the life of your cookies beyond the browser's session. Therefore, they will be sent in requests after the browser is restarted. -chris - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Lock on database file not being released...
Hi, I did as you said and adjusted those values for the odbc. Same result. The database file is still showing as locked. Yaakov Chaikin Software Engineer BAE SYSTEMS 301-838-6899 (phone) 301-838-6802 (fax) [EMAIL PROTECTED] -Original Message- From: George Sexton [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 1:11 AM To: 'Tomcat Users List' Subject: RE: Lock on database file not being released... In the ODBC connection entry in the registry, or by using the ODBC Connection editor, change those two parameters. They are probably set for Yes and should be set to No. If you are not using an ODBC Connection entry, then you need to pass these as arguments in the connection string. -Original Message- From: Chaikin, Yaakov Y (US SSA) [mailto:[EMAIL PROTECTED] Sent: Sunday, December 07, 2003 11:07 PM To: Tomcat Users List Subject: RE: Lock on database file not being released... How do I do that in server.xml file? Is that what you are suggesting? Specifying other parameters for the connection pooling? Please elaborate on what you think I should do. Thanks. Yaakov Chaikin Software Engineer BAE SYSTEMS 301-838-6899 (phone) 301-838-6802 (fax) [EMAIL PROTECTED] -Original Message- From: George Sexton [mailto:[EMAIL PROTECTED] Sent: Sunday, December 07, 2003 11:28 PM To: 'Tomcat Users List' Subject: RE: Lock on database file not being released... OK, I now think I know the issue. Try changing the entries for the ODBC connection. Specifically change: ImplicitCommitSync And UserCommitSync The docs are inconsistent on their usage, and I think the drivers vary depending upon the version of the Jet engine you are using. Anyhow, adjust these and see what happens. -Original Message- From: Chaikin, Yaakov Y (US SSA) [mailto:[EMAIL PROTECTED] Sent: Sunday, December 07, 2003 2:13 PM To: Tomcat Users List Subject: RE: Lock on database file not being released... However, I have used this driver before in a standalone app and when you close a connection, it certainly does release the lock on the database file. This makes me think, you didn't use pooling in this standalone app. Therefor check weather you close all your ResultSets and Statements. In standalone apps where no pooling is involved, they are caught by the garbage collector, but not in connection pooling. Trapped into this myself. Steffen, I tried what you said and closed the ResultSet and Statement before I close the Connection. Still same affect. Any other ideas anyone? I highly doubt it's the driver. I would bet that I am doing something wrong. I just can't figure out what it is. Thanks, Yaakov. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
More sophisticated JDBCRealm Security
In looking through the docs I am surpised that I dont see a way to do some more sophisticated JDBCRealm security. I may just be looking in the wrong place or misreading something so please let me know if I am. My DB tables are arranged as follows create table user ( id BIGINT NOT NULL AUTO_INCREMENT, email VARCHAR(100) not null unique, groupId BIGINT not null, password VARCHAR(20) not null, active BIT, primary key (id) ); create table groups ( id BIGINT NOT NULL AUTO_INCREMENT, role VARCHAR(255) not null, primary key (id) ); The email address is the user login, password is obvious. I would want something that would only let ACTIVE users log in (active = 1), and User.groupId maps to Groups.id field. Using the standard JDBCRealm I do not see how this is possible. Would I actually have to create my own custom Realm implementation in order to achieve these goals? Thanks for any input/advice, Frank - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: More sophisticated JDBCRealm Security
Howdy, The typical solution in many cases involving JDBCRealm is (if you don't want to customize the realm by coding) to create a view for use by the JDBC realm. In your case, you'd create a view on the user table where only active users are shown, and configure the JDBC realm to query this view rather than the user table. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM To: Tomcat Users List Subject: More sophisticated JDBCRealm Security In looking through the docs I am surpised that I dont see a way to do some more sophisticated JDBCRealm security. I may just be looking in the wrong place or misreading something so please let me know if I am. My DB tables are arranged as follows create table user ( id BIGINT NOT NULL AUTO_INCREMENT, email VARCHAR(100) not null unique, groupId BIGINT not null, password VARCHAR(20) not null, active BIT, primary key (id) ); create table groups ( id BIGINT NOT NULL AUTO_INCREMENT, role VARCHAR(255) not null, primary key (id) ); The email address is the user login, password is obvious. I would want something that would only let ACTIVE users log in (active = 1), and User.groupId maps to Groups.id field. Using the standard JDBCRealm I do not see how this is possible. Would I actually have to create my own custom Realm implementation in order to achieve these goals? Thanks for any input/advice, Frank - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Cookies.
I checked the javadoc documentation for the Cookie class, and it doesn't seem to mention the default life of a Cookie object once sent to the browser. I'm inclined to think that the default is that it will live as long as the browser session does (especially because of your evidence). It is. I've been implementing cookies in my app. Try this: Cookie cookie = new Cookie(entId, eID); cookie.setMaxAge(cookie_life_in_seconds); res.addCookie(cookie); cookie = new Cookie(ognId, ignId); cookies.setMaxAge(cookie_life_in_seconds); res.addCookie(cookie); This is likely to extend the life of your cookies beyond the browser's session. Therefore, they will be sent in requests after the browser is restarted. [OT] Personally I think that being able to have a single name=value attribute in a cookie is a bad idea. I can't find anywhere that explains the reason for this. Anyway to get around this I have been looking at formatting my cookie as: name=lang:en;usr:grahamr;pswrd:fud; and deencode the result afterwards. Then you don't have to mess around with lots of cookies. G. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[OT] Rad Game Tools
Does anyone else get a message from [EMAIL PROTECTED] asking them to update their email address? Everytime I email this list I get one back. G. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
directive.include problem
Hello, I'm getting a weird error when using jsp:directive.include file=.. /. I get an jsp.error.badaction error. I don't know maybe I'm using the the directive incorrectly. What I am trying to do is make my JSPs cleaner by moving some of the header and footer code onto a different file. Since I use the same header and footer code, I thought that I could use the directive.include element. But no luck. Any help? -- _ Atreya Basu Developer, Greenfield Research Inc. e-mail: atreya (at) greenfieldresearch (dot) ca - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: More sophisticated JDBCRealm Security
What about the fact that the groupId column in User is called id in the Groups table, would it be a case of making another view to accomplish that translation too? Besides craeting views, which is easy, what are the other options here? - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, The typical solution in many cases involving JDBCRealm is (if you don't want to customize the realm by coding) to create a view for use by the JDBC realm. In your case, you'd create a view on the user table where only active users are shown, and configure the JDBC realm to query this view rather than the user table. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM To: Tomcat Users List Subject: More sophisticated JDBCRealm Security In looking through the docs I am surpised that I dont see a way to do some more sophisticated JDBCRealm security. I may just be looking in the wrong place or misreading something so please let me know if I am. My DB tables are arranged as follows create table user ( id BIGINT NOT NULL AUTO_INCREMENT, email VARCHAR(100) not null unique, groupId BIGINT not null, password VARCHAR(20) not null, active BIT, primary key (id) ); create table groups ( id BIGINT NOT NULL AUTO_INCREMENT, role VARCHAR(255) not null, primary key (id) ); The email address is the user login, password is obvious. I would want something that would only let ACTIVE users log in (active = 1), and User.groupId maps to Groups.id field. Using the standard JDBCRealm I do not see how this is possible. Would I actually have to create my own custom Realm implementation in order to achieve these goals? Thanks for any input/advice, Frank - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[OT}RE: directive.include problem
Try: %@ include file=... % Michele From: Atreya Basu [EMAIL PROTECTED] Reply-To: Tomcat Users List [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Subject: directive.include problem Date: Mon, 08 Dec 2003 12:24:06 -0400 Hello, I'm getting a weird error when using jsp:directive.include file=.. /. I get an jsp.error.badaction error. I don't know maybe I'm using the the directive incorrectly. What I am trying to do is make my JSPs cleaner by moving some of the header and footer code onto a different file. Since I use the same header and footer code, I thought that I could use the directive.include element. But no luck. Any help? -- _ Atreya Basu Developer, Greenfield Research Inc. e-mail: atreya (at) greenfieldresearch (dot) ca - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Cell phone switch rules are taking effect find out more here. http://special.msn.com/msnbc/consumeradvocate.armx - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
SSL problem with TC 5.0.16
Hi, before you start throwing eggs and tomatoes at me: I *have* searched the mailing list archive before posting this message... ;-) I just installed Tomcat 5.0.16. Now we want to migrate an application from TC 4.0.6 to it. For this we need to run TC with SSL. However, there's apparently a mistake in our SSL configuration. After adapting server.xml for our webapp, we see the following startup error message: snip INFO: Starting Coyote HTTP/1.1 on port 8080 08.12.2003 17:01:45 org.apache.coyote.http11.Http11Protocol start SCHWERWIEGEND: Error starting endpoint java.io.IOException: Keystore was tampered with, or password was incorrect at sun.security.provider.JavaKeyStore.engineLoad(JavaKeyStore.java:748) at java.security.KeyStore.load(KeyStore.java:652) at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getStore(JSSESocket Factory.java:295) at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeystore(JSSESoc ketFactory.java:259) at org.apache.tomcat.util.net.jsse.JSSE14SocketFactory.getKeyManagers(JS SE14SocketFactory.java:172) /snip Following the docs, we checked the password and we have also created quite a few new keystores and put there paths into the keystoreFile attribute of the Factory tag. In TC5 even the old keystore with the original certificate of our application is rejected. Has anybody seen this before? Can you provide some hint, what the problem could be caused by? We can rule out the things mentioned in the docs, I think! Thanks in advance! Regards Alex - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: More sophisticated JDBCRealm Security
Howdy, Your other option is to extend JDBCRealm into your own custom realm implementation. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:41 AM To: Tomcat Users List Subject: Re: More sophisticated JDBCRealm Security What about the fact that the groupId column in User is called id in the Groups table, would it be a case of making another view to accomplish that translation too? Besides craeting views, which is easy, what are the other options here? - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, The typical solution in many cases involving JDBCRealm is (if you don't want to customize the realm by coding) to create a view for use by the JDBC realm. In your case, you'd create a view on the user table where only active users are shown, and configure the JDBC realm to query this view rather than the user table. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM To: Tomcat Users List Subject: More sophisticated JDBCRealm Security In looking through the docs I am surpised that I dont see a way to do some more sophisticated JDBCRealm security. I may just be looking in the wrong place or misreading something so please let me know if I am. My DB tables are arranged as follows create table user ( id BIGINT NOT NULL AUTO_INCREMENT, email VARCHAR(100) not null unique, groupId BIGINT not null, password VARCHAR(20) not null, active BIT, primary key (id) ); create table groups ( id BIGINT NOT NULL AUTO_INCREMENT, role VARCHAR(255) not null, primary key (id) ); The email address is the user login, password is obvious. I would want something that would only let ACTIVE users log in (active = 1), and User.groupId maps to Groups.id field. Using the standard JDBCRealm I do not see how this is possible. Would I actually have to create my own custom Realm implementation in order to achieve these goals? Thanks for any input/advice, Frank - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: SSL problem with TC 5.0.16
Did you set keystorePass? -Original Message- From: Baer Peter Christoph Alexander [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:49 AM To: '[EMAIL PROTECTED]' Subject: SSL problem with TC 5.0.16 Hi, before you start throwing eggs and tomatoes at me: I *have* searched the mailing list archive before posting this message... ;-) I just installed Tomcat 5.0.16. Now we want to migrate an application from TC 4.0.6 to it. For this we need to run TC with SSL. However, there's apparently a mistake in our SSL configuration. After adapting server.xml for our webapp, we see the following startup error message: snip INFO: Starting Coyote HTTP/1.1 on port 8080 08.12.2003 17:01:45 org.apache.coyote.http11.Http11Protocol start SCHWERWIEGEND: Error starting endpoint java.io.IOException: Keystore was tampered with, or password was incorrect at sun.security.provider.JavaKeyStore.engineLoad(JavaKeyStore.java:748) at java.security.KeyStore.load(KeyStore.java:652) at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getStore(JSSESocket Factory.java:295) at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeystore(JSSESoc ketFactory.java:259) at org.apache.tomcat.util.net.jsse.JSSE14SocketFactory.getKeyManagers(JS SE14SocketFactory.java:172) /snip Following the docs, we checked the password and we have also created quite a few new keystores and put there paths into the keystoreFile attribute of the Factory tag. In TC5 even the old keystore with the original certificate of our application is rejected. Has anybody seen this before? Can you provide some hint, what the problem could be caused by? We can rule out the things mentioned in the docs, I think! Thanks in advance! Regards Alex - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [OT}RE: directive.include problem
The only problem with the include directive is that it actually outputs the result of a jsp rather than just the text. What I want to do is have some content in a another file, have the two file put together then compiled. Is there a way to do that I wonder? Michele Emmi wrote: Try: %@ include file=... % Michele From: Atreya Basu [EMAIL PROTECTED] Reply-To: Tomcat Users List [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Subject: directive.include problem Date: Mon, 08 Dec 2003 12:24:06 -0400 Hello, I'm getting a weird error when using jsp:directive.include file=.. /. I get an jsp.error.badaction error. I don't know maybe I'm using the the directive incorrectly. What I am trying to do is make my JSPs cleaner by moving some of the header and footer code onto a different file. Since I use the same header and footer code, I thought that I could use the directive.include element. But no luck. Any help? -- _ Atreya Basu Developer, Greenfield Research Inc. e-mail: atreya (at) greenfieldresearch (dot) ca - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Cell phone switch rules are taking effect find out more here. http://special.msn.com/msnbc/consumeradvocate.armx - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- _ Atreya Basu Developer, Greenfield Research Inc. e-mail: atreya (at) greenfieldresearch (dot) ca - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: connection refused, localhost not found
I took out the welcome-file config in web.xml and now I just get a plain status 404. But the tomcat manager shows the context is started and has a session after I try to access it. On 12/08/2003 02:32 PM Adam Hardy wrote: I changed the web.xml and have now managed to get tomcat to generate a status 404. This is also what comes thro to telnet. Strange because the context appears in tomcat manager as running, with sessions. I'm thinking about upgrading to 5.0.16 on this machine but I wanted to solve this problem before tackling the upgrade. On 12/08/2003 02:19 PM Patrick Ale wrote: what happens when you do: telnet localhost 8080 GET /myapp/ HTTP/1.1enter host: localhostenter enter enter Patrick Ale System administrator Freeler B.V Email: [EMAIL PROTECTED] Tel.: +31 320 267678 Muda o mundo, começe com você mesmo -Oorspronkelijk bericht- Van: Adam Hardy [mailto:[EMAIL PROTECTED] Verzonden: maandag 8 december 2003 14:16 Aan: Tomcat Users List Onderwerp: Re: connection refused, localhost not found The app is not running, yup, guess I can't argue with that. Unfortunately it's not logging any exceptions. I see that tomcat starts a session for the context, and it logs the request in localhost_access_log, but otherwise, it's dead as a dodo. It's definitely on 8080 - the other contexts are obviously on 8080 and still run fine. On 12/08/2003 01:41 PM Patrick Ale wrote: Well, I got this problem with MLDonkey (not really java, I know but hey.. :P) This simply means your program crashes on startup and that nothing listens on port 8080. Now.. dunno what browser you use but I had this with Mozilla. I tried to connect to http://localhost:4080/ it didnt find anything on that port so it went on with resolving random/known by mozilla things, till it found localhost.net.au which actually is an existing page. Motto of this story is: your app is not running or not on port 8080 :-) Patrick Ale System administrator Freeler B.V Muda o mundo, começe com você mesmo -Oorspronkelijk bericht- Van: Adam Hardy [mailto:[EMAIL PROTECTED] Verzonden: maandag 8 december 2003 13:29 Aan: Tomcat Users List Onderwerp: connection refused, localhost not found Hi Listers I'm sceptical whether anybody else has ever suffered this bizarre problem so I'm not expecting anybody to be able to help, but this is seriously damaging my enjoyment of Monday morning. I have tomcat 5.0.14 set up on one computer and it works fine mostly, i.e. root context, JSP examples, manager apps are working fine. The problem is with the app I'm developing. On Friday night last week I did loads of debugging to sort out the JNDI connection pool, e.g. configuring the app context, the web.xml etc. Now when I try to call up http://localhost:8080/myapp/ the browser zooms off to find http://www.localhost.net.au! When I try http://127.0.0.1:8080/myapp/ I get a 'connection refused' pop-up from the browsers - on my machine and on others. (root context still works as I said). Obviously I tried restarting tomcat, redeploying the app, taking out all the filters, changing the context name, checked server.xml. Anybody care to take a wild guess about what I need to do? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Differences between jServ and Tomcat
jServ is just a servlet engine (JSDK 2.0). Tomcat is a servlet engine (JSDK 2.2/2.3/2.4), a jsp engine and a webserver and contains much more additional functionality (DB Connection Pool, Realms, Manager, ) -Original Message- From: Jan Behrens [mailto:[EMAIL PROTECTED] Sent: Saturday, December 06, 2003 12:37 PM To: 'Tomcat Users List' Subject: Differences between jServ and Tomcat Hi List, I wonder whether anyone out there could give me some insight on the main differences between jServ and Tomcat. As far as I understand, jServ is a Servlet Engine to be included with an instance of Apache, whereas Tomcat of course can be used as a Standalone Server doing more than just handling jsp/servlet requests from a webserver. Is that about right? Any comments or good links on the matter would be highly appreciated. Cheers, Jan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Urgent: referencing external jar files from a jar in WEB-INF/lib
Hello, I just posted a very similar question some time ago, but got no answer until now. see http://marc.theaimsgroup.com/?l=tomcat-userm=106337028016813w=2 I use Tomcat 4.1.27. My question was, if Tomcat ClassLoaders can evaluate the CLASS-PATH attribute set in the manifest of a jar file, to reference external jar files. In the meantime I saw that the common class loader (and also server and shared) can interprete the CLASS-PATH variable of the Manifest file of a jar file. Unfortunately it seems not to work if I put a jar file, that references an external jar file by means of the CLASS-PATH variable in the Manifest, in the WEB-INF/lib of my WAR file. Should this be possible, or not ? Are there any other methods (do I use the wrong one)? As I understood the servlet spec 2.3 chapter 9.7.1 it should be possible by means of the CLASS-PATH attribute: Snippet from the servlet spec 2.3 chapter 9.7.1 WebContainers should be able to recognize declared dependencies expressed in the manifest entry of any of the library JARs under the WEB-INF/lib entry in a WAR So the question is very urgent to me. Please help me. Cheers Karin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [OT}RE: directive.include problem
erm. shouldn't it be: jsp:include page=.../ as per section JSP.4.4 of the JSP 1.2 specification. HTH, Jon Atreya Basu wrote: The only problem with the include directive is that it actually outputs the result of a jsp rather than just the text. What I want to do is have some content in a another file, have the two file put together then compiled. Is there a way to do that I wonder? Michele Emmi wrote: Try: %@ include file=... % Michele From: Atreya Basu [EMAIL PROTECTED] Reply-To: Tomcat Users List [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Subject: directive.include problem Date: Mon, 08 Dec 2003 12:24:06 -0400 Hello, I'm getting a weird error when using jsp:directive.include file=.. /. I get an jsp.error.badaction error. I don't know maybe I'm using the the directive incorrectly. What I am trying to do is make my JSPs cleaner by moving some of the header and footer code onto a different file. Since I use the same header and footer code, I thought that I could use the directive.include element. But no luck. Any help? -- _ Atreya Basu Developer, Greenfield Research Inc. e-mail: atreya (at) greenfieldresearch (dot) ca - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: More sophisticated JDBCRealm Security
Well crap! Turns out we are using MySQL 4.0.x which does not have support for views. Can anyone point me in a direction that would help me in implementing my own Realm (either brand new or by extending another) Thank you very much, Frank - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:49 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, Your other option is to extend JDBCRealm into your own custom realm implementation. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:41 AM To: Tomcat Users List Subject: Re: More sophisticated JDBCRealm Security What about the fact that the groupId column in User is called id in the Groups table, would it be a case of making another view to accomplish that translation too? Besides craeting views, which is easy, what are the other options here? - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, The typical solution in many cases involving JDBCRealm is (if you don't want to customize the realm by coding) to create a view for use by the JDBC realm. In your case, you'd create a view on the user table where only active users are shown, and configure the JDBC realm to query this view rather than the user table. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM To: Tomcat Users List Subject: More sophisticated JDBCRealm Security In looking through the docs I am surpised that I dont see a way to do some more sophisticated JDBCRealm security. I may just be looking in the wrong place or misreading something so please let me know if I am. My DB tables are arranged as follows create table user ( id BIGINT NOT NULL AUTO_INCREMENT, email VARCHAR(100) not null unique, groupId BIGINT not null, password VARCHAR(20) not null, active BIT, primary key (id) ); create table groups ( id BIGINT NOT NULL AUTO_INCREMENT, role VARCHAR(255) not null, primary key (id) ); The email address is the user login, password is obvious. I would want something that would only let ACTIVE users log in (active = 1), and User.groupId maps to Groups.id field. Using the standard JDBCRealm I do not see how this is possible. Would I actually have to create my own custom Realm implementation in order to achieve these goals? Thanks for any input/advice, Frank - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: SSL problem with TC 5.0.16
Yes, we set keystorePass to what we entered when creating the keystore. Below are the Connectors from our server.xml. Do you see anything wrong, here? Something, that was ok with TC 4.0.6, but is no longer valid for TC 5.0.16? Thanks in advance! Alex snip Connector acceptCount=100 connectionTimeout=3 debug=0 disableUploadTimeout=true enableLookups=true maxSpareThreads=75 maxThreads=150 minSpareThreads=25 port=8080 redirectPort=8443 scheme=https secure=yes / !-- Define a SSL Coyote HTTP/1.1 Connector on port 8443 -- Connector acceptCount=100 debug=0 disableUploadTimeout=true enableLookups=false maxSpareThreads=75 maxThreads=150 minSpareThreads=25 port=8443 scheme=https secure=true Factory clientAuth=false keystoreFile=D:\ourwebapp\certificate\keystore keystorePass=yeahsure protocol=TLS / /Connector !-- Define a Coyote/JK2 AJP 1.3 Connector on port 8009 -- Connector debug=0 enableLookups=false port=8009 protocol=AJP/1.3 redirectPort=8443 / /snip -Original Message- From: Luc Foisy [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 5:53 PM To: Tomcat Users List Subject: RE: SSL problem with TC 5.0.16 Did you set keystorePass? -Original Message- From: Baer Peter Christoph Alexander [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:49 AM To: '[EMAIL PROTECTED]' Subject: SSL problem with TC 5.0.16 Hi, before you start throwing eggs and tomatoes at me: I *have* searched the mailing list archive before posting this message... ;-) I just installed Tomcat 5.0.16. Now we want to migrate an application from TC 4.0.6 to it. For this we need to run TC with SSL. However, there's apparently a mistake in our SSL configuration. After adapting server.xml for our webapp, we see the following startup error message: snip INFO: Starting Coyote HTTP/1.1 on port 8080 08.12.2003 17:01:45 org.apache.coyote.http11.Http11Protocol start SCHWERWIEGEND: Error starting endpoint java.io.IOException: Keystore was tampered with, or password was incorrect at sun.security.provider.JavaKeyStore.engineLoad(JavaKeyStore.java:748) at java.security.KeyStore.load(KeyStore.java:652) at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getStore(JSSESocket Factory.java:295) at org.apache.tomcat.util.net.jsse.JSSESocketFactory.getKeystore(JSSESoc ketFactory.java:259) at org.apache.tomcat.util.net.jsse.JSSE14SocketFactory.getKeyManagers(JS SE14SocketFactory.java:172) /snip Following the docs, we checked the password and we have also created quite a few new keystores and put there paths into the keystoreFile attribute of the Factory tag. In TC5 even the old keystore with the original certificate of our application is rejected. Has anybody seen this before? Can you provide some hint, what the problem could be caused by? We can rule out the things mentioned in the docs, I think! Thanks in advance! Regards Alex - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: More sophisticated JDBCRealm Security
Since your making a view to only be used by tomcat, there is no problem. You can change column names when creating a view. Additionally, if you want more security, make your group and user views locked to a tomcat id (sql login that is). Then tomcat itself is locked out of other changes or looks into your sql database. -Tim Frank Febbraro wrote: What about the fact that the groupId column in User is called id in the Groups table, would it be a case of making another view to accomplish that translation too? Besides craeting views, which is easy, what are the other options here? - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, The typical solution in many cases involving JDBCRealm is (if you don't want to customize the realm by coding) to create a view for use by the JDBC realm. In your case, you'd create a view on the user table where only active users are shown, and configure the JDBC realm to query this view rather than the user table. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM To: Tomcat Users List Subject: More sophisticated JDBCRealm Security In looking through the docs I am surpised that I dont see a way to do some more sophisticated JDBCRealm security. I may just be looking in the wrong place or misreading something so please let me know if I am. My DB tables are arranged as follows create table user ( id BIGINT NOT NULL AUTO_INCREMENT, email VARCHAR(100) not null unique, groupId BIGINT not null, password VARCHAR(20) not null, active BIT, primary key (id) ); create table groups ( id BIGINT NOT NULL AUTO_INCREMENT, role VARCHAR(255) not null, primary key (id) ); The email address is the user login, password is obvious. I would want something that would only let ACTIVE users log in (active = 1), and User.groupId maps to Groups.id field. Using the standard JDBCRealm I do not see how this is possible. Would I actually have to create my own custom Realm implementation in order to achieve these goals? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [OT}RE: directive.include problem
Oops. Note to self: must read JSP2.0 spec ;) (specifically JSP.6.2.4) Jon Wingfield wrote: erm. shouldn't it be: jsp:include page=.../ as per section JSP.4.4 of the JSP 1.2 specification. HTH, Jon Atreya Basu wrote: The only problem with the include directive is that it actually outputs the result of a jsp rather than just the text. What I want to do is have some content in a another file, have the two file put together then compiled. Is there a way to do that I wonder? Michele Emmi wrote: Try: %@ include file=... % Michele From: Atreya Basu [EMAIL PROTECTED] Reply-To: Tomcat Users List [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Subject: directive.include problem Date: Mon, 08 Dec 2003 12:24:06 -0400 Hello, I'm getting a weird error when using jsp:directive.include file=.. /. I get an jsp.error.badaction error. I don't know maybe I'm using the the directive incorrectly. What I am trying to do is make my JSPs cleaner by moving some of the header and footer code onto a different file. Since I use the same header and footer code, I thought that I could use the directive.include element. But no luck. Any help? -- _ Atreya Basu Developer, Greenfield Research Inc. e-mail: atreya (at) greenfieldresearch (dot) ca - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: More sophisticated JDBCRealm Security
Easiest alternative: Cron and a sql script. lock user and group table truncate user and group table insert into user and group tables with query unlock -Tim Frank Febbraro wrote: Well crap! Turns out we are using MySQL 4.0.x which does not have support for views. Can anyone point me in a direction that would help me in implementing my own Realm (either brand new or by extending another) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Urgent! Tomcat4 closed giving Out of Memory Error
Look at the open files - it is 9182. That IS already pretty high, but you may be hitting that limit since in Unix, everything is a file. Sockets, etc. On Linux, is there a way in the JVM to tell the difference between memory given to the new generation, old generation, and permanent generation in the JVM? There were users on this list posting weird OutOfMemory errors last week that were doing class reloading, and the permanent generation was filling up even though there was plenty of space in the old and new gen. Of course, I think these comments only apply to a 1.4.x JVM. Does your code do funky stuff with the classloaders, or are you reloading your application in Tomcat's manager? (or changing web.xml, which would cause reloads??) Have you profiled your application to find any memory leaks? [EMAIL PROTECTED] 12/6/03 11:45:27 AM I am using Linux2.4.20-smp. I think the limits for the entire system are not problem: cat /proc/sys/kernel/threads-max 14336 cat /proc/sys/fs/file-max 209708 cat /proc/sys/fs/file-nr 22311366209708 ulimit -a core file size(blocks, -c) 0 data seg size (kbytes, -d) unlimited file size (blocks, -f) unlimited max locked memory (kbytes, -l) unlimited max memory size (kbytes, -m) unlimited open files(-n) 9182 pipe size (512 bytes, -p) 8 stack size(kbytes, -s) 8192 cpu time (seconds, -t) unlimited max user processes(-u) 7168 virtual memory(kbytes, -v) unlimited But I can't find where the limits for each process/user are. One message found from google said PTHREAD_THREADS_MAX could be the max thread count per process. In my /usr/include/bits/local_lim.h, I have /* The number of threads per process. */ #define _POSIX_THREAD_THREADS_MAX 64 /* This is the value this implementation supports. */ #define PTHREAD_THREADS_MAX 16384 16384 is large enough, I believe. Then what could be the reason of the error? By the way, the Out of Memory error didn't appear all the time. Sometimes there was just no response without any error message. Do you know where I can get more detailed bug files? Thank you very much. Qi On Sat, 6 Dec 2003, Tim Funk wrote: When you get java.lang.OutOfMemoryError: unable to create new native thread it means you are running into an operating system limit. You can give the JVM 1 Exabyte of memory and you'll still get this error. Look at the kernel parameters for your machine and the following limits: 1) Threads allowable on the system 2) Threads run by a user 3) Threads run by a process 4) File handles per process 5) File handles per user Use your OS manual or Google to tweak these parameters. http://jakarta.apache.org/tomcat/faq/memory.html#why -Tim qi zhang wrote: Hi, I have stunk on this problem for almost 2 weeks. :-( In these two weeks, I have tried many methods, but it still doesn't work. I built a system to run TPCW benchmark. One web and application server, with tomcat4.0 running, one database with mysql4.0 running on it and several client machines. The Jave version is j2sdk1.4.0_03. The system worked perfect under light load. But when the number of clients exceeded some number (like 600), the tomcat4 didn't work anymore. I checked catalina.out. Sometimes no error message appear, while in some time it appeared the error: SEVERE: Caught exception executing [EMAIL PROTECTED], terminating thread java.lang.OutOfMemoryError: unable to create new native thread at java.lang.Thread.start(Native Method) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.init(ThreadPool.java:497) at - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Qi Zhang, Ph.D Student Department of Computer Science, College of William and Mary P.O. Box 8795 Williamsburg, VA 23187-8795 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Jeff Tulley ([EMAIL PROTECTED]) (801)861-5322 Novell, Inc., The Leading Provider of Net Business Solutions http://www.novell.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [OT}RE: directive.include problem
On Mon, 2003-12-08 at 11:53, Atreya Basu wrote: The only problem with the include directive is that it actually outputs the result of a jsp rather than just the text. What I want to do is have some content in a another file, have the two file put together then compiled. I don't think this is true. The jsp:include action tag acts as you describe above, outputing its results during the request proccessing phase. http://java.sun.com/products/jsp/tags/syntaxref.fm11.html The %@ include directive includes the contents of the file before compilation. http://java.sun.com/products/jsp/tags/syntaxref.fm6.html#8772 dave Is there a way to do that I wonder? Michele Emmi wrote: Try: %@ include file=... % Michele From: Atreya Basu [EMAIL PROTECTED] Reply-To: Tomcat Users List [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Subject: directive.include problem Date: Mon, 08 Dec 2003 12:24:06 -0400 Hello, I'm getting a weird error when using jsp:directive.include file=.. /. I get an jsp.error.badaction error. I don't know maybe I'm using the the directive incorrectly. What I am trying to do is make my JSPs cleaner by moving some of the header and footer code onto a different file. Since I use the same header and footer code, I thought that I could use the directive.include element. But no luck. Any help? -- _ Atreya Basu Developer, Greenfield Research Inc. e-mail: atreya (at) greenfieldresearch (dot) ca - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Cell phone switch rules are taking effect find out more here. http://special.msn.com/msnbc/consumeradvocate.armx - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- _ Atreya Basu Developer, Greenfield Research Inc. e-mail: atreya (at) greenfieldresearch (dot) ca - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat5.0.16 not reading request attributes from mod_jk
Hi, I have a problem getting request attributes (like SSL information and additional CGI variables) in Tomcat5.0.16 connected to Apache using mod_jk/1.2.5 It seems to be some problem with the new Coyote/JK2 AJP 1.3 connector, because it works in Tomcat4.1.29. Please help. Here are the details: I have it working with Tomcat4.1.29, after some experiments I figured out that in Apache's httpd.conf, I have to set JkMount /myapp/* myworker JkEnvVar SSL_CLIENT_S_DN none Location /myapp/* SSLOptions +ExportCertData +StdEnvVars /Location so that mod_jk extracts the SSL-related information from CGI variables, adds value of CGI variable specified by the JkEnvVar directive and sends the information to TomCat. In Tomcat4.1.29's server.xml I can use both prepared connectors !-- Define a Coyote/JK2 AJP 1.3 Connector on port 8009 -- Connector className=org.apache.coyote.tomcat4.CoyoteConnector port=8009 minProcessors=5 maxProcessors=75 enableLookups=true redirectPort=8443 acceptCount=10 debug=0 connectionTimeout=0 useURIValidationHack=false protocolHandlerClassName=org.apache.jk.server.JkCoyoteHandler/ !-- Define an AJP 1.3 Connector on port 8009 -- Connector className=org.apache.ajp.tomcat4.Ajp13Connector port=8010 minProcessors=5 maxProcessors=75 acceptCount=10 debug=0/ to get the information as request attributes, but the older Ajp13Connector is better, because it gets also the SSL_CLIENT_S_DN value, but JkCoyoteHandler does not, it gets only the SSL attributes. But in Tomcat5.0.16, with exactly the same Apache setup and the standard Coyote connector in server.xml: !-- Define a Coyote/JK2 AJP 1.3 Connector on port 8009 -- Connector port=8009 enableLookups=false redirectPort=8443 debug=0 protocol=AJP/1.3 / it sets no request attributes at all ! Is it a bug in Tomcat5.0.16's Coyote connector or is something wrong with my configuration ? Martin -- ~~ Supercomputing Center Brno Martin Kuba Institute of Computer Scienceemail: [EMAIL PROTECTED] Masaryk University http://www.ics.muni.cz/~makub/ Botanicka 68a, 60200 Brno, CZ mobil: +420-603-533775 -- smime.p7s Description: S/MIME Cryptographic Signature
Re: [OT}RE: directive.include problem
That's right. The XML equivalent for %@ include is directive.include page= /. That's what I am having difficulty with. Anyone with experience using the above directive? Atreya David Evans wrote: The %@ include directive includes the contents of the file before compilation. http://java.sun.com/products/jsp/tags/syntaxref.fm6.html#8772 dave -- _ Atreya Basu Developer, Greenfield Research Inc. e-mail: atreya (at) greenfieldresearch (dot) ca - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat5.0.16 not reading request attributes from mod_jk
Martin Kuba wrote: Hi, I have a problem getting request attributes (like SSL information and additional CGI variables) in Tomcat5.0.16 connected to Apache using mod_jk/1.2.5 It seems to be some problem with the new Coyote/JK2 AJP 1.3 connector, because it works in Tomcat4.1.29. Please help. I don't know about your problem, but most of the connector code is identical with TC 4.1.29 (in particular, the JK implementation is the same). The code in CoyoteRequest.getAttribute from TC 5 seems fine, when compared to the code from TC 4.1. Here are the details: I have it working with Tomcat4.1.29, after some experiments I figured out that in Apache's httpd.conf, I have to set JkMount /myapp/* myworker JkEnvVar SSL_CLIENT_S_DN none Location /myapp/* SSLOptions +ExportCertData +StdEnvVars /Location so that mod_jk extracts the SSL-related information from CGI variables, adds value of CGI variable specified by the JkEnvVar directive and sends the information to TomCat. In Tomcat4.1.29's server.xml I can use both prepared connectors !-- Define a Coyote/JK2 AJP 1.3 Connector on port 8009 -- Connector className=org.apache.coyote.tomcat4.CoyoteConnector port=8009 minProcessors=5 maxProcessors=75 enableLookups=true redirectPort=8443 acceptCount=10 debug=0 connectionTimeout=0 useURIValidationHack=false protocolHandlerClassName=org.apache.jk.server.JkCoyoteHandler/ !-- Define an AJP 1.3 Connector on port 8009 -- Connector className=org.apache.ajp.tomcat4.Ajp13Connector port=8010 minProcessors=5 maxProcessors=75 acceptCount=10 debug=0/ to get the information as request attributes, but the older Ajp13Connector is better, because it gets also the SSL_CLIENT_S_DN value, but JkCoyoteHandler does not, it gets only the SSL attributes. But in Tomcat5.0.16, with exactly the same Apache setup and the standard Coyote connector in server.xml: !-- Define a Coyote/JK2 AJP 1.3 Connector on port 8009 -- Connector port=8009 enableLookups=false redirectPort=8443 debug=0 protocol=AJP/1.3 / it sets no request attributes at all ! Is it a bug in Tomcat5.0.16's Coyote connector or is something wrong with my configuration ? -- x Rémy Maucherat Senior Developer Consultant JBoss Group (Europe) SàRL x - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
login page css not applied
Hi, I have a problem where the login page is not showing any images and not having the css applied to it. Here is my web.xml: --- web-app servlet servlet-nameController/servlet-name servlet-classcorej2ee.web.Controller/servlet-class init-param param-namecorej2ee.web.navigation.class/param-name param-valuecorej2ee.web.EnvEntryNavigator/param-value /init-param /servlet servlet-mapping servlet-nameController/servlet-name url-pattern/*.jsp/url-pattern /servlet-mapping welcome-file-list welcome-filewelcome.jsp/welcome-file welcome-fileindex.html/welcome-file /welcome-file-list resource-ref res-ref-namejdbc/afecWEBDB/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref security-constraint web-resource-collection web-resource-nameRegular and Power User/web-resource-name url-pattern/*/url-pattern /web-resource-collection auth-constraint role-nameRegularUser/role-name role-namePowerUser/role-name role-nameAdministrator/role-name /auth-constraint user-data-constraint transport-guaranteeNONE/transport-guarantee /user-data-constraint /security-constraint security-constraint web-resource-collection web-resource-nameAdministrator/web-resource-name url-pattern/admin/*/url-pattern /web-resource-collection auth-constraint role-nameAdministrator/role-name /auth-constraint user-data-constraint transport-guaranteeNONE/transport-guarantee /user-data-constraint /security-constraint login-config auth-methodFORM/auth-method form-login-config form-login-page/login.jsp/form-login-page form-error-page/loginError.html/form-error-page /form-login-config /login-config env-entry env-entry-nameroute/welcomePage/success/env-entry-name env-entry-value/welcome.jsp/env-entry-value env-entry-typejava.lang.String/env-entry-type /env-entry /web-app My images are under images folder in the root of the application and my css in under css folder in the root of my application. The webpage is referencing css, for example, like this: link href=css/background.css rel=stylesheet type=text/css I am know I am messing up security paths, but I can't figure out what to do about it. Any help would be greatly appreciated. Thanks. Yaakov Chaikin Software Engineer BAE SYSTEMS 301-838-6899 (phone) 301-838-6802 (fax) [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Hot deploy?
Hi all, I'm very much looking forward to Tomcat 5.x! Reading the docs, I can't tell if Tomcat 5.0 offers JBoss-style hot-deployment of WARs or not. By JBoss-style, I mean all I have to do is drop a new WAR into a deployment directory, and it will get picked up and redeployed. Section 4 of the User's Guide (Deployment) implies that this is possible, using something called the host's autodeploy attribute. However, Section 3 (First Webapp) seems to have an exhaustive list of all possible deployment methods, and automatic hot deployment is not mentioned. Does such hot deployment exist? Or is the only option to use the deployment Ant tasks? Thanks, Chris __ Do you Yahoo!? New Yahoo! Photos - easier uploading and sharing. http://photos.yahoo.com/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
java.net.SocketException: Broken pipe
Im running tomcat 4.1.29 with mod_jk2 under apache and getting constant stack traces in catalina.out like this one: Dec 8, 2003 8:04:49 PM org.apache.jk.server.JkCoyoteHandler action SEVERE: Error in action code java.net.SocketException: Broken pipe at java.net.SocketOutputStream.socketWrite0(Native Method) at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92) at java.net.SocketOutputStream.write(SocketOutputStream.java:136) at org.apache.jk.common.ChannelSocket.send(ChannelSocket.java:457) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:654) at org.apache.jk.server.JkCoyoteHandler.action(JkCoyoteHandler.java:435) at org.apache.coyote.Response.action(Response.java:222) at org.apache.coyote.Response.finish(Response.java:343) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:314) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:387) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:673) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java: 615) at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:786) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool .java:666) at java.lang.Thread.run(Thread.java:536) Have anybody ran over this issue and is it fixable? I already red some posting about firewalls closing connections after some period of time and Stop button pressed in browser. But is there any reasonable solution for this, since i cant ignore firewalls and cant make users not press stop? thanks in advance for any hints
Re: login page css not applied
US SSA said: Hi, I have a problem where the login page is not showing any images and not having the css applied to it. But after the user has authenticated, it works right? I'm not 100% sure about the setup of your webapp and I've been spending so much time with other products I've forgotten a lot of stuff, but it appears to me on first glance that you've got a security constraint on /*, which would include images/ and css/ in that webapp before the user has authenticated, wouldn't it? If not, then I've forgotten more than I realized. Anyway, if so, the browser is requesting the css and image files before the user has enough authentication to get them. That's why it's working after the user is authenticated and a role assigned. Rod. [snip] security-constraint web-resource-collection web-resource-nameRegular and Power User/web-resource-name url-pattern/*/url-pattern /web-resource-collection auth-constraint role-nameRegularUser/role-name role-namePowerUser/role-name role-nameAdministrator/role-name /auth-constraint user-data-constraint transport-guaranteeNONE/transport-guarantee /user-data-constraint /security-constraint - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: login page css not applied
Yes, you are right. However, when I changed the pattern to /*.jsp, the login page was skipped and the browser went straight to the protected page without any authentication. I am not sure what's going on. Yaakov Chaikin Software Engineer BAE SYSTEMS 301-838-6899 (phone) 301-838-6802 (fax) [EMAIL PROTECTED] -Original Message- From: Rod Giffin [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 1:31 PM To: [EMAIL PROTECTED] Subject: Re: login page css not applied US SSA said: Hi, I have a problem where the login page is not showing any images and not having the css applied to it. But after the user has authenticated, it works right? I'm not 100% sure about the setup of your webapp and I've been spending so much time with other products I've forgotten a lot of stuff, but it appears to me on first glance that you've got a security constraint on /*, which would include images/ and css/ in that webapp before the user has authenticated, wouldn't it? If not, then I've forgotten more than I realized. Anyway, if so, the browser is requesting the css and image files before the user has enough authentication to get them. That's why it's working after the user is authenticated and a role assigned. Rod. [snip] security-constraint web-resource-collection web-resource-nameRegular and Power User/web-resource-name url-pattern/*/url-pattern /web-resource-collection auth-constraint role-nameRegularUser/role-name role-namePowerUser/role-name role-nameAdministrator/role-name /auth-constraint user-data-constraint transport-guaranteeNONE/transport-guarantee /user-data-constraint /security-constraint - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: login page css not applied
I just did this same thing yesterday. Your CSS and images are being protected by the web resource containing url-pattern/*/url-pattern. Until a user has logged in, they won't be able to receive images, css, etc. Be more specific in your URL pattern so you don't include those common resources. -Original Message- From: Chaikin, Yaakov Y (US SSA) [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 12:06 PM To: [EMAIL PROTECTED] Subject: login page css not applied Hi, I have a problem where the login page is not showing any images and not having the css applied to it. Here is my web.xml: --- web-app servlet servlet-nameController/servlet-name servlet-classcorej2ee.web.Controller/servlet-class init-param param-namecorej2ee.web.navigation.class/param-name param-valuecorej2ee.web.EnvEntryNavigator/param-value /init-param /servlet servlet-mapping servlet-nameController/servlet-name url-pattern/*.jsp/url-pattern /servlet-mapping welcome-file-list welcome-filewelcome.jsp/welcome-file welcome-fileindex.html/welcome-file /welcome-file-list resource-ref res-ref-namejdbc/afecWEBDB/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref security-constraint web-resource-collection web-resource-nameRegular and Power User/web-resource-name url-pattern/*/url-pattern /web-resource-collection auth-constraint role-nameRegularUser/role-name role-namePowerUser/role-name role-nameAdministrator/role-name /auth-constraint user-data-constraint transport-guaranteeNONE/transport-guarantee /user-data-constraint /security-constraint security-constraint web-resource-collection web-resource-nameAdministrator/web-resource-name url-pattern/admin/*/url-pattern /web-resource-collection auth-constraint role-nameAdministrator/role-name /auth-constraint user-data-constraint transport-guaranteeNONE/transport-guarantee /user-data-constraint /security-constraint login-config auth-methodFORM/auth-method form-login-config form-login-page/login.jsp/form-login-page form-error-page/loginError.html/form-error-page /form-login-config /login-config env-entry env-entry-nameroute/welcomePage/success/env-entry-name env-entry-value/welcome.jsp/env-entry-value env-entry-typejava.lang.String/env-entry-type /env-entry /web-app My images are under images folder in the root of the application and my css in under css folder in the root of my application. The webpage is referencing css, for example, like this: link href=css/background.css rel=stylesheet type=text/css I am know I am messing up security paths, but I can't figure out what to do about it. Any help would be greatly appreciated. Thanks. Yaakov Chaikin Software Engineer BAE SYSTEMS 301-838-6899 (phone) 301-838-6802 (fax) [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: login page css not applied
Ok, I've seen that before. Probably your protected page has the same name as one of the welcome-file page matches in web.xml, or they're both present. If index.html is your welcome page, use that in the welcome-file setting and not an existing .jsp file. I think that's the way it works. Rod. US SSA said: Yes, you are right. However, when I changed the pattern to /*.jsp, the login page was skipped and the browser went straight to the protected page without any authentication. I am not sure what's going on. Yaakov Chaikin Software Engineer BAE SYSTEMS 301-838-6899 (phone) 301-838-6802 (fax) [EMAIL PROTECTED] -Original Message- From: Rod Giffin [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 1:31 PM To: [EMAIL PROTECTED] Subject: Re: login page css not applied US SSA said: Hi, I have a problem where the login page is not showing any images and not having the css applied to it. But after the user has authenticated, it works right? I'm not 100% sure about the setup of your webapp and I've been spending so much time with other products I've forgotten a lot of stuff, but it appears to me on first glance that you've got a security constraint on /*, which would include images/ and css/ in that webapp before the user has authenticated, wouldn't it? If not, then I've forgotten more than I realized. Anyway, if so, the browser is requesting the css and image files before the user has enough authentication to get them. That's why it's working after the user is authenticated and a role assigned. Rod. [snip] security-constraint web-resource-collection web-resource-nameRegular and Power User/web-resource-name url-pattern/*/url-pattern /web-resource-collection auth-constraint role-nameRegularUser/role-name role-namePowerUser/role-name role-nameAdministrator/role-name /auth-constraint user-data-constraint transport-guaranteeNONE/transport-guarantee /user-data-constraint /security-constraint - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: login page css not applied
Rod, I am sorry, but I am not 100% following you... Yes, you are right. I have the following situation: I am trying url: localhost/xxxWEB/ This gets forwared by the welcome-page to welcome.jsp, which I want to be protected. welcome.jsp page is in xxxWEB/ directory. Could you explain what you are suggesting again? Thanks. Yaakov Chaikin Software Engineer BAE SYSTEMS 301-838-6899 (phone) 301-838-6802 (fax) [EMAIL PROTECTED] -Original Message- From: Rod Giffin [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 1:46 PM To: [EMAIL PROTECTED] Subject: RE: login page css not applied Ok, I've seen that before. Probably your protected page has the same name as one of the welcome-file page matches in web.xml, or they're both present. If index.html is your welcome page, use that in the welcome-file setting and not an existing .jsp file. I think that's the way it works. Rod. US SSA said: Yes, you are right. However, when I changed the pattern to /*.jsp, the login page was skipped and the browser went straight to the protected page without any authentication. I am not sure what's going on. Yaakov Chaikin Software Engineer BAE SYSTEMS 301-838-6899 (phone) 301-838-6802 (fax) [EMAIL PROTECTED] -Original Message- From: Rod Giffin [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 1:31 PM To: [EMAIL PROTECTED] Subject: Re: login page css not applied US SSA said: Hi, I have a problem where the login page is not showing any images and not having the css applied to it. But after the user has authenticated, it works right? I'm not 100% sure about the setup of your webapp and I've been spending so much time with other products I've forgotten a lot of stuff, but it appears to me on first glance that you've got a security constraint on /*, which would include images/ and css/ in that webapp before the user has authenticated, wouldn't it? If not, then I've forgotten more than I realized. Anyway, if so, the browser is requesting the css and image files before the user has enough authentication to get them. That's why it's working after the user is authenticated and a role assigned. Rod. [snip] security-constraint web-resource-collection web-resource-nameRegular and Power User/web-resource-name url-pattern/*/url-pattern /web-resource-collection auth-constraint role-nameRegularUser/role-name role-namePowerUser/role-name role-nameAdministrator/role-name /auth-constraint user-data-constraint transport-guaranteeNONE/transport-guarantee /user-data-constraint /security-constraint - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
AW: Database pool problem
Seams a bit off-topic, but proposing databases, have a look at firebirdsql.org. Firebird ist very good, stable, wide-spread (in flavor of interbase), even used in tanks. Firebird has all features of a good database, including triggers, views, stored procedures, referential integrity, and a lot more. It is actually free even for commercial use! Maybe PostgreSQL is as good as firebird (or even better), but MySQL doen't even reach the power of firebird partly. Just my 5 cent, Steffen - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Unable to compile class for JSP
I've recently upgraded from 4.1.29 to 5.0.16 and Jasper appears to be (inconsistently) unable to rename temporary class files. One moment, a JSP will compile cleanly and, after a very simple page modification, the same JSP will cause this exception: 2003-12-08 12:29:30,527 [http8080-Processor25] ERROR org.apache.struts.taglib.tiles.InsertTag - ServletException in '/property/edit/title.jsp': tmpFile.rena meTo(classFile) failed org.apache.jasper.JasperException: Unable to compile class for JSP at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:5 58) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:2 91) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) ...yada x 3... Thanks in advance for any insight. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Enforce no cache
If it really is not allowed, then the handling of several proxies and/or browsers is severly broken. We had several problems with caching until we forced the reload by appending a unique query parameter in each link. -Original Message- From: Tim Funk [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 12:50 PM To: Tomcat Users List Subject: Re: Enforce no cache Write a filter that adds all the no-cacheing headers. (Google) (Or to be lazy, use ssl - since I think cacheing is not allowed in ssl) -Tim Jerald Powel wrote: Hello, How do I enforce no caching for a particular context under TC? Sites/doco welcome G. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
REPOST: Can't find child 2386 in scoreboard
This is a repost. Please help. Hi I have checked the archives and google to solve the problem but to no avail. Please help. The error I get in my apache error_log when navigating to http://localhost/examples is: [Sat Dec 06 00:11:21 2003] [info] Server: Apache/2.0.46, Interface: mod_ssl/2.0.46, Library: OpenSSL/0.9.6b [Sat Dec 06 00:11:21 2003] [error] jk2_init() Can't find child 2386 in scoreboard [Sat Dec 06 00:11:21 2003] [error] mod_jk child init 1 -2 [Sat Dec 06 00:11:21 2003] [error] jk2_init() Can't find child 2389 in scoreboard [Sat Dec 06 00:11:21 2003] [error] mod_jk child init 1 -2 [Sat Dec 06 00:11:21 2003] [notice] Apache/2.0.46 (Unix) mod_ssl/2.0.46 OpenSSL/0.9.6b mod_jk2/2.0.3-dev configured -- resuming normal operations [Sat Dec 06 00:11:21 2003] [info] Server built: Nov 30 2003 02:31:06 [Sat Dec 06 00:11:21 2003] [debug] in the catalina.out log output seems fine: [Sat Dec 06 00:10:08 2003] ( info ) [jk_uriEnv.c (245)] uriEnv.setAttribute() t he worker directive is deprecated. Use 'group' instead. [Sat Dec 06 00:10:08 2003] ( info ) [jk_uriEnv.c (245)] uriEnv.setAttribute() t he worker directive is deprecated. Use 'group' instead. [Sat Dec 06 00:10:08 2003] ( info ) [jk_logger_file.c (184)] Initializing log f ile stderr [Sat Dec 06 00:10:08 2003] ( info ) [jk_workerEnv.c (403)] workerEnv.init() ok /usr/local/apache2/conf/workers2.properties Dec 6, 2003 12:10:08 AM org.apache.jk.apr.AprImpl init INFO: JK2: Initialized apr Dec 6, 2003 12:10:08 AM org.apache.jk.common.ChannelUn init INFO: JK: listening on unix socket: /opt/apache/jakarta-tomcat-4.1.29/work/jk2.s ocket Dec 6, 2003 12:10:08 AM org.apache.jk.common.ChannelSocket init INFO: JK2: ajp13 listening on /0.0.0.0:8009 I am trying to use unix sockets. WHAT could be wrong? I have made sure that shm.file exists and that the same shm.file is being used by tomcat and apache. I am using apache 2.0.46, jk2 2.0.3 and tomcat 4.1.29. Please help. sachin dole = Cheers! Sachin Dole __ Do you Yahoo!? New Yahoo! Photos - easier uploading and sharing. http://photos.yahoo.com/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: login page css not applied
US SSA said: Rod, I am sorry, but I am not 100% following you... Yes, you are right. I have the following situation: I am trying url: localhost/xxxWEB/ I think it would work if you set the welcome-file element to send the user by default to localhost/xxxWEB/login.html (or index.html or whatever) where the login form could reside. The welcome.jsp page should not be a default page if it is protected, or it will be served before the user is authenticated. Since login.html or whatnot is not a jsp page, it won't be protected by a security-constraint such as /*.jsp, and it will be able to be accessed. This gets forwared by the welcome-page to welcome.jsp, which I want to be protected. welcome.jsp page is in xxxWEB/ directory. Could you explain what you are suggesting again? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Hot deploy?
Howdy, Hot deployment as you describe exists and is enabled by default, i.e. you don't have to do anything but drop the WAR into the webapps directory. This is true for tomcat 4 as well as tomcat 5, for which you can stop waiting as it's available already. Yoav Shapira Millennium ChemInformatics -Original Message- From: Chris [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 1:07 PM To: [EMAIL PROTECTED] Subject: Hot deploy? Hi all, I'm very much looking forward to Tomcat 5.x! Reading the docs, I can't tell if Tomcat 5.0 offers JBoss-style hot-deployment of WARs or not. By JBoss- style, I mean all I have to do is drop a new WAR into a deployment directory, and it will get picked up and redeployed. Section 4 of the User's Guide (Deployment) implies that this is possible, using something called the host's autodeploy attribute. However, Section 3 (First Webapp) seems to have an exhaustive list of all possible deployment methods, and automatic hot deployment is not mentioned. Does such hot deployment exist? Or is the only option to use the deployment Ant tasks? Thanks, Chris __ Do you Yahoo!? New Yahoo! Photos - easier uploading and sharing. http://photos.yahoo.com/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: More sophisticated JDBCRealm Security
Howdy, You can search the archives of this list for many examples. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 12:10 PM To: Tomcat Users List Subject: Re: More sophisticated JDBCRealm Security Well crap! Turns out we are using MySQL 4.0.x which does not have support for views. Can anyone point me in a direction that would help me in implementing my own Realm (either brand new or by extending another) Thank you very much, Frank - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:49 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, Your other option is to extend JDBCRealm into your own custom realm implementation. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:41 AM To: Tomcat Users List Subject: Re: More sophisticated JDBCRealm Security What about the fact that the groupId column in User is called id in the Groups table, would it be a case of making another view to accomplish that translation too? Besides craeting views, which is easy, what are the other options here? - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, The typical solution in many cases involving JDBCRealm is (if you don't want to customize the realm by coding) to create a view for use by the JDBC realm. In your case, you'd create a view on the user table where only active users are shown, and configure the JDBC realm to query this view rather than the user table. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM To: Tomcat Users List Subject: More sophisticated JDBCRealm Security In looking through the docs I am surpised that I dont see a way to do some more sophisticated JDBCRealm security. I may just be looking in the wrong place or misreading something so please let me know if I am. My DB tables are arranged as follows create table user ( id BIGINT NOT NULL AUTO_INCREMENT, email VARCHAR(100) not null unique, groupId BIGINT not null, password VARCHAR(20) not null, active BIT, primary key (id) ); create table groups ( id BIGINT NOT NULL AUTO_INCREMENT, role VARCHAR(255) not null, primary key (id) ); The email address is the user login, password is obvious. I would want something that would only let ACTIVE users log in (active = 1), and User.groupId maps to Groups.id field. Using the standard JDBCRealm I do not see how this is possible. Would I actually have to create my own custom Realm implementation in order to achieve these goals? Thanks for any input/advice, Frank - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed,
Ant install tasks
I've used the custom ant tasks to build and install web apps a zillion times. However, I'm setting up a new build/test environment on a fresh machine and I'm having a problem getting the install task to work. I can do all the normal all/compile/dist tasks. plus I can do the LIST task. I can also use the HTML manager app to do the install. Just can't do the install via ant. Environment: Windows XP Pro jakarta-tomcat-5.0.16 apache-ant-1.5.4 Error: BUILD FAILED file:C:/Documents%20and%20Settings/rich/My%20Documents/workbench/java/bu ild.xml:368: java.net.UnknownHostException: C I'm nearly 100% the host is correct - it's simply localhost. Plus, the list task works fine, so it has to be hitting the correct url to do that. I've also echoed all the variables being passed to the install target (in the build.xml), and they look correct. Running ant with debug doesn't offer much more insight: BUILD FAILED file:C:/Documents%20and%20Settings/rich/My%20Documents/workbench/java/bu ild.xml:368: java.net.UnknownHostException: C at org.apache.catalina.ant.DeployTask.execute(DeployTask.java:208) at org.apache.tools.ant.Task.perform(Task.java:341) at org.apache.tools.ant.Target.execute(Target.java:309) at org.apache.tools.ant.Target.performTasks(Target.java:336) at org.apache.tools.ant.Project.executeTarget(Project.java:1339) at org.apache.tools.ant.Project.executeTargets(Project.java:1255) at org.apache.tools.ant.Main.runBuild(Main.java:609) at org.apache.tools.ant.Main.start(Main.java:196) at org.apache.tools.ant.Main.main(Main.java:235) Caused by: java.net.UnknownHostException: C at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:153) at java.net.Socket.connect(Socket.java:452) at java.net.Socket.connect(Socket.java:402) at sun.net.NetworkClient.doConnect(NetworkClient.java:139) at sun.net.NetworkClient.openServer(NetworkClient.java:118) at sun.net.ftp.FtpClient.openServer(FtpClient.java:423) at sun.net.ftp.FtpClient.init(FtpClient.java:692) at sun.net.www.protocol.ftp.FtpURLConnection.connect(FtpURLConnection.ja va:175) at sun.net.www.protocol.ftp.FtpURLConnection.getInputStream(FtpURLConnec tion.java:257) at org.apache.catalina.ant.DeployTask.execute(DeployTask.java:205) ... 8 more --- Nested Exception --- java.net.UnknownHostException: C at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:153) at java.net.Socket.connect(Socket.java:452) at java.net.Socket.connect(Socket.java:402) at sun.net.NetworkClient.doConnect(NetworkClient.java:139) at sun.net.NetworkClient.openServer(NetworkClient.java:118) at sun.net.ftp.FtpClient.openServer(FtpClient.java:423) at sun.net.ftp.FtpClient.init(FtpClient.java:692) at sun.net.www.protocol.ftp.FtpURLConnection.connect(FtpURLConnection.ja va:175) at sun.net.www.protocol.ftp.FtpURLConnection.getInputStream(FtpURLConnec tion.java:257) at org.apache.catalina.ant.DeployTask.execute(DeployTask.java:205) at org.apache.tools.ant.Task.perform(Task.java:341) at org.apache.tools.ant.Target.execute(Target.java:309) at org.apache.tools.ant.Target.performTasks(Target.java:336) at org.apache.tools.ant.Project.executeTarget(Project.java:1339) at org.apache.tools.ant.Project.executeTargets(Project.java:1255) at org.apache.tools.ant.Main.runBuild(Main.java:609) at org.apache.tools.ant.Main.start(Main.java:196) at org.apache.tools.ant.Main.main(Main.java:235) Total time: 11 seconds Anyone have a hint? I've never run into this before and I'm going crazy trying to figure out what's wrong. Many thanks, Rich
Custom Realm deployment, was More sophisticated JDBCRealm Security
Thanks Yoav, One more question to you or the group, When deploying a custom Realm implementation, I am defining the Realm inside the Context for my specific application. But on startup I get: java.lang.ClassNotFoundException: .util.CustomJDBCRealm Can I have the Realm class in my WAR file or do I have to put it on the tomcat classpath somewhere? Thanks again, Frank - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 2:52 PM Subject: RE: More sophisticated JDBCRealm Security Howdy, You can search the archives of this list for many examples. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 12:10 PM To: Tomcat Users List Subject: Re: More sophisticated JDBCRealm Security Well crap! Turns out we are using MySQL 4.0.x which does not have support for views. Can anyone point me in a direction that would help me in implementing my own Realm (either brand new or by extending another) Thank you very much, Frank - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:49 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, Your other option is to extend JDBCRealm into your own custom realm implementation. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:41 AM To: Tomcat Users List Subject: Re: More sophisticated JDBCRealm Security What about the fact that the groupId column in User is called id in the Groups table, would it be a case of making another view to accomplish that translation too? Besides craeting views, which is easy, what are the other options here? - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, The typical solution in many cases involving JDBCRealm is (if you don't want to customize the realm by coding) to create a view for use by the JDBC realm. In your case, you'd create a view on the user table where only active users are shown, and configure the JDBC realm to query this view rather than the user table. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM To: Tomcat Users List Subject: More sophisticated JDBCRealm Security In looking through the docs I am surpised that I dont see a way to do some more sophisticated JDBCRealm security. I may just be looking in the wrong place or misreading something so please let me know if I am. My DB tables are arranged as follows create table user ( id BIGINT NOT NULL AUTO_INCREMENT, email VARCHAR(100) not null unique, groupId BIGINT not null, password VARCHAR(20) not null, active BIT, primary key (id) ); create table groups ( id BIGINT NOT NULL AUTO_INCREMENT, role VARCHAR(255) not null, primary key (id) ); The email address is the user login, password is obvious. I would want something that would only let ACTIVE users log in (active = 1), and User.groupId maps to Groups.id field. Using the standard JDBCRealm I do not see how this is possible. Would I actually have to create my own custom Realm implementation in order to achieve these goals? Thanks for any input/advice, Frank - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank
RE: Custom Realm deployment, was More sophisticated JDBCRealm Security
It must be in Tomcat's classpath, not in your WAR file. -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 3:10 PM To: Tomcat Users List Subject: Custom Realm deployment, was More sophisticated JDBCRealm Security Thanks Yoav, One more question to you or the group, When deploying a custom Realm implementation, I am defining the Realm inside the Context for my specific application. But on startup I get: java.lang.ClassNotFoundException: .util.CustomJDBCRealm Can I have the Realm class in my WAR file or do I have to put it on the tomcat classpath somewhere? Thanks again, Frank - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 2:52 PM Subject: RE: More sophisticated JDBCRealm Security Howdy, You can search the archives of this list for many examples. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 12:10 PM To: Tomcat Users List Subject: Re: More sophisticated JDBCRealm Security Well crap! Turns out we are using MySQL 4.0.x which does not have support for views. Can anyone point me in a direction that would help me in implementing my own Realm (either brand new or by extending another) Thank you very much, Frank - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:49 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, Your other option is to extend JDBCRealm into your own custom realm implementation. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:41 AM To: Tomcat Users List Subject: Re: More sophisticated JDBCRealm Security What about the fact that the groupId column in User is called id in the Groups table, would it be a case of making another view to accomplish that translation too? Besides craeting views, which is easy, what are the other options here? - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, The typical solution in many cases involving JDBCRealm is (if you don't want to customize the realm by coding) to create a view for use by the JDBC realm. In your case, you'd create a view on the user table where only active users are shown, and configure the JDBC realm to query this view rather than the user table. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM To: Tomcat Users List Subject: More sophisticated JDBCRealm Security In looking through the docs I am surpised that I dont see a way to do some more sophisticated JDBCRealm security. I may just be looking in the wrong place or misreading something so please let me know if I am. My DB tables are arranged as follows create table user ( id BIGINT NOT NULL AUTO_INCREMENT, email VARCHAR(100) not null unique, groupId BIGINT not null, password VARCHAR(20) not null, active BIT, primary key (id) ); create table groups ( id BIGINT NOT NULL AUTO_INCREMENT, role VARCHAR(255) not null, primary key (id) ); The email address is the user login, password is obvious. I would want something that would only let ACTIVE users log in (active = 1), and User.groupId maps to Groups.id field. Using the standard JDBCRealm I do not see how this is possible. Would I actually have to create my own custom Realm implementation in order to achieve these goals? Thanks for any input/advice, Frank - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is
Re: Custom Realm deployment, was More sophisticated JDBCRealm Security
To be more sepcific - it needs to be in the server classpath. You may also need to do some MBean registration work too. (editing/creating an mbeans.xml file) -Tim Hart, Justin wrote: It must be in Tomcat's classpath, not in your WAR file. -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 3:10 PM To: Tomcat Users List Subject: Custom Realm deployment, was More sophisticated JDBCRealm Security Thanks Yoav, One more question to you or the group, When deploying a custom Realm implementation, I am defining the Realm inside the Context for my specific application. But on startup I get: java.lang.ClassNotFoundException: .util.CustomJDBCRealm Can I have the Realm class in my WAR file or do I have to put it on the tomcat classpath somewhere? Thanks again, Frank - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 2:52 PM Subject: RE: More sophisticated JDBCRealm Security Howdy, You can search the archives of this list for many examples. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 12:10 PM To: Tomcat Users List Subject: Re: More sophisticated JDBCRealm Security Well crap! Turns out we are using MySQL 4.0.x which does not have support for views. Can anyone point me in a direction that would help me in implementing my own Realm (either brand new or by extending another) Thank you very much, Frank - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:49 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, Your other option is to extend JDBCRealm into your own custom realm implementation. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:41 AM To: Tomcat Users List Subject: Re: More sophisticated JDBCRealm Security What about the fact that the groupId column in User is called id in the Groups table, would it be a case of making another view to accomplish that translation too? Besides craeting views, which is easy, what are the other options here? - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, The typical solution in many cases involving JDBCRealm is (if you don't want to customize the realm by coding) to create a view for use by the JDBC realm. In your case, you'd create a view on the user table where only active users are shown, and configure the JDBC realm to query this view rather than the user table. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM To: Tomcat Users List Subject: More sophisticated JDBCRealm Security In looking through the docs I am surpised that I dont see a way to do some more sophisticated JDBCRealm security. I may just be looking in the wrong place or misreading something so please let me know if I am. My DB tables are arranged as follows create table user ( id BIGINT NOT NULL AUTO_INCREMENT, email VARCHAR(100) not null unique, groupId BIGINT not null, password VARCHAR(20) not null, active BIT, primary key (id) ); create table groups ( id BIGINT NOT NULL AUTO_INCREMENT, role VARCHAR(255) not null, primary key (id) ); The email address is the user login, password is obvious. I would want something that would only let ACTIVE users log in (active = 1), and User.groupId maps to Groups.id field. Using the standard JDBCRealm I do not see how this is possible. Would I actually have to create my own custom Realm implementation in order to achieve these goals? Thanks for any input/advice, Frank - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail,
RE: Custom Realm deployment, was More sophisticated JDBCRealm Security
Basically, jar your package that you are using for your JDBCRealm and put the .jar file into common/lib directory. That will make your package visible to both your webapps and Tomcat server. Well, in your case, you only care about the server seeing this package. HTH. Yaakov Chaikin Software Engineer BAE SYSTEMS 301-838-6899 (phone) 301-838-6802 (fax) [EMAIL PROTECTED] -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 3:10 PM To: Tomcat Users List Subject: Custom Realm deployment, was More sophisticated JDBCRealm Security Thanks Yoav, One more question to you or the group, When deploying a custom Realm implementation, I am defining the Realm inside the Context for my specific application. But on startup I get: java.lang.ClassNotFoundException: .util.CustomJDBCRealm Can I have the Realm class in my WAR file or do I have to put it on the tomcat classpath somewhere? Thanks again, Frank - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 2:52 PM Subject: RE: More sophisticated JDBCRealm Security Howdy, You can search the archives of this list for many examples. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 12:10 PM To: Tomcat Users List Subject: Re: More sophisticated JDBCRealm Security Well crap! Turns out we are using MySQL 4.0.x which does not have support for views. Can anyone point me in a direction that would help me in implementing my own Realm (either brand new or by extending another) Thank you very much, Frank - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:49 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, Your other option is to extend JDBCRealm into your own custom realm implementation. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 11:41 AM To: Tomcat Users List Subject: Re: More sophisticated JDBCRealm Security What about the fact that the groupId column in User is called id in the Groups table, would it be a case of making another view to accomplish that translation too? Besides craeting views, which is easy, what are the other options here? - Original Message - From: Shapira, Yoav [EMAIL PROTECTED] To: Tomcat Users List [EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM Subject: RE: More sophisticated JDBCRealm Security Howdy, The typical solution in many cases involving JDBCRealm is (if you don't want to customize the realm by coding) to create a view for use by the JDBC realm. In your case, you'd create a view on the user table where only active users are shown, and configure the JDBC realm to query this view rather than the user table. Yoav Shapira Millennium ChemInformatics -Original Message- From: Frank Febbraro [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 10:48 AM To: Tomcat Users List Subject: More sophisticated JDBCRealm Security In looking through the docs I am surpised that I dont see a way to do some more sophisticated JDBCRealm security. I may just be looking in the wrong place or misreading something so please let me know if I am. My DB tables are arranged as follows create table user ( id BIGINT NOT NULL AUTO_INCREMENT, email VARCHAR(100) not null unique, groupId BIGINT not null, password VARCHAR(20) not null, active BIT, primary key (id) ); create table groups ( id BIGINT NOT NULL AUTO_INCREMENT, role VARCHAR(255) not null, primary key (id) ); The email address is the user login, password is obvious. I would want something that would only let ACTIVE users log in (active = 1), and User.groupId maps to Groups.id field. Using the standard JDBCRealm I do not see how this is possible. Would I actually have to create my own custom Realm implementation in order to achieve these goals? Thanks for any input/advice, Frank - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you.
Tomcat 5.0.16 fails to compile JSP page where 4.1.18 would...
Hello Group! I'm trying to upgrade to tomcat 5.0.16 but I'm having some trouble with just one JSP page. The pagew will not compile and the error points to this line in the JSP: jsp:useBean id = LOG_KEEPER class=com.k4sv.web.LogKeeper scope = application / A pretty straight forward JSP line to be sure. Here is the error message: type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception org.apache.jasper.JasperException: Unable to compile class for JSP An error occurred at line: 17 in the jsp file: /LogCheck.jsp Generated servlet error: [javac] Compiling 1 source file /usr/local/tomcat/jakarta-tomcat-5.0.16/work/Catalina/k4sv.com/_/org/apache/ jsp/LogCheck_jsp.java:59: LogKeeper(java.lang.String) in com.k4sv.web.LogKeeper cannot be applied to () LOG_KEEPER = new com.k4sv.web.LogKeeper(); ^ 1 error org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandle r.java:127) org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:3 51) org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:415) org.apache.jasper.compiler.Compiler.compile(Compiler.java:458) org.apache.jasper.compiler.Compiler.compile(Compiler.java:439) org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:5 52) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:2 91) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248) javax.servlet.http.HttpServlet.service(HttpServlet.java:856) note The full stack trace of the root cause is available in the Tomcat logs. Is there something in the new JSP spec that prevents this syntax? Am I doing something wrong? This page compiles great under 4.1.18 by the way. Thanks, Lon
Re: Ant install tasks
Rich Garabedian wrote: I've used the custom ant tasks to build and install web apps a zillion times. However, I'm setting up a new build/test environment on a fresh machine and I'm having a problem getting the install task to work. I can do all the normal all/compile/dist tasks. plus I can do the LIST task. I can also use the HTML manager app to do the install. Just can't do the install via ant. The tasks did change to some extent. In particular, install/remove were deprecated in favor of deploy/undeploy, to avoid confusing users (deploy includes the install functionality). Please look in the docs or the deployer package for the full story. -- x Rémy Maucherat Senior Developer Consultant JBoss Group (Europe) SàRL x - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
AW: Ant install tasks
Hi First, I don't know anything about ant... BUILD FAILED file:C:/Documents%20and%20Settings/rich/My%20Documents/workbench/java/bu ild.xml:368: java.net.UnknownHostException: C I'm nearly 100% the host is correct - it's simply localhost. But it seams to read your c:/... as (host):, so it says: I dont know host 'C'!. It isn't trying to connet to localhost but to C. Just my 5 cents, Steffen - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: login page css not applied
Rod, Actually, I am pretty sure that the welcome-file has nothing to do with it. All that does is tell the server which URL to try to serve up if you were to leave off the file name from the url you are typing in. So, in my case typing localhost/xxxWEB/ is equivalent to localhost/xxxWEB/welcome.jsp. The real problem that I can't figure out is why when I specify that I am only securing *.jsp, it secures nothing. I'll have to research that one. Yaakov Chaikin Software Engineer BAE SYSTEMS 301-838-6899 (phone) 301-838-6802 (fax) [EMAIL PROTECTED] -Original Message- From: Rod Giffin [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 2:34 PM To: [EMAIL PROTECTED] Subject: RE: login page css not applied US SSA said: Rod, I am sorry, but I am not 100% following you... Yes, you are right. I have the following situation: I am trying url: localhost/xxxWEB/ I think it would work if you set the welcome-file element to send the user by default to localhost/xxxWEB/login.html (or index.html or whatever) where the login form could reside. The welcome.jsp page should not be a default page if it is protected, or it will be served before the user is authenticated. Since login.html or whatnot is not a jsp page, it won't be protected by a security-constraint such as /*.jsp, and it will be able to be accessed. This gets forwared by the welcome-page to welcome.jsp, which I want to be protected. welcome.jsp page is in xxxWEB/ directory. Could you explain what you are suggesting again? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat 5.0.16 fails to compile JSP page where 4.1.18 would...
Lon Palmer wrote: Hello Group! I'm trying to upgrade to tomcat 5.0.16 but I'm having some trouble with just one JSP page. The pagew will not compile and the error points to this line in the JSP: jsp:useBean id = LOG_KEEPER class=com.k4sv.web.LogKeeper scope = application / A pretty straight forward JSP line to be sure. Here is the error message: type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception org.apache.jasper.JasperException: Unable to compile class for JSP An error occurred at line: 17 in the jsp file: /LogCheck.jsp Generated servlet error: [javac] Compiling 1 source file /usr/local/tomcat/jakarta-tomcat-5.0.16/work/Catalina/k4sv.com/_/org/apache/ jsp/LogCheck_jsp.java:59: LogKeeper(java.lang.String) in com.k4sv.web.LogKeeper cannot be applied to () LOG_KEEPER = new com.k4sv.web.LogKeeper(); ^ 1 error org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandle r.java:127) org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:3 51) org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:415) org.apache.jasper.compiler.Compiler.compile(Compiler.java:458) org.apache.jasper.compiler.Compiler.compile(Compiler.java:439) org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:5 52) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:2 91) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248) javax.servlet.http.HttpServlet.service(HttpServlet.java:856) note The full stack trace of the root cause is available in the Tomcat logs. Is there something in the new JSP spec that prevents this syntax? Am I doing something wrong? This page compiles great under 4.1.18 by the way. For jsp:getProperty and the others, your bean must comply with the JavaBean specification (ie, have a no arg constructor). I think this is indeed a change from 4.1.x (you can compare the generated code). BTW, you can use the Jasper from 4.1.x with 5.0.x without any problems if you don't care about JSP 2.0 for now (I suggest you care, it's nice :) ). -- x Rémy Maucherat Senior Developer Consultant JBoss Group (Europe) SàRL x - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Ant install tasks
Hello, Is it possible to put an object in session of another webapp, like I am in context of webapp1 and I want to put an UserInfo object in session of webapp2. Can I even access session of webapp2 from webapp1. Both are deployed under Tomcat4.1. Thanks -sumit - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Giving access to an html file in tomcat
Hey, I have added the following to my web.xml of one of my web apps: error-page error-code403/error-code location/error/error.htm/location /error-page When I try and test this (go to a page I do not have access to that will throw a 403 error), i get the Internet Explorer error page that says You might not have permission to view this directory or page using the credentials you supplied and not my page (and not even a tomcat page). Am I missing some configuration somewhere? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
session sharing across webapps
Sorry, I posted the message earlier with a wrong subject. Is it possible to put an object in session of another webapp, like I am in context of webapp1 and I want to put an UserInfo object in session of webapp2. Can I even access session of webapp2 from webapp1. Both are deployed under Tomcat4.1. Thanks -sumit -Original Message- From: Kumar, Sumit Sent: Monday, December 08, 2003 2:39 PM To: 'Tomcat Users List'; [EMAIL PROTECTED] Subject: RE: Ant install tasks Hello, Is it possible to put an object in session of another webapp, like I am in context of webapp1 and I want to put an UserInfo object in session of webapp2. Can I even access session of webapp2 from webapp1. Both are deployed under Tomcat4.1. Thanks -sumit - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: session sharing across webapps
Howdy, The short answer is you can't access another webapp's sessions, period. But you can have a singleton you write live in shared/lib and both webapps will see the same instance of the singleton. Yoav Shapira Millennium ChemInformatics -Original Message- From: Kumar, Sumit [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 3:42 PM To: 'Tomcat Users List' Subject: session sharing across webapps Sorry, I posted the message earlier with a wrong subject. Is it possible to put an object in session of another webapp, like I am in context of webapp1 and I want to put an UserInfo object in session of webapp2. Can I even access session of webapp2 from webapp1. Both are deployed under Tomcat4.1. Thanks -sumit -Original Message- From: Kumar, Sumit Sent: Monday, December 08, 2003 2:39 PM To: 'Tomcat Users List'; [EMAIL PROTECTED] Subject: RE: Ant install tasks Hello, Is it possible to put an object in session of another webapp, like I am in context of webapp1 and I want to put an UserInfo object in session of webapp2. Can I even access session of webapp2 from webapp1. Both are deployed under Tomcat4.1. Thanks -sumit - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tomcat 5.0.16 fails to compile JSP page where 4.1.18 would...
Thanks Remmy, That was it. Lon -Original Message- From: Remy Maucherat [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 3:38 PM To: Tomcat Users List Subject: Re: Tomcat 5.0.16 fails to compile JSP page where 4.1.18 would... Lon Palmer wrote: Hello Group! I'm trying to upgrade to tomcat 5.0.16 but I'm having some trouble with just one JSP page. The pagew will not compile and the error points to this line in the JSP: jsp:useBean id = LOG_KEEPER class=com.k4sv.web.LogKeeper scope = application / A pretty straight forward JSP line to be sure. Here is the error message: type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception org.apache.jasper.JasperException: Unable to compile class for JSP An error occurred at line: 17 in the jsp file: /LogCheck.jsp Generated servlet error: [javac] Compiling 1 source file /usr/local/tomcat/jakarta-tomcat-5.0.16/work/Catalina/k4sv.com/_/org/apache/ jsp/LogCheck_jsp.java:59: LogKeeper(java.lang.String) in com.k4sv.web.LogKeeper cannot be applied to () LOG_KEEPER = new com.k4sv.web.LogKeeper(); ^ 1 error org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandle r.java:127) org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:3 51) org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:415) org.apache.jasper.compiler.Compiler.compile(Compiler.java:458) org.apache.jasper.compiler.Compiler.compile(Compiler.java:439) org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:5 52) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:2 91) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248) javax.servlet.http.HttpServlet.service(HttpServlet.java:856) note The full stack trace of the root cause is available in the Tomcat logs. Is there something in the new JSP spec that prevents this syntax? Am I doing something wrong? This page compiles great under 4.1.18 by the way. For jsp:getProperty and the others, your bean must comply with the JavaBean specification (ie, have a no arg constructor). I think this is indeed a change from 4.1.x (you can compare the generated code). BTW, you can use the Jasper from 4.1.x with 5.0.x without any problems if you don't care about JSP 2.0 for now (I suggest you care, it's nice :) ). -- x Rémy Maucherat Senior Developer Consultant JBoss Group (Europe) SàRL x - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Giving access to an html file in tomcat
if i go to http://localhost/dmt/error/error.htm or http://localhost:8080/dmt/error/error.htm the page comes up. If i trigger the error code 403, i get it thrown back to me as an IE error, and I do not see my page./ -Original Message- From: Bender, Christopher Sent: Monday, December 08, 2003 3:40 PM To: Tomcat Users List Subject: Giving access to an html file in tomcat Hey, I have added the following to my web.xml of one of my web apps: error-page error-code403/error-code location/error/error.htm/location /error-page When I try and test this (go to a page I do not have access to that will throw a 403 error), i get the Internet Explorer error page that says You might not have permission to view this directory or page using the credentials you supplied and not my page (and not even a tomcat page). Am I missing some configuration somewhere? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Giving access to an html file in tomcat
Howdy, Turn off the Display Friendly Error Pages option in the IE preferences section. Yoav Shapira Millennium ChemInformatics -Original Message- From: Bender, Christopher [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 4:02 PM To: Tomcat Users List Subject: RE: Giving access to an html file in tomcat if i go to http://localhost/dmt/error/error.htm or http://localhost:8080/dmt/error/error.htm the page comes up. If i trigger the error code 403, i get it thrown back to me as an IE error, and I do not see my page./ -Original Message- From: Bender, Christopher Sent: Monday, December 08, 2003 3:40 PM To: Tomcat Users List Subject: Giving access to an html file in tomcat Hey, I have added the following to my web.xml of one of my web apps: error-page error-code403/error-code location/error/error.htm/location /error-page When I try and test this (go to a page I do not have access to that will throw a 403 error), i get the Internet Explorer error page that says You might not have permission to view this directory or page using the credentials you supplied and not my page (and not even a tomcat page). Am I missing some configuration somewhere? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]