1
0
mirror of https://github.com/apache/httpd.git synced 2025-11-06 16:49:32 +03:00
Commit Graph

146 Commits

Author SHA1 Message Date
Graham Leggett
bf820c3251 Fix some compiler warnings in proxy
PR:
Obtained from:
Submitted by:	Geoffrey Young <geoff@modperlcookbook.org>
Reviewed by:


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@104708 13f79535-47bb-0310-9956-ffa450edef68
2004-08-18 13:34:17 +00:00
William A. Rowe Jr
787adb7c05 Start porting connection pool to ftp.
Submitted by: mturk


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@104626 13f79535-47bb-0310-9956-ffa450edef68
2004-08-11 23:28:58 +00:00
Jeff Trawick
b0d1112a81 style fix only
(previously committed from user-supplied patch)


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@104148 13f79535-47bb-0310-9956-ffa450edef68
2004-07-03 12:25:11 +00:00
Graham Leggett
c61e73c2a5 Small fix to allow reverse proxying to an ftp server. Previously
an attempt to do this would try and connect to 0.0.0.0, regardless
of the server specified.
PR:	24922
Obtained from:
Submitted by:	Pascal Terjan <pterjan@linuxfr.org>
Reviewed by:


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@103725 13f79535-47bb-0310-9956-ffa450edef68
2004-05-21 22:05:31 +00:00
Jeff Trawick
3b16ac459e apr_pstrcat() needs NULL at end of parameter list to know
when to stop (mississi^#@75UiSIGSEGV)


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@103699 13f79535-47bb-0310-9956-ffa450edef68
2004-05-19 16:15:53 +00:00
Jeff Trawick
7d99a3c077 Fix handling of IPv6 numeric strings in mod_proxy.
(Some such operations would work if port was specified
in url due to way parsing was performed, finding last ':'
and considering everything after as the port.)


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@103698 13f79535-47bb-0310-9956-ffa450edef68
2004-05-19 13:30:14 +00:00
André Malo
c7031febd3 Fix a bunch of cases where the return code of the regex compiler
was not checked properly. This affects: mod_setenvif, mod_usertrack,
mod_proxy, mod_proxy_ftp and core.

PR: 28218


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@103328 13f79535-47bb-0310-9956-ffa450edef68
2004-04-10 13:57:39 +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
3d75c8c079 fix copyright dates according to the first check in
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@102572 13f79535-47bb-0310-9956-ffa450edef68
2004-02-08 12:27:14 +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
Jeff Trawick
07e907f0c2 stop using apr_sockaddr_port_get() accessor function, as it will
disappear from APR 1.0 API shortly


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@101991 13f79535-47bb-0310-9956-ffa450edef68
2003-12-05 00:59:29 +00:00
Sander Striker
67a3a71877 Fold in the CAN-2003-0542 regex patch.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@101556 13f79535-47bb-0310-9956-ffa450edef68
2003-10-24 16:20:28 +00:00
Jeff Trawick
aa21671e13 switch to APR 1.0 API (which is still in flux)
because of the changes to the argument lists of apr_mmap_dup and apr_socket_create,
2.1-dev won't build with apr and apr-util's 0.9 branch anymore


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@101154 13f79535-47bb-0310-9956-ffa450edef68
2003-09-03 19:27:12 +00:00
Sander Striker
320d035eaa Forward port security patch for CAN-2003-0254 from 2.0.
SECURITY [CAN-2003-0254]: Fixed a bug in ftp proxy causing denial
of service when target host is IPv6 but proxy server can't create
IPv6 socket.  Fixed by the reporter.  [Yoshioka Tsuneo
<tsuneo.yoshioka@f-secure.com>]


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@100516 13f79535-47bb-0310-9956-ffa450edef68
2003-07-09 12:19:01 +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
Ian Holsman
b0db736597 PR:
Obtained from:
Submitted by:	Alexey Panchenko alexey@liwest.ru
Reviewed by:


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@96439 13f79535-47bb-0310-9956-ffa450edef68
2002-08-18 21:01:06 +00:00
Jeff Trawick
9cf303e9bc Get proxy ftp to work over IPv6.
Submitted by:                      Shoichi Sakane <sakane@kame.net>
Reviewed and modified slightly by: Jeff Trawick


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@96100 13f79535-47bb-0310-9956-ffa450edef68
2002-07-17 17:55:59 +00:00
William A. Rowe Jr
ed8fc9abae http occurances to update for apr_socket_opt_get/set
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@96057 13f79535-47bb-0310-9956-ffa450edef68
2002-07-15 08:05:11 +00:00
William A. Rowe Jr
6b69fe06c0 Timeout/time fixes
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@96055 13f79535-47bb-0310-9956-ffa450edef68
2002-07-15 07:46:19 +00:00
Victor J. Orlikowski
d982829aa1 Continue the Bill Rowe apr_size_t crusade.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95993 13f79535-47bb-0310-9956-ffa450edef68
2002-07-10 06:01:14 +00:00
Ian Holsman
6deba78a9a Renames Pending:
This clears the list of renames pending in apr-util.
 Parts of this list was alreadu done, but the pending list hadn't been updated.

 apr_hook_debug_current     from apr_current_hooking_module
 apr_hook_debug_show        from apr_show_hook

 apr_hook_global_pool       from apr_global_hook_pool
 apr_hook_sort_all          from apr_sort_hooks

 apr_uri_port_of_scheme     from apr_uri_default_port_for_scheme
 apr_uri_unparse            from apr_uri_unparse_components
 apr_uri_parse              from apr_uri_parse_components
 apr_uri_parse_hostinfo     from apr_uri_parse_hostinfo_components

 apr_uri_t                  from apr_uri_components

 All APR_URI_*              from all APU_URI_* symbols
 All APR_UNP_*              from all UNP_* symbols

PR:
Obtained from:
Submitted by:	 Thom May
Reviewed by:


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95966 13f79535-47bb-0310-9956-ffa450edef68
2002-07-06 20:04:38 +00:00
Justin Erenkrantz
798c1dae43 Add a filter_init function to the filters so that a filter can execute
arbitrary code before the handlers are invoked.

This resolves an issue with incorrect 304s on If-Modified-Since mod_include
requests since ap_meets_conditions() is not aware that this is a dynamic
request and it is not possible to satisfy 304 for these requests (unless
xbithack full is on, of course).  When mod_include runs as a filter, it is
too late to set any flag since the handler is responsible for calling
ap_meets_conditions(), which it should do before generating any data.

If a module doesn't need to run such arbitrary code, it can just pass NULL
as the argument and all is well.

PR:	9673
Reviewed by:	Ryan Bloom and others


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95906 13f79535-47bb-0310-9956-ffa450edef68
2002-06-28 08:40:25 +00:00
William A. Rowe Jr
f8511d81d8 No crutches, people!
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95854 13f79535-47bb-0310-9956-ffa450edef68
2002-06-23 06:06:25 +00:00
William A. Rowe Jr
3f6aa521eb Cleanup proxy timeouts a bit to remove emits and make consistent to
vhost timeout.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95674 13f79535-47bb-0310-9956-ffa450edef68
2002-06-14 17:14:57 +00:00
William A. Rowe Jr
7af68c0bf5 Solve the 80/20 by initializing and storing server_rec->timeout and
server_rec->keep_alive_timeout in apr_time_interval_t format (in apr
  units, whatever they be), as both values exist to pass into APR, and
  all APR timeouts are in apr_time_t.

Reviewed by:	Cliff Woolley


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95623 13f79535-47bb-0310-9956-ffa450edef68
2002-06-12 23:59:31 +00:00
Jeff Trawick
50bac91072 stop using APLOG_NOERRNO in calls to ap_log_[pr]error()
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95150 13f79535-47bb-0310-9956-ffa450edef68
2002-05-17 11:24:17 +00:00
Jeff Trawick
3b7f35cd82 fix a compile break on EBCDIC machines
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94812 13f79535-47bb-0310-9956-ffa450edef68
2002-04-26 14:43:18 +00:00
Jeff Trawick
d439ef140b get mod_proxy to build on EBCDIC machines
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94808 13f79535-47bb-0310-9956-ffa450edef68
2002-04-25 22:12:51 +00:00
Cliff Woolley
3e2ce19baf BUCKET FREELISTS
Add an allocator-passing mechanism throughout the bucket brigades API.

From Apache's standpoint, the apr_bucket_alloc_t* used throughout a given
connection is stored in the conn_rec by the create_connection hook.  That
means it's the MPM's job to optimize recycling of apr_bucket_alloc_t's --
the MPM must ensure that no two threads can ever use the same one at the
same time, for instance.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94304 13f79535-47bb-0310-9956-ffa450edef68
2002-03-29 08:17:26 +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
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
Graham Leggett
01b5958cf7 New directive ProxyIOBufferSize. Sets the size of the buffer used
when reading from a remote HTTP server in proxy.

Modify receive/send loop in proxy_http and proxy_ftp so that
should it be necessary, the remote server socket is closed before
transmitting the last buffer (set by ProxyIOBufferSize) to the
client. This prevents the backend server from being forced to hang
around while the last few bytes are transmitted to a slow client.
Fix the case where no error checking was performed on the final
brigade in the loop.
PR:
Obtained from:
Submitted by:
Reviewed by:


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93811 13f79535-47bb-0310-9956-ffa450edef68
2002-03-09 07:15:33 +00:00
Justin Erenkrantz
3058b601ff As hinted on dev@httpd, change filter naming schemes to match our
expectations of their usage.

The reason that we should make this change now is that we have changed
the implied meaning of AP_FTYPE_HTTP_HEADER - some users of this should
be PROTOCOL while others should be CONTENT_SET.  In order to clarify it,
toss all of the bogus names and force the filter writers to make sure
they understand what they are doing.

CONTENT_SET is new (horrible name - change if you have better idea), but
it indicates that it should run between RESOURCE and PROTOCOL.
mod_deflate is the ideal CONTENT_SET filter.

The changed type names are:
CONTENT is now RESOURCE.
HTTP_HEADER is now PROTOCOL.  However, most filters that used HTTP_HEADER
may want CONTENT_SET.  (Only things like POP and HTTP belong as PROTOCOL.)

MMN bump since all filters need to be recompiled due to filter reordering.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93756 13f79535-47bb-0310-9956-ffa450edef68
2002-03-07 09:27:17 +00:00
Ryan Bloom
862f407872 Remove the install_transport_filters hook. The same function can be
acheived with the pre_connection hook.  I have added the socket to the
pre_connection phase to make this possible.
Reviewed by:	Bill Stoddard


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93259 13f79535-47bb-0310-9956-ffa450edef68
2002-02-05 22:18:49 +00:00
Martin Kraemer
34e0d8cf5d Oops. Use ftp_check_globbingchars().
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93217 13f79535-47bb-0310-9956-ffa450edef68
2002-02-04 10:11:29 +00:00
Martin Kraemer
c5ef15249d And update the year....
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93216 13f79535-47bb-0310-9956-ffa450edef68
2002-02-04 10:07:10 +00:00
Martin Kraemer
9f645d6622 React (in the dir lister) on the same globbing chars as used in the escaping routine
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93215 13f79535-47bb-0310-9956-ffa450edef68
2002-02-04 10:06:37 +00:00
Justin Erenkrantz
59874f5443 Make sure we include time.h if it is there. (Other mojo may be needed for
other platforms.)


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93201 13f79535-47bb-0310-9956-ffa450edef68
2002-02-03 17:18:18 +00:00
Bill Stoddard
bd3d360392 Reintroduce the create_connection hook. This hook is required to enable
modules to completely take over all network i/o from the core.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93171 13f79535-47bb-0310-9956-ffa450edef68
2002-02-01 22:16:31 +00:00
Martin Kraemer
5b7ceb18a9 Add MDTM support if supported by the FTP server, and if either
timegm() exists or struct tm has a tm_gmtoff field (needed for
easily converting the time string to a GMT timestamp).
Escaping for ftp path arguments now uses a dedicated escaping
routine (in order to only escape globbing characters, not all
shell meta characters).
Execute the SIZE query with the same TYPE setting as the RETR transfer,
because the SIZE may be calculated differently for ASCII files.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93128 13f79535-47bb-0310-9956-ffa450edef68
2002-01-31 14:48:51 +00:00
Martin Kraemer
f6e4afd31b Eliminate variables where unneeded; move ";type=" checking code to front;
drop redundant log messages (covered by proxy_ftp_command());
do checks for /%2f as in apache-1.3.24;
escape path argument in SIZE command


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93120 13f79535-47bb-0310-9956-ffa450edef68
2002-01-30 22:41:59 +00:00
Ian Holsman
8cf569593b add a ProxyTimeout directive
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93117 13f79535-47bb-0310-9956-ffa450edef68
2002-01-30 18:46:56 +00:00
Martin Kraemer
0a372f9393 Minor tipos
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93111 13f79535-47bb-0310-9956-ffa450edef68
2002-01-30 15:30:09 +00:00
Martin Kraemer
abf7e5464b Of course, more wildcard characters
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93110 13f79535-47bb-0310-9956-ffa450edef68
2002-01-30 15:14:39 +00:00
Martin Kraemer
de3c03c970 Port the "squid %2f hack" from apache_1.3.24.
It is now possible to browse the root directory by using a url
like:   ftp://user@host/%2f/
Also, the last path component may contain wildcard characters
'*' and '?', and if they do, a directory listing is created instead
of a file retrieval. Example: ftp://user@host/httpd/server/*.c


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93108 13f79535-47bb-0310-9956-ffa450edef68
2002-01-30 15:07:48 +00:00
Martin Kraemer
8ae6ee9022 Oops, sorry. Lost one line.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93107 13f79535-47bb-0310-9956-ffa450edef68
2002-01-30 14:59:46 +00:00
Martin Kraemer
1d76ccd517 Something sets the content_encoding, even if a directory listing
is going to be returned. Hack: unset the content_encoding if
dirlisting == TRUE.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93106 13f79535-47bb-0310-9956-ffa450edef68
2002-01-30 14:56:42 +00:00
Martin Kraemer
e135391780 For the ftp commands CWD and RETR, do escaping for the path elements,
because FTP servers do globbing, which we do not want for filenames
from the directory listing.
PR:
Obtained from:
Submitted by:
Reviewed by:


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@93105 13f79535-47bb-0310-9956-ffa450edef68
2002-01-30 14:54:18 +00:00