[thelist] mysql - old_password - persistent connection

Jon Molesa rjmolesa at consoltec.net
Tue Nov 18 16:56:24 CST 2008


Is this related to your previous Joomla username/password question?

*On Tue, Nov 18, 2008 at 03:19:04PM -0700 Bob Meetin <bobm at dottedi.biz> wrote:

> Date: Tue, 18 Nov 2008 15:19:04 -0700
> From: Bob Meetin <bobm at dottedi.biz>
> Subject: [thelist] mysql - old_password - persistent connection
> To: "thelist at lists.evolt.org" <thelist at lists.evolt.org>
> 
> I think I'm running into a problem with persistent connection dropping 
> losing old_passwords = 'OFF'.  If I run any of the following queries 
> from within mysql they work fine:
> 
> 1) mysql> set old_passwords = 'OFF';select * from jos_users where 
> username = 'some_username';
> 2) mysql> set old_passwords = 'OFF';select * from jos_users where 
> username='some_username' AND password=PASSWORD('some_password');
> 3) mysql> select * from jos_users where username='some_username' AND 
> password = (select password('some_password'));
> 
> However when I run them from within PHP, the first is fine, but the 
> second and third fail:
> 
> 1) $query = "set old_passwords = 'OFF';select * from jos_users where 
> username = '$username'";
> 2) $query = "set old_passwords = 'OFF';select * from jos_users where 
> username='$username' AND password=PASSWORD('$password')";
> 3) $query = "set old_passwords = 'OFF';select * from jos_users where 
> username='$username' AND password = (select password('$password'))";
> 
>  From the mysql prompt if I run:
> 
> mysql> set old_passwords = 'OFF';
> mysql> select * from jos_users where username='some_username' AND 
> password=PASSWORD('some_password');
> 
> It works fine, however if I wait 10-15 seconds it fails, indicating that 
> mysql has lost connection.  Is there another way I can do this to keep 
> it honest?
> -- 
> 
> * * Please support the community that supports you.  * *
> http://evolt.org/help_support_evolt/
> 
> For unsubscribe and other options, including the Tip Harvester 
> and archives of thelist go to: http://lists.evolt.org 
> Workers of the Web, evolt ! 

-- 
Jon Molesa
rjmolesa at consoltec.net
if you're bored or curious
http://rjmolesa.com


More information about the thelist mailing list