[ 
https://issues.apache.org/jira/browse/LANG-572?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Henri Yandell updated LANG-572:
-------------------------------

    Fix Version/s: Discussion

> [XSS] StringEscapeUtils.escapeHtml() must escape ' chars to ' 
> ------------------------------------------------------------------
>
>                 Key: LANG-572
>                 URL: https://issues.apache.org/jira/browse/LANG-572
>             Project: Commons Lang
>          Issue Type: Improvement
>          Components: lang.*
>    Affects Versions: 2.4
>         Environment: Operating System: All
> Platform: All 
>            Reporter: Keisuke Kato
>            Priority: Minor
>             Fix For: Discussion
>
>
> If developers putting untrusted data into attribute values using the single 
> quote character ' and StringEscapeUtils.escapeHtml() like:
> <input type='text' name='input' 
> value=*'<%=StringEscapeUtils.escapeHtml(request.getParameter("input"))%>'*>
> Then, the attacker is able to break out of the HTML attribute context like:
> hxxp://example.org/?input=*' onfocus='alert(document.cookie);' id='*
> <input type='text' name='input' 
> value='*'onfocus='alert(document.cookie);'id='*'>
> I think [LANG\-122|https://issues.apache.org/jira/browse/LANG-122] is not 
> truly fixed from this aspect (XSS).



--
This message was sent by Atlassian JIRA
(v6.1#6144)

Reply via email to