1
0
mirror of https://github.com/apache/httpd.git synced 2025-11-05 05:30:39 +03:00
Commit Graph

108 Commits

Author SHA1 Message Date
Doug MacEachern
3ae56fb280 reverting to sterlings original segv fix when extension_mappings is NULL
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@90512 13f79535-47bb-0310-9956-ffa450edef68
2001-08-22 22:03:01 +00:00
Doug MacEachern
8a61898a77 v2 of sterlings segv fix
always initialize the extension_info hash rather than checking that it is
!= NULL
PR:
Obtained from:
Submitted by:	John Sterling <sterling@covalent.net>
Reviewed by: dougm


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@90510 13f79535-47bb-0310-9956-ffa450edef68
2001-08-22 20:43:30 +00:00
Doug MacEachern
4fbdccc7aa fix segv in mod_mime if no AddTypes are configured
PR:
Obtained from:
Submitted by:	John Sterling <sterling@covalent.net>
Reviewed by:	dougm


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@90506 13f79535-47bb-0310-9956-ffa450edef68
2001-08-22 20:03:47 +00:00
Ryan Bloom
6fdd45dc48 Update the Apache code to account for the XtOffset change in APR.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@90356 13f79535-47bb-0310-9956-ffa450edef68
2001-08-19 05:48:19 +00:00
William A. Rowe Jr
1c0c1a70a2 The two more Remove flavors needed testing, as well. While I'm at it,
add a reasonable explanation of why we are about to copy.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@90245 13f79535-47bb-0310-9956-ffa450edef68
2001-08-16 21:23:29 +00:00
William A. Rowe Jr
80d01c5861 Push back CHANGES to document the complete mod_mime segfault solution.
Rounded out the mod_mime Add/Remove pairs by adding RemoveLanguage
  and RemoveCharset directives, and rolled in the remove_items handling.
  This is (effectively) my complete patch, sans pool optimizations.
  [William Rowe]


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@90239 13f79535-47bb-0310-9956-ffa450edef68
2001-08-16 20:04:32 +00:00
William A. Rowe Jr
4a48ea1586 Build on Greg's fix for the hash copy, and always copy the exinfo elements
as well.  This should sufficiently demonstrate in benchmarking why we either
  must optimize, or revert to tables.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@90237 13f79535-47bb-0310-9956-ffa450edef68
2001-08-16 18:36:17 +00:00
William A. Rowe Jr
5e3e42e250 Solve the segfault until the right patch is unearthed.
[Greg Ames]


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@90166 13f79535-47bb-0310-9956-ffa450edef68
2001-08-15 03:09:32 +00:00
Roy T. Fielding
184c965da5 Clean up several parsing errors in find_ct that may or may not be causing
a seg fault.  In any case, it was butt ugly code.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@90150 13f79535-47bb-0310-9956-ffa450edef68
2001-08-14 02:35:55 +00:00
William A. Rowe Jr
f96ecb7c51 Subtle variation for security. If the mod_mime file has nothing specific
to say about a given set of file extentions (and has only based the
  resolved fields on the default language, encoding and content type)
  then tell us we can ignore the result by leaving the exception list
  entirely undefined.  If mod_mime adds anything (a language, charset, or
  whatnot) then proceed to use the file in the Multiviews evaluation,
  otherwise mod_negotation will ignore the file found.

  This points out a need for a slightly twisted DefaultClientLanguage,
  as opposed to creating foo.html.html files.  Either that, or introduce
  a 'neutral' entity that the user can list (say, .default) for mod_mime
  to declare it as a fallback language/encoding/content-type/handler.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89919 13f79535-47bb-0310-9956-ffa450edef68
2001-08-04 04:32:59 +00:00
Jeff Trawick
b42eaaf94d axe unused variable
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89917 13f79535-47bb-0310-9956-ffa450edef68
2001-08-04 01:29:38 +00:00
William A. Rowe Jr
d640fd47fe Solve the major underlying problem of content negotation by passing
mod_negotiation the 'unresolved' parts of the path in a ->notes
  array ap-mime-exceptions-list.

  If mod_mime is given index.html.bad.en it will add index and bad
  to the list (presuming html and en are both defined.)

  mod_negotiation will decide if index and bad are it's fault (the
  user requested index.html.bad[.*]) or if it's a messed up file
  (say .old, .junk, or .bak).

  The next patch to allow any-order negotiation should check each
  of these list elements, so that asking for index.bad in the prior
  example would succeed.  Right now that request would fail because
  .html was recognized, so it's not in the exceptions list.  This
  patch uses a simple strcmp to the given name.

  Also, this patch allows any mod_mime processed file to be served,
  even if the content type cannot be determined (think README.en).
  This is crippled by the client expect headers and omitting the
  default content type.

  PLEASE vet this code carefully.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89912 13f79535-47bb-0310-9956-ffa450edef68
2001-08-03 22:57:47 +00:00
William A. Rowe Jr
e43b4bde19 Really compress the add_/remove_ handling, and fix pool allocations.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89878 13f79535-47bb-0310-9956-ffa450edef68
2001-08-02 17:25:05 +00:00
William A. Rowe Jr
c0dbe65816 Need some context for the iterator! Finally get to use that accessor :)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89866 13f79535-47bb-0310-9956-ffa450edef68
2001-08-02 00:17:45 +00:00
William A. Rowe Jr
a99bc9cbb5 Solve the merge bugs, by storing a copy bit to save us a ton of
reallocation in the merge config phase.  Should keep most of the
  savings realized by moving to tables.

  Need others to vet this code, please!  Look at this and the prior
  patch as a single diff (-r n -r n-2) to see the overall changes.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89865 13f79535-47bb-0310-9956-ffa450edef68
2001-08-01 23:33:08 +00:00
Bill Stoddard
13793b8a50 Performance improvement to mod_mime.c. find_ct() in mod_mime,
spends a lot of time in apr_table_get calls.  Using the default
httpd.conf, the tables for languages and charsets are somewhat
large, so the time spent scanning them on each request is
significant. Replacing the tables with hash tables provides
a nice speedup. [Brian Pane <bpane@pacbell.net>]

Had to handmerge a lot of this patch so please review! Dean had some suggestions
for improvement which are not currently implemented.

Submitted by:	Brian Pane
Reviewed by:	Bill Stoddard


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89535 13f79535-47bb-0310-9956-ffa450edef68
2001-07-11 04:47:02 +00:00
William A. Rowe Jr
546f8d040c Allow index.html.en and Index.html.FR to both be considered in negotation
on case insensitive platforms, only.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89381 13f79535-47bb-0310-9956-ffa450edef68
2001-06-18 05:36:33 +00:00
Chuck Murcko
93463cfc17 This is a fix that went into v1.3 quite a while back, but not into v2.0.
It sorts out the problem when a password protected reverse proxy URL
sends a Proxy-Authenticate to a browser instead of a WWW-Authenticate.

This patch covers the changes to the httpd-2.0 tree.

Submitted by:	Graham Leggett
Reviewed by:	Chuck Murcko


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@88527 13f79535-47bb-0310-9956-ffa450edef68
2001-03-16 07:28:08 +00:00
William A. Rowe Jr
5cccb4a478 Clean up namespace badness with s/configfile_t/ap_configfile_t/
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@88312 13f79535-47bb-0310-9956-ffa450edef68
2001-02-25 00:51:32 +00:00
Roy T. Fielding
381f88d56a Update copyright to 2001
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@88184 13f79535-47bb-0310-9956-ffa450edef68
2001-02-16 04:26:53 +00:00
Greg Stein
32dcfd70c4 sneaky for loop... make it more obvious what it is doing
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@88105 13f79535-47bb-0310-9956-ffa450edef68
2001-02-12 03:02:05 +00:00
Greg Stein
5dc34feb12 *) continued header revamping
*) torch some headers (and some libs) from the autoconf stuff


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@88061 13f79535-47bb-0310-9956-ffa450edef68
2001-02-10 14:04:21 +00:00
Ryan Bloom
6fc8754f2b Remove the SetFilter directive from the code. This directive wasn't
nearly as useful as the SetOutputFilter and SetInputFilter, and it never
really worked properly.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@88053 13f79535-47bb-0310-9956-ffa450edef68
2001-02-10 05:30:51 +00:00
Doug MacEachern
88d3406f9a renaming various functions for consistency sake
see: http://apr.apache.org/~dougm/apr_rename.pl
PR:
Obtained from:
Submitted by:
Reviewed by:


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@88019 13f79535-47bb-0310-9956-ffa450edef68
2001-02-08 07:45:33 +00:00
William A. Rowe Jr
59bbd68bec The big change. This is part 3 of the apr-util symbols rename, please
see the first commit of srclib/apr-util/include (cvs apr-util/include)
  for the quick glance at symbols changed.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@87731 13f79535-47bb-0310-9956-ffa450edef68
2001-01-19 07:04:36 +00:00
William A. Rowe Jr
40655f8641 Provide apr_pool_t arg to register_hooks, since anything they do in that
step -must- be done with a pool that will not outlive the cmd pool, from
  which they may have been dynamically loaded.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@87697 13f79535-47bb-0310-9956-ffa450edef68
2001-01-17 15:52:12 +00:00
Ben Laurie
45f620672d Make handlers use hooks.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@87604 13f79535-47bb-0310-9956-ffa450edef68
2001-01-07 19:55:59 +00:00
Ryan Bloom
31602dc2c0 Get SetFilter working with MIME-types again and update the docs
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@87035 13f79535-47bb-0310-9956-ffa450edef68
2000-11-20 18:29:55 +00:00
Ryan Bloom
1206c2c37d Update the SetFilter directive to work with Handlers instead of MIME-types.
This also updates the docs to reflect the change.
Submitted by:	Joshua Slive
Reviewed by:	Ryan Bloom


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@87028 13f79535-47bb-0310-9956-ffa450edef68
2000-11-19 18:52:21 +00:00
Ryan Bloom
a17358b280 Add a directive to mod_mime which allows people to configure a filter
stack for a given mime-type.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@87026 13f79535-47bb-0310-9956-ffa450edef68
2000-11-19 16:55:11 +00:00
William A. Rowe Jr
d6490633eb Renamed all MODULE_EXPORT symbols to AP_MODULE_DECLARE and all symbols
for CORE_EXPORT to AP_CORE_DECLARE (namespace protecting the wrapper)
  and retitled API_EXPORT as AP_DECLARE and APR_EXPORT as APR_DECLARE.
  All _VAR_ flavors changes to _DATA to be absolutely clear.
  Thank you Greg, for the most obvious suggestion.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@86609 13f79535-47bb-0310-9956-ffa450edef68
2000-10-16 06:05:15 +00:00
Ryan Bloom
e016730659 Port the fix for Remove Handler from 1.3 to 2.0
Submitted by:	Sander van Zoest <sander@covalent.net>
Reviewed by:	Ryan Bloom


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@86467 13f79535-47bb-0310-9956-ffa450edef68
2000-10-09 03:05:38 +00:00
Jeff Trawick
cc301503a1 Fix some problems with the recent port of RemoveEncoding and
RemoveType to 2.0.  (--with-maintainer-mode works wonders!)


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@86248 13f79535-47bb-0310-9956-ffa450edef68
2000-09-18 12:17:29 +00:00
Ryan Bloom
dc62a5eb8d Port the RemoveEncodings/RemoveTypes code from 1.3 to 2.0. This includes
the bug fix that was recently committed to the 2.0 tree.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@86240 13f79535-47bb-0310-9956-ffa450edef68
2000-09-17 01:12:46 +00:00
William A. Rowe Jr
1a9db204f5 Remaining cleanup of ap_ -> apr_ and AP_ -> APR_ transformation...
see src/lib/apr/apr_compat.h for most details.
  Also a few minor nits to get Win32 to build.

PR:
Obtained from:
Submitted by:
Reviewed by:


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@86008 13f79535-47bb-0310-9956-ffa450edef68
2000-08-06 06:07:53 +00:00
Doug MacEachern
059d8dd212 prefix libapr functions and types with apr_
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@85976 13f79535-47bb-0310-9956-ffa450edef68
2000-08-02 05:27:38 +00:00
Ryan Bloom
28f6bfe4a2 Remove all of the ap_is* functions from Apache. They were already in APR,
and we all hate duplicate code.  :-)  This also required adding ap_isascii
to APR.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@85897 13f79535-47bb-0310-9956-ffa450edef68
2000-07-26 15:31:30 +00:00
Ryan Bloom
22d9fbdec0 Move all APR functions related to strings to their own directory, and
create a new header for those functions.  This is the first step to
removing the apr/lib directory completely, and moving those files/functions
to descriptive directories.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@85867 13f79535-47bb-0310-9956-ffa450edef68
2000-07-21 19:50:58 +00:00
Bill Stoddard
2e40320b53 Get rid of more compiler warnings.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@85618 13f79535-47bb-0310-9956-ffa450edef68
2000-06-19 18:11:47 +00:00
Ben Laurie
8da89daa47 More command handlers.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@85604 13f79535-47bb-0310-9956-ffa450edef68
2000-06-17 21:37:05 +00:00
William A. Rowe Jr
da493b8be1 PR:
Obtained from:
Submitted by:
Reviewed by:

  Reverse out all _EXPORT_VAR changes back to their original _VAR_EXPORT
  names for linkage (API_, CORE_, and MODULE_).


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@85318 13f79535-47bb-0310-9956-ffa450edef68
2000-05-27 22:40:44 +00:00
William A. Rowe Jr
86e2a18f2a This patch corrects the issues from the AP_EXPORT and linkage
specification arguments to the ap_hooks.h declarations.  As with
  the APR_ and AP_ patches, API_VAR_EXPORT becomes API_EXPORT_VAR,
  and MODULE_VAR_EXPORT becomes MODULE_EXPORT_VAR.

  I will be happy to revert the inclusion of ap_config.h from 
  httpd.h if this bothers anyone.  More individual modules need
  to be patched if we do so.

  The API_EXPORTs all moved into central storage in the ap_config.h
  header.  Without WIN32 or API_STATIC compile time declarations, 
  these macros remain no-ops.

  This patch also moves the following data from http_main to http_config:

    const char *ap_server_argv0;
    const char *ap_server_root;
    ap_array_header_t *ap_server_pre_read_config;
    ap_array_header_t *ap_server_post_read_config;
    ap_array_header_t *ap_server_config_defines;

  And the following variables had already moved into ap_hooks.c:

    ap_pool_t *g_pHookPool;  (initialized now in http_config)
    int g_bDebugHooks;                   (out of http_config)
    const char *g_szCurrentHookName;     (out of http_config)

  The changes to http_main.c are in preparation for that module to
  move out to a seperate .exe for win32.  Other platforms will be
  unaffected, outside of these changes.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@85309 13f79535-47bb-0310-9956-ffa450edef68
2000-05-27 05:28:02 +00:00
Doug MacEachern
6644b34387 add AP_ prefix to *HOOK* macros
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@85045 13f79535-47bb-0310-9956-ffa450edef68
2000-04-26 07:14:39 +00:00
Ryan Bloom
de3a77dc01 Change ap_context_t to ap_pool_t. This compiles, runs, and serves pages
on Linux, but probably breaks somewhere.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@84963 13f79535-47bb-0310-9956-ffa450edef68
2000-04-14 15:59:20 +00:00
Roy T. Fielding
2bee4ad19d Update to Apache Software License version 1.1
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@84879 13f79535-47bb-0310-9956-ffa450edef68
2000-03-31 09:05:25 +00:00
Jeff Trawick
61ae47aed8 improve error message for missing mime types file
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@84824 13f79535-47bb-0310-9956-ffa450edef68
2000-03-22 11:21:58 +00:00
Dirk-Willem van Gulik
6f4be46b0e Added AddCharset back in again. Need that badly for
my production hosts. Still checking and this also
exposes the lack of EBCDIC and the NOT_PROXY change
which is done since 1.3.9

PR:
Obtained from:
Submitted by:
Reviewed by:


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@84785 13f79535-47bb-0310-9956-ffa450edef68
2000-03-17 01:10:41 +00:00
Dirk-Willem van Gulik
290f6829dd PR:
Obtained from:
Submitted by:
Reviewed by:


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@84784 13f79535-47bb-0310-9956-ffa450edef68
2000-03-17 01:09:10 +00:00
Ryan Bloom
b1c26f031a Fix all the License issues. Including:
s/Apache Group/Apache Software Foundation/
s/1999/2000/
s/Sascha's license/ASF license


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@84725 13f79535-47bb-0310-9956-ffa450edef68
2000-03-10 00:07:37 +00:00
Ryan Bloom
505fa49a3a Manoj has been pushing for this for a while, but I've been too dense
to understand that he was right.  :-)  Basically, this makes the modules
use ap_config to test for header file inclusion.  This method is not to
be used for larger modules that run autoconf theirselves.  Including
ap_config is only valid for modules which rely on Apache to do their
configuration.  Currently, this is only the core modules.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@84497 13f79535-47bb-0310-9956-ffa450edef68
2000-01-19 02:42:17 +00:00