I finally found an <span id="goog_1260974067763"></span>RFC Errata Repor<span id="goog_1260974067764"></span>t (<a href="http://www.rfc-editor.org/errata_search.php?rfc=4122">http://www.rfc-editor.org/errata_search.php?rfc=4122</a>) that states:<br>
<br><p>In Appendix B, it says:</p>
<pre class="rfctext">uuid_create_md5_from_name(): e902893a-9d22-3c7e-a7b8-d6e313b71d9f<br></pre>
<p>It should say:</p>
<pre class="rfctext">uuid_create_md5_from_name(): 3d813cbb-47fb-32ba-91df-831e1593ac29<br></pre>
<p>Notes:</p>
<p class="simpleindent">
The given value e902... etc. is based on a calculation swapping the
eight octets 0..3, 4..5, 6..7 twice, for the name space UUID, and for
the MD5 output, as foreseen for little endian input, but the example
values were already big endian. I can reproduce the example and the
proposed fix, see
<<a href="http://omniplex.blogspot.com/2008/03/md5-16-pop3-and-uuid.html">http://omniplex.blogspot.com/2008/03/md5-16-pop3-and-uuid.html</a>>.<br>
<br>
The blog entry contains links to an identical older error report, and
two (different) examples from third parties also agreeing with that
theory. <br></p>---<br><br>I will take Robby's advice and have one definition and have an optional Boolean argument to force the 'buggy' behaviour. The default will be the 'correct' encoding per the Unix uuid command.<br>
<br>Now, I have the following test output:<br><br>...<br>(make-uuid-3 namespace-DNS "<a href="http://www.widgets.com">www.widgets.com</a>") = #<uuid 3d813cbb-47fb-32ba-91df-831e1593ac29><br>(make-uuid-3 namespace-DNS "<a href="http://www.widgets.com">www.widgets.com</a>" #t) = #<uuid e902893a-9d22-3c7e-a7b8-d6e313b71d9f><br>
...<br><br>I think this is the correct resolution. <br><br>Doug<br><br><div class="gmail_quote">On Tue, Dec 15, 2009 at 9:03 PM, Robby Findler <span dir="ltr"><<a href="mailto:robby@eecs.northwestern.edu">robby@eecs.northwestern.edu</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">I would say that the right thing is an optional (or keyword) argument<br>
that defaults to the value of a parameter, so the default can easily<br>
be changed for a range of code.<br>
<br>
Robby<br>
<div><div></div><div class="h5"><br>
On Tue, Dec 15, 2009 at 9:46 PM, Doug Williams<br>
<<a href="mailto:m.douglas.williams@gmail.com">m.douglas.williams@gmail.com</a>> wrote:<br>
> I've implemented RFC 4122 Universally Unique Identifiers (UUIDs) and have an<br>
> interesting dilemma. Two of the types of UUIDs are generated based on a<br>
> namespace UUID and name using either MD5 (a type 3 UUID) or SLA-1 (a type 5<br>
> UUID) hashes. I implemented the type 3 and type 5 UUIDs in accordance with<br>
> RFC 4122 - in particular, my result for the type 3 example in the RFC<br>
> matches the result I get; there is no type 5 example. Then I checked it<br>
> against the Python implementation and got a different answer. After a bit of<br>
> a search I found a post by the original author of the Python code that said<br>
> he felt the RFC implementation was in error. Anyway, the Unix uuid command<br>
> matches the Python answer, but I have found others (e.g., Apache and PHP<br>
> that match (or did match) the RFC). For the curious, the difference has to<br>
> do with byte-swapping to/from network order.<br>
><br>
> I've implemented type 3 and type 5 UUIDs both ways and have separate calls -<br>
> for example, make-uuid-3 and make-uuid-3*. For now, I have make-uuid-3<br>
> matching the Unix uuid command and make-uuid-3* matching the RFC. The same<br>
> goes for type 5 UUIDs.<br>
><br>
> The first question is whether there are any web gurus on the mailing list<br>
> that might know which really is the correct/preferred implementation. I<br>
> haven't found any addenda or anything for RFC 4122 that suggests that the<br>
> IETF considers the RFC to be in error. On the other hand, the Unix and<br>
> Python implementations are widely used.<br>
><br>
> The second question is whether to two functions as described above or a<br>
> single function with an optional argument to specify which of the two<br>
> alternatives to use. My initial decision is to use two functions as above,<br>
> where the Unix uuid values are the unstarred version. So, make-uuid-3<br>
> returns the same value as the Unix 'uuid -v3' command and make-uuid-3*<br>
> returns the same value as the RFC reference implementation. [My assumption<br>
> being that the Unix uuid version is the more wide used, but I may be totally<br>
> wrong.]<br>
><br>
> I do feel I should provide both, since both seem to exist 'in the wild' and<br>
> the purpose of type 3 and 5 UUIDs is to be repeatable.<br>
><br>
> For those interested, the package also produces type 1 (time-based) and type<br>
> 4 (random) UUIDs.<br>
><br>
> Doug<br>
><br>
</div></div>> _________________________________________________<br>
> For list-related administrative tasks:<br>
> <a href="http://list.cs.brown.edu/mailman/listinfo/plt-scheme" target="_blank">http://list.cs.brown.edu/mailman/listinfo/plt-scheme</a><br>
><br>
><br>
</blockquote></div><br>