Posted 19 June 2009 - 08:07 AM
From how I interpret that quote, what they're talking about is really nothing ground breaking.
They're saying that, by using SQL Injection, you can inject HTML code into a website and when it gets pulled from the database and echoed to the client, it will execute. Basically allowing you to XSS their website.
The problem with this is, if the website designer has any sense, the XSS filtering will take place when the DB data is echoed out. Not before it's uploaded. So this won't cause any harm at all. If the XSS filtering is done before the user data is saved to the DB, then yes. This could allow for persistent attacks. That's unlikely, though.
Take this forum, for instance. What I'm typing now is going to be saved to the CS database. It's very likely that my text will be filtered/sanitized before being saved. When it gets echoed out (and you can read it) the sanitizing will take place. In this case, finding an SQLi vulnerability would mean no damage (XSS wise) to the site.
There are instances, though, where something similar can be used for such purposes. Not that long ago, I remember some .tw website for virus protection software had an SQL vulnerability. The link looked something similar to www.virusprotection.tw/downloads.php?id=10. An attacker was/would be able to edit the database and point the download link to a file of his choosing. So when a user went to download virus protection software, they could be downloading a virus itself.
I think that covers what you're asking...
On a side note, certain DBM's allow for file system access depending on the user privileges the DBM is running under. MySQL, for instance, has the INTO OUTFILE function that can be used to write files to the server.
For instance, SELECT '<?php echo `[removed] /`; ?>' INTO OUTFILE('/var/www/mysite/shell.php')
In a bit of a rush, so hope that helps.