This site is the archived OWASP Foundation Wiki and is no longer accepting Account Requests.
To view the new OWASP Foundation website, please visit https://owasp.org

Difference between revisions of "Category:OWASP Enterprise Security API"

From OWASP
Jump to: navigation, search
(Using the ESAPI)
m (Update Javadoc link on main tab to reference 2.2.0.0 release.)
 
(358 intermediate revisions by 32 users not shown)
Line 1: Line 1:
=OWASP Enterprise Security API (ESAPI) Project=
+
= Home  =
 +
<div style="width:100%;height:160px;border:0,margin:0;overflow: hidden;">[[File:OWASP_Project_Header.jpg|link=]]</div>
  
===What is ESAPI?===
+
{| style="padding: 0;margin:0;margin-top:10px;text-align:left;" |-
The '''ESAPI''' is a free and open collection of all the security methods that a developer needs to build a secure web application. You can just use the interfaces and build your own implementation using your company's infrastructure. Or, you can use the reference implementation as a starting point. In concept, the API is language independent. However, the first deliverables from the project are a Java API and a Java reference implementation.  Efforts to build ESAPI in .NET and PHP are already underway.
+
| valign="top"  style="border-right: 1px dotted gray;padding-right:25px;" |
  
===Why ESAPI?===
+
ESAPI (The OWASP Enterprise Security API) is a free, open source, web application security control library that makes it easier for programmers to write lower-risk applications. The ESAPI libraries are designed to make it easier for programmers to retrofit security into existing applications. The ESAPI libraries also serve as a solid foundation for new development.  
Unfortunately, the available platforms, frameworks, and toolkits (Java EE, Struts, Spring, etc...) simply do not provide enough protection. This leaves developers with responsibility for designing and building security mechanisms. This reinventing the wheel for every application leads to wasted time and massive security holes.
 
  
The cost savings through reduced development time, and the increased security due to using heavily analyzed and carefully designed security methods provide developers with a massive advantage over organizations that are trying to deal with security using existing ad hoc secure coding techniques. This API is designed to automatically take care of many aspects of application security, making these issues invisible to the developers.
+
Allowing for language-specific differences, all OWASP ESAPI versions have the same basic design:
  
===Where did ESAPI come from?===
+
*'''There is a set of security control interfaces.''' They define for example types of parameters that are passed to types of security controls.
The OWASP ESAPI project is led by [[User:Jeff Williams|Jeff Williams]], who serves as the volunteer chair of OWASP and is the CEO of Aspect Security. Jeff is a software developer who has specialized in application security since 1995. The ESAPI is the result of over a decade of code review and penetration testing of critical enterprise applications.  If you'd like to volunteer to help on the project, you can contact him at [email protected].
 
  
More information about the ESAPI can be found in the [http://owasp-esapi-java.googlecode.com/svn/trunk/documentation/OWASP%20ESAPI%20Overview.pptx ESAPI PowerPoint presentation]
+
*'''There is a reference implementation for each security control.''' The logic is not organization‐specific and the logic is not application‐specific. An example: string‐based input validation.
  
==Architecture==
+
*'''There are optionally your own implementations for each security control.''' There may be application logic contained in these classes which may be developed by or for your organization. An example: enterprise authentication.
  
The ESAPI architecture is very simple, just a collection of classes that encapsulate the key security operations most applications need. ESAPI is designed to make it easy to retrofit security into existing applications, as well as providing a solid foundation for new development. New development projects should consider integrating ESAPI into their framework to make even more of the security happen automatically. ESAPI comes with an ESAPI filter that minimizes the changes required to your base application.
+
This project source code is licensed under the [http://en.wikipedia.org/wiki/BSD_license BSD license], which is very permissive and about as close to public domain as is possible. The project documentation is licensed under the [http://creativecommons.org/licenses/by-sa/2.0/ Creative Commons] license. You can use or modify ESAPI however you want, even include it in commercial products.
  
The ESAPI covers most of the key security challenges facing application developers. ESAPI provides the capability for developers to create applications that are protected against almost all of the risks described in the OWASP [[Top Ten]]. Compare this coverage with automated scanning and static analysis tools, and then consider how your time is best spent.
+
The following organizations are a few of the many organizations that are starting to adopt ESAPI to secure their web applications: [http://www.americanexpress.com/ American Express], [http://www.apache.org/ Apache Foundation], [http://www.boozallen.com Booz Allen Hamilton], [http://www.aspectsecurity.com/ Aspect Security], [http://www.coraid.com Coraid], [http://www.thehartford.com/ The Hartford], [http://www.infinitecampus.com Infinite Campus], [http://www.lockheedmartin.com/ Lockheed Martin], [http://cwe.mitre.org/top25/index.html MITRE], [http://enterprise.spawar.navy.mil/ U.S. Navy - SPAWAR], [http://www.worldbank.org/ The World Bank], [http://www.sans.org/top25errors/ SANS Institute].  
  
http://owasp-esapi-java.googlecode.com/svn/trunk/doc/org/owasp/esapi/doc-files/OWASPTopTen.jpg
+
Please let us know how your organization is using OWASP ESAPI. Include your name, organization's name, and brief description of how you are using it. The project co-leads can be reached  [mailto:kevin.w.wall@gmail.com here] and [mailto:xeno6696@gmail.com here].
 +
| valign="top"  style="padding-left:25px;width:300px;border-right: 1px dotted gray;padding-right:25px;" |
  
There are two key parts to the ESAPI:
+
== Let's talk here  ==
* A set of interfaces
 
* A reference implementation
 
  
By using the ESAPI, applications across an organization will be easier to develop, more consistent, and easier to update in a single place. The use of the ESAPI will make it much easier for static analysis tools to verify an application, as the ESAPI calls can be built into the ruleset.
+
[[Image:Asvs-bulb.jpg]]'''ESAPI Communities'''
  
==Download Now==
+
Further development of ESAPI occurs through mailing list discussions and occasional workshops, and suggestions for improvement are welcome. For more information, please subscribe to one of the lists below.
  
This release is the first public release and will undoubtably undergo significant revision over the coming months. We are seeking organizations willing to pilot this ESAPI and work with us to make this library better. Please contact jeff.williams@owasp.org for more information. If you're interested in application security, please join the [http://lists.owasp.org/mailman/listinfo/owasp-esapi OWASP ESAPI mailing list] and help make ESAPI better!
+
*[https://lists.owasp.org/mailman/listinfo/esapi-dev esapi-dev mailing list (this is the main list)]
 +
*[https://lists.owasp.org/mailman/listinfo/esapi-user esapi-user mailing list]
 +
*[https://lists.owasp.org/mailman/listinfo/esapi-php esapi-php mailing list]
 +
*[https://lists.owasp.org/mailman/listinfo/esapi-python esapi-python mailing list]
 +
*[https://lists.owasp.org/mailman/listinfo/owasp-esapi-ruby esapi-ruby mailing list]
 +
*[https://lists.owasp.org/mailman/listinfo/owasp-esapi-swingset esapi-swingset mailing list]
 +
*[http://groups.google.com/group/cfesapi esapi-coldfusion mailing list]
  
Versions (archived source files are also available on the SVN under tags)
+
IRC Chat
  
<table width="100%" valign="top"><tr><th width="50%">JAR Files</th><th>Source Files</th></tr><tr valign="top"><td>
+
If you would rather chat with us about your problem or thoughts - you can join us in our IRC channel using an [http://www.google.com/search?q=irc+client IRC Client] or using FreeNode's [http://webchat.freenode.net WebChat] client.
  
; [http://owasp-esapi-java.googlecode.com/files/owasp-esapi-java-1.3.jar ESAPI v1.3.0 Complete JAR file]
+
*Server: irc.freenode.net
: JAVA 1.4 compatible JAR for ESAPI v1.3.0
+
*Channel: #esapi
  
; [http://owasp-esapi-java.googlecode.com/files/owasp-esapi-java-1.2.1.jar ESAPI v1.2.1 Complete JAR file]
+
== Got developer cycles?  ==
: JAVA 1.4 compatible JAR for ESAPI v1.2.1
 
  
; [http://owasp-esapi-java.googlecode.com/files/owasp-esapi-java-1.1.1.jar ESAPI v1.1.1 Complete JAR file]  
+
[[Image:Asvs-waiting.JPG]]'''ESAPI Coding'''
: JAVA 1.4 compatible JAR for ESAPI v1.1.1
 
  
</td><td>
+
The ESAPI project is always on the lookout for volunteers who are interested in contributing developer cycles.
 +
 +
*ESAPI for other languages developer onboarding instructions -- coming soon!
  
; [http://owasp-esapi-java.googlecode.com/files/owasp-esapi-java-src-1.3.zip ESAPI v1.3.0 Source archive]
+
== Project Sponsors ==
: Source files for ESAPI v1.3.0
 
  
; [http://owasp-esapi-java.googlecode.com/files/owasp-esapi-java-src-1.2.1.zip ESAPI v1.2.1 Source archive]
+
The ESAPI project is sponsored by {{MemberLinks|link=http://www.aspectsecurity.com|logo=Aspect_logo_owasp.jpg}}
: Source files for ESAPI 1.2.1
 
  
; [http://owasp-esapi-java.googlecode.com/files/owasp-esapi-java-src-1.1.1.zip ESAPI v1.1.1 Source archive]
+
|}
: Source files for ESAPI 1.1.1
 
  
</td></tr></table>
+
= Downloads  =
 +
<div style="width:100%;height:160px;border:0,margin:0;overflow: hidden;">[[File:OWASP_Project_Header.jpg|2400x160px|link=]]</div>
  
===Resources===
+
{| style="padding: 0;margin:0;margin-top:10px;text-align:left;" |-
* Information regarding the ESAPI SVN can be found at [http://code.google.com/p/owasp-esapi-java/ the ESAPI Google Code repository].
+
| valign="top"  style="border-right: 1px dotted gray;padding-right:25px;" |
  
* If you have any problems with the ESAPI, please report them to [http://code.google.com/p/owasp-esapi-java/issues/list the issues section].
+
[[Image:Asvs-step1.jpg]]'''1. About ESAPI'''
  
* The ESAPI [http://owasp-esapi-java.googlecode.com/svn/trunk/doc/index.html Javadocs] are located [http://owasp-esapi-java.googlecode.com/svn/trunk/doc/index.html here].
+
*Data sheet([http://www.owasp.org/images/8/81/Esapi-datasheet.pdf PDF],[http://www.owasp.org/images/3/32/Esapi-datasheet.doc Word])
 +
*Project presentation ([http://owasp-esapi-java.googlecode.com/files/OWASP%20ESAPI.ppt PowerPoint])
 +
*Video presentation ([http://www.youtube.com/watch?v=QAPD1jPn04g YouTube])
  
* For more information about the ESAPI, please view the [http://owasp-esapi-java.googlecode.com/svn/trunk/documentation/OWASP%20ESAPI%20Overview.pptx ESAPI PowerPoint presentation].
+
| valign="top"  style="padding-left:25px;width:33%;border-right: 1px dotted gray;padding-right:25px;" |
  
* If you are generating your own Javadocs for the ESAPI project, information regarding generation can be found [https://www.owasp.org/index.php/ESAPI_Javadocs here].
+
[[Image:Asvs-step2.jpg]]'''2. Get ESAPI'''
  
==Changing/Building/Using the ESAPI==
+
*[https://search.maven.org/#search|ga|1|esapi ESAPI for Java Downloads (binaries)]
If you would like to work with the ESAPI source code, or build the project, please [[ESAPI-Building | see here]].
+
*[https://github.com/ESAPI/esapi-java-legacy ESAPI for Java (source)]<br>
 +
*[https://github.com/ESAPI/owasp-esapi-js ESAPI for Javascript]<br>
  
===Using the ESAPI===
+
'''No longer supported versions'''. If you absolutely need to download one of those, it is suggested that you search the [https://archive.org/ Internet Archive Wayback Machine] or [https://github.com/ GitHub] for someone who may have mirrored it:
If you want to see what the ESAPI is all about, and want to use the built-in implementations,
 
* Download the latest version of the ESAPI JAR from above.
 
* Add the ESAPI JAR to your project's build path.
 
* At the moment, ESAPI is set up for Java 1.4.2.  If you would like to use the ESAPI reference implementations with a Java 1.6 application, there are some lines of code that need to be uncommented.  Please see [https://www.owasp.org/index.php/ESAPI-Building here] for information on editing the ESAPI.  More information regarding this topic will be added to the Wiki soon.  For now, please contact [http://www.owasp.org/index.php/User:Jeff_Williams Jeff Williams] if you plan to use ESAPI with a Java 1.6 project.
 
* As stated above, ESAPI requires Java 1.4.2.  Be sure to set your workspace settings regarding this.
 
* Use the [http://owasp-esapi-java.googlecode.com/svn/trunk/doc/index.html ESAPI's Javadocs ] to take advantage of all the built-in functions of the ESAPI.
 
  
===Running Demo App===
+
* ESAPI for .NET
The ESAPI Demo application has been named ''The ESAPI Swingset''.  More information about Swingset is [[ESAPI_Swingset | available here]].
+
* ESAPI for Classic ASP
 +
* ESAPI for PHP
 +
* ESAPI for ColdFusion & CFML
 +
* ESAPI for Python
  
==Project Sponsors==
 
  
The OWASP ESAPI project is sponsored by
+
| valign="top"  style="padding-left:25px;width:33%;" |
[http://www.aspectsecurity.com https://www.owasp.org/images/d/d1/Aspect_logo.gif]
 
  
==Licensing==
+
[[Image:Asvs-step3.jpg]]'''3. Learn ESAPI'''
This project is dual-licensed under GPL and BSD. Pick whichever one fits your corporate policy...[JFM]
 
  
[[Category:OWASP Download]]
+
*ESAPI design patterns (not language-specific): [http://www.owasp.org/images/8/82/Esapi-design-patterns.pdf (PDF], [http://www.owasp.org/index.php/File:Esapi-design-patterns.doc Word], [http://www.owasp.org/images/8/87/Esapi-design-patterns.ppt PPT)]  
[[Category:OWASP Project]]
+
*The [[ESAPI Swingset|ESAPI Swingset]] sample application demonstrates how to leverage ESAPI to protect a web application.
 +
*LAMP should be spelled LAMPE ([http://www.owasp.org/images/a/ac/LAMP_Should_be_Spelled_LAMPE.pdf PDF])
 +
*ESAPI for Java interface documentation ([http://www.javadoc.io/doc/org.owasp.esapi/esapi/2.2.0.0 JavaDocs])
  
__NOTOC__
+
|}
 +
 
 +
= What I did with ESAPI  =
 +
<div style="width:100%;height:160px;border:0,margin:0;overflow: hidden;">[[File:OWASP_Project_Header.jpg|link=]]</div>
 +
 
 +
*I used ESAPI for Java with Google AppEngine. I used it for simple validation and encoding. --[mailto:[email protected] Jeff]
 +
 
 +
*I used ESAPI for PHP with a custom web 2.0 corporate knowledge management application, made up of many open source and commercial applications integrated to work together. I added an organization- and application-specific "Adapter" control to wrap calls to the other ESAPI controls. --[mailto:[email protected] Mike]
 +
 
 +
*I used ESAPI for Java’s "Logger" control to make it easier for a US Government customer to meet C&amp;A requirements. --[mailto:[email protected] Dave]
 +
 
 +
*I used ESAPI for Java to build a low risk web application that was over 250,000+ lines of code in size. --[mailto:[email protected] Jim]
 +
 
 +
*I used ESAPI for Java's "Authenticator" to replace a spaghetti-like mechanism in a legacy financial services web application. In hindsight I should have used the application-specific "Adapter" pattern mentioned by Mike above. The organization also uses the ESAPI Encryptor as an interface to a hardware security module. --[mailto:[email protected] Roman]
 +
 
 +
*I use ESAPI to be our security package for all our product, this way we can set one standard for all products. --[mailto:[email protected] Yair]
 +
 
 +
*I use ESAPI for Java to educate developers about application security principals at several of the world’s largest organizations. --[mailto:[email protected] Jim]<br>
 +
 
 +
= Should I use ESAPI?  =
 +
<div style="width:100%;height:160px;border:0,margin:0;overflow: hidden;">[[File:OWASP_Project_Header.jpg|link=]]</div>
 +
[NOTE: The heretical opinions on this ESAPI tab are 100% my own and do not necessarily reflect the rest of other ESAPI contributors or the OWASP staff, leadership, community. --kevin wall]
 +
 
 +
Or, specifically, "Should I use ESAPI for Java?" since that's the only one run by OWASP that still shows any semblance of life.
 +
Maintenance activities is down, way down in fact of its peak development activities. Some of us are still trying and haven't given up and volunteers are still welcome. But without active contributors, projects make slow progress.
 +
 
 +
The first question to ask is, are you already using ESAPI in your project, and if so, do you have a lot vested in it? If so, then the answer to "Should I use ESAPI?" probably is "yes". The second question you should ask, if I'm using it, why am I not contributing to it in some manner? But we won't go there.
 +
 
 +
If you are starting out on a new project or trying for the first time to secure an existing project, then _before_ you consider ESAPI, you should consider these possible alternatives:
 +
* Output encoding: [https://www.owasp.org/index.php/OWASP_Java_Encoder_Project OWASP Java Encoder Project]
 +
* General HTML sanitization: [https://www.owasp.org/index.php/OWASP_Java_HTML_Sanitizer_Project OWASP Java HTML Sanitizer]
 +
* Validation: [http://beanvalidation.org/ JSR-303/JSR-349 Bean Validation]
 +
*Strong cryptography: [https://github.com/google/tink Google Tink], [https://github.com/google/keyczar Keyczar]
 +
* Authentication / authorization: [https://shiro.apache.org/ Apache Shiro]
 +
* CSRF protection: [https://www.owasp.org/index.php/Category:OWASP_CSRFGuard_Project OWASP CSRFGuard Project] or [https://www.owasp.org/index.php/CSRFProtector_Project OWASP CSRFProtector Project]
 +
 
 +
Note that this is not to suggest that ESAPI is dead, but rather to acknowledge the fact that it isn't being as well-maintained as most F500 companies would like for their enterprise software. There may be alternatives, such as companies that you can purchase ESAPI support from. Those are not being considered here for various reasons, not the least of which is to remain vendor neutral.  Rather, instead these recommendations should be taken as possible alternatives to secure your application. It is not a perfect world that we live in, but I would be remiss as an appsec guy if I were to plug ESAPI over other good security solutions simply because of my contributions to / involvement with ESAPI. I think that ESAPI has it's place and I will do my best to maintain it, but not to the exclusion of my family or day job. If you would like to volunteer to help, you know where to find me.
 +
 
 +
-[mailto:[email protected] kevin wall]
 +
 
 +
= Glossary  =
 +
<div style="width:100%;height:160px;border:0,margin:0;overflow: hidden;">[[File:OWASP_Project_Header.jpg|link=]]</div>
 +
[[Image:Asvs-letters.jpg]]'''ESAPI Terminology'''
 +
 
 +
*'''adapter''' - There are optionally your own implementations for each security control. There may be application logic contained in these classes which may be developed by or for your organization. The logic may be organization-specific and/or application-specific. There may be proprietary information or logic contained in these classes which may be developed by or for your organization.
 +
*'''built-in singleton design pattern''' - The "built-in" singleton design pattern refers to the replacement of security control reference implementations with your own implementations. ESAPI interfaces are otherwise left intact.
 +
*'''codec''' - ESAPI encoder/decoder reference implementations.
 +
*'''core''' - The ESAPI interfaces and reference implementations that are not intended to be replaced with enterprise-specific versions are called the ESAPI Core.
 +
*'''exception''' - ESAPI exception reference implementations.
 +
*'''extended factory design pattern''' - The "extended" factory design pattern refers to the addition of a new security control interface and corresponding implementation, which in turn calls ESAPI security control reference implementations and/or security control reference implementations that were replaced with your own implementations. The ESAPI locator class would be called in order to retrieve a singleton instance of your new security control, which in turn would call ESAPI security control reference implementations and/or security control reference implementations that were replaced with your own implementations.
 +
*'''extended singleton design pattern''' - The "extended" singleton pattern refers to the replacement of security control reference implementations with your own implementations and the addition/modification/subtraction of corresponding security control interfaces.
 +
*'''ES-enable (or ESAPI-enable)''' - Just as web applications and web services can be Public Key Infrastructure (PKI) enabled (PK-enabled) to perform for example certificate-based authentication, applications and services can be OWASP ESAPI-enabled (ES-enabled) to enable applications and services to protect themselves from attackers.
 +
*'''filter''' - In ESAPI for Java, there is additionally an HTTP filter that can be called separately from the other controls.
 +
*'''interfaces''' - There is a set of security control interfaces. There is no application logic contained in these interfaces. They define for example types of parameters that are passed to types of security controls. There is no proprietary information or logic contained in these interfaces.
 +
*'''locator''' - The ESAPI security control interfaces include an "ESAPI" class that is commonly referred to as a "locator" class. The ESAPI locator class is called in order to retrieve singleton instances of individual security controls, which are then called in order to perform security checks (such as performing an access control check) or that result in security effects (such as generating an audit record).
 +
*'''reference implementation''' - There is a reference implementation for each security control. There is application logic contained in these classes, i.e. contained in these interface implementations. However, the logic is not organization-specific and the logic is not application-specific. There is no proprietary information or logic contained in these reference implementation classes.
 +
*'''Web Application Firewall (WAF)''' - In ESAPI for Java, there is additionally a Web Application Firewall (WAF) that can be called separately from the other controls.
 +
 
 +
<br>
 +
 
 +
= Java EE  =
 +
<div style="width:100%;height:160px;border:0,margin:0;overflow: hidden;">[[File:OWASP_Project_Header.jpg|link=]]</div>
 +
 
 +
{{:GPC_Project_Details/OWASP_Enterprise_Security_API_Java_EE_Version | OWASP Project Identification Tab}}
 +
 
 +
 
 +
= Project Details  =
 +
<div style="width:100%;height:160px;border:0,margin:0;overflow: hidden;">[[File:OWASP_Project_Header.jpg|link=]]</div>
 +
{{:GPC_Project_Details/OWASP_Enterprise_Security_API | OWASP Project Identification Tab}}
 +
 
 +
__NOTOC__ <headertabs /> <br>
 +
 
 +
{{OWASP Builders}}
 +
[[Category:Popular]]
 +
[[Category:SAMM-SA-3]]

Latest revision as of 17:39, 28 June 2019

OWASP Project Header.jpg

ESAPI (The OWASP Enterprise Security API) is a free, open source, web application security control library that makes it easier for programmers to write lower-risk applications. The ESAPI libraries are designed to make it easier for programmers to retrofit security into existing applications. The ESAPI libraries also serve as a solid foundation for new development.

Allowing for language-specific differences, all OWASP ESAPI versions have the same basic design:

  • There is a set of security control interfaces. They define for example types of parameters that are passed to types of security controls.
  • There is a reference implementation for each security control. The logic is not organization‐specific and the logic is not application‐specific. An example: string‐based input validation.
  • There are optionally your own implementations for each security control. There may be application logic contained in these classes which may be developed by or for your organization. An example: enterprise authentication.

This project source code is licensed under the BSD license, which is very permissive and about as close to public domain as is possible. The project documentation is licensed under the Creative Commons license. You can use or modify ESAPI however you want, even include it in commercial products.

The following organizations are a few of the many organizations that are starting to adopt ESAPI to secure their web applications: American Express, Apache Foundation, Booz Allen Hamilton, Aspect Security, Coraid, The Hartford, Infinite Campus, Lockheed Martin, MITRE, U.S. Navy - SPAWAR, The World Bank, SANS Institute.

Please let us know how your organization is using OWASP ESAPI. Include your name, organization's name, and brief description of how you are using it. The project co-leads can be reached here and here.

Let's talk here

Asvs-bulb.jpgESAPI Communities

Further development of ESAPI occurs through mailing list discussions and occasional workshops, and suggestions for improvement are welcome. For more information, please subscribe to one of the lists below.

IRC Chat

If you would rather chat with us about your problem or thoughts - you can join us in our IRC channel using an IRC Client or using FreeNode's WebChat client.

  • Server: irc.freenode.net
  • Channel: #esapi

Got developer cycles?

Asvs-waiting.JPGESAPI Coding

The ESAPI project is always on the lookout for volunteers who are interested in contributing developer cycles.

  • ESAPI for other languages developer onboarding instructions -- coming soon!

Project Sponsors

The ESAPI project is sponsored by Aspect_logo_owasp.jpg       

OWASP Project Header.jpg

Asvs-step1.jpg1. About ESAPI

Asvs-step2.jpg2. Get ESAPI

No longer supported versions. If you absolutely need to download one of those, it is suggested that you search the Internet Archive Wayback Machine or GitHub for someone who may have mirrored it:

  • ESAPI for .NET
  • ESAPI for Classic ASP
  • ESAPI for PHP
  • ESAPI for ColdFusion & CFML
  • ESAPI for Python


Asvs-step3.jpg3. Learn ESAPI

  • ESAPI design patterns (not language-specific): (PDF, Word, PPT)
  • The ESAPI Swingset sample application demonstrates how to leverage ESAPI to protect a web application.
  • LAMP should be spelled LAMPE (PDF)
  • ESAPI for Java interface documentation (JavaDocs)
OWASP Project Header.jpg
  • I used ESAPI for Java with Google AppEngine. I used it for simple validation and encoding. --Jeff
  • I used ESAPI for PHP with a custom web 2.0 corporate knowledge management application, made up of many open source and commercial applications integrated to work together. I added an organization- and application-specific "Adapter" control to wrap calls to the other ESAPI controls. --Mike
  • I used ESAPI for Java’s "Logger" control to make it easier for a US Government customer to meet C&A requirements. --Dave
  • I used ESAPI for Java to build a low risk web application that was over 250,000+ lines of code in size. --Jim
  • I used ESAPI for Java's "Authenticator" to replace a spaghetti-like mechanism in a legacy financial services web application. In hindsight I should have used the application-specific "Adapter" pattern mentioned by Mike above. The organization also uses the ESAPI Encryptor as an interface to a hardware security module. --Roman
  • I use ESAPI to be our security package for all our product, this way we can set one standard for all products. --Yair
  • I use ESAPI for Java to educate developers about application security principals at several of the world’s largest organizations. --Jim
OWASP Project Header.jpg

[NOTE: The heretical opinions on this ESAPI tab are 100% my own and do not necessarily reflect the rest of other ESAPI contributors or the OWASP staff, leadership, community. --kevin wall]

Or, specifically, "Should I use ESAPI for Java?" since that's the only one run by OWASP that still shows any semblance of life. Maintenance activities is down, way down in fact of its peak development activities. Some of us are still trying and haven't given up and volunteers are still welcome. But without active contributors, projects make slow progress.

The first question to ask is, are you already using ESAPI in your project, and if so, do you have a lot vested in it? If so, then the answer to "Should I use ESAPI?" probably is "yes". The second question you should ask, if I'm using it, why am I not contributing to it in some manner? But we won't go there.

If you are starting out on a new project or trying for the first time to secure an existing project, then _before_ you consider ESAPI, you should consider these possible alternatives:

Note that this is not to suggest that ESAPI is dead, but rather to acknowledge the fact that it isn't being as well-maintained as most F500 companies would like for their enterprise software. There may be alternatives, such as companies that you can purchase ESAPI support from. Those are not being considered here for various reasons, not the least of which is to remain vendor neutral. Rather, instead these recommendations should be taken as possible alternatives to secure your application. It is not a perfect world that we live in, but I would be remiss as an appsec guy if I were to plug ESAPI over other good security solutions simply because of my contributions to / involvement with ESAPI. I think that ESAPI has it's place and I will do my best to maintain it, but not to the exclusion of my family or day job. If you would like to volunteer to help, you know where to find me.

-kevin wall

OWASP Project Header.jpg

Asvs-letters.jpgESAPI Terminology

  • adapter - There are optionally your own implementations for each security control. There may be application logic contained in these classes which may be developed by or for your organization. The logic may be organization-specific and/or application-specific. There may be proprietary information or logic contained in these classes which may be developed by or for your organization.
  • built-in singleton design pattern - The "built-in" singleton design pattern refers to the replacement of security control reference implementations with your own implementations. ESAPI interfaces are otherwise left intact.
  • codec - ESAPI encoder/decoder reference implementations.
  • core - The ESAPI interfaces and reference implementations that are not intended to be replaced with enterprise-specific versions are called the ESAPI Core.
  • exception - ESAPI exception reference implementations.
  • extended factory design pattern - The "extended" factory design pattern refers to the addition of a new security control interface and corresponding implementation, which in turn calls ESAPI security control reference implementations and/or security control reference implementations that were replaced with your own implementations. The ESAPI locator class would be called in order to retrieve a singleton instance of your new security control, which in turn would call ESAPI security control reference implementations and/or security control reference implementations that were replaced with your own implementations.
  • extended singleton design pattern - The "extended" singleton pattern refers to the replacement of security control reference implementations with your own implementations and the addition/modification/subtraction of corresponding security control interfaces.
  • ES-enable (or ESAPI-enable) - Just as web applications and web services can be Public Key Infrastructure (PKI) enabled (PK-enabled) to perform for example certificate-based authentication, applications and services can be OWASP ESAPI-enabled (ES-enabled) to enable applications and services to protect themselves from attackers.
  • filter - In ESAPI for Java, there is additionally an HTTP filter that can be called separately from the other controls.
  • interfaces - There is a set of security control interfaces. There is no application logic contained in these interfaces. They define for example types of parameters that are passed to types of security controls. There is no proprietary information or logic contained in these interfaces.
  • locator - The ESAPI security control interfaces include an "ESAPI" class that is commonly referred to as a "locator" class. The ESAPI locator class is called in order to retrieve singleton instances of individual security controls, which are then called in order to perform security checks (such as performing an access control check) or that result in security effects (such as generating an audit record).
  • reference implementation - There is a reference implementation for each security control. There is application logic contained in these classes, i.e. contained in these interface implementations. However, the logic is not organization-specific and the logic is not application-specific. There is no proprietary information or logic contained in these reference implementation classes.
  • Web Application Firewall (WAF) - In ESAPI for Java, there is additionally a Web Application Firewall (WAF) that can be called separately from the other controls.


OWASP Project Header.jpg


PROJECT INFO
What does this OWASP project offer you?
RELEASE(S) INFO
What does this OWASP project release offer you?
what is this project?
OWASP ESAPI for Java EE

Purpose: This is the Java EE language version of OWASP ESAPI. The ESAPI for Java EE is the baseline ESAPI design.

License: BSD license

who is working on this project?
Project Leader: Kevin Wall & Matt Seil @

Project Maintainer: ESAPI-Dev mailing list @

Project Contributor(s):

how can you learn more?
Project Pamphlet: N/A

3x slide Project Presentation: N/A

Mailing list: Subscribe or read the archives

Project Roadmap: N/A

Main links:

Project Health: Yellow button.JPG Not Reviewed (Provisional)
To be reviewed under Assessment Criteria v2.0

Key Contacts
  • Contact Kevin Wall & Matt Seil @ to contribute, review or sponsor this project
  • Contact the GPC to report a problem or concern about this project or to update information.
current release
2.2.0.0 - June 25, 2019 - (download)

Release Leader: N/A

Release details: N/A :

Rating: Yellow button.JPG Not Reviewed
To be reviewed under Assessment Criteria v2.0



OWASP Project Header.jpg
PROJECT INFO
What does this OWASP project offer you?
what is this project?
OWASP Enterprise Security API

Purpose: ESAPI (The OWASP Enterprise Security API) is a free, open source, web application security control library that makes it easier for programmers to write lower-risk applications. The ESAPI libraries are designed to make it easier for programmers to retrofit security into existing applications. The ESAPI libraries also serve as a solid foundation for new development. Allowing for language-specific differences, all OWASP ESAPI versions have the same basic design:

  • There is a set of security control interfaces. They define for example types of parameters that are passed to types of security controls.
  • There is a reference implementation for each security control. The logic is not organization‐specific and the logic is not application‐specific. An example: string‐based input validation.
  • There are optionally your own implementations for each security control. There may be application logic contained in these classes which may be developed by or for your organization. An example: enterprise authentication.

License: BSD license

who is working on this project?
Project Leader: Kevin W. Wall and Matt Seil @

Project Maintainer:

Project Contributor(s):

  • Jeremiah J. Stacey
  • Chris Schmidt @
  • Jeff Williams
  • Dave Wichers
  • John Steven
how can you learn more?
Project Pamphlet: View

3x slide Project Presentation: View

Mailing list: Subscribe or read the archives

Project Roadmap: N/A

Main links:

Project Health: Yellow button.JPG Not Reviewed (Provisional)
To be reviewed under Assessment Criteria v2.0

Key Contacts
  • Contact Kevin W. Wall and Matt Seil @ to contribute, review or sponsor this project
  • Contact the GPC to report a problem or concern about this project or to update information.

This project is part of the OWASP Builders community.
Feel free to browse other projects within the Defenders, Builders, and Breakers communities.