Hi All,

> > anyone knows a web-based password changing source code?

Here is my solution to this.  I saw this a while ago on this list where 
someone (I forget who sorry) had written a PHP class to talk to the PopPass 
daemon to change passwords.

The PHP class had very limited error handling and I wrote a similar class 
from scratch as a learning exercise.

Find attached:
- poppassd.php (PHP class)
- changepassword.php (WEB page)
- poppassd daemon in RPM format

This version is probably not suitable for placing on the web for general 
usage but I am in the middle of writing an interface for ISP clients to 
change their passwords, mail settings etc which I hope to release in GPL form 
in the near future.

-- 
Regards,
+-----------------------+---------------------------------+
| Peter Kiem            | E-Mail    : <[EMAIL PROTECTED]> |
| Zordah IT             | Mobile    : +61 0418 798 121    |
|   IT Consultancy &    | WWW       : www.zordah.net      |
|   Internet Hosting    | ICQ       : "Zordah" 866661     |
+-----------------------+---------------------------------+
    The Rules Have Changed...Be paid to Surf the Web! 
    http://au.nz.alladvantage.com/go.asp?refid=OMP682

poppassd.php

Title: Change your Password

Change your CVS password

Your userid
Old password
New password New password again
'; $error = false; if ($userid == "") { print "You must give your userid
"; $error = true; } if ($oldpassword == "") { print "You must give your old password
"; $error = true; } if ($newpassword[0] == "") { print "You must give your new password
"; $error = true; } if ($newpassword[1] == "") { print "You must verify your new password
"; $error = true; } if (!($newpassword[0] == $newpassword[1])) { print "Your new passwords didn't match
"; $error = true; } if ($error == false) { require("poppassd.php"); $daemon = new poppassd; if ($daemon->change_password($userid, $oldpassword, $newpassword[0])) { echo "Success!"; } else { echo "Failure!
$daemon->err_str"; } } print "

"; } ?>

Reply via email to