Set same permissions for /root/.ssh/authorized_keys
in post-tasks.d/010fix-ssh-perms as is done by Puppet with sunet::ssh_keys.
This commit is contained in:
parent
1bd6524ad3
commit
ca353ed406
|
@ -17,7 +17,7 @@ if test -f /root/.ssh/authorized_keys; then
|
||||||
if test `stat -t /root/.ssh/authorized_keys | cut -d\ -f5` != 0; then
|
if test `stat -t /root/.ssh/authorized_keys | cut -d\ -f5` != 0; then
|
||||||
chown root.root /root/.ssh/authorized_keys
|
chown root.root /root/.ssh/authorized_keys
|
||||||
fi
|
fi
|
||||||
if test `stat --printf=%a /root/.ssh/authorized_keys` != 600; then
|
if test `stat --printf=%a /root/.ssh/authorized_keys` != 440; then
|
||||||
chmod 600 /root/.ssh/authorized_keys
|
chmod 440 /root/.ssh/authorized_keys
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue