I'm attempting to link my Discord bot with a MySQL database that is on another server. However, this example is apparently insecure:
const mysql = require('mysql');
const connection = mysql.createConnection({
host : 'hostname',
port : 'portnum',
user : 'db_user',
password : 'db_user_password',
database : 'db_name',
charset : 'utf8mb4'
});
How would I go about establishing a (more) secure connection?
from How to securely connect to MySQL database on another server?
No comments:
Post a Comment