Shodan For Penetration Testers: Michael "Theprez98" Schearer
Shodan For Penetration Testers: Michael "Theprez98" Schearer
Shodan For Penetration Testers: Michael "Theprez98" Schearer
box testing
hacking Security auditing Vulnerability assessment Standards compliance Training All of the above
WHAT IS SHODAN?
(http://www.shodanhq.com/) is a computer search engine designed by web developer John Matherly (http:// twitter.com/achillean) While SHODAN is a search engine, it is much different than content search engines like Google, Yahoo or Bing
search engines crawl for data on web pages and then index it for searching SHODAN interrogates ports and grabs the resulting banners, then indexes the banners (rather than the web content) for searching
than to locate specific content on a particular search term, SHODAN is designed to help the user find specific nodes (desktops, servers, routers, switches, etc.) with specific content in their banners Optimizing search results requires some basic knowledge of banners
BASIC OPERATIONS
terms are entered into a text box (seen below) Quotation marks can narrow a search Boolean operators + and can be used to include and exclude query terms (+ is implicit default)
country
port
Filtering by country can be accomplished by clicking on the country map (available from the drop down menu) Mouse over a country for the number of scanned hosts for a particular country
Find apache servers running version 2.2.3 Top four countries matching your query
net filter allows you to refine your searches by IP/CIDR notation The OS filter allows you to refine searches by operating system
port Current collection is limited to ports 21 (FTP), 22 (SSH), 23 (Telnet), and 80 (HTTP), while the overwhelming majority of collection is HTTP More ports/services coming (send requests to the developer via Twitter)
searches are available on the main page Logged in users can save searches and share them with other users
lets you export up to 1,000 results per credit in XML format Credits can be purchased online Sample data export file is available
PENETRATION TESTING
No authentication
SHODAN for penetration testing requires some basic knowledge of banners including HTTP status codes Banners advertise service and version Banners can be spoofed (unlikely?)
401 Unauthorized Request requires authentication 403 Forbidden Request is denied regardless of authentication
OK banner results will load without any authentication (at least not initially) 401 Unauthorized banners with Wwwauthenticate indicate a username and password pop-up box (authentication is possible but not yet accomplished, as distinguished from 403 Forbidden) Some banners advertise defaults
Take note of the Www-authenticate line which indicates the requirement for a username and password
In fact, among cisco results these two lines are more than 99% mutually exclusive
suggests that Cisco 200 OK banners that include the Last-modified line do not require any authentication (at least not initially) The results on the previous slide suggest there are potentially 4,200+ Cisco devices that do not require authentication
Nope. No authentication required for Level 15! No authentication required for configure commands
show running-config
default password search locates servers that have those words in the banner This doesnt suggest that these results will be using the defaults, but since theyre advertising the defaults they would potentially be the lowest hanging fruit
The server line indicates this is likely to be a print server; also note the 401 and Wwwauthenticate which indicates the likelihood of a username and password pop-up box
does not suggest that this device is using the default password, but it does mean that it is a possibility While no username is listed, a null username or admin is always a good guess And did it work?
PWN w to Ho n ISP a
with direct access to Cisco 7606 Router VLAN IDs for internal ISP network, hotels, condos, apartments, convention center, public backbone SNMP server IP address and community strings
OTHER EXAMPLES
javascript:SnapshotWin() client.html
system.html security.html network.html wireless.html ddns.html accesslist.html audiovideo.html cameracontrol.html mailftp.html motion.html application.html syslog.html parafile.html maintain.html
THE FUTURE
The Future
API
in the works for program integration Summary report for export option Software fingerprints Collection of HTTPS
CONCLUSIONS
Conclusions
SHODAN
aggregates a significant amount of information that isnt already widely available in an easy to understand format Allows for passive vulnerability analysis Bottom line: SHODAN is a potential gamechanger for pen testers that will help shape the path for future vulnerability assessments
Matherly (http://twitter.com/achillean) Gianni Amato (SHODAN Helper) sagar38 (SHODAN Search Provider)
QUESTIONS