Page 1 of 1

Disconnect from Server. Reason: Not Authenticated

PostPosted: Mon Mar 15, 2021 12:21 pm
by FrankFrankly
Shorah all! I recently changed my Myst passwords, and now I am unable to log in to the Deep Island server. It keeps telling me "Disconnect from server. Reason: not authenticated." I tried both my old and new passwords, and no luck. Any ideas what I may have messed up? Or how to reset the password again?

Re: Disconnect from Server. Reason: Not Authenticated

PostPosted: Wed Mar 17, 2021 11:11 am
by diafero
Hm, all I can see in the logfile is that the GoW server responds with "password is wrong":
Code: Select all
(2021:03:15-18:55:31.959469)[140346883757824] AUTH: player FrankFrankly (IP: XXX, game server [0][85.214.18.84:5000]):
 (2021:03:15-18:55:32.447624)[140346883757824] CGAS error message: 11
Password is wrong
0


The script relies on some integration from the GoW forum side, maybe that got lost -- Hoikas, any chance you could take a look? Here are some notes I found on the subject:
Code: Select all
To fill it, you need to patch include/auth/auth_db.php. After the following block:
      // User inactive...
      if ($row['user_type'] == USER_INACTIVE || $row['user_type'] == USER_IGNORE)
      {
         return array(
            'status'      => LOGIN_ERROR_ACTIVE,
            'error_msg'      => 'ACTIVE_ERROR',
            'user_row'      => $row,
         );
      }
that should end at line 184, insert this code:
      // SAVE md5hash OF PASSWORD FOR CGAS BEGIN
      $sql = 'SELECT user_id FROM cgas_passwords WHERE user_id='. $row['user_id'];
      $result = $db->sql_query($sql);
      $cgas = $db->sql_fetchrow($result);
      $db->sql_freeresult($result);
      
      if (!$cgas) {
         $sql = 'INSERT INTO cgas_passwords (user_id, user_password) VALUES ('.$row['user_id'].', \''.md5($password).'\')';
      }
      else {
         $sql = 'UPDATE cgas_passwords SET user_password=\''.md5($password).'\' WHERE user_id='. $row['user_id'];
      }
      $db->sql_query($sql);
      // SAVE md5hash OF PASSWORD FOR CGAS END

Re: Disconnect from Server. Reason: Not Authenticated

PostPosted: Wed Mar 17, 2021 7:28 pm
by FrankFrankly
Thanks for the reply! Hmm that error in the log is strange. I log in here with my new password just fine. Last time I logged into Deep Island was maybe a month ago, so I'm not inactive.

Re: Disconnect from Server. Reason: Not Authenticated

PostPosted: Thu Mar 18, 2021 4:27 pm
by FrankFrankly
I was able to log in, thanks so much!