Bug #92587 default-auth-override.cnf file is executable in Ubuntu
Submitted: 27 Sep 2018 13:39 Modified: 3 Oct 2018 14:33
Reporter: Tomislav Plavcic (OCA) Email Updates:
Status: Closed Impact on me:
Category:MySQL Server: Packaging Severity:S3 (Non-critical)
Version:8.0.12 OS:Ubuntu
Assigned to: Lars Tangvald CPU Architecture:Any

[27 Sep 2018 13:39] Tomislav Plavcic
I have installed 8.0.12 on Ubuntu Bionic and when package configuration asked me I choose to  "Use Legacy Authentication Method (Retain MySQL 5.x Compatibility)".
The file "/etc/mysql/mysql.conf.d/default-auth-override.cnf" was generated and for some reason it is executable, but from what I see it's just normal config file so no need to be executable or I'm missing something.

Here's how it looks:
root@ubuntu-bionic:/etc/mysql/mysql.conf.d# ls -alh
total 16K
drwxr-xr-x 2 root root 4,0K ruj  27 13:26 .
drwxr-xr-x 4 root root 4,0K ruj  27 13:26 ..
-rwxr-xr-x 1 root root  130 ruj  27 13:26 default-auth-override.cnf
-rw-r--r-- 1 root root 1,5K lip  28 17:30 mysqld.cnf

root@ubuntu-bionic:/etc/mysql/mysql.conf.d# mysqld --version
/usr/sbin/mysqld  Ver 8.0.12 for Linux on x86_64 (MySQL Community Server - GPL)

root@ubuntu-bionic:/etc/mysql/mysql.conf.d# dpkg -l|grep mysql
ii  mysql-apt-config                0.8.10-1                          all          Auto configuration for MySQL APT Repo.
ii  mysql-client                    8.0.12-1ubuntu18.04               amd64        MySQL Client meta package depending on latest version
ii  mysql-common                    8.0.12-1ubuntu18.04               amd64        MySQL Common
ii  mysql-community-client          8.0.12-1ubuntu18.04               amd64        MySQL Client
ii  mysql-community-client-core     8.0.12-1ubuntu18.04               amd64        MySQL Client Core Binaries
ii  mysql-community-server          8.0.12-1ubuntu18.04               amd64        MySQL Server
ii  mysql-community-server-core     8.0.12-1ubuntu18.04               amd64        MySQL Server Core Binaires
ii  mysql-server                    8.0.12-1ubuntu18.04               amd64        MySQL Server meta package depending on latest version

How to repeat:
Wrote in description.

Suggested fix:
Fix permissions for /etc/mysql/mysql.conf.d/default-auth-override.cnf file.
[27 Sep 2018 15:01] MySQL Verification Team
Thank you for the bug report.
[28 Sep 2018 5:31] Lars Tangvald
The default mode of the install command used to create the file is 755, so we need to specify 644. Thanks!
[28 Sep 2018 7:19] Evgeniy Patlan
I have created pull request which should solve this issue.
[28 Sep 2018 14:28] OCA Admin
Contribution submitted via Github - [Bug #92587] Fix permissions for default-auth-override.cnf 
(*) Contribution by Evgeniy Patlan (Github EvgeniyPatlan, mysql-server/pull/222#issuecomment-425435263): I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it.

Contribution: git_patch_218874435.txt (text/plain), 1.13 KiB.

[3 Oct 2018 14:33] Paul Dubois
Posted by developer:
Fixed in 8.0.14.

On Ubuntu, the installed
/etc/mysql/mysql.conf.d/default-auth-override.cnf file was mistakenly
created with executable mode. Thanks to Evgeniy Patlan for the
correction contribution.