New Techniques Obfuscate, Optimize SQL Injection Attacks

  /     /     /  
Publicated : 22/11/2024   Category : security


New Techniques Obfuscate, Optimize SQL Injection Attacks


Black Hat researcher to demonstrate new methods for getting around defenses even more quickly to extract database data through SQLi



SQL injection attacks already stand as one of the most effective means hackers use to break into enterprise database infrastructures today. Now the attack could get a boost in effectiveness when a researcher at Black Hat USA later this month takes the wraps off new techniques that will make it harder for defenses to detect SQL injection attempts and which will speed up the process of extracting data from databases through blind SQL injection attacks.
It just came out of playing around with SQL injections and seeing what they were capable of, says Roberto Salgado, founder and CTO of security consultancy Websec. I started discovering all of these improvements I could make and places where I could make the data extraction from the database faster.
Salgados discoveries centered around both obfuscation and optimization of SQL injection attacks. On the obfuscation side, he refined techniques that take advantage of the discrepancies in the way that databases handle certain characters versus applications and the Web application firewalls that protect them.
I started noticing how [by] sometimes changing just one character or adding one special thing -- if you can figure out or guess features of the database which maybe the developer of the firewall wasnt aware of -- it can be very easy to get around firewalls, he says.
TFor example, the way Oracle handles the null byte, or 00, is one such instance.
Oracle just reads the null byte as the white space, so everything runs as normal. Whereas the firewall might see the null byte as something else, a lot of times null bytes will actually terminate programs, he says. So some databases will just do a null byte and ignore it, thinking its harmless on the whole, but its really allowing that SQL injection to get by the firewall undetected.
[Why do injection attacks still stand on top of the OWASP Top 10 2013? See
Myth-Busting SQL- And Other Injection Attacks
.]
While he believes the obfuscation techniques will certainly interest penetration testers, he believes that his techniques on the optimization side are the potential game changers for blind SQL injection.
Having an optimized SQL injection can definitely help us because were doing a lot fewer requests to the server, which will get the data faster, he says. It will use less bandwidth and be less of a burden on the server, which means we can get the data faster without alerting as many people or giving them enough time to react to the attack.
The difficulty of blind SQL injection is that the attacker can extract only one character at a time, Salgado says.
Sometimes we have the possibility when errors are enabled and showing we can just dump the data through errors, but thats not always possible, he says.
Salgado says his new methods are completely new, making it possible to extract database information through blind SQL injection 20 to 40 percent faster than the current optimization technique, called the bisection method. One of the techniques he will demonstrate is a method that makes it possible to cut down the current testing of parameters for single, double, or no quotes to a single test. So for a site with, say, 400 parameters, thats 800 fewer tests needed. Similarly, he has managed to reduce the number of requests to the server in other ways.
With my method Im able to successfully reduce the amount of characters required to look for to two. What it does is it maps the set of characters wed be interested in looking for in a list to their position in that list, and then we convert that position to binary, he says Then instead of having to extract letters and numbers, say from A to Z, zero to nine, all we have to look for at this point is just one or zero.
The demonstration that Salgado will do on obfuscation and optimization techniques at Black Hat will not only provide penetration testers with new techniques for improving on their SQL injection mojo, but it should also give those responsible for protecting database resources reason to pause. The faster and easier it is for attackers to get around Web application firewalls, the more imperative to see that they are no fix for SQL injection.
I think what is really important to understand is that a firewall will not be the end goal -- it wont protect you against everything, he says, explaining that organizations should be looking to fix the root vulnerabilities in the application. You should really have a security team look at your application, make sure that everything is secure, and then add the firewall as an extra step, just in case. A firewall will stop most script kiddies or amateurs, but theyre a joke to anyone with slightly more sophistication.
Have a comment on this story? Please click Add Your Comment below. If youd like to contact
Dark Readings
editors directly,
send us a message
.

Last News

▸ Travel agency fined £150,000 for breaking Data Protection Act. ◂
Discovered: 23/12/2024
Category: security

▸ 7 arrested, 3 more charged in StubHub cyber fraud ring. ◂
Discovered: 23/12/2024
Category: security

▸ Nigerian scammers now turning into mediocre malware pushers. ◂
Discovered: 23/12/2024
Category: security


Cyber Security Categories
Google Dorks Database
Exploits Vulnerability
Exploit Shellcodes

CVE List
Tools/Apps
News/Aarticles

Phishing Database
Deepfake Detection
Trends/Statistics & Live Infos



Tags:
New Techniques Obfuscate, Optimize SQL Injection Attacks