HomeFreeBSD

rc.d/ntp: Ensure ntpd.leap-seconds.list is readable by ntpd

Description

rc.d/ntp: Ensure ntpd.leap-seconds.list is readable by ntpd

When a use sets umask in login.conf(5) to 027 or 077 a subsequently
fetched /var/db/ntpd.leap-seconds.list will inherit the permissions
allowed by the umask, resulting in a file that may not be readable
ntpd running under the ntp account. This patch adds a umask command
to preempt the umask in login.conf(5) prior to fetching a new copy
of the leap-seconds file.

PR: 261298
Reported by: Martin Waschbusch <martin@waschbuesch.de>

(cherry picked from commit c6806434e79079f4f9419c3ba4fec37efcaa1635)

Details

Provenance
cyAuthored on Jan 18 2022, 2:14 PM
Parents
rGc8c305ac071a: Fix inverse sleep logic in buf_daemon().
Branches
Unknown
Tags
Unknown