Commit 18bab434 authored by Martin Kraemer's avatar Martin Kraemer
Browse files

Rename the module structures so that the exported symbol matches

the file name, and it is easier to automate the installation
process (generating LoadModule directives from the module filenames).

Next step is to remove the 4th argument to the APACHE_MODULE macro
completely and require people to use the matching names, and to
reduce the LoadModule directive to 1 argument.... Objections?


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@88189 13f79535-47bb-0310-9956-ffa450edef68
parent 3d39e7c4
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
Changes with Apache 2.0.12-dev

  *) Rename the module structures so that the exported symbol matches
     the file name, and it is easier to automate the installation
     process (generating LoadModule directives from the module filenames).
     [Martin Kraemer]

  *) Remove the coalesce filter.  With the ap_f* functions, this filter
     is no longer needed. [Ryan Bloom]

+4 −4
Original line number Diff line number Diff line
@@ -6,15 +6,15 @@ APACHE_MODPATH_INIT(aaa)

APACHE_MODULE(access, host-based access control, , , yes)
APACHE_MODULE(auth, user-based access control, , , yes)
APACHE_MODULE(auth_anon, anonymous user access, , anon_auth, no)
APACHE_MODULE(auth_dbm, DBM-based access databases, , dbm_auth, no)
APACHE_MODULE(auth_anon, anonymous user access, , , no)
APACHE_MODULE(auth_dbm, DBM-based access databases, , , no)

APACHE_MODULE(auth_db, DB-based access databases, , db_auth, no, [
APACHE_MODULE(auth_db, DB-based access databases, , , no, [
  AC_CHECK_HEADERS(db.h)
  AC_CHECK_LIB(db,main)
]) 

APACHE_MODULE(auth_digest, digests, , digest_auth, no)
APACHE_MODULE(auth_digest, RFC2617 Digest authentication, , , no)

LTFLAGS="$LTFLAGS -export-dynamic"

+4 −4
Original line number Diff line number Diff line
@@ -217,13 +217,13 @@ static const command_rec anon_auth_cmds[] =
    {NULL}
};

module AP_MODULE_DECLARE_DATA anon_auth_module;
module AP_MODULE_DECLARE_DATA auth_anon_module;

static int anon_authenticate_basic_user(request_rec *r)
{
    anon_auth_config_rec *sec =
    (anon_auth_config_rec *) ap_get_module_config(r->per_dir_config,
					       &anon_auth_module);
					       &auth_anon_module);
    const char *sent_pw;
    int res = DECLINED;

@@ -284,7 +284,7 @@ static int check_anon_access(request_rec *r)
    conn_rec *c = r->connection;
    anon_auth_config_rec *sec =
    (anon_auth_config_rec *) ap_get_module_config(r->per_dir_config,
					       &anon_auth_module);
					       &auth_anon_module);

    if (!sec->anon_auth)
	return DECLINED;
@@ -303,7 +303,7 @@ static void register_hooks(apr_pool_t *p)
    ap_hook_auth_checker(check_anon_access,NULL,NULL,APR_HOOK_MIDDLE);
}

module AP_MODULE_DECLARE_DATA anon_auth_module =
module AP_MODULE_DECLARE_DATA auth_anon_module =
{
    STANDARD20_MODULE_STUFF,
    create_anon_auth_dir_config,/* dir config creater */
+5 −5
Original line number Diff line number Diff line
@@ -75,7 +75,7 @@
 *           instead of   AuthDBMUserFile    AuthDBMGroupFile
 *
 * Also, in the configuration file you need to specify
 *  db_auth_module rather than auth_dbm_module
 *  auth_db_module rather than auth_dbm_module
 *
 * On some BSD systems (e.g. FreeBSD and NetBSD) dbm is automatically
 * mapped to Berkeley DB. You can use either mod_auth_dbm or
@@ -161,7 +161,7 @@ static const command_rec db_auth_cmds[] =
    {NULL}
};

module db_auth_module;
module auth_db_module;

static char *get_db_pw(request_rec *r, char *user, const char *auth_dbpwfile)
{
@@ -293,7 +293,7 @@ static int db_authenticate_basic_user(request_rec *r)
{
    db_auth_config_rec *sec =
    (db_auth_config_rec *) ap_get_module_config(r->per_dir_config,
						&db_auth_module);
						&auth_db_module);
    const char *sent_pw;
    char *real_pw, *colon_pw;
    apr_status_t invalid_pw;
@@ -341,7 +341,7 @@ static int db_check_auth(request_rec *r)
{
    db_auth_config_rec *sec =
    (db_auth_config_rec *) ap_get_module_config(r->per_dir_config,
						&db_auth_module);
						&auth_db_module);
    char *user = r->user;
    int m = r->method_number;

@@ -404,7 +404,7 @@ static void register_hooks(apr_pool_t *p)
    ap_hook_auth_checker(db_check_auth,NULL,NULL,APR_HOOK_MIDDLE);
}

module db_auth_module =
module auth_db_module =
{
    STANDARD20_MODULE_STUFF,
    create_db_auth_dir_config,	/* dir config creater */
+5 −5
Original line number Diff line number Diff line
@@ -101,7 +101,7 @@
 *
 * XXX: this needs updating for apache-2.0 configuration method
 * MODULE-DEFINITION-START
 * Name: dbm_auth_module
 * Name: auth_dbm_module
 * ConfigStart
    . ./helpers/find-dbm-lib
 * ConfigEnd
@@ -156,7 +156,7 @@ static const command_rec dbm_auth_cmds[] =
    {NULL}
};

module AP_MODULE_DECLARE_DATA dbm_auth_module;
module AP_MODULE_DECLARE_DATA auth_dbm_module;

static char *get_dbm_pw(request_rec *r, char *user, char *auth_dbmpwfile)
{
@@ -237,7 +237,7 @@ static int dbm_authenticate_basic_user(request_rec *r)
{
    dbm_auth_config_rec *sec =
    (dbm_auth_config_rec *) ap_get_module_config(r->per_dir_config,
					      &dbm_auth_module);
					      &auth_dbm_module);
    const char *sent_pw;
    char *real_pw, *colon_pw;
    apr_status_t invalid_pw;
@@ -280,7 +280,7 @@ static int dbm_check_auth(request_rec *r)
{
    dbm_auth_config_rec *sec =
    (dbm_auth_config_rec *) ap_get_module_config(r->per_dir_config,
					      &dbm_auth_module);
					      &auth_dbm_module);
    char *user = r->user;
    int m = r->method_number;

@@ -344,7 +344,7 @@ static void register_hooks(apr_pool_t *p)
    ap_hook_auth_checker(dbm_check_auth, NULL, NULL, APR_HOOK_MIDDLE);
}

module AP_MODULE_DECLARE_DATA dbm_auth_module =
module AP_MODULE_DECLARE_DATA auth_dbm_module =
{
    STANDARD20_MODULE_STUFF,
    create_dbm_auth_dir_config,	/* dir config creater */
Loading