You are viewing a plain text version of this content. The canonical link for it is here.
Posted to bugs@httpd.apache.org by bu...@apache.org on 2007/09/13 02:17:23 UTC

DO NOT REPLY [Bug 43250] - mod_negotiation can't match file when filename has an uppercase chars

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=43250>.
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=43250





------- Additional Comments From basant.kukreja@sun.com  2007-09-12 17:17 -------
Created an attachment (id=20804)
 --> (http://issues.apache.org/bugzilla/attachment.cgi?id=20804&action=view)
Patch against trunk

Problem description :
/FooBar.Baz does not return /FooBar.Baz.html
while
/FooBar.baz return /FooBar.baz.html

find_ct function in mime.c collect mime related information. It prepares the
ap-mime-exception-list in r->notes. In this list, all extensions which are
*not* mime type extensions, are stored. Since mime types are case insensitive
so ext is converted into lower case. However "ap-mime-exception-list" should
not be case insensitive.

Currently there is only one consumer of this list that is mod_negotiation.
read_type_multi function read this mime exception list and try to match it
with file name extension. If the OS filesystem is case sensitive then it uses
strncmp (instead of strncasecmp) to compare the file extensions with mime
exception. The comparision fails if mime exception is converted to lower case.

Since mime exceptions are not really mime types so they should be stored with
their cases.  In this fix, extensions are stored with their preserved values
in "ap-mime-exception-list". 


-- 
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: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org