Display SSH Login Message

Display SSH Login Message

To display Welcome or Warning message for SSH users before login. We use issue.net file to display a banner massages.

Open the following file with NANO editor

# yum -y install nano

nano /etc/issue.net

Add the following banner sample message and save the file.

######################################
#    W E L C O M E   TO  MY  SSHD  SERVER   #
######################################

save the issue.net document

To use the banner message you have to edit the sshd_config document located in

# /etc/ssh/sshd_config

or

# /etc/ssh/ssh_config

Edit the sshd_config document with NANO

# nano /etc/ssh/sshd_config

or

# nano /etc/ssh_config

Search for the word “Banner” and uncomment out the line

#Banner /some/path

Change #Banner /some/path

Banner /etc/issue.net (You can use any path you like!)

Save the document!

Restart your SSHD server

# systemctl restart sshd

Check if the SSHD server is running

# systemctl status sshd

Connect to your SSH server and you will see your new login message