JP2009199529A - Information equipment, program and method for preventing execution of unauthorized program code - Google Patents
Information equipment, program and method for preventing execution of unauthorized program code Download PDFInfo
- Publication number
- JP2009199529A JP2009199529A JP2008043003A JP2008043003A JP2009199529A JP 2009199529 A JP2009199529 A JP 2009199529A JP 2008043003 A JP2008043003 A JP 2008043003A JP 2008043003 A JP2008043003 A JP 2008043003A JP 2009199529 A JP2009199529 A JP 2009199529A
- Authority
- JP
- Japan
- Prior art keywords
- program code
- return address
- address
- memory
- acquired
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims description 36
- 238000012545 processing Methods 0.000 claims abstract description 36
- 230000006870 function Effects 0.000 claims description 77
- 238000001514 detection method Methods 0.000 claims description 19
- 230000002265 prevention Effects 0.000 claims description 2
- 230000008569 process Effects 0.000 description 24
- 238000010586 diagram Methods 0.000 description 20
- 238000004891 communication Methods 0.000 description 6
- 230000004048 modification Effects 0.000 description 3
- 238000012986 modification Methods 0.000 description 3
- 238000003491 array Methods 0.000 description 2
- 230000007246 mechanism Effects 0.000 description 2
- 238000003780 insertion Methods 0.000 description 1
- 230000037431 insertion Effects 0.000 description 1
- 239000004973 liquid crystal related substance Substances 0.000 description 1
- 239000004065 semiconductor Substances 0.000 description 1
- 230000007704 transition Effects 0.000 description 1
Images
Landscapes
- Storage Device Security (AREA)
Abstract
Description
本発明は、情報機器、プログラム及び不正なプログラムコードの実行防止方法に関する。 The present invention relates to an information device, a program, and an illegal program code execution prevention method.
一般的に、PC(Personal Computer)やWS(Work Station)等の情報機器では、CPU(Central Processing Unit)などの制御部がRAM(Random Access Memory)等の記憶部の作業領域に展開されたプログラムコードを順次実行することで、各種データ処理を実行している。近年、上記情報機器においては、悪意のあるユーザによりプログラムコードの実行時に不正な操作が行われることで、データの盗みだしや改竄などの不正アクセスが発生している。 Generally, in an information device such as a PC (Personal Computer) or WS (Work Station), a program in which a control unit such as a CPU (Central Processing Unit) is developed in a work area of a storage unit such as a RAM (Random Access Memory). Various data processing is executed by sequentially executing the code. In recent years, unauthorized access such as data stealing or tampering has occurred in the above information devices due to malicious operations being performed by malicious users when executing program codes.
通常、情報機器が管理するデータにはアクセス権限が設定されている。従って、データへのアクセス権限がなければ、不正アクセスが行われることはない。しかしながら、データへのアクセス権限がある通常のプログラムコードを利用し、不正な操作が実行された場合は、不正アクセスが可能となる。上述したプログラムコードを利用して不正アクセスを可能とする手法としては、プログラムコードの実行時のデータをRAM等に確保された所定領域からオーバーフローさせる、いわゆるバッファオーバーフローを用いた手法が知られている。 Usually, access authority is set for data managed by an information device. Therefore, unauthorized access will not be performed if there is no access right to the data. However, unauthorized access is possible when an unauthorized operation is performed using normal program code that has the authority to access data. As a technique for enabling unauthorized access using the program code described above, a technique using a so-called buffer overflow is known in which data at the time of execution of the program code is overflowed from a predetermined area secured in a RAM or the like. .
ここで、バッファオーバーフローを用いた不正アクセスについて、正常にプログラムコードが実行された場合と、プログラムコードの実行時に不正が行われた場合と、を比較して詳細に説明する。 Here, the illegal access using the buffer overflow will be described in detail by comparing the case where the program code is executed normally and the case where the program code is executed illegally.
先ず、図11、図12を参照して正常にプログラムコードが実行された場合を説明する。図11は、プログラムコードのソースコードを例示する概念図であり、図12は、プログラムコード実行時におけるスタック領域の概要を例示する概念図である。 First, a case where the program code is executed normally will be described with reference to FIGS. FIG. 11 is a conceptual diagram illustrating the source code of the program code. FIG. 12 is a conceptual diagram illustrating the outline of the stack area when the program code is executed.
図11に例示されたソースコードによるプログラムコードは、main()関数から開始され、当該main()関数の中でstrcpy_helloworld()関数を呼び出している。このプログラムコードでは、strcpy_helloworld()関数の中で画面などに表示する「hello!」という文字列を用意し、main()関数のprintf()関数でそれを表示させている。関数とは、所定の機能をモジュール化してまとめたサブルーチンやサブプログラムなどであり、メインとなるプログラム内で随時呼び出すことができる。 The program code by the source code illustrated in FIG. 11 starts from the main () function, and calls the strcpy_helloworld () function in the main () function. In this program code, the character string “hello!” To be displayed on the screen or the like is prepared in the strcpy_helloworld () function, and is displayed by the printf () function of the main () function. A function is a subroutine, subprogram, or the like obtained by modularizing predetermined functions, and can be called at any time in a main program.
上記プログラムコードの実行時のデータは、RAM等に確保されたスタック領域に格納される。このスタック領域では、後入れ先出し (LIFO: Last In First Out; FILO: First In Last Out) 構造でデータが格納される。具体的には、図12に示すように、上から下に向かって順次確保された領域へプログラムコードの実行時のデータが格納される。 Data at the time of execution of the program code is stored in a stack area secured in a RAM or the like. In this stack area, data is stored in a last-in-first-out (LIFO) structure. Specifically, as shown in FIG. 12, the data at the time of execution of the program code is stored in an area sequentially secured from the top to the bottom.
例えば、図11に例示したソースコードによるプログラムコードの実行時には、main()関数を処理した際に、ReturnAddress1、ebp Backup、char Buf[8]などが1つのスタックフレームとして格納される。次いで、main()関数の中でstrcpy_helloworld()関数が呼び出された際に、ReturnAddress2、ebp Backup2、int iなどが一つのスタックフレームとして格納される。 For example, when executing the program code by the source code illustrated in FIG. 11, ReturnAddress1, ebp Backup, char Buf [8], etc. are stored as one stack frame when the main () function is processed. Next, when the strcpy_helloworld () function is called in the main () function, ReturnAddress2, ebp Backup2, inti, and the like are stored as one stack frame.
ReturnAddressは、プログラムの終了時に戻るべきアドレス値や、関数などによりサブプログラムが呼び出された場合の当該サブプログラム終了時に戻るべきアドレス値を示す。このReturnAddressは、プログラムの実行直後や関数などによりサブプログラムが呼び出された直後に、CPUにより自動的にスタック領域へ格納される。 ReturnAddress indicates an address value to be returned at the end of the program, or an address value to be returned at the end of the subprogram when the subprogram is called by a function or the like. This ReturnAddress is automatically stored in the stack area by the CPU immediately after the execution of the program or immediately after the subprogram is called by a function or the like.
ebpは、CPUのレジスタの一種であり、現在使用している一時的なメモリ領域のアドレスの直前を示す。図12の例では、char Buf[8]、int iの前のアドレスであり、スタックフレームのReturnAddressが該当する。従って、スタックフレームにおいて、上記レジスタ値をebp Backupとしてバックアップすることで、当該スタックフレーム内の一領域を一時的なデータ(変数や配列等)を格納するメモリ領域として簡単に使用することが可能となる。 ebp is a kind of register of the CPU and indicates immediately before the address of the temporary memory area currently used. In the example of FIG. 12, this is the address before char Buf [8] and int i and corresponds to the ReturnAddress of the stack frame. Therefore, by backing up the register value as ebp Backup in the stack frame, it is possible to easily use one area in the stack frame as a memory area for storing temporary data (variables, arrays, etc.). Become.
char Buf[8]は、main()関数で使用される配列であるBufを格納する。このBufは、char型の変数(1バイト)を8個格納する配列であり、8バイト分のデータが格納可能となっている。int iは、strcpy_helloworld()関数で使用されるint型の変数であるiを格納する。 char Buf [8] stores Buf which is an array used in the main () function. This Buf is an array for storing eight char type variables (1 byte), and can store 8 bytes of data. int i stores i, which is an int type variable used in the strcpy_helloworld () function.
従って、上記プログラムコードの実行により、スタック領域では、main()関数のスタックフレームが確保され、strcpy_helloworld()関数のスタックフレームが確保される。次いで、int iの値が順次インクリメントされて、「hello!」という6バイト分の文字列がchar Buf[8]に格納される。次いで、strcpy_helloworld()関数の終了により、ReturnAddress2が読み出されてmain()関数へ復帰され、main()関数の終了により、ReturnAddress1が読み出されてプログラムは正常終了する。 Therefore, by executing the program code, a stack frame for the main () function is secured in the stack area, and a stack frame for the strcpy_helloworld () function is secured. Next, the value of int i is sequentially incremented, and a 6-byte character string “hello!” Is stored in char Buf [8]. Next, when the strcpy_helloworld () function ends, ReturnAddress2 is read and returned to the main () function, and when the main () function ends, ReturnAddress1 is read and the program ends normally.
次に、図13、図14を参照してプログラムコードの実行時に不正が行われた場合を説明する。図13は、プログラムコードのソースコードを例示する概念図であり、図14は、プログラムコード実行時におけるスタック領域の概要を例示する概念図である。 Next, a case where fraud is performed during the execution of the program code will be described with reference to FIGS. FIG. 13 is a conceptual diagram illustrating the source code of the program code. FIG. 14 is a conceptual diagram illustrating the outline of the stack area when the program code is executed.
図13に例示されたソースコードによるプログラムコードは、前述した図11と比較すればわかるとおり、配列bufへ「Hello World」という12バイト分(11文字+文字列終端)のデータを書き込んでいる。 The program code by the source code illustrated in FIG. 13 has data of 12 bytes (11 characters + character string end) of “Hello World” written in the array buf, as can be seen from comparison with FIG. 11 described above.
図14に示すように、スタック領域では、配列bufを格納する領域として8バイト分の領域が確保されている。従って、strcpy_helloworld()関数が実行された際には、確保されているサイズ以上のデータが書き込まれることとなる。このように、メモリに確保されているサイズ以上のデータが書き込まれることをバッファオーバーフローという。また、このバッファオーバーフローがスタック領域で起きる場合をスタックベースのバッファオーバーフローという。 As shown in FIG. 14, in the stack area, an area of 8 bytes is secured as an area for storing the array buf. Therefore, when the strcpy_helloworld () function is executed, data larger than the secured size is written. In this way, writing of data larger than the size secured in the memory is called buffer overflow. The case where this buffer overflow occurs in the stack area is called a stack-based buffer overflow.
図14に例示したスタック領域おいて、領域の確保は上から下に向かって順次行われ、その確保された領域へのデータの書き込みは下から上に向かって行われる。従って、ReturnAddress1、ebp Backupはstrcpy_helloworld()関数が実行された際に、「Hello World」という12バイト分のデータにより不正に上書き(overwrite)される。上述した上書きにより、ReturnAddress1の内容が実行可能なプログラムコードが置いてあるアドレスに書き換えられた場合は、main()関数の終了によりReturnAddress1が読み出され、その書き換えられたプログラムコードが実行される。 In the stack area illustrated in FIG. 14, the areas are sequentially reserved from the top to the bottom, and the data writing to the reserved areas is performed from the bottom to the top. Therefore, ReturnAddress1 and ebp Backup are overwritten by 12 bytes of data “Hello World” when the strcpy_helloworld () function is executed. When the contents of ReturnAddress1 are rewritten to the address where the executable program code is placed by the above-described overwriting, ReturnAddress1 is read by the end of the main () function, and the rewritten program code is executed.
図13に例示したソースコードでは、「Hello World」という予め定義された文字列によりオーバーフローとなっている。しかしながら、実際には、メールサーバやWebサーバ等の通信ポートで受信されたデータや、コンソールやファイルから入力されたデータなどが配列bufに格納される場合もある。このような場合は、悪意のあるユーザにより通信、コンソール入力、ファイル入力などを介して任意のプログラムコードが実行され、データの盗みだしや改竄などの不正アクセスが発生する。 In the source code illustrated in FIG. 13, an overflow is caused by a predefined character string “Hello World”. However, in practice, data received at a communication port such as a mail server or a Web server, data input from a console or a file, and the like may be stored in the array buf. In such a case, an arbitrary program code is executed by a malicious user via communication, console input, file input, etc., and unauthorized access such as data stealing or falsification occurs.
上述した不正アクセスを防止するための有用な技術としては、特許文献1、2がある。特許文献1には、CPUが有するデバッグ機能を使用してプログラムの流れを随時チェックし、不正アクセスを防止することが開示されている。具体的には、プログラムコードにおける実行フローの妥当性をチェックし、妥当でない実行フローに遷移した場合、プログラムコードが攻撃を受けたものとして、その実行を停止もしくは修正する。また、特許文献2には、プログラムコードに随時バッファオーバーフロー検出のプログラムコードを挿入することが開示されている。
しかしながら、上記従来技術では、上述したバッファオーバーフローに関する不正アクセスの防止を十分に行うことができなかった。 However, the above prior art cannot sufficiently prevent the unauthorized access related to the buffer overflow described above.
例えば、特許文献1では、実行フローの妥当性を定義する必要があるが、その定義は非常に難しい。不正なプログラムコードの実行による場合と正常なプログラムコードによる場合との差異を区別することは困難である。このため、不正アクセスを確実に防止するには十分ではなかった。さらに、この特許文献1に記載の技術を実装するには、CPUのデバック機能に依存する必要があり、パフォーマンスの低下を招く虞があった。
For example, in
また、特許文献2では、防御対象となるプログラムコードのソースコードが必要となる。従って、プログラムコードの開発元(提供元)が不正検出用のプログラムコードを挿入しなければならず、実質的に開発元が提供することでしか実施できない。
Moreover, in
本発明の課題は、上記従来技術の問題に鑑みてなされたものであり、バッファオーバーフローに関する不正アクセスを確実且つ容易に防止する技術を提供することである。 An object of the present invention has been made in view of the above-described problems of the prior art, and is to provide a technique for reliably and easily preventing unauthorized access related to buffer overflow.
上記課題を解決するために、請求項1に記載の発明は、メモリに展開された各プログラムコードと中央制御部との協働によりデータ処理を行う情報機器であって、
前記いずれかのプログラムコードの呼び出し時を検出する検出手段と、
前記検出手段により検出されたプログラムコードの呼び出し時に、前記メモリに展開された各プログラムコードのリターンアドレスを順次取得するリターンアドレス取得手段と、
前記検出手段により検出されたプログラムコードの呼び出し時に、前記リターンアドレス取得手段により順次取得されたリターンアドレスが示すアドレスの属性情報を取得する属性取得手段と、
前記検出手段により検出されたプログラムコードの呼び出し時に、前記属性取得手段により取得された各リターンアドレスが示すアドレスの属性情報に基づいて前記データ処理を停止させる停止手段と、
を備える。
In order to solve the above-mentioned problem, the invention according to
Detecting means for detecting when the program code is called;
Return address acquisition means for sequentially acquiring the return address of each program code expanded in the memory at the time of calling the program code detected by the detection means;
Attribute acquisition means for acquiring attribute information of addresses indicated by return addresses sequentially acquired by the return address acquisition means when calling the program code detected by the detection means;
Stop means for stopping the data processing based on attribute information of an address indicated by each return address acquired by the attribute acquisition means when calling the program code detected by the detection means;
Is provided.
請求項2に記載の発明は、請求項1に記載の発明において、前記メモリは、各プログラムコードのリターンアドレスを格納するスタック領域を備え、
前記リターンアドレス取得手段は、前記スタック領域に格納されたリターンアドレスをトレースして取得する。
The invention according to
The return address acquisition means traces and acquires the return address stored in the stack area.
請求項3に記載の発明は、請求項1又は2に記載の発明において、前記停止手段は、前記属性取得手段により取得された各リターンアドレスが示すアドレスの属性情報が、プログラムコードを格納するコード領域を示す情報でない場合に、前記データ処理を停止させる。 According to a third aspect of the present invention, in the first or second aspect of the present invention, the stop means is a code in which attribute information of an address indicated by each return address acquired by the attribute acquisition means stores a program code. If it is not information indicating an area, the data processing is stopped.
請求項4に記載の発明は、請求項1〜3のいずれか一項に記載の発明において、前記停止手段は、前記属性取得手段により取得された各リターンアドレスが示すアドレスの属性情報が、データの書き込みが許可された領域を示す情報である場合に、前記データ処理を停止させる。 According to a fourth aspect of the present invention, in the invention according to any one of the first to third aspects of the present invention, the stop means includes attribute information of an address indicated by each return address acquired by the attribute acquisition means. The data processing is stopped when the information indicates an area in which writing of the file is permitted.
請求項5に記載の発明は、メモリに展開された各プログラムコードを実行するコンピュータを、
前記いずれかのプログラムコードの呼び出し時を検出する検出手段、
前記検出手段により検出されたプログラムコードの呼び出し時に、前記メモリに展開された各プログラムコードのリターンアドレスを順次取得するリターンアドレス取得手段、
前記検出手段により検出されたプログラムコードの呼び出し時に、前記リターンアドレス取得手段により順次取得されたリターンアドレスが示すアドレスの属性情報を取得する属性取得手段、
前記検出手段により検出されたプログラムコードの呼び出し時に、前記属性取得手段により取得された各リターンアドレスが示すアドレスの属性情報に基づいて前記各プログラムコードによるデータ処理を停止させる停止手段、
として機能させる。
According to a fifth aspect of the present invention, there is provided a computer for executing each program code expanded in a memory.
Detecting means for detecting when the program code is called,
Return address acquisition means for sequentially acquiring the return address of each program code expanded in the memory when calling the program code detected by the detection means;
Attribute acquisition means for acquiring attribute information of addresses indicated by return addresses sequentially acquired by the return address acquisition means when calling the program code detected by the detection means;
Stop means for stopping data processing by each program code based on attribute information of an address indicated by each return address acquired by the attribute acquisition means when calling the program code detected by the detection means;
To function as.
請求項6に記載の発明は、メモリに展開された各プログラムコードを実行するコンピュータにおける不正なプログラムコードの実行防止方法であって、
前記いずれかのプログラムコードの呼び出し時を検出し、当該検出されたプログラムコードの呼び出し時において、前記メモリに展開された各プログラムコードのリターンアドレスを順次取得し、当該順次取得されたリターンアドレスが示すアドレスの属性情報を取得し、当該取得された各リターンアドレスが示すアドレスの属性情報に基づいて前記各プログラムコードによるデータ処理を停止させる。
The invention described in
When any one of the program codes is called, the return address of each program code developed in the memory is sequentially obtained when the detected program code is called, and the sequentially obtained return address indicates Address attribute information is acquired, and data processing by each program code is stopped based on the address attribute information indicated by each acquired return address.
本発明によれば、バッファオーバーフローに関する不正アクセスを確実且つ容易に防止することが可能となる。 According to the present invention, it is possible to reliably and easily prevent unauthorized access related to buffer overflow.
以下、本発明の実施の形態について図を参照して説明するが、この発明の範囲は以下の実施の形態に限定されない。 Hereinafter, embodiments of the present invention will be described with reference to the drawings. However, the scope of the present invention is not limited to the following embodiments.
先ず、本実施の形態に係る情報機器の構成について、図1、図2を参照して説明する。図1は、情報機器1の機能的構成を模式的に示すブロック図である。図2は、RAM30のスタック領域を例示する概念図である。
First, the configuration of the information device according to the present embodiment will be described with reference to FIGS. FIG. 1 is a block diagram schematically showing a functional configuration of the
図1に示すように、情報機器1は、CPU10、記憶部20、RAM30、操作部40、表示部50、I/F部60を有する。上記情報機器1の各部はバス70により電気的に接続されている。具体的には、情報機器1は、PC、WS、PDA(Personal Digital Assistant)、携帯電話などであってよい。
As illustrated in FIG. 1, the
CPU10は、情報機器1の動作を中央制御する。具体的には、CPU10は、記憶部20に記憶されたプログラムコードや各種データをRAM30の作業領域に展開し、当該RAM30に展開されたデータとの協働により各部へ制御信号を出力することで、上記中央制御を行う。
The
記憶部20は、プログラムコードや各種設定情報などのデータをCPU10から読み書き可能に記憶する。例えば、記憶部20は、HDD(Hard Disk Drive)や半導体メモリなどであってよい。また、記憶部20は、上記データをROM(Read Only Memory)などに記憶する構成であってもよい。なお、記憶部20が記憶するプログラムコードとしては、OS(Operating System)などの基本的なソフトウエアの他、ベンダーが提供した各種アプリケーションプログラム、後述する処理に係るプログラムなどが含まれる。
The
RAM30には、プログラムコードの実行時のデータを格納するスタック領域が確保される。具体的には、図2に示すようなスタック領域がRAM30の所定領域に確保される。このスタック領域では、スタックフレームごとにデータが格納される。一つのスタックフレームには、ReturnAddress、ebp Backup、プログラムコードの実行時に一時的に使われるデータ(変数や配列等)などのデータが格納される。
In the
ReturnAddressはプログラムコードの戻り先アドレスである。ebp Backupは一つ前のスタックフレームのebp Backupを示す。ebp Backupの直前にはReturnAddressがあるので、ebp Backupを辿ることでReturnAddressを順次トレースして取得することが可能となる。 ReturnAddress is the return address of the program code. ebp Backup indicates the previous stack frame ebp Backup. Since there is ReturnAddress immediately before ebp Backup, ReturnAddress can be traced and acquired sequentially by following ebp Backup.
上記スタックフレームは、各プログラムコードが順次実行された場合に、そのプログラムコードの実行に伴って順次確保される。例えば、メインとなるプログラムコードが実行され、そのプログラムコード内でサブルーチンに関するプログラムコードが呼び出され、更に別のプログラムコードが呼び出された場合などは、図示したとおり、スタックフレームFr1〜Fr3の順に各プログラムコードに係る領域が確保される。この各プログラムコードに係る処理が終了した際には、スタックフレームFr1〜Fr3のReturnAddressが読み出されることで、メインとなるプログラムコードへの復帰や、プログラム終了後の処理が行われる。 When each program code is sequentially executed, the stack frame is secured sequentially as the program code is executed. For example, when a main program code is executed, a program code related to a subroutine is called in the program code, and another program code is called, the respective programs are sequentially arranged in the stack frames Fr1 to Fr3 as shown in the figure. An area related to the code is secured. When the processing related to each program code is completed, the return address of the stack frames Fr1 to Fr3 is read, so that the return to the main program code and the processing after the program end are performed.
操作部40は、ユーザからの操作入力を受け付け、当該操作に応じた操作信号をCPU10へ出力する。例えば、操作部40は、文字入力キー、数字入力キー、その他各種機能に対応付けられたキーを備えたキーボード、マウス等のポインティングデバイスなどであってよい。
The
表示部50は、CPU10から出力された表示制御信号に基づいた画像を表示画面に表示する。例えば、表示部50は、CRT(Cathode Ray Tube)、LCD(Liquid Crystal Display)などであってよい。
The
I/F部60は、データ通信用IC(Integrated Circuit)や接続コネクタなどを備え(いずれも図示しない)、外部機器や通信ネットワークと通信可能に接続する。例えば、I/F部60は、USB(Universal Serial Bus)通信ポートや、LAN(Local Area Network)、WAN(Wide Area Network)、インターネットなどと接続するネットワークインターフェイスカード(NIC:Network Interface Card)であってよい。
The I /
次に、情報機器1のCPU10の制御の下で実行される処理について、図3〜図10を参照して詳細に説明する。
Next, processing executed under the control of the
図3は、情報機器1のフック処理を示すフローチャートである。図4〜図6は、関数を動的に生成するためのソースコードを例示する概念図である。図7は、通常の関数呼び出しを例示する概念図である。図8は、フックされた関数呼び出しを例示する概念図である。図9は、情報機器1のスタックレイアウトチェック処理を示すフローチャートである。図10は、情報機器1のスタックレイアウトチェック処理の変形例を示すフローチャートである。
FIG. 3 is a flowchart showing hook processing of the
情報機器1において、不正なプログラムコードの実行を防止するためには、当該不正なプログラムコードの実行に必要なAPI、ライブラリ関数、システムコールなどの検出、すなわち、サブプログラムコードの呼び出しを検出し、不正なプログラムコードの実行の有無をチェックする処理を挿入する必要がある。本実施の形態では、このサブプログラムコードの呼び出し検出と、不正のチェックを行う処理の挿入を、フック(Hook)を用いて実現している。
In the
フックは、プログラム中の特定の箇所に、利用者が独自の処理を追加できるようにする仕組みである。すなわち、フックされる側のプログラムコードを作成したプログラマーと、フックする側のプログラムコードを作成したプログラマーと、が同じプログラマーでなく、互いのプログラムコードに関するソースコードが同一のプログラマーにより作成されない場合に利用される仕組みである。従って、ベンダーが提供するOSや関数の機能変更や、任意の処理の追加時に使用される。 A hook is a mechanism that allows a user to add a unique process to a specific part of a program. In other words, it is used when the programmer who created the hooked program code and the programmer who created the hooked program code are not the same programmer, and the source code related to each other's program code is not created by the same programmer It is a mechanism to be done. Therefore, it is used when changing the function of an OS or function provided by a vendor or adding arbitrary processing.
なお、フックは、チェック対象となる関数などのサブプログラムをプログラマー自身が修正可能である場合であっても用いてよい。但し、プログラマー自身がサブプログラムを修正可能であり、当該サブプログラムが実行された際に不正のチェックを行うように修正した場合は、フックを使用する必要はなくなるとともに、既存の関数やライブラリをより安全なものとして実装することが可能となる。 Note that the hook may be used even when the programmer can modify a subprogram such as a function to be checked. However, if the programmer himself can modify the subprogram and corrects it so that an illegal check is performed when the subprogram is executed, it is not necessary to use a hook, and existing functions and libraries can be used more effectively. It can be implemented as safe.
先ず、APIフック(ライブラリ関数をフック)して不正なプログラムコードの実行の有無をチェックする場合について図3〜図9を参照して説明する。 First, a case where an API hook (a library function is hooked) to check whether or not an illegal program code is executed will be described with reference to FIGS.
以下では、ベンダーが用意したWinExec()というライブラリ関数のフックを例示し、当該ライブラリ関数が呼び出された際に実行されるスタックレイアウトチェック処理を例示している。 In the following, a hook of a library function called WinExec () prepared by a vendor is exemplified, and a stack layout check process executed when the library function is called is exemplified.
図3に示すように、WinExec()というライブラリ関数が呼び出されることで、フック処理が開始されると、WinExec()の関数の存在するアドレスが取得される(ステップS1)。この関数のアドレス取得は、ベンダーから提供される関数を呼び出すことで可能である。 As shown in FIG. 3, when a hook function is started by calling a library function called WinExec (), an address where the function of WinExec () exists is acquired (step S1). The address of this function can be obtained by calling a function provided by the vendor.
次いで、APIの実行にフックをかける小さな関数(一時的な関数)が動的に生成される(ステップS2)。この動的に生成される関数とは、後述するスタックレイアウトチェック処理を呼び出す関数である。 Next, a small function (temporary function) that hooks API execution is dynamically generated (step S2). This dynamically generated function is a function that calls a stack layout check process described later.
次いで、WinExec()関数の先頭コードの書き換えが行われ、ステップS2で生成された関数にジャンプするように変更される(ステップS3)。 Next, the top code of the WinExec () function is rewritten and changed so as to jump to the function generated in step S2 (step S3).
上述したAPIフック用の関数を動的に生成するためのソースコードを図4〜図6に例示する。図4に示すように、ソースコードC1は、フックターゲットのコードを定義する。図5に示すように、ソースコードC2は、実際に生成されるコードのテンプレートを出力するTrampolineStdcall_CodeHook()関数である。この関数の中で、0xccccccc1とある部分では、WinExec()関数のアドレスに5バイト加算したアドレスを入力する。また、5つあるnopとある部分では、コード書き換え前のオリジナルのWinExec()関数の先頭5バイトをそのままコピーする。 Source codes for dynamically generating the function for the API hook described above are illustrated in FIGS. As shown in FIG. 4, the source code C1 defines a hook target code. As shown in FIG. 5, the source code C2 is a TrampolineStdcall_CodeHook () function that outputs a template of code that is actually generated. In this function, in the part with 0xccccccc1, an address obtained by adding 5 bytes to the address of the WinExec () function is input. In the part with 5 nop, the first 5 bytes of the original WinExec () function before code rewriting is copied as it is.
図6に示すように、ソースコードC3は、BuildTrampolineCode_CodeHook()関数である。この関数により、TrampolineStdcall_CodeHook()関数の2つの書き換えが行われる。 As shown in FIG. 6, the source code C3 is a BuildTrampolineCode_CodeHook () function. This function performs two rewrites of the TrampolineStdcall_CodeHook () function.
情報機器1では、上述したフック処理により、サブプログラムコードの呼び出しを検出し、不正のチェックを行う処理の挿入が可能となっている。通常、関数に係るサブプログラムが呼び出された場合は、図7に示すように、関数f1で呼び出された関数f2、f3や、関数f2で呼び出された関数f4がそのまま実行される。しかしながら、情報機器1では、図8に示すように、関数f1で関数f2が呼び出された場合、関数f2が呼び出される前にスタックレイアウトチェック処理を呼び出すフック関数f2aが実行される。
In the
図9に示すように、フック処理に次いで、スタックレイアウトチェック処理が開始されると、StackWolk()ライブラリの初期化が行われる(ステップS11)。StackWolk()ライブラリは、ベンダーが用意したスタックトレースを行う関数である。このStackWolk()を利用してトレース位置をインクリメント又はデクリメントすることで、スタック領域に格納されたリターンアドレスを順次取得することが可能となる。 As shown in FIG. 9, when the stack layout check process is started after the hook process, the StackWolk () library is initialized (step S11). The StackWolk () library is a stack trace function provided by the vendor. By using StackWolk () to increment or decrement the trace position, it is possible to sequentially obtain return addresses stored in the stack area.
次いで、StackWolk()が呼び出されてスタック領域のスタックフレームを順次呼び出すように、スタックが1つバックトレースされ(ステップS12)、トレース後にリターンアドレスが正しく取得できたか否かが判定される(ステップS13)。 Next, StackWolk () is called and one stack is backtraced so as to sequentially call stack frames in the stack area (step S12), and it is determined whether or not the return address has been correctly acquired after tracing (step S13). ).
ステップS13において、リターンアドレスが正しく取得できない場合は、正常終了としてチェック対象であるWinExec()の実行が続行される。これは不正アクセス以外の未知の理由などにより、スタックが破壊されており、StackWolk()が正常に動作しない場合等が該当する。なお、本実施の形態では、StackWolk()が正常に動作しない場合に正常終了しているが、このスタックトレースが失敗した場合にも、プログラムの停止や、ユーザに停止するか否かを確認するためのダイアログを表示部50へ表示してもよい。
In step S13, if the return address cannot be acquired correctly, the execution of WinExec () that is the check target is continued as normal termination. This is the case when the stack is destroyed due to unknown reasons other than unauthorized access, and StackWolk () does not operate normally. In this embodiment, StackWolk () terminates normally when it does not operate normally, but even if this stack trace fails, it is confirmed whether or not to stop the program or to the user. A dialog for this purpose may be displayed on the
ステップS13において、リターンアドレスが正しく取得できた場合は、取得されたリターンアドレスが示すメモリ領域の属性情報が取得される(ステップS14)。この属性情報は、アドレスを指定することで当該アドレスの属性情報を出力する関数などが用いて取得される。 In step S13, if the return address can be correctly acquired, attribute information of the memory area indicated by the acquired return address is acquired (step S14). This attribute information is acquired using a function that outputs attribute information of the address by designating the address.
次いで、ステップS13により取得された属性情報に基づいて、リターンアドレスが示すメモリ領域がコード領域であるか否かが判定される(ステップS15)。コード領域とは、プログラムコードが格納されるメモリ領域である。このステップS15において、コード領域であると判定された場合は、リターンアドレスが示すメモリ領域が書き込みが不可であるか否か(又は、書き込みが許可された領域であるか否か)が判定される(ステップS16)。 Next, based on the attribute information acquired in step S13, it is determined whether or not the memory area indicated by the return address is a code area (step S15). The code area is a memory area in which program code is stored. If it is determined in step S15 that the area is a code area, it is determined whether or not the memory area indicated by the return address is not writable (or whether or not writing is permitted). (Step S16).
ステップS16において、書き込みが不可な領域であると判定された場合は、未チェックのリターンアドレスが存在するか否かが判定され(ステップS17)、未チェックのリターンアドレスが存在する場合はステップS12へ戻って、次のリターンアドレスがトレースされる。また、ステップS17において、未チェックのリターンアドレスが存在しない場合は正常終了としてチェック対象であるWinExec()が実行される。 If it is determined in step S16 that the area is not writable, it is determined whether an unchecked return address exists (step S17). If an unchecked return address exists, the process proceeds to step S12. Returning, the next return address is traced. In step S17, if there is no unchecked return address, WinExec () to be checked is executed as a normal end.
ステップS15においてコード領域でない(データ領域である)と判定された場合、及び、ステップS16において書き込みが不可でない領域(書き込みが許可された領域)と判定された場合は、不正アクセス等の攻撃を検出し、不正なプログラムコードの実行を防止するためにデータ処理を一時的に停止する旨のダイアログが表示部50に表示され(ステップS18)、プログラムの実行が停止される(ステップS19)。
If it is determined in step S15 that it is not a code area (data area), and if it is determined in step S16 that writing is not possible (area where writing is permitted), an attack such as unauthorized access is detected. Then, a dialog for temporarily stopping data processing is displayed on the
不正なプログラムコードなどは、データを格納するデータ領域に一旦格納された後、バッファオーバーフローを利用して実行権限を有するプログラムコードによりデータ領域から実行される。従って、情報機器1では、ステップS15において、リターンアドレスが示すメモリ領域がコード領域でない(データ領域である)と判定された場合にプログラムの実行が停止されるため、不正なプログラムコードの実行を防止することが可能となる。
An illegal program code or the like is temporarily stored in a data area for storing data, and then executed from the data area by a program code having execution authority using buffer overflow. Therefore, in the
また、不正なプログラムコードなどは、データを格納するデータ領域に一旦格納される必要があるため、データの書き込みが許可された領域に存在する。従って、情報機器1では、ステップS16において、リターンアドレスが示すメモリ領域が書き込みが許可された領域であると判定された場合にプログラムの実行が停止されるため、不正なプログラムコードの実行を防止することが可能となる。
In addition, since an illegal program code or the like needs to be temporarily stored in a data area for storing data, it exists in an area where data writing is permitted. Accordingly, in the
次に、変形例として、システムコールをフックして不正なプログラムコードの実行の有無をチェックする場合について図10を参照して説明する。 Next, as a modification, a case where a system call is hooked to check whether or not an illegal program code is executed will be described with reference to FIG.
図10では、何らかのシステムコールが呼び出された際に、カーネルからユーザランドのスタックをチェックするスタックレイアウトチェック処理を例示している。なお、このスタックレイアウチェック処理では、通常のebpを用いた方法でスタックトレースを行っている。 FIG. 10 illustrates a stack layout check process for checking the userland stack from the kernel when any system call is called. In the stack layout check process, stack tracing is performed by a method using a normal ebp.
スタックレイアウトチェック処理は、システムコールを処理しているカーネル内の関数をフックすることで、当該システムコール処理の前に実行される。このように、システムコールをフックすることで、スタックレイアウトチェック処理に関するプログラムコードをカーネルモジュールとして作成することが可能となり、カーネル本体のリビルドや改造を必要としない。 The stack layout check process is executed before the system call process by hooking a function in the kernel that is processing the system call. Thus, by hooking the system call, it becomes possible to create a program code related to the stack layout check process as a kernel module, and it is not necessary to rebuild or modify the kernel body.
従って、カーネルのソースコードが未公開の場合であっても実装可能である。また、ソースコードが提供されている場合であっても、カーネルの入れ替えをする必要がなく、カーネルモジュールをインストールするだけで実装可能である。 Therefore, even if the kernel source code is not disclosed, it can be implemented. Even if source code is provided, it is not necessary to replace the kernel, and it can be implemented simply by installing a kernel module.
図10に示すように、システムコールが呼び出されることで、スタックレイアウトチェック処理が開始されると、現在のebpの値から最新のebp backupが取得される(ステップS21)。すなわち、ステップS21では、RAM30のスタック領域における現在の読み出し位置が取得される。
As shown in FIG. 10, when the stack layout check process is started by calling a system call, the latest ebp backup is acquired from the current ebp value (step S21). That is, in step S21, the current read position in the stack area of the
次いで、ebp backupからその直前にあるリターンアドレスが取得され(ステップS23)、リターンアドレスが正しく取得できたか否かが判定される(ステップS23)。ステップS23において、リターンアドレスが正しく取得できない場合は、前述したステップS13と同様に正常終了となり、呼び出されたシステムコードが実行される。 Next, the return address immediately before it is acquired from ebp backup (step S23), and it is determined whether or not the return address has been correctly acquired (step S23). In step S23, if the return address cannot be acquired correctly, the process ends normally and the called system code is executed as in step S13 described above.
ステップS23において、リターンアドレスが正しく取得できた場合は、そのリターンアドレスが含まれるスタックフレームがシグナル処理用のスタックフレームであるか否かが判定される(ステップS24)。このスタックフレームの判定は、予め用意されたライブラリ関数(例えばlibunwind関数)の出力結果などに基づいて行われる。 In step S23, if the return address can be acquired correctly, it is determined whether or not the stack frame including the return address is a signal processing stack frame (step S24). The determination of the stack frame is performed based on an output result of a library function (for example, libunwind function) prepared in advance.
ステップS24において、スタックフレームがシグナル処理用のスタックフレームであると判定された場合は、正常終了となり、呼び出されたシステムコードが実行される。シグナル処理とは、OSの種類や設定によって異なるが、シグナル処理の場合は、プログラムの実行方法が特殊になる場合があり、スタックフレームも特殊なレイアウトになる。したがって、誤検知を避けるために、シグナル処理の場合はチェックを中断し、常に正常終了としている。 If it is determined in step S24 that the stack frame is a signal processing stack frame, the process ends normally and the called system code is executed. The signal processing differs depending on the type and setting of the OS, but in the case of signal processing, the program execution method may be special, and the stack frame also has a special layout. Therefore, in order to avoid false detection, the check is interrupted in the case of signal processing, and the normal termination is always performed.
ステップS24において、スタックフレームがシグナル処理用のスタックフレームでないと判定された場合は、前述したステップS14〜S17と同様の処理が行われる(ステップS26〜S28)。なお、ステップS28において、未チェックのリターンアドレスが存在する場合は、ebp backupから次のebp backupが取得され(ステップS29)、ステップS22へ戻って、次のリターンアドレスが取得される。 If it is determined in step S24 that the stack frame is not a signal processing stack frame, the same processing as in steps S14 to S17 described above is performed (steps S26 to S28). If there is an unchecked return address in step S28, the next ebp backup is acquired from ebp backup (step S29), and the process returns to step S22 to acquire the next return address.
また、ステップS26においてコード領域でない(データ領域である)と判定された場合、及び、ステップS27において書き込みが不可でない領域(書き込みが許可された領域)と判定された場合は、ステップS18、S19と同様に、プログラムの実行が停止される(ステップS30、S31)。 If it is determined in step S26 that it is not a code area (data area), and if it is determined in step S27 that writing is not possible (area where writing is permitted), steps S18 and S19 are performed. Similarly, the program execution is stopped (steps S30 and S31).
従って、情報機器1では、システムコールが呼び出された場合も、ステップS26において、リターンアドレスが示すメモリ領域がコード領域でない(データ領域である)と判定された場合にプログラムの実行が停止されるため、不正なプログラムコードの実行を防止することが可能となる。同様に、情報機器1では、ステップS27において、リターンアドレスが示すメモリ領域が書き込みが許可された領域であると判定された場合にプログラムの実行が停止されるため、不正なプログラムコードの実行を防止することが可能となる。
Therefore, in the
以上のように、情報機器1は、メモリ(RAM30)に展開された各プログラムコードと中央制御部(CPU10)との協働によりデータ処理を行う。また、情報機器1は、いずれかのプログラムコードの呼び出し時を検出する検出手段(CPU10、フック処理)と、検出手段により検出されたプログラムコードの呼び出し時に、メモリに展開された各プログラムコードのリターンアドレスを順次取得するリターンアドレス取得手段(CPU10、ステップS12、S22)と、検出手段により検出されたプログラムコードの呼び出し時に、リターンアドレス取得手段により順次取得されたリターンアドレスが示すアドレスの属性情報を取得する属性取得手段(CPU10、ステップS14、S25)と、検出手段により検出されたプログラムコードの呼び出し時に、属性取得手段により取得された各リターンアドレスが示すアドレスの属性情報に基づいてデータ処理を停止させる停止手段(CPU10、ステップS19、S31)と、を備える。
As described above, the
このため、情報機器1は、プログラムコードの呼び出し時において、メモリに展開された各プログラムコードのリターンアドレスを全てチェックして、データ処理の停止の有無を制御することができる。また、情報機器1は、各プログラムコードを改変する必要がない。従って、1は、バッファオーバーフローに関する不正アクセスを確実且つ容易に防止することが可能となる。
For this reason, the
なお、上述した実施の形態における記述は、一例を示すものであり、これに限定するものではない。上述した実施の形態における構成及び動作に関しては、適宜変更が可能である。 Note that the description in the above-described embodiment shows an example, and the present invention is not limited to this. The configuration and operation in the embodiment described above can be changed as appropriate.
例えば、以上の説明では、本発明に係るプログラムのコンピュータ読み取り可能な媒体として記憶部20やROMを使用した例を開示したが、この例に限定されない。その他のコンピュータ読み取り可能な媒体として、フラッシュメモリ等の不揮発性メモリ、CD-ROM等の可搬型記録媒体を適用することが可能である。また、本発明に係るプログラムのデータをI/F部60と接続する通信回線を介して提供する媒体として、キャリアウエーブ(搬送波)も本発明に適用される。
For example, in the above description, an example in which the
1 情報機器
10 CPU
20 記憶部
30 RAM
40 操作部
50 表示部
60 I/F部
70 バス
C1〜C3 ソースコード
Fr1〜Fr3 スタックフレーム
1
20
40
Claims (6)
前記いずれかのプログラムコードの呼び出し時を検出する検出手段と、
前記検出手段により検出されたプログラムコードの呼び出し時に、前記メモリに展開された各プログラムコードのリターンアドレスを順次取得するリターンアドレス取得手段と、
前記検出手段により検出されたプログラムコードの呼び出し時に、前記リターンアドレス取得手段により順次取得されたリターンアドレスが示すアドレスの属性情報を取得する属性取得手段と、
前記検出手段により検出されたプログラムコードの呼び出し時に、前記属性取得手段により取得された各リターンアドレスが示すアドレスの属性情報に基づいて前記データ処理を停止させる停止手段と、
を備える情報機器。 An information device that performs data processing in cooperation with each program code developed in a memory and a central control unit,
Detecting means for detecting when the program code is called;
Return address acquisition means for sequentially acquiring the return address of each program code expanded in the memory at the time of calling the program code detected by the detection means;
Attribute acquisition means for acquiring attribute information of addresses indicated by return addresses sequentially acquired by the return address acquisition means when calling the program code detected by the detection means;
Stop means for stopping the data processing based on attribute information of an address indicated by each return address acquired by the attribute acquisition means when calling the program code detected by the detection means;
Information equipment equipped with.
前記リターンアドレス取得手段は、前記スタック領域に格納されたリターンアドレスをトレースして取得する請求項1に記載の情報機器。 The memory includes a stack area for storing a return address of each program code,
The information device according to claim 1, wherein the return address acquisition unit traces and acquires a return address stored in the stack area.
前記いずれかのプログラムコードの呼び出し時を検出する検出手段、
前記検出手段により検出されたプログラムコードの呼び出し時に、前記メモリに展開された各プログラムコードのリターンアドレスを順次取得するリターンアドレス取得手段、
前記検出手段により検出されたプログラムコードの呼び出し時に、前記リターンアドレス取得手段により順次取得されたリターンアドレスが示すアドレスの属性情報を取得する属性取得手段、
前記検出手段により検出されたプログラムコードの呼び出し時に、前記属性取得手段により取得された各リターンアドレスが示すアドレスの属性情報に基づいて前記各プログラムコードによるデータ処理を停止させる停止手段、
として機能させるためのプログラム。 A computer that executes each program code expanded in memory
Detecting means for detecting when the program code is called,
Return address acquisition means for sequentially acquiring the return address of each program code expanded in the memory when calling the program code detected by the detection means;
Attribute acquisition means for acquiring attribute information of addresses indicated by return addresses sequentially acquired by the return address acquisition means when calling the program code detected by the detection means;
Stop means for stopping data processing by each program code based on attribute information of an address indicated by each return address acquired by the attribute acquisition means when calling the program code detected by the detection means;
Program to function as.
前記いずれかのプログラムコードの呼び出し時を検出し、当該検出されたプログラムコードの呼び出し時において、前記メモリに展開された各プログラムコードのリターンアドレスを順次取得し、当該順次取得されたリターンアドレスが示すアドレスの属性情報を取得し、当該取得された各リターンアドレスが示すアドレスの属性情報に基づいて前記各プログラムコードによるデータ処理を停止させる不正なプログラムコードの実行防止方法。 A method for preventing unauthorized execution of program code in a computer that executes each program code expanded in memory,
When any one of the program codes is called, the return address of each program code developed in the memory is sequentially obtained when the detected program code is called, and the sequentially obtained return address indicates An illegal program code execution prevention method that acquires address attribute information and stops data processing by each program code based on the address attribute information indicated by each acquired return address.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2008043003A JP2009199529A (en) | 2008-02-25 | 2008-02-25 | Information equipment, program and method for preventing execution of unauthorized program code |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2008043003A JP2009199529A (en) | 2008-02-25 | 2008-02-25 | Information equipment, program and method for preventing execution of unauthorized program code |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JP2009199529A true JP2009199529A (en) | 2009-09-03 |
Family
ID=41142927
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2008043003A Pending JP2009199529A (en) | 2008-02-25 | 2008-02-25 | Information equipment, program and method for preventing execution of unauthorized program code |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP2009199529A (en) |
Cited By (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2012077300A1 (en) | 2010-12-08 | 2012-06-14 | パナソニック株式会社 | Information processing device and information processing method |
| JP2015141718A (en) * | 2014-01-27 | 2015-08-03 | イグルー セキュリティ,インク. | Aggression detection device and method using vulnerable point of program |
| KR101741026B1 (en) * | 2010-10-29 | 2017-05-30 | 주식회사 엔씨소프트 | Method and Computer Readable Recording Medium for Detecting Malicious Module of On-Line Game |
| JP2017514260A (en) * | 2014-07-31 | 2017-06-01 | エヌイーシー ラボラトリーズ アメリカ インクNEC Laboratories America, Inc. | Transparent detection and extraction of return-oriented programming attacks |
-
2008
- 2008-02-25 JP JP2008043003A patent/JP2009199529A/en active Pending
Cited By (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| KR101741026B1 (en) * | 2010-10-29 | 2017-05-30 | 주식회사 엔씨소프트 | Method and Computer Readable Recording Medium for Detecting Malicious Module of On-Line Game |
| WO2012077300A1 (en) | 2010-12-08 | 2012-06-14 | パナソニック株式会社 | Information processing device and information processing method |
| JP5954666B2 (en) * | 2010-12-08 | 2016-07-20 | パナソニックIpマネジメント株式会社 | Information processing apparatus and information processing method |
| JP2015141718A (en) * | 2014-01-27 | 2015-08-03 | イグルー セキュリティ,インク. | Aggression detection device and method using vulnerable point of program |
| JP2017514260A (en) * | 2014-07-31 | 2017-06-01 | エヌイーシー ラボラトリーズ アメリカ インクNEC Laboratories America, Inc. | Transparent detection and extraction of return-oriented programming attacks |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| JP4572259B1 (en) | Information device, program, and illegal program code execution prevention method | |
| US10839085B1 (en) | Detection and healing of vulnerabilities in computer code | |
| JP4793733B2 (en) | High integrity firmware | |
| US5949973A (en) | Method of relocating the stack in a computer system for preventing overrate by an exploit program | |
| Han et al. | A bad dream: Subverting trusted platform module while you are sleeping | |
| JP6984710B2 (en) | Computer equipment and memory management method | |
| US6698016B1 (en) | Method for injecting code into another process | |
| EP2107489A2 (en) | Obfuscating computer program code | |
| CN110414218B (en) | Kernel detection method and device, electronic equipment and storage medium | |
| JP4927231B1 (en) | Program, information device, and unauthorized access detection method | |
| CN104881610A (en) | Method for defending hijacking attacks of virtual function tables | |
| US20090144828A1 (en) | Rapid signatures for protecting vulnerable browser configurations | |
| JP2009199529A (en) | Information equipment, program and method for preventing execution of unauthorized program code | |
| CN111881485B (en) | A Kernel Sensitive Data Integrity Protection Method Based on ARM Pointer Verification | |
| KR102066580B1 (en) | Program for injecting watermark into captured data and screen leak realisation service providing method | |
| US11256786B2 (en) | Method to secure a software code | |
| CN113139190A (en) | Program file detection method and device, electronic equipment and storage medium | |
| CN111625296B (en) | Method for protecting program by constructing code copy | |
| CN118605922A (en) | A Hook method, system and storage medium applied to iOS platform | |
| Lehniger et al. | Combination of rop defense mechanisms for better safety and security in embedded systems | |
| CN119830281B (en) | Memory vulnerability protection method, device, electronic device and storage medium | |
| CN111625824A (en) | IAST-based security test method and device, electronic device and storage medium | |
| CN119781736B (en) | Anti-cheat code binding methods, devices and program products | |
| US20240281361A1 (en) | Bintyper: type confusion bug detection for c++ program binaries | |
| CN117034278A (en) | Vulnerability detection method and device, storage medium and electronic equipment |