JP2020013385A - Information processing apparatus, patch application confirming system, patch application confirming method, and patch application confirming program - Google Patents

Information processing apparatus, patch application confirming system, patch application confirming method, and patch application confirming program Download PDF

Info

Publication number
JP2020013385A
JP2020013385A JP2018135851A JP2018135851A JP2020013385A JP 2020013385 A JP2020013385 A JP 2020013385A JP 2018135851 A JP2018135851 A JP 2018135851A JP 2018135851 A JP2018135851 A JP 2018135851A JP 2020013385 A JP2020013385 A JP 2020013385A
Authority
JP
Japan
Prior art keywords
patch
instruction
correction
instruction type
type
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.)
Granted
Application number
JP2018135851A
Other languages
Japanese (ja)
Other versions
JP7075011B2 (en
Inventor
佳宏 安田
Yoshihiro Yasuda
佳宏 安田
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fujitsu Ltd
Original Assignee
Fujitsu Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP2018135851A priority Critical patent/JP7075011B2/en
Publication of JP2020013385A publication Critical patent/JP2020013385A/en
Application granted granted Critical
Publication of JP7075011B2 publication Critical patent/JP7075011B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Stored Programmes (AREA)

Abstract

To make it possible to determine whether or not a patch has been applied.SOLUTION: An information processing apparatus 10 stores a source file 2 which is a target of application of a patch for changing a part of instruction string to a correction instruction string 1a. The information processing apparatus 10 generates patch instruction kind information 3 indicating an instruction kind of each instruction in the correction instruction string 1a based on the patch file 1 including the correction instruction string 1a. Next, the information processing apparatus 10 generates source instruction kind information 4 indicating an instruction kind of each instruction in the source file 2. Further, the information processing apparatus 10, based on the patch instruction kind information 3 and the source instruction kind information 4, extracts, from the source file 2, a kind-matched instruction string 2a having the same arraying order of the instruction kind as that of the correct instruction string 1a. The information processing apparatus 10 determines, based on description contents of the kind-matched instruction string 2a and the correction instruction string 1a excluding a variable name and a function name, whether the patch has been already applied to the source file 2.SELECTED DRAWING: Figure 1

Description

本発明は、情報処理装置、パッチ適用確認システム、パッチ適用確認方法、およびパッチ適用確認プログラムに関する。   The present invention relates to an information processing apparatus, a patch application confirmation system, a patch application confirmation method, and a patch application confirmation program.

オープンソースソフトウェア(OSS:Open Source Software)の商用システムへの適用が近年盛んになっている。OSSを利用したシステムを構築する場合、システムの管理者は、例えばOSSのソースコードをビルドして実行形式のソフトウェアを生成し、そのソフトウェアをシステムに導入する。   In recent years, the application of open source software (OSS: Open Source Software) to commercial systems has become popular. When constructing a system using the OSS, the system administrator builds, for example, the source code of the OSS, generates executable software, and introduces the software into the system.

OSSの脆弱性が見つかると、システムの管理者は、OSS修正用のパッチプログラム(以下、修正パッチと呼ぶ)を取得して、OSSを修正する。システムには、様々な修正パッチが適用される。そこで、システムを安全に運用するために、システムの管理者は、システムへの各種修正パッチの適用の有無を管理することとなる。OSSは、パッケージ管理ツールによって脆弱性管理ができるディストリビューションと異なり、脆弱性管理ツールが十分に整備されていない。そのためシステムの管理者は、提供元が公開している修正パッチ情報を収集し、独自に脆弱性の修正パッチ適用の有無を管理する。   When a vulnerability of the OSS is found, the system administrator obtains a patch program for correcting the OSS (hereinafter, referred to as a correction patch) and corrects the OSS. Various correction patches are applied to the system. Therefore, in order to operate the system safely, the administrator of the system manages whether or not various correction patches are applied to the system. The OSS differs from the distribution in which the vulnerability management can be performed by the package management tool, and the vulnerability management tool is not sufficiently prepared. Therefore, the system administrator collects the patch information released by the provider and independently manages whether or not to apply the vulnerability patch.

OSSをシステムへ導入する際には、ソフトウェアの開発支援技術を利用することができる。ソフトウェアの開発支援に関する技術としては、例えば、複数のソフトウェア部品を結合する作業において、当該複数のソフトウェア間で公開、参照される関数の取り扱いの整合性を保つために人が行う作業量を低減するソフトウェア開発支援システムがある。   When introducing the OSS into the system, software development support technology can be used. As a technique related to software development support, for example, in a work of combining a plurality of software components, the amount of work performed by a person to maintain consistency in handling of functions that are disclosed and referred to among the plurality of software is reduced. There is a software development support system.

またパッチ適用を可視化する技術もある。例えばカスタマイズした基準ソースコードに対して、その基準ソースコードのバージョン変更による変更箇所を反映する場合に、変更すべき確度に基づいて修正候補箇所を提示するソフトウェア開発支援方法がある。   There is also a technique for visualizing patch application. For example, there is a software development support method for presenting a modification candidate portion based on the likelihood of a change when reflecting a changed portion due to a version change of the reference source code in a customized reference source code.

特開2004−362048号公報JP-A-2004-362048 特開2017−045354号公報JP 2017-045354 A

OSSのソースコードをビルドして利用しているシステムでは、脆弱性に対処するための修正パッチの適用状況の調査に時間がかかるという問題がある。その要因の1つは、OSSの変数名や関数名を変更して運用する場合があることである。   In a system in which the OSS source code is built and used, there is a problem that it takes a long time to investigate the application status of a correction patch for dealing with a vulnerability. One of the factors is that the OSS may be operated by changing the variable name or the function name.

例えば、修正パッチにおいて、変数名や関数名を含む行の削除や追加が行われる場合、変数名や関数名でソースコード内を検索すれば、修正パッチの適用により修正される行を容易に見つけ出すことができる。しかし、OSSの修正パッチを適用する際に、プログラム側の命名規則にしたがってOSSの修正パッチの変数名や関数名を書き換えて適用していると、ソースコードに対する変数名や関数名での検索では、修正パッチの適用箇所を抽出することができない。この場合、管理者は、ソースコードを詳細に確認して、パッチの適用の有無を判断することとなり、調査に時間がかかってしまう。   For example, when a line containing a variable name or function name is deleted or added in a patch, if the source code is searched by the variable name or function name, a line that is corrected by applying the patch can be easily found. be able to. However, if the OSS patch is applied by rewriting the variable name or function name of the OSS patch according to the naming rules on the program side, the search by the variable name or function name in the source code will not be performed. , It is not possible to extract the location where the patch is applied. In this case, the administrator has to check the source code in detail to determine whether or not a patch has been applied, and it takes a long time to investigate.

1つの側面では、本件は、パッチの適用の有無を判定できるようにすることを目的とする。   In one aspect, an object of the present invention is to be able to determine whether or not a patch has been applied.

1つの案では、以下に示す記憶部と処理部とを有する情報処理装置が適用される。
記憶部は、一部の命令列を修正命令列に変更するパッチの適用対象であるソースファイルを記憶する。処理部は、修正命令列を含むパッチファイルに基づいて、修正命令列内の各命令の命令種別を示すパッチ命令種別情報を生成する。次に処理部は、ソースファイル内の各命令の命令種別を示すソース命令種別情報を生成する。さらに処理部は、パッチ命令種別情報とソース命令種別情報とに基づいて、ソースファイルから、修正命令列と命令種別の並びが一致する種別一致命令列を抽出する。そして処理部は、種別一致命令列と修正命令列との、変数名と関数名とを除外した記述内容に基づいて、ソースファイルにパッチが適用されているか否かを判定する。
In one proposal, an information processing apparatus having a storage unit and a processing unit described below is applied.
The storage unit stores a source file to which a patch for changing a part of the instruction sequence to the correction instruction sequence is applied. The processing unit generates patch instruction type information indicating the instruction type of each instruction in the correction instruction sequence based on the patch file including the correction instruction sequence. Next, the processing unit generates source instruction type information indicating the instruction type of each instruction in the source file. Further, the processing unit extracts, from the source file, a type matching instruction sequence in which the order of the correction instruction sequence and the instruction type matches based on the patch instruction type information and the source instruction type information. Then, the processing unit determines whether a patch has been applied to the source file based on the description content of the type matching instruction sequence and the correction instruction sequence excluding the variable name and the function name.

1態様によれば、パッチの適用の有無が判定可能となる。   According to one aspect, it is possible to determine whether or not a patch has been applied.

第1の実施の形態に係るパッチ適用確認方法の一例を示す図である。FIG. 7 is a diagram illustrating an example of a patch application confirmation method according to the first embodiment. 第2の実施の形態のパッチ適用確認システムの一例を示す図である。FIG. 14 is a diagram illustrating an example of a patch application confirmation system according to a second embodiment. コンピュータのハードウェアの一例を示す図である。FIG. 3 is a diagram illustrating an example of computer hardware. 修正パッチ適用可視化機能の一例を示すブロック図である。It is a block diagram which shows an example of a correction patch application visualization function. 修正パッチの一例を示す図である。It is a figure showing an example of a correction patch. ソースファイルの一例を示す図である。FIG. 4 is a diagram illustrating an example of a source file. 固定キーワード辞書の一例を示す図である。FIG. 4 is a diagram illustrating an example of a fixed keyword dictionary. 修正パッチに対する命令種別判定の一例を示す図である。FIG. 14 is a diagram illustrating an example of determining an instruction type for a correction patch. 配列を用いた修正パッチの命令種別判定処理の一例を示す図である。FIG. 14 is a diagram illustrating an example of an instruction type determination process of a correction patch using an array. ソースファイルに対する命令種別判定の一例を示す図である。FIG. 9 is a diagram illustrating an example of determining a command type for a source file. 配列を用いたソースファイルの命令種別判定処理の一例を示す図である。FIG. 14 is a diagram illustrating an example of a source file instruction type determination process using an array. パッチ導入箇所推定処理の一例を示す図である。FIG. 9 is a diagram illustrating an example of a patch introduction location estimation process. マッチング処理の一例を示す図である。It is a figure showing an example of matching processing. 配列を用いたマッチング処理の一例を示す図である。FIG. 9 is a diagram illustrating an example of a matching process using an array. マッチング結果の一例を示す図である。It is a figure showing an example of a matching result. 可変キーワードの対応関係の保存例を示す図である。FIG. 11 is a diagram illustrating an example of storing correspondences between variable keywords. 類似度算出処理の一例を示す図である。It is a figure showing an example of similarity calculation processing. パッチ適用情報の一例を示す図である。FIG. 6 is a diagram illustrating an example of patch application information. 結果表示画面の一例を示す図である。It is a figure showing an example of a result display screen. 修正パッチ適用可視化処理の手順の一例を示すフローチャートである。It is a flowchart which shows an example of the procedure of a correction patch application visualization process. 命令種別判定処理の手順の一例を示すフローチャートである。It is a flowchart which shows an example of the procedure of instruction type determination processing. 命令種別情報取得処理の手順の詳細を示すフローチャートの前半である。It is the first half of the flowchart which shows the details of the procedure of the instruction type information acquisition processing. 命令種別情報取得処理の手順の詳細を示すフローチャートの後半である。It is the latter half of the flowchart showing the details of the procedure of the command type information acquisition processing. パッチ導入箇所推定処理の手順の一例を示すフローチャートである。It is a flowchart which shows an example of the procedure of a patch introduction part estimation process. マッチング処理の手順の一例を示すフローチャートである。It is a flowchart which shows an example of the procedure of a matching process. 類似度算出処理の手順の一例を示すフローチャートである。It is a flowchart which shows an example of the procedure of a similarity calculation process. 結果出力処理の手順の一例を示すフローチャートである。It is a flowchart which shows an example of the procedure of a result output process.

以下、本実施の形態について図面を参照して説明する。なお各実施の形態は、矛盾のない範囲で複数の実施の形態を組み合わせて実施することができる。
〔第1の実施の形態〕
まず第1の実施の形態について説明する。
Hereinafter, the present embodiment will be described with reference to the drawings. Note that each embodiment can be implemented by combining a plurality of embodiments within a consistent range.
[First Embodiment]
First, a first embodiment will be described.

図1は、第1の実施の形態に係るパッチ適用確認方法の一例を示す図である。図1の例では、情報処理装置10を用いてパッチ適用確認方法を実施している。情報処理装置10は、記憶部11と処理部12とを有する。記憶部11は、例えば情報処理装置10が有するメモリ、またはストレージ装置である。処理部12は、例えば情報処理装置10が有するプロセッサ、または演算回路である。情報処理装置10は、例えばパッチ適用確認方法の処理手順を記述したパッチ適用確認プログラムを処理部12に実行させることで、パッチ適用確認方法を実施することができる。   FIG. 1 is a diagram illustrating an example of the patch application confirmation method according to the first embodiment. In the example of FIG. 1, the patch application confirmation method is performed using the information processing device 10. The information processing device 10 includes a storage unit 11 and a processing unit 12. The storage unit 11 is, for example, a memory or a storage device included in the information processing device 10. The processing unit 12 is, for example, a processor or an arithmetic circuit included in the information processing device 10. The information processing apparatus 10 can execute the patch application confirmation method by causing the processing unit 12 to execute a patch application confirmation program that describes, for example, a processing procedure of the patch application confirmation method.

記憶部11は、一部の命令列を修正命令列1aに変更するパッチの適用対象であるソースファイル2を記憶する。
処理部12は、修正命令列1aを含むパッチファイル1に基づいて、修正命令列1a内の各命令の命令種別を示すパッチ命令種別情報3を生成する。例えばパッチファイル1には、ソースファイル2のどの命令を削除して、どのような命令を追加するのかが定義されている。処理部12は、パッチファイル1を解析することで、パッチ適用後に、ソースファイル2内のパッチにより修正された部分が、どのような命令列になるのかを判断し、その命令列を修正命令列1aとする。また処理部12は、ソースファイル2内の各命令の命令種別を示すソース命令種別情報4を生成する。命令種別には、変数型を定義する「宣言」や、処理の実施条件を定義する「条件」や、変数または配列の要素に値を設定する「代入」などがある。
The storage unit 11 stores a source file 2 to which a patch for changing a part of the instruction sequence to the modified instruction sequence 1a is applied.
The processing unit 12 generates patch instruction type information 3 indicating the instruction type of each instruction in the correction instruction sequence 1a based on the patch file 1 including the correction instruction sequence 1a. For example, the patch file 1 defines which instructions in the source file 2 are deleted and what instructions are added. By analyzing the patch file 1, the processing unit 12 determines what kind of instruction sequence the part corrected by the patch in the source file 2 becomes after application of the patch, and converts the instruction sequence into a modified instruction sequence. 1a. Further, the processing unit 12 generates source instruction type information 4 indicating the instruction type of each instruction in the source file 2. The instruction types include “declaration” for defining a variable type, “condition” for defining an execution condition of processing, and “assignment” for setting a value to a variable or an element of an array.

次に処理部12は、パッチ命令種別情報3とソース命令種別情報4とに基づいて、ソースファイル2内の、修正命令列1aと命令種別の並びが一致する種別一致命令列2aの位置(命令種別一致箇所)を判定する。命令種別一致箇所は、例えばソースファイル2内のソースコードの行の範囲(何行目から何行目までか)で示される。そして処理部12は、ソースファイル2から、命令種別一致箇所に記述された種別一致命令列2aを抽出する。   Next, based on the patch instruction type information 3 and the source instruction type information 4, the processing unit 12 determines, in the source file 2, the position of the type matching instruction sequence 2a (instruction Type match). The instruction type matching position is indicated, for example, by the range of the line of the source code in the source file 2 (from what line to what line). Then, the processing unit 12 extracts, from the source file 2, the type matching instruction sequence 2a described in the instruction type matching location.

処理部12は、種別一致命令列2aと修正命令列1aとの、変数名と関数名とを除外した記述内容に基づいて、ソースファイル2にパッチが適用されているか否かを判定する。例えば処理部12は、変数名と関数名とを除外した種別一致命令列2aの記述内容と、変数名と関数名とを除外した修正命令列1aの記述内容との類似度を算出する。そして処理部12は、算出した類似度に基づいて、ソースファイル2にパッチが適用されているか否かを判定する。   The processing unit 12 determines whether a patch has been applied to the source file 2 based on the description contents of the type matching instruction sequence 2a and the correction instruction sequence 1a excluding the variable name and the function name. For example, the processing unit 12 calculates the similarity between the description content of the type matching instruction sequence 2a excluding the variable name and the function name and the description content of the correction instruction sequence 1a excluding the variable name and the function name. Then, the processing unit 12 determines whether a patch has been applied to the source file 2 based on the calculated similarity.

類似度算出では、例えば処理部12は、種別一致命令列2aと修正命令列1aとのそれぞれの命令行に先頭から順に行番号を付与する。そして処理部12は、同じ行番号の行同士の記述の同一性を判定し、一致すると判定した行の割合を類似度とする。   In the similarity calculation, for example, the processing unit 12 sequentially assigns a line number to each instruction line of the type matching instruction sequence 2a and the correction instruction sequence 1a from the top. Then, the processing unit 12 determines the similarity of the description of the lines having the same line number, and sets the ratio of the lines determined to match as the similarity.

行同士の同一性の判定では、例えば処理部12は、比較対象の行内の単語同士を、行の先頭から順に比較する。その際、処理部12は、例えば少なくとも単語の種別が同一であれば、単語が一致すると判定する。また処理部12は、単語の種別だけでなく、単語の文字または記号が完全に同一の場合に、単語が一致すると判定してもよい。さらに処理部12は、種別が同一であれば一致と判定する方法と、文字または記号が完全に同一であれば一致と判定する方法とのうち、採用する判定方法を、単語の種別に応じて決定してもよい。例えば処理部12は、単語の種別が変数型の場合、種別が同一であれば、単語が一致すると判定し、単語の種別は算術演算子などの演算子の場合、文字または記号が完全に同一であれば、単語が一致すると判定する。   In determining the identity between lines, for example, the processing unit 12 compares words in the line to be compared sequentially from the beginning of the line. At that time, the processing unit 12 determines that the words match if, for example, at least the types of the words are the same. Further, the processing unit 12 may determine that the words match if not only the type of the word but also the characters or symbols of the word are completely the same. Further, the processing unit 12 determines, based on the type of the word, a determination method to be adopted among a method of determining a match if the types are the same and a method of determining a match if the characters or symbols are completely the same. You may decide. For example, when the type of a word is a variable type, if the type is the same, the processing unit 12 determines that the words match, and when the type of the word is an operator such as an arithmetic operator, the characters or symbols are completely the same. If so, it is determined that the words match.

単語の種別の判定には、キーワード辞書を用いることができる。例えば記憶部11は、行間の同一性の判定において比較対象とする単語のリストを含むキーワード辞書を記憶する。処理部12は、種別一致命令列2aの第1の行内のキーワード辞書に含まれる単語と、修正命令列1aにおける、第1の行と同じ行番号の第2の行内のキーワード辞書に含まれる単語とを比較することで、同じ行番号の行同士の同一性を判定する。   A keyword dictionary can be used to determine the type of word. For example, the storage unit 11 stores a keyword dictionary including a list of words to be compared in determining the identity between lines. The processing unit 12 includes a word included in the keyword dictionary in the first line of the type matching instruction sequence 2a and a word included in the keyword dictionary in the second line having the same line number as the first line in the correction instruction sequence 1a. Are compared to determine the identity between rows having the same row number.

類似度に基づくパッチ適用の有無の判定では、処理部12は、類似度が100%であれば、ソースファイル2にパッチが適用済みであると判定する。また処理部12は、類似度が予め設定された閾値以上であれば、ソースファイル2にパッチが適用されている可能性が高いと判定する。さらに処理部12は、類似度が閾値未満であれば、ソースファイル2に対してパッチが未適用であると判定する。   When determining whether or not to apply a patch based on the similarity, the processing unit 12 determines that the patch has been applied to the source file 2 if the similarity is 100%. If the similarity is equal to or greater than the preset threshold, the processing unit 12 determines that there is a high possibility that the source file 2 has a patch applied. Further, if the similarity is less than the threshold, the processing unit 12 determines that the patch has not been applied to the source file 2.

このようにして、変数名や関数名のように、変更の自由度が高く、システムの管理者が自由に変更できる単語を除外して、パッチの適用の有無を判断できる。すなわち処理部12が、修正命令列1aと命令種別の並びが同じ種別一致命令列2aをソースファイル2から抽出することで、パッチの適用により修正される可能性の高い部分を適切に抽出できる。そして、パッチ適用で修正される可能性が高い部分である種別一致命令列2aと修正命令列1aとを比較して、パッチの適用の有無を判定することで、変数名や関数名を除外しても、高精度に判定することができる。   In this way, it is possible to determine whether or not to apply a patch, excluding words that have a high degree of freedom of change, such as variable names and function names, and that can be freely changed by the system administrator. That is, the processing unit 12 extracts, from the source file 2, the type-matching instruction sequence 2a having the same instruction sequence as the correction instruction sequence 1a, so that a portion that is likely to be modified by applying a patch can be appropriately extracted. Then, the type matching instruction sequence 2a, which is likely to be modified by the patch application, is compared with the modification instruction sequence 1a to determine whether or not the patch is applied, thereby excluding the variable names and the function names. However, the determination can be made with high accuracy.

また処理部12は、変数型の型の定義の変更のように、同一種別内で単語を変更してもプログラム上の処理のアルゴリズムに変更がないような単語については、種別が同一であれば一致すると判定することができる。これにより、パッチ適用の有無の判定精度が向上する。例えば図1の例では、修正命令列1aの1行目の先頭の単語は、変数型の単語「short」である。それに対して、種別一致命令列2aの1行目の先頭の単語は、変数型の単語「int」である。単語「short」と単語「int」は、変数型のうちの整数型と呼ばれる型の指定であり、変数に格納する値のサイズが異なるのみである。このような変数型の変更は、情報処理装置10の使用者が独自に行っている可能性がある。そのため処理部12は、変数型の単語については、種別が変数型で同一であれば、文字または記号が同一でなくても、類似度の算出時の比較においては、一致すると判定してもよい。これにより、ソースファイル2に対して変数型の変更の改変が加えられている場合でも、パッチの適用の有無を正しく判断できるようになる。   In addition, the processing unit 12 may change the word in the same type, such as a change in the definition of the type of the variable type, such that the algorithm of the processing in the program does not change if the type is the same. It can be determined that they match. As a result, the accuracy of determining whether a patch has been applied is improved. For example, in the example of FIG. 1, the first word in the first line of the correction instruction sequence 1a is a variable-type word “short”. On the other hand, the first word in the first line of the type matching instruction sequence 2a is a variable-type word “int”. The word “short” and the word “int” are designations of a type called an integer type among the variable types, and only differ in the size of the value stored in the variable. Such a change of the variable type may be performed by the user of the information processing apparatus 10 independently. Therefore, if the type of the variable type word is the same in the variable type, the processing unit 12 may determine that the words or symbols are not the same even in the comparison at the time of calculating the similarity, even if the characters or symbols are not the same. . As a result, even when the change of the variable type is changed in the source file 2, it is possible to correctly determine whether or not the patch is applied.

〔第2の実施の形態〕
次に第2の実施の形態について説明する。第2の実施の形態は、OSSを利用しているコンピュータにおける修正パッチの適用状況を可視化するものである。
[Second embodiment]
Next, a second embodiment will be described. In the second embodiment, the application status of a correction patch on a computer using the OSS is visualized.

図2は、第2の実施の形態のパッチ適用確認システムの一例を示す図である。OSSを利用しているコンピュータ100は、ネットワーク20を介してサーバ200に接続されている。サーバ200は、修正パッチを配布するコンピュータである。   FIG. 2 is a diagram illustrating an example of a patch application confirmation system according to the second embodiment. The computer 100 using the OSS is connected to the server 200 via the network 20. The server 200 is a computer that distributes a correction patch.

コンピュータ100は、OSSコミュニティがサーバ200を用いて公開している修正パッチとソースファイルとの類似度に基づいて、ソースファイルへの修正パッチの適用の有無を判断する。   The computer 100 determines whether or not a correction patch is applied to the source file based on the similarity between the correction patch released by the OSS community using the server 200 and the source file.

例えばコンピュータ100に導入しているOSSの脆弱性が、サーバ200で配布されている修正パッチで修正できる場合、コンピュータ100の管理者は、その修正パッチがコンピュータ100に適用済みか否かを調査することとなる。このとき管理者は、パッチ適用確認プログラムをコンピュータ100で実行することで、コンピュータ100に修正パッチの適用状況を可視化させる。管理者は、例えば可視化された修正パッチの適用状況を参考にして、ソースコードの内容を確認し、修正パッチが正しく適用されているか否かを調査する。   For example, if the vulnerability of the OSS introduced in the computer 100 can be corrected by the patch distributed on the server 200, the administrator of the computer 100 checks whether the patch has been applied to the computer 100 or not. It will be. At this time, the administrator executes the patch application confirmation program on the computer 100 to cause the computer 100 to visualize the application status of the correction patch. The administrator checks the contents of the source code with reference to the application status of the visualized patch, for example, and checks whether the patch is correctly applied.

図3は、コンピュータのハードウェアの一例を示す図である。コンピュータ100は、プロセッサ101によって装置全体が制御されている。プロセッサ101には、バス109を介してメモリ102と複数の周辺機器が接続されている。プロセッサ101は、マルチプロセッサであってもよい。プロセッサ101は、例えばCPU(Central Processing Unit)、MPU(Micro Processing Unit)、またはDSP(Digital Signal Processor)である。プロセッサ101がプログラムを実行することで実現する機能の少なくとも一部を、ASIC(Application Specific Integrated Circuit)、PLD(Programmable Logic Device)などの電子回路で実現してもよい。   FIG. 3 is a diagram illustrating an example of computer hardware. The computer 100 is entirely controlled by a processor 101. The processor 102 is connected to the memory 102 and a plurality of peripheral devices via a bus 109. Processor 101 may be a multiprocessor. The processor 101 is, for example, a CPU (Central Processing Unit), an MPU (Micro Processing Unit), or a DSP (Digital Signal Processor). At least a part of the function realized by the processor 101 executing the program may be realized by an electronic circuit such as an ASIC (Application Specific Integrated Circuit) or a PLD (Programmable Logic Device).

メモリ102は、コンピュータ100の主記憶装置として使用される。メモリ102には、プロセッサ101に実行させるOS(Operating System)のプログラムやアプリケーションプログラムの少なくとも一部が一時的に格納される。また、メモリ102には、プロセッサ101による処理に利用する各種データが格納される。メモリ102としては、例えばRAM(Random Access Memory)などの揮発性の半導体記憶装置が使用される。   The memory 102 is used as a main storage device of the computer 100. The memory 102 temporarily stores at least a part of an OS (Operating System) program and an application program to be executed by the processor 101. Further, the memory 102 stores various data used for processing by the processor 101. As the memory 102, for example, a volatile semiconductor storage device such as a RAM (Random Access Memory) is used.

バス109に接続されている周辺機器としては、ストレージ装置103、グラフィック処理装置104、入力インタフェース105、光学ドライブ装置106、機器接続インタフェース107およびネットワークインタフェース108がある。   The peripheral devices connected to the bus 109 include a storage device 103, a graphic processing device 104, an input interface 105, an optical drive device 106, a device connection interface 107, and a network interface 108.

ストレージ装置103は、内蔵した記録媒体に対して、電気的または磁気的にデータの書き込みおよび読み出しを行う。ストレージ装置103は、コンピュータの補助記憶装置として使用される。ストレージ装置103には、OSのプログラム、アプリケーションプログラム、および各種データが格納される。なお、ストレージ装置103としては、例えばHDD(Hard Disk Drive)やSSD(Solid State Drive)を使用することができる。   The storage device 103 electrically or magnetically writes and reads data on a built-in recording medium. The storage device 103 is used as an auxiliary storage device of a computer. The storage device 103 stores OS programs, application programs, and various data. As the storage device 103, for example, a hard disk drive (HDD) or a solid state drive (SSD) can be used.

グラフィック処理装置104には、モニタ21が接続されている。グラフィック処理装置104は、プロセッサ101からの命令に従って、画像をモニタ21の画面に表示させる。モニタ21としては、有機EL(Electro Luminescence)を用いた表示装置や液晶表示装置などがある。   The monitor 21 is connected to the graphic processing device 104. The graphic processing device 104 displays an image on the screen of the monitor 21 according to a command from the processor 101. Examples of the monitor 21 include a display device using an organic EL (Electro Luminescence) and a liquid crystal display device.

入力インタフェース105には、キーボード22とマウス23とが接続されている。入力インタフェース105は、キーボード22やマウス23から送られてくる信号をプロセッサ101に送信する。なお、マウス23は、ポインティングデバイスの一例であり、他のポインティングデバイスを使用することもできる。他のポインティングデバイスとしては、タッチパネル、タブレット、タッチパッド、トラックボールなどがある。   The keyboard 22 and the mouse 23 are connected to the input interface 105. The input interface 105 transmits a signal transmitted from the keyboard 22 or the mouse 23 to the processor 101. The mouse 23 is an example of a pointing device, and another pointing device can be used. Other pointing devices include touch panels, tablets, touchpads, trackballs, and the like.

光学ドライブ装置106は、レーザ光などを利用して、光ディスク24に記録されたデータの読み取りを行う。光ディスク24は、光の反射によって読み取り可能なようにデータが記録された可搬型の記録媒体である。光ディスク24には、DVD(Digital Versatile Disc)、DVD−RAM、CD−ROM(Compact Disc Read Only Memory)、CD−R(Recordable)/RW(ReWritable)などがある。   The optical drive device 106 reads data recorded on the optical disk 24 using laser light or the like. The optical disk 24 is a portable recording medium on which data is recorded so as to be readable by light reflection. The optical disc 24 includes a DVD (Digital Versatile Disc), a DVD-RAM, a CD-ROM (Compact Disc Read Only Memory), a CD-R (Recordable) / RW (ReWritable), and the like.

機器接続インタフェース107は、コンピュータ100に周辺機器を接続するための通信インタフェースである。例えば機器接続インタフェース107には、メモリ装置25やメモリリーダライタ26を接続することができる。メモリ装置25は、機器接続インタフェース107との通信機能を搭載した記録媒体である。メモリリーダライタ26は、メモリカード27へのデータの書き込み、またはメモリカード27からのデータの読み出しを行う装置である。メモリカード27は、カード型の記録媒体である。   The device connection interface 107 is a communication interface for connecting a peripheral device to the computer 100. For example, the memory device 25 and the memory reader / writer 26 can be connected to the device connection interface 107. The memory device 25 is a recording medium having a communication function with the device connection interface 107. The memory reader / writer 26 is a device that writes data to the memory card 27 or reads data from the memory card 27. The memory card 27 is a card-type recording medium.

ネットワークインタフェース108は、ネットワーク20に接続されている。ネットワークインタフェース108は、ネットワーク20を介して、他のコンピュータまたは通信機器との間でデータの送受信を行う。   The network interface 108 is connected to the network 20. The network interface 108 transmits and receives data to and from another computer or communication device via the network 20.

コンピュータ100は、以上のようなハードウェア構成によって、第2の実施の形態の処理機能を実現することができる。なおサーバ200も、図3に示したコンピュータ100と同様のハードウェアにより実現することができる。また第1の実施の形態に示した情報処理装置10も、図3に示したコンピュータ100と同様のハードウェアにより実現することができる。   The computer 100 can realize the processing functions of the second embodiment with the above hardware configuration. Note that the server 200 can also be realized by the same hardware as the computer 100 shown in FIG. Further, the information processing apparatus 10 described in the first embodiment can also be realized by the same hardware as the computer 100 illustrated in FIG.

コンピュータ100は、例えばコンピュータ読み取り可能な記録媒体に記録されたプログラムを実行することにより、第2の実施の形態の処理機能を実現する。コンピュータ100に実行させる処理内容を記述したプログラムは、様々な記録媒体に記録しておくことができる。例えば、コンピュータ100に実行させるプログラムをストレージ装置103に格納しておくことができる。プロセッサ101は、ストレージ装置103内のプログラムの少なくとも一部をメモリ102にロードし、プログラムを実行する。またコンピュータ100に実行させるプログラムを、光ディスク24、メモリ装置25、メモリカード27などの可搬型記録媒体に記録しておくこともできる。可搬型記録媒体に格納されたプログラムは、例えばプロセッサ101からの制御により、ストレージ装置103にインストールされた後、実行可能となる。またプロセッサ101が、可搬型記録媒体から直接プログラムを読み出して実行することもできる。   The computer 100 realizes the processing functions of the second embodiment, for example, by executing a program recorded on a computer-readable recording medium. The program describing the processing to be executed by the computer 100 can be recorded on various recording media. For example, a program to be executed by the computer 100 can be stored in the storage device 103. The processor 101 loads at least a part of the program in the storage device 103 into the memory 102 and executes the program. Further, the program to be executed by the computer 100 may be recorded on a portable recording medium such as the optical disk 24, the memory device 25, and the memory card 27. The program stored in the portable recording medium becomes executable after being installed in the storage device 103 under the control of the processor 101, for example. Further, the processor 101 can also read out the program directly from the portable recording medium and execute the program.

コンピュータ100は、修正パッチの適用の有無を可視化するための修正パッチ適用可視化機能を有する。
図4は、修正パッチ適用可視化機能の一例を示すブロック図である。コンピュータ100は、導入されているOSSの修正パッチを、サーバ200が有するリポジトリ210から取得し、取得した修正パッチの適用の有無を可視化することができる。修正パッチの適用の有無を可視化するために、コンピュータ100は、図4に示す各要素を有する。すなわちコンピュータ100は、ソースファイル記憶部110、固定キーワード辞書記憶部120、類似度閾値記憶部130、ソースコード取得部141、命令種別判定部142、命令種別記憶部143、パッチ導入箇所推定部144、パッチ導入推定箇所記憶部145、マッチング処理部146、マッチング結果記憶部147、類似度算出部148、類似度記憶部149、結果出力部150、およびパッチ適用情報記憶部151を有する。
The computer 100 has a correction patch application visualization function for visualizing whether or not a correction patch has been applied.
FIG. 4 is a block diagram illustrating an example of the correction patch application visualization function. The computer 100 can acquire the installed patch of the OSS from the repository 210 of the server 200 and visualize whether or not the acquired patch has been applied. In order to visualize whether or not a correction patch has been applied, the computer 100 has the components shown in FIG. That is, the computer 100 includes a source file storage unit 110, a fixed keyword dictionary storage unit 120, a similarity threshold storage unit 130, a source code acquisition unit 141, an instruction type determination unit 142, an instruction type storage unit 143, a patch introduction location estimation unit 144, It has a patch introduction estimated location storage unit 145, a matching processing unit 146, a matching result storage unit 147, a similarity calculation unit 148, a similarity storage unit 149, a result output unit 150, and a patch application information storage unit 151.

ソースファイル記憶部110は、OSSのソースコードが記述されたソースファイルを記憶する。ソースファイルは、修正パッチ適用可視化処理の開始前に、予めソースファイル記憶部110に格納される。なおソースファイルに記述されているOSSのソースコードは、変数名や関数名が変更されている場合がある。   The source file storage unit 110 stores a source file in which the OSS source code is described. The source file is stored in the source file storage unit 110 in advance before the start of the correction patch application visualization processing. Note that in the OSS source code described in the source file, variable names and function names may be changed.

固定キーワード辞書記憶部120は、固定キーワード辞書を記憶する。固定キーワード辞書は、ソースコードに含まれる単語を固定キーワードと可変キーワードとに分類する場合における、固定キーワードに該当する単語を示す情報である。固定キーワードは、例えば算術演算子のように、変更してしまうと、ソースファイルで示されるプログラムの処理内容が変わってしまう単語である。命令の終端を示す「;」のように、プログラミング言語の仕様上、他の文字に置き換えることが許容されない文字も、固定キーワードである。可変キーワードは、例えば変数名や関数名のように、変更してもソースファイルで示されるプログラムの処理内容が変わらない単語である。   The fixed keyword dictionary storage unit 120 stores a fixed keyword dictionary. The fixed keyword dictionary is information indicating words corresponding to the fixed keywords when words included in the source code are classified into fixed keywords and variable keywords. A fixed keyword is a word, such as an arithmetic operator, that changes the processing content of the program indicated by the source file when changed. Characters that cannot be replaced with other characters due to the specification of the programming language, such as “;” indicating the end of the instruction, are also fixed keywords. A variable keyword is a word, such as a variable name or a function name, that does not change the processing content of the program indicated by the source file even if it is changed.

また固定キーワード辞書には、各単語の種別(変数型、条件演算子など)が示されている。固定キーワード辞書は、修正パッチ適用可視化処理の開始前に、予め固定キーワード辞書記憶部120に格納される。   The fixed keyword dictionary indicates the type of each word (variable type, conditional operator, etc.). The fixed keyword dictionary is stored in the fixed keyword dictionary storage unit 120 in advance before the correction patch application visualization process starts.

類似度閾値記憶部130は、修正パッチ導入推定箇所について、部分一致とするか不一致とするかを判定するための類似度の閾値を記憶する。類似度の閾値は、例えば「50%」である。類似度の閾値は、修正パッチ適用可視化処理の開始前に、予め類似度閾値記憶部130に格納される。   The similarity threshold value storage unit 130 stores a similarity threshold value for determining whether a modified patch introduction estimated location is partially matched or not matched. The threshold value of the similarity is, for example, “50%”. The similarity threshold is stored in the similarity threshold storage unit 130 in advance before the correction patch application visualization processing is started.

ソースコード取得部141は、適用対象の修正パッチを示すパッチファイルに記述された修正用ソースコードと、その修正パッチを適用するOSSのソースコードとを取得する。例えばソースコード取得部141は、ネットワーク20を介して、サーバ200内のリポジトリ210から、修正パッチの修正用ソースコードを取得する。またソースコード取得部141は、ソースファイル記憶部110内のソースファイルから、修正パッチを適用するOSSのソースコードを取得する。   The source code acquisition unit 141 acquires a correction source code described in a patch file indicating a patch to be applied and a source code of an OSS to which the patch is applied. For example, the source code obtaining unit 141 obtains a correction source code of a correction patch from the repository 210 in the server 200 via the network 20. Further, the source code acquisition unit 141 acquires, from the source file in the source file storage unit 110, the source code of the OSS to which the correction patch is applied.

命令種別判定部142は、固定キーワード辞書に示された単語の種別に基づいて、修正パッチの修正用ソースコードと、OSSのソースファイル内のソースコードとのそれぞれについて、行ごとの命令種別を判定する。命令種別判定部142は、命令種別の判定結果を、命令種別記憶部143に格納する。   The instruction type determination unit 142 determines an instruction type for each line for each of the correction source code of the correction patch and the source code in the OSS source file based on the type of the word indicated in the fixed keyword dictionary. I do. The instruction type determination unit 142 stores the instruction type determination result in the instruction type storage unit 143.

命令種別記憶部143は、修正パッチの修正用ソースコードとOSSのソースコードとの行ごとの命令種別を記憶する。
パッチ導入箇所推定部144は、修正パッチのソースコードとOSSのソースコードとの行ごとの命令種別に基づいて、OSSのソースコード内のパッチ導入推定箇所を特定する。パッチ導入推定箇所は、OSSのソースコードのうち、修正パッチに基づいて修正されている可能性がある部分である。パッチ導入箇所推定部144は、パッチ導入推定箇所を示す情報を、パッチ導入推定箇所記憶部145に格納する。
The instruction type storage unit 143 stores an instruction type for each line of a correction source code of a correction patch and an OSS source code.
The patch introduction location estimation unit 144 specifies a patch introduction estimation location in the OSS source code based on the instruction type of each line of the source code of the correction patch and the OSS source code. The estimated patch introduction location is a portion of the OSS source code that may be modified based on the modified patch. The patch introduction location estimation unit 144 stores information indicating the patch introduction estimation location in the patch introduction estimation location storage unit 145.

パッチ導入推定箇所記憶部145は、パッチ導入推定箇所を示す情報を記憶する。
マッチング処理部146は、固定キーワード辞書を参照し、パッチ導入推定箇所の各行の固定キーワードを、修正パッチの修正用ソースコードの各行の固定キーワードと比較し、行ごとの一致・不一致を判断する。マッチング処理部146は、一致・不一致の判断結果(マッチング結果)を、マッチング結果記憶部147に格納する。
The estimated patch introduction location storage unit 145 stores information indicating the estimated patch introduction location.
The matching processing unit 146 refers to the fixed keyword dictionary, compares the fixed keyword in each line of the estimated patch introduction location with the fixed keyword in each line of the correction source code of the correction patch, and determines the match / mismatch of each line. The matching processing unit 146 stores the matching / mismatch determination result (matching result) in the matching result storage unit 147.

マッチング結果記憶部147は、マッチング結果を記憶する。
類似度算出部148は、マッチング結果に基づいて、パッチ導入推定箇所と修正パッチとの類似度を算出する。そして類似度算出部148は、算出した類似度に基づいて、類似度のランク分けを行う。例えば類似度算出部148は、パッチ導入推定箇所の類似度が100%一致の場合、そのパッチ導入推定箇所について完全一致と判定する。また類似度算出部148は、類似度閾値記憶部130に格納されている類似度の閾値に基づいて、パッチ導入推定箇所の類似度が閾値以上の場合、そのパッチ導入推定箇所について類似度高(部分一致)と判定する。また類似度算出部148は、パッチ導入推定箇所の類似度が閾値未満の場合、そのパッチ導入推定箇所について不一致と判定する。類似度算出部148は、算出した類似度と、類似度のランクとを、類似度記憶部149に格納する。
The matching result storage unit 147 stores the matching result.
The similarity calculation unit 148 calculates the similarity between the estimated patch introduction location and the corrected patch based on the matching result. Then, the similarity calculating section 148 ranks the similarities based on the calculated similarities. For example, when the similarity of the estimated patch introduction location is 100% identical, the similarity calculation unit 148 determines that the estimated patch introduction location is a perfect match. Further, based on the similarity threshold stored in the similarity threshold storage unit 130, if the similarity of the patch introduction estimated location is equal to or greater than the threshold, the similarity calculation unit 148 determines the similarity high ( (Partial match). When the similarity of the estimated patch introduction location is less than the threshold, the similarity calculation unit 148 determines that the estimated patch introduction location does not match. The similarity calculation unit 148 stores the calculated similarity and the rank of the similarity in the similarity storage unit 149.

類似度記憶部149は、パッチ導入推定箇所の類似度と、類似度のランクとを記憶する。
結果出力部150は、類似度記憶部149に格納されたパッチ導入推定箇所の類似度に基づいて、OSSのソースファイルごとに、そのソースファイルへの修正パッチの適用状況を示すパッチ適用情報を生成する。さらに結果出力部150は、パッチ導入推定箇所のソースコードと修正パッチの修正用ソースコードとの比較情報を生成してもよい。そして結果出力部150は、パッチ適用情報またはソースコードの比較情報を、パッチ適用情報記憶部151に格納する。また結果出力部150は、パッチ適用情報またはソースコードの比較情報を、モニタ21に表示させることもできる。
The similarity storage unit 149 stores the similarity of the estimated patch introduction location and the rank of the similarity.
The result output unit 150 generates, for each OSS source file, patch application information indicating the status of application of the modified patch to the source file for each OSS source file based on the similarity of the estimated patch introduction location stored in the similarity storage unit 149. I do. Further, the result output unit 150 may generate comparison information between the source code of the estimated patch introduction location and the correction source code of the correction patch. Then, the result output unit 150 stores the patch application information or the comparison information of the source code in the patch application information storage unit 151. The result output unit 150 can also display the patch application information or the comparison information of the source code on the monitor 21.

なお、図4に示した各要素間を接続する線は通信経路の一部を示すものであり、図示した通信経路以外の通信経路も設定可能である。また、図4に示した各要素の機能は、例えば、その要素に対応するプログラムモジュールをコンピュータに実行させることで実現することができる。   The lines connecting the elements shown in FIG. 4 show a part of the communication path, and a communication path other than the illustrated communication path can be set. The function of each element shown in FIG. 4 can be realized by, for example, causing a computer to execute a program module corresponding to the element.

次にサーバ200のリポジトリ210に格納される修正パッチについて具体的に説明する。
図5は、修正パッチの一例を示す図である。リポジトリ210には、複数の修正パッチ211,212,・・・が格納されている。修正パッチ211,212,・・・には、OSSのソースファイルの修正内容を示す修正用ソースコードが記述されている。修正パッチ211,212,・・・において、先頭の文字が「+」の行は、その行の「+」に続く文字列を、ソースファイルに追加することを示している。また、修正パッチ211,212,・・・において、先頭の文字が「−」の行は、その行の「−」に続く文字列に対応する行を、ソースファイルから削除することを示している。
Next, the modified patches stored in the repository 210 of the server 200 will be specifically described.
FIG. 5 is a diagram illustrating an example of the correction patch. The repository 210 stores a plurality of modified patches 211, 212,... Each of the correction patches 211, 212,... Describes a correction source code indicating the contents of correction of the OSS source file. In the modified patches 211, 212,..., A line whose first character is “+” indicates that a character string following “+” in the line is added to the source file. In the modified patches 211, 212,..., A line whose first character is "-" indicates that a line corresponding to a character string following "-" of the line is deleted from the source file. .

次にソースファイル記憶部110に格納されるソースファイルについて具体的に説明する。
図6は、ソースファイルの一例を示す図である。ソースファイル記憶部110には、複数のソースファイル111,112,・・・が格納されている。各ソースファイル111,112,・・・に記述されているソースコードは、一般に配布されているオリジナルのソースファイルに対して、変数名や関数名の書き換えが行われている可能性がある。例えばソースファイル111の「int」は、オリジナルのソースファイルにおける「short」から書き換えられたものである。
Next, the source file stored in the source file storage unit 110 will be specifically described.
FIG. 6 is a diagram illustrating an example of the source file. The source file storage unit 110 stores a plurality of source files 111, 112,... The source code described in each of the source files 111, 112,... May have been rewritten with variable names and function names with respect to the original source files generally distributed. For example, “int” in the source file 111 is rewritten from “short” in the original source file.

このように、ソースファイル111,112,・・・内のソースコードの書き換えが行われている場合がある。この場合、各ソースファイル111,112,・・・への適用の有無を判定する際に、変数名や関数名を含む検索キーによる修正箇所の検索を行っても、修正箇所を適切に検出することができない。そこでコンピュータ100では、ソースコードから変数名や関数名を抽出し、変数名または関数名以外の記述を解析して、修正パッチの適用の有無を判断する。例えばコンピュータ100は、修正パッチの適用の有無の判断には、固定キーワード辞書を用いる。   Thus, the source code in the source files 111, 112,... May be rewritten. In this case, when determining whether or not to apply to each of the source files 111, 112,..., Even if a search is made for a correction portion using a search key including a variable name or a function name, the correction portion is appropriately detected. Can not do. Therefore, the computer 100 extracts a variable name or a function name from the source code, analyzes a description other than the variable name or the function name, and determines whether a correction patch is applied. For example, the computer 100 uses a fixed keyword dictionary to determine whether a correction patch has been applied.

次に、固定キーワード辞書記憶部120に格納された固定キーワード辞書について、具体的に説明する。
図7は、固定キーワード辞書の一例を示す図である。固定キーワード辞書121は、例えば表形式のデータ構造となっている。固定キーワード辞書121の各行の第0列には、ソースコードに用いられる単語(記号を含む)の種別(単語種別)が設定されている。例えば「変数型」、「算術演算子」、「関係演算子」、「条件演算子」、「記号・引用符」、「その他」などの単語種別がある。固定キーワード辞書121の各行の第2列以降の各列には、その行に設定された単語種別に該当する単語が設定されている。
Next, the fixed keyword dictionary stored in the fixed keyword dictionary storage unit 120 will be specifically described.
FIG. 7 is a diagram illustrating an example of the fixed keyword dictionary. The fixed keyword dictionary 121 has, for example, a tabular data structure. In the 0th column of each row of the fixed keyword dictionary 121, the type (word type) of a word (including a symbol) used in the source code is set. For example, there are word types such as “variable type”, “arithmetic operator”, “relational operator”, “conditional operator”, “symbol / quote”, and “other”. In the second and subsequent columns of each row of the fixed keyword dictionary 121, a word corresponding to the word type set in that row is set.

単語種別「変数型」は、変数の型(文字型、整数型、浮動小数点型など)を示す単語であり、例えば「int」、「short」などの型名を示す単語が該当する。
単語種別「算術演算子」は、算術演算を示す単語であり、例えば「+」、「−」、「*」、「/」、「%」などの記号が該当する。
The word type “variable type” is a word indicating a variable type (character type, integer type, floating point type, etc.), and corresponds to a word indicating a type name such as “int” or “short”.
The word type “arithmetic operator” is a word indicating an arithmetic operation, and corresponds to a symbol such as “+”, “−”, “*”, “/”, “%”.

単語種別「関係演算子」は、2つの対象の関係を判定するための単語であり、例えば「=」、「>」、「<」、「≠」、「==」、「!=」などの記号が該当する。
単語種別「条件演算子」は、処理の分岐条件を定義するのに用いる単語であり、例えば「if」、「while」、「for」などの単語が該当する。
The word type “relation operator” is a word for determining the relationship between two objects, for example, “=”, “>”, “<”, “≠”, “==”, “! =”, And the like. Symbol is applicable.
The word type “conditional operator” is a word used to define a branch condition of a process, and corresponds to, for example, a word such as “if”, “while”, or “for”.

単語種別「記号・引用符」は、続く文字が記号または引用符であることを示す単語であり、例えば「“」、「¥」、「’」などの記号が該当する。
単語種別「その他」は、上記の単語種別以外の固定キーワードであり、例えば「(」、「)」などの記号が該当する。
The word type "symbol / quotation mark" is a word indicating that the following character is a symbol or a quotation mark, and corresponds to a symbol such as "", "$", "'", and the like.
The word type “others” is a fixed keyword other than the above word types, and corresponds to a symbol such as “(”, “)”.

固定キーワード辞書121は、ソースコードの各行の命令種別の判定や、各単語が固定キーワードか可変キーワードかの判定に用いられる。命令種別の判定は、適用の有無の確認対象の修正パッチと、その修正パッチの適用対象のソースファイルとのそれぞれに対して行われる。   The fixed keyword dictionary 121 is used for determining the instruction type of each line of the source code and determining whether each word is a fixed keyword or a variable keyword. The determination of the instruction type is performed for each of the patch to be checked for the presence or absence of application and the source file to which the patch is applied.

図8は、修正パッチに対する命令種別判定の一例を示す図である。ソースコード取得部141がリポジトリ210から、適用の有無の確認対象の修正パッチ211を取得し、取得した修正パッチ211を命令種別判定部142に送信する。すると命令種別判定部142が、修正パッチ211内のソースコードについて、1行ごとの命令種別を判定する。   FIG. 8 is a diagram illustrating an example of an instruction type determination for a corrected patch. The source code acquisition unit 141 acquires, from the repository 210, the correction patch 211 to be checked for the application, and transmits the acquired correction patch 211 to the instruction type determination unit 142. Then, the instruction type determination unit 142 determines the instruction type of each line of the source code in the correction patch 211.

例えば命令種別判定部142は、種別判別のために、種別判別に不要な修正パッチ211内の記載を削除する編集を行う。例えば命令種別判定部142は、以下の編集処理を行う。   For example, the instruction type determination unit 142 performs editing for deleting the description in the correction patch 211 that is unnecessary for the type determination, for the type determination. For example, the instruction type determination unit 142 performs the following editing processing.

(編集#1)命令種別判定部142は、行頭が「−」の行を削除する。これにより、行の削除の命令の行が、修正パッチ211,212,・・・から削除され、該当行に関する命令種別の判定は行われなくなる。   (Edit # 1) The instruction type determination unit 142 deletes a line whose head is “-”. As a result, the line of the instruction to delete the line is deleted from the correction patches 211, 212,..., And the determination of the instruction type for the line is not performed.

(編集#2)命令種別判定部142は、行頭が「+」の行の先頭の「+」の文字を削除する。
命令種別判定部142は、編集後の修正パッチ211aに含まれるソースコードの各行について、固定キーワード辞書121に基づいて、以下のような基準で命令種別の判定を行う。修正パッチ211aの各行の先頭に示されている数字は、命令種別判定対象の行の行番号であり、説明のために付与したものである。
(Edit # 2) The instruction type determination unit 142 deletes the character “+” at the beginning of the line “+”.
The instruction type determination unit 142 determines the instruction type of each line of the source code included in the edited correction patch 211a based on the fixed keyword dictionary 121 based on the following criteria. The number shown at the beginning of each line of the correction patch 211a is the line number of the line for which the instruction type is to be determined, and is given for explanation.

(判定#1)命令種別判定部142は、空白行、#等のコメント行は、命令種別の判定を行わずに処理をスキップする。
(判定#2)命令種別判定部142は、固定キーワード辞書121に登録されている単語種別(変数型、算術演算子など)を参照し、行頭の単語が「変数型」に登録されている単語と一致した場合は、該当行の命令種別を「宣言」と判定する。
(Determination # 1) The instruction type determination unit 142 skips processing of a comment line such as a blank line or # without performing determination of the instruction type.
(Determination # 2) The instruction type determination unit 142 refers to the word type (variable type, arithmetic operator, etc.) registered in the fixed keyword dictionary 121, and sets the word at the beginning of the line to the word registered in “variable type”. If they match, the instruction type of the corresponding line is determined to be “declaration”.

(判定#3)命令種別判定部142は、固定キーワード辞書121に登録されている単語種別(変数型、算術演算子など)を参照し、行頭の単語が「条件演算子」に登録されている単語と一致した場合は、該当行の命令種別を「条件」と判定する。   (Determination # 3) The instruction type determination unit 142 refers to the word type (variable type, arithmetic operator, etc.) registered in the fixed keyword dictionary 121, and the word at the beginning of the line is registered as a “conditional operator”. If the word matches, the instruction type of the corresponding line is determined as “condition”.

(判定#4)命令種別判定部142は、行頭の単語が「変数型」と「条件演算子」とのいずれかに登録されている単語と一致せず、かつ行内に「=」が出現した場合は、該当行の命令種別を「代入」と判定する。   (Determination # 4) The instruction type determination unit 142 determines that the word at the beginning of the line does not match a word registered in any of “variable type” and “conditional operator”, and “=” appears in the line. In this case, the instruction type of the corresponding line is determined as “assignment”.

(判定#5)命令種別判定部142は、判定#1〜#4のいずれにも該当しない行の命令種別を、「その他」と判定する。
これにより、修正パッチ211aに対応する命令種別情報31が生成される。命令種別判定部142は、生成した命令種別情報31を、命令種別記憶部143に格納する。例えば命令種別判定部142は、命令種別記憶部143内に設けられたパッチ意味用配列143aの要素として、各行の命令種別を格納する。
(Determination # 5) The instruction type determination unit 142 determines that the instruction type of the row that does not correspond to any of the determinations # 1 to # 4 is “other”.
Thereby, the instruction type information 31 corresponding to the correction patch 211a is generated. The instruction type determination unit 142 stores the generated instruction type information 31 in the instruction type storage unit 143. For example, the instruction type determination unit 142 stores the instruction type of each row as an element of the patch meaning array 143a provided in the instruction type storage unit 143.

図9は、配列を用いた修正パッチの命令種別判定処理の一例を示す図である。例えば命令種別判定部142は、作業用配列「tmp_mean_extract[]」を定義する。作業用配列のインデックスの値は、判定対象の行の単語の順番を示す番号である。単語の順番を示す番号は、行の先頭から順に、各単語に、0から昇順の番号が割り当てられているものとする。   FIG. 9 is a diagram illustrating an example of a correction patch instruction type determination process using an array. For example, the instruction type determination unit 142 defines a work array “tmp_mean_extract []”. The value of the index in the working array is a number indicating the order of words in the row to be determined. Numbers indicating the order of words are assumed to be assigned numbers in ascending order from 0, in order from the head of the line.

例えば命令種別判定部142は、修正パッチ211aの最初の行の命令種別を判定する際、判定対象の行内の各単語を、作業用配列に格納する。例えば「short ans = −1;」の命令種別を判定する場合、「short」、「ans」、「=」、「−1」、「;」の各単語が、作業用配列に格納される。なお、作業用配列は、判定対象の行が更新されるごとに初期化される。   For example, when determining the instruction type of the first line of the correction patch 211a, the instruction type determination unit 142 stores each word in the determination target line in the work array. For example, when determining the instruction type of “short ans = −1;”, the words “short”, “ans”, “=”, “−1”, “;” are stored in the work array. The work array is initialized each time a row to be determined is updated.

命令種別判定部142は、作業用配列に格納した単語について、判定#1〜#5のどの判定条件を満たすのかを判断する。例えば命令種別判定部142は、固定キーワード辞書121を参照し、判定対象の行の先頭の単語「short」の単語種別が「変数型」であることを認識する。その結果、命令種別判定部142は、判定対象の行が判定#2の条件を満たしていると判断する。なお、判定対象の行内には「=」が出現しているが、判定#4では先頭の単語が「変数型」と「条件演算子」とのいずれでもないことが条件となっているため、判定#4は満たしていない。そこで命令種別判定部142は、この行の命令種別を「宣言」と判定する。   The instruction type determination unit 142 determines which of the determination conditions # 1 to # 5 is satisfied for the word stored in the work array. For example, the instruction type determination unit 142 refers to the fixed keyword dictionary 121 and recognizes that the word type of the first word “short” of the line to be determined is “variable type”. As a result, the instruction type determination unit 142 determines that the row to be determined satisfies the condition of determination # 2. Note that “=” appears in the row to be determined, but in determination # 4, the condition is that the first word is neither “variable type” nor “conditional operator”. The judgment # 4 is not satisfied. Therefore, the instruction type determination unit 142 determines that the instruction type of this line is “declaration”.

命令種別判定部142は、判定結果をパッチ意味用配列143a「patch_mean_extract[]」に格納する。パッチ意味用配列143aのインデックスの値は、編集後の修正パッチ211a内での判定対象の行の行番号である。行番号は、先頭行から順に、空白またはコメント行以外の各行に、0から昇順の番号が割り当てられているものとする。例えば修正パッチ211a内の先頭の行(行番号「0」)の命令種別は、インデックス値「0」の要素としてパッチ意味用配列143aに格納される。   The instruction type determination unit 142 stores the determination result in the patch meaning array 143a “patch_mean_extract []”. The index value of the patch meaning array 143a is the row number of the row to be determined in the modified patch 211a after editing. The line numbers are assumed to be assigned numbers in ascending order from 0 to each line other than a blank line or a comment line in order from the top line. For example, the instruction type of the first line (line number “0”) in the correction patch 211a is stored in the patch meaning array 143a as an element of the index value “0”.

同様に、修正パッチ211の適用の有無の判定対象のソースファイルに対しても、命令種別の判定が行われる。
図10は、ソースファイルに対する命令種別判定の一例を示す図である。命令種別判定部142は、ソースファイル記憶部110から判定対象のソースファイル111を取得し、ソースファイル111内のソースコードについて、1行ごとに命令種別を判定する。なおソースファイル111の各行の先頭に示されている数字は、命令種別判定対象の行の行番号であり、説明のために付与したものである。
Similarly, the instruction type is also determined for the source file for which the determination of whether the correction patch 211 has been applied is made.
FIG. 10 is a diagram illustrating an example of the instruction type determination for a source file. The instruction type determination unit 142 acquires the source file 111 to be determined from the source file storage unit 110, and determines the instruction type for each line of the source code in the source file 111. The number shown at the beginning of each line of the source file 111 is the line number of the line for which the instruction type is to be determined, and is provided for explanation.

例えば命令種別判定部142は、修正パッチに対する命令種別判定と同様に、判定#1〜#5を行い、ソースファイル111に対応する命令種別情報32を生成する。そして命令種別判定部142は、生成した命令種別情報32を命令種別記憶部143に格納する。例えば命令種別判定部142は、命令種別記憶部143内に設けられたソース意味用配列143bの要素として、各行の命令種別を格納する。   For example, the instruction type determination unit 142 performs the determinations # 1 to # 5 in the same manner as the instruction type determination for the corrected patch, and generates the instruction type information 32 corresponding to the source file 111. Then, the instruction type determination unit 142 stores the generated instruction type information 32 in the instruction type storage unit 143. For example, the instruction type determination unit 142 stores the instruction type of each row as an element of the source meaning array 143b provided in the instruction type storage unit 143.

図11は、配列を用いたソースファイルの命令種別判定処理の一例を示す図である。例えば命令種別判定部142は、ソースファイル111の最初の行の命令種別を判定する際、判定対象の行内の各単語を、作業用配列に格納する。例えば「int res = −1;」の命令種別を判定する場合、「int」、「res」、「=」、「−1」、「;」の各単語が、作業用配列に格納される。   FIG. 11 is a diagram illustrating an example of a source file instruction type determination process using an array. For example, when determining the instruction type of the first line of the source file 111, the instruction type determination unit 142 stores each word in the determination target line in the work array. For example, when determining the instruction type of “int res = −1;”, the words “int”, “res”, “=”, “−1”, “;” are stored in the work array.

命令種別判定部142は、作業用配列に格納した単語について、判定#1〜#5のどの判定条件を満たすのかを判断する。例えば命令種別判定部142は、固定キーワード辞書121を参照し、判定対象の行の先頭の単語「int」の単語種別が「変数型」であることを認識する。その結果、命令種別判定部142は、判定対象の行が判定#2の条件を満たしていると判断する。そこで命令種別判定部142は、この行の命令種別を「宣言」と判定する。   The instruction type determination unit 142 determines which of the determination conditions # 1 to # 5 is satisfied for the word stored in the work array. For example, the instruction type determination unit 142 refers to the fixed keyword dictionary 121 and recognizes that the word type of the first word “int” of the line to be determined is “variable type”. As a result, the instruction type determination unit 142 determines that the row to be determined satisfies the condition of determination # 2. Therefore, the instruction type determination unit 142 determines that the instruction type of this line is “declaration”.

命令種別判定部142は、判定結果をソース意味用配列143b「source_mean_extract[]」に格納する。ソース意味用配列143bのインデックスの値は、ソースファイル111内での判定対象の行の行番号である。行番号は、先頭行から順に、空白またはコメント行以外の各行に、0から昇順の番号が割り当てられているものとする。例えばソースファイル111内の「int res = −1;」の行が20行目(行番号「19」)の場合、この行の命令種別は、インデックス値「19」の要素としてソース意味用配列143bに格納される。   The instruction type determination unit 142 stores the determination result in the source meaning array 143b “source_mean_extract []”. The value of the index of the source meaning array 143b is the line number of the line to be determined in the source file 111. The line numbers are assumed to be assigned numbers in ascending order from 0 to each line other than a blank line or a comment line in order from the top line. For example, if the line of “int res = −1;” in the source file 111 is the 20th line (line number “19”), the instruction type of this line is the source semantic array 143b as an element of the index value “19”. Is stored in

修正パッチ211aとソースファイル111との命令種別判定が完了すると、命令種別情報31,32に基づいて、パッチ導入箇所推定部144が、修正パッチ適用によるソースファイル111内の修正対象の箇所を推定する。   When the instruction type determination of the correction patch 211a and the source file 111 is completed, the patch introduction location estimating unit 144 estimates a correction target location in the source file 111 by applying the correction patch, based on the instruction type information 31 and 32. .

図12は、パッチ導入箇所推定処理の一例を示す図である。パッチ導入箇所推定部144は、修正パッチ211aの命令種別情報31とソースファイル111の命令種別情報32とを比較する。そしてパッチ導入箇所推定部144は、ソースファイル111の命令種別情報32の中から、修正パッチ211aの命令種別情報31の命令種別群と一致する命令種別群を抽出する。図12の例では、修正パッチ211aの命令種別情報31には、「宣言」、「宣言」、「条件」、「代入」、「条件」、「代入」、「その他」、「その他」という並びで命令種別が示されている。パッチ導入箇所推定部144は、同じ命令種別の並びを、ソースファイル111の命令種別情報32の中から抽出する。この場合、複数の箇所から抽出される場合もある。   FIG. 12 is a diagram illustrating an example of the patch introduction location estimation process. The patch introduction location estimating unit 144 compares the instruction type information 31 of the correction patch 211a with the instruction type information 32 of the source file 111. Then, the patch introduction location estimating unit 144 extracts an instruction type group that matches the instruction type group of the instruction type information 31 of the correction patch 211a from the instruction type information 32 of the source file 111. In the example of FIG. 12, the instruction type information 31 of the correction patch 211a includes a list of “declaration”, “declaration”, “condition”, “assignment”, “condition”, “assignment”, “other”, and “other”. Indicates the instruction type. The patch introduction location estimating unit 144 extracts the same sequence of instruction types from the instruction type information 32 of the source file 111. In this case, it may be extracted from a plurality of places.

パッチ導入箇所推定部144は、抽出した命令種別群に対応するソースファイル111内の部分を、パッチ導入推定箇所111a,111bとして特定する。そして、パッチ導入箇所推定部144は、パッチ導入推定箇所111a,111bを示す情報(パッチ導入推定箇所情報145a)を、パッチ導入推定箇所記憶部145に格納する。パッチ導入推定箇所情報145aには、例えば、パッチ導入推定箇所を有するソースファイルのファイル名と、パッチ導入推定箇所の行番号とが示される。   The patch introduction location estimating unit 144 specifies portions in the source file 111 corresponding to the extracted instruction type group as patch introduction estimation locations 111a and 111b. Then, the patch introduction location estimation unit 144 stores information indicating the patch introduction estimation locations 111a and 111b (patch introduction estimation location information 145a) in the patch introduction estimation location storage unit 145. The estimated patch introduction location information 145a indicates, for example, the file name of the source file having the estimated patch introduction location and the line number of the estimated patch introduction location.

パッチ導入推定箇所111a,111bが特定されると、次にマッチング処理部146により、マッチング処理が行われる。
図13は、マッチング処理の一例を示す図である。マッチング処理部146は、固定キーワード辞書記憶部120内の固定キーワード辞書121を参照し、パッチ導入推定箇所111aと修正パッチ211aとに含まれる単語を、可変キーワードと固定キーワードとに分類する。すなわちマッチング処理部146は、固定キーワード辞書121に示されている単語を固定キーワードと判断し、それ以外の単語を可変キーワードと判断する。
When the estimated patch introduction locations 111a and 111b are specified, a matching process is next performed by the matching processing unit 146.
FIG. 13 is a diagram illustrating an example of the matching process. The matching processing unit 146 refers to the fixed keyword dictionary 121 in the fixed keyword dictionary storage unit 120, and classifies words included in the estimated patch introduction location 111a and the modified patch 211a into variable keywords and fixed keywords. That is, the matching processing unit 146 determines a word indicated in the fixed keyword dictionary 121 as a fixed keyword, and determines other words as variable keywords.

そしてマッチング処理部146は、パッチ導入推定箇所111aと修正パッチ211aとの同一行番号の行同士の、固定キーワードの一致率を計算する。
図13の例では、1行目は「一致」、2行目は「不一致」、3行目は「一致」となる。
Then, the matching processing unit 146 calculates the matching rate of the fixed keyword between the lines having the same line number in the estimated patch introduction location 111a and the correction patch 211a.
In the example of FIG. 13, the first line is “match”, the second line is “mismatch”, and the third line is “match”.

以下、図14〜図16を参照して、マッチング処理を具体的に説明する。例えばマッチング処理部146は、パッチ導入推定箇所111aと修正パッチ211aとのソースコードを単語ごとに分割し、配列に格納する。そしてマッチング処理部146は、配列を用いてマッチング処理を行う。   Hereinafter, the matching process will be specifically described with reference to FIGS. For example, the matching processing unit 146 divides the source code of the estimated patch introduction location 111a and the corrected patch 211a for each word and stores them in an array. Then, the matching processing unit 146 performs a matching process using the array.

図14は、配列を用いたマッチング処理の一例を示す図である。パッチ導入推定箇所111a内の単語は、ソースマッチ用配列「source_comp[][]」に格納される。ソースマッチ用配列は2次元配列であり、1つ目のインデックスにはパッチ導入推定箇所111a内の行の行番号が設定され、2つ目のインデックスには行内の単語の順番を示す番号が設定される。ソースマッチ用配列には、1つ目のインデックスに示される行の、2つ目のインデックスに示される順番の単語が、それらのインデックス値に対応する要素として設定される。   FIG. 14 is a diagram illustrating an example of a matching process using an array. The word in the estimated patch introduction location 111a is stored in the source match array “source_comp [] []”. The source match array is a two-dimensional array. The first index is set to the line number of the line in the estimated patch introduction location 111a, and the second index is set to the number indicating the order of the words in the line. Is done. In the source match array, words in the order indicated by the second index in the row indicated by the first index are set as elements corresponding to those index values.

修正パッチ211a内の単語は、パッチマッチ用配列「patch_comp[][]」に格納される。パッチマッチ用配列は2次元配列であり、1つ目のインデックスには修正パッチ211a内の行の行番号が設定され、2つ目のインデックスには行内の単語の順番を示す番号が設定される。パッチマッチ用配列には、1つ目のインデックスに示される行の、2つ目のインデックスに示される順番の単語が、それらのインデックス値に対応する要素として設定される。   The words in the correction patch 211a are stored in the patch matching array “patch_comp [] []”. The patch matching array is a two-dimensional array. The first index is set to the line number of the line in the correction patch 211a, and the second index is set to the number indicating the order of the words in the line. . In the patch matching array, words in the order indicated by the second index in the row indicated by the first index are set as elements corresponding to those index values.

そしてマッチング処理部146は、パッチ導入推定箇所111aと修正パッチ211aとの行ごとの比較を行う際、ソースマッチ用配列とパッチマッチ用配列との、同じインデックス値に設定されている単語同士を比較する。マッチング処理部146は、同一行番号の行内の単語同士の比較により、その行の一致・不一致を判定し、判定結果を結果格納用配列「result_comp[][]」に格納する。結果格納用配列は2次元配列であり、1つ目のインデックスには判定対象の行の行番号が設定され、2つ目のインデックスには行内の単語の順番を示す番号が設定される。図14の例では、比較対象の行の先頭の単語に対応付けて、比較結果が格納されている。すなわち結果格納用配列には、1つ目のインデックスに示される行の判定結果が、2つ目のインデックス値「0」の要素として設定される。   Then, when performing a row-by-row comparison between the estimated patch introduction location 111a and the correction patch 211a, the matching processing unit 146 compares words set to the same index value in the source match array and the patch match array. I do. The matching processing unit 146 determines the match / mismatch of the lines by comparing the words in the lines with the same line number, and stores the determination result in the result storage array “result_comp [] []”. The result storage array is a two-dimensional array, in which the first index is set with the row number of the row to be determined, and the second index is set with a number indicating the order of words in the row. In the example of FIG. 14, the comparison result is stored in association with the first word of the line to be compared. That is, in the result storage array, the determination result of the row indicated by the first index is set as an element of the second index value “0”.

図15は、マッチング結果の一例を示す図である。例えばパッチ導入推定箇所111aの1行目は、「int res = −1;」である。この行には、固定キーワードが3単語(「int」、「=」、「;」)含まれている。また可変キーワードが2単語(「res」、「−1」)含まれている。   FIG. 15 is a diagram illustrating an example of the matching result. For example, the first line of the estimated patch introduction location 111a is “int res = −1;”. This line includes three fixed keywords (“int”, “=”, “;”). Further, two variable keywords ("res", "-1") are included.

また修正パッチ211aの1行目は「short ans = −1;」である。この行には、固定キーワードが3単語(「short」、「=」、「;」)含まれている。また可変キーワードが2単語(「ans」、「−1」)含まれている。   The first line of the correction patch 211a is “short ans = −1;”. This line includes three fixed keywords (“short”, “=”, “;”). Also, two variable keywords ("ans", "-1") are included.

1行目の行同士を比較すると、パッチ導入推定箇所111aの固定キーワード「int」が、修正パッチ211aの固定キーワード「short」に対応する。「int」と「short」とは、固定キーワード辞書121において、いずれも「変数型」であることが示されている。マッチング処理部146は、このように単語種別が「変数型」の固定キーワード同士は、一致すると判定する。またマッチング処理部146は、単語種別が「変数型」以外の場合、単語の1以上の文字または記号がすべて同じ場合、単語が一致すると判定する。パッチ導入推定箇所111aの1行目と修正パッチ211aの1行目との残りの固定キーワード「=」、「;」はいずれも記号が一致している。その結果、マッチング処理部146は、1行目の固定キーワードの一致率を100%とする。   When the first line is compared with each other, the fixed keyword “int” of the estimated patch introduction location 111a corresponds to the fixed keyword “short” of the correction patch 211a. “Int” and “short” are both shown to be “variable types” in the fixed keyword dictionary 121. The matching processing unit 146 determines that the fixed keywords having the word type “variable type” match each other. When the word type is other than “variable type”, the matching processing unit 146 determines that the words match if one or more characters or symbols of the words are all the same. The symbols of the remaining fixed keywords “=” and “;” in the first line of the estimated patch introduction location 111a and the first line of the modified patch 211a are the same. As a result, the matching processing unit 146 sets the matching rate of the fixed keywords in the first row to 100%.

パッチ導入推定箇所111aの2行目は、「int c = res + 1;」である。この行には、固定キーワードが4単語(「int」、「=」、「+」、「;」)含まれている。また可変キーワードが3単語(「c」、「res」、「1」)含まれている。   The second line of the patch introduction estimation location 111a is “int c = res + 1;”. This line includes four fixed keywords (“int”, “=”, “+”, “;”). Also, three variable keywords (“c”, “res”, “1”) are included.

また修正パッチ211aの2行目は「short x;」である。この行には、固定キーワードが2単語(「short」、「;」)含まれている。また可変キーワードが1単語(「x」)含まれている。   The second line of the correction patch 211a is “short x;”. This line includes two fixed keywords ("short", ";"). Further, one variable keyword (“x”) is included.

2行目の行同士を比較すると、パッチ導入推定箇所111aの固定キーワード「int」が、修正パッチ211aの固定キーワード「short」に対応する。「int」と「short」とは、固定キーワード辞書121において、いずれも「変数型」であるため、マッチング処理部146は固定キーワードが一致すると判定する。パッチ導入推定箇所111aの2行目の固定キーワード「=」(3番目の単語)は追加された単語であり、修正パッチ211aの2行目には対応する固定キーワードが存在しない。そのためマッチング処理部146は、固定キーワード「=」については不一致と判定する。パッチ導入推定箇所111aの2行目の固定キーワード「;」は7番目の単語であり、修正パッチ211aには7番目の単語は存在しない。そのためマッチング処理部146は、固定キーワード「;」については不一致と判定する。その結果、マッチング処理部146は、2行目の固定キーワードの一致率を33%(1/3)とする。なお一致率は、例えば判定対象の2つ行のうちの固定キーワードを多く含む行の固定キーワード数で、一致した固定キーワード数を除算することにより求められる。   Comparing the second row, the fixed keyword “int” of the patch introduction estimated location 111a corresponds to the fixed keyword “short” of the correction patch 211a. Since both “int” and “short” are “variable types” in the fixed keyword dictionary 121, the matching processing unit 146 determines that the fixed keywords match. The fixed keyword “=” (third word) on the second line of the estimated patch introduction location 111a is an added word, and the corresponding fixed keyword does not exist on the second line of the modified patch 211a. Therefore, the matching processing unit 146 determines that the fixed keyword “=” does not match. The fixed keyword ";" on the second line of the estimated patch introduction location 111a is the seventh word, and the modified patch 211a does not have the seventh word. Therefore, the matching processing unit 146 determines that the fixed keyword “;” does not match. As a result, the matching processing unit 146 sets the matching rate of the fixed keywords in the second row to 33% ((). The matching rate is obtained, for example, by dividing the number of matched fixed keywords by the number of fixed keywords in a row that includes a large number of fixed keywords among the two rows to be determined.

マッチング処理部146は、行単位での比較結果をマッチング結果記憶部147内の結果格納用配列147aに格納する。
なおマッチング処理部146は、マッチング処理では、可変キーワードの変換前と変換後との対応関係を、メモリ102などに記憶しておくことができる。記憶した対応関係は、以後の可変キーワードの特定に利用することができる。
The matching processing unit 146 stores the comparison result for each row in the result storage array 147a in the matching result storage unit 147.
In the matching process, the matching processing unit 146 can store the correspondence between the variable keyword before and after the conversion in the memory 102 or the like. The stored correspondence relationship can be used for specifying a variable keyword thereafter.

図16は、可変キーワードの対応関係の保存例を示す図である。図16の例では、パッチ導入推定箇所111aにおける「res」、「−1」、「*s」それぞれと、修正パッチ211aの「ans」、「−1」、「*z」それぞれとの対応関係が、メモリ102に保存される。マッチング処理部146は、例えば保存された対応関係を用いて、改変された可変キーワードを容易に検出することができる。例えばマッチング処理部146は、可変キーワードとして記憶した単語については、固定キーワード辞書121と照合するまでもなく、可変キーワードと判断する。   FIG. 16 is a diagram illustrating an example of storing the correspondence between variable keywords. In the example of FIG. 16, the correspondence between “res”, “−1”, and “* s” at the estimated patch introduction location 111a and each of “ans”, “−1”, and “* z” of the correction patch 211a. Are stored in the memory 102. The matching processing unit 146 can easily detect the modified variable keyword using, for example, the stored correspondence. For example, the matching processing unit 146 determines a word stored as a variable keyword as a variable keyword without having to collate it with the fixed keyword dictionary 121.

また改変された可変キーワードを記憶しておくことで、例えば修正パッチの適用状況を表示する際に、結果出力部150が、保存された可変キーワードに基づいて、改変された可変キーワードを強調表示することもできる。   Also, by storing the modified variable keywords, the result output unit 150 highlights the modified variable keywords based on the stored variable keywords, for example, when displaying the application status of the modified patch. You can also.

マッチング処理が完了すると、類似度算出部148により、パッチ導入推定箇所111aと修正パッチ211aとの類似度が算出される。
図17は、類似度算出処理の一例を示す図である。類似度算出部148は、パッチ導入推定箇所111aと修正パッチ211aとの行単位での比較結果に基づいて、一致する行の割合(一致率)を、類似度として計算する。図17の例では、8行のうちの7行で一致しており、類似度は87.5%である。
When the matching process is completed, the similarity calculating unit 148 calculates the similarity between the estimated patch introduction location 111a and the correction patch 211a.
FIG. 17 is a diagram illustrating an example of the similarity calculation process. The similarity calculation unit 148 calculates the proportion of matching rows (matching rate) as the similarity based on the comparison result of the patch introduction estimated portion 111a and the correction patch 211a in units of rows. In the example of FIG. 17, there is a match in seven of the eight rows, and the similarity is 87.5%.

次に類似度算出部148は、類似度のランク分けを行う。例えば類似度算出部148は、類似度が100%であれば一致と判定する。また類似度算出部148は、類似度が100%未満で、類似度閾値記憶部130に格納されている類似度閾値131以上であれば、類似度高と判定する。類似度高は、部分一致(partial match)と呼ぶこともある。さらに類似度算出部148は、類似度閾値131未満であれば、不一致と判定する。図17の例では、類似度閾値131は50%である。そして類似度算出部148は、算出した類似度とランクとを示す類似度情報149aを、類似度記憶部149に格納する。   Next, the similarity calculating section 148 performs similarity ranking. For example, if the similarity is 100%, the similarity calculating unit 148 determines that they match. If the similarity is less than 100% and equal to or greater than the similarity threshold 131 stored in the similarity threshold storage unit 130, the similarity calculating unit 148 determines that the similarity is high. The high degree of similarity is sometimes called a partial match. Further, the similarity calculation unit 148 determines that they do not match if the value is less than the similarity threshold 131. In the example of FIG. 17, the similarity threshold value 131 is 50%. Then, the similarity calculation unit 148 stores the similarity information 149a indicating the calculated similarity and rank in the similarity storage unit 149.

類似度算出後、結果出力部150が、パッチ適用情報記憶部151内のパッチ適用情報に、パッチ適用判定結果を出力する。
図18は、パッチ適用情報の一例を示す図である。パッチ適用情報151aには、ソースファイルのファイル名が示された列の各行に、その行に対応する修正パッチのソースファイルへの適用状況が示されている。図18の例では、ソースファイル内のパッチ導入推定箇所の類似度が100%の場合(完全一致)、二重丸が設定される。またソースファイル内のパッチ導入推定箇所の類似度が100%未満でかつ閾値以上の場合(類似度高)、丸印が設定される。さらにソースファイル内のパッチ導入推定箇所の類似度が閾値未満の場合(不一致)、ばつ印が設定される。なお、1つのソースファイルについて、パッチ導入推定箇所が複数検出された場合、パッチ導入推定箇所ごとの適用状況がパッチ適用情報151aに設定される。
After calculating the similarity, the result output unit 150 outputs the patch application determination result to the patch application information in the patch application information storage unit 151.
FIG. 18 is a diagram illustrating an example of the patch application information. In the patch application information 151a, the application status of the correction patch corresponding to the row to the source file is indicated in each row of the column indicating the file name of the source file. In the example of FIG. 18, when the similarity of the patch introduction estimated portion in the source file is 100% (perfect match), a double circle is set. If the similarity of the patch introduction estimated portion in the source file is less than 100% and equal to or more than the threshold (high similarity), a circle is set. Further, when the similarity of the patch introduction estimated portion in the source file is less than the threshold value (mismatch), a cross is set. When a plurality of estimated patch introduction locations are detected for one source file, the application status of each estimated patch introduction location is set in the patch application information 151a.

類似度に基づくランク分けにより、完全一致の場合と類似度高の場合とは、修正パッチ適用済みであると推定できる。またランク分けにより不一致とされた場合、修正パッチ未適用であると推定できる。なお修正パッチの適用対象外のソースファイルに対しては、パッチ適用の判定が行われておらず、空欄「−」となっている。   By ranking based on the degree of similarity, it can be estimated that the case of perfect match and the case of high degree of similarity have already been corrected. In addition, when it is determined that they do not match by the ranking, it can be estimated that the modified patch has not been applied. It should be noted that patch application is not determined for source files that are not to be applied with a correction patch, and are blank “-”.

また結果出力部150は、ユーザからの指示に従って、パッチ適用情報151aをモニタ21に表示する。結果出力部150は、ソースファイルと修正パッチとを指定した表示指示を受け付けると、パッチ導入推定箇所と修正パッチとの比較結果を含む結果表示画面をモニタ21に表示することもできる。   Further, the result output unit 150 displays the patch application information 151a on the monitor 21 according to an instruction from the user. When the result output unit 150 receives a display instruction specifying a source file and a modified patch, the result output unit 150 can also display a result display screen including a comparison result between the estimated patch introduction location and the modified patch on the monitor 21.

図19は、結果表示画面の一例を示す図である。結果表示画面41には、修正パッチ導入推定箇所ごとの、算出した類似度(87.5%)と、類似度のランク(partial match)が示されている。また結果表示画面41には、修正パッチ導入推定箇所ごとに、修正パッチ導入推定箇所のソースコードと修正パッチのソースコードとが対比して表示されている。   FIG. 19 is a diagram illustrating an example of the result display screen. The result display screen 41 shows the calculated similarity (87.5%) and the rank of the similarity (partial match) for each estimated location of the modified patch introduction. In addition, on the result display screen 41, the source code of the estimated patch introduction point and the source code of the modified patch are displayed for each estimated estimated patch introduction point.

以下、修正パッチ適用可視化処理の手順について、詳細に説明する。
図20は、修正パッチ適用可視化処理の手順の一例を示すフローチャートである。以下、図20に示す処理をステップ番号に沿って説明する。
Hereinafter, the procedure of the correction patch application visualization processing will be described in detail.
FIG. 20 is a flowchart illustrating an example of the procedure of the correction patch application visualization process. Hereinafter, the processing illustrated in FIG. 20 will be described along with step numbers.

[ステップS101]命令種別判定部142は、命令種別判定処理を行う。命令種別判定処理では、修正パッチのソースコードとOSSのソースファイル内のソースコードとの行ごとの命令種別が判定される。命令種別判定処理の詳細は後述する(図21参照)。   [Step S101] The instruction type determination unit 142 performs an instruction type determination process. In the instruction type determination process, the instruction type of each line between the source code of the correction patch and the source code in the OSS source file is determined. The details of the instruction type determination processing will be described later (see FIG. 21).

[ステップS102]命令種別判定部142は、パッチ導入箇所推定処理を行う。パッチ導入箇所推定処理では、ソースファイル内のソースコードの中から、パッチ適用により修正された可能性がある箇所(1以上の連続の行)が検出される。パッチ導入箇所推定処理の詳細は後述する(図24参照)。   [Step S102] The instruction type determination unit 142 performs a patch introduction location estimation process. In the patch introduction location estimation process, a location (one or more continuous lines) that may have been modified by the patch application is detected from the source code in the source file. Details of the patch introduction location estimation processing will be described later (see FIG. 24).

[ステップS103]命令種別判定部142は、修正パッチ導入推定箇所が少なくとも1つ抽出できたか否かを判断する。命令種別判定部142は、修正パッチ導入推定箇所が抽出できた場合、処理をステップS104に進める。また命令種別判定部142は、修正パッチ導入推定箇所が抽出できなかった場合、処理をステップS106に進める。   [Step S103] The instruction type determination unit 142 determines whether at least one corrected patch introduction estimated location has been extracted. The instruction type determination unit 142 proceeds with the process to step S <b> 104 when the corrected patch introduction estimated portion can be extracted. If the estimated patch introduction location has not been extracted, the instruction type determination unit 142 proceeds to step S106.

[ステップS104]マッチング処理部146は、マッチング処理を行う。マッチング処理では、修正パッチ導入推定箇所と修正パッチとのソースコードについて、行ごとに比較され、一致・不一致が判定される。マッチング処理の詳細は後述する(図25参照)。   [Step S104] The matching processing unit 146 performs a matching process. In the matching process, the source code between the estimated patch introduction location and the modified patch is compared line by line, and a match / mismatch is determined. Details of the matching process will be described later (see FIG. 25).

[ステップS105]類似度算出部148は、類似度算出処理を行う。類似度算出処理では、マッチング処理の結果に基づいて、修正パッチ導入推定箇所と修正パッチとの類似度が算出される。類似度算出処理の詳細は後述する(図26参照)。   [Step S105] The similarity calculating section 148 performs a similarity calculating process. In the similarity calculation process, the similarity between the corrected patch introduction estimated portion and the corrected patch is calculated based on the result of the matching process. Details of the similarity calculation processing will be described later (see FIG. 26).

[ステップS106]結果出力部150は、結果出力処理を行う。結果出力処理では、ソースファイルに対して修正パッチが適用されているか否かを示す情報の格納、または表示が行われる。結果出力処理の詳細は後述する(図27参照)。   [Step S106] The result output unit 150 performs a result output process. In the result output processing, storage or display of information indicating whether or not a correction patch has been applied to the source file is performed. Details of the result output process will be described later (see FIG. 27).

次に、図20に示す各ステップの処理の詳細を説明する。
図21は、命令種別判定処理の手順の一例を示すフローチャートである。以下、図21に示す処理をステップ番号に沿って説明する。
Next, details of the processing of each step shown in FIG. 20 will be described.
FIG. 21 is a flowchart illustrating an example of the procedure of the instruction type determination process. Hereinafter, the processing illustrated in FIG. 21 will be described along the step numbers.

[ステップS111]命令種別判定部142は、修正パッチとOSSのソースファイルとを取得する。例えばソースコード取得部141が、サーバ200内のリポジトリ210から修正パッチを取得すると共に、ソースファイル記憶部110からOSSのソースファイルを取得する。そして、命令種別判定部142は、ソースコード取得部141から修正パッチとソースファイルとを取得する。   [Step S111] The instruction type determination unit 142 acquires a corrected patch and an OSS source file. For example, the source code acquisition unit 141 acquires a correction patch from the repository 210 in the server 200 and acquires an OSS source file from the source file storage unit 110. Then, the instruction type determination unit 142 acquires the corrected patch and the source file from the source code acquisition unit 141.

[ステップS112]命令種別判定部142は、固定キーワード辞書記憶部120から固定キーワード辞書121を取得する。
[ステップS113]命令種別判定部142は、修正パッチとOSSのソースファイルとのそれぞれについて、命令種別情報取得処理を行う。命令情報取得処理の詳細は、図22、図23を参照して説明する。
[Step S112] The instruction type determination unit 142 acquires the fixed keyword dictionary 121 from the fixed keyword dictionary storage unit 120.
[Step S113] The instruction type determination unit 142 performs instruction type information acquisition processing on each of the corrected patch and the OSS source file. Details of the command information acquisition process will be described with reference to FIGS.

図22は、命令種別情報取得処理の手順の詳細を示すフローチャートの前半である。以下、図22に示す処理をステップ番号に沿って説明する。
[ステップS121]命令種別判定部142は、配列のインデックスの値を示す変数iに初期値「0」を設定する。
FIG. 22 is the first half of a flowchart showing details of the procedure of the command type information acquisition process. Hereinafter, the processing illustrated in FIG. 22 will be described along the step numbers.
[Step S121] The instruction type determination unit 142 sets an initial value “0” to a variable i indicating an index value of an array.

[ステップS122]命令種別判定部142は、修正パッチまたはソースファイル内に未選択の行があるか否かを判断する。命令種別判定部142は、未選択の行がある場合、処理をステップS123に進める。また命令種別判定部142は、すべての行が選択済みの場合、命令種別情報取得処理を終了する。   [Step S122] The instruction type determination unit 142 determines whether there is an unselected line in the modified patch or the source file. When there is an unselected line, the instruction type determination unit 142 proceeds with the process to step S123. When all the rows have been selected, the instruction type determination unit 142 ends the instruction type information acquisition processing.

[ステップS123]命令種別判定部142は、修正パッチまたはソースファイルの先頭から順に、未選択の次の行を選択する。
[ステップS124]命令種別判定部142は、選択した行から単語を抽出し、作業用配列に格納する。
[Step S123] The instruction type determination unit 142 selects the next unselected line in order from the top of the modified patch or the source file.
[Step S124] The instruction type determination unit 142 extracts a word from the selected line and stores it in the work array.

[ステップS125]命令種別判定部142は、選択した行の先頭に「−」があるか否かを判断する。例えば命令種別判定部142は、作業用配列の最初の要素に「−」の単語が格納されていれば、先頭に「−」があると判断する。命令種別判定部142は、先頭に「−」がある場合、処理をステップS126に進める。また命令種別判定部142は、先頭に「−」がないと判断した場合、処理をステップS127に進める。   [Step S125] The instruction type determination unit 142 determines whether "-" is at the beginning of the selected line. For example, if the word “−” is stored in the first element of the working array, the instruction type determination unit 142 determines that “−” is at the beginning. If the instruction type determination unit 142 has “-” at the beginning, the process proceeds to step S126. If the instruction type determination unit 142 determines that there is no "-" at the beginning, the process proceeds to step S127.

なお先頭に「−」が設定された行を含むのは修正パッチのみである。そのためソースファイルに対する命令種別情報取得処理を行う場合、ステップS125,S126の処理をスキップしてもよい。   It is to be noted that only the corrected patch includes a line with "-" at the beginning. Therefore, when performing the instruction type information acquisition processing for the source file, the processing of steps S125 and S126 may be skipped.

[ステップS126]命令種別判定部142は、修正パッチの選択された行を削除する。命令種別判定部142は、その後、処理をステップS123に進める。
[ステップS127]命令種別判定部142は、選択した行が空白行またはコメント行であるか否かを判断する。例えば命令種別判定部142は、「#」で始まる行をコメント行と判断する。命令種別判定部142は、空白行またはコメント行の場合、処理をステップS123に進める。また命令種別判定部142は、空白行およびコメント行のいずれでもなければ、処理をステップS128に進める。
[Step S126] The instruction type determination unit 142 deletes the selected line of the modified patch. Thereafter, the instruction type determination unit 142 proceeds with the process to step S123.
[Step S127] The instruction type determination unit 142 determines whether the selected line is a blank line or a comment line. For example, the instruction type determination unit 142 determines that a line beginning with “#” is a comment line. In the case of a blank line or a comment line, the instruction type determination unit 142 proceeds with the process to step S123. If neither the blank line nor the comment line is present, the instruction type determination unit 142 proceeds with the process to step S128.

[ステップS128]命令種別判定部142は、選択した行の先頭に「+」が単体で存在するか否かを判断する。命令種別判定部142は、先頭に「+」が単体で存在する場合、処理をステップS129に進める。また命令種別判定部142は、先頭に「+」が単体で存在しない場合、処理をステップS131(図23参照)に進める。   [Step S128] The instruction type determination unit 142 determines whether “+” alone exists at the head of the selected line. If “+” is present alone at the beginning, the instruction type determination unit 142 proceeds with the process to step S129. In addition, when there is no single “+” at the beginning, the instruction type determination unit 142 advances the processing to step S131 (see FIG. 23).

なお先頭に「+」が単独で設定された行を含むのは修正パッチのみである。そのためソースファイルに対する命令種別情報取得処理を行う場合、ステップS128,S129の処理をスキップしてもよい。   It is to be noted that only the corrected patch includes a line in which “+” is set alone at the beginning. Therefore, when performing the instruction type information acquisition processing for the source file, the processing of steps S128 and S129 may be skipped.

[ステップS129]命令種別判定部142は、修正パッチの選択された行から、先頭の「+」を削除する。その後、命令種別判定部142は、処理をステップS131(図23参照)に進める。   [Step S129] The instruction type determination unit 142 deletes the leading “+” from the selected line of the correction patch. Thereafter, the instruction type determination unit 142 proceeds with the process to step S131 (see FIG. 23).

図23は、命令種別情報取得処理の手順の詳細を示すフローチャートの後半である。以下、図23に示す処理をステップ番号に沿って説明する。
[ステップS131]命令種別判定部142は、選択した行の先頭に、固定キーワード辞書121において「変数型」とされている単語があるか否かを判断する。行の先頭の単語が「int」や「short」などの変数型を指定する単語の場合、その行は、変数型を宣言する命令文であると考えられる。命令種別判定部142は、先頭の単語が変数型の場合、処理をステップS132に進める。また命令種別判定部142は、先頭の単語が変数型でなければ、処理をステップS133に進める。
FIG. 23 is the latter half of the flowchart showing details of the procedure of the command type information acquisition processing. Hereinafter, the processing illustrated in FIG. 23 will be described along the step numbers.
[Step S131] The instruction type determination unit 142 determines whether or not there is a word that is “variable type” in the fixed keyword dictionary 121 at the beginning of the selected line. If the first word of the line is a word that specifies a variable type, such as “int” or “short,” the line is considered to be a statement declaring the variable type. When the first word is of the variable type, the instruction type determination unit 142 proceeds to step S132. If the first word is not a variable type, the instruction type determination unit 142 advances the process to step S133.

[ステップS132]命令種別判定部142は、ソース意味用配列143bまたはパッチ意味用配列143aのi番目の要素に、「宣言」を格納する。例えば命令種別判定部142は、ソースファイルに対して命令種別情報取得処理を行っている場合、ソース意味用配列143bの要素に「宣言」を格納する。また命令種別判定部142は、修正パッチに対して命令種別情報取得処理を行っている場合、パッチ意味用配列143aの要素に「宣言」を格納する。その後、命令種別判定部142は、処理をステップS138に進める。   [Step S132] The instruction type determination unit 142 stores “declaration” in the i-th element of the source meaning array 143b or the patch meaning array 143a. For example, when the instruction type information acquisition processing is performed on the source file, the instruction type determination unit 142 stores “declaration” in the element of the source meaning array 143b. Further, when the instruction type information acquisition processing is performed on the corrected patch, the instruction type determination unit 142 stores “declaration” in the element of the patch meaning array 143a. Thereafter, the instruction type determination unit 142 proceeds with the process to step S138.

[ステップS133]命令種別判定部142は、選択した行の先頭に、固定キーワード辞書121において「条件演算子」とされている単語があるか否かを判断する。行の先頭の単語が「if」、「while」などの条件演算子の場合、その行は、処理の条件を定義する命令文であると考えられる。命令種別判定部142は、先頭の単語が条件演算子の場合、処理をステップS134に進める。また命令種別判定部142は、先頭の単語が条件演算子でなければ、処理をステップS135に進める。   [Step S133] The instruction type determination unit 142 determines whether there is a word at the head of the selected line that is a “conditional operator” in the fixed keyword dictionary 121. When the first word of a line is a conditional operator such as “if” or “while”, the line is considered to be a statement defining a processing condition. If the first word is a conditional operator, the instruction type determination unit 142 proceeds with the process to step S134. If the first word is not a conditional operator, the instruction type determination unit 142 proceeds with the process to step S135.

[ステップS134]命令種別判定部142は、ソース意味用配列143bまたはパッチ意味用配列143aのi番目の要素に、「条件」を格納する。例えば命令種別判定部142は、ソースファイルに対して命令種別情報取得処理を行っている場合、ソース意味用配列143bの要素に「条件」を格納する。また命令種別判定部142は、修正パッチに対して命令種別情報取得処理を行っている場合、パッチ意味用配列143aの要素に「条件」を格納する。その後、命令種別判定部142は、処理をステップS138に進める。   [Step S134] The instruction type determination unit 142 stores “condition” in the i-th element of the source meaning array 143b or the patch meaning array 143a. For example, when the instruction type information acquisition processing is performed on the source file, the instruction type determination unit 142 stores “condition” in the element of the source meaning array 143b. When the instruction type information acquisition processing is performed on the corrected patch, the instruction type determination unit 142 stores “condition” in the element of the patch meaning array 143a. Thereafter, the instruction type determination unit 142 proceeds with the process to step S138.

[ステップS135]命令種別判定部142は、選択した行の中に、「=」が単体で存在するか否かを判断する。行の中に「=」が単体である場合、その行は、変数への値の代入を指示する命令文であると考えられる。命令種別判定部142は、「=」が単体で存在する場合、処理をステップS136に進める。また命令種別判定部142は、単体の「=」が存在しない場合、処理をステップS137に進める。   [Step S135] The instruction type determination unit 142 determines whether “=” alone exists in the selected line. When “=” is a single item in a line, the line is considered to be a statement instructing the assignment of a value to a variable. If “=” exists alone, the instruction type determination unit 142 proceeds with the process to step S136. If there is no single “=”, the instruction type determination unit 142 proceeds with the process to step S137.

[ステップS136]命令種別判定部142は、ソース意味用配列143bまたはパッチ意味用配列143aのi番目の要素に、「代入」を格納する。例えば命令種別判定部142は、ソースファイルに対して命令種別情報取得処理を行っている場合、ソース意味用配列143bの要素に「代入」を格納する。また命令種別判定部142は、修正パッチに対して命令種別情報取得処理を行っている場合、パッチ意味用配列143aの要素に「代入」を格納する。その後、命令種別判定部142は、処理をステップS138に進める。   [Step S136] The instruction type determination unit 142 stores “assignment” in the i-th element of the source meaning array 143b or the patch meaning array 143a. For example, when the instruction type information acquisition processing is performed on the source file, the instruction type determination unit 142 stores “assignment” as an element of the source meaning array 143b. Further, when the instruction type information acquisition processing is performed on the modified patch, the instruction type determination unit 142 stores “assignment” as an element of the patch meaning array 143a. Thereafter, the instruction type determination unit 142 proceeds with the process to step S138.

[ステップS137]命令種別判定部142は、ソース意味用配列143bまたはパッチ意味用配列143aのi番目の要素に、「その他」を格納する。例えば命令種別判定部142は、ソースファイルに対して命令種別情報取得処理を行っている場合、ソース意味用配列143bの要素に「その他」を格納する。また命令種別判定部142は、修正パッチに対して命令種別情報取得処理を行っている場合、パッチ意味用配列143aの要素に「その他」を格納する。   [Step S137] The instruction type determination unit 142 stores “other” in the i-th element of the source meaning array 143b or the patch meaning array 143a. For example, when the instruction type information acquisition processing is performed on the source file, the instruction type determination unit 142 stores “other” in the element of the source meaning array 143b. When the instruction type information acquisition processing is performed on the corrected patch, the instruction type determination unit 142 stores “other” in the element of the patch meaning array 143a.

[ステップS138]命令種別判定部142は、変数iの値を1だけインクリメントする。その後、命令種別判定部142は、処理をステップS122(図22参照)に進める。   [Step S138] The instruction type determination unit 142 increments the value of the variable i by one. Thereafter, the instruction type determination unit 142 proceeds with the process to step S122 (see FIG. 22).

このように、命令種別判定部142は、図22、図23に示すような命令種別情報取得処理を、修正パッチとソースファイルとのそれぞれのすべての行に対して実行することで、各行の命令種別を示す情報(命令種別情報)を取得する。そしてパッチ導入箇所推定部144により、命令種別情報に基づいてパッチ導入箇所推定処理が行われる。   As described above, the instruction type determination unit 142 executes the instruction type information acquisition processing as shown in FIGS. 22 and 23 on all the lines of the corrected patch and the source file, thereby obtaining the instruction of each line. Acquires information indicating the type (instruction type information). Then, the patch introduction location estimating unit 144 performs a patch introduction location estimation process based on the instruction type information.

図24は、パッチ導入箇所推定処理の手順の一例を示すフローチャートである。以下、図24に示す処理をステップ番号に沿って説明する。
[ステップS141]パッチ導入箇所推定部144は、修正パッチの修正用ソースコードとOSSのソースコードとの行単位の命令種別情報を取得する。
FIG. 24 is a flowchart illustrating an example of a procedure of a patch introduction location estimation process. Hereinafter, the processing illustrated in FIG. 24 will be described along with step numbers.
[Step S141] The patch introduction part estimating unit 144 acquires instruction type information of the correction patch source code and the OSS source code in units of lines.

[ステップS142]パッチ導入箇所推定部144は、修正パッチの修正用ソースコードの命令種別情報とOSSのソースコードの命令種別情報とを比較する。パッチ導入箇所推定部144は、修正パッチの修正用ソースコードの命令種別情報に示される命令種別と、命令種別の並びが一致する部分(ブロック)を、OSSのソースコードの命令種別情報から検索する。   [Step S142] The patch introduction point estimating unit 144 compares the instruction type information of the source code for correction of the corrected patch with the instruction type information of the source code of the OSS. The patch introduction point estimating unit 144 searches the instruction type information of the OSS source code for a part (block) in which the instruction type indicated in the instruction type information of the correction source code of the correction patch matches the order of the instruction type. .

[ステップS143]パッチ導入箇所推定部144は、一致するブロックがあるか否かを判断する。パッチ導入箇所推定部144は、一致するブロックが検出できた場合、処理をステップS144に進める。またパッチ導入箇所推定部144は、一致するブロックが検出できなければ、パッチ導入箇所推定処理を終了する。   [Step S143] The patch introduction location estimation unit 144 determines whether there is a matching block. If a matching block is detected, the patch introduction location estimating unit 144 proceeds with the process to step S144. If a matching block cannot be detected, the patch introduction location estimation unit 144 ends the patch introduction location estimation processing.

[ステップS144]パッチ導入箇所推定部144は、OSSのソースコード内の一致するすべてのブロックを示す情報を、パッチ導入推定箇所としてすべて抽出する。パッチ導入推定箇所には、例えばブロックに含まれる1以上の連続する行のOSSのソースコード内での位置が示される。パッチ導入箇所推定部144は、その後、パッチ導入箇所指定処理を終了する。   [Step S144] The patch introduction location estimation unit 144 extracts all pieces of information indicating all matching blocks in the OSS source code as patch introduction estimation locations. The estimated patch introduction position indicates, for example, the position in the source code of the OSS of one or more continuous lines included in the block. Thereafter, the patch introduction location estimating unit 144 ends the patch introduction location designation processing.

パッチ導入箇所推定処理により1以上のパッチ導入推定箇所が特定できた場合、パッチ導入推定箇所と修正パッチとのマッチング処理が行われる。
図25は、マッチング処理の手順の一例を示すフローチャートである。以下、図25に示す処理をステップ番号に沿って説明する。
If one or more estimated patch introduction locations can be identified by the patch introduction location estimation processing, matching processing between the estimated patch introduction location and the corrected patch is performed.
FIG. 25 is a flowchart illustrating an example of the procedure of the matching process. Hereinafter, the processing illustrated in FIG. 25 will be described along with step numbers.

[ステップS151]マッチング処理部146は、修正パッチの修正用ソースコードを取得する。またマッチング処理部146は、OSSのソースコード内のパッチ導入推定箇所を取得する。例えばマッチング処理部146は、パッチ導入推定箇所情報145a(図12参照)に基づいて、ソースファイル内のパッチ導入推定箇所を認識し、該当箇所に示される1以上の行を取得する。   [Step S151] The matching processing unit 146 acquires a correction source code of the correction patch. Further, the matching processing unit 146 acquires a patch introduction estimated position in the OSS source code. For example, the matching processing unit 146 recognizes the estimated patch introduction location in the source file based on the estimated patch introduction location information 145a (see FIG. 12), and acquires one or more lines indicated in the corresponding location.

[ステップS152]マッチング処理部146は、固定キーワード辞書記憶部120から固定キーワード辞書121を取得する。
[ステップS153]マッチング処理部146は、ソースマッチ用配列とパッチマッチ用配列とに単語を格納する。
[Step S152] The matching processing unit 146 acquires the fixed keyword dictionary 121 from the fixed keyword dictionary storage unit 120.
[Step S153] The matching processing unit 146 stores words in the source match array and the patch match array.

[ステップS154]マッチング処理部146は、ソースマッチ用配列とパッチマッチ用配列とに基づいて、パッチ導入推定箇所と修正パッチの修正用ソースコードを行単位で比較し、一致・不一致を判断する。例えばマッチング処理部146は、比較対象の2つの行のうちの一方の行の固定キーワードと、その固定キーワードと同じ位置(先頭からの単語の順番)にある他方の行の単語とを比較する。そしてマッチング処理部146は、一方の行の固定キーワードと同じ種別および文字の固定キーワードが、他の行の同じ位置にある場合、それらの固定キーワードが一致していると判断する。なおマッチング処理部146は、一方の行の固定キーワードの種別が「変数型」の場合、「変数型」の固定キーワードが他の行の同じ位置にある場合、それらの固定キーワードが一致していると判断する。   [Step S154] Based on the source match array and the patch match array, the matching processing unit 146 compares the estimated patch introduction location and the correction source code of the correction patch on a line-by-line basis, and determines a match / mismatch. For example, the matching processing unit 146 compares the fixed keyword in one of the two lines to be compared with a word in the other line at the same position (order of words from the beginning) as the fixed keyword. Then, when the fixed keywords having the same type and the same character as the fixed keywords in one line are located at the same position in the other line, the matching processing unit 146 determines that the fixed keywords match. When the type of the fixed keyword in one line is “variable type”, and when the fixed keyword of “variable type” is located at the same position in another line, the matching processing unit 146 matches the fixed keywords. Is determined.

[ステップS155]マッチング処理部146は、固定キーワードの一致または不一致を示す情報を、結果格納用配列147a(図15参照)に格納する。
[ステップS156]マッチング処理部146は、固定キーワードが一致すると判定した行の可変キーワードの対応関係を、メモリ102に保存する。
[Step S155] The matching processing unit 146 stores information indicating whether the fixed keyword matches or does not match in the result storage array 147a (see FIG. 15).
[Step S156] The matching processing unit 146 stores, in the memory 102, the correspondence between the variable keywords in the row determined to match the fixed keywords.

マッチング処理が完了すると、類似度算出部148が類似度算出処理を行う。
図26は、類似度算出処理の手順の一例を示すフローチャートである。以下、図26に示す処理をステップ番号に沿って説明する。
When the matching process is completed, the similarity calculation unit 148 performs the similarity calculation process.
FIG. 26 is a flowchart illustrating an example of the procedure of the similarity calculation process. Hereinafter, the processing illustrated in FIG. 26 will be described along with step numbers.

[ステップS161]類似度算出部148は、マッチング結果を取得する。例えば類似度算出部148は、結果格納用配列147aに格納された情報を読み取る。
[ステップS162]類似度算出部148は、類似度閾値記憶部130から類似度閾値131(図17参照)を取得する。
[Step S161] The similarity calculation unit 148 acquires a matching result. For example, the similarity calculation unit 148 reads information stored in the result storage array 147a.
[Step S162] The similarity calculation unit 148 acquires the similarity threshold 131 (see FIG. 17) from the similarity threshold storage unit 130.

[ステップS163]類似度算出部148は、パッチ導入推定箇所と修正パッチとの一致度を算出する。例えば類似度算出部148は、結果格納用配列147aに設定された一致・不一致の判断結果すべてのうちの、一致と判断された割合(一致率)を、類似度として算出する。この際、類似度算出部148は、類似度のランク分けをすることもできる。例えば類似度算出部148は、類似度が100%であれば、類似度のランクを「一致」とする。また類似度算出部148は、類似度が100%未満、類似度閾値以上であれば、類似度のランクを「類似度高(または部分一致:partial match)」とする。また類似度算出部148は、類似度が類似度閾値未満であれば、類似度のランクを「不一致」とする。   [Step S163] The similarity calculation unit 148 calculates the degree of coincidence between the estimated patch introduction location and the corrected patch. For example, the similarity calculating unit 148 calculates, as the similarity, the ratio of the determination of the match (match rate) among all the determination results of the match / mismatch set in the result storage array 147a. At this time, the similarity calculating unit 148 can also classify the similarity. For example, if the similarity is 100%, the similarity calculating unit 148 sets the rank of the similarity to “match”. If the similarity is less than 100% and equal to or greater than the similarity threshold, the similarity calculating unit 148 sets the rank of the similarity to “high similarity (or partial match)”. When the similarity is less than the similarity threshold, the similarity calculating unit 148 sets the rank of the similarity to “mismatch”.

[ステップS164]類似度算出部148は、類似度を示す類似度情報149a(図17参照)を出力する。
類似度が算出されると、結果出力部150により、結果出力処理が行われる。
[Step S164] The similarity calculator 148 outputs similarity information 149a (see FIG. 17) indicating the similarity.
When the similarity is calculated, the result output unit 150 performs a result output process.

図27は、結果出力処理の手順の一例を示すフローチャートである。以下、図27に示す処理をステップ番号に沿って説明する。
[ステップS171]結果出力部150は、類似度情報とパッチ導入推定箇所情報とを取得する。また結果出力部150は、ソースコード取得部141から、取得した修正パッチのパッチ名と、取得したソースファイルのファイル名とを取得する。
FIG. 27 is a flowchart illustrating an example of a procedure of a result output process. Hereinafter, the processing illustrated in FIG. 27 will be described along the step numbers.
[Step S171] The result output unit 150 acquires similarity information and patch introduction estimated location information. In addition, the result output unit 150 acquires the patch name of the acquired correction patch and the file name of the acquired source file from the source code acquisition unit 141.

[ステップS172]結果出力部150は、パッチ適用情報記憶部151から、パッチ適用情報151aを取得する。
[ステップS173]結果出力部150は、類似度情報とパッチ導入推定箇所情報に基づいて、パッチ適用情報151aを更新する。例えば結果出力部150は、パッチ名とソースファイル名との組に対応付けて、類似度情報とパッチ導入推定箇所情報とを、パッチ適用情報151aに格納する。また結果出力部150は、パッチ適用情報151aをモニタ21に表示することもできる。
[Step S172] The result output unit 150 acquires the patch application information 151a from the patch application information storage unit 151.
[Step S173] The result output unit 150 updates the patch application information 151a based on the similarity information and the estimated patch introduction location information. For example, the result output unit 150 stores the similarity information and the estimated patch introduction location information in the patch application information 151a in association with the pair of the patch name and the source file name. The result output unit 150 can also display the patch application information 151a on the monitor 21.

このようにして、OSSのソースファイルの変数名や関数名が変更されていても、ソースファイルに対する修正パッチの適用の有無を適切に判断し、判断結果を可視化することができる。   In this way, even if the variable name or function name of the OSS source file has been changed, it is possible to appropriately determine whether or not a correction patch has been applied to the source file and visualize the determination result.

[その他の実施の形態]
第2の実施の形態では、OSSに修正パッチを適用する場合を想定しているが、第2の実施の形態に示したパッチ適用確認方法は、OSS以外のソフトウェアにも適用可能である。
[Other embodiments]
In the second embodiment, it is assumed that a patch is applied to the OSS. However, the patch application confirmation method described in the second embodiment can be applied to software other than the OSS.

また第2の実施の形態では、マッチング処理部146は、種別が変数型の単語については、比較される2つの単語が共に変数型であれば一致と判定しているが、変数型の単語について、文字または記号が同一の場合に一致と判定するようにしてもよい。例えば比較対象の単語が、変数型のうちの文字型を指定する「char」と整数型を指定する「int」との場合、マッチング処理部146は、これらの単語の種別は同じ変数型であるが、文字が異なるため不一致と判定する。   Further, in the second embodiment, the matching processing unit 146 determines that a word having a variable type is a match if the two words to be compared are both variable types. , May be determined to be the same when the characters or symbols are the same. For example, when the words to be compared are “char” specifying a character type among variable types and “int” specifying an integer type, the matching processing unit 146 determines that the types of these words are the same variable type. Are determined to be mismatched because the characters are different.

以上、実施の形態を例示したが、実施の形態で示した各部の構成は同様の機能を有する他のものに置換することができる。また、他の任意の構成物や工程が付加されてもよい。さらに、前述した実施の形態のうちの任意の2以上の構成(特徴)を組み合わせたものであってもよい。   As described above, the embodiment has been exemplified, but the configuration of each unit described in the embodiment can be replaced with another having the same function. Further, other arbitrary components and steps may be added. Further, any two or more configurations (features) of the above-described embodiments may be combined.

1 パッチファイル
1a 修正命令列
2 ソースファイル
2a 種別一致命令列
10 情報処理装置
11 記憶部
12 処理部
DESCRIPTION OF SYMBOLS 1 Patch file 1a Correction instruction sequence 2 Source file 2a Type matching instruction sequence 10 Information processing device 11 Storage unit 12 Processing unit

Claims (7)

一部の命令列を修正命令列に変更するパッチの適用対象であるソースファイルを記憶する記憶部と、
前記修正命令列を含むパッチファイルに基づいて、前記修正命令列内の各命令の命令種別を示すパッチ命令種別情報を生成し、前記ソースファイル内の各命令の命令種別を示すソース命令種別情報を生成し、前記パッチ命令種別情報と前記ソース命令種別情報とに基づいて、前記ソースファイルから、前記修正命令列と命令種別の並びが一致する種別一致命令列を抽出し、前記種別一致命令列と前記修正命令列との、変数名と関数名とを除外した記述内容に基づいて、前記ソースファイルに前記パッチが適用されているか否かを判定する処理部と、
を有する情報処理装置。
A storage unit for storing a source file to which a patch for changing some instruction sequences to a correction instruction sequence is applied;
Based on the patch file including the correction instruction sequence, patch instruction type information indicating the instruction type of each instruction in the correction instruction sequence is generated, and source instruction type information indicating the instruction type of each instruction in the source file is generated. Generating, based on the patch instruction type information and the source instruction type information, extracting, from the source file, a type matching instruction sequence in which the corrected instruction sequence matches the instruction type sequence; A processing unit that determines whether or not the patch has been applied to the source file, based on the description content excluding the variable name and the function name, with the correction instruction sequence,
Information processing device having
前記処理部は、変数名と関数名とを除外した前記種別一致命令列の記述内容と、変数名と関数名とを除外した前記修正命令列の記述内容との類似度を算出し、前記類似度に基づいて、前記ソースファイルに前記パッチが適用されているか否かを判定する、
請求項1記載の情報処理装置。
The processing unit calculates the similarity between the description content of the type matching instruction sequence excluding the variable name and the function name and the description content of the correction instruction sequence excluding the variable name and the function name, and calculates the similarity. Determining whether the patch has been applied to the source file based on the degree;
The information processing device according to claim 1.
前記処理部は、前記種別一致命令列と前記修正命令列とのそれぞれの命令行に先頭から順に行番号を付与し、同じ行番号の行同士の記述の同一性を判定し、一致すると判定した行の割合を前記類似度とする、
請求項2記載の情報処理装置。
The processing unit assigns a line number to each instruction line of the type matching instruction sequence and the correction instruction sequence in order from the beginning, determines the identity of descriptions of lines having the same line number, and determines that they match. The ratio of rows is the similarity,
The information processing device according to claim 2.
前記記憶部は、行間の同一性の判定において比較対象とする単語のリストを含むキーワード辞書をさらに記憶し、
前記処理部は、前記種別一致命令列の第1の行内の前記キーワード辞書に含まれる単語と、前記修正命令列における、前記第1の行と同じ行番号の第2の行内の前記キーワード辞書に含まれる単語との比較結果に基づいて、同じ行番号の行同士の同一性を判定する、
請求項3記載の情報処理装置。
The storage unit further stores a keyword dictionary including a list of words to be compared in determination of the identity between lines,
The processing unit stores a word included in the keyword dictionary in a first line of the type matching instruction sequence and the keyword dictionary in a second line having the same line number as the first line in the correction instruction sequence. Based on the result of comparison with the included words, determine the identity of the lines with the same line number,
The information processing device according to claim 3.
一部の命令列を修正命令列に変更するパッチ用の、前記修正命令列を含むパッチファイルを配布するサーバと、
前記パッチの適用対象であるソースファイルを記憶する記憶部と、前記サーバから前記パッチファイルを取得し、前記パッチファイルに基づいて、前記修正命令列内の各命令の命令種別を示すパッチ命令種別情報を生成し、前記ソースファイル内の各命令の命令種別を示すソース命令種別情報を生成し、前記ソース命令種別情報と前記パッチ命令種別情報とに基づいて、前記ソースファイルから、前記修正命令列と命令種別の並びが一致する種別一致命令列を抽出し、前記種別一致命令列と前記修正命令列との、変数名と関数名とを除外した記述内容に基づいて、前記ソースファイルに前記パッチが適用されているか否かを判定する、処理部と、を有する情報処理装置と、
を有するパッチ適用確認システム。
A server for distributing a patch file including the correction instruction sequence for a patch for changing a part of the instruction sequence to a correction instruction sequence,
A storage unit for storing a source file to which the patch is to be applied; and a patch instruction type information indicating an instruction type of each instruction in the correction instruction sequence based on the patch file, acquiring the patch file from the server. Generating source instruction type information indicating the instruction type of each instruction in the source file, and based on the source instruction type information and the patch instruction type information, from the source file, the correction instruction sequence and A type-matching instruction sequence in which the order of the instruction types matches is extracted, and the patch is included in the source file based on the description contents of the type-matching instruction sequence and the correction instruction sequence, excluding variable names and function names. An information processing apparatus having a processing unit, which determines whether or not the information is applied; and
Patch application confirmation system having
コンピュータが、
一部の命令列を修正命令列に変更するパッチ用の、前記修正命令列を含むパッチファイルに基づいて、前記修正命令列内の各命令の命令種別を示すパッチ命令種別情報を生成し、
前記パッチの適用対象であるソースファイル内の各命令の命令種別を示すソース命令種別情報を生成し、
前記パッチ命令種別情報と前記ソース命令種別情報とに基づいて、前記ソースファイルから、前記修正命令列と命令種別の並びが一致する種別一致命令列を抽出し、
前記種別一致命令列と前記修正命令列との、変数名と関数名とを除外した記述内容に基づいて、前記ソースファイルに前記パッチが適用されているか否かを判定する、
パッチ適用確認方法。
Computer
For a patch that changes a part of the instruction sequence to a correction instruction sequence, based on a patch file including the correction instruction sequence, generate patch instruction type information indicating the instruction type of each instruction in the correction instruction sequence,
Generating source instruction type information indicating an instruction type of each instruction in a source file to which the patch is applied;
Based on the patch instruction type information and the source instruction type information, from the source file, extract a type matching instruction sequence in which the sequence of the correction instruction sequence and the instruction type match,
Determining whether the patch has been applied to the source file, based on the description of the type matching instruction sequence and the correction instruction sequence, excluding variable names and function names;
Patch application confirmation method.
コンピュータに、
一部の命令列を修正命令列に変更するパッチ用の、前記修正命令列を含むパッチファイルに基づいて、前記修正命令列内の各命令の命令種別を示すパッチ命令種別情報を生成し、
前記パッチの適用対象であるソースファイル内の各命令の命令種別を示すソース命令種別情報を生成し、
前記パッチ命令種別情報と前記ソース命令種別情報とに基づいて、前記ソースファイルから、前記修正命令列と命令種別の並びが一致する種別一致命令列を抽出し、
前記種別一致命令列と前記修正命令列との、変数名と関数名とを除外した記述内容に基づいて、前記ソースファイルに前記パッチが適用されているか否かを判定する、
処理を実行させるパッチ適用確認プログラム。
On the computer,
For a patch that changes a part of the instruction sequence to a correction instruction sequence, based on a patch file including the correction instruction sequence, generate patch instruction type information indicating the instruction type of each instruction in the correction instruction sequence,
Generating source instruction type information indicating an instruction type of each instruction in a source file to which the patch is applied;
Based on the patch instruction type information and the source instruction type information, from the source file, extract a type matching instruction sequence in which the sequence of the correction instruction sequence and the instruction type match,
Determining whether the patch has been applied to the source file, based on the description of the type matching instruction sequence and the correction instruction sequence, excluding variable names and function names;
A patch application confirmation program that executes processing.
JP2018135851A 2018-07-19 2018-07-19 Information processing device, patch application confirmation system, patch application confirmation method, and patch application confirmation program Active JP7075011B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2018135851A JP7075011B2 (en) 2018-07-19 2018-07-19 Information processing device, patch application confirmation system, patch application confirmation method, and patch application confirmation program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2018135851A JP7075011B2 (en) 2018-07-19 2018-07-19 Information processing device, patch application confirmation system, patch application confirmation method, and patch application confirmation program

Publications (2)

Publication Number Publication Date
JP2020013385A true JP2020013385A (en) 2020-01-23
JP7075011B2 JP7075011B2 (en) 2022-05-25

Family

ID=69169884

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2018135851A Active JP7075011B2 (en) 2018-07-19 2018-07-19 Information processing device, patch application confirmation system, patch application confirmation method, and patch application confirmation program

Country Status (1)

Country Link
JP (1) JP7075011B2 (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010086072A (en) * 2008-09-29 2010-04-15 Toshiba Corp Computer system and method of confirming/applying corrective patch
WO2017061270A1 (en) * 2015-10-09 2017-04-13 日本電信電話株式会社 Vulnerability discovering device, vulnerability discovering method, and vulnerability discovering program

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010086072A (en) * 2008-09-29 2010-04-15 Toshiba Corp Computer system and method of confirming/applying corrective patch
WO2017061270A1 (en) * 2015-10-09 2017-04-13 日本電信電話株式会社 Vulnerability discovering device, vulnerability discovering method, and vulnerability discovering program

Also Published As

Publication number Publication date
JP7075011B2 (en) 2022-05-25

Similar Documents

Publication Publication Date Title
US10540350B2 (en) Source code search engine
US8181171B2 (en) Method and apparatus for analyzing large scale program and generation of code from degenerated program dependence graph
US20170068676A1 (en) Layer Identification and Dependency Analysis for Management of Images
US10430469B2 (en) Enhanced document input parsing
US20140013299A1 (en) Generalization and/or specialization of code fragments
US11714636B2 (en) Methods and arrangements to process comments
US20160224447A1 (en) Reliability verification apparatus and storage system
CN110945559A (en) Method and system for optimized visual summary of temporal event data sequences
CN110618926A (en) Source code analysis method and source code analysis device
RU2716553C1 (en) Signature creation device, signature creation method, recording medium in which signature creation program is recorded, and software determination system
CN113946366A (en) Code analysis method, system and computing equipment
US7624124B2 (en) System and method for assisting generation of business specification
JP2016009344A (en) Test case generation program, test case generation method, and test case generation device
JP2019079312A (en) Source code analysis device, source code analysis method, and source code analysis program
US20140324411A1 (en) Translation validation
CN110955632A (en) File index generation method and device
JP2017049639A (en) Evaluation program, procedure manual evaluation method, and evaluation device
JP7075011B2 (en) Information processing device, patch application confirmation system, patch application confirmation method, and patch application confirmation program
US11250127B2 (en) Binary software composition analysis
US9817659B2 (en) Artifact normalization
JP6447111B2 (en) Common information providing program, common information providing method, and common information providing apparatus
CN111310442B (en) Method for mining shape-word error correction corpus, error correction method, device and storage medium
JP5578625B2 (en) Program analysis apparatus, program analysis method, and program
JP6748357B2 (en) Analysis device, analysis program, and analysis method
US20220269681A1 (en) Computer-readable recording medium storing data specifying program, device, and method

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20210408

RD02 Notification of acceptance of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7422

Effective date: 20210413

RD04 Notification of resignation of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7424

Effective date: 20210413

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20220309

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20220412

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20220425

R150 Certificate of patent or registration of utility model

Ref document number: 7075011

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150