[Zope] damn sophisticated mysql security

Horst Wald horstwald@hotmail.com
Fri, 04 Jan 2002 12:32:01 +0000


Hello,

MySQL is so damn secure I can't access my own database!!!

.. but only if I try to connect to the MySQL-Server on the same host like 
the Zope-server; I get:

Error Type: OperationalError
Error Value: (1045, "Access denied for user: 'hsql@localhost' (Using 
password: YES)")

I can connect to a MySQL-Server on a remote machine without problems. Let's 
see if I understood what you have to do if you want to connect to the 
Database "MyDataBase", being the user "MyUser" on the local machine with the 
IP "195.196.197.198" using the password "MyPassWord":

1. become root
2. mysql
3. create database MyDataBase;
4. use mysql
5. insert into db values 
('195.196.197.198','MyUser','MyPassWord','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y');
6. insert into user 
values('195.196.197.198','MyUser',PASSWORD('MyPassWord'),'Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y');
7. flush privileges; (or even restart MySQL or even reboot the computer)

8. then (in Zope) add a ZMySQLDatabaseConnection with the connection string 
"MyDataBase MyUser MyPassWord", deliberately omitting the host

Any easier way? The easiest way? What I'd like best would be to disable the 
whole MySQL-security-stuff so I can start to work at last. I can care for 
security later.

Thanks in advance

Horst


_________________________________________________________________
Testen Sie MSN Messenger für Ihren Online-Chat mit Freunden: 
http://messenger.msn.de