Restrict the key file permissions as required by some OSes
Change-Id: I1774c8e50a8cabc7d4ac8046ed1325160b5fc0c3
diff --git a/tools/test/bin/onos-push-keys b/tools/test/bin/onos-push-keys
index 1eb1eec..55ee2ee 100755
--- a/tools/test/bin/onos-push-keys
+++ b/tools/test/bin/onos-push-keys
@@ -11,8 +11,10 @@
scp -q ~/.ssh/id_rsa.pub $remote:/tmp
ssh $remote "
mkdir -p ~/.ssh
+ chmod 700 ~/.ssh
cat /tmp/id_rsa.pub >> ~/.ssh/authorized_keys
sort -u ~/.ssh/authorized_keys > ~/.ssh/authorized_keys.bak
mv ~/.ssh/authorized_keys.bak ~/.ssh/authorized_keys
+ chmod 600 ~/.ssh/authorized_keys
"
ssh -n -o PasswordAuthentication=no $remote true