0

Bash Question or maybe it's just an Autorecon question:

I am trying to suppress any output back to the cli. I am stringing a bunch of tools together nmap, dirb, autorecon and other.

I can in do

autorecon > /dev/null

but this only forces the output of the initial startup of the code to be hidden but after a few minutes it starts putting the logging onto the screen.

I also tried flags --silent and -v0 but the actually just stop the entire code from running (so no hidden in commands)

Nathan
  • 107
  • 8
  • If your goal is to hide _logs_, you want to redirect stderr, not stdout. (stdout is where output goes; you can't send stdout both to a pipe _and_ to `/dev/null`, so `>/dev/null` will break any pipeline passing output to other commands). Though whether you really want to redirect just stderr or both stderr and stdout depends on _how_ you're combining this with other commands, which wasn't included in the question. – Charles Duffy May 26 '21 at 22:39
  • I do not want to hide logs, I just want to hide the output so its not displayed on the screen. Im using the tool to collect the data, and calling the data back all together afterwards – Nathan May 26 '21 at 23:29
  • [Edit] the question to distinguish if the linked duplicate doesn't help. – Charles Duffy May 26 '21 at 23:36
  • BTW, it might be a good place to start to run `autorecon >out 2>err`, and then inspect those two files to get a better understanding of what's written to stdout and what's written to stderr. – Charles Duffy May 26 '21 at 23:36

0 Answers0