Alertra Script Language 1.9

telnet

Connects to a Telnet server. If you supply a userid and password, this check will connect to the Telnet server and attempt to login. The 'telnet' command looks for the string 'ogin:' and then sends the userid. It then looks for 'ssword:" and sends the password. There is no way of knowing whether the login actually succeeds or not from a protocol standpoint; you should check the $CONTENT variable for some known value to tell whether the login was successful.

If you don't supply a userid and password, this command will return everything up to "ogin:" in $CONTENT.

You must call dns and tcp to set the hostname and port to connect to.

usage: telnet [userid] [password]

parameters:

req name type description
N userid expression The userid to use when logging into the server
N password expression The password to use when logging into the server

examples

telnet

Connects to the Telnet server identified in the last dns command.

telnet "joe" "garage"

Connects to the Telnet server identified in the last dns command. The user "joe" and password "garage" are supplied for the Telnet server authentication.


Alertra Script Language: Language Reference