Re: Format of Encrypted Password
| From: | Kevin Murphy | Date: | Thu, 07 Sep 2006 20:56:22 +0000 |
| Subject: | Re: Format of Encrypted Password | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-241458@lists.php.net to get a copy of this message | ||
Yup, that's got it. It didn't occur to me that its a MySQL thing.... I'm used to doing this as a PHP thing and inserting an already encrypted password into MySQL.
Anyone have any thoughts one way or another as to if this mysql password function is better/worse than doing it all in PHP?
--
Kevin Murphy
Webmaster: Information and Marketing Services
Western Nevada Community College
www.wncc.edu
775-445-3326
On Sep 7, 2006, at 12:50 PM, Eric Butera wrote:
> On 9/5/06, Kevin Murphy <php@stubborndonkey.com> wrote:
> $query = "select name from table where name = '$authuser' and
> password = password('$auth_pw')";
>
>
> If you haven't tried this you can probably create accounts yourself
> manually in MySQL like this:
> INSERT INTO table (name, password) VALUES ('user', PASSWORD('pass'));