directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Stefan Seelmann (JIRA)" <>
Subject [jira] Commented: (DIRSERVER-1247) removing unrequired escaping in DNs / filters
Date Tue, 14 Apr 2009 07:21:16 GMT


Stefan Seelmann commented on DIRSERVER-1247:

Hi Norval,

thanks for your patch, it also fixes DIRSERVER-1347 :-).

I applied it with some modifications:

In AbstractExprNode:
- changed visibility of escapeFilterValue( Object value ) from public to protected because
it is only used from subclasses
- removed encoding of '=' to '\3d' in escapeFilterValue( Object value ) because it is not
necessary according to RFC 4515
- removed unescapeFilterValue( Object value ) because it isn't used.

In SimpleNode:
- changed visibility of getValueEscaped() from public to protected because it is only used
from subclasses
- simplified the getValueEscaped() method

In the tests I replaced some "assert" statements with "assertEquals(...)" calls.

Additionally, not included in you patch, in the NormalizingVisitor I removed the unescapeValue()


> removing unrequired escaping in DNs / filters
> ---------------------------------------------
>                 Key: DIRSERVER-1247
>                 URL:
>             Project: Directory ApacheDS
>          Issue Type: Improvement
>          Components: ldap
>    Affects Versions: 1.5.4
>            Reporter: Norval Hope
>             Fix For: 1.5.5
>         Attachments: DIRSERVER-1247-escaping-2.patch, escaping.patch
>   Original Estimate: 8h
>  Remaining Estimate: 8h
> The current Dn and filter handling is overly restrictive in that all non-ascii characters
are quoted using the \NN syntax. This is probably due to rfc 2253 being unclear about the
fact that multibyte UTF-8 encoded values can be used, but this iss further clarified in rfc
4514 which superceeds 2253. The application of unrequired quoting makes debugging / reading
logs much harder then it should be, as it requires manual calculations rather then just setting
the file encoding on your log file / IDE windows to being UTF-8.
> I have attached a patch file with the required updates to code and unit tests under /shared/ldap
(some problems i had noted with earlier AD version due to unspecified encoding when converting
bytes to / from Strings had already been tidied up in AD 1.5.4). 

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message