Skip to content

Instantly share code, notes, and snippets.

@ddouhine
Created December 16, 2014 14:37
Show Gist options
  • Save ddouhine/b867b5f5a54f8687ddca to your computer and use it in GitHub Desktop.
Save ddouhine/b867b5f5a54f8687ddca to your computer and use it in GitHub Desktop.
#use to speed up recon when targeting large ip ranges
1. scan targets with nessus
2. filter using #10107 plugin
3. save html report
4. extract urls using this:
#extract IP
grep "<H2 style=\"COLOR" nessus_10107.html | awk -F ">" '{print $2}' > col1
#extract ports
grep ")</H2><SPAN class=" nessus_10107.html | awk -F "/" '{print $2}' | awk -F ")" '{print $1}' > col2
#merge IP:ports
paste -d' ' col1 col2 | sed -e 's/ /:/g' | sed 's/^/http:\/\//' > url
#duplicate http with https
cat url | sed 's/^http/https/' >> url
#delete line-feeds (wkhtmltopdf can't use an input file and need URLs on one line)
cat url | sed ':a;N;$!ba;s/\n/ /g' > url4wk
5. wkhtmltopdf –default-header "`cat url4wk`" output.pdf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment