1
0是循環冗餘校驗(CRC)的可能校驗和嗎?CRC計算輸出
我使用升壓來計算CRC:
const unsigned int CrcPolynomial = 0x11021;
const unsigned short InitialValue = 0xffff;
boost::crc_optimal<16, CrcPolynomial, InitialValue, 0, true, true> Crc;
// process some bytes...
int x = Crc.checksum(); // <------ can this be 0?
「然後crc(x。crc(x))將爲0」。這僅適用於基本的CRC算法,不能否定位或反轉位。有關更多詳細信息,請參閱此帖:http://stackoverflow.com/questions/5112733/checking-crc32-of-zero-padded-bitstream/6672972#6672972 – Nayuki 2011-07-15 20:09:49