@DPATCH@
diff -urNad mod-auth-mysql~/DIRECTIVES mod-auth-mysql/DIRECTIVES
---- mod-auth-mysql~/DIRECTIVES 2008-05-14 16:59:28.000000000 +0200
-+++ mod-auth-mysql/DIRECTIVES 2008-05-14 20:08:22.000000000 +0200
+--- mod-auth-mysql~/DIRECTIVES 2008-05-14 20:24:12.000000000 +0200
++++ mod-auth-mysql/DIRECTIVES 2008-05-14 20:46:56.000000000 +0200
@@ -1,23 +1,27 @@
All the directives understood by this version of mod-auth-mysql are listed
-below. The huge number of synonym directives is due to the merging of two
AuthName "<Realm>"
Describes the data you're guarding.
-@@ -96,48 +98,30 @@
+@@ -96,27 +98,18 @@
The name of the MySQL table in the specified database which stores
username:password pairs. By default, it is 'mysql_auth'.
Auth_MySQL_Password_Field <password_field_name>
As per ...Username_Field above, but for passwords. Same MySQL
access privileges. Defaults to 'password'.
-
--AuthMySQL_Password_Field <password_field_name>
-- Synonym for Auth_MySQL_Password_Field.
--
- Auth_MySQL_Group_Field <group_field_name>
- As per ...Username_Field above. Defaults to 'groups'.
+@@ -128,9 +121,6 @@
+ As per ...Username_Field above. Defaults to 'groups'. The query
+ will use FIND_IN_SET(<group_name>,<group_field_name>).
-AuthMySQL_Group_Field <group_field_name>
- Synonym for Auth_MySQL_Group_Field.
Auth_MySQL_Group_User_Field <field_name>
The name of the field in the groups table which stores the username.
Defaults to the field name specified for usernames in the passwords
- table.
-
--AuthMySQL_Group_User_Field <field_name>
-- Synonym for Auth_MySQL_Group_User_Field.
--
- Auth_MySQL_Password_Clause <SQL fragment>
- Adds arbitrary clause to username:password matching query, for example:
- " AND Allowed=1". Clause has to start with space. Default is empty.
-@@ -146,6 +130,9 @@
+@@ -147,6 +137,9 @@
Adds arbitrary clause to username:group matching query, for example:
" AND Allowed=1". Clause has to start with space. Default is empty.
Auth_MySQL_Empty_Passwords <on/off>
Whether or not to allow empty passwords. If the password field is
empty (equals to '') and this option is 'on', users would be able to
-@@ -153,9 +140,6 @@
+@@ -154,9 +147,6 @@
PASSWORD CHECKING. If this is 'off', they would be denied access.
Default: 'on'.
Auth_MySQL_Encryption_Types <type_list>
Select which types of encryption to check, and in which order to
-@@ -204,9 +188,6 @@
+@@ -205,9 +195,6 @@
MySQL
The hashing scheme used by the MySQL PASSWORD() function.
Auth_MySQL_Encrypted_Passwords <on/off> (DEPRECATED)
Equivalent to: Auth_MySQL_Encryption_Types Crypt_DES
Only used if ...Encryption_Types is not set. Defaults to 'on'. If
-@@ -214,17 +195,11 @@
+@@ -215,17 +202,11 @@
...Encryption_Types is not set, passwords are expected to be in
plaintext.
Auth_MySQL_Authoritative <on/off>
Whether or not to use other authentication schemes if the user is
successfully authenticated. That is, if the user passes the MySQL
-@@ -232,9 +207,6 @@
+@@ -233,9 +214,6 @@
option is set 'off'. The default is 'on' (i.e. if the user passes
the MySQL module, they're considered OK).
Auth_MySQL_Non_Persistent <on/off>
If set to 'on', the link to the MySQL server is explicitly closed
after each authentication request. Note that I can't think of any
-@@ -244,10 +216,10 @@
+@@ -245,10 +223,10 @@
increase the maximum number of simultaneous threads in MySQL and
keep this option off. Default: off, and for good reason.
Whether or not .htaccess files are allowed to use their own
Host/User/Password/DB specifications. If set to 'off', then the
defaults specified in the httpd.conf cannot be overridden.
-@@ -256,6 +228,3 @@
+@@ -257,6 +235,3 @@
Whether or not to enable MySQL authentication. If it's off, the
MySQL authentication will simply pass authentication off to other
modules defined.
-AuthMySQL <on/off>
- Synonym for Auth_MYSQL.
diff -urNad mod-auth-mysql~/USAGE mod-auth-mysql/USAGE
---- mod-auth-mysql~/USAGE 2008-05-14 16:59:28.000000000 +0200
-+++ mod-auth-mysql/USAGE 2008-05-14 20:08:22.000000000 +0200
-@@ -41,9 +41,9 @@
+--- mod-auth-mysql~/USAGE 2008-05-14 20:24:12.000000000 +0200
++++ mod-auth-mysql/USAGE 2008-05-14 20:24:12.000000000 +0200
+@@ -44,9 +44,9 @@
or
This should be placed globally.
-@@ -53,12 +53,12 @@
+@@ -56,12 +56,12 @@
Auth_MySQL_General_DB <database>
to set that. This setting can be overridden in .htaccess files if
and the host, user, password, and database name cannot be changed.
diff -urNad mod-auth-mysql~/mod_auth_mysql.c mod-auth-mysql/mod_auth_mysql.c
---- mod-auth-mysql~/mod_auth_mysql.c 2008-05-14 18:46:21.000000000 +0200
-+++ mod-auth-mysql/mod_auth_mysql.c 2008-05-14 20:15:29.000000000 +0200
-@@ -655,14 +655,30 @@
+--- mod-auth-mysql~/mod_auth_mysql.c 2008-05-14 20:24:12.000000000 +0200
++++ mod-auth-mysql/mod_auth_mysql.c 2008-05-14 20:52:32.000000000 +0200
+@@ -674,14 +674,30 @@
NULL,
RSRC_CONF, "host, user and password of the MySQL database" ),
AP_INIT_TAKE1( "AuthMySQL_DefaultPassword", set_auth_mysql_pwd,
NULL,
RSRC_CONF, "Default MySQL password" ),
-@@ -671,23 +687,39 @@
+@@ -690,23 +706,39 @@
NULL,
RSRC_CONF, "Default MySQL server port" ),
- AP_INIT_TAKE1( "AuthMySQL_Host", ap_set_string_slot,
+ AP_INIT_TAKE1( "Auth_MySQL_Host", ap_set_string_slot,
- (void*)APR_XtOffsetOf(mysql_auth_config_rec, db_host),
+ (void*)APR_OFFSETOF(mysql_auth_config_rec, db_host),
OR_AUTHCFG, "database host" ),
- AP_INIT_TAKE1( "Auth_MySQL_Host", ap_set_string_slot,
+ AP_INIT_TAKE1( "AuthMySQL_Host", ap_set_string_slot,
- (void*)APR_XtOffsetOf(mysql_auth_config_rec, db_host),
+ (void*)APR_OFFSETOF(mysql_auth_config_rec, db_host),
OR_AUTHCFG, "database host" ),
-@@ -711,12 +743,20 @@
- (void*)APR_XtOffsetOf(mysql_auth_config_rec, db_user),
- OR_AUTHCFG, "database user" ),
-
-+ AP_INIT_TAKE1( "AuthMySQL_Username", ap_set_string_slot,
-+ (void*)APR_XtOffsetOf(mysql_auth_config_rec, db_user),
-+ OR_AUTHCFG, "database user" ),
-+
-+ AP_INIT_TAKE1( "Auth_MySQL_User", ap_set_string_slot,
-+ (void*)APR_XtOffsetOf(mysql_auth_config_rec, db_user),
-+ OR_AUTHCFG, "database user" ),
-+
- AP_INIT_TAKE1( "AuthMySQL_User", ap_set_string_slot,
- (void*)APR_XtOffsetOf(mysql_auth_config_rec, db_user),
+@@ -735,7 +767,7 @@
OR_AUTHCFG, "database user" ),
AP_INIT_TAKE1( "Auth_MySQL_Password", ap_set_string_slot,
-- (void*)APR_XtOffsetOf(mysql_auth_config_rec, db_pwd),
-+ (void*)APR_XtOffsetOf(mysql_auth_config_rec, db_pwd),
+- (void*)APR_OFFSETOF(mysql_auth_config_rec, db_pwd),
++ (void*)APR_OFFSETOF(mysql_auth_config_rec, db_pwd),
OR_AUTHCFG, "database password" ),
AP_INIT_TAKE1( "AuthMySQL_Password", ap_set_string_slot,
-@@ -743,13 +783,17 @@
- (void*)APR_XtOffsetOf(mysql_auth_config_rec, group_table),
- OR_AUTHCFG, "Name of the MySQL table containing the group-name/user-name combination; can be the same as the password-table." ),
-
-+ AP_INIT_TAKE1( "AuthMySQL_Group_Table", ap_set_string_slot,
-+ (void*)APR_XtOffsetOf(mysql_auth_config_rec, group_table),
-+ OR_AUTHCFG, "Name of the MySQL table containing the group-name/user-name combination; can be the same as the password-table." ),
-+
- AP_INIT_TAKE1( "Auth_MySQL_Group_Clause", ap_set_string_slot,
- (void*)APR_XtOffsetOf(mysql_auth_config_rec, group_where_clause),
- OR_AUTHCFG, "Additional WHERE clause for group/user-name lookup" ),
-
-- AP_INIT_TAKE1( "AuthMySQL_Group_Table", ap_set_string_slot,
-- (void*)APR_XtOffsetOf(mysql_auth_config_rec, group_table),
-- OR_AUTHCFG, "Name of the MySQL table containing the group-name/user-name combination; can be the same as the password-table." ),
-+ AP_INIT_TAKE1( "AuthMySQL_Group_Clause", ap_set_string_slot,
-+ (void*)APR_XtOffsetOf(mysql_auth_config_rec, group_where_clause),
-+ OR_AUTHCFG, "Additional WHERE clause for group/user-name lookup" ),
-
- AP_INIT_TAKE1( "Auth_MySQL_Password_Field", ap_set_string_slot,
- (void*)APR_XtOffsetOf(mysql_auth_config_rec, password_field),
-@@ -763,6 +807,10 @@
- (void*)APR_XtOffsetOf(mysql_auth_config_rec, password_where_clause),
+@@ -782,6 +814,10 @@
+ (void*)APR_OFFSETOF(mysql_auth_config_rec, password_where_clause),
OR_AUTHCFG, "Additional WHERE clause for group password/user-name lookup" ),
+ AP_INIT_TAKE1( "AuthMySQL_Password_Clause", ap_set_string_slot,
+ OR_AUTHCFG, "Additional WHERE clause for group password/user-name lookup" ),
+
AP_INIT_TAKE1( "Auth_MySQL_Username_Field", ap_set_string_slot,
- (void*)APR_XtOffsetOf(mysql_auth_config_rec, user_field),
+ (void*)APR_OFFSETOF(mysql_auth_config_rec, user_field),
OR_AUTHCFG, "The name of the user-name field in the MySQL password (and possibly group) table(s)." ),
-@@ -803,6 +851,10 @@
- (void*)APR_XtOffsetOf(mysql_auth_config_rec, authoritative),
+@@ -822,6 +858,10 @@
+ NULL,
OR_AUTHCFG, "When 'on' the MySQL database is taken to be authoritative and access control is not passed along to other db or access modules." ),
+ AP_INIT_FLAG( "Auth_MySQL_AllowOverride", set_auth_mysql_override,
AP_INIT_FLAG( "AuthMySQL_AllowOverride", set_auth_mysql_override,
NULL,
RSRC_CONF, "Allow directory overrides of configuration" ),
-@@ -835,6 +887,14 @@
+@@ -854,6 +894,14 @@
NULL,
OR_AUTHCFG, "Use non-persistent MySQL links" ),
AP_INIT_FLAG( "AuthMySQL_Persistent", set_persistent,
NULL,
OR_AUTHCFG, "Use non-persistent MySQL links" ),
-@@ -851,6 +911,10 @@
- (void*)APR_XtOffsetOf(mysql_auth_config_rec, password_where_clause),
+@@ -870,6 +918,10 @@
+ (void*)APR_OFFSETOF(mysql_auth_config_rec, password_where_clause),
OR_AUTHCFG, "Additional WHERE clause for group password/user-name lookup" ),
+ AP_INIT_TAKE1( "AuthMySQL_Where", ap_set_string_slot,
{ NULL }
};
#else
-@@ -859,14 +923,30 @@
+@@ -878,14 +930,30 @@
NULL,
RSRC_CONF, TAKE3, "host, user and password of the MySQL database" },
{ "AuthMySQL_DefaultPassword", set_auth_mysql_pwd,
NULL,
RSRC_CONF, TAKE1, "Default MySQL password" },
-@@ -875,23 +955,39 @@
+@@ -894,23 +962,39 @@
NULL,
RSRC_CONF, TAKE1, "Default MySQL server port" },
(void *) XtOffsetOf(mysql_auth_config_rec, db_host),
OR_AUTHCFG, TAKE1, "database host" },
-@@ -899,14 +995,30 @@
+@@ -918,14 +1002,30 @@
(void *) XtOffsetOf(mysql_auth_config_rec, db_socket),
OR_AUTHCFG, TAKE1, "database host socket" },
{ "AuthMySQL_User", ap_set_string_slot,
(void *) XtOffsetOf(mysql_auth_config_rec, db_user),
OR_AUTHCFG, TAKE1, "database user" },
-@@ -939,14 +1051,18 @@
+@@ -958,14 +1058,18 @@
(void *) XtOffsetOf(mysql_auth_config_rec, group_table),
OR_AUTHCFG, TAKE1, "Name of the MySQL table containing the group-name/user-name combination; can be the same as the password-table." },
{ "Auth_MySQL_Password_Field", ap_set_string_slot,
(void *) XtOffsetOf(mysql_auth_config_rec, password_field),
OR_AUTHCFG, TAKE1, "The name of the field in the MySQL password table" },
-@@ -959,6 +1075,10 @@
+@@ -978,6 +1082,10 @@
(void *) XtOffsetOf(mysql_auth_config_rec, password_where_clause),
OR_AUTHCFG, TAKE1, "Additional WHERE clause for group password/user-name lookup" },
{ "Auth_MySQL_Username_Field", ap_set_string_slot,
(void *) XtOffsetOf(mysql_auth_config_rec, user_field),
OR_AUTHCFG, TAKE1, "The name of the user-name field in the MySQL password (and possibly group) table(s)." },
-@@ -999,6 +1119,10 @@
- (void *) XtOffsetOf(mysql_auth_config_rec, authoritative),
+@@ -1018,6 +1126,10 @@
+ NULL,
OR_AUTHCFG, FLAG, "When 'on' the MySQL database is taken to be authoritative and access control is not passed along to other db or access modules." },
+ { "Auth_MySQL_AllowOverride", set_auth_mysql_override,
{ "AuthMySQL_AllowOverride", set_auth_mysql_override,
NULL,
RSRC_CONF, FLAG, "Allow directory overrides of configuration" },
-@@ -1031,6 +1155,14 @@
+@@ -1050,6 +1162,14 @@
NULL,
OR_AUTHCFG, FLAG, "Use non-persistent MySQL links" },
{ "AuthMySQL_Persistent", set_persistent,
NULL,
OR_AUTHCFG, FLAG, "Use non-persistent MySQL links" },
-@@ -1047,6 +1179,10 @@
+@@ -1066,6 +1186,10 @@
(void *) XtOffsetOf(mysql_auth_config_rec, password_where_clause),
OR_AUTHCFG, TAKE1, "Additional WHERE clause for group password/user-name lookup" },