Password reset script in php

hi

i need a password reset tool (3.3.5a) for my site

i search but i cant found any thing

plz help

Try something like this:

// returns Server Username/password hash
function makePasswordHash($username, $password)
{
	return(strtoupper(sha1(strtoupper($username.":".$password))));
}


$hash = makePasswordHash($NewUserName, $Newpassword);
        
$sql = "UPDATE account SET username='$NewUserName', sha_pass_hash='$hash', sessionkey='', v='', s='', token_key ='' WHERE username='".$user_name."'";
$auth->Query($sql);

is there any ready project for download ?

No /emoticons/default_wink.png

/emoticons/default_sad.png

and, if there was, it wouldn’t be in help and support.

These days it probably would be. It would be buried on page 10 of some other thread that doesn’t belong in Help & Support.

do you know any compelet project for it?

Time to learn PhP my friend. Not to sound like a dick, but everyone pretty much taught themselves or found outdated forms and dissected them piece by piece and gained more experience from that.

— Canned message start —

This thread is not related to the official Trinity codebase and was moved to the Custom Code section.

Please read the stickies next time.

— Canned message end —

Would it be a best practise to use SOAP to set a new password these days? Or is it too much overhead for this usage?

I’m thinking about “account set password USER PASS”

If you anyway have activated the SOAP service, why not.

I got used to do such things in the database /emoticons/default_smile.png