Hardening attack surfaces with formally proven binary format parsers
Nikhil Swamy, Tahina Ramananandro, Aseem Rastogi, Irina Spiridonova, Haobin Ni, Dmitry Malloy, Juan Vazquez, Michael Tang, Omar Cardona, Arti Gupta
Abstract
With an eye toward performance, interoperability, or legacy concerns, low-level system software often must parse binary encoded data formats. Few tools are available for this task, especially since the formats involve a mixture of arithmetic and data dependence, beyond what can be handled by typical parser generators. As such, parsers are written by hand in languages like C, with inevitable errors leading to security vulnerabilities.
Addressing this need, we present EverParse3D, a parser generator for binary message formats that yields performant C code backed by fully automated formal proofs of memory safety, arithmetic safety, functional correctness, and even double-fetch freedom to prevent certain kinds of time-ofcheck/time-of-use errors. This allows systems developers to specify their message formats declaratively and to integrate correct-by-construction C code into their applications, eliminating several classes of bugs.
EverParse3D has been in use in the Windows kernel for the past year. Applied primarily to the Hyper-V network virtualization stack, the formats of nearly 100 different messages spanning four protocols have been specified in EverParse3D and the resulting formally proven parsers have replaced prior handwritten code. We report on our experience in detail.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext 2718c9b9-ccaf-4f10-bc2c-30ab7beef5e8Cited by top-tier papers10
- StarMalloc: Verifying a Modern, Hardened Memory AllocatorAntonin Reitz, Aymeric Fromherz, Jonathan ProtzenkoOOPSLA 2024 · 5 citations
- Validating Network Protocol Parsers with Traceable RFC Document InterpretationMingwei Zheng, Danning Xie, Qingkai Shi, Chengpeng Wang et al.ISSTA 2025 · 4 citations
- Towards Neural Synthesis for SMT-Assisted Proof-Oriented ProgrammingSaikat Chakraborty, Gabriel Ebner, Siddharth Bhat, Sarah Fakhoury et al.ICSE 2025 · 4 citations
- 3DGen: AI-Assisted Generation of Provably Correct Binary Format ParsersSarah Fakhoury, Markus Kuppe, Shuvendu K. Lahiri, Tahina Ramananandro et al.ICSE 2025 · 2 citations
- Formally Verified Cloud-Scale AuthorizationAleks Chakarov, Jaco Geldenhuys, Matthew Heck, Michael Hicks et al.ICSE 2025 · 1 citation
Builds on2
- EverParse: Verified Secure Zero-Copy Parsers for Authenticated Message FormatsTahina Ramananandro, Antoine Delignat-Lavaud, Cédric Fournet, Nikhil Swamy et al.USENIX Security 2019 · 70 citations
- CoStar: a verified ALL(*) parserSam Lasser, Chris Casinghino, Kathleen Fisher, Cody RouxPLDI 2021 · 10 citations
Related papers
- Secure Parsing and Serializing with Separation Logic Applied to CBOR, CDDL, and COSETahina Ramananandro, Gabriel Ebner, Guido Martínez, Nikhil SwamyCCS 2025
- Vest: Verified, Secure, High-Performance Parsing and Serialization for RustYi Cai, Pratap Singh, Zhengyao Lin, Jay Bosamiya et al.USENIX Security 2025
- BinaryInferno: A Semantic-Driven Approach to Field Inference for Binary Message FormatsJared Chandler, Adam Wick, Kathleen FisherNDSS 2023
- Extracting Protocol Format as State Machine via Controlled Static Loop AnalysisQingkai Shi, Xiangzhe Xu, Xiangyu ZhangUSENIX Security 2023
- VEP: A Two-stage Verification Toolchain for Full eBPF ProgrammabilityXiwei Wu, Yueyang Feng, Tianyi Huang, Xiaoyang Lu et al.NSDI 2025 · 8 citations
