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

89 Commits

Author SHA1 Message Date
Bradley Nicholes
74c5908625 Allow the enabled flag to be set to more than just TRUE or FALSE so that
the OPTIONAL flag can be correctly merged within the
ssl_config_server_merge() function.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@102860 13f79535-47bb-0310-9956-ffa450edef68
2004-03-05 02:44:40 +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
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
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
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
f74d7f0f69 Provide a far more useful explanation when SSLCryptoDevice fails to
find a device.  Still would be nice to implement dynamic:{options}
  but this gets us to display the usual, builtin devices.

  We now load builtin engines up front, in the pre_config phase, because
  this and any other config cmd processor must have an already valid
  library config.  So loading builtin engines becomes redundant in this
  cmd handler.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@100108 13f79535-47bb-0310-9956-ffa450edef68
2003-05-30 21:01:57 +00:00
William A. Rowe Jr
fb9c4b137c Based on list discussion between myself and Geoff, it seems prudent
to check for both the existence of the openssl/engine.h header file
  and some 'expected function' such as ENGINE_init() (better suggestions
  are welcome.)  Also clear up some confusion; so long as we have
  ENGINE_load_builtin_engines() we should attempt to preload those.

  This patch protects all ENGINE-based code within the tests for the
  engine header and function, and changes a version test into a
  function test.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@100104 13f79535-47bb-0310-9956-ffa450edef68
2003-05-30 18:41:53 +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
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
William A. Rowe Jr
60eda291ab Per JimJ's review - we prefer posix over semv, fcntl over flock,
and semv requires no file.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@99100 13f79535-47bb-0310-9956-ffa450edef68
2003-03-28 00:43:26 +00:00
William A. Rowe Jr
5d8f1b974a Addendum to r1.74; Keep only the resulting filename in the global pool,
toss the temporary strings away.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@99097 13f79535-47bb-0310-9956-ffa450edef68
2003-03-28 00:00:13 +00:00
William A. Rowe Jr
199b44f0af Allow any mutex to accept a 'filename' ... and always root it to the
server root unless we are using posixsem, which can't handle big paths.
  This reorganization should make the code much more readable because
  all of the common code is at the beginning and end of the function,
  simplifing the long conditional test case block.

  This patch allows SSLMutex default:logs/ssl_mutex syntax.  It also
  removes the mod_ssl historical '.pid' suffixes - that isn't how Apache2
  specifies files.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@99094 13f79535-47bb-0310-9956-ffa450edef68
2003-03-27 23:32:42 +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
Jim Jagielski
74d8971f72 2 silly bugs. First of all, make the code match the error log
(and allow 8192 to be valid). Secondly, this missplaced else
made the size part (8192) non-optional for shm:
PR:
Obtained from:
Submitted by:
Reviewed by:


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@97281 13f79535-47bb-0310-9956-ffa450edef68
2002-10-22 23:18:14 +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
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
Doug MacEachern
d07edc0f48 copy-n-pasto: ssl_cmd_SSLProxyMachineCertificatePath needs to set cert_path
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94404 13f79535-47bb-0310-9956-ffa450edef68
2002-04-02 21:56:12 +00:00
Doug MacEachern
26a5b7fc7c fix copy-n-pasto: ssl_cmd_SSLProxyCACertificatePath needs to use
ssl_cmd_check_dir rather than ssl_cmd_check_file


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94403 13f79535-47bb-0310-9956-ffa450edef68
2002-04-02 21:32: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
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
409e7fed52 s/id/mode/ in ssl_cmd_SSLProxyVerify
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94290 13f79535-47bb-0310-9956-ffa450edef68
2002-03-29 03:19:12 +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
987edc67d2 s/ctx/dcfg/g in ssl directive handlers
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94287 13f79535-47bb-0310-9956-ffa450edef68
2002-03-29 02:48:20 +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
543660842b add ssl_config_server_new function to fold some duplication in server
create/merge and to make sure merge config is fully inititialized


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94280 13f79535-47bb-0310-9956-ffa450edef68
2002-03-29 02:00:20 +00:00
Doug MacEachern
3539d5de18 inititialize and merge proxy config
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94279 13f79535-47bb-0310-9956-ffa450edef68
2002-03-29 01:56:40 +00:00
Doug MacEachern
6b105970df no point in merging things which are not set until after merge happens.
make a note of those which are set during module init.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94278 13f79535-47bb-0310-9956-ffa450edef68
2002-03-29 01:42:04 +00:00
Doug MacEachern
d5116bceb9 'ctx' traditionally refers to an SSL_CTX. change modssl_ctx_t
instances to 'mctx'


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94277 13f79535-47bb-0310-9956-ffa450edef68
2002-03-29 01:24:10 +00:00
Doug MacEachern
b08517ce8e ctx->sc is set during init
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94275 13f79535-47bb-0310-9956-ffa450edef68
2002-03-28 19:50:48 +00:00
Doug MacEachern
78b02f8110 switch from SSLSrvConfigRec* to modssl_ctx_t* in the ssl_init_ctx*
functions


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94274 13f79535-47bb-0310-9956-ffa450edef68
2002-03-28 19:48:31 +00:00
Doug MacEachern
038f201cbb make merging of modssl_ctx_t's generic
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94273 13f79535-47bb-0310-9956-ffa450edef68
2002-03-28 19:15:03 +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
1d76ab39ff breakup SSLSrvConfigRec in preparation for proxy support:
+ modssl_pk_server_t - certs/keys for the server
+ modssl_pk_proxy_t  - certs/keys for the proxy
+ modssl_auth_ctx_t  - stuff related to authentication that can also
                       be per-dir, used by both server and proxy
+ modssl_ctx_t       - context that can be used by both server and proxy
+ SSLSrvConfigRec    - now contains original stuff specific to the
                       server config and modssl_ctx_t *server, *proxy


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94267 13f79535-47bb-0310-9956-ffa450edef68
2002-03-28 18:50:07 +00:00
Doug MacEachern
e90c7fb27f ripping out some proxy stuff that isn't currently in use and is going
to change anyhow.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94266 13f79535-47bb-0310-9956-ffa450edef68
2002-03-28 17:23:50 +00:00
Doug MacEachern
d5c395f0e7 de-hungarian-ize server config member names which are going to stay
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94264 13f79535-47bb-0310-9956-ffa450edef68
2002-03-28 17:11:12 +00:00
Doug MacEachern
bb986b6b22 reorder a bit of the server config structure, moving items that are
going to stay there to the top.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94263 13f79535-47bb-0310-9956-ffa450edef68
2002-03-28 16:47:36 +00:00
Doug MacEachern
8bf48c5959 "new" is a c++ keyword; s/new/mrg/g in config merge functions
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94244 13f79535-47bb-0310-9956-ffa450edef68
2002-03-27 23:35:31 +00:00
Doug MacEachern
aeb7f9eb0b add configure checks for ssl functions:
-SSL_set_state: macro in OpenSSL, might be a function in a patched sslc
-SSL_set_cert_store: patch submitted to OpenSSL, might be applied to
OpenSSL or sslc


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94223 13f79535-47bb-0310-9956-ffa450edef68
2002-03-27 17:02:56 +00:00
Doug MacEachern
008b963af9 sslc does not currently support RAND_egd or RAND_status
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94207 13f79535-47bb-0310-9956-ffa450edef68
2002-03-27 03:27:13 +00:00
Doug MacEachern
7c1521f253 per-dir SSLCACertificate{File,Path} cannot use SSL_CTX_set_cert_store
as the 1.x based module does, since the function is not thread-safe.
a patch has been submitted to OpenSSL to support SSL_set_cert_store
which is thread safe.  this feature is enabled by default in the
current 1.x based module, we only enable it if the SSL_set_cert_store
function is available.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94179 13f79535-47bb-0310-9956-ffa450edef68
2002-03-26 16:57:49 +00:00
Doug MacEachern
9303382216 constificationization of some char * config items
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94177 13f79535-47bb-0310-9956-ffa450edef68
2002-03-26 15:49:37 +00:00
Doug MacEachern
6fba41424d performance enhancement: mod_ssl config directives that can have both
a per-server and per-dir context were configuring the per-dir context
for per-server commands.  this triggered ssl_hook_Access to always
compare the per-server context against per-dir configs that were
exactly the same.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94176 13f79535-47bb-0310-9956-ffa450edef68
2002-03-26 15:42:21 +00:00