← Lab /Software

LLM-generated input alphabets enable state machine learning to uncover new protocol bugs

Automatically generated alphabets and incremental learning reproduce known vulnerabilities and discover semantic bugs in stateful protocol implementations

Software arXiv 22 Jun 2026 Method Prototype evidence

Published as “An Automated Framework for Input Alphabet Construction in Stateful Protocol Implementation Learning”

Why it matters

The framework lets security engineers automatically generate comprehensive protocol alphabets and efficiently learn state machines, enabling discovery of semantic bugs that would be missed by manual alphabets or traditional fuzzers.

Summary

The paper shows that automatically generating input alphabets with large language models and structured mutation enables state-machine learning to reproduce two known high-severity semantic vulnerabilities and discover ten new semantic bugs (three patched and one assigned a CVE). Experiments on several real protocol implementations demonstrate that their mini-batch learning strategy cuts learning time by up to 32.5% compared to using the full, manually defined alphabet, and that the approach scales to large alphabets where naive learning fails to finish within 12 hours.

What they found 3

  1. Reproduces known vulnerabilities and discovers ten new semantic bugs

    “As a result, Our approach successfully reproduces two classic highseverity historical semantic vulnerabilities and discovers ten semantic bugs in total.”

  2. Reduces learning time by 32.5% on average for single-symbol mutation compared to baseline

    “For learning on the extended alphabet generated under the single-symbol mutation strategy, our method reduces the time cost by 32.5% on average compared with the baseline method.”

  3. Three discovered bugs have been fixed and one assigned a CVE

    “discovers previously unknown bugs (with three fixed and one assigned a CVE)”

Caveats 4

  • Learning over the full input symbol set fails to terminate within the 12-hour budget for several protocols, showing that a larger alphabet can make the approach impractical without the mini-batch strategy.
  • The single-symbol mutation priority may miss bugs that require interaction of multiple message types, potentially reducing detection coverage.
  • hand-crafted mutation strategies exhibit inherent limitations: they fail to adequately cover bug-relevant input spaces and introduce redundant runtime overhead.
  • Direct client-server interaction in our experiments incurs significant network I/O overhead and synchronous waiting, slowing the learning process.

What’s new here 4

  • Automatic construction of protocol input alphabets using LLM-parsed message layouts
  • Structured mutation rules that generate both valid and invalid message symbols
  • Mini-batch incremental learning that reuses a baseline state machine to keep learning tractable with large alphabets
  • Demonstration of semantic bug detection beyond memory-corruption fuzzing, including previously unknown bugs