Check out the new USENIX Web site. next up previous
Next: Checking for Resource Leaks Up: Specifying Correctness Properties Previous: Specifying Correctness Properties

Checking Protocol Conformance

Checking that a TCP implementation conforms to the protocol specification is a challenge. The specification itself [35,6] is large and complex. Moreover, the TCP specification is ambiguous at many places, leaving room for the implementations to make their own choices.

Along the lines of [33], we check for protocol conformance by ensuring that every transition of the implementation is allowed by a TCP reference model. This reference model consists of the basic state machine transitions literally translated from  [35] to C, and is around $500$ lines of code. During model checking, CMC provides the same set of input events (system calls, network and timer interrupts) to both the implementation and the reference model, and expects their states and the outputs (network packets and system call return values) to be consistent.

All inconsistencies between the TCP implementation and the reference model are not necessarily errors. They can arise due to the ambiguities in the TCP specification, known errors in the protocol [34], and manual errors in the reference model. We iteratively modified our reference model when we found such false error reports.


next up previous
Next: Checking for Resource Leaks Up: Specifying Correctness Properties Previous: Specifying Correctness Properties
Madanlal Musuvathi 2004-03-03