MySQL 8.0 Database Administrator — Question 116

You wish to store the username and password for a client connection to MySQL server in a file on a local file system.
Which is the best way to encrypt the file?

Answer options

Correct answer: D

Explanation

The correct answer is D because mysql_config_editor is specifically designed to create and manage encrypted login credentials for MySQL connections. Option A, while it provides encryption, does not specifically address the needs of storing credentials securely in a file. Option B relates to securing the MySQL installation rather than encrypting user credentials in a file. Option C lacks a specific mechanism for encryption and relies on manual methods, which are less secure.