Return-Path: Delivered-To: apmail-apache-cvs-archive@apache.org Received: (qmail 40737 invoked by uid 500); 23 Sep 2000 18:39:31 -0000 Mailing-List: contact apache-cvs-help@apache.org; run by ezmlm Precedence: bulk Reply-To: new-httpd@apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list apache-cvs@apache.org Received: (qmail 40720 invoked by uid 500); 23 Sep 2000 18:39:31 -0000 Delivered-To: apmail-apache-2.0-cvs@apache.org Date: 23 Sep 2000 18:39:30 -0000 Message-ID: <20000923183930.40713.qmail@locus.apache.org> From: rbb@locus.apache.org To: apache-2.0-cvs@apache.org Subject: cvs commit: apache-2.0/src/main http_core.c http_protocol.c http_request.c rbb 00/09/23 11:39:30 Modified: src CHANGES src/main http_core.c http_protocol.c http_request.c Log: Combine the calls to add the core_filter to one place. Basically, it is safe to add the core_filter during the post_read_request, and it means that we only have to add the filter once in the code. This should make it easier to add an SSL module in the future. Revision Changes Path 1.237 +5 -0 apache-2.0/src/CHANGES Index: CHANGES =================================================================== RCS file: /home/cvs/apache-2.0/src/CHANGES,v retrieving revision 1.236 retrieving revision 1.237 diff -u -r1.236 -r1.237 --- CHANGES 2000/09/23 00:05:44 1.236 +++ CHANGES 2000/09/23 18:39:28 1.237 @@ -1,5 +1,10 @@ Changes with Apache 2.0a7 + *) Move the addition of the CORE filter to the post_read_request + hook in http_core.c. This removes the need to add the filter in + multiple places and allows for an SSL module to be added much + simpler. [Ryan Bloom] + *) Fix a security problem that affects certain configurations of mod_rewrite. If the result of a RewriteRule is a filename that contains expansion specifiers, especially regexp backreferences 1.130 +6 -0 apache-2.0/src/main/http_core.c Index: http_core.c =================================================================== RCS file: /home/cvs/apache-2.0/src/main/http_core.c,v retrieving revision 1.129 retrieving revision 1.130 diff -u -r1.129 -r1.130 --- http_core.c 2000/09/22 20:36:20 1.129 +++ http_core.c 2000/09/23 18:39:29 1.130 @@ -3284,6 +3284,11 @@ static unsigned short core_port(const request_rec *r) { return DEFAULT_HTTP_PORT; } +static int core_post_read_req(request_rec *r) +{ + ap_add_filter("CORE", NULL, r); +} + static void core_register_filter(request_rec *r) { int i; @@ -3310,6 +3315,7 @@ /* FIXME: I suspect we can eliminate the need for these - Ben */ ap_hook_type_checker(do_nothing,NULL,NULL,AP_HOOK_REALLY_LAST); ap_hook_access_checker(do_nothing,NULL,NULL,AP_HOOK_REALLY_LAST); + ap_hook_post_read_request(core_post_read_req, NULL, NULL, AP_HOOK_REALLY_FIRST); /* define the CORE filter, then register a hook to insert it at * request-processing time. 1.131 +0 -2 apache-2.0/src/main/http_protocol.c Index: http_protocol.c =================================================================== RCS file: /home/cvs/apache-2.0/src/main/http_protocol.c,v retrieving revision 1.130 retrieving revision 1.131 diff -u -r1.130 -r1.131 --- http_protocol.c 2000/09/21 16:22:13 1.130 +++ http_protocol.c 2000/09/23 18:39:29 1.131 @@ -1200,8 +1200,6 @@ r->status = HTTP_REQUEST_TIME_OUT; /* Until we get a request */ r->the_request = NULL; - ap_add_filter("CORE", NULL, r); - #ifdef APACHE_XLATE r->rrx = apr_pcalloc(p, sizeof(struct ap_rr_xlate)); ap_set_content_xlate(r, 0, ap_locale_from_ascii); 1.51 +0 -2 apache-2.0/src/main/http_request.c Index: http_request.c =================================================================== RCS file: /home/cvs/apache-2.0/src/main/http_request.c,v retrieving revision 1.50 retrieving revision 1.51 diff -u -r1.50 -r1.51 --- http_request.c 2000/09/19 23:50:36 1.50 +++ http_request.c 2000/09/23 18:39:30 1.51 @@ -1388,8 +1388,6 @@ apr_table_setn(new->subprocess_env, "REDIRECT_STATUS", apr_psprintf(r->pool, "%d", r->status)); - ap_add_filter("CORE", NULL, new); - /* * XXX: hmm. This is because mod_setenvif and mod_unique_id really need * to do their thing on internal redirects as well. Perhaps this is a