New user creation doesn't work properly with drupal 4.5. The problem is with the role portion of the array passed to user_save.

Here's the patch, its also attached:

--- webserver_auth.module       2004-10-01 01:01:56.000000000 -0700
+++ webserver_auth.module.patched       2004-10-20 14:26:02.683075280 -0700
@@ -18,7 +18,7 @@ function webserver_auth_init() {
       $user = user_external_load($account->name);
       if (!$user->uid) {
         if (variable_get("user_register", 1) == 1) {
-          $user_default = array("name" => $account->name, "pass" => "cyan", "init" => check_query($name), "authname_webserver_auth" => $account->name, "status" => 1, "rid" => _user_authenticated_id());
+          $user_default = array("name" => $account->name, "pass" => "cyan", "init" => check_query($name), "authname_webserver_auth" => $account->name, "status" => 1, "roles" => array(_user_authenticated_id()));
           $user = user_save("", array_merge($user_default, $account));
           watchdog("user", "new user: $user->name (webserver_auth)", l(t("edit user"), "admin/user/edit/$user->uid"));
         }

-Darrian

CommentFileSizeAuthor
webserver_auth.module.patch932 bytesdarrian

Comments

darrian’s picture

It looks like this patch made it into the 4.5 version of webserver_auth, so im gonna mark this as fixed.

-Darrian

Anonymous’s picture