Commit 87c77b86 authored by Marcus Nordenberg's avatar Marcus Nordenberg Committed by Esteban Blanc

Do not fiddle with .rhosts

.rhosts should not be used nowadays

(cherry picked from commit 605dbe2984b11c02020231b5d45493ce21fca063)
parent 0e4b8496
...@@ -821,30 +821,6 @@ void pkg_node::fetchFiles(bool distribute) ...@@ -821,30 +821,6 @@ void pkg_node::fetchFiles(bool distribute)
ofu << "mv pwr_pkg.dat $pwrp_load\n" ofu << "mv pwr_pkg.dat $pwrp_load\n"
<< "rm -r /tmp/pkg_build\n"; << "rm -r /tmp/pkg_build\n";
// Group should not have write access to .rhosts file
ofu << "if [ -e $dir/.rhosts ]; then\n"
<< " if [ \"$USER\" == \"root\" ]; then\n"
<< " chown " << m_user << " $dir/.rhosts\n"
<< " chmod g-w $dir/.rhosts\n"
<< " else\n"
<< " if [ \"$tst\" != \"\" ]; then\n"
<< " sudo chown " << m_user << " $dir/.rhosts\n"
<< " sudo chmod g-w $dir/.rhosts\n"
<< " fi\n"
<< " fi\n"
<< "fi\n"
<< "if [ -e $dir/.ssh/authorized_keys ]; then\n"
<< " if [ \"$USER\" == \"root\" ]; then\n"
<< " chown " << m_user << " $dir/.ssh/authorized_keys\n"
<< " chmod g-w $dir/.ssh/authorized_keys\n"
<< " else\n"
<< " if [ \"$tst\" != \"\" ]; then\n"
<< " sudo chown " << m_user << " $dir/.ssh/authorized_keys\n"
<< " sudo chmod g-w $dir/.ssh/authorized_keys\n"
<< " fi\n"
<< " fi\n"
<< "fi\n";
ofu.close(); ofu.close();
// Create a data file with description and all installed files // Create a data file with description and all installed files
......
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