A few days ago I figured out that several blogs operated by T-Mobile Austria had a Git repository exposed which included their wordpress configuration file.
Due to the fact that a phpMyAdmin installation was also accessible this would have allowed me to change or delete their database and subsequently take over their blogs.
Git Repositories, Private Keys, Core Dumps
Last year I discovered that the German postal service exposed a database with 200.000 addresses on their webpage, because it was simply named
dump.sql (which is the default filename for database exports in the documentation example of mysql).
An Australian online pharmacy exposed a database under the filename
xaa, which is the output of the "split" tool on Unix systems.
It also turns out that plenty of people store their private keys for TLS certificates on their servers - or their SSH keys.
Crashing web applications can leave behind coredumps that may expose application memory.
For a while now I became interested in this class of surprisingly trivial vulnerabilities:
People leave files accessible on their web servers that shouldn't be public.
I've given talks at a couple of conferences (recordings available from Bornhack, SEC-T, Driving IT).
I scanned for these issues with a python script that extended with more and more such checks.
Scan your Web Pages with snallygaster
Apart from many checks for secret files it also contains some checks for related issues like checking invalid src references which can lead to Domain takeover vulnerabilities, for the Optionsleed vulnerability which I discovered during this work and for a couple of other vulnerabilities I found interesting and easily testable.
Some may ask why I wrote my own tool instead of extending an existing project. I thought about it, but I didn't really find any existing free software vulnerability scanner that I found suitable. The tool that comes closest is probably Nikto, but testing it I felt it comes with a lot of checks - thus it's slow - and few results.
I wanted a tool with a relatively high impact that doesn't take forever to run. Another commonly mentioned free vulnerability scanner is OpenVAS - a fork from Nessus back when that was free software - but I found that always very annoying to use and overengineered.
It's not a tool you can "just run". So I ended up creating my own tool.
A Dragon Legend in US Maryland
Finally you may wonder what the name means.
The Snallygaster is a dragon that according to some legends was seen in Maryland and other parts of the US.
Why that name? There's no particular reason, I just searched for a suitable name, I thought a mythical creature may make a good name.
So I searched Wikipedia for potential names and checked for name collisions.
This one had none and also sounded funny and interesting enough.
I hope snallygaster turns out to be useful for administrators and pentesters and helps exposing this class of trivial, but often powerful, vulnerabilities. Obviously I welcome new ideas of further tests that could be added to snallygaster.