summaryrefslogtreecommitdiffhomepage
path: root/src/http/modules
diff options
context:
space:
mode:
Diffstat (limited to 'src/http/modules')
-rw-r--r--src/http/modules/ngx_http_ssl_module.c (renamed from src/http/modules/ngx_http_ssl_filter.c)25
-rw-r--r--src/http/modules/ngx_http_ssl_module.h (renamed from src/http/modules/ngx_http_ssl_filter.h)8
-rw-r--r--src/http/modules/proxy/ngx_http_proxy_handler.h2
3 files changed, 19 insertions, 16 deletions
diff --git a/src/http/modules/ngx_http_ssl_filter.c b/src/http/modules/ngx_http_ssl_module.c
index 1d370be2d..3a8b863a2 100644
--- a/src/http/modules/ngx_http_ssl_filter.c
+++ b/src/http/modules/ngx_http_ssl_module.c
@@ -11,10 +11,9 @@
static void *ngx_http_ssl_create_srv_conf(ngx_conf_t *cf);
static char *ngx_http_ssl_merge_srv_conf(ngx_conf_t *cf,
void *parent, void *child);
-static ngx_int_t ngx_http_ssl_init_process(ngx_cycle_t *cycle);
-static ngx_command_t ngx_http_charset_filter_commands[] = {
+static ngx_command_t ngx_http_ssl_commands[] = {
{ ngx_string("ssl"),
NGX_HTTP_SRV_CONF|NGX_CONF_FLAG,
@@ -41,7 +40,7 @@ static ngx_command_t ngx_http_charset_filter_commands[] = {
};
-static ngx_http_module_t ngx_http_ssl_filter_module_ctx = {
+static ngx_http_module_t ngx_http_ssl_module_ctx = {
NULL, /* pre conf */
NULL, /* create main configuration */
@@ -55,13 +54,13 @@ static ngx_http_module_t ngx_http_ssl_filter_module_ctx = {
};
-ngx_module_t ngx_http_ssl_filter_module = {
+ngx_module_t ngx_http_ssl_module = {
NGX_MODULE,
- &ngx_http_ssl_filter_module_ctx, /* module context */
- ngx_http_charset_filter_commands, /* module directives */
+ &ngx_http_ssl_module_ctx, /* module context */
+ ngx_http_ssl_commands, /* module directives */
NGX_HTTP_MODULE, /* module type */
NULL, /* init module */
- ngx_http_ssl_init_process /* init process */
+ NULL /* init process */
};
@@ -102,13 +101,13 @@ static char *ngx_http_ssl_merge_srv_conf(ngx_conf_t *cf,
conf->ssl_ctx = SSL_CTX_new(SSLv23_server_method());
if (conf->ssl_ctx == NULL) {
- ngx_ssl_error(NGX_LOG_EMERG, cf->log, "SSL_CTX_new() failed");
+ ngx_ssl_error(NGX_LOG_EMERG, cf->log, 0, "SSL_CTX_new() failed");
return NGX_CONF_ERROR;
}
if (SSL_CTX_use_certificate_file(conf->ssl_ctx, conf->certificate.data,
SSL_FILETYPE_PEM) == 0) {
- ngx_ssl_error(NGX_LOG_EMERG, cf->log,
+ ngx_ssl_error(NGX_LOG_EMERG, cf->log, 0,
"SSL_CTX_use_certificate_file(\"%s\") failed",
conf->certificate.data);
return NGX_CONF_ERROR;
@@ -116,7 +115,7 @@ static char *ngx_http_ssl_merge_srv_conf(ngx_conf_t *cf,
if (SSL_CTX_use_PrivateKey_file(conf->ssl_ctx, conf->certificate_key.data,
SSL_FILETYPE_PEM) == 0) {
- ngx_ssl_error(NGX_LOG_EMERG, cf->log,
+ ngx_ssl_error(NGX_LOG_EMERG, cf->log, 0,
"SSL_CTX_use_PrivateKey_file(\"%s\") failed",
conf->certificate_key.data);
return NGX_CONF_ERROR;
@@ -126,6 +125,8 @@ static char *ngx_http_ssl_merge_srv_conf(ngx_conf_t *cf,
}
+#if 0
+
static ngx_int_t ngx_http_ssl_init_process(ngx_cycle_t *cycle)
{
ngx_uint_t i;
@@ -138,7 +139,7 @@ static ngx_int_t ngx_http_ssl_init_process(ngx_cycle_t *cycle)
cscfp = cmcf->servers.elts;
for (i = 0; i < cmcf->servers.nelts; i++) {
- sscf = cscfp[i]->ctx->srv_conf[ngx_http_ssl_filter_module.ctx_index];
+ sscf = cscfp[i]->ctx->srv_conf[ngx_http_ssl_module.ctx_index];
if (sscf->enable) {
cscfp[i]->recv = ngx_ssl_recv;
@@ -148,3 +149,5 @@ static ngx_int_t ngx_http_ssl_init_process(ngx_cycle_t *cycle)
return NGX_OK;
}
+
+#endif
diff --git a/src/http/modules/ngx_http_ssl_filter.h b/src/http/modules/ngx_http_ssl_module.h
index a42ee9135..2bb1fe1fe 100644
--- a/src/http/modules/ngx_http_ssl_filter.h
+++ b/src/http/modules/ngx_http_ssl_module.h
@@ -1,5 +1,5 @@
-#ifndef _NGX_HTTP_SSL_FILTER_H_INCLUDED_
-#define _NGX_HTTP_SSL_FILTER_H_INCLUDED_
+#ifndef _NGX_HTTP_SSL_H_INCLUDED_
+#define _NGX_HTTP_SSL_H_INCLUDED_
#include <ngx_config.h>
@@ -24,7 +24,7 @@ ngx_chain_t *ngx_http_ssl_write(ngx_connection_t *c, ngx_chain_t *in,
void ngx_http_ssl_close_connection(SSL *ssl, ngx_log_t *log);
-extern ngx_module_t ngx_http_ssl_filter_module;
+extern ngx_module_t ngx_http_ssl_module;
-#endif /* _NGX_HTTP_SSL_FILTER_H_INCLUDED_ */
+#endif /* _NGX_HTTP_SSL_H_INCLUDED_ */
diff --git a/src/http/modules/proxy/ngx_http_proxy_handler.h b/src/http/modules/proxy/ngx_http_proxy_handler.h
index c89e971dc..fa8698231 100644
--- a/src/http/modules/proxy/ngx_http_proxy_handler.h
+++ b/src/http/modules/proxy/ngx_http_proxy_handler.h
@@ -203,7 +203,7 @@ typedef struct {
} ngx_http_proxy_log_ctx_t;
-#define NGX_HTTP_PROXY_PARSE_NO_HEADER 20
+#define NGX_HTTP_PROXY_PARSE_NO_HEADER 30
#define NGX_HTTP_PROXY_FT_ERROR 0x02