OSSP CVS Repository

ossp - Ticket #206
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [Attach]  [Edit]  [History

Ticket 206: Data::UUID compat create_from_name() is broken

Hi, the create_from_namespace() method actually never uses the provided namespace (parameter $nsid).

  --- a/Data/UUID.pm
  +++ b/Data/UUID.pm
  @@ -61,7 +61,7 @@
       my ($self, $nsid, $name) = @_;
       my $uuid = OSSP::uuid->new;
       my $nsiduuid = OSSP::uuid->new;
  -    $nsiduuid->import('bin', $nsiduuid);
  +    $nsiduuid->import('bin', $nsid);
       $uuid = OSSP::uuid->new;
       $uuid->make('v3', $nsiduuid, $name);
       return $uuid->export('bin');

Not sure if fixing this is actually a good idea.

Doing so would mean the code would start generating different UUIDs for the same input. OTOH the current state makes this non-interoperable with other implementations.

[Add remarks]

Remarks:

Properties:

Type: code           Version: 1.6.2-1.5+b7 
Status: new          Created: 2022-May-30 17:17
Severity:          Last Change: 2022-May-30 17:17
Priority:          Subsystem: uuid 
Assigned To: rse           Derived From:  
Creator: anonymous 

CVSTrac 2.0.1