Eric Covener
925b6f0ceb
add ap_set_content_type_ex to differentiate
...
trusted sources
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1918551 13f79535-47bb-0310-9956-ffa450edef68
2024-06-24 17:22:51 +00:00
Ruediger Pluem
c23375e945
* In the reverse proxy case r->filename might contain a query string if
...
the nocanon option was used with ProxyPass.
If this is the case cut off the query string as the last parameter in
this query string might end up on an extension we take care about, but
we only want to match against path components not against query
parameters.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1907505 13f79535-47bb-0310-9956-ffa450edef68
2023-02-07 14:20:37 +00:00
Ruediger Pluem
9b05de8e2d
* Correctly initialize nomime member
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1868457 13f79535-47bb-0310-9956-ffa450edef68
2019-10-14 20:14:58 +00:00
Eric Covener
df8df5b5a6
allow mod_mime to be de disabled per-dir too
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1855663 13f79535-47bb-0310-9956-ffa450edef68
2019-03-16 18:15:23 +00:00
Eric Covener
b07b35d90f
spotted by Ruediger
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1855455 13f79535-47bb-0310-9956-ffa450edef68
2019-03-13 20:00:29 +00:00
Eric Covener
6a84f21f3a
mod_mime: Add MimeOptions
...
mod_mime: Add `MimeOptions` directive to allow Content-Type or all metadata
detection to use only the last (right-most) file extension.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1855449 13f79535-47bb-0310-9956-ffa450edef68
2019-03-13 18:41:30 +00:00
Christophe Jaillet
1cb2f82a23
Fix a cppcheck warning.
...
Remove some dead code. '!r->content_languages' is known to be true at this point.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1838285 13f79535-47bb-0310-9956-ffa450edef68
2018-08-17 20:36:31 +00:00
Eric Covener
c18ad646a5
mod_mime: fix quoted pair scanning
...
Submitted By: ylavic
CVEID: CVE-2017-7679
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1797550 13f79535-47bb-0310-9956-ffa450edef68
2017-06-03 22:04:47 +00:00
Graham Leggett
e666d3a64e
mod_mime: Don't arbitrarily bypass AddOutputFilter during a ProxyPass,
...
but then allow AddOutputFilter during a RewriteRule [P]. Make mod_mime
behave identically in both cases. PR52342.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1222370 13f79535-47bb-0310-9956-ffa450edef68
2011-12-22 17:48:17 +00:00
Stefan Fritsch
92e366007c
Add lots of unique tags to error log messages
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1209766 13f79535-47bb-0310-9956-ffa450edef68
2011-12-02 23:02:04 +00:00
Stefan Fritsch
70901d805d
Ignore leading dots when looking for mime extensions
...
PR 50434
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1061791 13f79535-47bb-0310-9956-ffa450edef68
2011-01-21 12:51:57 +00:00
Daniel Earl Poirier
6b803976f2
Fix a number of typos and misspellings. Reported by Ville Skytta.
...
PR48496.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1029134 13f79535-47bb-0310-9956-ffa450edef68
2010-10-30 17:56:13 +00:00
Stefan Fritsch
e444411df7
Replace apr_palloc+memcpy by apr_memdup
...
Submitted by: Boya Sun <boya sun case edu>
PR: 39518
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@981085 13f79535-47bb-0310-9956-ffa450edef68
2010-07-31 20:02:13 +00:00
Stefan Fritsch
ebb62867fb
Use the new APLOG_USE_MODULE/AP_DECLARE_MODULE macros everywhere to take
...
advantage of per-module loglevels
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@951895 13f79535-47bb-0310-9956-ffa450edef68
2010-06-06 16:59:50 +00:00
Stefan Fritsch
131e03efeb
Make RemoveType override the info from TypesConfig
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@821298 13f79535-47bb-0310-9956-ffa450edef68
2009-10-03 12:13:41 +00:00
Daniel Earl Poirier
264e4a0cfc
mod_mime: detect invalid use of MultiviewsMatch inside Location and
...
LocationMatch sections. Document that such usage is not valid.
PR47754.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@814728 13f79535-47bb-0310-9956-ffa450edef68
2009-09-14 16:32:30 +00:00
William A. Rowe Jr
2ce795f37c
wrap comment, no functional change
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@775315 13f79535-47bb-0310-9956-ffa450edef68
2009-05-15 20:30:47 +00:00
Nick Kew
0e3d53aeae
mod_mime: don't adjust case in filename components we don't use
...
PR 43250, patch by Basant Kumar Kukreja
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@693141 13f79535-47bb-0310-9956-ffa450edef68
2008-09-08 15:52:59 +00:00
Nick Kew
e5061abc93
Multiple trivial fixes from Christophe JAILLET
...
PR 38699, 39518, 42005, 42006, 42007, 42008, 42009
The patches are all his, and are sufficiently trivial to review
at a glance.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@557837 13f79535-47bb-0310-9956-ffa450edef68
2007-07-20 01:26:55 +00:00
Roy T. Fielding
de659cbed0
update license header text
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@420983 13f79535-47bb-0310-9956-ffa450edef68
2006-07-11 20:33:53 +00:00
Colm MacCarthaigh
dd95d7c37c
Update the copyright year in all .c, .h and .xml files
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@395228 13f79535-47bb-0310-9956-ffa450edef68
2006-04-19 12:11:27 +00:00
Jim Jagielski
5061d9fa92
No functional Change: Removing trailing whitespace. This also
...
means that "blank" lines consisting of just spaces or
tabs are now really blank lines
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@332306 13f79535-47bb-0310-9956-ffa450edef68
2005-11-10 15:11:44 +00:00
Justin Erenkrantz
905cdf9f0b
Update copyright year to 2005 and standardize on current copyright owner line.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@151408 13f79535-47bb-0310-9956-ffa450edef68
2005-02-04 20:28:49 +00:00
André Malo
a688f06b19
fix name of The Apache Software Foundation
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@102618 13f79535-47bb-0310-9956-ffa450edef68
2004-02-09 20:31:03 +00:00
André Malo
d0e05bada9
fix copyright dates according to the first check in
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@102565 13f79535-47bb-0310-9956-ffa450edef68
2004-02-08 12:07:22 +00:00
André Malo
4f02cb1e18
apply Apache License, Version 2.0
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@102525 13f79535-47bb-0310-9956-ffa450edef68
2004-02-06 22:58:42 +00:00
André Malo
fb07607180
update license to 2004.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@102135 13f79535-47bb-0310-9956-ffa450edef68
2004-01-01 13:26:26 +00:00
André Malo
be807cff9a
add a comment
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@101678 13f79535-47bb-0310-9956-ffa450edef68
2003-11-02 12:21:33 +00:00
André Malo
742af25096
finished that boring job:
...
update license to 2003.
Happy New Year! ;-))
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@98573 13f79535-47bb-0310-9956-ffa450edef68
2003-02-03 17:53:28 +00:00
André Malo
c05c7d9c80
provide better error messages for the multiviewsmatch directive.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@98145 13f79535-47bb-0310-9956-ffa450edef68
2003-01-01 04:25:02 +00:00
Brian Pane
33fa28e38a
don't segfault in mod_mime's find_ct() if we get there without having set r->filename
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@97924 13f79535-47bb-0310-9956-ffa450edef68
2002-12-15 16:37:19 +00:00
Jeff Trawick
c0136a291a
don't lose const when calling strrchr()
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@96646 13f79535-47bb-0310-9956-ffa450edef68
2002-09-05 11:04:25 +00:00
Justin Erenkrantz
166a901497
Add ModMimeUsePathInfo directive.
...
This directive allows mod_mime to lookup extension information for content
served via Location blocks so that content-type, filters, etc can be
applied to non-file content.
(I wouldn't be shocked if we end up changing the directive name.)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@96644 13f79535-47bb-0310-9956-ffa450edef68
2002-09-05 07:31:14 +00:00
Cliff Woolley
81c03e82c4
Renames:
...
APR_XtOffset -> APR_OFFSET
APR_XtOffsetOf -> APR_OFFSETOF
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95164 13f79535-47bb-0310-9956-ffa450edef68
2002-05-18 04:13:13 +00:00
Aaron Bannert
e3eca4ace6
Just another huge style diff. Space-indentation is comming back in
...
a big way. No more misaligned if's without {} blocks.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95162 13f79535-47bb-0310-9956-ffa450edef68
2002-05-18 00:45:05 +00:00
Brian Pane
32c16646d1
Remove an extraneous loop condition
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95045 13f79535-47bb-0310-9956-ffa450edef68
2002-05-12 03:59:31 +00:00
Brian Pane
8d637c1f13
Performance fixes:
...
* eliminate some copying of sub-parts of the content type in analyze_ct()
* take advantage of the fact that we know the lengths of those sub-parts
in find_ct() to avoid having to recompute their length for concatenation
The charset handling code needs the same type of optimization eventually.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94900 13f79535-47bb-0310-9956-ffa450edef68
2002-05-02 03:19:44 +00:00
Justin Erenkrantz
8e1a89e148
We must always use case-insensitive comparisons in mod_mime even if
...
our platform is not "case-blind." This matches 1.3 behavior and our
docs say that the extension argument is case-insensitive anyway.
This is case where the code fix is easier than the doc fix. =)
PR: 8223
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94789 13f79535-47bb-0310-9956-ffa450edef68
2002-04-25 05:40:15 +00:00
Bill Stoddard
d5c24720dc
Commit 1 of 2 to:
...
1. rename ap_rset_content_type to ap_set_content_type
2. reverse the arguments on the call to aligh with ap_set_content_length
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94056 13f79535-47bb-0310-9956-ffa450edef68
2002-03-20 17:41:55 +00:00
Bill Stoddard
470edb9dd8
First commit to introduce accessor function to set r->content_type..
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94027 13f79535-47bb-0310-9956-ffa450edef68
2002-03-20 01:58:47 +00:00
Jeff Trawick
0bd9790c41
fix the type of a string argument to ap_log_error()
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93973 13f79535-47bb-0310-9956-ffa450edef68
2002-03-16 20:29:38 +00:00
William A. Rowe Jr
65a37752ec
Eliminate potential ap_server_root_relative segfaults, with the input
...
of Jeff Trawick's style changes to the first patches. Doesn't include
the fixes to ssl [more complex], and we won't trap errors that involve
ap_serverroot, since we presume that was normalized on the way in.
Therefore, testing ap_server_root_relative(DEFAULT_FOO) cases
should never become necessary.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93965 13f79535-47bb-0310-9956-ffa450edef68
2002-03-16 18:26:58 +00:00
Roy T. Fielding
845cbfd508
Update our copyright for this year.
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93918 13f79535-47bb-0310-9956-ffa450edef68
2002-03-13 20:48:07 +00:00
Brian Pane
3e75e8b52e
[indentation fixes only]
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@92389 13f79535-47bb-0310-9956-ffa450edef68
2001-12-08 02:04:51 +00:00
Brian Pane
dc85b1450c
Reduced the number of times that we scan through each string
...
looking for invalid characters in analyze_ct()
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@92388 13f79535-47bb-0310-9956-ffa450edef68
2001-12-08 02:00:42 +00:00
Jeff Trawick
226d166f3e
fix a const-ness problem caused by calling the wrong strchr()
...
--enable-maintainer-mode and a decent compiler is *so* important!
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@92365 13f79535-47bb-0310-9956-ffa450edef68
2001-12-07 12:29:04 +00:00
Brian Pane
47a51848bc
Removed one more strdup in the content-type processing
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@92364 13f79535-47bb-0310-9956-ffa450edef68
2001-12-07 08:48:17 +00:00
Brian Pane
ad405f14c2
Optimized away some string scans and copies in analyze_ct()
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@92363 13f79535-47bb-0310-9956-ffa450edef68
2001-12-07 08:19:44 +00:00
Brian Pane
a262e40728
optimization: replaced an apr_pstrndup call with apr_pstrmemdup
...
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@92359 13f79535-47bb-0310-9956-ffa450edef68
2001-12-07 03:44:29 +00:00
Ian Holsman
86b792b21c
Modify post_config hook so that it can return a error,
...
causing the server not to start.
previous method was to call exit(1) which would not fail
gracefully
PR:
Obtained from:
Submitted by:
Reviewed by: (Idea only Jeff Trawick)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@92144 13f79535-47bb-0310-9956-ffa450edef68
2001-11-23 16:35:22 +00:00