Abstract
Memory errors can cause not only program malfunctions but also even unexpected system halt. Though a programmer checks memory errors, some memory errors with low occurrence frequency are missed to detect. In this paper, we propose a method for effectively detecting such memory errors using instruction transition diagrams through analyzing assembly codes obtained by disassembling an executable file. Out of various memory errors, local memory return errors, null pointer access errors and uninitialized pointer access errors are targeted for detection. When applying the proposed method to various programs including well-known open source programs such as Apache web server and PHP script interpreter, some potential memory errors are detected.
메모리 사용에 관련한 오류는 해당 프로그램뿐 아니라 시스템의 오작동을 유발할 수 있다. 특히 발생 빈도가 매우 낮은 일부 메모리 오류의 경우 제대로 된 동작 테스트를 할 수 없어, 오류에 대한 파악 및 수정이 힘들다. 이에 본 논문에서는 실행 프로그램을 역어셈블(Dis-Assemble)하여 만들어진 어셈블리어 코드를 구문 분석하여 명령어 전이도를 도출하고 이에 기반을 두어 메모리 사용 오류 가능성을 검출하는 방법을 제안하였다. 몇 가지 프로그램을 검사대상으로 선정하여 Local Memory Return Error, Null Pointer Access Error, Uninitialized Pointer Access Error를 검출하였으며 그 중 오픈 소스 프로젝트(Open Source Project)인 아파치 웹 서버와 PHP 스크립트 해석기에서도 메모리 사용 오류의 가능성이 있는 코드가 검출되었다.