FS#10058 - mysqld rc script creates insecure dummy log

Attached to Project: Arch Linux
Opened by Loui Chang (louipc) - Wednesday, 02 April 2008, 00:49 GMT
Last edited by Douglas Soares de Andrade (dsa) - Sunday, 11 January 2009, 12:25 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Alexander Baldeck (kth5)
Douglas Soares de Andrade (dsa)
Architecture All
Severity High
Priority Normal
Reported Version 2007.08-2
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 3
Private No

Details

Description:
mysql 5.0.51-3

The mysqld startup script touches the default mysqld.log location but doesn't do
anything to secure it from reading by non privileged users.
Databases can have sensitive information so should not be globally readable.

mysqld_safe seems to take care of log creation and security itself when a log file is
specified in my.cnf and it has write permission to the directory containing the logs.
(personally I just created /var/log/mysql/ and gave it user:group of mysql:mysql)

Furthermore the startup script assumes too much (location of log file), which may be incorrect depending on my.cnf

Let the admin take care of things him/herself.
Patch attached.

It would be handy though for a novice user to be able to enable secure logging (with logrotate) by just uncommenting a config option in my.cnf

Let me know if you need more files/info. :D
This task depends upon

Closed by  Douglas Soares de Andrade (dsa)
Sunday, 11 January 2009, 12:25 GMT
Reason for closing:  Fixed
Comment by Gavin Bisesi (Daenyth) - Wednesday, 04 June 2008, 18:49 GMT
This bug is still present in 5.0.51-3.
Comment by Loui Chang (louipc) - Saturday, 21 June 2008, 18:34 GMT
It's still present in mysql 5.0.60-1 too.

Comment by Loui Chang (louipc) - Sunday, 28 September 2008, 17:08 GMT
What is taking so long for this bug to be resolved?
Comment by Loui Chang (louipc) - Wednesday, 05 November 2008, 22:59 GMT
Any chance of resolution in the next century?
Comment by Aaron Griffin (phrakture) - Wednesday, 05 November 2008, 23:39 GMT
Committed to SVN trunk
Comment by Loui Chang (louipc) - Thursday, 06 November 2008, 00:08 GMT
Cool. Thanks for looking at this Aaron.
Comment by Loui Chang (louipc) - Thursday, 06 November 2008, 00:24 GMT
Oh! That'll probably require an update of the md5sum to 247e9fa664bccaca62ca0e42a6cfae20
I almost forgot. Cheers!

Loading...