MySQL user password in the special character character exclamation point number (! ) The Magical _mysql

Source: Internet
Author: User

Use the exclamation mark (! A method that prohibits user terminals from entering.

Copy Code code as follows:

Mysql> grant all privileges in wubx.* to ' wubx ' @ ' 172.16.100.185′identified by ' fd52!wubx&, ';
Query OK, 0 rows Affected (0.00 sec)
mysql>quit;
#mysql-H 172.16.100.185-u wubx-pfd52!wubx&,
-bash:!wubx@,: Event not found

Take a closer look, it turns out he did! The following string is executed as a command. Also tried a navicat management end, there is a problem of abnormal password.

In the measurement of the program is not available, write a PHP test.

Copy Code code as follows:

$link = mysql_connect (' 172.16.100.185′, ' wubx ', ' fd52!wubx&, ');
if (!link) {
Die (' Could not connect: '. Mysql_error ());
}
Echo ' Connected successfully '; mysql_close ($link);
?>
#php testdb.php
Connected successfully

Also look at the program can be normal identification.
PHP can still be OK to pass.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.