Skip to content

Generics-Aware Fuzz Target Generation for Rust Libraries via Structured API Analysis

Aug 2026 · arXiv.org · Vol abs/2608.08637 · 0 citations · 47 references
Computer Science

TL;DR

GRAFT is presented, which extracts structured API information from Rust documentation, builds an API dependency graph via recursive generics-aware type matching, and uses topology-guided traversal plus LLM synthesis with compiler-error feedback to produce compilable fuzz targets.

Abstract

Fuzzing Rust library APIs requires constructing well-typed, compilable call sequences that satisfy ownership rules, generic parameters, and trait bounds; existing tools ignore these constraints or use shallow heuristics, yielding low coverage. We present GRAFT, which extracts structured API information from Rust documentation, builds an API dependency graph via recursive generics-aware type matching, and uses topology-guided traversal plus LLM synthesis with compiler-error feedback to produce compilable fuzz targets. On 13 crates from crates.io, GRAFT achieves 80.75% macro-average API coverage at 96.19% compilation success, outperforming RULF and RPG by 4.76x and 2.43x, and reaching 1.41x the average API coverage of deepSURF on crates with unsafe-reaching APIs.

View source

Similar papers

Book Open access Oct 2026

Pattern-Guided Static Analysis for APIfication of COBOL Monoliths

Legacy COBOL mainframes resist APIfication due to monolithic structure and scattered logic. We present a novel pipeline that takes code blocks selected and validated by the user, potentially with AI-assisted boundary suggestions, and generates compilable API modules with request/response copybooks. Key innovations incl...

Vini Kanvar, Ashwina Kumar, Keerthi Narayan Raghunath · 1 citation
Book Open access Oct 2026

Typed Template Fuzzing

Fuzzing finds bugs by testing software behavior with high volumes of input. To create semantically valid inputs for different targets, traditional fuzzers require significant engineering effort. LLM-based fuzzing approaches can be adapted to create inputs for a wide range of software but introduce new issues: every tes...

Lu Maltsis · 0 citations
Book Open access Oct 2026

BanditFuzz: A Synergistic Differential Fuzzing Framework for Compilers

Compiler fuzzing is critical for ensuring the reliability of modern optimizing compilers. However, traditional generators and raw Large Language Model (LLM) outputs often yield syntactically invalid or low-value programs, incurring significant computational overhead. In this paper, we present BanditFuzz, an end-to-end...

Dong-Hui Li, Ying-Ying Li, Jin-Long Xu et al. · 0 citations
Preprint Oct 2026

Pattern-Guided Graph Synthesis for Suppressing Known Defects in DL Compiler Fuzzing

Fuzzing is effective at finding bugs in deep learning (DL) compilers, but existing fuzzers repeatedly trigger faults they have already uncovered. Current fuzzers diversify the generated programs, and downstream tools deduplicate bug reports post hoc, but neither stops a fuzzer from generating programs that re-trigger k...

Qiong Feng, Xiao-Tian Ma, Di Cui et al. · 0 citations
Book Open access Oct 2026

VARIES: Verification Harness Synthesis and Efficient Scheduling for Unsoundness Detection in Rust Libraries

Rust provides strong compile-time safety guarantees, but unsafe code in real-world libraries can still introduce unsoundness bugs that may undermine this guarantee. Compared with prior work, bounded model checking (BMC) offers a promising direction by adapting formal verification to unsoundness detection. In practice,...

Huang Li, Xing Hu, Xin Xia et al. · 0 citations
Open access Oct 2026

RICE: Harnessing LLMs and Historical Issues to Discover Internal Rust Compiler Errors

Rust is a modern system-level programming language that emphasizes safety, concurrency, and performance. Ensuring the reliability of the Rust compiler is critical, as undetected compiler defects, particularly internal compiler errors (ICEs), can lead to runtime crashes or undefined behavior in system software. Existing...

Lang-Yi Lu, Wei You, Bin Liang et al. · 0 citations

We use cookies to run the site and, with your consent, for analytics and to show ads. See our Cookie Policy.