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

150 Commits

Author SHA1 Message Date
Joe Orton
0f7f4106a3 * modules/ssl/mod_ssl.h: Declare ssl_is_https optional function.
* modules/ssl/ssl_engine_vars (ssl_is_https): New function.
(ssl_var_register): Register it.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@102850 13f79535-47bb-0310-9956-ffa450edef68
2004-03-04 13:06:54 +00:00
Joe Orton
3ca3524c31 Move mod_ssl-internal interfaces into ssl_private.h; allow mod_ssl.h
to be included even when mod_ssl is not enabled.

* Makefile.in (install-include): Only install mod_ssl.h.

* modules/ssl/ssl_private.h: New file.

* modules/ssl/mod_ssl.h: Move everything apart from than the optional
hook definitions into ssl_private.h.

* modules/ssl/*.c: Include ssl_private.h not mod_ssl.h

* modules/ssl/config.m4: Always add the mod_ssl directory to the
include path so other modules can find mod_ssl.h.

* modules/proxy/mod_proxy.c: Include mod_ssl.h to pick up the optional
hook definitions rather than copy'n'pasting them.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@102803 13f79535-47bb-0310-9956-ffa450edef68
2004-02-28 18:06:35 +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
0b6155c539 fix copyright dates according to the first check in
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@102573 13f79535-47bb-0310-9956-ffa450edef68
2004-02-08 12:52:25 +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
Joe Orton
223c481ae9 * modules/ssl/ssl_scache_dc.c: Add the Apache Software License.
* modules/ssl/mod_ssl.h: Undo accidental comment change in previous
commit.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@102228 13f79535-47bb-0310-9956-ffa450edef68
2004-01-08 16:40:18 +00:00
Joe Orton
3c52d23027 Add support to mod_ssl for a distributed session cache using
distcache.

* LAYOUT: Update for removal of scache_shmht and addition of scache_dc.

* modules/ssl/config.m4: Check for libdistcache; build ssl_scache_dc.lo.

* modules/ssl/mod_ssl.dsp: Build ssl_scache_dc (with luck).

* modules/ssl/mod_ssl.h: Add SSL_SCMODE_DC and scache_dc_* prototypes.

* modules/ssl/ssl_engine_config.c (ssl_cmd_SSLSessionCache): Allow
use of dc: argument.

* modules/ssl/ssl_scache_dc.c: New file.

* modules/ssl/ssl_scache.c (ssl_scache_init, ssl_scache_kill,
ssl_scache_store, ssl_scache_retrieve, ssl_scache_remove,
ssl_ext_status_hook): Hook into scache_dc.

Submitted by: Geoff Thorpe <geoff@geoffthorpe.net>


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@102227 13f79535-47bb-0310-9956-ffa450edef68
2004-01-08 16:26:53 +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
Joe Orton
2dbba35cc6 * modules/ssl/mod_ssl.h: Remove prototypes for shmht.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@101900 13f79535-47bb-0310-9956-ffa450edef68
2003-11-26 09:34:15 +00:00
Joe Orton
e2e8cc8e79 Extend mod_status output to include SSL session cache status
information:

* modules/ssl/mod_ssl.c (ssl_hook_pre_config): Call
ssl_scache_status_register.

* modules/ssl/ssl_scache.c (ssl_scache_status): Removed function.
(ssl_ext_status_hook): Renamed from ssl_ext_ms_display: switch to
2.1's mod_status "status_hook" API.
(ssl_scache_status_register): Register optional hook.

* modules/ssl/ssl_scache_dbm.c (ssl_scache_dbm_status): Adjust to use
new API.

* modules/ssl/ssl_scache_shmcb.c (ssl_scache_shmcb_status): Adjust
to use new API.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@101889 13f79535-47bb-0310-9956-ffa450edef68
2003-11-25 16:59:10 +00:00
Joe Orton
9ddbb80f51 Remove shmht session cache in favour of shmcb; shmht has had
data corruption bugs since being apr_rmm'ified.

* config.m4, mod_ssl.dsp: Don't build ssl_util_table and
ssl_scache_shmht.

* ssl_util_table.h, ssl_util_table.c, ssl_scache_shmht.c: Removed
files.

* mod_ssl.h (SSLModConfigRec): Use a void * pointer for storing
the scache-specific data.

* ssl_engine_config.c (ssl_cmd_SSLSessionCache): Treat shmht: as
shmcb:.

* ssl_scache.c: Remove shmht hooks throughout.

* ssl_scache_shmcb.c: Remove casts to use the table_t * pointer as a
void *.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@101888 13f79535-47bb-0310-9956-ffa450edef68
2003-11-25 15:46:37 +00:00
Cliff Woolley
d42d73e282 Make mod_ssl consistent with itself when you have a halfass install of
openssl-engine (ie, you're missing the headers).  ssl_cmd_SSLCryptoDevice()
is thrown away by the preprocessor if you're missing the header, so the
call to it should have the same condition applied.  otherwise, mod_ssl
will fail to link.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@100970 13f79535-47bb-0310-9956-ffa450edef68
2003-08-12 20:58:53 +00:00
Jeff Trawick
78fc3f4c59 not valid to modify string pointed to by szCryptoDevice... it points to a
static string or something parsed from the config


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@100603 13f79535-47bb-0310-9956-ffa450edef68
2003-07-14 17:16:47 +00:00
Martin Kraemer
a4da940b99 Needed on EBCDIC systems
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@100313 13f79535-47bb-0310-9956-ffa450edef68
2003-06-20 12:50:11 +00:00
Jeff Trawick
8f0cd048e0 Unix: Handle permissions settings for flock-based mutexes in
unixd_set_global|proc_mutex_perms().  Allow the functions to be
called for any type of mutex.

This resolves a fatal problem with mod_rewrite on systems where
APR uses flock-based mutex.

It simplifies mod_ssl as well, which had special logic to perform
the chown().  It fixed an init error with mod_ssl on systems where
flock is used when the user had no SSLMutex directive.

The Unix MPMs continue to call unixd_set_global|proc_mutex_perms()
only for SysV sems.  There is no permission problem with flock-based
accept mutexes since the child init logic for the MPMs is done
prior to switching identity.

PR:              20312


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@100189 13f79535-47bb-0310-9956-ffa450edef68
2003-06-07 19:50:01 +00:00
William A. Rowe Jr
a5708f15e6 Roll away the SSL_EXPERIMENTAL_ENGINE test in favor of testing for the
ENGINE_init() function in config.m4, and rely on HAVE_ENGINE_INIT instead.

Reviewed by: Ben Laurie (concept)


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@99919 13f79535-47bb-0310-9956-ffa450edef68
2003-05-19 14:48:47 +00:00
William A. Rowe Jr
8f2145c831 Why wouldn't this be a mod_ssl header?
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@99871 13f79535-47bb-0310-9956-ffa450edef68
2003-05-16 18:22:44 +00:00
Justin Erenkrantz
ec469e2318 Further breakage from r.1.131: MODSSL_INFO_CB_ARG_TYPE also includes the *.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@99279 13f79535-47bb-0310-9956-ffa450edef68
2003-04-06 19:40:40 +00:00
Justin Erenkrantz
483bdf7afd Fix compile breakage introduced in r1.131.
MODSSL_INFO_CB_ARG_TYPE already includes 'SSL' in its type.  Don't duplicate.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@99278 13f79535-47bb-0310-9956-ffa450edef68
2003-04-06 19:36:19 +00:00
William A. Rowe Jr
474812c956 Solve SSL-C breakage introduced in mod_ssl.h rev 1.129 and
ssl_engine_kernel.c rev 1.88.  SSL* is not const under SSL-C.

  I've confirmed Jeff's comment that the original patch doesn't harm
  earlier OpenSSL versions which declared no arguments at all.

  I suspect now that we could fold
     #define MODSSL_BIO_CB_ARG_TYPE const char
     #define MODSSL_CRYPTO_CB_ARG_TYPE const char
     #define MODSSL_INFO_CB_ARG_TYPE const SSL*
  into a single MODSSL_CB_ARG_CONST define, but this works for now.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@99263 13f79535-47bb-0310-9956-ffa450edef68
2003-04-05 22:45:28 +00:00
Jeff Trawick
805422eb77 get function prototypes for strcasecmp() and strncasecmp()
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@99202 13f79535-47bb-0310-9956-ffa450edef68
2003-04-04 04:02:01 +00:00
Jeff Trawick
4901acb22a Fix a compile failure with recent OpenSSL and picky compilers
(e.g., OpenSSL 0.9.7a and xlc_r on AIX).

The OpenSSL info callback field changed recently from a generic
function pointer to a specific one, and ssl_callback_LogTracingState
wasn't quite right.

old:
ssl.h:        void (*info_callback)();

new:
ssl.h:        void (*info_callback)(const SSL *ssl,int type,int val);


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@99201 13f79535-47bb-0310-9956-ffa450edef68
2003-04-04 03:57:10 +00:00
William A. Rowe Jr
e25454c894 Introduce a number of SSLC hints to mod_ssl, including the following
type overrides;

    MODSSL_CLIENT_CERT_CB_ARG_TYPE
    MODSSL_PCHAR_CAST      (for a host of non-void/const sslc values)
    modssl_read_bio_cb_fn  (for several callbacks with same prototypes)

  Declare callback functions appropriately.

  And protect us from indetermineant toolkits with
  #error "Unrecognized SSL Toolkit!"


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@99183 13f79535-47bb-0310-9956-ffa450edef68
2003-04-03 04:54:20 +00:00
Jim Jagielski
0deed15fe7 Because SSL's child init is run *after* we change uid/gid. So we need to ensure that file-based
locks have the correct perms so that the child process
can access them


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@99104 13f79535-47bb-0310-9956-ffa450edef68
2003-03-29 02:18:43 +00:00
Madhusudan Mathihalli
aea3ed09fb OpenSSL should be included as "openssl/ssl.h" and not "ssl.h" (and rely on the
INCLUDE path to be defined properly)

PR: 11310
Submitted by: Geoff Thrope <geoff@geoffthrope.net>
Reviewed by: Madhusudan Mathihalli


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@99008 13f79535-47bb-0310-9956-ffa450edef68
2003-03-14 02:20:50 +00:00
Jim Jagielski
694eb48bae Right now SSLMutex is bogus. It just uses APR_LOCK_DEFAULT no
matter what. We now allow for the full range of APR mutex
locking mechanims to be used, while maintaining backwards
compatibility.

PR: 8122
Obtained from:
Submitted by:
Reviewed by:	William Rowe


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@98771 13f79535-47bb-0310-9956-ffa450edef68
2003-02-23 17:12:43 +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
William A. Rowe Jr
2f62c790c7 After some productive feedback and no negative feedback, introduce
SSLEngine upgrade so that we can begin and continue to support these
  facilities.  This makes it simpler to keep this effort (while we have
  no known clients that support Connection: upgrade at this time), and
  begin refactoring more of SSL into smaller and tighter (and then optional)
  components.

  Submitted by: Ryan Bloom
  Reviewed by: William Rowe, Joe Orton


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@97912 13f79535-47bb-0310-9956-ffa450edef68
2002-12-14 07:46:45 +00:00
William A. Rowe Jr
dce6e3383f Merge the last of the 'filtering' functions into ssl_engine_io.c, merge
ssl_abort into what was ssl_hook_CloseConnection, clean out a bunch of
  now-static or private headers from mod_ssl.h, and final fix a very small
  but potent segfault if ->pssl is destroyed within our read loop.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@97411 13f79535-47bb-0310-9956-ffa450edef68
2002-11-05 20:47:01 +00:00
Ryan Bloom
658c2437bd This stuff shouldn't have been committed. This is the SSL upgrade stuff,
and it was included in a commit that shouldn't have touched these files.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@97201 13f79535-47bb-0310-9956-ffa450edef68
2002-10-14 04:15:58 +00:00
Ryan Bloom
37f9061757 Fix a compile of compiler warnings. I don't know how these slipped past.
Also, uncomment a line of code that the last commit should have uncommented.
Randall found this line and the fix, but I forgot to uncomment this line
along with the fix.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@97179 13f79535-47bb-0310-9956-ffa450edef68
2002-10-11 15:29:22 +00:00
Ryan Bloom
37f858acc6 Remove all special mod_ssl URIs. This also fixes the bug where
redirecting (.*) will allow an SSL protected page to be viewed
without SSL.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95501 13f79535-47bb-0310-9956-ffa450edef68
2002-06-04 07:12:26 +00:00
William A. Rowe Jr
4a621ec661 The only remaining question ... are nested or strictly unnested locks
expected by OpenSSL?  Right now I've left it as _DEFAULT for the platform
  preference.  Very simple code really - the server_rec was superfluous.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95497 13f79535-47bb-0310-9956-ffa450edef68
2002-06-04 02:19:33 +00:00
Justin Erenkrantz
fafabb637f Remove SSLLog and SSLLogLevel directives in favor of having mod_ssl use the
standard ErrorLog directives.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95129 13f79535-47bb-0310-9956-ffa450edef68
2002-05-16 06:09:13 +00:00
Justin Erenkrantz
d28c4dae36 Stop using SSL_ADD_SSLERR option in ssl_log() and replace with new
ssl_log_ssl_error() function that wraps ap_log_error instead.

This begins the migration from ssl_log() -> ap_log_error().  Divorcing
ourselves from the SSL_ADD_SSLERR option is required to make the next
pass easier.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@95122 13f79535-47bb-0310-9956-ffa450edef68
2002-05-15 23:10:33 +00:00
Aaron Bannert
9ff0d84088 Convert mod_ssl to the new apr_global_mutex.h API and remove all
uses of apr_lock.h [deprecated]. Tested that I could serve simple
SSL (v3) pages.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94583 13f79535-47bb-0310-9956-ffa450edef68
2002-04-09 15:53:09 +00:00
Doug MacEachern
bb2d86e811 PR: 7802
Obtained from:
Submitted by:
Reviewed by:
fix compilation problem in ssl_engine_kernel.c
if SSL_LIBRARY_VERSION >= 0x00907000


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94527 13f79535-47bb-0310-9956-ffa450edef68
2002-04-07 21:58:25 +00:00
Doug MacEachern
1138615486 fix ProxyPass when frontend is https and backend is http
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94515 13f79535-47bb-0310-9956-ffa450edef68
2002-04-07 03:37:35 +00:00
Doug MacEachern
3fa9f2ba65 add SSLProxyCARevocation{File,Path} directives to support CRLs in the proxy
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94338 13f79535-47bb-0310-9956-ffa450edef68
2002-03-30 06:46:24 +00:00
Doug MacEachern
663baf331b pass sc to myCtxConfig macro
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94337 13f79535-47bb-0310-9956-ffa450edef68
2002-03-30 06:38:10 +00:00
Doug MacEachern
97b59112b8 make it possible for proxy to use CRL callback
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94336 13f79535-47bb-0310-9956-ffa450edef68
2002-03-30 06:36:56 +00:00
Doug MacEachern
a456732c3f add myCtxConfig macro
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94331 13f79535-47bb-0310-9956-ffa450edef68
2002-03-30 05:57:59 +00:00
Doug MacEachern
9ee8bc12b5 implement proxy client certificate callback
(uses SSLProxyMachineCertificate{File,Cert} when downstream server
requires a client certificate)


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94329 13f79535-47bb-0310-9956-ffa450edef68
2002-03-30 05:40:02 +00:00
Cliff Woolley
5b5cccc4ae Fix the version string. We want to end up with "mod_ssl/2.0.xx", not
"mod_ssl/Apache/2.0.xx".


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94320 13f79535-47bb-0310-9956-ffa450edef68
2002-03-30 00:00:21 +00:00
Doug MacEachern
5e1c0e2c15 add SSLProxyEngine directive. this was not required in the 1.x based
mod_ssl because the SSL_CTX was created and configured for *every*
request.  unlike in 2.0 where we configure the proxy SSL_CTX at
startup time, which is much better for performance.  but we don't want
to configure a proxy context for every vhost if it isn't going to be
used, for the same reasons we don't create a server context for every
vhost unless SSLEngine is on.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94314 13f79535-47bb-0310-9956-ffa450edef68
2002-03-29 17:56:33 +00:00
Doug MacEachern
722125d944 add optional function (ssl_proxy_enable) to turn on ssl proxy
choose SSL_CTX based on SSLConnRec.is_proxy


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94293 13f79535-47bb-0310-9956-ffa450edef68
2002-03-29 04:50:37 +00:00
Doug MacEachern
f9f62ab460 use ssl_cmd_verify_parse for SSLProxyVerify directive handler
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94289 13f79535-47bb-0310-9956-ffa450edef68
2002-03-29 03:05:49 +00:00
Doug MacEachern
b31faa5036 enable proxy directives
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94286 13f79535-47bb-0310-9956-ffa450edef68
2002-03-29 02:43:33 +00:00
Doug MacEachern
0679fa7bf1 moving cfgMerge macros to ssl_engine_config.c, they are not used anywhere else
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94271 13f79535-47bb-0310-9956-ffa450edef68
2002-03-28 18:58:06 +00:00
Doug MacEachern
045abcfbbd remove unused cfgMerge{Table,Ctx} macros
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94269 13f79535-47bb-0310-9956-ffa450edef68
2002-03-28 18:54:52 +00:00