Exhumed from the dark days of the stupid ages
I just ran across this code while going through a sql injection testing report. The code is probably over 10 years old now yet still hanging around our system because management are code hoarders (but wait, someone might use it!).
<cfquery datasource="#DSN#" name="siteQuery">
select title,body,site_id,link_text,key_words
from pages
where id = #cgi.query_string#
</cfquery>
"Just take whatever is in the browser and shove it right into your sql that runs on every page... what could go wrong?!"
Posted Mar 12, 2014, 7:28 PM UTC
I was horrified by the third character. Cold Fusion? NOOOOOOOOOOOO.