Tuesday, February 6. 2007
There is a very funny posting at the modsecurity blog from yesterday that speaks a bit about the
combination PHP and modsecurity. Basically the entry tries to excuse the fact that most of the modsecurity rules that are in use today to protect against known vulnerabilites can be bypassed easily by simple things like adding spaces infront of the variable name.
It is quite amusing that the author blames the fact that web application firewalls parse the HTTP request in a different way than the installed application/script language (and therefore always contain bypass holes by design) onto the applications and languages. He especially blames PHP because it is so userfriendly when it comes to variable names.
I can understand that Ivan tries to defend his product. But fact is all webapplications/script languages have their own rules how they parse HTTP requests. modsecurity (and most probably other commerical web application firewalls) matches some of these understandings of HTTP partially but it does not match a single language 100% and therefore it will NEVER be secure. It is not feasible to have one parser that works on all languages because there are too many differences between the HTTP parsers.
Oh yeah... And I see no reason to especially blame PHP when a simple trick exists that works with many languages and allows getting a bunch of attacks through all modsecurity rules...