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

Abode IoT Security Camera Vulnerabilities Would Let Attackers Insert Images, Bitdefender Finds

Abode IoT Security Camera Vulnerabilities Would Let Attackers Insert Images, Bitdefender Finds

December 21, 2021

2 min read
Online Shoppers Beware, Mobile Scams Are on the Rise

Online Shoppers Beware, Mobile Scams Are on the Rise

December 17, 2021

2 min read
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

FOLLOW US ON

SOCIAL MEDIA


You might also like

Malware Posing as Ransomware Responsible for Ukraine Cyberattack Malware Posing as Ransomware Responsible for Ukraine Cyberattack
Silviu STAHIE

January 17, 2022

2 min read
Russian Authorities Cuff Last Remaining REvil Suspects Russian Authorities Cuff Last Remaining REvil Suspects
Filip TRUȚĂ

January 17, 2022

2 min read
Android 12 protects phones from Stingray attacks, lets users disable 2G Android 12 protects phones from Stingray attacks, lets users disable 2G
Radu CRAHMALIUC

January 14, 2022

1 min read