BIND 10 #256: bugs in base32.cc

BIND 10 Development do-not-reply at isc.org
Tue Jun 29 00:07:11 UTC 2010


#256: bugs in base32.cc
---------------------------+------------------------------------------------
 Reporter:  jinmei         |       Owner:  jinmei                     
     Type:  defect         |      Status:  new                        
 Priority:  major          |   Milestone:  06. 4th Incremental Release
Component:  DNSPacket API  |    Keywords:                             
Sensitive:  0              |  
---------------------------+------------------------------------------------
 The current implementation of lib/dns/base.cc is buggy.

 Among the bugs is this one:
 {{{
         string group;

         iss >> setw(8) >> group;
         if (iss.bad() || iss.fail()) {
             isc_throw(BadBase32String,
                       "Could not parse base32 input: " << base32);
         }
 }}}

 setw() isn't meaningful in the context of input stream.  With SunStudio
 this will trigger the exception.

 There are other bugs (see, e.g., disabled tests in
 tests/base32_unittest.cc).

 The setw issue will be solved with the attached patch, but I'd rather make
 a complete fix later.

-- 
Ticket URL: <http://bind10.isc.org/ticket/256>
BIND 10 Development <http://bind10.isc.org>
BIND 10 Development


More information about the bind10-tickets mailing list