Remove ssh references from mesh client setup

This commit is contained in:
Bob Mottram 2016-08-11 14:01:45 +01:00
parent 7571380f51
commit 06e2232482
1 changed files with 0 additions and 26 deletions

View File

@ -535,26 +535,6 @@ function show_desktop_icons {
killall mate-panel
}
function disable_password_logins {
if [ ! -d /home/$DEFAULT_USERNAME ]; then
echo $"Home directory for $DEFAULT_USERNAME not found"
exit 3682572
fi
# create an authorized_keys file
if [ ! -d /home/$DEFAULT_USERNAME/.ssh ]; then
mkdir -p /home/$DEFAULT_USERNAME/.ssh
fi
if [ ! -f /home/$DEFAULT_USERNAME/.ssh/authorized_keys ]; then
touch /home/$DEFAULT_USERNAME/.ssh/authorized_keys
fi
chown -R $DEFAULT_USERNAME:$DEFAULT_USERNAME /home/$DEFAULT_USERNAME/.ssh
# disable password logins
sed -i 's|#PasswordAuthentication.*|PasswordAuthentication no|g' /etc/ssh/sshd_config
sed -i 's|PasswordAuthentication.*|PasswordAuthentication no|g' /etc/ssh/sshd_config
}
function enable_batman_daemon {
systemctl enable batman
systemctl daemon-reload
@ -572,10 +552,6 @@ function mesh_amnesic {
echo "if [ -f /home/${MY_USERNAME}/.bash_history ]; then" >> /usr/bin/amnesic
echo " shred -zu /home/${MY_USERNAME}/.bash_history" >> /usr/bin/amnesic
echo 'fi' >> /usr/bin/amnesic
echo "if [ -f /home/${MY_USERNAME}/.ssh/authorized_keys ]; then" >> /usr/bin/amnesic
echo " shred -zu /home/${MY_USERNAME}/.ssh/authorized_keys" >> /usr/bin/amnesic
echo " echo '' > /home/${MY_USERNAME}/.ssh/authorized_keys" >> /usr/bin/amnesic
echo 'fi' >> /usr/bin/amnesic
echo "if [ -f /home/${MY_USERNAME}/.xsession-errors ]; then" >> /usr/bin/amnesic
echo " shred -zu /home/${MY_USERNAME}/.xsession-errors" >> /usr/bin/amnesic
echo 'fi' >> /usr/bin/amnesic
@ -606,7 +582,6 @@ function mesh_amnesic {
function mesh_restart_daemons {
systemctl restart avahi-daemon
systemctl restart ssh
systemctl restart tox-bootstrapd
if [ $ENABLE_ZERONET ]; then
systemctl restart zeronet
@ -803,7 +778,6 @@ if [ -f $MESH_INSTALL_SETUP ]; then
fi
configure_toxcore
create_tox_user
disable_password_logins
mesh_amnesic
if [ ! -f $MESH_AMNESIC ]; then