1
0
mirror of https://github.com/apache/httpd.git synced 2026-10-23 22:49:01 +03:00
Commit Graph

1176 Commits

Author SHA1 Message Date
Joe Orton
172d563455 * include/ap_socache.h: Use C++ safety wrappers, and rename ->delete
to ->remove since the former is a C++ reserved word.

* modules/ssl/ssl_scache.c (ssl_scache_remove): Update accordingly.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@724745 13f79535-47bb-0310-9956-ffa450edef68
2008-12-09 15:19:08 +00:00
Joe Orton
b078f2374e * include/ap_socache.h: Define AP_SOCACHE_DEFAULT_PROVIDER as a
default provider name, to allow consumers to use a default provider
  if not configured otherwise.

* modules/cache/mod_socache_shmcb.c (register_hooks): Register shmcb
  as the default provider.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@724723 13f79535-47bb-0310-9956-ffa450edef68
2008-12-09 14:52:59 +00:00
Joe Orton
dce91079c1 Reduce config overhead for use of socache interface by allowing
default paths to be used if none are configured:

* include/ap_socache.h (ap_socache_provider_t::create):
  Allow arg to be NULL to force use of defaults.
  (ap_socache_provider_t::init): Rename 'namespace' parameter to
  'cname' and restrict to allow use in filesystem paths.
  
* modules/cache/mod_socache_dbm.c (socache_dbm_create, 
  socache_dbm_init),
  modules/cache/mod_socache_shmcb.c (socache_shmcb_create, 
  socache_shmcb_init): 
  Default to use of runtimedir-relative paths if no
  explicit path is configured.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@724682 13f79535-47bb-0310-9956-ffa450edef68
2008-12-09 13:11:45 +00:00
Paul Querna
432d1edf3b Roll on trunk to 2.3.1-dev.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@724096 13f79535-47bb-0310-9956-ffa450edef68
2008-12-07 06:37:14 +00:00
Paul Querna
14623a3daf Remove -dev flag to prepare for 2.3.0.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@724094 13f79535-47bb-0310-9956-ffa450edef68
2008-12-07 06:36:20 +00:00
Paul Querna
a3c055552e bump minor for new apis
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@724083 13f79535-47bb-0310-9956-ffa450edef68
2008-12-07 05:50:07 +00:00
Paul Querna
03eb917952 New API, ap_body_to_table, a very ineffeicent and bad hack to remove an apreq dependency.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/wombat-integration@723652 13f79535-47bb-0310-9956-ffa450edef68
2008-12-05 08:36:26 +00:00
Paul Querna
ba87dcea6a Add new api, ap_args_to_table, to parse a request's arguments into a table.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/wombat-integration@723627 13f79535-47bb-0310-9956-ffa450edef68
2008-12-05 07:15:22 +00:00
Paul Querna
80d6606307 When dtrace support is not present, compile it all the way out.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@723571 13f79535-47bb-0310-9956-ffa450edef68
2008-12-05 03:48:57 +00:00
Paul Querna
f47b6f394e Import the core parts of the DTrace patch. This is a modified and updated
version of what was submited by Theo before:
 <http://mail-archives.apache.org/mod_mbox/httpd-dev/200805.mbox/%3C6AFBCFE8-4CCA-4A02-8A43-F9170689695D@omniti.com%3E>

Note, this does not hook it up into the build system at this time, because
the original patch was a little too creative there.

Submitted By: Theo Schlossnagle <jesus omniti.com>


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@723565 13f79535-47bb-0310-9956-ffa450edef68
2008-12-05 03:34:52 +00:00
Paul Querna
a73acf02f6 API Cleanup in preperation for 2.4.x, make sure all exported functions or variables contain an ap_ prefix.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@722399 13f79535-47bb-0310-9956-ffa450edef68
2008-12-02 08:13:36 +00:00
Eric Covener
51c4443fcc Prevent AP_FILTER_ERROR from being misinterpreted as SUSPENDED when checking
the status code returned by a handler by updating the values of the filter
error macros and consolidating them in httpd.h 



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@721677 13f79535-47bb-0310-9956-ffa450edef68
2008-11-29 12:57:42 +00:00
Ruediger Pluem
4a3c945b14 * Rip out the old flushing approach for solving lifetime issues between the
backend connection bucket allocator and front end connection bucket allocator.
  Instead copy the buckets from the backend over to ones that have been created
  using the front end bucket allocator. For metabucket this is done by recreating
  them, for data buckets this is done by reading them and putting the read data
  in a transient bucket.

PR: 45792


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@712375 13f79535-47bb-0310-9956-ffa450edef68
2008-11-08 11:09:38 +00:00
Nick Kew
a1252f96e3 Wrap the global count of privileges handlers operating. Silence grumblers.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@710037 13f79535-47bb-0310-9956-ffa450edef68
2008-11-03 11:37:03 +00:00
Nick Kew
72119d92f5 Switch all unix MPMs to use drop_privileges hook (mod_unixd) for startup
and add a flag to prevent running without any module taking responsibility
for managing system privileges!


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@709993 13f79535-47bb-0310-9956-ffa450edef68
2008-11-03 00:46:54 +00:00
Chris Darroch
fa0fdfa2fc Fix handling of authz configurations, make default authz logic replicate
2.2.x authz logic and support existing configurations (including .htaccess
files), and replace <Satisfy*>, Reject, and AuthzMergeRules directives
with Match, <Match*>, and AuthzMerge directives.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@709838 13f79535-47bb-0310-9956-ffa450edef68
2008-11-02 04:01:32 +00:00
Chris Darroch
d9b960bcc8 major not minor bump for r709708
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@709724 13f79535-47bb-0310-9956-ffa450edef68
2008-11-01 17:08:18 +00:00
Chris Darroch
6200ffa41e remove unused AUTHZ_GROUP_NOTE define
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@709708 13f79535-47bb-0310-9956-ffa450edef68
2008-11-01 15:01:35 +00:00
Chris Darroch
cc8a3547ca fix typo
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@709706 13f79535-47bb-0310-9956-ffa450edef68
2008-11-01 14:53:09 +00:00
Chris Darroch
3cc4c29256 whitespace cleanup
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@709704 13f79535-47bb-0310-9956-ffa450edef68
2008-11-01 14:47:07 +00:00
Paul Querna
1643f818ae * include/http_core.h
(core_dir_config): Fix warning: overflow in implicit constant conversion,
    generated by core.c line 117, which sets content_md5 to '2', which is too big
    for a signed value -- but it looks like this was really meant to be unsigned.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@708828 13f79535-47bb-0310-9956-ffa450edef68
2008-10-29 08:39:26 +00:00
Paul Querna
e51cb1a4ed * include/mod_auth.h
(authz_status): Remove trailing comma on enum.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@708822 13f79535-47bb-0310-9956-ffa450edef68
2008-10-29 08:25:58 +00:00
Ruediger Pluem
81c73ca116 * Move ap_timeout_parameter_parse from mod_proxy.c to server/util.c and thus
make it part of the public API.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@707022 13f79535-47bb-0310-9956-ffa450edef68
2008-10-22 10:23:52 +00:00
Chris Darroch
1ffb6a6c9e convert tabs to spaces
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@705462 13f79535-47bb-0310-9956-ffa450edef68
2008-10-17 04:17:12 +00:00
Graham Leggett
08e63788b2 Minor bump when exporting mod_rewrite.h
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@704845 13f79535-47bb-0310-9956-ffa450edef68
2008-10-15 10:09:33 +00:00
Paul Querna
767cc30c02 Introduce Suspendable Requests to the Event MPM.
Using this basic framework, you can return SUSPENDED from an HTTP Handler,
and then register a callback that is invoked by the MPM at a later time.

This initial version only supports _timers_ as callbacks, but in the future I
would like to add things like wait for socket activity, on a socket specified by
the handler.

Once in a callback, It is then the responsibility of the callback fucntion 
to finish the HTTP Request handling, but this alows you to do cool things like 
a fully async proxy, COMET support, or even rate limiting.

To prove I'm not insane, I've inlcuded an example module, mod_dialup.

You can configure it like this:
<Location "/docs">
  ModemStandard "V.32"
</Location>

And for static files inside that path, you will be rate limited to V.32 speeds, 
aka 9.6 kilobits/second.

Does anyone besides Rüdiger read commit emails :-) ?

I know there are likely huge problems with this, but I would like to see how far
we can push the Event MPM, figure out what to do better, if there is anything, 
and then really dive into the 3.0 development before ApacheCon.

* server/mpm/experimental/event/fdqueue.h:
    (timer_event_t): New structure to hold timer events and callback functions.
    
* server/mpm/experimental/event/fdqueue.c
    (ap_queue_empty): Modify to also look at Timer Ring.

    (ap_queue_init): Initialize Timer Ring.

    (ap_queue_push_timer): New function, pushes a timer event into the queue.

    (ap_queue_pop_something): Renamed function, returns a timer event or
        a socket/pool for a worker thread to run.


* server/mpm/experimental/event/event.c
    (process_socket): If the connection is in SUSPENDED state, don't force it
        into linger mode yet, the callback will have to take care of that.

    (push_timer2worker): New shortcut function, pushes timer event into queue
        for a worker to run.

    (timer_free_ring): New global data structure to recycle memory used by 
        timer events.

    (timer_ring): New global data structure to hold active timer events.

    (g_timer_ring_mtx): Thread mutex to protect timer event data structures.

    (ap_mpm_register_timed_callback): New Function, registers a callback to be
        invoked by the MPM at a later time.

    (listener_thread): Calculate our wakeup time based on the upcoming Event 
        Queue, and after pollset_poll runs, push any Timers that have passed
        onto worker threads to run.
    
    (worker_thread): Call new queue pop method, and if the Timer Event is 
        non-null, invoke the callback.  Once the callback is done, push the
        structure onto the timer_free_ring, to be recycled.

    (child_main): Initialize new mutex and ring structures.


* server/config.c
    (ap_invoke_handler): Allow SUSPENDED aa valid return code from handlers.


* modules/http/http_core.c
    (ap_process_http_async_connection): Don't close the connection when in 
        SUSPENDED state.


* modules/http/http_request.c
    (ap_process_request_after_handler): New function, body pulled from the old,
        ap_process_async_request.  Split to let handlers invoke this so they 
        don't need to know all of the details of finishing a request.

    (ap_process_async_request): If the handler returns SUSPENDED, don't do
        anything but return.


* include/ap_mmn.h: Bump MMN.


* include/ap_mpm.h
    (ap_mpm_register_timed_callback): New function.


* include/httpd.h:
    (SUSPENDED): New return code for handlers.
    (request_rec::invoke_mtx): New mutex to protect callback invokcations
        from being run before the original handler finishes running.
    (conn_state_e): Add a suspended state.


* include/http_request.h
    (ap_process_request_after_handler): New function to make it easier for 
        handlers to finish the HTTP Request.


* modules/test/config.m4: Add mod_dialup to build.


* modules/test/mod_dialup.c: New rate limiting module, requires the Event MPM 
    to work.




git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@697357 13f79535-47bb-0310-9956-ffa450edef68
2008-09-20 11:58:08 +00:00
Graham Leggett
4ed2378c5e mod_session_cookie, mod_session_dbd: Make sure cookies are set both
within the output headers and error output headers, so that the
session is maintained across redirects.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@690501 13f79535-47bb-0310-9956-ffa450edef68
2008-08-30 13:37:52 +00:00
Graham Leggett
ed1c1c4b06 The cookie attributes to fix cookie removal required an MMN bump
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@690401 13f79535-47bb-0310-9956-ffa450edef68
2008-08-29 21:57:44 +00:00
Graham Leggett
0ec83e8b1b mod_session_cookie: Make sure that cookie attributes are correctly
included in the blank cookie when cookies are removed. This fixes an
inability to log out when using mod_auth_form.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@690400 13f79535-47bb-0310-9956-ffa450edef68
2008-08-29 21:49:27 +00:00
Jim Jagielski
45c5291a7f Allow determination of whether to use ';' as
a sticky session path delim/sep (ala mod_jk) to
be runtime (and balancer-wise) configurable.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@687754 13f79535-47bb-0310-9956-ffa450edef68
2008-08-21 13:33:32 +00:00
Ruediger Pluem
b4e20c8e55 * Add the possibility to set a separate connection timeout for backend
workers.

PR: 45445
Submitted by: rahul <rahul sun.com>
Reviewed by: rpluem


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@684341 13f79535-47bb-0310-9956-ffa450edef68
2008-08-09 20:52:46 +00:00
Eric Covener
bb7398fce0 revert r672639 which lacked a necessary major bump, add a major MMN bump
to account for the short-lived API addition/removal.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@678947 13f79535-47bb-0310-9956-ffa450edef68
2008-07-22 23:49:51 +00:00
Eric Covener
3c03d962d6 fix comment associated with MMN change
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@674364 13f79535-47bb-0310-9956-ffa450edef68
2008-07-06 23:49:22 +00:00
Ruediger Pluem
dcc70f6bbb * Include http_config.h to ensure that cmd_parms is defined, otherwise
e.g. the perl test framework breaks.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@673999 13f79535-47bb-0310-9956-ffa450edef68
2008-07-04 10:54:09 +00:00
Eric Covener
bbc850ee33 mod_auth_digest: Detect during startup when AuthDigestProvider
is configured to use an incompatible provider via AuthnProviderAlias.
PR 45196 



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@672639 13f79535-47bb-0310-9956-ffa450edef68
2008-06-29 16:42:43 +00:00
William A. Rowe Jr
bbc545055b Consumed by server/*.c, belongs in include/
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@664235 13f79535-47bb-0310-9956-ffa450edef68
2008-06-07 01:39:25 +00:00
William A. Rowe Jr
6f0e96cfbc ap_ namespace, a dead giveaway that this information should reside
in the general include\ directory

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@664232 13f79535-47bb-0310-9956-ffa450edef68
2008-06-07 01:13:10 +00:00
William A. Rowe Jr
3ad01cf27e You don't export the fn hooked or registered as an optional fn
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@664227 13f79535-47bb-0310-9956-ffa450edef68
2008-06-07 01:02:31 +00:00
William A. Rowe Jr
cb4a8ab247 Declare the callback function NONSTD
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@664173 13f79535-47bb-0310-9956-ffa450edef68
2008-06-06 22:40:15 +00:00
William A. Rowe Jr
df5ca37b48 As this is consumed by the core, mod_auth must reside in
the serverwide include/'s.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@664169 13f79535-47bb-0310-9956-ffa450edef68
2008-06-06 22:34:44 +00:00
William A. Rowe Jr
626c03ae23 No. You cannot rely on mod_foo.h magic from the
various subdirectories if you will consume it in
the core (server/*.c).  server/request.c needs
mod_request (similar to mod_core.h) so this never
belonged in the subdir.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@664167 13f79535-47bb-0310-9956-ffa450edef68
2008-06-06 22:32:32 +00:00
Nick Kew
caab5e8b8a Switch ftp_directory_charset and interpolate_env in proxy_dir_conf,
with a major MMN bump.  As suggested by rpluem in r661069 to enable
backport *without* a major bump (ABI breakage) in 2.2.x.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@661079 13f79535-47bb-0310-9956-ffa450edef68
2008-05-28 20:56:02 +00:00
Greg Ames
66c1fe1649 The response to the TRACE method is partially garbled on an EBCDIC platform.
Send the request line and trailing CRLF in ASCII.

Submitted by:           David Jones <oscaremma gmail.com>
Reviewed and tested by: gregames


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@659560 13f79535-47bb-0310-9956-ffa450edef68
2008-05-23 14:52:33 +00:00
Dirk-Willem van Gulik
53d475f654 Currently each of the caching module includes logic to implement
the hop-by-hop rules of rfc 2616 along with the entity response
rules. To make sure that they stay in sync; and to make it easier
to add (http) caching modules - this change moves them all into
one place (cache_util) and exposes a in-bound and out-bound
version to operate on the headers.

In short: we retire ap_cache_cacheable_hdrs_out() which was used
for both in- and out-put headers; and replace it by a single
ap_cache_cacheable_headers() which understands the hop-by-hop
rules. And then wrap this into an in- and out-put specific 
ap_cache_cacheable_headers_in()/out() which we can teach things
about entity responses and so on.. The latter which will also 
merge error and ensure content-type. 

This API change bumps up the minor MM by one.    



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@649162 13f79535-47bb-0310-9956-ffa450edef68
2008-04-17 16:03:13 +00:00
Graham Leggett
c239e59ea5 Move the public mod_request.h header out of the include directory and back to modules/filters.
The current build of exports.c assumes that everything in include is part of the core, and so
putting the header there creates link errors.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@648254 13f79535-47bb-0310-9956-ffa450edef68
2008-04-15 13:53:32 +00:00
Graham Leggett
b613588a30 Move the KeptBodySize directive, kept_body filters and the
ap_parse_request_body function out of the http module and into a
new module called mod_request, reducing the size of the core.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@647263 13f79535-47bb-0310-9956-ffa450edef68
2008-04-11 18:41:53 +00:00
Graham Leggett
d5030b2190 Add a function to the http filters that is able to parse an HTML
form request with the type of application/x-www-form-urlencoded.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@646281 13f79535-47bb-0310-9956-ffa450edef68
2008-04-09 11:39:58 +00:00
Paul Querna
a6c8063f22 Add major bump for removing ap_graceful_stop_signalled
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@645551 13f79535-47bb-0310-9956-ffa450edef68
2008-04-07 15:06:42 +00:00
Joe Orton
cc34f73c89 * include/http_request.h: Fix warning with gcc -Wall.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@645472 13f79535-47bb-0310-9956-ffa450edef68
2008-04-07 12:09:02 +00:00
Paul Querna
5fa2bbbdeb Remove ap_graceful_stop_signalled from all MPMs.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@645437 13f79535-47bb-0310-9956-ffa450edef68
2008-04-07 10:00:32 +00:00