Detecting API-Misuse Based on Pattern Mining via API Usage Graph with Parameters

被引:0
|
作者
Wu, Yulin [1 ]
Xu, Zhiwu [1 ]
Qin, Shengchao [2 ]
机构
[1] Shenzhen Univ, Coll Comp Sci & Software Engn, Shenzhen, Peoples R China
[2] Xidian Univ, Sch Comp Sci & Technol, Xian, Peoples R China
基金
中国国家自然科学基金;
关键词
API-Misuse Detection; API Pattern; Static Analysis;
D O I
10.1007/978-3-031-35257-7_21
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
API misuse is a common issue that can trigger software crashes, bugs, and vulnerabilities. To address this problem, researchers have proposed pattern-based violation detectors that automatically extract patterns from code. However, these detectors have demonstrated low precision in detecting API misuses. In this paper, we propose a novel API misuse detector. Our proposed detector initially extracts API usages from the code and represents them as API Usage Graphs with Parameters (AUGPs). Utilizing the association rule algorithm, it then mines the binary rules, which are subsequently employed to detect the possible violations. The experimental results show that, comparing against five state-of-the-art detectors on the public dataset MuBench, our detector achieves the highest precision (1x more precise than the second-best one) and the highest F1-score (50% higher than the second-best one).
引用
收藏
页码:344 / 363
页数:20
相关论文
共 50 条
  • [21] API usage pattern recommendation for software development
    Niu, Haoran
    Keivanloo, Iman
    Zou, Ying
    JOURNAL OF SYSTEMS AND SOFTWARE, 2017, 129 : 127 - 139
  • [22] Demystify Official API Usage Directives with Crowdsourced API Misuse Scenarios, Erroneous Code Examples and Patches
    Ren, Xiaoxue
    Sun, Jiamou
    Xing, Zhenchang
    Xia, Xin
    Sun, Jianlin
    2020 ACM/IEEE 42ND INTERNATIONAL CONFERENCE ON SOFTWARE ENGINEERING (ICSE 2020), 2020, : 925 - 936
  • [23] Graph Neural Network Based Collaborative Filtering for API Usage Recommendation
    Ling, Chunyang
    Zou, Yanzhen
    Xie, Bing
    2021 IEEE INTERNATIONAL CONFERENCE ON SOFTWARE ANALYSIS, EVOLUTION AND REENGINEERING (SANER 2021), 2021, : 36 - 47
  • [24] CodeKernel: A Graph Kernel based Approach to the Selection of API Usage Examples
    Gu, Xiaodong
    Zhang, Hongyu
    Kim, Sunghun
    34TH IEEE/ACM INTERNATIONAL CONFERENCE ON AUTOMATED SOFTWARE ENGINEERING (ASE 2019), 2019, : 602 - 613
  • [25] Boosting API Misuse Detection via Integrating API Constraints from Multiple Sources
    Li, Can
    Zhang, Jingxuan
    Tang, Yixuan
    Li, Zhuhang
    Sun, Tianyue
    2024 IEEE/ACM 21ST INTERNATIONAL CONFERENCE ON MINING SOFTWARE REPOSITORIES, MSR, 2024, : 14 - 26
  • [26] ArgusDroid: detecting Android malware variants by mining permission-API knowledge graph
    Yude BAI
    Sen CHEN
    Zhenchang XING
    Xiaohong LI
    ScienceChina(InformationSciences), 2023, 66 (09) : 115 - 133
  • [27] ArgusDroid: detecting Android malware variants by mining permission-API knowledge graph
    Yude Bai
    Sen Chen
    Zhenchang Xing
    Xiaohong Li
    Science China Information Sciences, 2023, 66
  • [28] ArgusDroid: detecting Android malware variants by mining permission-API knowledge graph
    Bai, Yude
    Chen, Sen
    Xing, Zhenchang
    Li, Xiaohong
    SCIENCE CHINA-INFORMATION SCIENCES, 2023, 66 (09)
  • [29] Mining API Usage Examples from Test Code
    Zhu, Zixiao
    Zou, Yanzhen
    Xie, Bing
    Jin, Yong
    Lin, Zeqi
    Zhang, Lu
    2014 IEEE INTERNATIONAL CONFERENCE ON SOFTWARE MAINTENANCE AND EVOLUTION (ICSME), 2014, : 301 - 310
  • [30] Mining API usage scenarios from stack overflow
    Uddin, Gias
    Khomh, Foutse
    Roy, Chanchal K.
    INFORMATION AND SOFTWARE TECHNOLOGY, 2020, 122