This article will guide you through setting up a multi-line login banner in SRX.
By default, Junos OS does not display any login message. You can configure the device to display a login message by including the message statement at the [edit system login] hierarchy level. Whereas the device displays a login message after a user connects to the device but before the user logs in to the device.
To configure a multi-line login banner that displays during device login, it is necessary to include special characters in the banner configuration.
You can format the message text using the following special characters. If the text contains spaces, enclose it in quotation marks:
Here's an example of configuring the banner:
set system login message "\n\t*************************************************************************************************************************************\n\t*\n\t* WARNING *\n\t*\n\t* This is a private system and may only be used with the prior authorisation of the owner (the “System Owner”). *\n\t*\n\t* All other access to, or use of, this system is strictly prohibited. *\n\t*\n\t* Unauthorised attempts to access or use this system are tracked by the System Owner, may constitute a criminal offence, *\n\t*\n\t* and may result in criminal or civil legal action. *\n\t*\n\t* Any use of the system and networks is subject to compliance with the System Owner's policies, standards and related requirements.*\n\t*\n\t* This includes, without limitation, the System Owner's Code of Conduct and requirements for acceptable use of devices and systems.*\n\t*\n\t* The System Owner reserves the right to monitor, and where necessary, restrict the use of the system and networks. *\n\t*\n\t* Authorised users should refer to the System Owner's privacy notices for information on how personal information is processed by *\n\t*\n\t* the System Owner. *\n\t*\n\t* By accessing the system, you understand, acknowledge and accept these restrictions. *\n\t*\n\t*************************************************************************************************************************************"
Ensure the statement is written on a single line for it to function correctly.
Below is the output from executing the provided banner command:
https://www.juniper.net/documentation/us/en/fips-security-branch-dual-ac/topics/concept/display-login-message-announcement.html