JP2007133818A - Apparatus and method for detecting data alteration - Google Patents

Apparatus and method for detecting data alteration Download PDF

Info

Publication number
JP2007133818A
JP2007133818A JP2005328646A JP2005328646A JP2007133818A JP 2007133818 A JP2007133818 A JP 2007133818A JP 2005328646 A JP2005328646 A JP 2005328646A JP 2005328646 A JP2005328646 A JP 2005328646A JP 2007133818 A JP2007133818 A JP 2007133818A
Authority
JP
Japan
Prior art keywords
hash value
data
storage device
stored
vertex
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2005328646A
Other languages
Japanese (ja)
Inventor
Tomonari Fujita
智成 藤田
Ikuo Yoda
育生 依田
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.)
Nippon Telegraph and Telephone Corp
Original Assignee
Nippon Telegraph and Telephone Corp
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 Nippon Telegraph and Telephone Corp filed Critical Nippon Telegraph and Telephone Corp
Priority to JP2005328646A priority Critical patent/JP2007133818A/en
Publication of JP2007133818A publication Critical patent/JP2007133818A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Storage Device Security (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide an apparatus and method for detecting data alteration, capable of detecting alteration of data without change of a file system. <P>SOLUTION: The apparatus 1 which is connected to an external storage device 3 storing data to be stored and hash values of the data to be stored comprises an internal storage device 17 storing a hash value of apex, a hash value which can be the hash value of apex and data to be stored necessary for update of the hash value of apex; a comparison part 14 comparing the hash value of apex with the hash value of data to be stored; and an internal storage device management part 16 temporarily storing a hash value of data to be stored which can be the hash value of apex, data to be stored necessary for update of the hash value of apex in the internal storage device during data writing, and updating, when matching is determined as the result of comparison by the comparison part, the hash value of apex to a hash value of the data to be stored which can be the hash value of apex. <P>COPYRIGHT: (C)2007,JPO&INPIT

Description

本発明は、ファイルシステム又はデータベースアプリケーションにて保存されるデータの不正な改竄を検出するためのデータ改竄検出装置及びデータ改竄検出方法に関する。   The present invention relates to a data falsification detection device and a data falsification detection method for detecting unauthorized falsification of data stored in a file system or a database application.

ファイルシステムは、ユーザが長期的に保存することを望むデータをファイル単位で記憶装置に保存し、後にユーザがデータ要求した際に、再びその記憶装置から読み出すことで、データの長期的な利用を可能とする。   The file system saves data that the user desires to save in the long term in a storage device in units of files, and when the user requests the data later, reads the data from the storage device again, thereby enabling long-term use of the data. Make it possible.

ファイルシステムが動作する通信端末と記憶装置はバスやネットワーク等を介して接続されており、ファイルシステムと記憶装置が個別に管理される場合もある。   The communication terminal on which the file system operates and the storage device are connected via a bus, a network, or the like, and the file system and the storage device may be managed individually.

ファイルシステムの管理者等は、この記憶装置に物理的にアクセスすることができる。   A file system administrator or the like can physically access this storage device.

しかしながら、管理者といえども、記憶装置へ不正なアクセスや改竄が可能であることは、重要性の高いファイルを保存する上で好ましくない。   However, it is not preferable that an administrator can illegally access or tamper with a storage device in order to save a highly important file.

そこで、データ改竄を阻止する観点から、ファイルシステムにおいて、一方向関数を用いてファイルの完全性を保証する手法が開示されている。この手法では、ファイルシステムのデータ構造にハッシュ値を組み込み、改竄の検出を行う(特許文献1参照)。   Therefore, from the viewpoint of preventing data tampering, a method for guaranteeing file integrity using a one-way function in a file system is disclosed. In this method, a hash value is incorporated into the data structure of the file system to detect falsification (see Patent Document 1).

又、アプリケーションの内部に、改竄検出を実現するための機能を実装する手法もある(非特許文献1参照)。
特開2004−78696号公報 アドビシステムズ社“Acrobat family Features”、[online]、[平成17年10月31日検索]、インターネット、<URL:http : //www.Adobe.co.jp/epaper/features/acrpdffaq30/page2.html#102>
There is also a technique for implementing a function for realizing falsification detection inside an application (see Non-Patent Document 1).
JP 2004-78696 A Adobe "Acrobat family Features", [online], [October 31, 2005 search], Internet, <URL: http: // www. Adobe.co.jp/epaper/features/acrpdffaq30/page2.html#102>

しかしながら、特許文献1のように、ファイルシステムのデータ構造にハッシュ値を組み込む場合、2つの問題点が発生する。1つ目は、一般に用いられている改竄検出機能を持たない通常のファイルシステムの使用を中止し、新たなファイルシステムへ切り替えなければいけない点である。2つ目は、例えばデータベースアプリケーションのような、ファイルシステムを介さずに独自のデータ構造を用いて記憶装置にデータを保存するアプリケーションには適用できない点である。   However, as in Patent Document 1, when a hash value is incorporated in the data structure of the file system, two problems occur. The first is that the use of a normal file system that does not have a falsification detection function that is generally used must be stopped and switched to a new file system. The second problem is that it cannot be applied to an application such as a database application that stores data in a storage device using a unique data structure without using a file system.

又、非特許文献1のように、アプリケーションが各自で改竄検出を備える場合にはファイルシステムへの変更は必要ないが、他のアプリケーションのファイルについては不正改竄を検出することは不可能である。つまり、使用する全てのアプリケーションが改竄検出機能を備えていなければならないという問題がある。   In addition, as in Non-Patent Document 1, when an application is provided with falsification detection on its own, it is not necessary to change the file system, but it is impossible to detect illegal falsification of files of other applications. That is, there is a problem that all applications to be used must have a falsification detection function.

本発明は、本発明は上記問題点を鑑みてなされたものであり、ファイルシステムを変更すること無く、使用する全てのアプリケーションにおけるデータの改竄を検出し、記憶装置内に保管されるデータの完全性を保証するデータ改竄検出装置及びデータ改竄検出方法を提供することを目的としたものである。   The present invention has been made in view of the above problems, and detects alteration of data in all applications used without changing the file system, and completes the data stored in the storage device. It is an object of the present invention to provide a data falsification detection device and a data falsification detection method that guarantee the performance.

上記目的を達成するために、本発明の第1の特徴は、[イ]保存するデータ及び保存するデータのハッシュ値を格納する外部記憶装置(3)に通信可能に接続され、外部記憶装置内での保存するデータの改竄を検出するデータ改竄検出装置であって、ハッシュ値を木構造に並べた際の頂点のハッシュ値、頂点のハッシュ値となる可能性のあるハッシュ値及び頂点のハッシュ値更新に必要な保存するデータを格納する内部記憶装置(17)と、[ロ]内部記憶装置内の頂点のハッシュ値と外部記憶装置内の保存するデータのハッシュ値を比較する比較部(14)と、[ハ]外部記憶装置へのデータ書込み時に、保存するデータのハッシュ値であり頂点のハッシュ値となる可能性のあるハッシュ値及び頂点のハッシュ値更新に必要な保存するデータを内部記憶装置に一時格納し、比較部による比較結果が一致した場合、頂点のハッシュ値を保存するデータのハッシュ値であり頂点のハッシュ値となる可能性のあるハッシュ値に更新する内部記憶装置管理部(16)とを備えるデータ改竄検出装置であることを要旨とする。   In order to achieve the above object, the first feature of the present invention is [i] communicably connected to an external storage device (3) for storing data to be stored and a hash value of the data to be stored. A data falsification detection device that detects falsification of data stored in the hash value of a vertex when hash values are arranged in a tree structure, a hash value that may become a hash value of a vertex, and a hash value of a vertex An internal storage device (17) for storing data to be saved necessary for updating, and [ii] a comparison unit (14) for comparing the hash value of the vertex in the internal storage device with the hash value of the data to be saved in the external storage device [C] When writing data to the external storage device, the hash value of the data to be saved and the hash value that may become the vertex hash value and the data to be saved required for updating the vertex hash value Is temporarily stored in the internal storage device, and when the comparison result by the comparison unit matches, the internal storage device updates the hash value of the vertex to the hash value of the data that stores the hash value of the vertex and may become the hash value of the vertex The gist of the present invention is a data falsification detection device including a management unit (16).

本発明の第2の特徴は、[イ]保存するデータ及び保存するデータのハッシュ値を外部記憶装置(3)に格納するステップと、[ロ]ハッシュ値を木構造に並べた際の頂点のハッシュ値、頂点のハッシュ値となる可能性のあるハッシュ値及び頂点のハッシュ値更新に必要な保存するデータを格納する内部記憶装置(17)に、頂点のハッシュ値を格納させるステップと、[ハ]内部記憶装置内の頂点のハッシュ値と外部記憶装置内の保存するデータのハッシュ値を比較部(14)が比較するステップと、[ニ]外部記憶装置へのデータ書込み時に、内部記憶装置管理部(16)が、保存するデータのハッシュ値である頂点のハッシュ値となる可能性のあるハッシュ値及び頂点のハッシュ値更新に必要な保存するデータを内部記憶装置に一時格納し、比較部による比較結果が一致した場合、格納されている頂点のハッシュ値を、保存するデータのハッシュ値である頂点のハッシュ値となる可能性のあるハッシュ値に更新するステップとを備えるデータ改竄検出方法であることを要旨とする。   The second feature of the present invention is that [a] storing the data to be stored and the hash value of the data to be stored in the external storage device (3), and [b] the vertexes when the hash values are arranged in a tree structure. Storing the hash value of the vertex in the internal storage device (17) for storing the hash value, the hash value that may be the hash value of the vertex, and the data to be stored necessary for updating the hash value of the vertex; The comparison unit (14) compares the hash value of the vertex in the internal storage device with the hash value of the data to be stored in the external storage device, and [d] management of the internal storage device when writing data to the external storage device. The unit (16) temporarily stores in the internal storage device the hash value that may be the hash value of the vertex, which is the hash value of the data to be stored, and the data to be stored necessary for updating the vertex hash value. If the comparison result by the comparison unit matches, the stored hash value of the vertex is updated to a hash value that may be a hash value of the vertex that is a hash value of the stored data. The gist is that it is a falsification detection method.

本発明によれば、ファイルシステムを変更すること無く、使用する全てのアプリケーションにおける記憶装置内でのデータの改竄を検出することができる。これにより記憶装置内に保管されるデータの完全性を保証できる。   According to the present invention, it is possible to detect falsification of data in the storage device in all applications to be used without changing the file system. This ensures the integrity of the data stored in the storage device.

以下、本発明の実施の形態に係るデータ改竄検出装置及びデータ改竄検出方法について説明する。尚、本発明の実施の形態において使用される機器、手法等は一例であり、本発明はこれらに限定されるものでないことは勿論である。   Hereinafter, a data falsification detection apparatus and a data falsification detection method according to embodiments of the present invention will be described. In addition, the apparatus, method, etc. which are used in embodiment of this invention are examples, and of course this invention is not limited to these.

(実施の形態)
(データ改竄検出装置を備える通信端末)
本発明の実施の形態に係るデータ改竄検出装置を備える通信端末100は、図1に示すように、データ改竄検出装置1、データベースアプリケーション2a、Aファイルシステム2b及びBファイルシステム2c等を備える。又、通信端末100は、外部に存在する外部記憶装置3と有線、無線のネットワークにて通信可能に接続されている。通信端末100は、パスワード等で管理されており、この通信端末100の使用を許可されたユーザのみが使用できるものとする。
(Embodiment)
(Communication terminal equipped with a data alteration detection device)
As shown in FIG. 1, a communication terminal 100 including a data falsification detection apparatus according to an embodiment of the present invention includes a data falsification detection apparatus 1, a database application 2a, an A file system 2b, a B file system 2c, and the like. The communication terminal 100 is communicably connected to an external storage device 3 existing outside via a wired or wireless network. The communication terminal 100 is managed with a password or the like, and can be used only by a user who is permitted to use the communication terminal 100.

データベースアプリケーション2a、Aファイルシステム2b及びBファイルシステム2cは、通信端末100が備える、データベース機能やファイルシステム機能を実現させる為のソフトウェアである。これらのソフトウェアは、市販のもので構わず、又、データ処理の最中に外部記憶装置3へアクセスする必要があるものとする。   The database application 2a, the A file system 2b, and the B file system 2c are software for realizing a database function and a file system function provided in the communication terminal 100. These software may be commercially available, and it is necessary to access the external storage device 3 during data processing.

外部記憶装置3は、ユーザが使用可能な記憶領域を備えている。外部記憶装置3は、複数のユーザの為に、複数の記憶領域を備えていても構わないが、各々のユーザは各々に割り当てられた記憶領域以外のアクセスは不可能なものとする。尚、外部記憶装置3は、数百ギガバイト、数テラバイト等のデータを記憶可能な大容量記憶装置である。外部記憶装置3の記憶領域は一定の大きさに分割され、記憶領域の先頭から番号をつけて管理される。この管理単位をブロックと呼ぶ。本発明の実施の形態において、外部記憶装置3は、データベースアプリケーション2a、Aファイルシステム2b及びBファイルシステム2cで使用するデータを格納するデータブロックと、各々のデータのハッシュ値を格納するハッシュブロックを備える。データブロック及びハッシュブロックの内部構成については後述する。尚、外部記憶装置3を利用するデータベースアプリケーション2a、Aファイルシステム2b及びBファイルシステム2cは、外部記憶装置3に対してセクタ(512バイト)単位でアクセスする。ブロックのサイズはセクタサイズと一致する必要はないが、効率のためにブロックサイズがセクタサイズの倍数であることが望ましい。   The external storage device 3 includes a storage area that can be used by the user. The external storage device 3 may include a plurality of storage areas for a plurality of users, but each user cannot access any area other than the storage area assigned to each user. The external storage device 3 is a large-capacity storage device capable of storing data such as several hundred gigabytes and several terabytes. The storage area of the external storage device 3 is divided into a certain size and managed by assigning a number from the beginning of the storage area. This management unit is called a block. In the embodiment of the present invention, the external storage device 3 includes a data block that stores data used in the database application 2a, the A file system 2b, and the B file system 2c, and a hash block that stores a hash value of each data. Prepare. The internal configuration of the data block and hash block will be described later. The database application 2a, the A file system 2b, and the B file system 2c that use the external storage device 3 access the external storage device 3 in units of sectors (512 bytes). The block size need not match the sector size, but it is desirable for the block size to be a multiple of the sector size for efficiency.

データ改竄検出装置1は、通信端末100で動作するオペレーティングシステムの記憶装置管理機能として実装される。データ改竄検出装置1は、データベースアプリケーション2a、Aファイルシステム2b及びBファイルシステム2c等のソフトウェアと、外部記憶装置3の間に配置され、各ソフトウェアが外部記憶装置3内のデータを使用する際に、外部記憶装置3内で不正なデータ改竄が行われていないかを検出する。データ改竄検出装置1は、外部記憶装置3と同じインターフェイスを提供するので、各ソフトウェアへの変更は必要ない。各ソフトウェアは、従来どおり外部記憶装置3にアクセスするだけで、中間に配置されている改竄検出装置1を利用することができる。以下、データ改竄検出装置1について詳細に説明する。   The data alteration detection device 1 is implemented as a storage device management function of an operating system that operates on the communication terminal 100. The data alteration detection device 1 is arranged between software such as the database application 2a, the A file system 2b, and the B file system 2c and the external storage device 3, and each software uses data in the external storage device 3. Then, it is detected whether or not unauthorized data alteration has been performed in the external storage device 3. Since the data alteration detection device 1 provides the same interface as that of the external storage device 3, no change to each software is necessary. Each software can use the falsification detection device 1 arranged in the middle by simply accessing the external storage device 3 as usual. Hereinafter, the data alteration detection device 1 will be described in detail.

(データ改竄検出装置)
データ改竄検出装置1は、図1に示すように、記憶装置管理部11、ハッシュ値計算部12、ハッシュ値保存位置管理部13、比較部14、記憶装置アクセス部15、内部記憶装置管理部16及び内部記憶装置17等を備える。
(Data falsification detection device)
As shown in FIG. 1, the data alteration detection device 1 includes a storage device management unit 11, a hash value calculation unit 12, a hash value storage location management unit 13, a comparison unit 14, a storage device access unit 15, and an internal storage device management unit 16. And an internal storage device 17 and the like.

記憶装置管理部11は、データベースアプリケーション2a、Aファイルシステム2b及びBファイルシステム2c等より外部記憶装置3への所定データの読込み・書込み命令を受け、この読込み・書込み命令に関する処理を統括して実行し、又管理を行う。   The storage device management unit 11 receives commands for reading / writing predetermined data to the external storage device 3 from the database application 2a, the A file system 2b, the B file system 2c, and the like, and performs overall processing related to the read / write commands. And manage.

ハッシュ値計算部12は、データのハッシュ値を算出する。ハッシュ値保存位置管理部13は、ハッシュブロック内のハッシュ値が保存されている位置を管理する。比較部14は、2つ以上のハッシュ値を比較することにより、データの改竄の有無を検出する。例えば、内部記憶装置17に格納されるハッシュ値と外部記憶装置3に格納されるハッシュ値を比較する。記憶装置アクセス部15は、読込み・書込み命令に従い、外部記憶装置3へのアクセスを行う。   The hash value calculation unit 12 calculates a hash value of data. The hash value storage location management unit 13 manages the location where the hash value in the hash block is stored. The comparison unit 14 detects the presence or absence of data falsification by comparing two or more hash values. For example, the hash value stored in the internal storage device 17 is compared with the hash value stored in the external storage device 3. The storage device access unit 15 accesses the external storage device 3 in accordance with a read / write command.

内部記憶装置17は、数キロバイト等の容量の小容量記憶メモリである。内部記憶装置17は、頂点のハッシュ値を格納する領域、頂点のハッシュ値となる可能性のあるハッシュ値を格納する領域及び頂点のハッシュ値を更新する際に必要なデータを格納する領域等を備える。内部記憶装置管理部16は、外部記憶装置3へのデータ書込み時に、頂点のハッシュ値となる可能性のあるハッシュ値及び頂点のハッシュ値更新に必要なデータを内部記憶装置17に一時格納し、比較部の比較結果に従い、頂点のハッシュ値を頂点のハッシュ値となる可能性のあるハッシュ値に書き換える。   The internal storage device 17 is a small-capacity storage memory having a capacity of several kilobytes. The internal storage device 17 includes an area for storing the hash value of the vertex, an area for storing the hash value that may be the vertex hash value, an area for storing data necessary for updating the hash value of the vertex, and the like. Prepare. The internal storage device management unit 16 temporarily stores in the internal storage device 17 a hash value that may become a hash value of a vertex and data necessary for updating the hash value of the vertex when data is written to the external storage device 3, According to the comparison result of the comparison unit, the hash value of the vertex is rewritten with a hash value that may become the hash value of the vertex.

(データブロック及びハッシュブロックの構成)
データブロック及びデータブロックのハッシュ値を複数格納するハッシュブロックは木構造に構成され、データブロックのハッシュ値は、ブロック番号順に並べられてハッシュブロックに保存される。例えば、データブロックが6個で、各ブロックに3つのハッシュ値を保存できる場合について図2に示す。ブロック番号0〜2を第1データブロック群、ブロック番号3〜5を第2データブロック群とすると、第1データブロック群の各ハッシュ値はブロック番号6、第2データブロック群の各ハッシュ値はブロック番号7に格納される。更に、ブロック番号6のハッシュ値とブロック番号7のハッシュ値がブロック番号8に格納される。このブロック番号8のハッシュ値は木構造の頂点であり、「頂点のハッシュ値」となる。この例では、ブロック番号6〜8がハッシュブロックとなり、外部記憶装置3の全体のブロック数は9個となる。
(Configuration of data block and hash block)
A data block and a hash block that stores a plurality of hash values of the data block are configured in a tree structure, and the hash values of the data block are arranged in the order of block numbers and stored in the hash block. For example, FIG. 2 shows a case where there are six data blocks and three hash values can be stored in each block. If the block numbers 0 to 2 are the first data block group and the block numbers 3 to 5 are the second data block group, each hash value of the first data block group is block number 6, and each hash value of the second data block group is Stored in block number 7. Further, the hash value of block number 6 and the hash value of block number 7 are stored in block number 8. The hash value of the block number 8 is the vertex of the tree structure, and becomes the “vertex hash value”. In this example, block numbers 6 to 8 are hash blocks, and the total number of blocks in the external storage device 3 is nine.

データブロックの数、ブロックサイズ、ハッシュ値のサイズによって、必要なハッシュブロックの段数は変化する。例えば、一方向関数としてSHA1アルゴリズムを用いた場合は、ハッシュ値のサイズが20バイトになり、ブロックサイズを4キロバイトにすると、1つのハッシュブロックに204個分のデータブロックのハッシュ値を保存することができる。従って、例えばデータブロックが10、000個であれば、1段目のハッシュブロックが50個必要となる。1段目のハッシュブロックが50個なので、1つの2段目のハッシュブロックに全てのハッシュ値を保存することができることになる。又、この二段目のハッシュブロックが頂点のハッシュ値となる。   Depending on the number of data blocks, the block size, and the size of the hash value, the required number of stages of hash blocks changes. For example, when the SHA1 algorithm is used as a one-way function, if the hash value size is 20 bytes and the block size is 4 kilobytes, the hash values of 204 data blocks are stored in one hash block. Can do. Therefore, for example, if there are 10,000 data blocks, 50 first-stage hash blocks are required. Since there are 50 first-stage hash blocks, all hash values can be stored in one second-stage hash block. The second-stage hash block is the vertex hash value.

(データ改竄検出方法)
次に、データ改竄検出装置1を備えた通信端末100における初期化動作、データ読込み動作、データ書込み動作について説明する。
(Data falsification detection method)
Next, an initialization operation, a data reading operation, and a data writing operation in the communication terminal 100 provided with the data alteration detection device 1 will be described.

(初期化動作)
次に初期化処理について説明する。
(Initialization operation)
Next, the initialization process will be described.

(a)先ず、外部記憶装置3の記憶領域の一部をハッシュブロックとして利用する為に、図1の記憶装置管理部11がデータブロックとハッシュブロックの配分の決定を行う。配分比率については、一方向関数の種類や外部記憶装置3のデータ容量等に基づいて決定される。 (A) First, in order to use a part of the storage area of the external storage device 3 as a hash block, the storage device management unit 11 in FIG. 1 determines the allocation of the data block and the hash block. The distribution ratio is determined based on the type of one-way function, the data capacity of the external storage device 3, and the like.

(b)又、記憶装置管理部11は、外部記憶装置3の本来の大きさから、ハッシュブロックの領域を除いた記憶領域の大きさ、すなわちデータブロック記憶領域を、格納可能な領域として図1のデータベースアプリケーション2a、Aファイルシステム2b及びBファイルシステム2cに通知する。 (B) In addition, the storage device management unit 11 sets the size of the storage area excluding the hash block area from the original size of the external storage apparatus 3, that is, the data block storage area as a storable area. To the database application 2a, the A file system 2b, and the B file system 2c.

(c)次に、データベースアプリケーション2a、Aファイルシステム2b及びBファイルシステム2cより外部記憶装置3のデータブロックに記憶すべきデータを受信すると、記憶装置管理部11は、ハッシュブロックの書込み処理を行う。ハッシュブロックの書込みでは、図2にて説明したように、第1データブロック群及び第2データブロック群を読み、ハッシュ値計算部12にて各々のハッシュ値を算出させ、第1データブロック群のハッシュ値をブロック番号6、第2データブロック群のハッシュ値をブロック番号7に格納する。更に、ブロック番号6及びブロック番号7のハッシュ値をブロック番号8に格納する。これらの格納位置はハッシュ値保存位置管理部13が管理する。 (C) Next, when data to be stored in the data block of the external storage device 3 is received from the database application 2a, the A file system 2b, and the B file system 2c, the storage device management unit 11 performs a hash block write process. . In writing the hash block, as described with reference to FIG. 2, the first data block group and the second data block group are read, and each hash value is calculated by the hash value calculation unit 12, and the first data block group The hash value is stored in block number 6, and the hash value of the second data block group is stored in block number 7. Further, the hash values of block number 6 and block number 7 are stored in block number 8. These storage positions are managed by the hash value storage position management unit 13.

(d)最後に、図1の内部記憶装置管理部16はブロック番号8を「頂点のハッシュ値」として、内部記憶装置17に格納する。 (D) Finally, the internal storage device management unit 16 in FIG. 1 stores the block number 8 as the “vertex hash value” in the internal storage device 17.

(データ読込み動作)
次に、データブロックの読込み時にデータ改竄の有無を検査する処理について図3のフローチャートを参照して説明する。尚、初期化処理により全ブロックは、図2にて説明したように、データブロック6つ、ハッシュブロック3つの状態であるものとする。
(Data reading operation)
Next, a process for inspecting whether data has been tampered with when reading a data block will be described with reference to the flowchart of FIG. It is assumed that all blocks in the initialization process are in the state of six data blocks and three hash blocks as described with reference to FIG.

(a)先ずステップS101において、図1のデータ改竄検出装置1の記憶装置管理部11が、データベースアプリケーション2a、Aファイルシステム2b及びBファイルシステム2cのいずれかより、ブロック番号0のデータの読み出し命令を受け取ったとする。するとステップS102にて、記憶装置管理部11が、記憶装置アクセス部15に、外部記憶装置3のブロック番号0のデータ読み出しを命令する。記憶装置アクセス部15は、ブロック番号0のデータを読み出す。ステップS103において、ハッシュ値計算部12は、読み出されたブロック番号0のデータのハッシュ値を算出する。 (A) First, in step S101, the storage device management unit 11 of the data falsification detection device 1 shown in FIG. 1 reads out data of block number 0 from any of the database application 2a, the A file system 2b, and the B file system 2c. Is received. Then, in step S102, the storage device management unit 11 instructs the storage device access unit 15 to read data of block number 0 of the external storage device 3. The storage device access unit 15 reads the data of block number 0. In step S103, the hash value calculation unit 12 calculates the hash value of the read data of block number 0.

(b)ステップS104において、記憶装置管理部11が、ブロック番号0のハッシュ値が保存されているブロック番号6の読み出しを、記憶装置アクセス部15に命令する。記憶装置アクセス部15は、ブロック番号6を読み出し、ブロック番号0のハッシュ値を取得する。 (B) In step S104, the storage device management unit 11 instructs the storage device access unit 15 to read the block number 6 in which the hash value of the block number 0 is stored. The storage device access unit 15 reads block number 6 and obtains a hash value of block number 0.

(c)ステップS105において、比較部14が、ステップS103で算出されたブロック番号0のハッシュ値と、ステップS104で取得されたブロック番号0のハッシュ値を比較する。ここでハッシュ値が一致しなければ、ブロック番号0又はブロック番号6のどちらかのデータが改竄されていることを意味する。ハッシュ値が一致するとステップS106へ進み、ハッシュ値が異なる場合ステップS113へ進む。 (C) In step S105, the comparison unit 14 compares the hash value of block number 0 calculated in step S103 with the hash value of block number 0 acquired in step S104. Here, if the hash values do not match, it means that the data of either block number 0 or block number 6 has been falsified. If the hash values match, the process proceeds to step S106, and if the hash values are different, the process proceeds to step S113.

(d)ステップS106においては、記憶装置アクセス部15がブロック番号6のデータを読み出し、ハッシュ値計算部12が、読み出されたブロック番号6のデータのハッシュ値を算出する。 (D) In step S106, the storage device access unit 15 reads the data of block number 6, and the hash value calculation unit 12 calculates the hash value of the read data of block number 6.

(e)ステップS107においては、記憶装置アクセス部15が、外部記憶装置3からブロック番号8に保存されているブロック番号6のハッシュ値を取得する。 (E) In step S <b> 107, the storage device access unit 15 acquires the hash value of the block number 6 stored in the block number 8 from the external storage device 3.

(f)ステップS108において、比較部14が、ステップS106で算出されたブロック番号6のハッシュ値と、ステップS107で取得されたブロック番号6のハッシュ値を比較する。ここでハッシュ値が一致しなければ、ブロック番号6又はブロック番号8のどちらかのデータが改竄されていることを意味する。ハッシュ値が一致するとステップS109へ進み、ハッシュ値が異なる場合ステップS113へ進む。 (F) In step S108, the comparison unit 14 compares the hash value of block number 6 calculated in step S106 with the hash value of block number 6 acquired in step S107. Here, if the hash values do not match, it means that the data of either block number 6 or block number 8 has been falsified. If the hash values match, the process proceeds to step S109, and if the hash values are different, the process proceeds to step S113.

(g)ステップS109においては、記憶装置アクセス部15がブロック番号8のデータを読み出し、ハッシュ値計算部12が、読み出されたブロック番号8のデータのハッシュ値を算出する。ステップS110においては、内部記憶装置管理部16が、図1の内部記憶装置17から頂点のハッシュ値を読み出す。 (G) In step S109, the storage device access unit 15 reads the data of block number 8, and the hash value calculation unit 12 calculates the hash value of the read data of block number 8. In step S110, the internal storage device management unit 16 reads the hash value of the vertex from the internal storage device 17 of FIG.

(h)ステップS111において、比較部14が、ステップS109で算出されたブロック番号8のハッシュ値と、ステップS110で読み出された頂点のハッシュ値を比較する。ここでハッシュ値が一致しなければ、ブロック番号8のデータが改竄されていることを意味する。ハッシュ値が一致するとステップS112へ進み、ハッシュ値が異なる場合ステップS113へ進む。 (H) In step S111, the comparison unit 14 compares the hash value of block number 8 calculated in step S109 with the hash value of the vertex read in step S110. Here, if the hash values do not match, it means that the data of block number 8 has been falsified. If the hash values match, the process proceeds to step S112, and if the hash values are different, the process proceeds to step S113.

(i)ステップS112では、全てのハッシュ値の比較が成功した為、ブロック0は改竄されていないことが保証される。この場合、記憶装置管理部11は、ブロック0の読み込みが成功したことを読み込み命令を出したデータベースアプリケーション2a、Aファイルシステム2b又はBファイルシステム2cに通知し、更に、ブロック番号0に保存されているデータを引き渡す。 (I) In step S112, since all hash values have been successfully compared, it is guaranteed that block 0 has not been tampered with. In this case, the storage device management unit 11 notifies the database application 2a, the A file system 2b, or the B file system 2c that issued the read command that the reading of the block 0 was successful, and is further stored in the block number 0. Hand over the data.

(j)ステップS113においては、記憶装置管理部11は、データが改竄されていると判断し、読み込み命令を出したデータベースアプリケーション2a、Aファイルシステム2b又はBファイルシステム2cに読み込みが失敗したことを通知する。 (J) In step S113, the storage device management unit 11 determines that the data has been tampered with and that the database application 2a, A file system 2b, or B file system 2c that issued the read command has failed to read. Notice.

(データ書込み動作)
次に、データブロックの書込み時にデータ改竄の有無を検査する処理について図4のフローチャートを参照して説明する。尚、書込み実行中に通信端末100内で予期せぬイベントが発生して電源が落ちた場合などは、全てのブロックへの書込みが終わっていない状態となる。この時、通信端末100は書込み途中の状態を把握することが出来ない。このため、通信端末100は起動後に内部記憶装置17の状態を調べ、一時的に書込んだデータが残っていた場合、これらを外部記憶装置3に書込むことで、直前に実行していた書込み命令を完了させることができるようにする。尚、初期化処理により全ブロックは、図2にて説明したように、データブロック6つ、ハッシュブロック3つの状態であるものとする。
(Data write operation)
Next, a process for checking the presence / absence of data tampering at the time of data block writing will be described with reference to the flowchart of FIG. Note that when an unexpected event occurs in the communication terminal 100 during the execution of writing and the power is turned off, writing to all blocks is not completed. At this time, the communication terminal 100 cannot grasp the state during writing. For this reason, the communication terminal 100 checks the state of the internal storage device 17 after activation, and if temporarily written data remains, it writes these to the external storage device 3 to perform the write executed immediately before Allow the instruction to complete. It is assumed that all blocks in the initialization process are in the state of six data blocks and three hash blocks as described with reference to FIG.

(a)先ずステップS201において、図1のデータ改竄検出装置1の記憶装置管理部11が、データベースアプリケーション2a、Aファイルシステム2b及びBファイルシステム2cのいずれかより、ブロック番号0のデータの書込み命令及びブロック0の更新するデータを受け取ったとする。するとステップS202にて、ハッシュ値計算部12は、ブロック番号0の更新するデータのハッシュ値を算出する。 (A) First, in step S201, the storage device management unit 11 of the data falsification detection device 1 in FIG. 1 issues a data write command for block number 0 from any of the database application 2a, the A file system 2b, and the B file system 2c. And the data to be updated in block 0 is received. Then, in step S202, the hash value calculation unit 12 calculates the hash value of the data to be updated with the block number 0.

(b)ステップS203においては、ブロック番号0のハッシュブロックであるブロック番号6のデータを読み出す。ステップS204では、ブロック番号6内のブロック番号0のハッシュ値をステップS202にて算出したブロック番号0の更新するデータのハッシュ値に更新する。この更新後のデータ内容を「ブロック番号6の更新するデータ」とする。又、ハッシュ値計算部12は、ブロック番号6の更新するデータのハッシュ値を算出する。 (B) In step S203, data of block number 6 which is a hash block of block number 0 is read. In step S204, the hash value of block number 0 in block number 6 is updated to the hash value of the data to be updated of block number 0 calculated in step S202. The updated data content is “data to be updated with block number 6”. The hash value calculation unit 12 calculates a hash value of data to be updated with the block number 6.

(c)ステップS205においては、ブロック番号6のハッシュブロックであるブロック番号8のデータを読み出す。ステップS206では、ブロック番号8内のブロック番号6のハッシュ値をステップS204にて算出したブロック番号6の更新データのハッシュ値に更新する。この更新後のデータ内容を「ブロック番号8の更新するデータ」とする。又、ハッシュ値計算部12は、ブロック番号8の更新するデータのハッシュ値を算出する。 (C) In step S205, data of block number 8 which is a hash block of block number 6 is read. In step S206, the hash value of block number 6 in block number 8 is updated to the hash value of the update data of block number 6 calculated in step S204. The updated data content is “data to be updated with block number 8”. The hash value calculation unit 12 calculates a hash value of data to be updated with the block number 8.

(d)ステップS207においては、内部記憶装置管理部16は、ブロック番号0,6,8の更新するデータを内部記憶装置17の頂点のハッシュ値を更新する際に必要なデータを格納する領域に、ブロック番号8の更新するデータのハッシュ値を内部記憶装置17の頂点のハッシュ値となる可能性のあるハッシュ値を格納する領域に、一時的に書込む。それらの書込み終了後にステップS208において、記憶装置アクセス部15は、外部記憶装置3のブロック番号0,6,8に更新するデータを書込む。又、内部記憶装置管理部16は内部記憶装置17の頂点のハッシュ値領域に、ブロック番号8の更新するデータのハッシュ値を書込む。これらの書込みが終わるとステップS209において、内部記憶装置17に一時的に書込んだ、ブロック番号0,6,8の更新するデータとブロック番号8の更新するデータのハッシュ値を削除する。 (D) In step S207, the internal storage device management unit 16 stores the data to be updated in the block numbers 0, 6, and 8 in an area for storing data necessary for updating the hash value of the vertex of the internal storage device 17. Then, the hash value of the data to be updated with the block number 8 is temporarily written in an area for storing the hash value that may be the hash value of the vertex of the internal storage device 17. After completion of the writing, in step S208, the storage device access unit 15 writes the data to be updated to the block numbers 0, 6, and 8 of the external storage device 3. Further, the internal storage device management unit 16 writes the hash value of the data to be updated with the block number 8 in the hash value area at the vertex of the internal storage device 17. When these writings are completed, in step S209, the updated data of block numbers 0, 6, and 8 and the hash value of the updated data of block number 8 temporarily written in the internal storage device 17 are deleted.

このように、頂点のハッシュ値を更新する際に必要なデータを格納する領域及び頂点のハッシュ値となる可能性のあるハッシュ値を格納する領域への一時書込みを行い、この一時書込みを参照して、各更新するデータを外部記憶装置3へ、頂点のハッシュ値を内部記憶装置17へ書込むことにより、書込み実行中に通信端末100内で予期せぬイベントが発生して電源が落ちた等の理由により、全てのブロックへの書込みが終わっていない場合であっても、正確に書込み処理を完了することが可能となる。   In this way, temporary writing is performed to the area that stores the data necessary for updating the hash value of the vertex and the area that stores the hash value that may become the hash value of the vertex, and this temporary writing is referred to. Thus, by writing the data to be updated to the external storage device 3 and the hash value of the vertex to the internal storage device 17, an unexpected event occurs in the communication terminal 100 during the execution of writing, and the power is turned off. For this reason, even if writing to all the blocks is not completed, the writing process can be completed accurately.

本発明の実施の形態に係るデータ改竄検出装置を備える通信端末の構造を示した図である。It is the figure which showed the structure of the communication terminal provided with the data alteration detection apparatus which concerns on embodiment of this invention. データブロック及びハッシュブロックのデータ構造を示した図である。It is the figure which showed the data structure of the data block and the hash block. 本発明の実施の形態に係るデータ改竄検出装置の読込み動作を示すフロー図である。It is a flowchart which shows the reading operation | movement of the data alteration detection apparatus which concerns on embodiment of this invention. 本発明の実施の形態に係るデータ改竄検出装置の書込み動作を示すフロー図である。It is a flowchart which shows the write-in operation | movement of the data alteration detection apparatus which concerns on embodiment of this invention.

符号の説明Explanation of symbols

1…データ改竄検出装置
2a…データベースアプリケーション
2b…Aファイルシステム
2c…Bファイルシステム
3…外部記憶装置
11…記憶装置管理部
12…ハッシュ値計算部
13…ハッシュ値保存位置管理部
14…比較部
15…記憶装置アクセス部
16…内部記憶装置管理部
17…内部記憶装置
100…通信端末
DESCRIPTION OF SYMBOLS 1 ... Data tampering detection apparatus 2a ... Database application 2b ... A file system 2c ... B file system 3 ... External storage device 11 ... Storage device management part 12 ... Hash value calculation part 13 ... Hash value storage position management part 14 ... Comparison part 15 ... Storage device access unit 16 ... Internal storage device management unit 17 ... Internal storage device 100 ... Communication terminal

Claims (2)

保存するデータ及び前記保存するデータのハッシュ値を格納する外部記憶装置に通信可能に接続され、前記外部記憶装置内での前記保存するデータの改竄を検出するデータ改竄検出装置であって、
前記ハッシュ値を木構造に並べた際の頂点のハッシュ値、前記頂点のハッシュ値となる可能性のあるハッシュ値及び前記頂点のハッシュ値更新に必要な前記保存するデータを格納する内部記憶装置と、
前記内部記憶装置内の前記頂点のハッシュ値と前記外部記憶装置内の前記保存するデータのハッシュ値を比較する比較部と、
前記外部記憶装置へのデータ書込み時に、前記保存するデータのハッシュ値であり前記頂点のハッシュ値となる可能性のあるハッシュ値及び前記頂点のハッシュ値更新に必要な前記保存するデータを前記内部記憶装置に一時格納し、前記比較部による比較結果が一致した場合、前記頂点のハッシュ値を前記保存するデータのハッシュ値であり前記頂点のハッシュ値となる可能性のあるハッシュ値に更新する内部記憶装置管理部
とを備えることを特徴とするデータ改竄検出装置。
A data falsification detection device that is communicably connected to an external storage device that stores data to be stored and a hash value of the data to be stored, and detects falsification of the data to be stored in the external storage device,
An internal storage device for storing a hash value of a vertex when the hash values are arranged in a tree structure, a hash value that may be a hash value of the vertex, and the data to be stored necessary for updating the hash value of the vertex; ,
A comparison unit that compares the hash value of the vertex in the internal storage device with the hash value of the data to be stored in the external storage device;
When writing data to the external storage device, the hash value of the data to be stored and the hash value that may be the hash value of the vertex and the data to be stored necessary for updating the hash value of the vertex are stored in the internal storage Internal storage that temporarily stores in the device and updates the hash value of the vertex to the hash value of the stored data and the hash value of the vertex when the comparison result by the comparison unit matches A data falsification detection device comprising: a device management unit.
保存するデータ及び前記保存するデータのハッシュ値を外部記憶装置に格納するステップと、
前記ハッシュ値を木構造に並べた際の頂点のハッシュ値、前記頂点のハッシュ値となる可能性のあるハッシュ値及び前記頂点のハッシュ値更新に必要な前記保存するデータを格納する内部記憶装置に、前記頂点のハッシュ値を格納させるステップと、
前記内部記憶装置内の前記頂点のハッシュ値と前記外部記憶装置内の前記保存するデータのハッシュ値を比較部が比較するステップと、
前記外部記憶装置へのデータ書込み時に、内部記憶装置管理部が、前記保存するデータのハッシュ値である前記頂点のハッシュ値となる可能性のあるハッシュ値及び前記頂点のハッシュ値更新に必要な前記保存するデータを前記内部記憶装置に一時格納し、前記比較部による比較結果が一致した場合、格納されている前記頂点のハッシュ値を、前記保存するデータのハッシュ値である前記頂点のハッシュ値となる可能性のあるハッシュ値に更新するステップ
とを備えることを特徴とするデータ改竄検出方法。

Storing data to be stored and a hash value of the data to be stored in an external storage device;
A hash value of a vertex when the hash values are arranged in a tree structure, a hash value that may be a hash value of the vertex, and an internal storage device that stores the data to be stored necessary for updating the hash value of the vertex Storing a hash value of the vertex;
A step of comparing a hash value of the vertex in the internal storage device with a hash value of the data to be stored in the external storage device;
When writing data to the external storage device, the internal storage device management unit needs to update the hash value of the vertex that is the hash value of the vertex that is the hash value of the stored data and the hash value of the vertex. Data to be stored is temporarily stored in the internal storage device, and when the comparison result by the comparison unit matches, the stored hash value of the vertex is the hash value of the vertex that is the hash value of the data to be stored A data falsification detection method comprising: a step of updating to a hash value that is likely to become.

JP2005328646A 2005-11-14 2005-11-14 Apparatus and method for detecting data alteration Pending JP2007133818A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2005328646A JP2007133818A (en) 2005-11-14 2005-11-14 Apparatus and method for detecting data alteration

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2005328646A JP2007133818A (en) 2005-11-14 2005-11-14 Apparatus and method for detecting data alteration

Publications (1)

Publication Number Publication Date
JP2007133818A true JP2007133818A (en) 2007-05-31

Family

ID=38155399

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2005328646A Pending JP2007133818A (en) 2005-11-14 2005-11-14 Apparatus and method for detecting data alteration

Country Status (1)

Country Link
JP (1) JP2007133818A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB2528780A (en) * 2014-07-24 2016-02-03 Boeing Co Security against memory replay attacks in computing systems

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB2528780A (en) * 2014-07-24 2016-02-03 Boeing Co Security against memory replay attacks in computing systems
GB2528780B (en) * 2014-07-24 2021-06-09 Boeing Co Security against memory replay attacks in computing systems

Similar Documents

Publication Publication Date Title
US10296239B1 (en) Object-based commands with quality of service identifiers
US8838875B2 (en) Systems, methods and computer program products for operating a data processing system in which a file delete command is sent to an external storage device for invalidating data thereon
US9898404B2 (en) Method and apparatus for providing improved garbage collection process in solid state drive
CN101809566B (en) Efficient file hash identifier computation
KR101780891B1 (en) System and method of blocking ransomware based on white list and black list
US7533291B2 (en) System and method for storing a data file backup
JP2008217209A (en) Difference snapshot management method, computer system and nas computer
US7970804B2 (en) Journaling FAT file system and accessing method thereof
JP2007012058A (en) File system for storing transaction records in flash-like media
JP2001297038A (en) Data storage device, recording medium, and recording medium control method
JP2007012060A (en) File system having inverted hierarchical structure
JP2007012054A (en) Startup authentication of optimized file system integrity
US20130269039A1 (en) Data access control
US10649682B1 (en) Focused sanitization process for deduplicated storage systems
US11249677B2 (en) Method and apparatus for erasing or writing flash data
TW201337589A (en) Systems and methods for providing dynamic file system awareness on storage devices
US7523319B2 (en) System and method for tracking changed LBAs on disk drive
US8990589B1 (en) System and method for robust full-drive encryption
US20100115004A1 (en) Backup system that stores boot data file of embedded system in different strorage sections and method thereof
US9245152B2 (en) Method for authenticating a storage device, machine-readable storage medium, and host device
CN109558752B (en) Method for quickly realizing file identification under host white list mechanism
JP6201385B2 (en) Storage apparatus and storage control method
JP2007133818A (en) Apparatus and method for detecting data alteration
CN107257281B (en) Method, apparatus and computer readable storage medium for NOR F L ASH storage key record
KR101618999B1 (en) Network boot system

Legal Events

Date Code Title Description
A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20090317

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20090513

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20090929

A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20100209