Guest User

Untitled

a guest
May 23rd, 2018
127
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. ; Generate a list of random IPs to be fed into nmap so that nmap may scan
  2. ; aggressively but not swamp any given subnet within the 172.16.0.0/12 range.
  3. ;
  4. ; Licensed under the EPL. (fwiw ;)
  5.  
  6. (use '[clojure.contrib.seq-utils :only (shuffle)]
  7. '[clojure.contrib.duck-streams :only (write-lines)])
  8.  
  9. (write-lines
  10. "./ips.txt"
  11. (shuffle
  12. (for [octet1 [172]
  13. octet2 (range 16 33)
  14. octet3 (range 256)
  15. octet4 (range 256)]
  16. (str octet1 \. octet2 \. octet3 \. octet4))))
Add Comment
Please, Sign In to add comment