Difference between revisions of "Source Code Analysis Tools"

From OWASP
Jump to: navigation, search
(Open Source or Free Tools Of This Type: removed reference to PreFix - only available to the MS Windows developer team)
(updated links, improved formatting)
Line 3: Line 3:
 
Some tools are starting to move into the IDE. For the types of problems that can be detected during the software development phase itself, this is a powerful phase within the development lifecycle to employ such tools, as it provides immediate feedback to the developer on issues they might be introducing into the code during code development itself. This immediate feedback is very useful as compared to finding vulnerabilities much later in the development cycle.
 
Some tools are starting to move into the IDE. For the types of problems that can be detected during the software development phase itself, this is a powerful phase within the development lifecycle to employ such tools, as it provides immediate feedback to the developer on issues they might be introducing into the code during code development itself. This immediate feedback is very useful as compared to finding vulnerabilities much later in the development cycle.
  
==Strengths and Weaknesses==
+
==Strengths and Weaknesses of such tools==
  
Strengths:
+
=== Strengths ===
 
* Scales Well (Can be run on lots of software, and can be repeatedly (like in nightly builds))
 
* Scales Well (Can be run on lots of software, and can be repeatedly (like in nightly builds))
 
* For things that such tools can automatically find with high confidence, such as buffer overflows, SQL Injection Flaws, etc. they are great.
 
* For things that such tools can automatically find with high confidence, such as buffer overflows, SQL Injection Flaws, etc. they are great.
  
Weaknesses:
+
=== Weaknesses ===
 
* Many types of security vulnerabilities are very difficult to find automatically, such as authentication problems, access control issues, insecure use of cryptography, etc. The current state of the art only allows such tools to automatically find a relatively small percentage of application security flaws. Tools of this type are getting better, however.
 
* Many types of security vulnerabilities are very difficult to find automatically, such as authentication problems, access control issues, insecure use of cryptography, etc. The current state of the art only allows such tools to automatically find a relatively small percentage of application security flaws. Tools of this type are getting better, however.
 
* High numbers of false positives.
 
* High numbers of false positives.
Line 27: Line 27:
 
==OWASP Tools Of This Type==
 
==OWASP Tools Of This Type==
  
* [http://www.owasp.org/index.php/Category:OWASP_LAPSE_Project OWASP_LAPSE_Project]
+
* [[Category:OWASP_LAPSE_Project | OWASP LAPSE Project]]
  
 
==Open Source or Free Tools Of This Type==
 
==Open Source or Free Tools Of This Type==
  
* Microsoft - [[FxCop]]
+
* [[FxCop]] (Microsoft)
* Microsoft - PreFast
+
* PreFast (Microsoft)
* [http://www.securitycompass.com/swaat.html SWAAT - Simplistic Beta Tool - Languages: Java, JSP, ASP .Net, and PHP]
+
* [http://www.securitycompass.com/inner_swaat.shtml SWAAT] - Simplistic Beta Tool - Languages: Java, JSP, ASP .Net, and PHP
* [http://www.securesoftware.com/resources/download_rats.html Secure Software - RATS - Scans C, C++, Perl, PHP and Python source code for security problems like buffer overflows and TOCTOU (Time Of Check, Time Of Use) race conditions]
+
* [http://www.securesoftware.com/resources/download_rats.html RATS] (Secure Software) - Scans C, C++, Perl, PHP and Python source code for security problems like buffer overflows and TOCTOU (Time Of Check, Time Of Use) race conditions
  
 
==Commercial Tools from OWASP Members Of This Type==
 
==Commercial Tools from OWASP Members Of This Type==
  
These vendors have decided to support OWASP by becoming [[Membership|members]]. OWASP appreciates the support from these organizations, but cannnot endorse any commercial products or services.
+
These vendors have decided to support OWASP by becoming [[Membership|members]]. OWASP appreciates the support from these organizations, but cannot endorse any commercial products or services.
  
* [http://www.armorize.com/corpweb/en/products/codesecure Armorize Technologies - Static Source Code Analysis with CodeSecure™]
+
* [http://www.armorize.com/corpweb/en/products/codesecure Static Source Code Analysis with CodeSecure™] (Armorize Technologies)
* [http://www.fortifysoftware.com/products/sca.jsp Fortify - Source Code Analysis]
+
* [http://www.fortifysoftware.com/products/sca.jsp Source Code Analysis] (Fortify)
* [http://www.ouncelabs.com/ Ounce Labs - Ounce]
+
* [http://www.ouncelabs.com/ Ounce] (Ounce Labs)
  
 
==Other Well Known Commercial Tools Of This Type==
 
==Other Well Known Commercial Tools Of This Type==
  
* [http://www.coverity.com/products/prevent.html Coverity - Prevent]
+
* [http://www.coverity.com/products/prevent.html Prevent] (Coverity)
* [http://www.klocwork.com/products/klocworkk7.asp KlocWork - K7]
+
* [http://www.klocwork.com/products/klocworkk7.asp K7] (KlocWork)
  
 
==More Info==
 
==More Info==
  
* add comments from: http://lists.owasp.org/pipermail/owasp-dotnet/2006-August/000002.html
+
* TODO: add comments from: http://lists.owasp.org/pipermail/owasp-dotnet/2006-August/000002.html
* http://www.owasp.org/index.php/Appendix_A:_Testing_Tools
+
* [[Appendix_A:_Testing_Tools | Appendix A: Testing Tools]]
* NIST's list of Source Code Security Analysis Tools - http://samate.nist.gov/index.php/Source_Code_Security_Analyzers
+
* [http://samate.nist.gov/index.php/Source_Code_Security_Analyzers NIST's list of Source Code Security Analysis Tools]
  
 
[[Category:OWASP .NET Project]]
 
[[Category:OWASP .NET Project]]

Revision as of 22:54, 31 August 2008

Source Code Analysis tools are designed to analyze source code and/or compiled version of code in order to help find security flaws. Ideally, such tools would automatically find security flaws with a high degree of confidence that what is found is indeed a flaw. However, this is beyond the state of the art for many types of application security flaws. Thus, such tools frequently serve as aids for an analyst to help them zero in on security relevant portions of code so they can find flaws more efficiently, rather than a tool that simply finds flaws automatically.

Some tools are starting to move into the IDE. For the types of problems that can be detected during the software development phase itself, this is a powerful phase within the development lifecycle to employ such tools, as it provides immediate feedback to the developer on issues they might be introducing into the code during code development itself. This immediate feedback is very useful as compared to finding vulnerabilities much later in the development cycle.

Strengths and Weaknesses of such tools

Strengths

  • Scales Well (Can be run on lots of software, and can be repeatedly (like in nightly builds))
  • For things that such tools can automatically find with high confidence, such as buffer overflows, SQL Injection Flaws, etc. they are great.

Weaknesses

  • Many types of security vulnerabilities are very difficult to find automatically, such as authentication problems, access control issues, insecure use of cryptography, etc. The current state of the art only allows such tools to automatically find a relatively small percentage of application security flaws. Tools of this type are getting better, however.
  • High numbers of false positives.
  • Frequently can't find configuration issues, since they are not represented in the code.
  • Difficult to 'prove' that an identified security issue is an actual vulnerability.
  • Many of these tools have difficulty analyzing code that can't be compiled. Analysts frequently can't compile code because they don't have the right libraries, all the compilation instructions, all the code, etc.

Important Selection Criteria

  • Requirement: Must support your language, but not usually a key factor once it does.
  • Types of Vulnerabilities it can detect (Out of the OWASP Top Ten?) (plus more?)
  • Does it require a fully buildable set of source?
  • Can it run against binaries instead of source?
  • Can it be integrated into the developer's IDE?

OWASP Tools Of This Type

Open Source or Free Tools Of This Type

  • FxCop (Microsoft)
  • PreFast (Microsoft)
  • SWAAT - Simplistic Beta Tool - Languages: Java, JSP, ASP .Net, and PHP
  • RATS (Secure Software) - Scans C, C++, Perl, PHP and Python source code for security problems like buffer overflows and TOCTOU (Time Of Check, Time Of Use) race conditions

Commercial Tools from OWASP Members Of This Type

These vendors have decided to support OWASP by becoming members. OWASP appreciates the support from these organizations, but cannot endorse any commercial products or services.

Other Well Known Commercial Tools Of This Type

More Info