1
0
mirror of https://github.com/apache/httpd.git synced 2025-06-03 10:42:03 +03:00

211 Commits

Author SHA1 Message Date
Jean-Frederic Clere
a0c15d9c9b Fix the warning:
mod_proxy.c:284: warning: passing argument 1 of 'ap_strchr' discards qualifiers from pointer target type
Thanks Joe for catch it.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@551935 13f79535-47bb-0310-9956-ffa450edef68
2007-06-29 16:08:24 +00:00
Jean-Frederic Clere
3fe0224692 Don't display "PHPSESSIONID | PHPSESSIONID" but only
"PHPSESSIONID".


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@551126 13f79535-47bb-0310-9956-ffa450edef68
2007-06-27 11:39:03 +00:00
Jean-Frederic Clere
9e567f96de Remove the balancer modification logic of balancer-manager
because it can't work. And add the sticky_path to the
sticky display.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@551099 13f79535-47bb-0310-9956-ffa450edef68
2007-06-27 08:42:02 +00:00
Jean-Frederic Clere
4dee811cb9 Add sticky_path to solve PR41897.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@550519 13f79535-47bb-0310-9956-ffa450edef68
2007-06-25 14:42:25 +00:00
Jim Jagielski
09c3cbe87b Fold in ProxyPassMatch directive with docs. Support
full regex substitution but also allow for "simple"
cases (ala JkMount) to work as well.



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@537599 13f79535-47bb-0310-9956-ffa450edef68
2007-05-13 15:28:29 +00:00
Jim Jagielski
5fdd230cc1 Add regex pattern matching to ProxyPass, allowing,
for example:

   ProxyPass ~ \.gif balancer://imagecluster




git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@537429 13f79535-47bb-0310-9956-ffa450edef68
2007-05-12 14:12:24 +00:00
Nick Kew
d14f70a89f Return METHOD_NOT_ALLOWED, not FORBIDDEN, to a TRACE request when
TraceEnable is Off.  This agrees with our documentation, and with
our Allow: header in response to OPTIONS.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@507526 13f79535-47bb-0310-9956-ffa450edef68
2007-02-14 13:34:38 +00:00
Nick Kew
45c507dd7c Patch for PR#11540 (submitted by Stuart Children)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@507516 13f79535-47bb-0310-9956-ffa450edef68
2007-02-14 12:56:49 +00:00
Mladen Turk
6a68c112dc Enable retry=0 for the worker.
This allows to have an option to always retry
the workers in error state instead using a
specified time.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@451575 13f79535-47bb-0310-9956-ffa450edef68
2006-09-30 10:41:51 +00:00
Ruediger Pluem
ef038e0617 * Print the correct error message for erroneous configured ProxyPass directives.
PR: 40439
Submitted by: serai lans-tv.com
Reviewed by: rpluem


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@441947 13f79535-47bb-0310-9956-ffa450edef68
2006-09-10 12:37:21 +00:00
Joe Orton
b3265c64fb * modules/proxy/mod_proxy.c (proxysection): Fix another strchr() warning.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@428291 13f79535-47bb-0310-9956-ffa450edef68
2006-08-03 09:33:35 +00:00
Mladen Turk
78f6ef0859 Allow optional name=value options within <Proxy
section line. Additional arguments are allowed
only for 'standard' url's, meaning that the wildchar
urls will return error like before.
This allow to specify the worker/balancer parameters
on the definition line, without the need for extra
ProxySet options.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@427928 13f79535-47bb-0310-9956-ffa450edef68
2006-08-02 07:59:47 +00:00
Mladen Turk
20a4dc5137 Enable ProxySet inside <Proxy> section to
create balancer or worker if they were not
already created.
This allows to have ProxySet directive before
BalancerMember directives inside Proxy section.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@427920 13f79535-47bb-0310-9956-ffa450edef68
2006-08-02 06:54:01 +00:00
Jim Jagielski
61a56451a3 Add in a very simple balancer "set" concept, which allows
for members to be assigned to a particular cluster set
such that members in lower-numbered sets are checked/used
before those in higher ones.

Also bundled in this are some HTML cleanups for the balancer
manager UI. Sorry for the mixins :)

Compiles/builds clean: passes test framework as well
as more normal usage tests ;)


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@427172 13f79535-47bb-0310-9956-ffa450edef68
2006-07-31 17:01:40 +00:00
Mladen Turk
4fd2c57da0 Added cping/cpong support for the AJP protocol.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@425454 13f79535-47bb-0310-9956-ffa450edef68
2006-07-25 16:50:07 +00:00
Nick Kew
a3f4adfa28 Use <string.h>-compatible versions of ap_str* functions.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@422178 13f79535-47bb-0310-9956-ffa450edef68
2006-07-15 08:39:41 +00:00
Jim Jagielski
58c0a69c7b Don't down cast
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@421959 13f79535-47bb-0310-9956-ffa450edef68
2006-07-14 17:34:59 +00:00
Nick Kew
346c6c3e76 Support environment variable interpolation in reverse proxy configuration
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@421686 13f79535-47bb-0310-9956-ffa450edef68
2006-07-13 19:00:26 +00:00
Jean-Frederic Clere
2afcfcfe6d Issue a warning when the same worker name is reused.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@421252 13f79535-47bb-0310-9956-ffa450edef68
2006-07-12 12:08:36 +00:00
Jim Jagielski
0b80babf0b Add in hot-standby balancer member. If all other members
are disabled or not-usable, ONLY THEN will the hot
standby's be used.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@420986 13f79535-47bb-0310-9956-ffa450edef68
2006-07-11 20:39:38 +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
dede56b14d Document the removal of the flushing bandaid to a
runtime param. Since other protocols might benefit
from this, remove the ajp_ prefixes, to make it
more generic looking.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@390210 13f79535-47bb-0310-9956-ffa450edef68
2006-03-30 18:32:53 +00:00
Jim Jagielski
391472a050 Make AJP flushing admin configurable.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@384580 13f79535-47bb-0310-9956-ffa450edef68
2006-03-09 18:39:16 +00:00
Ruediger Pluem
06c6bde4c6 * revert r355823 and r355837
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@355853 13f79535-47bb-0310-9956-ffa450edef68
2005-12-11 01:28:13 +00:00
Ruediger Pluem
614df45f1e * Move handling of backends that broke after the headers have been sent
into the proxy handler of mod_proxy.

  This patch still sets r->connection->aborted to 1 which is currently
  vetoed by Roy. Moving it from the scheme handler to the proxy handler
  should ease the reimplementation of this, as the scheme handlers only
  needs to return PROXY_BACKEND_BROKEN to signal the above situation to
  the proxy handler.

  mod_proxy.h: Add define for PROXY_BACKEND_BROKEN
  mod_proxy.c: Handle PROXY_BACKEND_BROKEN in proxy handler
  mod_proxy_http.c: Sent back PROXY_BACKEND_BROKEN if backend broke
  after we sent the headers.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@355823 13f79535-47bb-0310-9956-ffa450edef68
2005-12-11 00:15:27 +00:00
Jeff Trawick
3a67f28030 Fix typo in ProxyStatus syntax error message.
Submitted by: Christophe Jaillet <christophe.jaillet wanadoo.fr>
Reviewed by:  trawick


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@344491 13f79535-47bb-0310-9956-ffa450edef68
2005-11-16 01:31:44 +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
Ruediger Pluem
00933409fe * Fix PR36906 by not lower caseing the whole worker name. Only lower case the
schema when storing the worker url. Thus preventing case sensitive URI's in
  BalancerMembers to get broken.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@328463 13f79535-47bb-0310-9956-ffa450edef68
2005-10-25 19:54:11 +00:00
Ruediger Pluem
16051d9681 * run the request_status hook in proxy_handler if HTTP_SERVICE_UNAVAILABLE
is returned by ap_proxy_pre_request.

Suggested by: Brian Akins <brian.akins turner.com>, Mladen Turk
Reviewed by: Jim Jagielski


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@293123 13f79535-47bb-0310-9956-ffa450edef68
2005-10-02 14:32:35 +00:00
Joe Orton
8df46b6dd6 * modules/proxy/mod_proxy_balancer.c (balancer_handler): Fix gcc
warning; no functional change.

* modules/proxy/mod_proxy.c (set_balancer_param): Likewise.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@279973 13f79535-47bb-0310-9956-ffa450edef68
2005-09-10 09:10:27 +00:00
Jim Jagielski
22c5cb4728 Proxy balancer lbmethods are now registered as providers and not
via hooks. Move various find() functions back to mod_proxy_balancer
where they belong :)


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@279752 13f79535-47bb-0310-9956-ffa450edef68
2005-09-09 12:28:02 +00:00
Jim Jagielski
54bb998b3a Minor nit. Methods are server-wide, so simply use the base version table.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@279319 13f79535-47bb-0310-9956-ffa450edef68
2005-09-07 13:14:16 +00:00
Jim Jagielski
da3e833d30 Restruct of lbmethod find-best algo's, bypassing hook mechanism.
Looking into provider method, but until then... Prevent core dump
when balancer not in vhosts


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@279305 13f79535-47bb-0310-9956-ffa450edef68
2005-09-07 12:04:15 +00:00
Jim Jagielski
a7d488a6d2 simple, functional interface to add additional balancer lb selection methods
without requiring code changes to mod_proxy/mod_proxy_balancer;
these can be implemented via sub-modules now.

Let the games begin...


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@232282 13f79535-47bb-0310-9956-ffa450edef68
2005-08-12 12:47:04 +00:00
Nick Kew
9d7b5928db Fix build error from cut&paste
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@231501 13f79535-47bb-0310-9956-ffa450edef68
2005-08-11 18:52:16 +00:00
Nick Kew
d153de58fe Fix ProxyPassReverse & family to work correctly in <Location>
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@231355 13f79535-47bb-0310-9956-ffa450edef68
2005-08-10 23:36:39 +00:00
Mladen Turk
e7479bf114 Add status param option so that current worker
status can be changed via editing httpd.conf instead
just using web page. Seems the ApacheCon is paying of.
Thanks to Sander for pointing that out.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@225751 13f79535-47bb-0310-9956-ffa450edef68
2005-07-28 11:16:34 +00:00
Ian Holsman
9ffe8c5d1a This patch adds a new hook (request_status) that gets ran in proxy_handler
just before the final return.  This gives modules an opportunity to do
something based on the proxy status.

A couple of examples where this is useful:

-You are using a caching module and would rather return stale content rather
than an error to the client if the origin is down.

-you proxy some subrequests (using SSI - mod_include) and do not want SSI
errors when the backend is down. If you would normally return
HTTP_BAD_GATEWAY, you may have a module that serves some other content.


new hook -- so mmn bump.. i made it a major one, hope thats ok 

Patch From Brian Akins <Brian.Akins turner.com>




git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@219372 13f79535-47bb-0310-9956-ffa450edef68
2005-07-17 05:12:10 +00:00
William A. Rowe Jr
d2ff850241 End abuse of apr_strnat[case]cmp - it isn't str[case]cmp.
Unsure if apr_strnatcasecmp(conf_ip, uri_ip) was intentional, on the
  off chance that the left or right hand ip string happens to contain
  leading zeros.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@216111 13f79535-47bb-0310-9956-ffa450edef68
2005-07-13 04:43:59 +00:00
William A. Rowe Jr
179ca062fd This test for TraceEnable cases cannot be buried within the max-forwards
logic cases.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@209406 13f79535-47bb-0310-9956-ffa450edef68
2005-07-06 04:10:50 +00:00
William A. Rowe Jr
d90cbe8650 Plug AllowTrace extended|on|off into proxy and http core.
It still is not 'correct' until REQUEST_CHUNKED_PASS is reimplemented
  and passes some chunk headers, since we aren't echoing the entire
  request.  But it gets me further on testing 1.3 -> 2.0 -> 2.1 -> 2.0 -> 1.3
  proxy behaviors.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@208787 13f79535-47bb-0310-9956-ffa450edef68
2005-07-01 19:59:59 +00:00
Paul Querna
c84966321a Make sure mod_rewrite always runs before mod_proxy in the translate_name hook. This makes doing RewriteRules on a Reverse Proxy.. Slightly more predictable than the order of LoadModules.
Reported By: David D. Miller <justdave bugzilla.org>


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@169692 13f79535-47bb-0310-9956-ffa450edef68
2005-05-11 20:11:44 +00:00
Mladen Turk
9fac5c4376 Add failover to mod proxy. If the service is unavailable,
check another worker in case this is balancer request.
In case the error in unrecoverable, fail with returned
status code.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@160848 13f79535-47bb-0310-9956-ffa450edef68
2005-04-11 08:45:15 +00:00
Mladen Turk
363117e7a1 Move direct_connect out of attempt loop. No need to
calculate that value on each attempt, because it's always
the same.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@160705 13f79535-47bb-0310-9956-ffa450edef68
2005-04-09 18:33:00 +00:00
Mladen Turk
0eab042f6a Use two optional functions from mod_ssl so that we
can receive both is_ssl and ssl_var for ajp protocol.
This is combined work based on patch from Brad Boyer and
Joe Orton's suggestion to use ssl_var_lookup.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@160690 13f79535-47bb-0310-9956-ffa450edef68
2005-04-09 16:16:54 +00:00
Joe Orton
a0570c8746 Move the POSIX reg* implementations into the ap_* namespace;
internalise the ap_reg*<->PCRE wrapper:

* configure.in: Add srclib/pcre to the include path.

* include/ap_regex.h: Renamed from include/pcreposix.h.  Prefix all
constants with AP_; prefix all functions and types with ap_.  Define
AP_DECLARE to nothing if necessary.  Remove regcomp error codes.

* include/httpd.h: Include ap_regex.h not pcreposix.h.
(ap_pregcomp, ap_regexec, ap_regfree): s/regex_t/ap_regex_t/.
(ap_regexec, ap_regerror): Prototypes moved to ap_regex.h.

* server/util.c (regex_cleanup, ap_pregcomp, ap_pregsub, ap_pregfree):
Adjust for ap_ prefixed types.  (ap_regexec, ap_regerror): Removed.

* server/Makefile.in: Build util_pcre.c.

* server/util_pcre.c: Copied from srclib/pcre/pcreposix.c; remove use
of PCRE-internals to do error mapping; rename types to add AP_/ap_
prefixes as above.  Use APR includes.  (ap_regerror): Use apr_snprintf.

* srclib/pcre/Makefile.in: Don't build pcreposix.c into libpcre.la.

* modules/*: Update to use new type and constant names.

PR: 27750 (part one)
Submitted by: Andres Salomon <dilinger voxel.net>, Joe Orton


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@153384 13f79535-47bb-0310-9956-ffa450edef68
2005-02-11 12:00:41 +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
Justin Erenkrantz
632ec345e9 mod_proxy: Fix ProxyRemoteMatch directive.
PR: 33170
Submitted by: Rici Lake <rici ricilake.net>
Reviewed by:  Justin Erenkrantz


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@151248 13f79535-47bb-0310-9956-ffa450edef68
2005-02-03 23:18:48 +00:00
Sander Striker
4162b98a0f Clean up some crumbs... The sandwich is next.
* modules\proxy\mod_proxy.c

  (alias_match): Removed unused variables.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@151241 13f79535-47bb-0310-9956-ffa450edef68
2005-02-03 22:05:06 +00:00