Password security from PHP to MySQL
| From: | Egan | Date: | Thu, 25 Jan 2001 18:52:16 +0000 |
| Subject: | Password security from PHP to MySQL | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-36682@lists.php.net to get a copy of this message | ||
I know that ~.my.cnf with
[client]
password={mypass}
is the recommended method of securing your MySQL password when using a
shell command line to access MySQL.
But what is the recommended method for MySQL password security via
PHP? Is there some way to make it use the ~.my.cnf file?
It seems to me that if you hardcode a MySQL password into your PHP
source code, it could become exposed inadvertently. Forgive me if
this is already answered in the FAQ or manual.
Egan