What IF Is Not Enough? Fixing Null Pointer Dereference With Contextual Check
Yunlong Xing, Shu Wang, Shiyu Sun, Xu He, Kun Sun, Qi Li
摘要
Null pointer dereference (NPD) errors pose the risk of unexpected behavior and system instability, potentially leading to abrupt program termination due to exceptions or segmentation faults. When generating NPD fixes, all existing solutions are confined to the function level fixes and ignore the valuable intraprocedural and interprocedural contextual information, potentially resulting in incorrect patches. In this paper, we introduce CONCH, a novel approach that addresses the challenges of generating correct fixes for NPD issues by incorporating contextual checks. Our method first constructs an NPD context graph to maintain the semantics related to patch generation. Then we summarize distinct fixing position selection policies based on the distribution of the error positions, ensuring the resolution of bugs without introducing duplicate code. Next, the intraprocedural state retrogression builds the if condition, retrogresses the local resources, and constructs return statements as an initial patch. Finally, we conduct interprocedural state propagation to assess the correctness of the initial patch in the entire call chain. We evaluate the effectiveness of CONCH over two real-world datasets. The experimental results demonstrate that CONCH outperforms the SOTA methods and yields over 85% accurate patches.
问问这篇 Paper
智能体会读完全文。
Lune 把这篇 Paper 索引到了每一个公式,引用它的顶会 Paper 也一样。你提问,回答直接引用原文。
引用它的顶会 Paper5
- pPatch: Automated Vulnerability UnpatchingTianyi Jing, Pengyu Ding, Meng Xu, Yinhao Hu 等FSE 2026
- PATCHAGENT: A Practical Program Repair Agent Mimicking Human ExpertiseZheng Yu, Ziyi Guo, Yuhang Wu, Jiahao Yu 等USENIX Security 2025
- SoK: Automated Vulnerability Repair: Methods, Tools, and AssessmentsYiwei Hu, Zhen Li, Kedie Shu, Shenghua Guan 等USENIX Security 2025
- LogicEval: A Systematic Framework for Evaluating Automated Repair Techniques for Logical Vulnerabilities in Real-World SoftwareSyed Md. Mukit Rashid, Abdullah Al Ishtiaq, Kai Tu, Yilu Dong 等ACL 2026
- SoK: Towards Effective Automated Vulnerability RepairYing Li, Faysal Hossain Shezan, Bomin Wei, Gang Wang 等USENIX Security 2025
它引用的顶会 Paper4
- Where Does It Go?: Refining Indirect-Call Targets with Multi-Layer Type AnalysisKangjie Lu, Hong HuCCS 2019 · 被引用 142 次
- Local Reasoning About the Presence of Bugs: Incorrectness Separation LogicAzalea Raad, Josh Berdine, Hoang-Hai Dang, Derek Dreyer 等CAV 2020 · 被引用 70 次
- SAVER: scalable, precise, and safe memory-error repairSeongjoon Hong, Junhee Lee, Jeongsoo Lee, Hakjoo OhICSE 2020 · 被引用 28 次
- NPEX: Repairing Java Null Pointer Exceptions without TestsJunhee Lee, Seongjoon Hong, Hakjoo OhICSE 2022 · 被引用 13 次
相关 Paper
- Detecting API Post-Handling Bugs Using Code and Description in PatchesMiaoqian Lin, Kai Chen, Yang XiaoUSENIX Security 2023
- Program vulnerability repair via inductive inferenceYuntong Zhang, Xiang Gao, Gregory J. Duck, Abhik RoychoudhuryISSTA 2022 · 被引用 29 次
- Reorder Pointer Flow in Sound Concurrency Bug PredictionYuqi Guo, Shihao Zhu, Yan Cai, Liang He 等ICSE 2024 · 被引用 1 次
- Context Debloating for Object-Sensitive Pointer AnalysisDongjie He, Jingbo Lu, Jingling XueASE 2021 · 被引用 10 次
- Rete: Learning Namespace Representation for Program RepairNikhil Parasaram, Earl T. Barr, Sergey MechtaevICSE 2023 · 被引用 12 次
