Honig
February 27th, 2007, 05:33 PM
I am running a 6.06 LTS server for a wireless gateway (chillispot, freeradius, & mysql). I have built some simple pages to add/delete users, change passwords, and view usage. I have attempted to use auth_mysql (libapache2-mod-auth-mysql) to authenticate admin users who need these tools, but since I am posting here I guess you can figure out it is not working. :)
My install steps:
1. apt-get install libapache2-mod-auth-mysql
2. a2enmod auth_mysql
3. created & populated database
4. edited .htaccess and apache2.conf
I have two valid accounts on the server in the correct table but when I enter in the Username and Password it just loops like I am not authorized at all. I have verified that I can logon to the mysql server with the account/password that is specified in the apache2.conf and I have run a simple select query against the table where my users are stores; this works fine.
I cannot figure out for the life of me what the problem is. It is hard to diagnose from the lack of hard error messages unless I break it completely causeing the server to go HTTP 500 Error on me.
I would appreciate any help that any one could give me.
Below are my .htaccess, apache2.conf, and access.log files:
.htaccess
AuthName "MySQL Testing"
AuthType Basic
<Limit GET POST>
Auth_MySQL_Password_Table clients
Auth_MySQL_Username_Field username
Auth_MySQL_Password_Field passwd
AuthMySQL_Empty_Passwords off
Auth_MySQL On
require valid-user
</Limit>
apache2.conf
Auth_MySQL_Info localhost auth_user XXXXXXXXXXX
Auth_MySQL_General_DB auth
Entry in /var/log/apache2/access.log for one of the attempts
xxx.xxx.xxx.xxx - test [27/Feb/2007:15:27:48 -0600] "GET /radcreate/main.html HTTP/1.1" 401 521 "-" "Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1) Gecko/20060601 Firefox/2.0 (Ubuntu-edgy)"
My install steps:
1. apt-get install libapache2-mod-auth-mysql
2. a2enmod auth_mysql
3. created & populated database
4. edited .htaccess and apache2.conf
I have two valid accounts on the server in the correct table but when I enter in the Username and Password it just loops like I am not authorized at all. I have verified that I can logon to the mysql server with the account/password that is specified in the apache2.conf and I have run a simple select query against the table where my users are stores; this works fine.
I cannot figure out for the life of me what the problem is. It is hard to diagnose from the lack of hard error messages unless I break it completely causeing the server to go HTTP 500 Error on me.
I would appreciate any help that any one could give me.
Below are my .htaccess, apache2.conf, and access.log files:
.htaccess
AuthName "MySQL Testing"
AuthType Basic
<Limit GET POST>
Auth_MySQL_Password_Table clients
Auth_MySQL_Username_Field username
Auth_MySQL_Password_Field passwd
AuthMySQL_Empty_Passwords off
Auth_MySQL On
require valid-user
</Limit>
apache2.conf
Auth_MySQL_Info localhost auth_user XXXXXXXXXXX
Auth_MySQL_General_DB auth
Entry in /var/log/apache2/access.log for one of the attempts
xxx.xxx.xxx.xxx - test [27/Feb/2007:15:27:48 -0600] "GET /radcreate/main.html HTTP/1.1" 401 521 "-" "Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1) Gecko/20060601 Firefox/2.0 (Ubuntu-edgy)"