04. Protocol Drift — When Two Sides Disagree About the Contract
04. การเบี่ยงเบนของโปรโตคอล — เมื่อสองฝ่ายมีความเห็นไม่ตรงกันเรื่องสัญญา
The Origins of Liberal Acceptance
ต้นกำเนิดของการยอมรับแบบยืดหยุ่น
In 1989, J. Postel and his colleagues codified a foundational design principle for internet communication within the document formally known as RFC 1122. This guideline, which advised developers to be conservative in what they do but liberal in what they accept, aimed to ensure maximum interoperability between disparate systems. The IETF architects believed that by accepting slightly malformed input, services could survive minor errors without collapsing, thereby keeping the network functional and resilient. However, this design choice quietly shifted the actual maintenance burden onto the side that attempted to remain strictly correct according to the original, intended specification. Because the receiver silently papered over errors, the sender was never alerted that their output had drifted away from the agreed-upon standards of the protocol. Over time, the original contract between these two systems effectively vanished, leaving behind a fragile, undocumented reality that neither party fully owned or understood.
ในปี 1989 J. Postel และคณะเขียนหลักการที่ภายหลังจะทำให้สัญญาระหว่างระบบเลือนหายไป ลงในเอกสารที่รู้จักกันในชื่อทางการว่า RFC 1122 หลักการนั้นว่าไว้สั้นๆ ทำในสิ่งที่ตนทำอย่างอนุรักษ์นิยม ยอมรับสิ่งที่ได้รับอย่างยืดหยุ่น เป้าหมายคือให้ระบบที่ต่างกันทำงานร่วมกันได้มากที่สุด สถาปนิกของ IETF เชื่อว่าถ้ายอมรับอินพุตที่ผิดรูปแบบไปบ้าง บริการต่างๆ จะรอดจากข้อผิดพลาดเล็กน้อยได้โดยไม่ล่ม และเครือข่ายจะยังทำงานได้และทนทาน ทางเลือกนี้กลับผลักภาระบำรุงรักษาจริงไปไว้ที่ฝ่ายที่พยายามทำให้ถูกต้องตามข้อกำหนดดั้งเดิมอย่างเคร่งครัด โดยไม่มีใครรู้ตัว ผู้รับกลบเกลื่อนข้อผิดพลาดไปเงียบๆ ผู้ส่งจึงไม่เคยรู้ว่าเอาต์พุตของตนเบี่ยงเบนไปจากมาตรฐานของโปรโตคอลที่ตกลงกันไว้ เมื่อเวลาผ่านไป สัญญาดั้งเดิมระหว่างระบบทั้งสองก็หายไปในทางปฏิบัติ เหลือไว้เพียงความเป็นจริงที่เปราะบาง ไม่มีเอกสารกำกับ และไม่มีฝ่ายใดเป็นเจ้าของหรือเข้าใจอย่างถ่องแท้
The Cost of Silent Tolerance
ต้นทุนของการยอมรับอย่างเงียบเชียบ
By 2023, the Internet Architecture Board, led by authors including Martin Thomson and T. Pauly, published RFC 9413 to formally address the consequences of this drift. The board observed that the long-standing habit of tolerating non-conforming input had inadvertently rewarded senders who failed to adhere to the established, rigorous protocol specifications. This silent tolerance entrenched deep ambiguity and created significant security flaws, as systems began to rely on unpredictable behaviors rather than the formal, explicit interface contract. The conservative sender, who continued to follow the rules, was forced to pay the maintenance cost indefinitely to accommodate the erratic behavior of the liberal peer. The IAB concluded that active protocol maintenance is far superior to the passive acceptance of malformed input, as it forces both sides to remain aligned. Contract testing, such as the use of consumer-driven contracts like Pact, serves as the modern enforcement mechanism that replaces vague assumptions with executable, verifiable interface expectations.
ภายในปี 2023 การเบี่ยงเบนนี้ถูกจัดการอย่างเป็นทางการ Internet Architecture Board นำโดยผู้เขียนที่รวมถึง Martin Thomson และ T. Pauly เผยแพร่ RFC 9413 เพื่อรับมือกับผลของมันโดยตรง คณะกรรมการสังเกตว่านิสัยยอมรับอินพุตที่ไม่ตรงมาตรฐานซึ่งมีมานาน ให้รางวัลแก่ผู้ส่งที่ไม่ทำตามข้อกำหนดโปรโตคอลที่เข้มงวดและชัดเจน โดยไม่มีใครตั้งใจ การยอมรับเงียบๆ นี้ฝังความคลุมเครือลงลึก และสร้างข้อบกพร่องด้านความปลอดภัยที่สำคัญ เพราะระบบเริ่มพึ่งพาพฤติกรรมที่คาดเดาไม่ได้ แทนสัญญาจุดเชื่อมต่อที่ชัดเจนและเป็นทางการ ผู้ส่งที่อนุรักษ์นิยมและยังทำตามกฎ ต้องจ่ายต้นทุนบำรุงรักษาไปไม่มีกำหนด เพื่อรองรับพฤติกรรมที่เอาแน่เอานอนไม่ได้ของคู่สนทนาที่ยืดหยุ่นเกินไป IAB สรุปว่าการบำรุงรักษาโปรโตคอลเชิงรุกเหนือกว่าการรับอินพุตผิดรูปแบบโดยไม่โต้ตอบอยู่มาก เพราะมันบังคับให้ทั้งสองฝ่ายรักษาแนวทางให้ตรงกันอยู่เสมอ การทดสอบสัญญา เช่น สัญญาที่ขับเคลื่อนโดยผู้ใช้งาน (consumer-driven contracts) อย่าง Pact คือกลไกบังคับใช้สมัยใหม่ มันแทนที่ข้อสมมติฐานที่คลุมเครือด้วยความคาดหวังต่อจุดเชื่อมต่อที่รันได้และตรวจสอบได้จริง
The Shift in Standards
การเปลี่ยนแปลงของมาตรฐาน
The dispute regarding the validity of liberal acceptance is now resolved rather than contested, as the Internet Architecture Board has officially adopted the critique. The industry has moved away from the 1989 philosophy of RFC 1122 and toward the 2023 mandate of RFC 9413 for maintaining robust, predictable network protocols. The IETF has essentially reversed its stance, prioritizing explicit enforcement and clear contract adherence over the previous preference for loose, forgiving communication channels.
ข้อพิพาทเรื่องความถูกต้องของการยอมรับแบบยืดหยุ่นจบแล้ว ไม่ใช่ยังถกเถียงกันอยู่ เพราะ Internet Architecture Board รับคำวิจารณ์นั้นไว้อย่างเป็นทางการ อุตสาหกรรมย้ายจากปรัชญาปี 1989 ของ RFC 1122 ไปสู่ข้อบังคับปี 2023 ของ RFC 9413 เพื่อรักษาโปรโตคอลเครือข่ายให้ทนทานและคาดการณ์ได้ IETF กลับจุดยืนโดยพื้นฐาน มันให้น้ำหนักกับการบังคับใช้ที่ชัดเจนและการทำตามสัญญาที่ชัดแจ้ง มากกว่าช่องทางสื่อสารที่หละหลวมและให้อภัยความผิดพลาดอย่างที่เคยเลือกในอดีต
Example: A handshake that ignores a broken finger eventually leads to a grip that cannot hold any weight at all.
ตัวอย่าง: จับมือโดยละเลยนิ้วที่หัก สุดท้ายมือนั้นจะจับอะไรไม่อยู่ รับน้ำหนักไม่ได้เลย
Verdict. Systems fail when the interface contract is allowed to decay through the silent, unverified acceptance of inputs that deviate from the agreed specifications.
คำตัดสิน. ระบบล้มเหลวเมื่อสัญญาจุดเชื่อมต่อถูกปล่อยให้เสื่อมถอย ผ่านอินพุตที่เบี่ยงเบนจากข้อกำหนดที่ตกลงกันไว้ แล้วถูกรับเข้ามาเงียบเชียบโดยไม่มีการตรวจสอบ
Overturned if: A large-scale empirical study demonstrates that protocols enforcing strict input validation suffer higher rates of catastrophic failure than those using liberal acceptance policies.
จะพลิกคำตัดสินได้เมื่อ: มีการศึกษาเชิงประจักษ์ขนาดใหญ่แสดงว่าโปรโตคอลที่บังคับตรวจสอบอินพุตอย่างเข้มงวด ล้มเหลวร้ายแรงในอัตราที่สูงกว่าโปรโตคอลที่ใช้นโยบายยอมรับแบบยืดหยุ่น
Sources. 1989 · J. Postel et al., "Requirements for Internet Hosts — Communication Layers" — IETF Datatracker · 2023 · Internet Architecture Board / M. Thomson, T. Pauly, "Maintaining Robust Protocols" — RFC Editor
แหล่งอ้างอิง. 1989 · J. Postel et al., "Requirements for Internet Hosts — Communication Layers" — IETF Datatracker · 2023 · Internet Architecture Board / M. Thomson, T. Pauly, "Maintaining Robust Protocols" — RFC Editor