Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/nextcloudpi.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornachoparker <nacho@ownyourbits.com>2018-05-17 15:12:59 +0300
committernachoparker <nacho@ownyourbits.com>2018-05-17 15:12:59 +0300
commit93a94da1822f2743efc95174d45b8a5480399daa (patch)
treeb116b0a93f9a92d779cbc76b42b1ab70a8952941
parentf04de1f0ae294cc9aa2496f055633670432e8868 (diff)
build: move SSH root hardening. Make it specific to Raspbian
-rw-r--r--nextcloudplus.sh1
-rw-r--r--raspbian-cleanup.sh3
2 files changed, 2 insertions, 2 deletions
diff --git a/nextcloudplus.sh b/nextcloudplus.sh
index 982b9675..afd26272 100644
--- a/nextcloudplus.sh
+++ b/nextcloudplus.sh
@@ -228,7 +228,6 @@ EOF
sed -i 's|^#LogLevel .*|LogLevel VERBOSE|' /etc/ssh/sshd_config
sed -i 's|^#Compression .*|Compression no|' /etc/ssh/sshd_config
sed -i 's|^#AllowAgentForwarding .*|AllowAgentForwarding no|' /etc/ssh/sshd_config
- sed -i 's|^#PermitRootLogin .*|PermitRootLogin no|' /etc/ssh/sshd_config
fi
## kernel hardening
diff --git a/raspbian-cleanup.sh b/raspbian-cleanup.sh
index f71045ba..b258111f 100644
--- a/raspbian-cleanup.sh
+++ b/raspbian-cleanup.sh
@@ -69,7 +69,8 @@ EOF
# clean build flags
rm /.ncp-image
- # disable SSH
+ # harden and disable SSH
+ sed -i 's|^#PermitRootLogin .*|PermitRootLogin no|' /etc/ssh/sshd_config
systemctl disable ssh
# enable randomize passwords