Permalink
Browse files

Create unique host keys

  • Loading branch information...
NEMS Linux
NEMS Linux committed Nov 7, 2018
1 parent ec7fbba commit 924281e5331c87711da4f3d4b5735aa08610c078
Showing with 12 additions and 2 deletions.
  1. +11 −1 gen-cert.sh
  2. +1 −1 init.sh
@@ -4,7 +4,7 @@
# nemslinux.com | baldnerd.com | category5.tv
echo ""
echo "Let's generate your SSL Certificates..."
echo "Generating unique SSL Certificates..."
# Install make-ssl-cert if it isn't already installed
if [[ ! -e /usr/sbin/make-ssl-cert ]]; then
@@ -22,6 +22,16 @@
# Cert is owned by root:root
chmod 600 /etc/ssl/certs/ssl-cert-snakeoil-combined.pem
echo "Generating unique SSH Certificates..."
/bin/rm /etc/ssh/ssh_host_*
dpkg-reconfigure openssh-server
systemctl restart ssh
echo "@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ WARNING: NEMS SERVER IDENTIFICATION HAS CHANGED! @
@ Next time you connect, you'll need to re-import! @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
"
echo Done.
exit 1
@@ -284,7 +284,7 @@ if (( $(awk 'BEGIN {print ("'$ver'" >= "'1.3'")}') )); then
sqlite3 /etc/nagvis/etc/auth.db "INSERT INTO users (userId,name,password) VALUES (1,'$username','$(echo -n '29d58ead6a65f5c00342ae03cdc6d26565e20954'$password | sha1sum | awk '{print $1}')');"
# Setup SSL Certificates
# Create new SSL and SSH Certificates
/usr/local/bin/nems-cert
fi

0 comments on commit 924281e

Please sign in to comment.