Vulnerabilities / Threats
7/10/2011
11:13 PM
Connect Directly
RSS
E-Mail
50%
50%

As SQL Injection Attacks Surge, New Report Offers Insight On How To Prevent Them

SQL injection has taken its place among the top Web threats and compromised some of the Internet’s best-known companies. Here's a look at how SQL injection attacks happen -- and what you can do about it

[Excerpted from “Stop SQL Injection: Don’t Let Thieves In Through Your Web Apps,” a new report posted this week on Dark Reading’s Database Security Tech Center.]

SQL injection continues to be one of the primary methods by which attackers exploit vulnerable Web applications and gain access to critical corporate databases. These attacks strike various types of infrastructures and software platforms; sometimes they are launched from inside the corporate network, but more typically external attackers use globally accessible Web applications as entry points.

There have been several instances of SQL injection attacks in the news recently, including a major breach that hit Sony Corp. What all these attacks have in common is that they rely on structured data, stored in a relational database in a multitier application structure.

SQL injection flaws are arguably public enemy No. 1. Even after years as a leading Web security threat, SQL injection still makes up the largest portion of the vulnerabilities discovered today. In 2010, they were by far the most commonly found Web application vulnerability, followed by cross-site scripting errors, and have been on the OWASP Top 10 list of most serious Web security issues for years.

SQL injection, at its most basic level, is simply manipulating an existing SQL query to perform an action not intended by the developer. This is typically done through the user interface in some area of a Web application.

All SQL injection vulnerabilities begin with nonvalidated user input of some type. User input can take many forms and include anything an attacker can manipulate that is processed by the server in some way. This includes user-agents, HTTP headers, POST parameters, cookies, GET parameters, and even referrer headers.

What makes nonvalidated user input unique is that the application does not perform sufficient checks to ensure that the input received is of the type and manner expected. Simplified, this means that although your application is written to receive, for example, a string of alphanumeric characters to be input as a user name, it does not validate that input and allows an attacker to insert, in the case of SQL injection, a database query.

There are two broad methods attackers use to take advantage of SQL injection vulnerabilities: automated and manual. These two kinds of attacks are mechanically very different. Automated exploitation is generally the result of a tool built for a specific purpose. LizaMoon and Asprox, for example, use mass injection attacks to maximize their breadth and spread their code indiscriminately. These types of mass attacks generally target a very specific application architecture, such as IIS servers running classic ASP with Microsoft SQL Server database servers, in the case of Asprox.

In many cases, the attacker can take complete control over the underlying operating system of the SQL server; the attacker can even take over the Web application, and ultimately the Web server itself.

To get a detailed description of how SQL injection attacks work -- and to get recommendations on how to prevent them -- download the free report.

Have a comment on this story? Please click "Comment" below. If you'd like to contact Dark Reading's editors directly, send us a message.

Comment  | 
Print  | 
More Insights
Register for Dark Reading Newsletters
White Papers
Flash Poll
Current Issue
Cartoon
Video
Slideshows
Twitter Feed
Dark Reading - Bug Report
Bug Report
Enterprise Vulnerabilities
From DHS/US-CERT's National Vulnerability Database
CVE-2013-6117
Published: 2014-07-11
Dahua DVR 2.608.0000.0 and 2.608.GV00.0 allows remote attackers to bypass authentication and obtain sensitive information including user credentials, change user passwords, clear log files, and perform other actions via a request to TCP port 37777.

CVE-2014-0174
Published: 2014-07-11
Cumin (aka MRG Management Console), as used in Red Hat Enterprise MRG 2.5, does not include the HTTPOnly flag in a Set-Cookie header for the session cookie, which makes it easier for remote attackers to obtain potentially sensitive information via script access to this cookie.

CVE-2014-3485
Published: 2014-07-11
The REST API in the ovirt-engine in oVirt, as used in Red Hat Enterprise Virtualization (rhevm) 3.4, allows remote authenticated users to read arbitrary files and have other unspecified impact via unknown vectors, related to an XML External Entity (XXE) issue.

CVE-2014-3499
Published: 2014-07-11
Docker 1.0.0 uses world-readable and world-writable permissions on the management socket, which allows local users to gain privileges via unspecified vectors.

CVE-2014-3503
Published: 2014-07-11
Apache Syncope 1.1.x before 1.1.8 uses weak random values to generate passwords, which makes it easier for remote attackers to guess the password via a brute force attack.

Best of the Web
Dark Reading Radio
Archived Dark Reading Radio
Marilyn Cohodas and her guests look at the evolving nature of the relationship between CIO and CSO.