Recently a client's Joomla website got cracked, and guess what? Attackers breached through a 3rd party extension (of course not installed or suggested by me). After getting a super admin's credentials via SQL injection, they took the liberty to try the credentials on another website of the client and bingo, got 2 websites under their control and played fantastic background music on a brand new one-page template with vital information about improving my sex life. The client however preferred the old templates and content, so I reconstructed the old sites. Seems like I have to stick to my mum and dad's version about procreation.
The interesting part is how they found the website. I stumbled upon the top search keywords in Google Webmaster Tools and found out that lots of queries were like "option=com_...." (extension name blanked out).

One simply cannot know about all vulnerabilities of extensions. So what can be done about that, apart from typical best practices?
I guess activating SEF URLs and having menu items for that component (at least hidden menu items) will make sure you don't expose all your query parameters to search results. Of course that does not hinder SQL injections, but at least you masquerade your used extensions.
Besides, it's interesting to simply google the component's name (com_xxx). If a lot of pages about exploits come up, check the version exploited and fare carefully.
There are nice tweaks in the
video from Brian Teeman about SQL injection. They sure help, but you shouldn't feel to safe following these practices:
Changing the default jos_ DB prefix doesn't help if SQL injection queries use the #__ placeholder instead of jos_.
Removing user id 62 or username 'admin' does not help if the injection query can use the group field (group='super administrator') with a LIMIT 1.
That's it for me, hope you can use that info!
You need to be a member of All Together, As A Whole to add comments!
Join All Together, As A Whole