cvs commit: jakarta-tomcat/src/facade22/org/apache/tomcat/facade RequestDispatcherImpl.java

2004-09-30 Thread billbarker
billbarker2004/09/29 23:02:39

  Modified:src/facade22/org/apache/tomcat/facade
RequestDispatcherImpl.java
  Log:
  Set the correct query-string on forwards.
  
  The parameters are the sum of the forward URI and the request URI, but the 
query-string is the one from the forward URI according to the spec.
  
  This still needs some work to handle the post-request clean-up.
  
  Fix for Bug #31474
  Reported By: Marc Daniels  [EMAIL PROTECTED]
  
  Revision  ChangesPath
  1.29  +7 -5  
jakarta-tomcat/src/facade22/org/apache/tomcat/facade/RequestDispatcherImpl.java
  
  Index: RequestDispatcherImpl.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat/src/facade22/org/apache/tomcat/facade/RequestDispatcherImpl.java,v
  retrieving revision 1.28
  retrieving revision 1.29
  diff -u -r1.28 -r1.29
  --- RequestDispatcherImpl.java23 Feb 2004 06:06:13 -  1.28
  +++ RequestDispatcherImpl.java30 Sep 2004 06:02:39 -  1.29
  @@ -193,7 +193,7 @@
//realRequest.query().recycle();
realRequest.servletPath().recycle();
realRequest.pathInfo().recycle();
  -realRequest.setChild(null);
  + realRequest.setChild(null);
   
// merge query string as specified in specs - before, it may affect
// the way the request is handled by special interceptors
  @@ -201,11 +201,11 @@
// Process existing parameters, if not already done so
// ( otherwise we'll process some twice )
realRequest.parameters().handleQueryParameters();
  - // Set the query string - the sum of the new one and old one.
  + // Set the query string - the new one.
String oldQS=realRequest.queryString().toString();
  - String newQS=(oldQS==null ) ? queryString : queryString +  +
  - oldQS;
  - realRequest.queryString().setString(newQS);
  + // String newQS=(oldQS==null ) ? queryString : queryString +  +
  + //  oldQS;
  + realRequest.queryString().setString(queryString);
   
// Process the additional parsm. We don't know if the old
// params were processed ( so we need to make sure they are,
  @@ -215,6 +215,8 @@
   
child.processParameters( queryString );
//realRequest.parameters().processParameters( queryString ); 
  + } else {
  + realRequest.queryString().recycle();
}

// run the new request through the context manager
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31474] - URL query string attribute duplication when using forward method

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31474.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31474

URL query string attribute duplication when using forward method

[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||FIXED



--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 06:05 ---
Fix now in the CVS.

Thanks for the report!

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31473] - Windows installer for tomcat 5.5 mess up with tomcat 5.0 service

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31473.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31473

Windows installer for tomcat 5.5 mess up with tomcat 5.0 service

[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
  everconfirmed|0   |1



--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 07:28 ---
The same problem here.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



321greetings auto responder

2004-09-30 Thread list
Hi,

Due to the amount of e-mails we get per day we have setup this auto responder for your 
convenience.  
This is not a monitored e-mail address

To unsubscribe 
http://321greetings.com/unsubscribenewlist.htm
a href=\ http://321greetings.com/unsubscribenewlist.htm \ AOL Link /a

To subscribe please go here:
http://321greetings.com/sub321greetings-newsletter.htm
a href=\ http://321greetings.com/sub321greetings-newsletter.htm \ AOL Link /a


If you need technical assistance, please go here:
http://321greetings.com/contactus.htm
a href=\ http://321greetings.com/contactus.htm \ AOL-link /a



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31475] - resouce-ref does not refer to the server data resource

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31475.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31475

resouce-ref does not refer to the server data resource

[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||INVALID



--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 08:10 ---
We're indeed going to require the ResourceLink in this case. You don't have to
remove your resource-ref, though.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Mike Duffy/Oshkosh/Fonda is out of the office.

2004-09-30 Thread Mike Duffy
I will be out of the office starting Thu 09/30/2004 and will not return
until Mon 10/04/2004.

I will be on vacation on Thurs Sept 30  Friday Oct 1, returning to the
office on Monday Oct 4.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31480] New: - Tomcat 5.5.1 not downloadable!

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31480.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31480

Tomcat 5.5.1 not downloadable!

   Summary: Tomcat 5.5.1 not downloadable!
   Product: Tomcat 5
   Version: 5.5.1
  Platform: All
   URL: http://jakarta.apache.org/site/binindex.cgi
OS/Version: All
Status: NEW
  Severity: Blocker
  Priority: Other
 Component: Unknown
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]


Only tomcat 5.5.2-alpha is downloadable, it would be nice to have a stable 5.5
available for download also

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31480] - Tomcat 5.5.1 not downloadable!

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31480.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31480

Tomcat 5.5.1 not downloadable!

[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||INVALID



--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 09:29 ---
5.5.0 and 5.5.1 are alpha releases. Sorry, it wasn't written obviously enough.
5.5.2 is an ok build if you don't need the admin webapp and the Ant deploy task,
and might be upgraded to beta.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31482] New: - HttpSession loses attributes if cross context is set to true

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31482.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31482

HttpSession loses attributes if cross context is set to true

   Summary: HttpSession loses attributes if cross context is set to
true
   Product: Tomcat 5
   Version: 5.0.28
  Platform: PC
OS/Version: Windows XP
Status: NEW
  Severity: Normal
  Priority: Other
 Component: Catalina
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]


Hallo,

I am using Tomcat 5 to run two webapplications. For both contexts I set cross 
context to true. In one webapplication I put some attributes in the session and 
use a RequestDispatcher to pass the request to the other webapplication. There 
I need to get these attributes out of the session. This worked with Tomcat 4 
but is not working any more with Tomcat 5. I looked in the source code and 
found the problem in the class org.apache.catalina.core.ApplicationHttpRequest. 
There is the function HttpSession getSession(boolean create) that overrides the 
same function of the super class. In Tomcat 4 this function was not overriden 
an thats why you got the exact same session object that you had in the other 
context. In Tomcat 5 now there is in this function getSession(boolean create) a 
new session object created (line 503) that gets only the same session id as the 
original session of the other context. That means that this session has not my 
attributes any more which I had put in the session in the other context.
For me it is unclear why this function is overriden in this way. I commented 
this function out and recompiled the class. Whith this it is working again. 
I think that should be fixed.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31341] - getting javac java.lang.OutOfMemoryError after org.apache.jasper.JspC name=jasper2 when precompiling jsps

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31341.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31341

getting javac java.lang.OutOfMemoryError after org.apache.jasper.JspC name=jasper2 
when precompiling jsps





--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 12:35 ---
It looks like this bug happens when the application workDir has a long name. I
tried changing to c:\work and the error stopped.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31485] New: - setclasspath.sh: JAVA_ENDORSED_DIRS should be extended with `$JAVA_HOME/jre/lib/endorsed`

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31485.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31485

setclasspath.sh: JAVA_ENDORSED_DIRS should be extended with 
`$JAVA_HOME/jre/lib/endorsed`

   Summary: setclasspath.sh: JAVA_ENDORSED_DIRS should be extended
with `$JAVA_HOME/jre/lib/endorsed`
   Product: Tomcat 5
   Version: 5.0.28
  Platform: Other
OS/Version: Linux
Status: NEW
  Severity: Minor
  Priority: Other
 Component: Unknown
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]


When using newer versions of jars (e.g. Xerces) than those delivered with the JDK,
you normally place them into `$JAVA_HOME/jre/lib/endorsed`. Tomcat
does not acknowledge these but replaces JAVA_ENDORSED_DIRS with
`$BASEDIR/common/endorsed`.

When changing this to:
JAVA_ENDORSED_DIRS=$BASEDIR/common/endorsed:$JAVA_HOME/jre/lib/endorsed
you only have to place the new jars in one dir.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31482] - HttpSession loses attributes if cross context is set to true

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31482.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31482

HttpSession loses attributes if cross context is set to true

[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||WORKSFORME



--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 15:03 ---
This change was done on purpose: the intent of crossContext is not to allow 
complete session sharing.  It's for dispatching across web applications.  If 
you need to pass attributes, you can put them in the request or response, and 
they will be passed around.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31485] - setclasspath.sh: JAVA_ENDORSED_DIRS should be extended with `$JAVA_HOME/jre/lib/endorsed`

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31485.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31485

setclasspath.sh: JAVA_ENDORSED_DIRS should be extended with 
`$JAVA_HOME/jre/lib/endorsed`

[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||WONTFIX



--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 15:04 ---
We don't want to much with the user's JDK installation.  So we provide another 
location, $CATALINA_HOME/common/endorsed, where they can take advantage of 
Java's endorsed classloading mechanism.  This approach is safe, effective, and 
fairly standard in that numerous other containers apply it.  If you want to 
modify your own startup script, you're obviously free to do so, but the default 
Tomcat scripts will refer to $CATALINA_HOME/common/endorsed.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 26372] - java.lang.ThreadDeath when trwaing to reload an application

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=26372.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=26372

java.lang.ThreadDeath when trwaing to reload an application





--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 15:05 ---
Unless I hear that the combination of solutions offered in this thread does not 
address this problem, I will close this issue as WORKFORME soon.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31473] - Windows installer for tomcat 5.5 mess up with tomcat 5.0 service

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31473.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31473

Windows installer for tomcat 5.5 mess up with tomcat 5.0 service

[EMAIL PROTECTED] changed:

   What|Removed |Added

   Severity|Minor   |Enhancement
  Component|Unknown |Native:Integration
   Priority|Other   |Low



--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 15:07 ---
Changing Severity to Enhancement and Componet to Native:Integration.  If you 
feel like submitting a patch that makes your request possible, that'd be great.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31447] - Contribution: system daemon script for GNU/Linux

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31447.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31447

Contribution: system daemon script for GNU/Linux





--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 15:10 ---
I wonder what the proper CVS location for this is.  jakarta-tomcat-
catalina/catalina/src/bin might be the place, but I'm thinking we might need a 
new contrib directory for some other OS-specific scripts we're getting via the 
mailing list.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 26372] - java.lang.ThreadDeath when trwaing to reload an application

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=26372.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=26372

java.lang.ThreadDeath when trwaing to reload an application





--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 15:12 ---

A couple of questions:

1) Does it actually work for you?
2) Does it work for Allistair Crossley ?
3) Wouldn't closing the report hide or obfuscate the information contained herein?

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 26372] - java.lang.ThreadDeath when trwaing to reload an application

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=26372.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=26372

java.lang.ThreadDeath when trwaing to reload an application





--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 15:17 ---
I'm on it. Will let you know ASAP what the outcome of Introspector.flushCaches
() is on this bug.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core ApplicationContextFacade.java ApplicationFilterChain.java StandardWrapper.java

2004-09-30 Thread jfarcand
jfarcand2004/09/30 08:26:21

  Modified:catalina/src/share/org/apache/catalina/core
ApplicationContextFacade.java
ApplicationFilterChain.java StandardWrapper.java
  Log:
  Avoid creating objects on every call since it clearly produces a memory leak when 
the SecurityManager is turned on. All Tcks passed except there is two jsp regressions:
  
  com/sun/ts/tests/jsp/spec/i18n/URLClient.java#i18nEncodingMismatchTest: Failed. Test 
case throws exception: [BaseUrlClient] null failed!  Check output for cause of failure.
  Test finished: 
com/sun/ts/tests/jsp/spec/configuration/encoding/URLClient.java#jspConfigurationDifferentEncodingTest:
 Failed. Test case throws exception: [BaseUrlClient] null failed!  Check output for 
cause of failure.
  
  The same exceptions occurs when the SecurityManager is turned off.
  
  Revision  ChangesPath
  1.11  +55 -28
jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/ApplicationContextFacade.java
  
  Index: ApplicationContextFacade.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/ApplicationContextFacade.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- ApplicationContextFacade.java 26 May 2004 15:36:14 -  1.10
  +++ ApplicationContextFacade.java 30 Sep 2004 15:26:20 -  1.11
  @@ -52,8 +52,13 @@
   /**
* Cache Class object used for reflection.
*/
  -private HashMap classCache;
  +private static HashMap classCache = new HashMap();
   
  +static {
  +if (System.getSecurityManager() != null) {
  +initClassCache();
  +}
  +}
   
   /**
* Cache method object.
  @@ -64,7 +69,13 @@
   private static org.apache.commons.logging.Log sysLog=
   org.apache.commons.logging.LogFactory.getLog( 
ApplicationContextFacade.class );
   
  -
  +
  +/**
  + * Object repository used when the SecurityManager is turned on and
  + * Filter.doFilter is invoked.
  + */
  +private Object[] objectArg = new Object[1];
  +private Object[] objectArgs = new Object[2];
   // --- Constructors
   
   
  @@ -78,13 +89,12 @@
   super();
   this.context = context;
   
  -classCache = new HashMap();
   objectCache = new HashMap();
  -initClassCache();
  +
   }
   
   
  -private void initClassCache(){
  +private static void initClassCache(){
   Class[] clazz = new Class[]{String.class};
   classCache.put(getContext, clazz);
   classCache.put(getMimeType, clazz);
  @@ -119,8 +129,8 @@
   public ServletContext getContext(String uripath) {
   ServletContext theContext = null;
   if (System.getSecurityManager() != null) {
  -theContext = (ServletContext)
  -doPrivileged(getContext, new Object[]{uripath});
  +objectArg[0] = uripath; 
  +theContext = (ServletContext)doPrivileged(getContext, objectArg);
   } else {
   theContext = context.getContext(uripath);
   }
  @@ -144,7 +154,8 @@
   
   public String getMimeType(String file) {
   if (System.getSecurityManager() != null) {
  -return (String)doPrivileged(getMimeType, new Object[]{file});
  +objectArg[0] = file;
  +return (String)doPrivileged(getMimeType, objectArg);
   } else {
   return context.getMimeType(file);
   }
  @@ -153,7 +164,8 @@
   
   public Set getResourcePaths(String path) {
   if (System.getSecurityManager() != null){
  -return (Set)doPrivileged(getResourcePaths, new Object[]{path});
  +objectArg[0] = path;
  +return (Set)doPrivileged(getResourcePaths, objectArg);
   } else {
   return context.getResourcePaths(path);
   }
  @@ -164,8 +176,9 @@
   throws MalformedURLException {
   if (System.getSecurityManager() != null) {
   try {
  +objectArg[0] = path;
   return (URL) invokeMethod(context, getResource, 
  -  new Object[]{path});
  +  objectArg);
   } catch(Throwable t) {
   if (t instanceof MalformedURLException){
   throw (MalformedURLException)t;
  @@ -180,8 +193,9 @@
   
   public InputStream getResourceAsStream(String path) {
   if (System.getSecurityManager() != null) {
  +objectArg[0] = path;
   return (InputStream) doPrivileged(getResourceAsStream, 
  -  new Object[]{path});
  +   

cvs commit: jakarta-tomcat-catalina/webapps/docs changelog.xml

2004-09-30 Thread jfarcand
jfarcand2004/09/30 08:28:13

  Modified:webapps/docs changelog.xml
  Log:
  Add memory leak info.
  
  Revision  ChangesPath
  1.122 +3 -0  jakarta-tomcat-catalina/webapps/docs/changelog.xml
  
  Index: changelog.xml
  ===
  RCS file: /home/cvs/jakarta-tomcat-catalina/webapps/docs/changelog.xml,v
  retrieving revision 1.121
  retrieving revision 1.122
  diff -u -r1.121 -r1.122
  --- changelog.xml 29 Sep 2004 19:06:53 -  1.121
  +++ changelog.xml 30 Sep 2004 15:28:12 -  1.122
  @@ -36,6 +36,9 @@
 subsection name=Catalina
   changelog
 fix
  +Fix memory leak when Security Manager is turned on. (jfarcand)
  +  /fix
  +  fix
   When checking status codes for error handling, only check if
   Response.isError() is true. This way, users may use setStatus() to set 
their own
   error status without having the error page invoked. (in which case, the 
user should've
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: jakarta-tomcat-catalina/webapps/docs changelog.xml

2004-09-30 Thread luehe
luehe   2004/09/30 08:58:32

  Modified:webapps/docs changelog.xml
  Log:
  Fixed StandardContext.getStartTime(), and exposed it in Manager's status page
  
  Revision  ChangesPath
  1.123 +6 -0  jakarta-tomcat-catalina/webapps/docs/changelog.xml
  
  Index: changelog.xml
  ===
  RCS file: /home/cvs/jakarta-tomcat-catalina/webapps/docs/changelog.xml,v
  retrieving revision 1.122
  retrieving revision 1.123
  diff -u -r1.122 -r1.123
  --- changelog.xml 30 Sep 2004 15:28:12 -  1.122
  +++ changelog.xml 30 Sep 2004 15:58:32 -  1.123
  @@ -75,6 +75,9 @@
fix
  bug30949/bug: Make sure ApplicationDispatcher unwraps request/response 
even if include error occurs. (yoavs)
/fix
  +  fix
  +Fixed StandardContext.getStartTime() to return actual start time/date 
instead of time (startupTime) it took to start context. (luehe)
  +  /fix
   /changelog
 /subsection
   
  @@ -119,6 +122,9 @@
 fix
   bug31058/bug: Ensure StatusTransformer escapes query string for XML. 
(yoavs)
 /fix
  +  update
  +Added contexts' start time (available from 'startTime' MBean attribute of 
StandardContext) to status page (luehe)
  +  /update
   /changelog
 /subsection
   /section
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: jakarta-tomcat-catalina/webapps/docs changelog.xml

2004-09-30 Thread jfarcand
jfarcand2004/09/30 09:02:36

  Modified:webapps/docs Tag: TOMCAT_5_0 changelog.xml
  Log:
  Port patch
  
  Revision  ChangesPath
  No   revision
  No   revision
  1.70.2.46 +3 -0  jakarta-tomcat-catalina/webapps/docs/changelog.xml
  
  Index: changelog.xml
  ===
  RCS file: /home/cvs/jakarta-tomcat-catalina/webapps/docs/changelog.xml,v
  retrieving revision 1.70.2.45
  retrieving revision 1.70.2.46
  diff -u -r1.70.2.45 -r1.70.2.46
  --- changelog.xml 29 Sep 2004 18:02:21 -  1.70.2.45
  +++ changelog.xml 30 Sep 2004 16:02:36 -  1.70.2.46
  @@ -38,6 +38,9 @@
   configure the port. (funkman)
 /update
 fix
  +Fix memory leak when Security Manager is turned on. (jfarcand)
  +  /fix
  +  fix
   bug28914/bug: threadPriority attribute ignored. (yoavs)
 /fix
 fix
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: cvs commit: jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core ApplicationContextFacade.java ApplicationFilterChain.java StandardWrapper.java

2004-09-30 Thread Bill Barker
   @@ -1012,13 +1041,12 @@
DummyResponse res = new DummyResponse();

if( System.getSecurityManager() != null) {
   -Class[] classType = new
Class[]{ServletRequest.class,
   -
ServletResponse.class};
   -Object[] args = new Object[]{req, res};
   +serviceType[0] = req;
   +serviceType[1] = res;
SecurityUtil.doAsPrivilege(service,
   servlet,
   -   classType,
   -   args);
   +
classTypeUsedInService,
   +   serviceType);
} else {
servlet.service(req, res);
}



This can't possibly be thread-safe (and the changes to ACF look dubious as
well).


This message is intended only for the use of the person(s) listed above as the 
intended recipient(s), and may contain information that is PRIVILEGED and 
CONFIDENTIAL.  If you are not an intended recipient, you may not read, copy, or 
distribute this message or any attachment. If you received this communication in 
error, please notify us immediately by e-mail and then delete all copies of this 
message and any attachments.

In addition you should be aware that ordinary (unencrypted) e-mail sent through the 
Internet is not secure. Do not send confidential or sensitive information, such as 
social security numbers, account numbers, personal identification numbers and 
passwords, to us via ordinary (unencrypted) e-mail.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Re: Re: cvs commit: jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core ApplicationContextFacade.java ApplicationFilterChain.java StandardWrapper.java

2004-09-30 Thread jansdell
I am out of the office until Monday 4 October.

If your enquiry is urgent please contact [EMAIL PROTECTED], otherwise I will get back 
to you on my return. 

Best Regards,
Jim Ansdell
See (Nottingham)
dl: 0115 9129179
f: 0115 9484345









-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31495] New: - Context reload causes ClusterManager to stop operating

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31495.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31495

Context reload causes ClusterManager to stop operating

   Summary: Context reload causes ClusterManager to stop operating
   Product: Tomcat 5
   Version: 5.0.28
  Platform: PC
OS/Version: Linux
Status: NEW
  Severity: Major
  Priority: Other
 Component: Catalina:Cluster
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]


A functioning clustered application works fine when the tomcat server is
initially started.  Sessions are replicated, etc.

As soon as the context is reloaded on one server, the sessions are no longer
replicated between servers.  A full tomcat restart is required to restore this
functionality.

The application and configuration are known to be functional, and the problem
does not occur on 5.0.25.  The problem only occurs on our 5.0.28 installation. 
We have downgraded our installation to verify this, and the same functionality
that does not work properly on 5.0.28 does in fact work on 5.0.25.

There is a thread with the subject of Clustering and session replication in
the tomcat-users mailing list, starting on 9/29/2004.

All relevant output is below:
--Host A catalina.out from context reload--
Sep 29, 2004 3:47:26 PM org.apache.catalina.cluster.session.DeltaManager
start
WARNING: Manager[/nahrgisdev], requesting session state from
org.apache.catalina.cluster.mcast.McastMember[tcp://10.0.0.2:4001,
10.0.0.2,4001, alive=253140]. This operation will timeout if no
session state has been received within 60 seconds
Sep 29, 2004 3:48:26 PM org.apache.catalina.cluster.session.DeltaManager
start
SEVERE: Manager[/nahrgisdev], No session state received, timing out.

--Host B catalina.out from context reload--
Sep 29, 2004 3:50:16 PM org.apache.catalina.cluster.session.DeltaManager start
WARNING: Manager[/nahrgisdev], requesting session state from
org.apache.catalina.cluster.mcast.McastMember[tcp://10.0.0.1:4001,10.0.0.1,4001,
alive=681060]. This operation will timeout if no session state has been received
within 60 seconds
Sep 29, 2004 3:50:16 AM org.apache.catalina.cluster.session.DeltaManager start
INFO: Manager[/nahrgisdev], session state received in 109 ms.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31497] New: - Tomcat and JAXB

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31497.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31497

Tomcat and JAXB

   Summary: Tomcat and JAXB
   Product: Tomcat 5
   Version: 5.0.1
  Platform: PC
OS/Version: Other
Status: NEW
  Severity: Normal
  Priority: Other
 Component: Servlet  JSP API
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]


Classloader problem for JAXB working under the Tomcat environment.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31497] - Tomcat and JAXB

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31497.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31497

Tomcat and JAXB

[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||INVALID



--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 19:11 ---
Please provide precise details of your problems, including a test case or other 
instructions so we can reproduce it.  Without these, there's no problem.

Even if you have these instructions, I encourage you to raise and discuss the 
problem on the mailing list first to ensure you're not just misconfiguring 
something, before opening a Bugzilla issue.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 28727] - CLOSE_WAIT connections draw 100 % cpu

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=28727.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=28727

CLOSE_WAIT connections draw 100 % cpu





--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 19:12 ---
Please keep us posted ;)  I don't want to leave the issue open forever without 
us being able to reproduce it.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core StandardContext.java

2004-09-30 Thread luehe
luehe   2004/09/30 12:29:04

  Modified:catalina/src/share/org/apache/catalina/core
StandardContext.java
  Log:
  Reset startup/start/tldScanTime to 0 in resetContext()
  
  Revision  ChangesPath
  1.149 +4 -1  
jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/StandardContext.java
  
  Index: StandardContext.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/StandardContext.java,v
  retrieving revision 1.148
  retrieving revision 1.149
  diff -u -r1.148 -r1.149
  --- StandardContext.java  29 Sep 2004 21:07:05 -  1.148
  +++ StandardContext.java  30 Sep 2004 19:29:04 -  1.149
  @@ -4415,6 +4415,9 @@
   // Restore the original state ( pre reading web.xml in start )
   // If you extend this - override this method and make sure to clean up
   children=new HashMap();
  +startupTime = 0;
  +startTime = 0;
  +tldScanTime = 0;
   log.debug(resetContext  + oname +   + mserver);
   }
   
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: cvs commit: jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core ApplicationContextFacade.java ApplicationFilterChain.java StandardWrapper.java

2004-09-30 Thread Jean-Francois Arcand

Bill Barker wrote:
 @@ -1012,13 +1041,12 @@
  DummyResponse res = new DummyResponse();
  if( System.getSecurityManager() != null) {
 -Class[] classType = new
Class[]{ServletRequest.class,
 -
ServletResponse.class};
 -Object[] args = new Object[]{req, res};
 +serviceType[0] = req;
 +serviceType[1] = res;
  SecurityUtil.doAsPrivilege(service,
 servlet,
 -   classType,
 -   args);
 +
classTypeUsedInService,
 +   serviceType);
  } else {
  servlet.service(req, res);
  }


This can't possibly be thread-safe (and the changes to ACF look dubious as
well).
Hum...I did run a lot of stress tests that target the same servlet (ex: 
trade2 benchmarks) without seeing anything like that.  I will 
investigate




This message is intended only for the use of the person(s) listed above as the 
intended recipient(s), and may contain information that is PRIVILEGED and 
CONFIDENTIAL.  If you are not an intended recipient, you may not read, copy, or 
distribute this message or any attachment. If you received this communication in 
error, please notify us immediately by e-mail and then delete all copies of this 
message and any attachments.
In addition you should be aware that ordinary (unencrypted) e-mail sent through the 
Internet is not secure. Do not send confidential or sensitive information, such as 
social security numbers, account numbers, personal identification numbers and 
passwords, to us via ordinary (unencrypted) e-mail.


-
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]


DO NOT REPLY [Bug 31499] New: - Contributing catalina launcher for OpenVMS Alpha

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31499.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31499

Contributing catalina launcher for OpenVMS Alpha

   Summary: Contributing catalina launcher for OpenVMS Alpha
   Product: Tomcat 5
   Version: 5.0.28
  Platform: Alpha
OS/Version: Other
Status: NEW
  Severity: Normal
  Priority: Other
 Component: Catalina
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]
CC: [EMAIL PROTECTED],[EMAIL PROTECTED]


We would like to contribute a Tomcat launcher (catalina.com) and java setup 
script (tomcat_setup_java.com) for OpenVMS Alpha.  These are needed by 
NetBeans for use in testing and debugging JSPs from within the IDE. 

If you're willing to accept them, I'll attach them here.

Note, they must be placed in the CVS library with the binary substitution 
switch -Kb.   Otherwise, they will have the wrong format on OpenVMS.

We're willing to keep our eyes on the dev and user groups in case there are 
any problems/questions.


Thanks,
Meg Garrison/Isao Yanagimachi
Hewlett-Packard 
OpenVMS Systems Software Group

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 28727] - CLOSE_WAIT connections draw 100 % cpu

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=28727.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=28727

CLOSE_WAIT connections draw 100 % cpu





--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 20:31 ---
Tomcat calls close on all the sockets, in a very obvious way. After that, if the
socket isn't properly closed, then it's a bug in either the VM or the network stack.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31499] - Contributing catalina launcher for OpenVMS Alpha

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31499.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31499

Contributing catalina launcher for OpenVMS Alpha





--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 20:33 ---
Created an attachment (id=12914)
Tomcat catalina launcher for OpenVMS... should go in /bin with other launchers

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31499] - Contributing catalina launcher for OpenVMS Alpha

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31499.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31499

Contributing catalina launcher for OpenVMS Alpha





--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 20:34 ---
Created an attachment (id=12915)
Java setup script for Tomcat on OpenVMS - should go in .bin directory with catalina.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 31398] - StandardWrapperValve logging

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=31398.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=31398

StandardWrapperValve logging

[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||FIXED



--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 20:44 ---
This is fixed in 4.1.28 onwards.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: cvs commit: jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core ApplicationContextFacade.java ApplicationFilterChain.java StandardWrapper.java

2004-09-30 Thread Remy Maucherat
Jean-Francois Arcand wrote:
Bill Barker wrote:
This can't possibly be thread-safe (and the changes to ACF look 
dubious as
well).
Hum...I did run a lot of stress tests that target the same servlet 
(ex: trade2 benchmarks) without seeing anything like that.  I will 
investigate
I think there will be thread safety problems too. There's no way around 
instantiating argument arrays here.
I also think the shared classCache is not useful. I don't see why 
objectCache couldn't be static, so it could be the only cache.

Rémy
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


DO NOT REPLY [Bug 28631] - JAASRealm fix to permit user-specified user/group Principals

2004-09-30 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
http://issues.apache.org/bugzilla/show_bug.cgi?id=28631.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=28631

JAASRealm fix to permit user-specified user/group Principals

[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|RESOLVED|REOPENED
 Resolution|FIXED   |



--- Additional Comments From [EMAIL PROTECTED]  2004-09-30 21:54 ---
It looks like the most recent commit of JAASRealm has a slight problem in it. 

The whole-file version I submitted has these lines, starting at line 536:

if (userPrincipal == null  userClasses.contains(principalClass)) {
userPrincipal = principal;
if( log.isDebugEnabled() ) {
log.debug(sm.getString(jaasRealm.userPrincipalSuccess, 
principal.getName()));
}
}
if (roleClasses.contains(principalClass)) {
roles.add(principal);
if( log.isDebugEnabled() ) {
log.debug(sm.getString(jaasRealm.rolePrincipalAdd, 
principal.getName()));
}
}

The current file in HEAD looks like this (also starting at 536):

if (userPrincipal == null  userClasses.contains(principalClass)) {
userPrincipal = principal;
if( log.isDebugEnabled() ) {
log.debug(sm.getString(jaasRealm.userPrincipalSuccess, 
principal.getName()));
}
}

if (roleClasses.contains(principalClass)) {
roles.add(principal.getName());
}

if (roleClasses.contains(principalClass)) {
roles.add(principal);
if( log.isDebugEnabled() ) {
log.debug(sm.getString(jaasRealm.rolePrincipalAdd, 
principal.getName()));
}
}

The middle chunk of code (3 lines) shouldn't be there. It is adding a String to what 
is supposed to be a 
collection of Principal objects. This is causing downstream calls to 
hasRole(Principal, String) to choke 
and die with a ClassCastException.

The patch file I submitted also has this middle chunk marked for removal (-), so I 
think this was just a 
mistake in the commit process.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/xmlparser XMLEncodingDetector.java

2004-09-30 Thread luehe
luehe   2004/09/30 14:57:09

  Modified:jasper2/src/share/org/apache/jasper/xmlparser
XMLEncodingDetector.java
  Log:
  Log warning when XML prolog cannot be parsed.
  
  The 2 JSP TCK failures reported by Jeanfrancois are due to this, with
  this root cause:
  
java.lang.ClassNotFoundException: org.apache.xerces.util.SymbolTable
  
  Revision  ChangesPath
  1.8   +6 -1  
jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/xmlparser/XMLEncodingDetector.java
  
  Index: XMLEncodingDetector.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/xmlparser/XMLEncodingDetector.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- XMLEncodingDetector.java  17 Mar 2004 19:23:05 -  1.7
  +++ XMLEncodingDetector.java  30 Sep 2004 21:57:09 -  1.8
  @@ -23,9 +23,13 @@
   import org.apache.jasper.JspCompilationContext;
   import org.apache.jasper.compiler.ErrorDispatcher;
   
  +import org.apache.commons.logging.Log;
  +import org.apache.commons.logging.LogFactory;
   
   public class XMLEncodingDetector {
   
  +private static Log log = LogFactory.getLog(XMLEncodingDetector.class);
  +
   /**
* Autodetects the encoding of the XML document supplied by the given
* input stream.
  @@ -51,7 +55,8 @@
   Class.forName(org.apache.xerces.util.SymbolTable);
   Class 
detectorClass=Class.forName(org.apache.jasper.xmlparser.XercesEncodingDetector);
   detector = (XMLEncodingDetector) detectorClass.newInstance();
  -} catch(Exception ex ) {
  +} catch (Exception ex) {
  +log.warn(Unable to parse XML prolog: Defaulting encoding to UTF8 , 
ex);
   detector = new XMLEncodingDetector();
   }
   return detector.getEncodingMethod(fname, jarFile, ctxt, err);
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/xmlparser XMLEncodingDetector.java

2004-09-30 Thread luehe
luehe   2004/09/30 15:03:57

  Modified:jasper2/src/share/org/apache/jasper/xmlparser
XMLEncodingDetector.java
  Log:
  Fixed formating
  
  Revision  ChangesPath
  1.9   +2 -1  
jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/xmlparser/XMLEncodingDetector.java
  
  Index: XMLEncodingDetector.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/xmlparser/XMLEncodingDetector.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- XMLEncodingDetector.java  30 Sep 2004 21:57:09 -  1.8
  +++ XMLEncodingDetector.java  30 Sep 2004 22:03:57 -  1.9
  @@ -56,7 +56,8 @@
   Class 
detectorClass=Class.forName(org.apache.jasper.xmlparser.XercesEncodingDetector);
   detector = (XMLEncodingDetector) detectorClass.newInstance();
   } catch (Exception ex) {
  -log.warn(Unable to parse XML prolog: Defaulting encoding to UTF8 , 
ex);
  +log.warn(Unable to parse XML prolog: Defaulting encoding to UTF8,
  + ex);
   detector = new XMLEncodingDetector();
   }
   return detector.getEncodingMethod(fname, jarFile, ctxt, err);
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: cvs commit: jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/xmlparser XMLEncodingDetector.java

2004-09-30 Thread Remy Maucherat
[EMAIL PROTECTED] wrote:
luehe   2004/09/30 14:57:09
 Modified:jasper2/src/share/org/apache/jasper/xmlparser
   XMLEncodingDetector.java
 Log:
 Log warning when XML prolog cannot be parsed.
 
 The 2 JSP TCK failures reported by Jeanfrancois are due to this, with
 this root cause:
 
   java.lang.ClassNotFoundException: org.apache.xerces.util.SymbolTable
 

We don't bundle Xerces anymore with the binaries, as Java 5 is supposed 
to be used. With JRE 1.4, the compat package must be added (it adds JMX 
and Xerces as endorsed).
I think this would explain the problem.

Rémy
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: cvs commit: jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/xmlparser XMLEncodingDetector.java

2004-09-30 Thread Jan Luehe
Remy Maucherat wrote:
[EMAIL PROTECTED] wrote:
luehe   2004/09/30 14:57:09
 Modified:jasper2/src/share/org/apache/jasper/xmlparser
   XMLEncodingDetector.java
 Log:
 Log warning when XML prolog cannot be parsed.
 
 The 2 JSP TCK failures reported by Jeanfrancois are due to this, with
 this root cause:
 
   java.lang.ClassNotFoundException: org.apache.xerces.util.SymbolTable
 

We don't bundle Xerces anymore with the binaries, as Java 5 is supposed 
to be used. With JRE 1.4, the compat package must be added (it adds JMX 
and Xerces as endorsed).
I think this would explain the problem.
Yes, it does. I yet have to find XML prolog parsing and encoding
autodetection support in JDK 1.5 (the equivalent of what Xerces used to
provide).
Jan

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


cvs commit: jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core ApplicationContextFacade.java ApplicationFilterChain.java StandardWrapper.java

2004-09-30 Thread jfarcand
jfarcand2004/09/30 18:10:17

  Modified:catalina/src/share/org/apache/catalina/core Tag: TOMCAT_5_0
ApplicationContextFacade.java
ApplicationFilterChain.java StandardWrapper.java
  Log:
  Rollback wrong logic.
  
  Revision  ChangesPath
  No   revision
  No   revision
  1.10.2.2  +28 -55
jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/ApplicationContextFacade.java
  
  Index: ApplicationContextFacade.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/ApplicationContextFacade.java,v
  retrieving revision 1.10.2.1
  retrieving revision 1.10.2.2
  diff -u -r1.10.2.1 -r1.10.2.2
  --- ApplicationContextFacade.java 30 Sep 2004 15:53:31 -  1.10.2.1
  +++ ApplicationContextFacade.java 1 Oct 2004 01:10:17 -   1.10.2.2
  @@ -52,13 +52,8 @@
   /**
* Cache Class object used for reflection.
*/
  -private static HashMap classCache = new HashMap();
  +private HashMap classCache;
   
  -static {
  -if (System.getSecurityManager() != null) {
  -initClassCache();
  -}
  -}
   
   /**
* Cache method object.
  @@ -69,13 +64,7 @@
   private static org.apache.commons.logging.Log sysLog=
   org.apache.commons.logging.LogFactory.getLog( 
ApplicationContextFacade.class );
   
  -
  -/**
  - * Object repository used when the SecurityManager is turned on and
  - * Filter.doFilter is invoked.
  - */
  -private Object[] objectArg = new Object[1];
  -private Object[] objectArgs = new Object[2];
  +
   // --- Constructors
   
   
  @@ -89,12 +78,13 @@
   super();
   this.context = context;
   
  +classCache = new HashMap();
   objectCache = new HashMap();
  -
  +initClassCache();
   }
   
   
  -private static void initClassCache(){
  +private void initClassCache(){
   Class[] clazz = new Class[]{String.class};
   classCache.put(getContext, clazz);
   classCache.put(getMimeType, clazz);
  @@ -129,8 +119,8 @@
   public ServletContext getContext(String uripath) {
   ServletContext theContext = null;
   if (System.getSecurityManager() != null) {
  -objectArg[0] = uripath; 
  -theContext = (ServletContext)doPrivileged(getContext, objectArg);
  +theContext = (ServletContext)
  +doPrivileged(getContext, new Object[]{uripath});
   } else {
   theContext = context.getContext(uripath);
   }
  @@ -154,8 +144,7 @@
   
   public String getMimeType(String file) {
   if (System.getSecurityManager() != null) {
  -objectArg[0] = file;
  -return (String)doPrivileged(getMimeType, objectArg);
  +return (String)doPrivileged(getMimeType, new Object[]{file});
   } else {
   return context.getMimeType(file);
   }
  @@ -164,8 +153,7 @@
   
   public Set getResourcePaths(String path) {
   if (System.getSecurityManager() != null){
  -objectArg[0] = path;
  -return (Set)doPrivileged(getResourcePaths, objectArg);
  +return (Set)doPrivileged(getResourcePaths, new Object[]{path});
   } else {
   return context.getResourcePaths(path);
   }
  @@ -176,9 +164,8 @@
   throws MalformedURLException {
   if (System.getSecurityManager() != null) {
   try {
  -objectArg[0] = path;
   return (URL) invokeMethod(context, getResource, 
  -  objectArg);
  +  new Object[]{path});
   } catch(Throwable t) {
   if (t instanceof MalformedURLException){
   throw (MalformedURLException)t;
  @@ -193,9 +180,8 @@
   
   public InputStream getResourceAsStream(String path) {
   if (System.getSecurityManager() != null) {
  -objectArg[0] = path;
   return (InputStream) doPrivileged(getResourceAsStream, 
  -  objectArg);
  +  new Object[]{path});
   } else {
   return context.getResourceAsStream(path);
   }
  @@ -204,9 +190,8 @@
   
   public RequestDispatcher getRequestDispatcher(final String path) {
   if (System.getSecurityManager() != null) {
  -objectArg[0] = path;
   return (RequestDispatcher) doPrivileged(getRequestDispatcher, 
  -objectArg);
  +

cvs commit: jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core ApplicationContextFacade.java ApplicationFilterChain.java StandardWrapper.java

2004-09-30 Thread jfarcand
jfarcand2004/09/30 18:18:12

  Modified:catalina/src/share/org/apache/catalina/core
ApplicationContextFacade.java
ApplicationFilterChain.java StandardWrapper.java
  Log:
  Rollback wrong logic.
  
  Revision  ChangesPath
  1.12  +28 -55
jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/ApplicationContextFacade.java
  
  Index: ApplicationContextFacade.java
  ===
  RCS file: 
/home/cvs/jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core/ApplicationContextFacade.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- ApplicationContextFacade.java 30 Sep 2004 15:26:20 -  1.11
  +++ ApplicationContextFacade.java 1 Oct 2004 01:18:12 -   1.12
  @@ -52,13 +52,8 @@
   /**
* Cache Class object used for reflection.
*/
  -private static HashMap classCache = new HashMap();
  +private HashMap classCache;
   
  -static {
  -if (System.getSecurityManager() != null) {
  -initClassCache();
  -}
  -}
   
   /**
* Cache method object.
  @@ -69,13 +64,7 @@
   private static org.apache.commons.logging.Log sysLog=
   org.apache.commons.logging.LogFactory.getLog( 
ApplicationContextFacade.class );
   
  -
  -/**
  - * Object repository used when the SecurityManager is turned on and
  - * Filter.doFilter is invoked.
  - */
  -private Object[] objectArg = new Object[1];
  -private Object[] objectArgs = new Object[2];
  +
   // --- Constructors
   
   
  @@ -89,12 +78,13 @@
   super();
   this.context = context;
   
  +classCache = new HashMap();
   objectCache = new HashMap();
  -
  +initClassCache();
   }
   
   
  -private static void initClassCache(){
  +private void initClassCache(){
   Class[] clazz = new Class[]{String.class};
   classCache.put(getContext, clazz);
   classCache.put(getMimeType, clazz);
  @@ -129,8 +119,8 @@
   public ServletContext getContext(String uripath) {
   ServletContext theContext = null;
   if (System.getSecurityManager() != null) {
  -objectArg[0] = uripath; 
  -theContext = (ServletContext)doPrivileged(getContext, objectArg);
  +theContext = (ServletContext)
  +doPrivileged(getContext, new Object[]{uripath});
   } else {
   theContext = context.getContext(uripath);
   }
  @@ -154,8 +144,7 @@
   
   public String getMimeType(String file) {
   if (System.getSecurityManager() != null) {
  -objectArg[0] = file;
  -return (String)doPrivileged(getMimeType, objectArg);
  +return (String)doPrivileged(getMimeType, new Object[]{file});
   } else {
   return context.getMimeType(file);
   }
  @@ -164,8 +153,7 @@
   
   public Set getResourcePaths(String path) {
   if (System.getSecurityManager() != null){
  -objectArg[0] = path;
  -return (Set)doPrivileged(getResourcePaths, objectArg);
  +return (Set)doPrivileged(getResourcePaths, new Object[]{path});
   } else {
   return context.getResourcePaths(path);
   }
  @@ -176,9 +164,8 @@
   throws MalformedURLException {
   if (System.getSecurityManager() != null) {
   try {
  -objectArg[0] = path;
   return (URL) invokeMethod(context, getResource, 
  -  objectArg);
  +  new Object[]{path});
   } catch(Throwable t) {
   if (t instanceof MalformedURLException){
   throw (MalformedURLException)t;
  @@ -193,9 +180,8 @@
   
   public InputStream getResourceAsStream(String path) {
   if (System.getSecurityManager() != null) {
  -objectArg[0] = path;
   return (InputStream) doPrivileged(getResourceAsStream, 
  -  objectArg);
  +  new Object[]{path});
   } else {
   return context.getResourceAsStream(path);
   }
  @@ -204,9 +190,8 @@
   
   public RequestDispatcher getRequestDispatcher(final String path) {
   if (System.getSecurityManager() != null) {
  -objectArg[0] = path;
   return (RequestDispatcher) doPrivileged(getRequestDispatcher, 
  -objectArg);
  +new Object[]{path});
   } else {
   return 

Document

2004-09-30 Thread mikeb
--  Virus Warning Message (on uusnwa0p)

Found virus WORM_NETSKY.Z in file Bill.txt 
   
 .exe (in Bill.zip)
The file is deleted.

-
Important bill!


--  Virus Warning Message (on uusnwa0p)

Bill.zip is removed from here because it contains a virus.

-
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Re: cvs commit: jakarta-tomcat-catalina/catalina/src/share/org/apache/catalina/core ApplicationContextFacade.java ApplicationFilterChain.java StandardWrapper.java

2004-09-30 Thread Jean-Francois Arcand

Remy Maucherat wrote:
Jean-Francois Arcand wrote:
Bill Barker wrote:
This can't possibly be thread-safe (and the changes to ACF look 
dubious as
well).

Hum...I did run a lot of stress tests that target the same servlet 
(ex: trade2 benchmarks) without seeing anything like that.  I will 
investigate

I think there will be thread safety problems too. There's no way around 
instantiating argument arrays here.
I agree. I've reverted the patch. The only solution will be to 
nulllify all objects after every calls.


I also think the shared classCache is not useful. I don't see why 
objectCache couldn't be static, so it could be the only cache.
OK will take a look.
Thanks
-- Jeanfrancois

Rémy
-
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]