Re: clearReferencesThreads, Poller SunPKCS11-Solaris and strange context class loader
2010/5/9 Rainer Jung : > On 07.05.2010 20:08, Filip Hanik - Dev Lists wrote: >> >> On 05/07/2010 08:03 AM, Rainer Jung wrote: >>> >>> It's there after JDK start with some version of the JDK. It's not >>> there if I only start a plain Java test doing only a sleep using the >>> same JDK. >> >> well, if the app uses java.net.URL to a https, then this would make >> sense that the thread got started with the webapp's class loader > > Yes, but there is no app. The thread is there even when I remove all webapps > (except for the ROOT context I kept). I guess I need to do more systematic > testing. > Some more research, looking at the source code that I mentioned: 1. "SunPKCS11-Solaris" is not the default name. The default name of the class instance would be "SunPKCS11-Dummy". You may want to look at the "/lib/security/java.security" file in your JRE. It should be configured there. Here is some, though failing. example of trying to use this class: http://forums.sun.com/thread.jspa?threadID=5431010 2. sun.security.pkcs11.SunPKCS11 extends java.security.AuthProvider 3. SunPKCS11() constructor calls initToken(slotInfo) and that method will call createPoller() if the token is not present in the slot. (Thus apparently it starts waiting for the token). 4. It is said that PKCS11 "defines a platform-independent API to cryptographic tokens, such as Hardware Security Modules (HSM) and smart cards." Best regards, Konstantin Kolinko - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r942517 - in /tomcat/tc5.5.x/trunk/container/webapps/docs: default-servlet.xml tomcat-docs.xsl
Author: kkolinko Date: Sun May 9 10:17:51 2010 New Revision: 942517 URL: http://svn.apache.org/viewvc?rev=942517&view=rev Log: CTR: documentation It is backport of r941463 More anchor handling improvements: 1) escape '#' character as well as spaces. See virtual-hosting-howto.html for an example. 2) allow to explicitly specify anchor name, using anchor="" attribute on a (sub)section. See default-servlet.html for an example. Modified: tomcat/tc5.5.x/trunk/container/webapps/docs/default-servlet.xml tomcat/tc5.5.x/trunk/container/webapps/docs/tomcat-docs.xsl Modified: tomcat/tc5.5.x/trunk/container/webapps/docs/default-servlet.xml URL: http://svn.apache.org/viewvc/tomcat/tc5.5.x/trunk/container/webapps/docs/default-servlet.xml?rev=942517&r1=942516&r2=942517&view=diff == --- tomcat/tc5.5.x/trunk/container/webapps/docs/default-servlet.xml (original) +++ tomcat/tc5.5.x/trunk/container/webapps/docs/default-servlet.xml Sun May 9 10:17:51 2010 @@ -33,19 +33,13 @@ - -This discusses different ways to manipulate the default servlet. - - - - + The default servlet is the servlet which serves static resources as well as serves the directory listings (if directory listings are enabled). - - + It is declared globally in $CATALINA_HOME/conf/web.xml. By default here is it's declaration: @@ -78,8 +72,7 @@ So by default, the default servlet is lo directory listings are enabled and debugging is turned off. - - + The DefaultServlet allows the following initParamters: @@ -184,8 +177,7 @@ The DefaultServlet allows the following - - + You can override DefaultServlet with you own implementation and use that in your web.xml declaration. If you can understand what was just said, we will assume you can read the code @@ -303,8 +295,7 @@ The following is a sample xsl file which - - + Use web.xml in each individual webapp. See the security section of the Servlet specification. Modified: tomcat/tc5.5.x/trunk/container/webapps/docs/tomcat-docs.xsl URL: http://svn.apache.org/viewvc/tomcat/tc5.5.x/trunk/container/webapps/docs/tomcat-docs.xsl?rev=942517&r1=942516&r2=942517&view=diff == --- tomcat/tc5.5.x/trunk/container/webapps/docs/tomcat-docs.xsl (original) +++ tomcat/tc5.5.x/trunk/container/webapps/docs/tomcat-docs.xsl Sun May 9 10:17:51 2010 @@ -190,10 +190,17 @@ - + + + + + + + + - + @@ -226,15 +233,22 @@ - - - - + + + + + + + + + + + - + @@ -259,15 +273,22 @@ - - - - + + + + + + + + + + + - + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r942518 - /tomcat/site/trunk/xdocs/stylesheets/tomcat-site.xsl
Author: kkolinko Date: Sun May 9 10:30:25 2010 New Revision: 942518 URL: http://svn.apache.org/viewvc?rev=942518&view=rev Log: It is port of r941463 from Tomcat trunk. More anchor handling improvements: 1) escape '#' character as well as spaces. See virtual-hosting-howto.html for an example. 2) allow to explicitly specify anchor name, using anchor="" attribute on a (sub)section. See default-servlet.html for an example. Modified: tomcat/site/trunk/xdocs/stylesheets/tomcat-site.xsl Modified: tomcat/site/trunk/xdocs/stylesheets/tomcat-site.xsl URL: http://svn.apache.org/viewvc/tomcat/site/trunk/xdocs/stylesheets/tomcat-site.xsl?rev=942518&r1=942517&r2=942518&view=diff == --- tomcat/site/trunk/xdocs/stylesheets/tomcat-site.xsl (original) +++ tomcat/site/trunk/xdocs/stylesheets/tomcat-site.xsl Sun May 9 10:30:25 2010 @@ -177,10 +177,17 @@ - + + + + + + + + - + @@ -214,15 +221,22 @@ - - - - + + + + + + + + + + + - + @@ -248,15 +262,22 @@ - - - - + + + + + + + + + + + - + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r942520 - /tomcat/tc6.0.x/trunk/STATUS.txt
Author: kkolinko Date: Sun May 9 10:44:48 2010 New Revision: 942520 URL: http://svn.apache.org/viewvc?rev=942520&view=rev Log: vote Modified: tomcat/tc6.0.x/trunk/STATUS.txt Modified: tomcat/tc6.0.x/trunk/STATUS.txt URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/STATUS.txt?rev=942520&r1=942519&r2=942520&view=diff == --- tomcat/tc6.0.x/trunk/STATUS.txt (original) +++ tomcat/tc6.0.x/trunk/STATUS.txt Sun May 9 10:44:48 2010 @@ -144,7 +144,7 @@ PATCHES PROPOSED TO BACKPORT: * Correct SSL session timeout attribute name http://people.apache.org/~markt/patches/2010-04-07-SslSessionTimeout.patch - +1: markt + +1: markt, kkolinko -1: kkolinko: Generally, I would be against renaming some attributes, but this one is already documented as "sessionTimeout" in config/http.xml, though, - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: clearReferencesThreads, Poller SunPKCS11-Solaris and strange context class loader
Hi Konstantin, On 09.05.2010 11:38, Konstantin Kolinko wrote: 2010/5/9 Rainer Jung: On 07.05.2010 20:08, Filip Hanik - Dev Lists wrote: On 05/07/2010 08:03 AM, Rainer Jung wrote: It's there after JDK start with some version of the JDK. It's not there if I only start a plain Java test doing only a sleep using the same JDK. well, if the app uses java.net.URL to a https, then this would make sense that the thread got started with the webapp's class loader Yes, but there is no app. The thread is there even when I remove all webapps (except for the ROOT context I kept). I guess I need to do more systematic testing. Some more research, looking at the source code that I mentioned: 1. "SunPKCS11-Solaris" is not the default name. The default name of the class instance would be "SunPKCS11-Dummy". You may want to look at the "/lib/security/java.security" file in your JRE. It should be configured there. Yes, I knew. PKCS is in there, but it is by default. The file hasn't been touched. Here is some, though failing. example of trying to use this class: http://forums.sun.com/thread.jspa?threadID=5431010 2. sun.security.pkcs11.SunPKCS11 extends java.security.AuthProvider 3. SunPKCS11() constructor calls initToken(slotInfo) and that method will call createPoller() if the token is not present in the slot. (Thus apparently it starts waiting for the token). 4. It is said that PKCS11 "defines a platform-independent API to cryptographic tokens, such as Hardware Security Modules (HSM) and smart cards." The point is: - there is no cryptographic hardware involved in my case - Tomcat default configuration used, HTTPS connector disabled - no tc native - I don't want to use PKCS or any other crypto Nevertheless the threads show up and is spotted by the memory leak detection during manager shutdown/restart as belonging to the manager webapp (by means of the TCCL), although in the dump before the restart its TCCL was the system class loader and the thread also gets started when no manager gets deployed. My first priority is to remove the false positive for the leak detection, only the second prio is getting rid of the thread. Regards, Rainer - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r942526 - /tomcat/tc6.0.x/trunk/STATUS.txt
Author: kkolinko Date: Sun May 9 11:29:44 2010 New Revision: 942526 URL: http://svn.apache.org/viewvc?rev=942526&view=rev Log: vote Modified: tomcat/tc6.0.x/trunk/STATUS.txt Modified: tomcat/tc6.0.x/trunk/STATUS.txt URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/STATUS.txt?rev=942526&r1=942525&r2=942526&view=diff == --- tomcat/tc6.0.x/trunk/STATUS.txt (original) +++ tomcat/tc6.0.x/trunk/STATUS.txt Sun May 9 11:29:44 2010 @@ -198,8 +198,14 @@ PATCHES PROPOSED TO BACKPORT: * Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=48379 Make session cookie name, domain and path configurable per context. http://people.apache.org/~markt/patches/2010-05-05-bug48379.patch - +1: markt + +1: markt, kkolinko -1: + kkolinko: (Trivial: + in JvmRouteBinderValve#setNewSessionCookie() + in if (log.isDebugEnabled()) { ... } block + s/Globals.SESSION_COOKIE_NAME/newCookie.getName()/ + ) + * https://issues.apache.org/bugzilla/show_bug.cgi?id=49081 "#${1+1}" should evaluate to "#2" - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r942554 - /tomcat/trunk/test/org/apache/catalina/core/TestStandardContext.java
Author: markt Date: Sun May 9 16:12:41 2010 New Revision: 942554 URL: http://svn.apache.org/viewvc?rev=942554&view=rev Log: Fix FindBugs warning Modified: tomcat/trunk/test/org/apache/catalina/core/TestStandardContext.java Modified: tomcat/trunk/test/org/apache/catalina/core/TestStandardContext.java URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/catalina/core/TestStandardContext.java?rev=942554&r1=942553&r2=942554&view=diff == --- tomcat/trunk/test/org/apache/catalina/core/TestStandardContext.java (original) +++ tomcat/trunk/test/org/apache/catalina/core/TestStandardContext.java Sun May 9 16:12:41 2010 @@ -48,7 +48,9 @@ public class TestStandardContext extends Tomcat tomcat = getTomcatInstance(); File docBase = new File(tomcat.getHost().getAppBase(), "ROOT"); -docBase.mkdirs(); +if (!docBase.exists() && !docBase.mkdirs()) { +fail("Unable to create docBase"); +} Context root = tomcat.addContext("", "ROOT"); - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org