By Scott Behrens
I was recently on an application blackbox assessment on a pretty solid application. One thing that might get glazed over when developing a web application is the security of third party plugins or frameworks. During the process of the assessments I identified a plugin that seemed to be installed but not really enabled. It seemed to be SQL injectable but had nothing in the database. No problem! I found a method that allowed me to enter data in the database and then used another function to do Boolean based SQL injection against it. This issue was easy to identify because the plugin developer stated the code was vulnerable in a comment. I just did a Google search for the plugin name, and read though the source code. Although slightly redacted (to protect the plugin developer while we disclose the finding), the comment basically stated that ” request variables have not been escaped and may be vulnerable to SQL injection”.
What’s the takeaway (outside of a few asprin)? Don’t tell an attacker how to attack your application, security review third party plugins which may not have ever been assessed (especially small Github projects like the one above), and use prepared statements!