By mark_d on
Hi ,
with drupal 4.5 clean install, MySQL version 3.23.56 , PHP Version 4.2.2
webserver_auth call's user_external_load which check's for a user in the authmap table , the problem at least for me is that authmap is empty , i'm not sure if it's supposed to be but it is? adding a new user via drupal does not affect the authmap.
so webserver_auth fails as it can't find a valid user in authmap when that user exists in the users table.
my hack was to change
$user = user_external_load($account->name);
to
$user = user_load(array("name" => $account->name));
which now works , the question is why is authmap empty for me ? is this the same for other users
Mark
Comments
timing
if you had used webserver_auth from the beginning of your site, you would have an entry in authmap for every uid. once you populate the authmap for every uid, you could revert the code change you made.
the code change you made will work fine until someone changes their username in drupal but not in the webserver's auth database
Think I've got it now
Yep i installed the module after installing drupal and setting up some users then mirrored them in apache's user list.
One problem i had was the drupal was set to only allow admin to setup users so the auto-update code was not getting called at all , maybe need to add that to the readme , drupal must be set to allow users to register themselves without approval for webserver_auth to work.
now synced the db and reverted and all seems well
Thanks
Mark
I think that webserver_auth
I think that webserver_auth or any other server authentication module should fill {authmap} table with differences from {users} table. This could be done in installation script.