Re: Change Password script
| From: | mwaples at waples dot net | Date: | Sat, 03 Feb 2001 06:13:53 +0000 |
| Subject: | Re: Change Password script | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-37936@lists.php.net to get a copy of this message | ||
enthalpy wrote:
>
> anyone have example code of a change password script in php?
>
> <-----CoreComm-Internet-Services--http://core.com/----->
> (Jon Marshall CoreComm Services Chicago)
> (jonathon.marshall@core.com Systems Engineer II)
> (enthalpy@core.com Network Operations)
> <-----Enthalpy.org------------http://enthalpy.org/----->
> (enthalpy@enthalpy.org The World of Nothing)
> <------------------------------------------------------>
>
> --
this is for freebsd - use at your own risk -
best used as a php shell script run by root
$newpassword = "veryinsecure";
$fp = popen("/usr/sbin/pw usermod -n username -h passwd", "w");
fputs($fp, "$newpassword");
pclose($fp)