How to use the new md5 function
in the amxmodx.inc file i saw the declaretion is:
/* Calculates the md5 keysum of a string */ native md5(const szString[], md5buffer[34]); I want to use md5 encrypted passwords so i edit the admin.sma file. The line 290 is: Code:
else if (equal(password,g_aPassword[index]))Code:
else if (equal(md5(password),g_aPassword[index]))How can i use the md5 function? Thanks |
From amxmodx.inc:
Code:
This mean you must do: Code:
Or something similar |
I make it as you say but there is a weird error.
The md5 of my password is: 8cdee5526476b101869401a37c03e379 but amxmodx's md5 result is: 88bc49ab58742b4b7c68c58a2288ae11 I created the first password with php's md5 function. I put a line that prints the md5 of the password given to the console of the server. log_amx("Login: ^"%s^"",hash) When i connect with my password it writes the second password to the server console. What is wrong with this? Thanks |
Unless you're worried about routers actually reading the packets sent between a client computer and the server, there's no point.
And it's not an 'md5 password', it's a hash. You should probably encrypt it by a serverside key. |
Ok then i want to explain my system.
I have a forum and 4500 users. The forum is storing the passwords as md5 encrypted on database. I was using adminmod and it supports md5 passwords. But i don't like adminmod and i want to use amxmodx. I have to make the amxmodx to use these passwords. I think that the md5 function is included for this. But i don't understand why it gives a different result as the php gives. I used the php's md5 function and create an encrypted password, but amxmodx's encrypted password is differs from this password. Thanks |
Please post in the bug report forum, as it seems to be a bug indeed
|
I posted it to the Bug Report forum.
Thanks |
Can you post the code that you modifed? I suspect that you didn't md5 the right thing..
|
I posted it to the http://forums.alliedmods.net/showthread.php?t=5817
|
| All times are GMT -4. The time now is 17:24. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.