[
https://issues.apache.org/jira/browse/FC-28?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14224846#comment-14224846
]
Emmanuel Lecharny commented on FC-28:
-------------------------------------
May be it would be better to have it set to optional by default. We also might
want those checks to be relative to the type of backend (it's not necessarily
LDAP)
> The safeText method is probably not useful, and can be faster
> -------------------------------------------------------------
>
> Key: FC-28
> URL: https://issues.apache.org/jira/browse/FC-28
> Project: FORTRESS-CORE
> Issue Type: Improvement
> Affects Versions: 1.0-RC35
> Reporter: Emmanuel Lecharny
> Fix For: 1.1.0
>
>
> When we want to validate an entity before injecting it in the server, we call
> the RegExUtil.safeText() method.
> It's checking something the server will already check (each value injected in
> the server will be controlled). Of course, we can set limits like the max
> length, but this can be done when defining the AttributeType (using the
> {NNN}
> notation).
> Otherwise, the way the regexp is evaluated is costly : we compile the gexep
> every time, when it could be done only once.
> Pattern safeTextPattern = Pattern.compile(safeTextPatternStr);
> can be done globally.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)