Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 12809 - sendmail permisions
Summary: sendmail permisions
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Unspecified (show other bugs)
Hardware: All Linux
: High normal
Assignee: Nick Hadaway
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-12-27 15:52 UTC by roma1390
Modified: 2003-01-19 19:50 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description roma1390 2002-12-27 15:52:48 UTC
info from: "SENDMAIL INSTALLATION AND OPERATION GUIDE"

1. /etc/mail/aliases is:
-rw-r--r--    1 root     root          809 Dec 26 04:11 aliases
but permisions must be: 0640 or 0600. (SIAOG 1.3.10)

2. /etc/init.d/sendmail has:
start() {
        ebegin "Starting sendmail"
        /usr/bin/newaliases > /dev/null 2>&1
        /usr/sbin/sendmail ${SENDMAIL_OPTS} > /dev/null 2>&1
        eend $?
}
but recomendet (SIAOG 1.3.11):
checkconfig() {
        if [ ! -f /etc/mail/sendmail.cf ] ; then
                eerror "Please create /etc/mail/sendmail.cf"
                return 1
        fi

        return 0
}

start() {
        ebegin "Starting sendmail"
        /usr/bin/newaliases > /dev/null 2>&1
       (cd /var/spool/mqueue; rm -f xf*)
        /usr/sbin/sendmail ${SENDMAIL_OPTS} > /dev/null 2>&1
        eend $?
}
Comment 1 Nick Hadaway 2003-01-15 00:38:11 UTC
SIAOG 1.3.10
/etc/mail/aliases*

The system aliases are held in /etc/mail/aliases. A sample is given in sendmail/aliases which includes some aliases which must be defined:

cp sendmail/aliases /etc/mail/aliases
edit /etc/mail/aliases

You should extend this file with any aliases that are apropos to your system.

Normally sendmail looks at a database version of the files, stored either in /etc/mail/aliases.dir and /etc/mail/aliases.pag or /etc/mail/
aliases.db depending on which database package you are using. The actual path of this file is defined in the AliasFile option of the sendmail.cf file.
---
Nowhere in this section does it talk about permissions on the file... 
but anyway... it got me to thinking... maybe we shouldn't be allowing the normal user to be able to see an alias file as it gives one simple layer of protection from knowing "system secrets" ... so i have changed the permissions to 640 in mailbase-0.00-r5 (still marked unstable)

re: the init script changes... those changes look acceptable.  a -r1 will be released of 8.12.7 which i will include the init script solidification.
Comment 2 Nick Hadaway 2003-01-19 19:50:15 UTC
I have updated the /etc/init.d/sendmail script accordingly.