Nov 29, 2017

Customize Linux Logon

One of the easiest way to protect and secure SSH logins by displaying warming message to UN-authorized users or display welcome or informational messages to authorized users.
A legal banner contains some security warning information or general information, that alerts the user. It can be used for security, legal info, company policy, etc.
The /etc/issue file is a plain text file which will also accept certain escape sequences (see below) in order to insert information about the system. There is also the file which can be used when logging on remotely.
To display Welcome or Warning message for SSH users before login. Use file to display a banner massages. Open the following file with the editor.
vi /etc/
Add the banner message of your choice, and save the file. Next you would open the master ssh configuration file and enable banners.
vi /etc/ssh/sshd_config
Search for the word “Banner” and uncomment out the line and save the file.
#Banner /some/path
It should be like this.
Banner /etc/ (you can use any path you want)
Next, restart the SSH daemon to reflect new changes.
/etc/init.d/sshd restart
Now try to connect to server you will see banner message you just added.

Post a Comment

Featured Post

Modern tar recognizes the file format

One command works with any supported compression method. tar xf archive.tar.xz tar xf archive.tar.gz tar xf archive.tar etc. ...