计算机应用 ›› 2014, Vol. 34 ›› Issue (12): 3507-3510.

• 计算机软件技术 • 上一篇    下一篇

嵌入式智能电表中的反汇编关键问题分析

刘金硕1,王谢兵1,郑稳2,邓娟3,陈鑫1   

  1. 1. 武汉大学 计算机学院,武汉 430072;
    2. 武汉大学 城市设计学院,武汉 430072;
    3. 武汉大学 国际软件学院,武汉 430072
  • 收稿日期:2014-06-30 修回日期:2014-08-01 出版日期:2014-12-01 发布日期:2014-12-31
  • 通讯作者: 王谢兵
  • 作者简介:刘金硕(1974-),女,吉林辽源人,副教授,博士,主要研究方向:模式识别、图像处理、高性能计算;王谢兵(1992-),男,安徽无为人,硕士研究生,主要研究方向:信息安全、嵌入式系统设计、大数据;郑稳(1989-),男,安徽六安人,硕士研究生,主要研究方向:计算机图形设计、虚拟现实;邓娟(1976-),女,湖北武汉人,副教授,博士,主要研究方向:数字图像处理、高性能计算;陈鑫(1989-),男,河南信阳人,硕士研究生,主要研究方向:图像处理、大数据。

Analysis of key disassembly problems based on embedded smart meter

LIU Jinshuo1,WANG Xiebing1,ZHEN Wen2,DENG Juan3,CHEN Xin1   

  1. 1. School of Computer, Wuhan University, Wuhan Hubei 430072, China;
    2. School of Urban Design, Wuhan University, Wuhan Hubei 430072, China;
    3. International School of Software, Wuhan University, Wuhan Hubei 430072, China
  • Received:2014-06-30 Revised:2014-08-01 Online:2014-12-01 Published:2014-12-31
  • Contact: WANG Xiebing

摘要:

电力企业在将反汇编技术应用于嵌入式智能电表软件一致性检测模型时出现了因不同硬件而产生差异的字节序问题和程序运行时的嵌入式设备内存受限问题,从而影响了模型整体的性能。针对这两个关键问题进行分析,结合嵌入式智能电表内部特征和硬件体系架构理论的深层探讨,依次提出了目标代码双逆置预处理算法(CDIPA)和分段反汇编算法(SDA)。对原代码使用目标代码双逆置预处理算法得到调整字节顺序的代码,分别将原代码和调整代码反汇编获得两种待测结果,结合硬件信息分析结果并以匹配度高的指令作为最终结果从而解决了字节序问题;分段反汇编算法通过调整反汇编输入规模并分次运行的方法解决设备内存受限问题。实验结果表明将这两种算法用于给定的电表设备,可以有效解决上述关键问题,同时算法也表现出良好的健壮性和可移植性。

Abstract:

Two key problems, endianness and memory capacity limit appear to be obstacles when electric enterprises implement a function consistency model for embedded smart meter software via disassembly technique, thus affecting the overall performance of the model. To solve these problems, a in-depth analysis was conducted combined with internal features of embedded smart meter and hardware architecture theory. Two algorithms named Code Double Inverse Preprocessing Algorithm (CDIPA) and Segmented Disassembling Algorithm (SDA) were proposed. CIDPA was used to generate adjusted binary code, together with raw binary as two inputs of disassembly. Thus endianness problem was solved by choosing the result more adaptable to hardware environment. SDA was adopted to decrease size of input binary so as to disassemble more times in limited memory. The experimental results show that CDIPA and SDA can effectively resolve the problems mentioned above and show up favorable robustness and portability.

中图分类号: