tag | 7754b7e484c33e953077c3532b5330840d146d96 | |
---|---|---|
tagger | The Android Open Source Project <initial-contribution@android.com> | Tue Jan 30 14:48:18 2024 -0800 |
object | 775a041404ca82339ff7df4b1daa7375b6cdc0d0 |
Platform Tools Release 34.0.5 (10900879)
commit | 775a041404ca82339ff7df4b1daa7375b6cdc0d0 | [log] [tgz] |
---|---|---|
author | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | Wed Jun 28 13:29:33 2023 +0000 |
committer | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | Wed Jun 28 13:29:33 2023 +0000 |
tree | dffefd0374f7ed3358f3a252c2e2aafba60b76be | |
parent | d86fa4e886eda62c4718b24d0feff83868c72fb8 [diff] | |
parent | 2c2c8105b67698b5a2df3c1cd79ec62f3388af60 [diff] |
Snap for 10399941 from 2c2c8105b67698b5a2df3c1cd79ec62f3388af60 to sdk-release Change-Id: Id4c900698f8b26442798f82f62f47c080d42f0b5
Contextual Output Encoding is a computer programming technique necessary to stop Cross-Site Scripting. This project is a Java 1.5+ simple-to-use drop-in high-performance encoder class with little baggage.
For more detailed documentation on the OWASP Javca Encoder please visit https://owasp.org/www-project-java-encoder/.
You can download a JAR from Maven Central.
JSP tags and EL functions are available in the encoder-jsp, also available in Central.
The jars are also available in Maven:
<dependency> <groupId>org.owasp.encoder</groupId> <artifactId>encoder</artifactId> <version>1.2.3</version> </dependency> <dependency> <groupId>org.owasp.encoder</groupId> <artifactId>encoder-jsp</artifactId> <version>1.2.3</version> </dependency>
The OWASP Java Encoder library is intended for quick contextual encoding with very little overhead, either in performance or usage. To get started, simply add the encoder-1.2.3.jar, import org.owasp.encoder.Encode and start using.
Example usage:
PrintWriter out = ....; out.println("<textarea>"+Encode.forHtml(userData)+"</textarea>");
Please look at the javadoc for Encode to see the variety of contexts for which you can encode.
Happy Encoding!
The team is happy to announce that version 1.2.3 has been released!
The team is happy to announce that version 1.2.2 has been released!
The team is happy to announce that version 1.2.1 has been released!
OWASP Java Encoder has been moved to GitHub. Version 1.2 was also released!
Please visit https://www.owasp.org/index.php/OWASP_Java_Encoder_Project#tab=Use_the_Java_Encoder_Project to see detailed documentation and examples on each API use!
We're happy to announce that version 1.1.1 has been released. Along with a important bug fix, we added ESAPI integration to replace the legacy ESAPI encoders with the OWASP Java Encoder.
We're happy to announce that version 1.1 has been released. Along with a few minor encoding enhancements, we improved performance, and added a JSP tag and function library.