tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 33106] - SSI Processing Enhancements (patch provided)
Date Thu, 21 Apr 2005 21:33:05 GMT
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=33106>.
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=33106





------- Additional Comments From markt@apache.org  2005-04-21 23:33 -------
Almost there, but one slight glitch. After the SSI processing, the
content-length header and the actual content length are different. This causes
problems for both FireFox and IE. The easiest way to see it is to do an SSI
include of a file containing a single character.

When I do commit your patch, I intend to include the following changes unless
you know of a reason not to:
SSIServlet
  - Not deprecated. I'd like to give people the option.
SSIFilter
  - Format changes for 80 character width.
ResponseIncludeWrapper
  - Default for lastModified changed to -1 from 0.
Globals
  - Keep the old flag
  - I need to check why the CGI servlet isn't using it any more
build.xml
  - Keep jar file name the same for consistency for current users
web.xml
  - Keep servlet mappings
SSIHowTo
  - Keep servlet configuration
SSIServletExternalResolver
  - Align behaviour with standard Tomcat. Fix posisble NPEs. Code is now:

        } else if (name.equalsIgnoreCase("QUERY_STRING_UNESCAPED")) {
            String queryString = req.getQueryString();
            if (queryString != null) {
                // Use default as a last resort
            	String queryStringEncoding =
                    org.apache.coyote.Constants.DEFAULT_CHARACTER_ENCODING;
                
                String uriEncoding = null;
                boolean useBodyEncodingForURI = false;
                
                // Get encoding settings from request / connector if possible
                String requestEncoding = req.getCharacterEncoding();
                if (req instanceof Request) {
                    uriEncoding = ((Request)req).getConnector().getURIEncoding();
                    useBodyEncodingForURI =
                        ((Request)req).getConnector().getUseBodyEncodingForURI();
                }
                
                // If valid, apply settings from request / connector
                if (uriEncoding != null) {
                	queryStringEncoding = uriEncoding;
                } else if(useBodyEncodingForURI) {
                    if (requestEncoding != null) {
                    	queryStringEncoding = requestEncoding;
                    }
                }
                
                try {
               	    retVal = URLDecoder.decode(queryString,
queryStringEncoding);                       
				} catch (UnsupportedEncodingException e) {
					retVal = queryString;
				}
            }



-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org


Mime
View raw message