Advanced Features

Telnet & SSH

10min
this page outlines how to enable telnet and/or ssh on a networked brightsign player you can use telnet/ssh to connect to the brightsign application console, which hosts the brightscript debug console docid\ ywksi6x 2hez1bwztfhmp and receives print messages from brightscript this is useful when the serial port (the default i/o for the brightsign application console) is inaccessible telnet and ssh have been tested and proven to work with putty, but any client with telnet/ssh support should work telnet offers no security features, while ssh uses encrypted sessions and requires credentials to access the shell however, for security reasons, we do not recommend enabling either telnet or ssh in a production environment; they should only be used for debugging presentations in a test environment enable telnet to enable telnet on a player, run an autorun brs script containing the following code brightscript reg = createobject("roregistrysection", "networking") reg write("telnet","23") reg flush() this will allow a telnet connection on port 23 (the default port for telnet) you can change the second parameter on the write() method to open telnet on a different port if desired telnet will not be enabled until the script exits and the player reboots you can use the rebootsystem() function to terminate the autorun brs script and reboot the player see telnet & ssh docid\ l0l gyihavtdbci9ffcqh for info about how to access the player via telnet disable telnet to disable telnet, run an autorun brs script containing the following code brightscript reg = createobject("roregistrysection", "networking") reg delete("telnet") reg flush() the player will need to be rebooted for this setting to take effect enable ssh a limited ssh environment is available, with the username brightsign , that allows you to attach to the brightscript interpreter process to enable ssh on a player, run an autorun brs containing the following code brightscript reg = createobject("roregistrysection", "networking") reg write("ssh","22") n=createobject("ronetworkconfiguration", 0) n setloginpassword("password") n apply() reg flush() this will allow an ssh connection on port 22 (the default port for ssh) you can change the second parameter on the write() method to open ssh on a different port note that the interface number used to create the ronetworkconfiguration instance (0 for ethernet or 1 for wifi) is not significant the code also sets the ssh login password to "password", which can be changed by editing the setloginpassword() parameter the username will always be "brightsign" ssh will not be enabled until the script exits and the player reboots you can use the rebootsystem() function to terminate the autorun brs script and reboot the player alternatively, you can use the end function to exit the script, then reboot the player manually see telnet & ssh docid\ l0l gyihavtdbci9ffcqh for info about how to access the player via ssh disable ssh to disable ssh, run an autorun brs script containing the following code brightscript reg = createobject("roregistrysection", "networking") reg delete("ssh") reg flush() the player will need to be rebooted for this setting to take effect access the telnet / ssh connection to connect to the player via telnet/ssh, enter the ip address of the player with the configured port into your client application you can obtain the ip address of the player by booting up the player without an sd card in the examples below, update instances of {{ip address}} or {{serial number}} with the proper values telnet {{ip address}} ssh brightsign@{{ip address}} since dhcp configured devices often change ip addresses when rebooted, this process will be easier if you assign the player a static ip address during setup if this is not feasible, you may be able to connect to the player using the following (this requires linux / macos or windows with bonjour installed) telnet brightsign {{serial number}} local ssh brightsign\@brightsign {{serial number}} local use telnet / ssh with serial by default, enabling debugging output via telnet or ssh will disable such output over serial the serial port can still be used for interaction with serial devices via the roserialport docid 25ega25abzftxgitvvmms object it is possible to enable debugging output over both telnet/ssh and serial; however, interaction with serial devices via the roserialport docid 25ega25abzftxgitvvmms object will become highly unreliable to enable debugging output over serial as well, run a script containing the following code after telnet/ssh has been enabled brightscript reg = createobject("roregistrysection", "networking") print "trying to enable serial with telnet/ssh" print reg write("serial with telnet", "1") reg flush() additional notes though the registry key is labeled "serial with telnet", it applies to both telnet and ssh configurations multiple simultaneous connections are permitted via telnet or ssh the output is mirrored as a single, shared session a running script can be interrupted by pressing ctrl c (if script debugging is disabled, you may need to press ctrl c twice) the ssh password remains set even if ssh access is disabled there is currently no way to clear the password there is currently no support for authenticating against an ssh public key