Jump to content
  • 0

MD5 Passwords


uDe

Question


  • Group:  Members
  • Topic Count:  43
  • Topics Per Day:  0.01
  • Content Count:  400
  • Reputation:   5
  • Joined:  12/05/11
  • Last Seen:  

Hello,

 

May I ask how to change players password from SQL? My server is using MD5 password.

Link to comment
Share on other sites

6 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  75
  • Topics Per Day:  0.02
  • Content Count:  2223
  • Reputation:   593
  • Joined:  10/26/11
  • Last Seen:  

You can also search by their login ID:

UPDATE `login` SET `user_pass` = MD5('NEW_PASSWORD') WHERE `userid`='THEIR_LOGIN_ID';
  • Upvote 2
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  50
  • Topics Per Day:  0.01
  • Content Count:  1702
  • Reputation:   238
  • Joined:  09/05/12
  • Last Seen:  

Can make everything with encrypted data using MD5()

UPDATE `login` SET `user_pass` = MD5('"+<NEW PASSWORD>+"') WHERE `account_id` = '"+getcharid(3)+"'";
  • Upvote 1
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.00
  • Content Count:  1479
  • Reputation:   172
  • Joined:  12/14/11
  • Last Seen:  

*Adding:

 

If this is an in-game NPC script, then make sure that this script will not be excecuted more than one time.

 

Have a nice day!

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  43
  • Topics Per Day:  0.01
  • Content Count:  400
  • Reputation:   5
  • Joined:  12/05/11
  • Last Seen:  

Can make everything with encrypted data using MD5()

UPDATE `login` SET `user_pass` = MD5('"+<NEW PASSWORD>+"') WHERE `account_id` = '"+getcharid(3)+"'";

 

Thank you.

You can also search by their login ID:

UPDATE `login` SET `user_pass` = MD5('NEW_PASSWORD') WHERE `userid`='THEIR_LOGIN_ID';

 

I'm using this, easy to update from sql..

 

Thank you to both of you..

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  9
  • Topics Per Day:  0.00
  • Content Count:  187
  • Reputation:   7
  • Joined:  09/04/12
  • Last Seen:  

*Adding:

 

If this is an in-game NPC script, then make sure that this script will not be excecuted more than one time.

 

Have a nice day!

what does it mean,sir?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  75
  • Topics Per Day:  0.02
  • Content Count:  2223
  • Reputation:   593
  • Joined:  10/26/11
  • Last Seen:  

Well technically, you could use an in-game NPC to change your login password as many times as you want. It would all work fine, and your password would be whatever you set it to the last time you used the NPC.

Maybe Winz was thinking of this query trunk/sql-files/tools/convert_passwords.sql that converts all passwords to MD5 hashes:

UPDATE `login` SET `user_pass`=MD5(`user_pass`);
^ do NOT execute that more than once, or else you would be converting MD5-passwords to hashes of MD5 hashes.
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...