Reputation: 139
Recently we learnt that while sending data through a communication channels, the noise in the channel can cause errors in the system, and therefore, an error checking code trailer is attached with the data to tell the receiver if the data has been corrupted or not.
The question is how do we make sure that this error checking data is not corrupted? Is there any way we can be sure of this?
Upvotes: 1
Views: 41
Reputation: 171206
If the error checking data (usually a hash/checksum) is corrupted it won't match the actual data and corruption will be reported. This means that in this case the data is falsely marked corrupt but that's fine since corruption is an expected case. It's "falsely" marked as corrupt because only the checksum is actually destroyed. But there is no way to tell the cases apart.
Upvotes: 0
Reputation: 310985
A CRC is computed over the payload. It is a fundamental property of a CRC that if you recompute it over the payload with the sent CRC appended, the result should be zero. If it isn't, either the payload or the CRC has been corrupted, or both. You don't know which, but it's irrelevant: the message has been corrupted in transit.
Upvotes: 1