Last active
August 29, 2018 22:21
-
-
Save picatz/45e4d8b35a314abd244453d9cc712b65 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
require "shodanz" | |
# create a shodanz client | |
client = Shodanz.client.new | |
# scan a host | |
result = client.rest_api.scan("8.8.8.8") | |
# save the scan result as json to a file | |
File.open('result.json', 'w') { |f| f.write(result.to_json) } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment