1. Home
  2. Security Hardening
  3. CIS MySQL 8.0 Enterprise Linux OS L1 V1.1.0
  4. Ensure ‘datadir’ Has Appropriate Permissions – datadir Has Appropriate Permissions and Ownership

Ensure ‘datadir’ Has Appropriate Permissions – datadir Has Appropriate Permissions and Ownership

Details

The data directory is the location of the MySQL databases.

Rationale:

Limiting the accessibility of these objects will protect the confidentiality, integrity, and availability of the MySQL database. If someone other than the MySQL user is allowed to read files from the data directory, it may be possible to read data from the mysql.user table which contains passwords. Additionally, the ability to create files can lead to denial of service, or might otherwise allow someone to gain access to specific data by manually creating a file with a view definition.

Solution

Execute the following commands at a terminal prompt:

chmod 750
chown mysql:mysql

Supportive Information

The following resource is also helpful.

This security hardening control applies to the following category of controls within NIST 800-53: Access Control, Media Protection.This control applies to the following type of system Unix.

References

Source

Updated on July 16, 2022
Was this article helpful?

Related Articles