[botan-devel] Botan Fletcher32 contribution

William K. Foster wkf at alum.mit.edu
Wed Nov 6 18:25:04 EST 2013


Hello,

I would like to contribute a fletcher32 checksum to Botan based on some
reading I was doing that shows Fletcher is superior to Adler.

See this 2009 paper about effectiveness of Adler32 vs Fletcher32 as
checksums:
        http://www.ece.cmu.edu/~koopman/pubs/maxino09_checksums.pdf

   "Based on our studies of undetected error probabilities, for networks
    where it is known that burst errors are the dominant source of errors,
    the XOR, two's complement addition, and CRC checksums provide better
    error detection performance than the one's complement addition,
    Fletcher, and Adler checksums."

   "For all networks, a "good" CRC polynomial, whenever possible, should be
    used for error detection purposes.  It provides at least one additional
    bit of error detection capability (more bits of HD) compared to other
    checksums and does so at only a factor of two to four times higher
    computational cost.  In networks where computational cost is a severe
    constraint, the Fletcher checksum is typically a good choice.  *The*
*    Fletcher checksum has a lower computational cost than the Adler*
*    checksum and, contrary to popular belief, is also more effective in*
*    most situations.*"

Therefore, I have created an initial fletcher32 implementation for use in
Botan v1.10.  It includes optimized code for 32 bit vs 64 bit platforms and
also includes assembly language definitions for x86_32 and x86_64. The code
is pretty well tested and appears correct based upon this.

Please let me know if you have any questions.

I hope my code can be incorporated into Botan.

Thanks.

-William
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.randombit.net/pipermail/botan-devel/attachments/20131106/bafe1344/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fletcher32.tar.gz
Type: application/x-gzip
Size: 6654 bytes
Desc: not available
URL: <http://lists.randombit.net/pipermail/botan-devel/attachments/20131106/bafe1344/attachment.bin>


More information about the botan-devel mailing list