| 390 | reason="no sha256 password authentication plugin found", |
| 391 | ) |
| 392 | def testAuthSHA256(self): |
| 393 | conn = self.connect() |
| 394 | c = conn.cursor() |
| 395 | with TempUser( |
| 396 | c, |
| 397 | "pymysql_sha256@localhost", |
| 398 | self.databases[0]["database"], |
| 399 | "sha256_password", |
| 400 | ): |
| 401 | c.execute("SET PASSWORD FOR 'pymysql_sha256'@'localhost' ='Sh@256Pa33'") |
| 402 | c.execute("FLUSH PRIVILEGES") |
| 403 | db = self.db.copy() |
| 404 | db["password"] = "Sh@256Pa33" |
| 405 | # Although SHA256 is supported, need the configuration of public key of |
| 406 | # the mysql server. Currently will get error by this test. |
| 407 | with self.assertRaises(pymysql.err.OperationalError): |
| 408 | pymysql.connect(user="pymysql_sha256", **db) |
| 409 | |
| 410 | @pytest.mark.skipif(not ed25519_found, reason="no ed25519 authention plugin") |
| 411 | def testAuthEd25519(self): |