1 min read

MySQL, MariaDB Flaw Allows Root Access with Wrong Passwords

Bogdan BOTEZATU

June 12, 2012

Ad One product to protect all your devices, without slowing them down.
Free 90-day trial
MySQL, MariaDB Flaw Allows Root Access with Wrong Passwords

A critical vulnerability in the MySQL and MariaDB database servers allows attackers to gain root access with wrong passwords – if they are persistent enough. This flaw affects one of the most popular database systems in the world and can result in significant data loss when successfully exploited. To add insult to injury, the exploitation technique is a no-brainer, as all the attacker has to do is keep trying passwords.

The responsibility for this major failure seems to reside in the fact that the server expects the memcmp() function to return a value between -127 and 127. However, some server setups often return a value outside the boundary, which confuses the routines that compare the entered password with its hashed value. This, in turn, validates the wrong password against the stored hash. Shortly put, there is a 1 in 256 chance that any password would be accepted as valid.

When a user connects to MariaDB/MySQL, a token (SHA over a password and a random scramble string) is calculated and compared with the expected value,“ wrote Sergei Golubchik in a post on the OS-Sec mailing list. “Because of incorrect casting, it might’ve happened that the token and the expected value were considered equal, even if the memcmp() returned a non-zero value. In this case, MySQL/MariaDB would think that the password is correct, even while it is not. Because the protocol uses random strings, the probability of hitting this bug is about 1/256.”

MySQL database servers are used in nearly all areas, ranging from personal and commercial to the military. Fortunately though, some Linux distributions bind the MySQL daemon to localhost, preventing remote access to the service. This means that an attacker won`t be able to access the server without access to the machine.

tags


Author



Right now

Top posts

The Holiday Guide to Tech Support: Fixing the Family Computer

The Holiday Guide to Tech Support: Fixing the Family Computer

November 24, 2021

2 min read
Bitdefender Celebrates 20 Years of Cybersecurity Leadership

Bitdefender Celebrates 20 Years of Cybersecurity Leadership

November 04, 2021

3 min read
Bitdefender Study Reveals How Consumers Like (and Dislike) Managing Passwords

Bitdefender Study Reveals How Consumers Like (and Dislike) Managing Passwords

October 26, 2021

3 min read
What are drive-by download attacks and how do you prevent them?

What are drive-by download attacks and how do you prevent them?

October 25, 2021

2 min read
Criminals Can't Wait to Add Your IoT Device to Their DDoS Networks

Criminals Can't Wait to Add Your IoT Device to Their DDoS Networks

October 22, 2021

2 min read
Six in 10 Consumers Faced a Cyber Threat in 2021, New Bitdefender Study Reveals

Six in 10 Consumers Faced a Cyber Threat in 2021, New Bitdefender Study Reveals

October 20, 2021

3 min read

FOLLOW US ON

SOCIAL MEDIA


You might also like

Chrome 96 Gets 22 More Security Fixes with New Incremental Update Chrome 96 Gets 22 More Security Fixes with New Incremental Update
Filip TRUȚĂ

December 08, 2021

1 min read
Most Employees Believe Passwords Affect Their Productivity, Research Finds Most Employees Believe Passwords Affect Their Productivity, Research Finds
Silviu STAHIE

December 06, 2021

1 min read
US State Department iPhones Infected with Pegasus Spyware – Report US State Department iPhones Infected with Pegasus Spyware – Report
Filip TRUȚĂ

December 06, 2021

2 min read