Red Hat Bugzilla – Bug 1008404
4.4.3. Configuring Servers for Enhanced Entitlements Reporting - step 6. addition: chown -R swreport:swreport /home/swreport/.ssh
Last modified: 2013-10-11 08:38:18 EDT
Description of problem:
In the documentation we advise to create /home/swreport/.ssh and /home/swreport/.ssh/authorized_keys, but when blindly following the guide, you end up with /home/swreport/.ssh owned by root and not swreport user.
IMO into the step 7, something like this should be appended:
# chown -R swreport:swreport /home/swreport/.ssh
Step 6 and 7 read:
6. Prepend the SAM public key content in /home/swreport/.ssh/authorized_keys with the following:
7. This ensures the swreport user only uses the spacewalk-report command.
Set permissions and the SELinux content on the .ssh directory and authorized_keys file for the swreport user.
[root@sat56] # chown -R swreport:swreport /home/swreport/.ssh
[root@sat56] # chmod 700 /home/swreport/.ssh
[root@sat56] # chmod 600 /home/swreport/.ssh/authorized_keys
[root@sat56] # restorecon -R /home/swreport/.ssh
Looks good to myself (usage of -R is OK, since directory shouldn't have anything but standard stuff).