Comprehensive Kernel Instrumentation via Dynamic Binary Translation

被引:0
作者
Feiner, Peter [1 ]
Brown, Angela Demke [1 ]
Goel, Ashvin [1 ]
机构
[1] Univ Toronto, Toronto, ON M5S 1A1, Canada
基金
加拿大自然科学与工程研究理事会;
关键词
Design; Performance; Dynamic binary translation; operating system instrumentation; Linux; interrupts;
D O I
10.1145/2248487.2150992
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Dynamic binary translation (DBT) is a powerful technique that enables fine-grained monitoring and manipulation of an existing program binary. At the user level, it has been employed extensively to develop various analysis, bug-finding, and security tools. Such tools are currently not available for operating system (OS) binaries since no comprehensive DBT framework exists for the OS kernel. To address this problem, we have developed a DBT framework that runs as a Linux kernel module, based on the user-level DynamoRIO framework. Our approach is unique in that it controls all kernel execution, including interrupt and exception handlers and device drivers, enabling comprehensive instrumentation of the OS without imposing any overhead on user-level code. In this paper, we discuss the key challenges in designing and building an in-kernel DBT framework and how the design differs from user-space. We use our framework to build several sample instrumentations, including simple instruction counting as well as an implementation of shadow memory for the kernel. Using the shadow memory, we build a kernel stack overflow protection tool and a memory addressability checking tool. Qualitatively, the system is fast enough and stable enough to run the normal desktop workload of one of the authors for several weeks.
引用
收藏
页码:135 / 146
页数:12
相关论文
共 50 条
[31]   Register allocation algorithm of dynamic binary translation based on priority [J].
Dai T. ;
Shan Z. ;
Lu S.-B. ;
Shi Q. ;
Tan J. .
Zhejiang Daxue Xuebao (Gongxue Ban)/Journal of Zhejiang University (Engineering Science), 2016, 50 (07) :1338-1346
[32]   Dynamic Binary Translation to a Reconfigurable Target for On-the-Fly Acceleration [J].
Kinsman, Phillip ;
Nicolici, Nicola .
PROCEEDINGS OF THE 48TH ACM/EDAC/IEEE DESIGN AUTOMATION CONFERENCE (DAC), 2011, :286-287
[33]   Improve Indirect Branch Prediction with Private Cache in Dynamic Binary Translation [J].
Liao Yin ;
Jiang Haitao ;
Sun Guangzhong ;
Jin Guojie ;
Chen Guoliang .
2012 IEEE 14TH INTERNATIONAL CONFERENCE ON HIGH PERFORMANCE COMPUTING AND COMMUNICATIONS & 2012 IEEE 9TH INTERNATIONAL CONFERENCE ON EMBEDDED SOFTWARE AND SYSTEMS (HPCC-ICESS), 2012, :280-286
[34]   StarDBT: An efficient multi-platform dynamic binary translation system [J].
Wang, Cheng ;
Hu, Shiliang ;
Kim, Ho-seop ;
Nair, Sreekumar R. ;
Breternitz, Mauricio, Jr. ;
Ying, Zhiwei ;
Wu, Youfeng .
ADVANCES IN COMPUTER SYSTEMS ARCHITECTURE, PROCEEDINGS, 2007, 4697 :4-+
[35]   Processor-Tracing Guided Region Formation in Dynamic Binary Translation [J].
Hong, Ding-Yong ;
Wu, Jan Jan ;
Liu, Yu-Ping ;
Fu, Sheng-Yu ;
Hsu, Wei-Chung .
ACM TRANSACTIONS ON ARCHITECTURE AND CODE OPTIMIZATION, 2019, 15 (04)
[36]   The Implementation of Static-integrated Optimization Framework for Dynamic Binary Translation [J].
Gu, Jinghui ;
Xu, Chao ;
Lin, Ling ;
Zheng, Juyu ;
Chen, Kai ;
Guan, Haibing .
2009 INTERNATIONAL CONFERENCE ON INFORMATION TECHNOLOGY AND COMPUTER SCIENCE, VOL 1, PROCEEDINGS, 2009, :510-513
[37]   PEMU: A PIN Highly Compatible Out-of-VM Dynamic Binary Instrumentation Framework [J].
Zeng, Junyuan ;
Fu, Yangchun ;
Lin, Zhiqiang .
ACM SIGPLAN NOTICES, 2015, 50 (07) :147-160
[38]   Efficiently Parallelizing Instruction Set Simulation of Embedded Multi-Core Processors Using Region-based Just-in-Time Dynamic Binary Translation [J].
Kyle, Stephen ;
Boehm, Igor ;
Franke, Bjorn ;
Leather, Hugh ;
Topham, Nigel .
ACM SIGPLAN NOTICES, 2012, 47 (05) :21-30
[39]   Towards Efficient Dynamic Binary Translation Optimizations Based on RISC Architectural Features [J].
Xie, WenBing ;
Tang, DaGuo ;
Qi, FengBin ;
Chai, ZhiLei ;
Luo, QiaoLing ;
Lin, Yuan .
JOURNAL OF CIRCUITS SYSTEMS AND COMPUTERS, 2024, 33 (06)
[40]   Software Transparent Dynamic Binary Translation for Coarse-Grain Reconfigurable Architectures [J].
Watkins, Matthew A. ;
Nowatzki, Tony ;
Carno, Anthony .
PROCEEDINGS OF THE 2016 IEEE INTERNATIONAL SYMPOSIUM ON HIGH-PERFORMANCE COMPUTER ARCHITECTURE (HPCA-22), 2016, :138-150