组件感知的安卓应用崩溃自动复现方法
CSTR:
作者:
作者单位:

作者简介:

通讯作者:

中图分类号:

TP311

基金项目:

国家自然科学基金(62372232); 中央高校基本科研业务费专项资金(NG2023005)


Component-aware Automatic Crash Reproduction Method for Android Applications
Author:
Affiliation:

Fund Project:

  • 摘要
  • |
  • 图/表
  • |
  • 访问统计
  • |
  • 参考文献
  • |
  • 相似文献
  • |
  • 引证文献
  • |
  • 资源附件
  • |
  • 文章评论
    摘要:

    Android应用开发人员需要快速、准确地复现错误报告以保障应用质量. 然而, 现有方法通常仅依赖堆栈跟踪中提供的崩溃信息生成事件序列, 难以准确定位崩溃页面, 无法为动态探索提供有效指导以触发崩溃. 为解决这一问题, 提出一种组件感知的安卓应用崩溃自动复现方法CReDroid, 能够结合崩溃报告的标题信息和堆栈跟踪来有效地复现崩溃. 首先, CReDroid通过动态探索被测应用构建组件转换图(component transition graph, CTG), 结合堆栈跟踪的动态异常信息与CTG的静态组件交互信息, 精确定位目标崩溃组件; 其次, 基于崩溃报告标题中的关键操作与CTG中的可达路径, 设计自适应评分策略, 利用当前页面所属组件与崩溃组件的上下文关系为GUI控件分配选择优先级分数, 并通过强化学习全局优化动态探索过程, 有效减轻预测过程中的不准确性. 在74个崩溃报告上评估了CReDroid的性能, 并与当前先进的崩溃复现工具CrashTranslator、ReCDroid、ReproBot以及广泛使用的自动化测试工具Monkey和APE进行对比实验. 实验结果显示, CReDroid成功复现了57个崩溃报告, 分别比CrashTranslator、ReCDroid、ReproBot、Monkey和APE多复现13、25、27、30和17个. 此外, 在成功复现相同崩溃的情况下, CReDroid的平均用时较CrashTranslator、ReCDroid、ReproBot、Monkey和APE分别减少26.71%、94.96%、71.65%、84.72%和88.56%.

    Abstract:

    Android application developers need to quickly and accurately reproduce error reports to ensure application quality. However, existing methods often rely solely on crash information provided in stack traces to generate event sequences, making it difficult to accurately locate the crash page and offer effective guidance for dynamic exploration to trigger the crash. To address this issue, this study proposes a component-aware automatic crash reproduction method for Android applications, called CReDroid, which effectively reproduces the crash by leveraging both the title and stack trace of the crash report. First, CReDroid dynamically explores the application under test to construct a component transition graph (CTG) and combines the dynamic exception information from the stack traces with the static component interaction data from the CTG to accurately locate the target crash component. Second, based on the critical operations in the crash report title and the reachable paths in the CTG, CReDroid designs an adaptive strategy that uses the contextual relationship between the current page’s component and the crash component to assign priority scores to GUI widgets. The dynamic exploration process is globally optimized through reinforcement learning to effectively reduce inaccuracies in the prediction process. This study evaluates CReDroid using 74 crash reports and compares its performance with state-of-the-art crash reproduction tools, including CrashTranslator, ReCDroid, and ReproBot, as well as widely used automated testing tools, Monkey and APE. The experimental results show that CReDroid successfully reproduces 57 crash reports, which is 13, 25, 27, 30, and 17 more than CrashTranslator, ReCDroid, ReproBot, Monkey, and APE, respectively. Moreover, for the successfully reproduced crashes, CReDroid reduces the average reproduction time by 26.71%, 94.96%, 71.65%, 84.72%, and 88.56%, compared to CrashTranslator, ReCDroid, ReproBot, Monkey, and APE.

    参考文献
    相似文献
    引证文献
引用本文

刘姝琪,周宇,杨慧文.组件感知的安卓应用崩溃自动复现方法.软件学报,,():1-22

复制
相关视频

分享
文章指标
  • 点击次数:
  • 下载次数:
  • HTML阅读次数:
  • 引用次数:
历史
  • 收稿日期:2025-01-07
  • 最后修改日期:2025-02-17
  • 录用日期:
  • 在线发布日期: 2025-09-10
  • 出版日期:
文章二维码
您是第位访问者
版权所有:中国科学院软件研究所 京ICP备05046678号-3
地址:北京市海淀区中关村南四街4号,邮政编码:100190
电话:010-62562563 传真:010-62562533 Email:jos@iscas.ac.cn
技术支持:北京勤云科技发展有限公司

京公网安备 11040202500063号