[SERVER-6287] Increase robustness of wire protocol with the addition of a CRC in header or footer Created: 03/Jul/12  Updated: 13/Jan/17  Resolved: 13/Jan/17

Status: Closed
Project: Core Server
Component/s: Networking, Security
Affects Version/s: None
Fix Version/s: None

Type: New Feature Priority: Trivial - P5
Reporter: Pieter Willem Jordaan Assignee: DO NOT USE - Backlog - Platform Team
Resolution: Won't Fix Votes: 3
Labels: network, packet, protocol, wireprotocol
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

N/A


Backwards Compatibility: Major Change
Participants:

 Description   

Eventhough TCP checksums and Link CRC checks are robust, it is not entirely impossible that false positives can be generated on the verification of network packet data. This could lead to broken data in the database which cannot be detected.

Thus wire protocols are advised to implement application level data integrity checks such as CRC's to provide even greater redundancy.

CRC-32 implementation is trivial and with table lookups performance hits would be negligible.

By implementing a CRC32 into the header or footer of the wire protocol could provide even greater redundancy and stability to what already is a robust system.



 Comments   
Comment by Justin Cohler [ 13/Jan/17 ]

We're not currently considering major breaking changes to the Wire protocol. Additionally, the server provides enhanced validation of user input and provides SSL/TLS.

Comment by Nico Schottelius [ 25/Oct/12 ]

Referred to here by SERVER-7163: I'd advise not only to ensure packets are correct (CRC), but also ensure that the server never crashes: So even in case CRC matches (can be total randomly matching), you should double check the actual data being delivered.

Comment by Ben Becker [ 17/Oct/12 ]

In addition to protecting against network errors, this would also catch bad data caused by a bug in client-side network buffer management code. A classic example is modifying a buffer before an asynchronous network IO function completes.

Generated at Thu Feb 08 03:11:16 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.