Reputation: 7877
I'd like to access a MySQL server which is setup in a way that only allows mysql_clear_password. I am able to connect to using command like, with the --enable-cleartext-plugin option, like so:
>> mysql --port NNN -u my_user -h DB.host.com --enable-cleartext-plugin -D my_database
However, from Python (specifically using SQLAlchemy/PyMySQL) It doesn't seem possible to use the enable-cleartext-plugin option. How can we optionally pass this information via Python?
Upvotes: 2
Views: 2856
Reputation: 86
I believe there's no need to do anything special, and it has worked for me. When connecting to the DB, the server asks the client to use the plugin mysql_clear_password
, and PyMySQL already understands how to handle that.
Upvotes: 1