James Thomas – I think we should probably file a JIRA in the HADOOP project to add the relevant APIs to DataChecksum. They aren't HDFS-specific – I just filed MAPREDUCE-5962 for one example of a place where we can use them from within MR.
Perhaps it makes sense to even file two:
1) support verifyChunkedSums on a byte array
2) native code to calculate chunked sums (on both byte array and byte buffer)
which would allow us to break up the work a bit better for easy review. Feel free to ping me for review when patches are ready.