mysql2
Version:
fast mysql driver. Implements core protocol, prepared statements, ssl and compression in native JS
19 lines (16 loc) • 410 B
Markdown
##
https://mysqlserverteam.com/mysql-8-0-4-new-default-authentication-plugin-caching_sha2_password/
```js
const mysql = require('mysq');
mysql.createConnection({
authPlugins: {
caching_sha2_password: mysql.authPlugins.caching_sha2_password({
onServerPublikKey: function(key) {
console.log(key);
},
serverPublicKey: 'xxxyyy',
overrideIsSecure: true //
})
}
});
```