一句话:提出 PSDroid,通过路径敏感语义分析检测 Android 应用 API 兼容性问题,显著降低误报与漏报。
Android 碎片化导致 API 相关兼容性问题成为开发者的严峻挑战,现有基于应用和 API 生命周期的方法因 API 使用实现多样、调用路径不同而存在大量误报(FP)和漏报(FN)。为此,本文提出 PSDroid:首先开展初步研究,总结多种带有不同检查实现的 API 用法;其次对所有 Android SDK 框架进行语义解析分析,构建精细化的 API 生命周期数据库;在此基础上设计并实现路径敏感的语义分析方法,自动检测不兼容问题。评估方面,与 FicFinder、ACRYL、CIDER、IctAPIFinder 和 CID 五种现有方法对比,PSDroid 表现更优;作者还进行根因分析,解释其降低 FP 与 FN 的能力。最终,30 个报告问题中有 18 个被应用开发者确认并修复。
Android API-related compatibility issues have be-come a severe problem and significant challenge for app devel-opers due to the well-known Android fragmentation issues. To address this problem, many effective approaches such as app-based and API lifetime-based methods have been proposed to identify incompatible API usages. However, due to the various implementations of API usages and different API invoking paths, there is still a significant weakness of existing approaches, i.e., introducing a massive number of false positives (FP) and false negatives (FN). To this end, in this paper, we propose PSDroid, an automated compatibility detection approach for Android apps, which aims to reduce FPs and FNs by overcoming several technical bottlenecks. Firstly, we make substantial efforts to carry out a preliminary study to summarize a set of novel API usages with diverse checking implementations. Secondly, we construct a refined API lifetime database by leveraging a semantic resolving analysis on all existing Android SDK frameworks. Based on the above two key phases, we design and implement a novel path-sensitive semantic approach to effectively and automatically detect incompatibility issues. To demonstrate the performance, we compared with five existing approaches (i.e., FicFinder, ACRYL, CIDER, IctAPIFinder, and CID) and the results show that PSDroid outperforms existing tools. We also conducted an in-depth root cause analysis to comprehensively explain the ability of PSDroid in reducing FPs and FNs. Finally, 18/30 reported issues have been confirmed and further fixed by app developers.
@inproceedings{YangCFXHH23,
title = {Compatibility Issue Detection for Android Apps Based on Path-Sensitive Semantic Analysis},
author = {Sen Yang and Sen Chen and Lingling Fan and Sihan Xu and Zhanwei Hui and Song Huang},
booktitle = {ICSE},
year = {2023},
doi = {10.1109/icse48619.2023.00033}
}