ahoj,
nedelate nekdo pomoci nodejs ovladani sitovych prvku skrze telnet/ssh ? zkousim expect-telnet, asi by to mohlo delat co potrebuju, ale nejak se mi nedari ziskat jakykoliv delsi vypis.
var et = require("expect-telnet");
et("host_IP:23", [
{expect: "Username", send: "......\r"},
{expect: "Password", send: "......\r"},
{expect: ">" , send: "enable\r" },
{expect: "Password", send: "......\r"},
{expect: "#" , send: "show version\r"},
{expect: "", out: function(output) { console.log(output); }, send: "exit\rexit\r"} ],
{ timeout: 5000 },
function(err) {
if (err) console.error(err);
}
);
vysledek je "s" nebo "sh"... :-D pricemz tcpdumpem vidim, ze mi cely vypis prisel...