Wrox Programmer Forums
Go Back   Wrox Programmer Forums > PHP/MySQL > PHP Databases
| Search | Today's Posts | Mark Forums Read
PHP Databases Using PHP in conjunction with databases. PHP questions not specific to databases should be directed to one of the other PHP forums.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the PHP Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old May 22nd, 2006, 01:59 PM
Registered User
Join Date: May 2006
Location: ArbĂșcies, , Spain.
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Default Client does not support authentication protocol

I've got a problem with databases, when I try to connect to my database using PHP, it fails and return me this message:

Warning: mysql_connect(): Client does not support authentication protocol requested by server; consider upgrading MySQL client in F:\Apache Group\Apache2\test\createmovie.php on line 4

Old May 24th, 2006, 11:05 AM
Friend of Wrox
Join Date: Jun 2003
Location: , , United Kingdom.
Posts: 256
Thanks: 0
Thanked 0 Times in 0 Posts

Your version of PHP is older than the version of MySQL you are trying to connect with. MySQL upped the security on their password loggin quite some time ago, so (since all loggin attempts are sent encrypted) any attempt to log in using the old encryption will result in this failure (the error message is essentially telling you that it has detected this fact: the encrypted password string that has been sent is simply too short to have been encoded using the new encryption).

Consider either upgrading your copy of PHP (and, thus, the client libraries it ships witrh), or encode your client password at the mysql end using the old_password function:

i.e. UPDATE mysql.users SET Password=old_password('whateveryourpasswordis') WHERE User='whateveryourremorteuseris' AND Host='whateveryourremotehostis';

This will get you loggged in, and will do in a test environment. In a live environment, you'd upgrade your copy of PHP, of course: ssimple.


Similar Threads
Thread Thread Starter Forum Replies Last Post
Error-Object does not support doesn't support this bootsy Classic ASP Basics 1 May 25th, 2008 07:14 PM
Client does not support authentication prot Yproc BOOK: Beginning PHP, Apache, MySQL Web Development ISBN: 978-0-7645-5744-6 0 January 29th, 2006 07:46 PM
#1251 - Client does not support authentication pro p2ptolu Beginning PHP 0 May 5th, 2005 11:00 AM
#1251 - Client does not support authentication pro p2ptolu MySQL 0 May 5th, 2005 09:00 AM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.