7. mysql_config_editor
(MySQL 5.6 Reference Manual)
• The mysql_config_editor utility (available as
of MySQL 5.6.6) enables you to store
authentication credentials in an encrypted
login file named .mylogin.cnf.
http://dev.mysql.com/doc/refman/5.6/en/mysql-config-editor.html より抜粋