I am using mod_auth_mysql 2.8.1 (as DSO) with Apache 1.3.33 and MySQL 4.1.9 and everything works fine.
However, not all .htaccess files use MySQL authentication. In fact, most of my clients still want to use plain htpasswd files. But this suddenly requires all of them to add the directive "AuthMySQLEnable Off" to their .htaccess files, which of course results in numerous support calls.
My solution would be to set "AuthMySQLEnable Off" as a default directive and use "AuthMySQLEnable On" only in those .htaccess files that really need MySQL authentication.
I tried to put the directive in my httpd.conf, but this resulted in the following error:
[root@wasabi ~]# apachectl configtest
Syntax error on line 79 of /usr/local/apache-1.3.33/conf/httpd.conf:
AuthMySQLEnable not allowed here
[root@wasabi ~]#
A solution would be very much appreciated.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I am using mod_auth_mysql 2.8.1 (as DSO) with Apache 1.3.33 and MySQL 4.1.9 and everything works fine.
However, not all .htaccess files use MySQL authentication. In fact, most of my clients still want to use plain htpasswd files. But this suddenly requires all of them to add the directive "AuthMySQLEnable Off" to their .htaccess files, which of course results in numerous support calls.
My solution would be to set "AuthMySQLEnable Off" as a default directive and use "AuthMySQLEnable On" only in those .htaccess files that really need MySQL authentication.
I tried to put the directive in my httpd.conf, but this resulted in the following error:
[root@wasabi ~]# apachectl configtest
Syntax error on line 79 of /usr/local/apache-1.3.33/conf/httpd.conf:
AuthMySQLEnable not allowed here
[root@wasabi ~]#
A solution would be very much appreciated.
Jeroen,
Please see the BUILD file.
During build time, AuthMySQLEnable is one of the options you can set for the module. You can add
-DENABLE=0
(that's a zero)
to the apxs command line. This will build the module with the default to be off.
Jerry
Thanks. This completely solved my problem.