Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to protect mysql_config_editor/login-path login password

2025-04-07 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

How to carry out mysql_config_editor/login-path login password protection, I believe that many inexperienced people do not know what to do, so this paper summarizes the causes of the problem and solutions, through this article I hope you can solve this problem.

Login-path is a new feature that MySQL5.6 begins to support. Encrypt the authentication information logged into the mysql_config_editor service in the .mylogin.cnf file (default in the user's home directory). After that, the MySQL client tool can connect to MySQL by reading the encrypted file, avoiding repeated entry of login information and exposure of sensitive information.

Help for using mysql_config_editor:

Configuration:

Mysql_config_editor set-host=127.0.0.1-login-path=local3306-port=3306-user=root-p

Where configurable items

Add host to the login file

-the login path name adds a name to the login file (default is client)

Add the password to the login file (the password will be automatically encrypted by mysql_config_editor)

Add the user name to the login file

Add sock file path to login file

Add the login port to the login file

Display configuration:

Mysql_config_editor print-- login-path=local3306 # shows the login-path configuration performed

Mysql_config_editor print-- all # displays all login-path information

Delete the configuration:

Mysql_config_editor remove-login-path=local3306

Where items can be deleted

Add host to the login file

-the login path name adds a name to the login file (default is client)

Add the password to the login file (the password will be automatically encrypted by mysql_config_editor)

Add the user name to the login file

Add sock file path to login file

Add the login port to the login file

Reset the configuration:

Mysql_config_editor reset-login-path=local3306

Log in using login-path:

Shell > mysql-- login-path=local3306

To log in to other hosts or ports, or to add other additional parameters, you can add them directly after the above command

Shell > mysql-- login-path=local3306-h host1-P port1 # Log in to MySQL on host1:poet1

Shell > mysql-- login-path=local3306-h host1-P port1 local3306_db # Log in to the local3306_ DB library in MySQL on host1:poet1

[root@12c01 ~] # mysql-- login-path=local3306 test # # directly enter the test library of the configuration environment

Type 'help;' or'\ h' for help. Type'\ c'to clear the current input statement.

01:52 test >

After reading the above, have you mastered how to protect the password of mysql_config_editor/login-path login? If you want to learn more skills or want to know more about it, you are welcome to follow the industry information channel, thank you for reading!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report