Specialized LLM-based APR framework can automatically fix cross-compartment interface bugs
The authors assert their compartmentalization-aware APR framework generates effective patches for interface vulnerabilities
Security & privacy arXiv 10 Mar 2026 Method Prototype evidence
Published as “Compartmentalization-Aware Automated Program Repair”
Why it matters
If the approach scales, LLM-based APR can automatically harden cross-compartment interfaces, reducing manual effort required to eliminate compartment interface vulnerabilities.
Summary
The compartmentalization-aware APR framework places patches at the correct trusted-side location 100% of the time and never violates the trust model, outperforming naive GPT-4o-mini (10% correct) and GPT-5 (20% correct, 50% trust break) baselines on a representative Apache HTTPD CIV; evidence comes from a small case study with 10 iterations, and the authors note the approach is still early, limited to one vulnerability and with unvalidated patch-location heuristics.
What they found 2
- The framework achieves 100% correct patch placement and 0% trust-model violations, while naive LLM baselines perform far worse.
“Naive GPT-4o-mini 10% 0% Naive GPT5 20% 50% This work 100% 0% where this unit is first interpreted in trusted code.”
- GPT-5’s patch only adds a NULL-pointer check, which is a partial fix because the failure mode also includes non-NULL unmapped pointers.
“GPT5 adds a NULL-pointer check before passing the pointer to apr_table_get. However, the failure mode in this CIV is not limited to NULL: the pointer can be non-NULL yet unmapped. As a result, this patch is only a partial fix.”
Caveats 7
- The framework does not handle the harder case where the pointer is mapped but refers to a corrupted apr_table_t object, which is left as future work.
- The current definition for the ideal CIV patch location has not been validated against a large amount of CIVs and may evolve.
- Evaluation so far is limited to a single representative vulnerability (Apache HTTPD) with 10 iterations; broader assessment is pending.
- We also only consider CIVs involving one malicious and one victim compartment, a prevalent scenario vs. more complex ones such as having several compartments under the control of the attacker.
- We also only consider CIVs involving one malicious and one victim compartment, ... we scope control flow-based cross-compartment attacks as future works.
- In particular, our current definition for the ideal CIV patch location has not been validated against a large amount of CIVs, and it may evolve in the future.
- This still does not address the harder case where the pointer is mapped but refers to a corrupted apr_table_t object. Handling mapped-but-corrupted structured state is left as future work.
What’s new here 4
- Integrates compartmentalization analysis (trust boundaries, payload flow) into LLM prompts for patch generation.
- Uses an in-memory fuzzer (ConfFuzz) in a feedback loop to discover CIVs and validate patches.
- Introduces two CIV classification techniques based on payload type and call-stack roles to guide patch location.
- Selects patch locations according to a trust-model-aware ranking policy, avoiding modifications inside untrusted compartments.