httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From William A Rowe Jr <wr...@rowe-clan.net>
Subject Re: apr_token_* conclusions (was: Better casecmpstr[n]?)
Date Thu, 26 Nov 2015 00:45:30 GMT
On Nov 25, 2015 4:19 PM, "Mikhail T." <mi+thun@aldan.algebra.com> wrote:
>
>
>>
>> So, the concern is, some hypothetical header, such as X-ASSIGN-TO may,
after going through the locale-aware strtolower() unexpectedly become
x-aßign-to?
>
> I just tested the above on both FreeBSD and Linux, and the results are
encouraging:
>>
>> % echo STRASSE | env LANG=de_DE.ISO8859 tr '[[:upper:]]' '[[:lower:]]'
>> strasse
>
> Thus, I contend, using C-library will not cause invalid results, and the
only reason to have Apache's own implementation is performance, but not
correctness.

Well almost but wrong...

The pure char-based ß processing produced no case change in my reviews of
tolower/toupper in de_DE codeset. If you were to examine string comparison
the collation order changes substantially.

That said, I'm working up a comprehensive audit and other codeset/language
combinations absolutely do.  Code and results forthcoming shortly.

As long as everyone keeps their fingers off the setlocale()/trigger, it's
all fine.

Mime
View raw message