Commit a7ef4c4c authored by Dmitry Bogatov's avatar Dmitry Bogatov

Fix wrong permissions of /var/run/utmp

Set permissions of /var/run/utmp to 664 (due bug in [ce3417] it was 644).
Also, change order of "chgrp" and "chown" calls, since "chgrp" can
affect permssions.

Thanks: Thorsten Glaser <tg@mirbsd.de>
Closes: #932380
parent 22e43c01
......@@ -33,8 +33,8 @@ do_start () {
readonly utmp='/var/run/utmp'
if > "${utmp}" ; then
chmod 644 "${utmp}" || log_warning_msg "failed to chmod ${utmp}"
chgrp utmp "${utmp}" || log_warning_msg "failed to chgrp ${utmp}"
chmod 664 "${utmp}" || log_warning_msg "failed to chmod ${utmp}"
return 0
else
log_failure_msg "failed to truncate ${utmp}"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment