The relatively nascent field of Java web application security has seen an explosion of interest in the past year or so from developers and security software vendors alike. Java open source projects have caught the interest of some these vendors as a means of cause marketing, a marketing technique not often seen in the software world where a commercial enterprise and a non-profit organization work together for mutual benefit. The benefit to the non-profit is that they are in some way making the world a better place. The benefit to the commercial software company is that they make more money.
The Java Open Review project, available at opensource.fortifysoftware.com and sponsored by Fortify, sets out to identify and root out security and quality bugs in popular Java open source projects to help improve the security of Java web applications in general. I have to commend all involved for the attempt and the mission of the project, but was surprised to see the lack of substantiated findings that was the first public release from the project’s efforts. The report is available at: www.fortifysoftware.com/servlet/downloads/user/Java_Open_Source_Report.pdf.
In their review of Hibernate, Struts, Spring and Tomcat, they seemed to find nothing of substance. Instead of continuing on their quest of improving the open source code base and finding real problems, they released what they had, which consisted of three odd conclusions.
Their first conclusion was that “Java is more reliable programming language than C/C++”. This is like announcing that electric light is more reliable than candles.
The second conclusion was that “Developers inadvertently incorporate open source code in an insecure manner”. Should the conclusion have read that “Developers inadvertently incorporate code in an insecure manner”. That’s kind of the root of the problem isn’t it?
Third conclusion: “Most common open source security vulnerability is cross-site scripting”. Not only is this the most basic conclusion of any experienced web application security auditor (that XSS is the most common problem), but the Java Open Review project found these problems in the open source sample applications, not the frameworks themselves. For example, they report that they found 8 “bugs” in Struts and its accompanying sample projects. I analyzed the Struts sample applications with SPI Dynamics web application security tools and found way more than 8 security vulnerabilities of varying severity, including multiple instances of cross-site scripting, information leakage through untrapped exceptions and server error messages, and unvalidated inputs potentially leading to buffer overflows or DOS.
Let’s keep working on improving developer security, especially in the use of open source technologies. But let’s do it in a transparent, collaborative, public-private partnership like DHS, Stanford U. and Coverity have been doing: http://news.com.com/Homeland+Security+helps+secure+open-source+code/2100-1002_3-6025579.html