Add a Logon Warning Notification to Linux
#Linux #LogonWarning #Customization
Full steps can be found at https://i12bretro.github.io/tutorials/0599.html
01. Log into the Linux device
02. Run the following command in a terminal
# create the logon notification text
sudo nano /etc/logon-warning.txt
03. Enter the text to be displayed during logon, below is an example ******************************* WARNING ******************************* * * * This system is intended for use by authorized users only. * * Unauthorized or improper use of this system is strictly prohibited. * * * ***********************************************************************
04. Press CTRL+O, Enter, CTRL+X to write the changes
05. Continue with the following command in terminal
# edit ssh config file
sudo nano /etc/ssh/sshd_config
06. Press CTRL+W and search for Banner
07. Uncomment the Banner line by removing the #
08. Enter the path to the logon-warning.txt file as the value
Banner /etc/logon-warning.txt
09. Press CTRL+O, Enter, CTRL+X to write the changes
10. Continue with the following command in terminal
# restart the ssh server
sudo systemctl restart ssh*
11. That's it, try connecting to a new session and the logon warning message should be displayed
### Connect with me and others ###
★ Discord: https://discord.com/invite/EzenvmSHW8
★ Reddit: https://reddit.com/r/i12bretro
★ Twitter: https://twitter.com/i12bretro