Joined: Apr 06, 2006 Posts: 2415 Location: Iowa, USA
Posted:
Tue Feb 06, 2007 6:28 pm
I got a genuine UNION attack today, but sentinel caught it.
This was directed at the Web_Links module.
While examining the code (Nuke 7.9 patched) to see what he was trying to do, I noticed that there are several cases where the $lid variable is not sanitized before use. See the function viewlinkeditorial() for example. It makes a SQL query with an unsanitized $lid near the top of the function, then sanitizes it, and does some more queries with it. That first query is vulnerable.
I fixed it by finding the switch($l_op) at the bottom of the file. Right before the switch I added a
$lid = intval($lid);
After looking over the code it doesn't look like his attack would have worked on my Nuke anyway; his column count didn't match for the UNION to succeed.
I am looking forward to RavenNuke 2.10...
(As an aside, there are lots of places in the functions where they do this: $lid = intval(trim($lid));...why the trim()? Doesn't seem necessary to me.)
More aside:
This was probably the 2nd or 3rd time that I've been attacked that I know of. I did a whois on the IP and traced it to some Chicago datacenter. I emailed the abuse account about it. He said there wasn't much he could do as they were using a proxy. He might be able to go through his logs but he didn't sound to interested in doing that. Maybe I'm just new to this, but I find this kind of thing really unsettling. Makes you question your faith in humanity when people do crap like this.
Joined: Aug 29, 2004 Posts: 9136 Location: Arizona
Posted:
Wed Feb 07, 2007 5:37 pm
I'll be honest right up front that the following may or may not apply to 7.9. Since I do not use that version, I don't know. But, in 7.6 (RavenNuke 2.02.02 and below) there was another issue where an add could occur even though the "anonymous" posting is turned off. I ended up changing the "Add" function as follows:
Joined: Aug 29, 2004 Posts: 9136 Location: Arizona
Posted:
Thu Feb 08, 2007 6:47 pm
Quote:
I know some other comment parts also had this problem
Uh, oh, I don't recall seeing anything there. If you know what you are looking for, do you mind taking a quick look at the code? Much ablidged kind Sir!
View next topic View previous topic
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum