You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by "Andreas Andreou (JIRA)" <de...@tapestry.apache.org> on 2007/10/24 05:19:50 UTC
[jira] Commented: (TAPESTRY-1857) Email validator's regexp pattern
causes possibly infinite loop
[ https://issues.apache.org/jira/browse/TAPESTRY-1857?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12537193 ]
Andreas Andreou commented on TAPESTRY-1857:
-------------------------------------------
Before revision 483838, we were using
public static final String PATTERN = "^\\w[-._\\w]*\\w@\\w[-._\\w]*\\w\\.\\w{2,6}$";
which (just like the suggested pattern) works very fast
but fails for single chars in local or domain part - our test case includes
j@apache.org, jkuhnert@a.org
I'm wondering if:
a) such emails are valid (dojo's js validator says yes)
b) it's worth supporting, considering the DOS opportunities.
c) there's anything better
> Email validator's regexp pattern causes possibly infinite loop
> --------------------------------------------------------------
>
> Key: TAPESTRY-1857
> URL: https://issues.apache.org/jira/browse/TAPESTRY-1857
> Project: Tapestry
> Issue Type: Bug
> Components: Framework
> Affects Versions: 4.1.3
> Reporter: Ulrich Stärk
> Assignee: Andreas Andreou
> Priority: Blocker
> Fix For: 4.1.4
>
> Attachments: patch.txt, Test.java
>
>
> The regex pattern used by the email validator causes a possibly infinite loop in java.util.regex.Pattern with some input.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org