Sendmail recommended permissions for apache/php server

Matthew Seaman matthew at FreeBSD.org
Thu Apr 12 14:12:32 UTC 2012


On 12/04/2012 14:40, Ian Lord wrote:
>> What are the permissions on /usr/libexec/sendmail/sendmail ? They should
>> >look like this:
>> >% ls -la /usr/libexec/sendmail/sendmail
>> >-r-xr-sr-x  1 root  smmsp  662136 Apr  1 08:38
>> >/usr/libexec/sendmail/sendmail
> # ls -al /usr/libexec/sendmail/sendmail
> -r-xr-sr-x  1 root  wheel  707160 Jan  3 02:57 /usr/libexec/sendmail/sendmail
> 
> So the group is wrong... I changed it from wheel to smmsp and
> everything works fine now !
> 
> Thanks a lot for the fix, but this server is a clean install of
> 9.0-RELEASE that I installed about 2-3 months ago. I never changed the
> permission myself on that file so I guess there is something wrong that
> would need to be fixed (unless it's already fixed in newer versions).

I haven't had any similar problems on 9.0 systems I've installed so I
don't think it is an obvious and universal bug in the system installer.
 It might be the case that you did something differently -- if you can
reproduce the effect, and if it's not by doing something daft like 'oh,
and here is where we recursively chgrp the whole filesystem for no
apparent reason' then please do send a PR with the details.

If you want to ensure that almost everything has the correct ownership
and permissions, then you can use mtree(8).  eg.

    # cd /
    # mtree -Ue -f /etc/mtree/BSD.root.dist
    # mtree -Ue -f /etc/mtree/BSD.sendmail.dist
    # cd /usr
    # mtree -Ue -f /etc/mtree/BSD.usr.dist
    # cd /usr/include
    # mtree -Ue -f /etc/mtree/BSD.include.dist
    # cd /var
    # mtree -Ue -f /etc/mtree/BSD.var.dist

... although now I come to look at it, this won't actually fix the group
ownership on /usr/libexec/sendmail/sendmail for example.  For that,
you'ld probably have to use the system sources or the installation media.

	Cheers,

	Matthew

-- 
Dr Matthew J Seaman MA, D.Phil.
PGP: http://www.infracaninophile.co.uk/pgpkey


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 267 bytes
Desc: OpenPGP digital signature
Url : http://lists.freebsd.org/pipermail/freebsd-questions/attachments/20120412/28ff5de7/signature.pgp


More information about the freebsd-questions mailing list