[PATCH][SAMBA4] data_blob_hex_string() output is now lowercase.

Andrew Bartlett abartlet at samba.org
Sun Sep 27 22:23:13 MDT 2009


On Sun, 2009-09-27 at 03:50 -0500, Andrew Kroeger wrote:
> Andrew Bartlett wrote:
> > On Sat, 2009-09-26 at 05:51 -0500, Andrew Kroeger wrote:
> >> All:
> >>
> >> Please find attached a patch that addresses a couple of the test 
> >> failures in the Samba4 test suite, due to case sensitivity changes in 
> >> generating hex blob strings.
> >>
> >> Testing via "make test" (with and without commit 
> >> b84edabbe9f358031117de2cf78613c704ac600 and the supplied patch) shows 
> >> that this patch corrects issues with the expected case of return values 
> >> in 2 of the failing Samba4 torture tests.
> >>
> >> All other test failures in the Samba4 test suite occur regardless of 
> >> whether commit b84edabbe9f358031117de2cf78613c704ac600 (or my proposed 
> >> patch) has or has not been applied.
> 
> Andrew:
> 
> > I think the right approach it to change data_blob_hex_string() to
> > generate an upper case string, but to have the extended DN code call a
> > lowercase version for this specific task, given the specific
> > requirement.
> 
> I cannot remember having a previous hex-based case-sensitivity issue in 
> Samba4.  Please correct me if I am incorrect.

Sure, but in the past we sent upper case.  We now know that Microsoft
writes code that is sensitive in this area, so we must be very careful
in future. 

> If W2K8 is matching against a lowercased hex string, and we have not 
> previously encountered any case-sensitivity issues, can we not assume 
> our initial implementation implied the wrong case for hex strings?

Because there are many different places that we use this common
function.  Given the two possible behaviours, we need two functions.
Also for other debugging purposes, lowercase hex is just harder to
read :-)

> After my testing with and without Tridge's casing patch, doesn't it make 
> more sense to address any new case-sensitivity issues as they occur, as 
> opposed to implementing new, special-cased functions every time we 
> discover a case discrepancy?

Given what it took (having an MS engineer run a debugger on and manual
inspection of their code) to find this one, I would rather not wait and
see.

Andrew Bartlett

-- 
Andrew Bartlett                                http://samba.org/~abartlet/
Authentication Developer, Samba Team           http://samba.org
Samba Developer, Red Hat Inc.                  http://redhat.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20090928/6bd23773/attachment.pgp>


More information about the samba-technical mailing list