I am trying to use mysql.connector in Python 3.7 to connect to an Amazon RDS MySQL database I created following this tutorial. In python if I try
mysql.connector.connect(host="hostname.rds.amazonaws.com",
user="username", passwd="password",
database="databasename")
I get the following error:
MySQLInterfaceError: SSL connection error: SSL_CTX_set_tmp_dh failed
What is the error referring to? If I connect with the same credentials from the command line using mysql or mysql workbench I have no problems.
Update:
It must have been an issue with the anaconda environment I was using. I've since used pip3 to install mysql-connector and it works correctly.