mirror of
https://github.com/apache/httpd.git
synced 2025-08-08 15:02:10 +03:00
PR:
Obtained from: Submitted by: Reviewed by: Ryan Bloom ap_remove_output_filter no longer works for connection filters. change logic in the case of "HTTP spoken on HTTPS port" to disable the ssl filters rather than attempt to remove the filters. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94393 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@@ -743,6 +743,13 @@ static apr_status_t ssl_io_input_getline(ssl_io_input_ctx_t *ctx,
|
||||
sizeof(HTTP_ON_HTTPS_PORT) - 1, \
|
||||
alloc)
|
||||
|
||||
static void ssl_io_filter_disable(ap_filter_t *f)
|
||||
{
|
||||
ssl_io_input_ctx_t *ctx = f->ctx;
|
||||
ctx->inbio.ssl = NULL;
|
||||
ctx->frec->pssl = NULL;
|
||||
}
|
||||
|
||||
static apr_status_t ssl_io_filter_error(ap_filter_t *f,
|
||||
apr_bucket_brigade *bb,
|
||||
apr_status_t status)
|
||||
@@ -758,6 +765,7 @@ static apr_status_t ssl_io_filter_error(ap_filter_t *f,
|
||||
|
||||
/* fake the request line */
|
||||
bucket = HTTP_ON_HTTPS_PORT_BUCKET(f->c->bucket_alloc);
|
||||
ssl_io_filter_disable(f);
|
||||
break;
|
||||
|
||||
default:
|
||||
@@ -781,6 +789,10 @@ static apr_status_t ssl_io_filter_Input(ap_filter_t *f,
|
||||
apr_size_t len = sizeof(ctx->buffer);
|
||||
int is_init = (mode == AP_MODE_INIT);
|
||||
|
||||
if (!ctx->inbio.ssl) {
|
||||
return ap_get_brigade(f->next, bb, mode, block, readbytes);
|
||||
}
|
||||
|
||||
/* XXX: we don't currently support anything other than these modes. */
|
||||
if (mode != AP_MODE_READBYTES && mode != AP_MODE_GETLINE &&
|
||||
mode != AP_MODE_SPECULATIVE && mode != AP_MODE_INIT) {
|
||||
|
Reference in New Issue
Block a user