JP2009258772A - Application execution device - Google Patents

Application execution device Download PDF

Info

Publication number
JP2009258772A
JP2009258772A JP2006216861A JP2006216861A JP2009258772A JP 2009258772 A JP2009258772 A JP 2009258772A JP 2006216861 A JP2006216861 A JP 2006216861A JP 2006216861 A JP2006216861 A JP 2006216861A JP 2009258772 A JP2009258772 A JP 2009258772A
Authority
JP
Japan
Prior art keywords
class file
encrypted
decryption key
class
application
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
JP2006216861A
Other languages
Japanese (ja)
Inventor
Germano Leichsenring
ジェルマーノ ライクセンリング
Hidetaka Oto
英隆 大戸
Tomonori Nakamura
智典 中村
Kazufumi Miyatake
和史 宮武
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.)
Panasonic Corp
Original Assignee
Panasonic 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 Panasonic Corp filed Critical Panasonic Corp
Priority to JP2006216861A priority Critical patent/JP2009258772A/en
Priority to PCT/JP2007/064851 priority patent/WO2008018310A1/en
Publication of JP2009258772A publication Critical patent/JP2009258772A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/10Protecting distributed programs or content, e.g. vending or licensing of copyrighted material ; Digital rights management [DRM]
    • G06F21/12Protecting executable software
    • G06F21/121Restricting unauthorised execution of programs
    • G06F21/125Restricting unauthorised execution of programs by manipulating the program code, e.g. source code, compiled code, interpreted code, machine code

Abstract

<P>PROBLEM TO BE SOLVED: To facilitate interception between interfaces for delivering a plain text class file between decryption and a load. <P>SOLUTION: In this application execution device, when it is determined in a loading determination part that a class file to be executed in an interpreter is an encrypted class file, the class file is sent to a decryptor loader. When it is determined in the loading determination part that a class file to be sent to a virtual machine is the plain text class file, the class file is sent to a loader. <P>COPYRIGHT: (C)2010,JPO&INPIT

Description

本発明はアプリケーションの著作権保護に関するものである。   The present invention relates to application copyright protection.

従来のアプリケーションの著作権保護としては、クラスファイルを暗号化するものがあった。たとえば非特許文献1にはクラスファイルを暗号化する方法および暗号化されたクラスファイルを実行時に復号化するための方法が開示されている。図12は、従来のアプリケーションの著作権保護を行う一般的な再生装置の構成図であり、仮想マシーン101とJava(登録商標)アプリケーション102で構成されている。仮想マシーン(Java(登録商標)バーチャルマシーンとも言う)101はインタプリタ103、ヒープメモリ104、ローダ105で構成されている。アプリケーションは復号クラスローダ107、保護対象クラスファイル108、復号鍵109で構成されている。アプリケーションの著作権保護を行うために保護対象クラスファイル108は暗号化形式で配布されていて解釈実行される前に復号化し解釈可能な形式に変換される。保護対象クラスが暗号化されたクラスファイルからクラスオブジェクトに変更される制御フローを図13で示す。まず復号クラスローダ107が復号鍵109を利用し、保護対象クラスファイル108を復号化する(S201)。復号化することによりクラスファイルを得る。その後、復号化クラスローダ107がローダ105にクラスファイルを渡しクラスオブジェクトを得る(S202)。保護対象クラスファイル108は暗号化形式で配布されることでアプリケーションの著作権保護が行われる。   Conventional copyright protection for applications includes encryption of class files. For example, Non-Patent Document 1 discloses a method for encrypting a class file and a method for decrypting an encrypted class file at the time of execution. FIG. 12 is a configuration diagram of a general playback device that protects the copyright of a conventional application, and includes a virtual machine 101 and a Java (registered trademark) application 102. A virtual machine (also referred to as a Java (registered trademark) virtual machine) 101 includes an interpreter 103, a heap memory 104, and a loader 105. The application includes a decryption class loader 107, a protection target class file 108, and a decryption key 109. In order to protect the copyright of the application, the protected class file 108 is distributed in an encrypted format, and is decrypted and converted into an interpretable format before being interpreted and executed. FIG. 13 shows a control flow in which the protected class is changed from the encrypted class file to the class object. First, the decryption class loader 107 decrypts the protection target class file 108 using the decryption key 109 (S201). A class file is obtained by decoding. Thereafter, the decryption class loader 107 passes the class file to the loader 105 to obtain a class object (S202). The protected class file 108 is distributed in an encrypted format, thereby protecting the copyright of the application.

上述の方式以外に、従来のコンテンツのコピープロテクションを適応し配布ファイル全体を暗号化するやり方も考えられる。
“Java(登録商標) World”、オンライン、インターネット<URL:http://www.javaworld.com/javaworld/javaqa/2003-05/01-qa-0509-jcrypt.html>
In addition to the above-described method, a method of encrypting the entire distribution file by applying conventional copy protection of the content can be considered.
“Java (registered trademark) World”, online, Internet <URL: http://www.javaworld.com/javaworld/javaqa/2003-05/01-qa-0509-jcrypt.html>

しかしながら、従来の技術ではJava(登録商標)アプリケーションの著作権を十分に保護することができない。復号化とロードの間で平文クラスファイルを受け渡しするためのインターフェースは明確であり、復号化とロード処理の間に平文クラスファイルの傍受が容易であるという貧弱性がある。また、復号化された後の平文クラスファイルはヒープメモリ104上に配置されるため、解析が容易である。また、攻撃者が配信メディアを通常のリバースエンジニアリング技術で解析し著作権保護を無効化することが可能だという欠点もある。リバースエンジニアリングとは逆アセンブラなどのツールを利用しアプリケーションを解析する技術である。   However, the conventional technology cannot sufficiently protect the copyright of the Java (registered trademark) application. The interface for passing the plaintext class file between decryption and loading is clear, and there is a weakness that it is easy to intercept the plaintext class file between decryption and loading processing. Further, since the decrypted plaintext class file is arranged on the heap memory 104, the analysis is easy. Another disadvantage is that attackers can disable the copyright protection by analyzing the distribution media using normal reverse engineering techniques. Reverse engineering is a technology that analyzes applications using tools such as disassembler.

また、配布ファイル全体を暗号化した場合、実行の際に配布ファイル全体の復号化を行い、配布ファイル全体をメモリ上に配置するため、長時間配布ファイルを平文としたものをメモリ上に保持する必要があるためメモリの傍受に対し極めて弱い。   In addition, when the entire distribution file is encrypted, the entire distribution file is decrypted at the time of execution, and the entire distribution file is placed in the memory, so that the long distribution file in plain text is held in the memory. Because it is necessary, it is extremely vulnerable to memory interception.

本発明のアプリケーション実行装置は、オブジェクト指向型のプログラムで記述されたアプリケーションの実行を行うアプリケーション実行装置であって、入力される前記アプリケーションに含まれる暗号化クラスファイルを復号し平文のクラスファイルとした後、クラスオブジェクトに変換してヒープメモリへロードするデクリプタローダ、入力される前記アプリケーション内の平文クラスファイルをクラスオブジェクトに変換して前記ヒープメモリへロードするローダおよび前記ヒープメモリへロードされたクラスオブジェクトを解釈実行するインタプリタを有する仮想マシンと、前記インタプリタにて実行すべきクラスファイルが暗号化されたクラスファイルまたは平文クラスファイルかを判定するローディング判定部とを備え、前記ローディング判定部において、前記インタプリタにて実行すべきクラスファイルが暗号化されたクラスファイルであると判定された場合には前記クラスファイルを前記デクリプタローダへ送り、前記ローディング判定部において前記仮想マシンへ送られるクラスファイルが平文クラスファイルであると判定された場合には前記クラスファイルを前記ローダへ送るように構成したことを特徴とする。   An application execution apparatus according to the present invention is an application execution apparatus that executes an application described in an object-oriented program, and decrypts an encrypted class file included in the input application into a plain text class file. Then, a decrypter loader that converts the class object into a heap memory and loads it into the heap memory, a loader that converts the input plain text class file in the application into a class object and loads it into the heap memory, and a class loaded into the heap memory A virtual machine having an interpreter that interprets and executes an object; and a loading determination unit that determines whether a class file to be executed by the interpreter is an encrypted class file or a plain text class file. When the coding determination unit determines that the class file to be executed by the interpreter is an encrypted class file, the class determination unit sends the class file to the decryptor loader, and the loading determination unit transfers the class file to the virtual machine. In the case where it is determined that the class file to be sent is a plain text class file, the class file is sent to the loader.

また、前記アプリケーションは記録媒体内に記録され、かつ前記記録媒体は、前記アプリケーションに含まれる暗号化されたクラスファイルを復号するための復号鍵をマスター鍵にて暗号化して記録し、かつ前記デクリプタローダは前記マスター鍵を予め保持しており、前記暗号化されたクラスファイルが入力されると暗号化されたクラスファイルに対応する暗号化された復号鍵を前記記録媒体から取得し、前記暗号化された復号鍵を前記予め保持するマスター鍵を用いて復号し、前記復号された復号鍵を用いて前記暗号化されたクラスファイルを復号することを特徴とする。   In addition, the application is recorded in a recording medium, and the recording medium encrypts and records a decryption key for decrypting an encrypted class file included in the application with a master key, and stores the data in the recording medium. The crypt loader holds the master key in advance, and when the encrypted class file is input, obtains an encrypted decryption key corresponding to the encrypted class file from the recording medium, and The encrypted decryption key is decrypted using the master key stored in advance, and the encrypted class file is decrypted using the decrypted decryption key.

また、前記デクリプタローダは前記記録媒体から前記暗号化された復号鍵を取得し、暗号化されたクラスファイルが入力される前に前記マスター鍵を用いて前記暗号化された復号鍵を復号し、キャッシュするようにしたことを特徴とする。   The decrypter loader obtains the encrypted decryption key from the recording medium and decrypts the encrypted decryption key using the master key before the encrypted class file is input. It is characterized by being cached.

また、前記アプリケーションは記録媒体内に記録され、かつ前記記録媒体は、前記アプリケーションに含まれる暗号化されたクラスファイルを復号するための復号鍵であってタイトル鍵で暗号化された復号鍵および前記復号鍵を取り出すための情報を記述したメタファイルを記録し、前記ローディング判定部は前記アプリケーション実行時に前記アプリケーションに含まれる前記暗号化されたクラスファイルに対応する復号鍵を取り出すための情報を記述したメタファイルに基づいて対応する復号鍵を取り出すための情報を前記デクリプタローダへ送り、前記デクリプタローダは前記復号鍵を取り出すための情報に基づき前記暗号化された復号鍵を前記記録媒体から取得し、前記デクリプタローダが保持するタイトル鍵を用いて復号した復号鍵を用いて前記暗号化されたクラスファイルを復号することを特徴とする。   Further, the application is recorded in a recording medium, and the recording medium is a decryption key for decrypting an encrypted class file included in the application, the decryption key encrypted with a title key, and the A metafile describing information for extracting a decryption key is recorded, and the loading determination unit describes information for extracting a decryption key corresponding to the encrypted class file included in the application when the application is executed. Information for retrieving the corresponding decryption key based on the metafile is sent to the decryptor loader, and the decrypter loader obtains the encrypted decryption key from the recording medium based on the information for retrieving the decryption key Decrypted using the title key held by the decryptor loader Characterized by decrypting the encrypted class files with.

また、前記デクリプタローダは前記記録媒体から取得した復号鍵を保持するようにしたことを特徴とする。   The decrypter loader holds a decryption key acquired from the recording medium.

本発明のアプリケーション実行装置は、オブジェクト指向型のプログラムで記述されたアプリケーションの実行を行うアプリケーション実行装置であって、入力される前記アプリケーションに含まれる暗号化されたクラスファイルを復号し、平文クラスファイルをローダへ送るためのデクリプタおよび入力される前記アプリケーション内の平文クラスファイルまたは前記デクリプタにより復号された平文クラスファイルをクラスオブジェクトに変換しヒープメモリへロードするローダおよび前記ヒープメモリへロードされたクラスオブジェクトを解釈実行するインタプリタを有する仮想マシンと、前記インタプリタにて実行すべきクラスファイルが暗号化されたクラスファイルか平文クラスファイルかを判定するローディング判定部とを備え、前記ローディング判定部により前記インタプリタにて実行すべきクラスファイルが暗号化されたクラスファイルであると判定された場合、前記暗号化されたクラスファイルを前記デクリプタへ送り、前記ローディング判定部により前記仮想マシンへ送られるクラスファイルが平文クラスファイルであると判定された場合には前記クラスファイルを前記ローダへ送るように構成したことを特徴とする。   An application execution apparatus according to the present invention is an application execution apparatus that executes an application described in an object-oriented program, decrypts an encrypted class file included in the input application, and outputs a plaintext class file. And a loader that converts the input plaintext class file in the application or the plaintext class file decrypted by the decryptor into a class object and loads it into the heap memory, and the class object loaded into the heap memory A virtual machine having an interpreter that interprets and executes, and a loading determination unit that determines whether a class file to be executed by the interpreter is an encrypted class file or a plain text class file When it is determined by the loading determination unit that the class file to be executed by the interpreter is an encrypted class file, the encrypted class file is sent to the decryptor, and the virtual machine is transmitted by the loading determination unit. When the class file to be sent to is determined to be a plain text class file, the class file is sent to the loader.

また、前記アプリケーションは記録媒体内に記録され、かつ前記記録媒体は、前記アプリケーションに含まれる暗号化されたクラスファイルを復号するための復号鍵をマスター鍵にて暗号化して記録し、前記デクリプタは前記マスター鍵を予め保持しており、前記暗号化されたクラスファイルが入力されると、前記暗号化されたクラスファイルを復号するための復号鍵を前記記録媒体から取得し、前記取得した暗号化された復号鍵を前記予め保持するマスター鍵を用いて復号し、前記復号された復号鍵を用いて前記暗号化されたクラスファイルを復号することを特徴とする。   The application is recorded in a recording medium, and the recording medium encrypts and records a decryption key for decrypting an encrypted class file included in the application with a master key, and the decryptor The master key is held in advance, and when the encrypted class file is input, a decryption key for decrypting the encrypted class file is obtained from the recording medium, and the obtained encryption The decrypted key is decrypted using the master key held in advance, and the encrypted class file is decrypted using the decrypted decryption key.

また、前記デクリプタは前記記録媒体から前記暗号化された復号鍵を取得し、前記暗号化されたクラスファイルが入力される前に前記復号鍵をキャッシュするようにしたことを特徴とする。   The decryptor acquires the encrypted decryption key from the recording medium and caches the decryption key before the encrypted class file is input.

また、前記アプリケーションは記録媒体内に記録され、かつ前記記録媒体は、前記アプリケーションに含まれる暗号化されたクラスファイルを復号するための復号鍵であってタイトル鍵で暗号化された復号鍵および前記復号鍵を取り出すための情報を記述したメタファイルを記録し、前記ローディング判定部は前記アプリケーション実行時に前記アプリケーションに含まれる前記暗号化されたクラスファイルに対応する復号鍵を取り出すための情報を記述したメタファイルに基づいて対応する復号鍵を取り出すための情報を前記デクリプタへ送り、前記デクリプタは前記復号鍵を取り出すための情報に基づき前記暗号化された復号鍵を前記記録媒体から取得し、前記デクリプタが保持するタイトル鍵を用いて復号した復号鍵を用いて前記暗号化されたクラスファイルを復号することを特徴とする。   Further, the application is recorded in a recording medium, and the recording medium is a decryption key for decrypting an encrypted class file included in the application, the decryption key encrypted with a title key, and the A metafile describing information for extracting a decryption key is recorded, and the loading determination unit describes information for extracting a decryption key corresponding to the encrypted class file included in the application when the application is executed. Information for retrieving a corresponding decryption key based on the metafile is sent to the decryptor, and the decryptor obtains the encrypted decryption key from the recording medium based on the information for retrieving the decryption key, and the decryptor Using the decryption key decrypted using the title key held by Wherein the decoding the class file.

また、前記デクリプタは前記記録媒体から取得した復号鍵を保持するようにしたことを特徴とする。   Further, the decryptor holds a decryption key acquired from the recording medium.

本発明のアプリケーション実行装置は、オブジェクト指向型のプログラムで記述されたアプリケーションの実行を行うアプリケーション実行装置であって、入力される前記アプリケーションに含まれる暗号化クラスファイルを復号し平文のクラスファイルとした後、クラスオブジェクトに変換してヒープメモリへロードするデクリプタローダ、入力される前記アプリケーション内の平文クラスファイルをクラスオブジェクトに変換して前記ヒープメモリへロードするローダおよび前記ヒープメモリへロードされたクラスオブジェクトを解釈実行するインタプリタを有する仮想マシンと、前記インタプリタにて実行すべきクラスファイルが暗号化されたクラスファイルまたは平文クラスファイルかを判定するローディング判定部とを備え、前記ローディング判定部において、前記インタプリタにて実行すべきクラスファイルが暗号化されたクラスファイルであると判定された場合には前記クラスファイルを前記デクリプタローダへ送り、前記ローディング判定部において前記仮想マシンへ送られるクラスファイルが平文クラスファイルであると判定された場合には前記クラスファイルを前記ローダへ送るように構成したので、仮想マシン内で暗号化されたクラスファイルを復号し、ロードすることが可能となり、アプリケーション実行時の秘匿性が高くなるばかりか、クラスファイル単位でのロードが可能となるため、アプリケーション実行時の秘匿性が高くなる。   An application execution apparatus according to the present invention is an application execution apparatus that executes an application described in an object-oriented program, and decrypts an encrypted class file included in the input application into a plain text class file. Then, a decrypter loader that converts the class object into a heap memory and loads it into the heap memory, a loader that converts the input plain text class file in the application into a class object and loads it into the heap memory, and a class loaded into the heap memory A virtual machine having an interpreter that interprets and executes an object; and a loading determination unit that determines whether a class file to be executed by the interpreter is an encrypted class file or a plain text class file. When the coding determination unit determines that the class file to be executed by the interpreter is an encrypted class file, the class determination unit sends the class file to the decryptor loader, and the loading determination unit transfers the class file to the virtual machine. If it is determined that the class file to be sent is a plain text class file, the class file is sent to the loader, so it is possible to decrypt and load the encrypted class file in the virtual machine. Thus, not only the confidentiality at the time of executing the application becomes high, but also the loading at the class file unit becomes possible, so the confidentiality at the time of executing the application becomes high.

更に、アプリケーションの中に著作権保護されるべきクラスファイルを暗号化クラスファイルとし、著作権保護される必要のないクラスファイルを通常のクラスファイルとすることで、通常のクラスファイルをロードさせる場合にローダをチューニングすることにより通常のクラスファイルのローディング処理速度の向上を図ることが可能となる。   In addition, when a class file that should be copyright-protected in an application is an encrypted class file and a class file that does not need to be copyright-protected is a normal class file, the normal class file is loaded. By tuning the loader, it is possible to improve the normal class file loading processing speed.

また、前記アプリケーションは記録媒体内に記録され、かつ前記記録媒体は、前記アプリケーションに含まれる暗号化されたクラスファイルを復号するための復号鍵であってタイトル鍵で暗号化された復号鍵および前記復号鍵を取り出すための情報を記述したメタファイルを記録し、前記ローディング判定部は前記アプリケーション実行時に前記アプリケーションに含まれる前記暗号化されたクラスファイルに対応する復号鍵を取り出すための情報を記述したメタファイルに基づいて対応する復号鍵を取り出すための情報を前記デクリプタローダへ送り、前記デクリプタローダは前記復号鍵を取り出すための情報に基づき前記暗号化された復号鍵を前記記録媒体から取得し、前記デクリプタローダが保持するタイトル鍵を用いて復号した復号鍵を用いて前記暗号化されたクラスファイルを復号するので、復号鍵および暗号化されたクラスファイルのリバースエンジニアリング技術での解析が困難となる。   Further, the application is recorded in a recording medium, and the recording medium is a decryption key for decrypting an encrypted class file included in the application, the decryption key encrypted with a title key, and the A metafile describing information for extracting a decryption key is recorded, and the loading determination unit describes information for extracting a decryption key corresponding to the encrypted class file included in the application when the application is executed. Information for retrieving the corresponding decryption key based on the metafile is sent to the decryptor loader, and the decrypter loader obtains the encrypted decryption key from the recording medium based on the information for retrieving the decryption key Decrypted using the title key held by the decryptor loader Since decrypting the encrypted class file with, it is difficult to analyze in reverse engineering techniques decryption key and the encrypted class files.

また、前記デクリプタローダは前記記録媒体から前記暗号化された復号鍵を取得し、暗号化されたクラスファイルが入力される前に前記マスター鍵を用いて前記暗号化された復号鍵を復号し、キャッシュするようにしたので、復号鍵を用いて暗号化されたクラスファイルを復号する処理を速くすることができる。   The decrypter loader obtains the encrypted decryption key from the recording medium and decrypts the encrypted decryption key using the master key before the encrypted class file is input. Therefore, the process of decrypting the class file encrypted using the decryption key can be speeded up.

また、前記アプリケーションは記録媒体内に記録され、かつ前記記録媒体は、前記アプリケーションに含まれる暗号化されたクラスファイルを復号するための復号鍵であってタイトル鍵で暗号化された復号鍵および前記復号鍵を取り出すための情報を記述したメタファイルを記録し、前記ローディング判定部は前記アプリケーション実行時に前記アプリケーションに含まれる前記暗号化されたクラスファイルに対応する復号鍵を取り出すための情報を記述したメタファイルに基づいて対応する復号鍵を取り出すための情報を前記デクリプタローダへ送り、前記デクリプタローダは前記復号鍵を取り出すための情報に基づき前記暗号化された復号鍵を前記記録媒体から取得し、前記デクリプタローダが保持するタイトル鍵を用いて復号した復号鍵を用いて前記暗号化されたクラスファイルを復号するこので、暗号化されたクラスファイルに対応する復号鍵を取り出すための情報を記述したメタファイルに複数の復号鍵を特定することで複数の復号鍵が利用可能になり、複数の復号鍵のひとつが暗号解読法により攻撃者にわかってしまっても、他の復号鍵が攻撃者に分らない限りは、他の復号鍵を用いて復号する暗号化されたクラスファイルの解読が出来ないため、より秘匿性が高くなる。   Further, the application is recorded in a recording medium, and the recording medium is a decryption key for decrypting an encrypted class file included in the application, the decryption key encrypted with a title key, and the A metafile describing information for extracting a decryption key is recorded, and the loading determination unit describes information for extracting a decryption key corresponding to the encrypted class file included in the application when the application is executed. Information for retrieving the corresponding decryption key based on the metafile is sent to the decryptor loader, and the decrypter loader obtains the encrypted decryption key from the recording medium based on the information for retrieving the decryption key Decrypted using the title key held by the decryptor loader The decrypted class file is decrypted by using a plurality of decryption keys by specifying a plurality of decryption keys in a metafile that describes information for extracting a decryption key corresponding to the encrypted class file. Even if the key becomes available and one of the multiple decryption keys is known to the attacker by cryptanalysis, the decryption key can be decrypted using another decryption key unless the attacker knows the other decryption key. Since the class file cannot be decrypted, the secrecy becomes higher.

また、前記デクリプタローダは前記記録媒体から取得した復号鍵を保持するようにしたので、復号鍵を用いて暗号化されたクラスファイルを復号する処理を速くすることができる。   In addition, since the decrypter loader holds the decryption key acquired from the recording medium, the process of decrypting the class file encrypted using the decryption key can be accelerated.

本発明のアプリケーション実行装置は、オブジェクト指向型のプログラムで記述されたアプリケーションの実行を行うアプリケーション実行装置であって、入力される前記アプリケーションに含まれる暗号化されたクラスファイルを復号し、平文クラスファイルをローダへ送るためのデクリプタおよび入力される前記アプリケーション内の平文クラスファイルまたは前記デクリプタにより復号された平文クラスファイルをクラスオブジェクトに変換しヒープメモリへロードするローダおよび前記ヒープメモリへロードされたクラスオブジェクトを解釈実行するインタプリタを有する仮想マシンと、前記インタプリタにて実行すべきクラスファイルが暗号化されたクラスファイルか平文クラスファイルかを判定するローディング判定部とを備え、前記ローディング判定部により前記インタプリタにて実行すべきクラスファイルが暗号化されたクラスファイルであると判定された場合、前記暗号化されたクラスファイルを前記デクリプタへ送り、前記ローディング判定部により前記仮想マシンへ送られるクラスファイルが平文クラスファイルであると判定された場合には前記クラスファイルを前記ローダへ送るように構成したことを特徴とする。   An application execution apparatus according to the present invention is an application execution apparatus that executes an application described in an object-oriented program, decrypts an encrypted class file included in the input application, and outputs a plaintext class file. And a loader that converts the input plaintext class file in the application or the plaintext class file decrypted by the decryptor into a class object and loads it into the heap memory, and the class object loaded into the heap memory A virtual machine having an interpreter that interprets and executes, and a loading determination unit that determines whether a class file to be executed by the interpreter is an encrypted class file or a plain text class file When it is determined by the loading determination unit that the class file to be executed by the interpreter is an encrypted class file, the encrypted class file is sent to the decryptor, and the virtual machine is transmitted by the loading determination unit. When the class file to be sent to is determined to be a plain text class file, the class file is sent to the loader.

また、前記アプリケーションは記録媒体内に記録され、かつ前記記録媒体は、前記アプリケーションに含まれる暗号化されたクラスファイルを復号するための復号鍵をマスター鍵にて暗号化して記録し、前記デクリプタは前記マスター鍵を予め保持しており、前記暗号化されたクラスファイルが入力されると、前記暗号化されたクラスファイルを復号するための復号鍵を前記記録媒体から取得し、前記取得した暗号化された復号鍵を前記予め保持するマスター鍵を用いて復号し、前記復号された復号鍵を用いて前記暗号化されたクラスファイルを復号するので、仮想マシン内で暗号化されたクラスファイルを復号し、ロードすることが可能となり、アプリケーション実行時の秘匿性が高くなるばかりか、クラスファイル単位でのロードが可能となるため、アプリケーション実行時の秘匿性が高くなる。   The application is recorded in a recording medium, and the recording medium encrypts and records a decryption key for decrypting an encrypted class file included in the application with a master key, and the decryptor The master key is held in advance, and when the encrypted class file is input, a decryption key for decrypting the encrypted class file is obtained from the recording medium, and the obtained encryption The decrypted key is decrypted using the master key held in advance, and the encrypted class file is decrypted using the decrypted decryption key, so the encrypted class file is decrypted in the virtual machine. It can be loaded, and the confidentiality at the time of application execution becomes high, and loading by class file unit is possible. Made for, confidentiality at the time of application execution is higher.

更に、アプリケーションの中に著作権保護されるべきクラスファイルを暗号化クラスファイルとし、著作権保護される必要のないクラスファイルを通常のクラスファイルとすることで、通常のクラスファイルをロードさせる場合にローダをチューニングすることにより通常のクラスファイルのローディング処理速度の向上を図ることが可能となる。   In addition, when a class file that should be copyright-protected in an application is an encrypted class file and a class file that does not need to be copyright-protected is a normal class file, the normal class file is loaded. By tuning the loader, it is possible to improve the normal class file loading processing speed.

また、前記アプリケーションは記録媒体内に記録され、かつ前記記録媒体は、前記アプリケーションに含まれる暗号化されたクラスファイルを復号するための復号鍵をマスター鍵にて暗号化して記録し、前記デクリプタは前記マスター鍵を予め保持しており、前記暗号化されたクラスファイルが入力されると、前記暗号化されたクラスファイルを復号するための復号鍵を前記記録媒体から取得し、前記取得した暗号化された復号鍵を前記予め保持するマスター鍵を用いて復号し、前記復号された復号鍵を用いて前記暗号化されたクラスファイルを復号するので、復号鍵および暗号化されたクラスファイルのリバースエンジニアリング技術での解析が困難となる。   The application is recorded in a recording medium, and the recording medium encrypts and records a decryption key for decrypting an encrypted class file included in the application with a master key, and the decryptor The master key is held in advance, and when the encrypted class file is input, a decryption key for decrypting the encrypted class file is obtained from the recording medium, and the obtained encryption Since the decrypted key is decrypted using the master key held in advance, and the encrypted class file is decrypted using the decrypted decryption key, the reverse engineering of the decrypted key and the encrypted class file is performed. Analysis with technology becomes difficult.

また、前記デクリプタは前記記録媒体から前記暗号化された復号鍵を取得し、前記暗号化されたクラスファイルが入力される前に前記復号鍵をキャッシュするようにしたので、復号鍵を用いて暗号化されたクラスファイルを復号する処理を速くすることができる。   Further, the decryptor obtains the encrypted decryption key from the recording medium and caches the decryption key before the encrypted class file is input. It is possible to speed up the process of decrypting the converted class file.

また、前記アプリケーションは記録媒体内に記録され、かつ前記記録媒体は、前記アプリケーションに含まれる暗号化されたクラスファイルを復号するための復号鍵であってタイトル鍵で暗号化された復号鍵および前記復号鍵を取り出すための情報を記述したメタファイルを記録し、前記ローディング判定部は前記アプリケーション実行時に前記アプリケーションに含まれる前記暗号化されたクラスファイルに対応する復号鍵を取り出すための情報を記述したメタファイルに基づいて対応する復号鍵を取り出すための情報を前記デクリプタへ送り、前記デクリプタは前記復号鍵を取り出すための情報に基づき前記暗号化された復号鍵を前記記録媒体から取得し、前記デクリプタが保持するタイトル鍵を用いて復号した復号鍵を用いて前記暗号化されたクラスファイルを復号するので、暗号化されたクラスファイルに対応する復号鍵を取り出すための情報を記述したメタファイルに複数の復号鍵を特定することで複数の復号鍵が利用可能になり、複数の復号鍵のひとつが暗号解読法により攻撃者にわかってしまっても、他の復号鍵が攻撃者に分らない限りは、他の復号鍵を用いて復号する暗号化されたクラスファイルの解読が出来ないため、より秘匿性が高くなる。   Further, the application is recorded in a recording medium, and the recording medium is a decryption key for decrypting an encrypted class file included in the application, the decryption key encrypted with a title key, and the A metafile describing information for extracting a decryption key is recorded, and the loading determination unit describes information for extracting a decryption key corresponding to the encrypted class file included in the application when the application is executed. Information for retrieving a corresponding decryption key based on the metafile is sent to the decryptor, and the decryptor obtains the encrypted decryption key from the recording medium based on the information for retrieving the decryption key, and the decryptor Using the decryption key decrypted using the title key held by Since the decrypted class file is decrypted, a plurality of decryption keys can be used by specifying a plurality of decryption keys in the metafile that describes information for extracting the decryption key corresponding to the encrypted class file. Even if one of the multiple decryption keys is known to the attacker by the decryption method, unless the other decryption key is known to the attacker, the decryption of the encrypted class file that is decrypted using the other decryption key Since it cannot be performed, confidentiality becomes higher.

また、前記デクリプタは前記記録媒体から取得した復号鍵を保持するようにしたので、復号鍵を用いて暗号化されたクラスファイルを復号する処理を速くすることができる。   In addition, since the decryptor holds the decryption key acquired from the recording medium, it is possible to speed up the process of decrypting the class file encrypted using the decryption key.

以下に、本発明の実施形態を、図面を参照しながら説明する。   Embodiments of the present invention will be described below with reference to the drawings.

(実施の形態1)
図1は、本実施の形態に用いる記録媒体の一例であるBD−ROM(BDともいう)の構成を示した図である。BDディスクは、他の光ディスク、例えばDVDやCDなどと同様にその内周から外周に向けてらせん状に記録領域を持ち、内周のリード・インと外周のリード・アウトの間に論理データを記録できる論理アドレス空間を有している。また、リード・インの内側にはBCA(Burst Cutting Area)と呼ばれるドライブでしか読み出せない特別な領域がある。この領域はアプリケーションから読み出せないため、例えば著作権保護技術などに利用されることがよくある。
(Embodiment 1)
FIG. 1 is a diagram illustrating a configuration of a BD-ROM (also referred to as a BD) which is an example of a recording medium used in the present embodiment. A BD disc has a spiral recording area from the inner circumference to the outer circumference like other optical discs such as DVDs and CDs, and logical data is transferred between the inner lead-in and outer lead-out. It has a logical address space that can be recorded. Further, inside the lead-in, there is a special area that can be read only by a drive called BCA (Burst Cutting Area). Since this area cannot be read from an application, it is often used for copyright protection technology, for example.

論理アドレス空間には、ファイルシステム情報(ボリューム)を先頭に映像データなどのアプリケーションデータが記録されている。ファイルシステムの実現例として、UDFやISO9660などの方式があり、通常のPCと同じように記録されている論理データをディレクトリ、ファイル構造を使って読み出しする事が可能になっている。   Application data such as video data is recorded in the logical address space with file system information (volume) at the head. As an implementation example of the file system, there are methods such as UDF and ISO9660, and logical data recorded in the same way as a normal PC can be read using a directory and file structure.

本実施の形態の場合、BDディスク上のディレクトリ、ファイル構造は、ルートディレクトリ(ROOT)直下にBDDATAディレクトリが置かれている。このディレクトリはBD−ROMで扱うJava(登録商標)アプリケーションが記録されているディレクトリである。   In the case of the present embodiment, the directory and file structure on the BD disc is a BDDATA directory placed directly under the root directory (ROOT). This directory is a directory in which Java (registered trademark) applications handled by the BD-ROM are recorded.

BDDATAディレクトリの下には、次の2種類のファイルが記録されている。   The following two types of files are recorded under the BDDATA directory.

(1) XXX.JAR(「XXX」は可変、拡張子「JAR」は固定)
Jarファイル仕様に準拠したJava(登録商標)アーカイブファイルである(以下Jarファイルと称する)。Jarファイルは複数のファイルをディレクトリ構造の形で格納している。一つのJarファイルは一つ以上のクラスファイル、Jarファイルの属性を示すメタファイル、画像などのデータが格納されている。基本的に一つのJarファイルに一つのJava(登録商標)アプリケーションが格納されており、Java(登録商標)アプリケーションはJava(登録商標)バーチャルマシーン上で実行することができる。Java(登録商標)アプリケーションは一つ以上のクラスファイルより構成されるが、Java(登録商標)アプリケーションの著作権保護を行う必要がある場合、一つ以上のクラスファイルが暗号化される。暗号化されていないクラスファイルは拡張子「class」を利用する。また、暗号化されているクラスファイルは拡張子「secure」を利用する。暗号化されているクラスファイルは、復号鍵(後述)がなければリバースエンジニアリングを利用しJava(登録商標)アプリケーションを復元することが不可能である。
(1) XXX. JAR ("XXX" is variable, extension "JAR" is fixed)
It is a Java (registered trademark) archive file conforming to the Jar file specification (hereinafter referred to as a Jar file). A Jar file stores a plurality of files in a directory structure. One Jar file stores data such as one or more class files, a metafile indicating attributes of the Jar file, and an image. Basically, one Java (registered trademark) application is stored in one Jar file, and the Java (registered trademark) application can be executed on the Java (registered trademark) virtual machine. A Java (registered trademark) application is composed of one or more class files. When it is necessary to protect the copyright of a Java (registered trademark) application, one or more class files are encrypted. An unencrypted class file uses the extension “class”. The encrypted class file uses the extension “secure”. An encrypted class file cannot restore a Java (registered trademark) application using reverse engineering without a decryption key (described later).

(2) XXX.KEY(「XXX」は可変、拡張子「KEY」は固定)
クラスファイルの復号化に必要な復号鍵である。復号鍵はマスター鍵で暗号化されており、再生装置でしか復号化できないようになっている。マスター鍵は再生装置の内部で保持されている。
(2) XXX. KEY ("XXX" is variable, extension "KEY" is fixed)
This is the decryption key required for decrypting the class file. The decryption key is encrypted with the master key and can be decrypted only by the playback device. The master key is held inside the playback device.

図2はJarファイルの中のファイル構造の一例である。ルートディレクトリ401以下に「META−INF」ディレクトリ402、「NotProtected.class」ファイル403、「Protected.secure」ファイル404が格納されている。「META−INF」ディレクトリ402以下に「MANIFEST.MF」に対応するマニフェストファイル405が格納されている。   FIG. 2 shows an example of the file structure in the Jar file. Under the root directory 401, a “META-INF” directory 402, a “NotProtected.class” file 403, and a “Protected.secure” file 404 are stored. A manifest file 405 corresponding to “MANIFEST.MF” is stored under the “META-INF” directory 402.

「NotProtected.class」ファイル403はクラスファイルの一例である。クラスファイルの仕様に準拠したファイルである。   A “NotProtected.class” file 403 is an example of a class file. The file conforms to the class file specification.

「Protected.secure」ファイル404は暗号化クラスファイルの一例である。暗号化されているため、現状でのリバースエンジニアリングでの解析が不可能と見なせるものである。   The “Protected.secure” file 404 is an example of an encryption class file. Since it is encrypted, it can be considered that analysis by reverse engineering in the present situation is impossible.

図3は再生制御のレイヤモデルを示した図である。図3の第1層は、物理層であり、処理対象たるJarファイルの供給制御である。この第1層に示すように、処理対象たるJarファイルは、BD−ROMだけではなく、HD、メモリカード、ネットワークといったあらゆる記録媒体、通信媒体を供給源としている。これらHD、メモリカード、ネットワークといった供給源に対する制御(ディスクアクセス、カードアクセス、ネットワーク通信)が第1層の制御である。   FIG. 3 is a diagram showing a layer model for reproduction control. The first layer in FIG. 3 is a physical layer and is supply control of a Jar file to be processed. As shown in the first layer, the Jar file to be processed uses not only the BD-ROM but also any recording medium such as HD, memory card, network, and communication medium as the supply source. The control of the supply sources such as HD, memory card, network (disk access, card access, network communication) is the first layer control.

第2層は、ミドルウェアのレイアである。第1層で供給されたJarファイルを、どのように実行するのかを規定しているのがこの第2層である。たとえばオペレーティングシステムやJava(登録商標)バーチャルマシーンやCPUに依存したネイティブライブラリや実行ファイルなどがミドルウェア層に存在する。   The second layer is a middleware layer. It is this second layer that defines how to execute the Jar file supplied in the first layer. For example, an operating system, a Java (registered trademark) virtual machine, a CPU-dependent native library, an execution file, and the like exist in the middleware layer.

第3層は、Java(登録商標)のレイアである。Java(登録商標)バーチャルマシーン上で実行されるJava(登録商標)アプリケーションおよびクラスライブラリは第3層に存在する。Java(登録商標)アプリケーションは記述された命令やユーザ入力に基づき処理を行い一定の出力、例えばオーディオやビデオの出力を行う。クラスライブラリはJava(登録商標)アプリケーションに対してJava(登録商標)のプロファイルで定義されているアプリケーションプログラミングインターフェース(API)を提供する。Java(登録商標)アプリケーションおよびクラスライブラリはJava(登録商標)の中間コードで書かれていて、第2層のJava(登録商標)バーチャルマシーンにより解釈実行される。Java(登録商標)アプリケーションは複数のクラスファイルにより構成されるが解釈実行されるためにクラスファイルがクラスオブジェクトに変換される必要がある。クラスオブジェクトはクラスファイルの内部表現とも言える。   The third layer is a Java (registered trademark) layer. Java applications and class libraries that run on Java virtual machines exist in the third layer. A Java (registered trademark) application performs processing based on a written command and user input, and outputs a certain output, for example, audio or video. The class library provides an application programming interface (API) defined by a Java (registered trademark) profile for a Java (registered trademark) application. Java (registered trademark) applications and class libraries are written in Java (registered trademark) intermediate code, and are interpreted and executed by the Java (registered trademark) virtual machine in the second layer. A Java (registered trademark) application is composed of a plurality of class files, but needs to be converted into class objects in order to be interpreted and executed. A class object is also an internal representation of a class file.

図4は、再生装置の大まかな機能構成を示すブロック図である。図3に示すように、再生装置は、BD−ROMドライブ601、ヒープメモリ104、インタプリタ103、デクリプタローダ602、ローダ105、UO検知モジュール603、出力エンジン604から構成される。   FIG. 4 is a block diagram showing a rough functional configuration of the playback apparatus. As shown in FIG. 3, the playback device includes a BD-ROM drive 601, a heap memory 104, an interpreter 103, a decrypter loader 602, a loader 105, a UO detection module 603, and an output engine 604.

但し、図4の例ではJarファイルの供給源をBD−ROMとしたものを例にして説明するものであり、Jarファイルの供給源として他にHD、メモリカード、ネットワークといった記録媒体、通信媒体を供給源とするのであればそれらの情報を取り込む手段がBD−ROMドライブ601に代替することが可能である。   However, in the example of FIG. 4, the description will be made by taking an example in which the supply source of the Jar file is a BD-ROM. If it is a supply source, a means for capturing such information can be substituted for the BD-ROM drive 601.

BD−ROMドライブ601は、BD−ROMのローディング/イジェクトを行い、BD−ROMに対するアクセスを実行する。   The BD-ROM drive 601 performs loading / ejecting of the BD-ROM and accesses the BD-ROM.

ヒープメモリ104は、Jarファイルを格納しJava(登録商標)層に必要なメモリである。ヒープメモリ104には後述するクラスファイルの内部形式(Java(登録商標)バーチャルマシーンに依存した構造体)であるクラスオブジェクトも格納される。   The heap memory 104 stores Jar files and is necessary for the Java (registered trademark) layer. The heap memory 104 also stores a class object that is an internal format of a class file (a structure depending on a Java (registered trademark) virtual machine) described later.

インタプリタ103はJava(登録商標)バーチャルマシーンの中核であり、クラスオブジェクトの中にあるバイトコードの解釈実行を行う。インタプリタ103はJava(登録商標)アプリケーションの実行速度に直接影響を与える重要な部分である。解釈実行の高速化を図るためにバイトコードをネイティブコードに変換するJITコンパイラを備えたインタプリタ(図示せず)やインタプリタの一部をハードウェア(図示せず)で実装される製品も市販されている。   The interpreter 103 is the core of the Java (registered trademark) virtual machine, and interprets and executes byte codes in the class object. The interpreter 103 is an important part that directly affects the execution speed of the Java (registered trademark) application. An interpreter (not shown) equipped with a JIT compiler that converts bytecode into native code to speed up interpretation execution and products that implement part of the interpreter in hardware (not shown) are also available on the market. Yes.

ローディング判定部(図示せず)はクラスオブジェクトの生成(ロードともいう)の必要性を判定する。ローディング判定部はインタプリタ103上で解釈実行される。クラスオブジェクトが必要な場合、インタプリタ103がローディング判定部の解釈実行を行う。   A loading determination unit (not shown) determines the necessity for generation (also referred to as loading) of class objects. The loading determination unit is interpreted and executed on the interpreter 103. When a class object is necessary, the interpreter 103 interprets and executes the loading determination unit.

解釈実行により、インタプリタがヒープメモリ104上のクラスファイルのロードをデクリプタローダまたはローダに要求する。ローディング判定部はヒープメモリ103上にクラスオブジェクトのキャッシュを持っている。ローディング判定部はJava(登録商標)層にあるClassLoaderクラスまたはその継承クラスとして実装される。尚ローディング判定部は高速化のため、一部ミドルウェア層で実装されることもある。   By executing the interpretation, the interpreter requests the descriptor loader or loader to load the class file on the heap memory 104. The loading determination unit has a cache of class objects on the heap memory 103. The loading determination unit is implemented as a ClassLoader class in the Java (registered trademark) layer or its inheritance class. Note that the loading determination unit may be partially implemented in the middleware layer for speeding up.

デクリプタローダ602はBD−ROMに存在する復号鍵を利用し暗号化クラスファイルを復号化した後、ヒープメモリ104上にクラスオブジェクトを生成する。BD−ROMに記録された復号鍵はマスター鍵で暗号化されている。デクリプタローダ602はマスター鍵を保持しており、マスター鍵を利用することで暗号化された復号鍵を復号した上で、この復号鍵を用いて暗号化されたクラスファイルを平文に復元することができる。デクリプタローダ602は著作権保護を行う上で重要な部分である。   The decrypter loader 602 generates a class object on the heap memory 104 after decrypting the encrypted class file using the decryption key existing in the BD-ROM. The decryption key recorded on the BD-ROM is encrypted with the master key. The decrypter loader 602 holds a master key, decrypts the decryption key encrypted by using the master key, and restores the class file encrypted using the decryption key to plain text Can do. The decrypter loader 602 is an important part for copyright protection.

デクリプタローダ602内に保持されるマスター鍵が第3者にわかってしまうと、マスター鍵にて暗号化された復号鍵の詳細な情報わかってしまい、その第3者に対して著作権保護ができなくなる。   When the third party knows the master key held in the decrypter loader 602, detailed information on the decryption key encrypted with the master key is known, and copyright protection is provided to the third party. become unable.

その場合、マスター鍵に関する情報が第3者により公開されてしまう恐れがある上に、復号鍵やその中間データや平文クラスファイルが傍受されてしまう危険性があるため、マスター鍵については実装する場合にセキュリティの配慮が多いに必要である。   In that case, there is a risk that information about the master key may be disclosed by a third party, and there is a risk that the decryption key, its intermediate data, or plain text class file may be intercepted. This is necessary for security considerations.

デクリプタローダ602がハードウェアで実装される場合、マスター鍵をハードウェアに隠蔽することが可能になり秘匿性が高くなる。デクリプタローダ602は暗号化クラスファイルを復号した後、平文クラスファイルを一時的にヒープメモリ104上に配置することもできるが、その場合ヒープメモリ104内の情報の傍受を困難にさせるため、復号した平文のクラスファイルをヒープメモリへ配置する期間をなるべく短くする必要があり、復号した平文のクラスファイルの利用が完了した後、速やかにヒープメモリ104から削除(たとえば、0で上書き)しなければならない。   When the decrypter loader 602 is implemented in hardware, the master key can be concealed in hardware, and confidentiality is improved. After decrypting the encrypted class file, the decrypter loader 602 can temporarily place the plain text class file on the heap memory 104, but in this case, in order to make it difficult to intercept information in the heap memory 104, It is necessary to shorten the period during which the plain text class file is allocated to the heap memory as much as possible. After the use of the decrypted plain text class file is completed, the plain text class file must be immediately deleted from the heap memory 104 (for example, overwritten with 0). Don't be.

ローダ105は平文クラスファイルを対応するクラスオブジェクトに変換し、ヒープメモリ104上にロードするものである。ヒープメモリ104上にロードされたクラスオブジェクトはインタプリタ103より解釈実行が可能である。   The loader 105 converts the plain text class file into a corresponding class object and loads it onto the heap memory 104. The class object loaded on the heap memory 104 can be interpreted and executed by the interpreter 103.

UO検知モジュール603は、リモコン(図示せず)や再生装置のフロントパネルといった入力手段に対してなされたユーザ操作を検知して、Java(登録商標)バーチャルマシーンへの通知を行う。   The UO detection module 603 detects a user operation performed on input means such as a remote controller (not shown) or a front panel of a playback device, and notifies the Java (registered trademark) virtual machine.

出力エンジン604はJava(登録商標)バーチャルマシーンより要求されるオーディオやビデオの出力を行う。   The output engine 604 outputs audio and video required by a Java (registered trademark) virtual machine.

インタプリタ103はアプリケーションプログラムを解釈実行中に、アプリケーションに含まれるクラスファイル(暗号化されたクラスファイルまたは平文のクラスファイル)の実行を必要とした場合、ローディング判定部を呼び出して、実行すべき対象となるクラスファイルをデクリプタローダ602によりロードさせるべきか、ローダ105によりロードさせるべきかを判定する。これは、例えばClassLoaderクラスが持つメソッドloadClass(クラス名)において、括弧内のクラス名を引数にして呼び出すことにより開始される。   When the interpreter 103 needs to execute a class file (encrypted class file or plain text class file) included in the application while interpreting and executing the application program, the interpreter 103 calls the loading determination unit and sets the object to be executed. Whether the class file to be loaded should be loaded by the decrypter loader 602 or the loader 105 is determined. This is started, for example, by calling the method loadClass (class name) of the ClassLoader class with the class name in parentheses as an argument.

ローディング判定部とJava(登録商標)バーチャルマシーンとのインターフェースを図5に示す。   FIG. 5 shows an interface between the loading determination unit and the Java (registered trademark) virtual machine.

ローディング判定部は例えばロードすべきクラスファイルの拡張子を調べ、対象となるクラスファイルが暗号化されている(例えば図2に示すものでは拡張子が「.secure」である)と判断した場合、APIであるdefineEncryptedClass(クラス名、暗号化クラスファイル)の呼び出しを行い暗号化クラスファイルのロードをミドルウェア層のデクリプタローダ602に依頼する。   For example, when the loading determination unit checks the extension of the class file to be loaded and determines that the target class file is encrypted (for example, the extension is “.secure” in FIG. 2), The API calls defineEncryptedClass (class name, encrypted class file) to request the middleware layer decryptor loader 602 to load the encrypted class file.

また、ローディング判定部はロードすべきクラスファイルが暗号化されていない(例えば図2に示すものでは拡張子が「.class」である)と判断した場合、APIであるdefineClass(クラス名、平文クラスファイル)の呼び出しを行い平文クラスファイルのロードをミドルウェア層のローダ105に依頼する。ローディング判定部はクラスライブラリの1つとして格納されており、呼び出しに応じて解釈実行されるため、ローディング判定部からデクリプタローダ602/ローダ105への依頼はインタプリタ103を通して行われる。   When the loading determination unit determines that the class file to be loaded is not encrypted (for example, the extension is “.class” in the case of FIG. 2), the API defines class (class name, plaintext class). File) is called to request the middleware layer loader 105 to load the plaintext class file. Since the loading determination unit is stored as one of the class libraries and is interpreted and executed in response to the call, a request from the loading determination unit to the decrypter loader 602 / loader 105 is made through the interpreter 103.

図6を参照して、Java(登録商標)層で実行されるローディング判定部がクラスオブジェクトを返す制御フローを説明する。   With reference to FIG. 6, the control flow in which the loading determination unit executed in the Java (registered trademark) layer returns the class object will be described.

クラスオブジェクトを要求されたローディング判定部はまずキャッシュ(図示せず)に対象となるクラスオブジェクトがキャッシュされているかどうかを検索する(S601)。ローディング判定部は自身がロードしたクラスオブジェクトのキャッシュを持っていて同じクラスオブジェクトを2回以上ヒープメモリ104へロードしないようにしている。   The loading determination unit that has requested the class object first searches whether a target class object is cached in a cache (not shown) (S601). The loading determination unit has a cache of class objects loaded by itself, and prevents the same class object from being loaded into the heap memory 104 more than once.

対象のクラスオブジェクトを見つけた場合(S602)、クラスオブジェクトをインタプリタ103に返す(S603)。   When the target class object is found (S602), the class object is returned to the interpreter 103 (S603).

ローディング判定部がキャッシュから対象となるクラスオブジェクトを見つからなかった場合(S602)、対象のクラスを定義するクラスファイルをJarファイルの中から取得する(S604)。   When the loading determination unit does not find the target class object from the cache (S602), the class file defining the target class is acquired from the Jar file (S604).

クラスファイルはJarファイルの中に格納されていて必要なクラスの名前に基づきクラスファイルを取得することができる。例えば、クラス名が「Abracadabra」の場合、暗号化されているクラスファイルのファイル名は「Abracadabra.secure」であり、暗号化されていないクラスファイルのファイル名は「Abracadabra.class」である。ローディング判定部は優先的に暗号化されているクラスファイルを選択する。   The class file is stored in the Jar file, and the class file can be acquired based on the necessary class name. For example, when the class name is “Abracadara”, the file name of the encrypted class file is “Abracabara.secure”, and the file name of the unencrypted class file is “Abracabara.class”. The loading determination unit selects a class file that is preferentially encrypted.

ローディング判定部はJarファイルより取得したクラスファイルが暗号化されているかどうかの判断を行う(S605)。クラスファイルが暗号化されているかどうかはクラスファイルの拡張子を調べることにより行うことができる。   The loading determination unit determines whether or not the class file acquired from the Jar file is encrypted (S605). Whether the class file is encrypted can be determined by examining the extension of the class file.

ローディング判定部はクラスファイルが暗号化されていると判断した場合、暗号化クラスファイルのロードを依頼する(S606)。暗号化クラスファイルのロードはAPIであるdefineEncryptedClass(クラス名、暗号化クラスファイル)の呼び出しにより行われる。暗号化クラスファイルのロードによりヒープメモリ104上の一つのクラスオブジェクトを取得する。   When it is determined that the class file is encrypted, the loading determination unit requests loading of the encrypted class file (S606). The encryption class file is loaded by calling defineEncryptedClass (class name, encryption class file) which is an API. One class object on the heap memory 104 is acquired by loading the encrypted class file.

ローディング判定部はクラスファイルが暗号化されていないと判断した場合、平文クラスファイルのロードを依頼する(S607)。平文クラスファイルのロードはAPIであるdefineClass(クラス名、平文クラスファイル)の呼び出しにより行われる。平文クラスファイルのロードによりヒープメモリ104上に一つのクラスオブジェクトを取得する。   If the loading determination unit determines that the class file is not encrypted, it requests the loading of the plaintext class file (S607). The plaintext class file is loaded by calling defineClass (class name, plaintext class file) which is an API. One class object is acquired on the heap memory 104 by loading the plaintext class file.

ローディング判定部は新しくできたクラスオブジェクトをキャッシュした後(S609)、新しくできたクラスオブジェクトを返す(S610)。   After loading the newly created class object (S609), the loading determination unit returns the newly created class object (S610).

暗号化クラスファイルのロードを行うためのAPI呼び出しdefineEncryptedClass(クラス名、暗号化クラスファイル)はデクリプタローダ602より処理される。図7を参照して、デクリプタローダ602が暗号化クラスファイルを復号し、ヒープメモリ104上にクラスオブジェクトを生成する制御フローを説明する。   The API call defineEncryptedClass (class name, encrypted class file) for loading the encrypted class file is processed by the decrypter loader 602. A control flow in which the decrypter loader 602 decrypts the encrypted class file and generates a class object on the heap memory 104 will be described with reference to FIG.

デクリプタローダ602は受け取った暗号化クラスファイルを復号し対応する平文のクラスファイルにする(S701)。この復号は、デクリプタローダ602が内部で保持する復号鍵で復号化できる。   The decrypter loader 602 decrypts the received encrypted class file and converts it into a corresponding plain text class file (S701). This decryption can be decrypted with a decryption key held internally by the decrypter loader 602.

デクリプタローダ602はクラスファイルのベリファイを行いクラスファイルが改竄されていないかなどをチェックする(S702)。   The decrypter loader 602 verifies the class file and checks whether the class file has been tampered with (S702).

デクリプタローダ602はベリファイを行った後、クラスファイルをクラスオブジェクトに変換する(S703)。クラスオブジェクトはJava(登録商標)バーチャルマシーンに依存した構造体という形でヒープメモリ104に格納され、ヒープメモリ104上の情報が傍受されてもクラスオブジェクトをクラスファイルに復元することが困難である。   After verifying, the decrypter loader 602 converts the class file into a class object (S703). The class object is stored in the heap memory 104 in the form of a structure depending on the Java (registered trademark) virtual machine, and it is difficult to restore the class object to the class file even if information on the heap memory 104 is intercepted.

デクリプタローダ602は著作権保護対象のクラスファイルを一時的に内部で保持している間はクラスファイルの傍受を避ける。クラスファイルの傍受を避けるために第2層のミドルウェア層や第1層の物理層に存在しなければならない。   The decrypter loader 602 avoids intercepting the class file while temporarily holding the class file subject to copyright protection. In order to avoid interception of the class file, it must exist in the second middleware layer and the first physical layer.

デクリプタローダは第3層のJava(登録商標)層に平文クラスファイルや復号鍵などを渡さないように構成している。第2層のミドルウェア層では処理中にヒープメモリのダンプが行われクラスファイルが傍受されてしまう危険性がある。傍受されないために、インタプリタ103等のほかのモジュールとのインタラクションを避け、ソフトウェア難読化技術を適用することが望ましい。また、ソフトウェア難読化技術の適用以外にCPUがセキュアな実行モードを提供するものもある。セキュアな実行モードで実行されるソフトウェアは他のソフトよりヒープメモリを傍受されることが困難になるため、CPUがその機能を提供する場合はデクリプタローダはセキュアな実行モードで実行されることが望ましい。   The decrypter loader is configured not to pass a plaintext class file, a decryption key, or the like to the third Java (registered trademark) layer. In the middleware layer of the second layer, there is a risk that the heap memory is dumped during processing and the class file is intercepted. In order not to be intercepted, it is desirable to avoid software interaction with other modules such as the interpreter 103 and apply software obfuscation techniques. In addition to the application of software obfuscation technology, the CPU provides a secure execution mode. Software that runs in secure execution mode is more difficult to intercept the heap memory than other software, so if the CPU provides that functionality, the decrypter loader may run in secure execution mode. desirable.

平文クラスファイルのロードを行うためのAPI呼び出しdefineClass(クラス名、平文クラスファイル)はローダ105より処理される。図8を参照して、ローダ105が平文クラスファイルよりクラスオブジェクトを生成する制御フローを説明する。   An API call defineClass (class name, plaintext class file) for loading a plaintext class file is processed by the loader 105. A control flow in which the loader 105 generates a class object from the plaintext class file will be described with reference to FIG.

まずローダ105はクラスファイルのベリファイを行いクラスファイルが改竄されていないかなどをチェックする(S801)。   First, the loader 105 verifies the class file and checks whether the class file has been tampered with (S801).

ローダ105はベリファイを行った後、平文のクラスファイルをクラスオブジェクトに変換する(S802)。クラスオブジェクトはJava(登録商標)バーチャルマシーンに依存した構造体という形でヒープメモリ104に格納されるので、ヒープメモリ104上の情報が傍受されてもクラスオブジェクトをクラスファイルに復元することが困難である。   After verifying, the loader 105 converts the plain text class file into a class object (S802). Since the class object is stored in the heap memory 104 in the form of a structure depending on the Java (registered trademark) virtual machine, it is difficult to restore the class object to the class file even if information on the heap memory 104 is intercepted. is there.

ローダ105とデクリプタローダ602はクラスオブジェクトの生成に共通点が多く存在するがローダが生成するクラスオブジェクトは著作権保護の配慮を行う必要が特にないため、実装の高速化を計るためのチューニングが可能になる。   The loader 105 and the decrypter loader 602 have a lot in common with the generation of class objects. However, since the class objects generated by the loader do not need to pay attention to copyright protection, tuning for speeding up the implementation is not necessary. It becomes possible.

または、デクリプタローダ602により暗号化されたクラスファイルを平文のクラスファイルへと変換した後の処理は、ローダ105による処理と同じ処理を行うため、デクリプタローダにおいて、平文のクラスファイルをクラスオブジェクトへと変換しヒープメモリへ格納する処理についてはローダ105を使用するような構成としても良い。   Alternatively, since the process after the class file encrypted by the decrypter loader 602 is converted to a plain text class file is the same as the process by the loader 105, the plain text class file is converted into a class object in the decrypter loader. The loader 105 may be used for the process of converting into the heap memory and storing it in the heap memory.

これは例えば、ローダ105とデクリプタローダ602による処理の一部が共通のライブラリを共有することなどにより実現が可能となる。   This can be realized, for example, by sharing a common library by a part of processing by the loader 105 and the decrypter loader 602.

図9は再生装置で再生されるBD−ROMのマスタリングを行うマスタリング装置の大まかな機能構成を示すブロック図である。図9に示すように、マスタリング装置は、クラスファイル取得モジュール1101、暗号化判定部1102、鍵生成部1103、クラスファイルエンクリプタ1104、アーカイバ1105、マスター鍵取得モジュール1106、復号鍵エンクリプタ1107、BD−ROMバーナー1108から構成される。   FIG. 9 is a block diagram showing a rough functional configuration of a mastering apparatus that performs mastering of a BD-ROM reproduced by the reproducing apparatus. As shown in FIG. 9, the mastering device includes a class file acquisition module 1101, an encryption determination unit 1102, a key generation unit 1103, a class file encryptor 1104, an archiver 1105, a master key acquisition module 1106, a decryption key encryptor 1107, and a BD- It consists of a ROM burner 1108.

クラスファイル取得モジュール1101は処理対象のJava(登録商標)アプリケーションを構成するクラスファイルを順次取得する。   A class file acquisition module 1101 sequentially acquires class files that constitute a Java (registered trademark) application to be processed.

暗号化判定部1102はクラスファイル取得モジュール1101より取得されたクラスファイルの暗号化の必要性を判断する。暗号化の必要性はクラスファイルの属性情報を用いたり、暗号化を行う前にユーザに問い合わせることで、暗号化の有無の判断を実現することが可能である。   The encryption determination unit 1102 determines the necessity of encryption of the class file acquired from the class file acquisition module 1101. The necessity of encryption can be determined by using the attribute information of the class file or by making an inquiry to the user before performing encryption.

鍵生成部1103は復号鍵および暗号鍵を生成する。再生装置での復号化を高速化するためにAES(Advanced Encryption Standard)やDES(Data Encryption Standard)のような対称鍵暗号を利用することが望ましい。対称鍵暗号を利用する場合は暗号鍵と復号鍵が同じであるため、これらを秘匿としておく機構(図示せず)を設けるのが望ましい。   The key generation unit 1103 generates a decryption key and an encryption key. It is desirable to use a symmetric key encryption such as AES (Advanced Encryption Standard) or DES (Data Encryption Standard) in order to speed up the decryption in the playback device. When using symmetric key encryption, since the encryption key and the decryption key are the same, it is desirable to provide a mechanism (not shown) for keeping them secret.

クラスファイルエンクリプタ1104は暗号化判定部1102より暗号化する必要があると判断されたクラスファイルを、鍵生成部1103より生成された暗号鍵で暗号化する。   The class file encryptor 1104 encrypts the class file determined to be encrypted by the encryption determination unit 1102 with the encryption key generated by the key generation unit 1103.

アーカイバ1105はクラスファイルを一つのJarファイルに格納する。暗号化の必要がないクラスファイルを拡張子「class」で格納し、クラスファイルエンクリプタ1104より得られた暗号化クラスファイルを拡張子「secure」で格納する。   The archiver 1105 stores the class file in one Jar file. A class file that does not need to be encrypted is stored with an extension “class”, and an encrypted class file obtained from the class file encryptor 1104 is stored with an extension “secure”.

マスター鍵取得モジュール1106は再生装置のマスター鍵を内部で保持し、復号鍵エンクリプタ1107に渡す。   The master key acquisition module 1106 internally holds the master key of the playback device and passes it to the decryption key encryptor 1107.

復号鍵エンクリプタ1107は復号鍵をマスター鍵で暗号化する。復号鍵はマスター鍵で暗号化されるため、このプロセスより作成されたBD−ROMはマスター鍵がなければ復号化は極めて困難となる。   The decryption key encryptor 1107 encrypts the decryption key with the master key. Since the decryption key is encrypted with the master key, the BD-ROM created by this process is extremely difficult to decrypt without the master key.

BD−ROMバーナー1108はJarファイルおよび暗号化された復号鍵を一つのBD−ROMに焼き付ける。   The BD-ROM burner 1108 burns the Jar file and the encrypted decryption key onto one BD-ROM.

マスタリング装置より作成された光ディスクは図1に示す構成を持つ。マスター鍵がなければJarファイルの中の暗号化クラスファイルを復号化するためにはクラスファイルエンクリプタ1104にて用いた暗号化アルゴリズムを破る必要が有り、リバースエンジニアリング技術での解析が不可能と見なせる。   An optical disc created from the mastering apparatus has the configuration shown in FIG. Without the master key, it is necessary to break the encryption algorithm used in the class file encryptor 1104 in order to decrypt the encrypted class file in the Jar file, which can be regarded as impossible to analyze with the reverse engineering technique. .

(実施の形態2)
本実施の形態は、マニフェストファイルに復号鍵の情報を格納するようにし、格納した復号鍵に関する情報に基づき記録媒体から復号鍵を取得し、デクリプタローダは取得した復号鍵を用いて暗号化されたクラスファイルを復号するように構成したことを特徴とする。
(Embodiment 2)
In this embodiment, the decryption key information is stored in the manifest file, the decryption key is obtained from the recording medium based on the stored decryption key information, and the decryptor loader is encrypted using the obtained decryption key. The class file is configured to be decrypted.

実施の形態1にて、説明した事項と同一もしくは同一とみなせる事項については説明を簡潔にするため、本実施の形態では詳しい説明を省略する。   In the first embodiment, in order to simplify the description of items that can be regarded as the same as or the same as the items described in Embodiment 1, detailed description thereof is omitted in this embodiment.

本実施の形態にて用いる記録媒体の一例であるBD−ROMは図1にて説明をしたとおりである。   A BD-ROM which is an example of a recording medium used in this embodiment is as described with reference to FIG.

BDDATAディレクトリの下には、次の2種類のファイルが記録されている。   The following two types of files are recorded under the BDDATA directory.

(1) XXX.JAR(「XXX」は可変、拡張子「JAR」は固定)
Jarファイル仕様に準拠したJava(登録商標)アーカイブファイルである(以下Jarファイルと称する)。Jarファイルは複数のファイルをディレクトリ構造の形で格納している。一つのJarファイルは一つ以上のクラスファイル、Jarファイルの属性を示すメタファイル、画像などのデータが格納されている。基本的に一つのJarファイルに一つのJava(登録商標)アプリケーションが格納されており、Java(登録商標)アプリケーションはJava(登録商標)バーチャルマシーン上で実行することができる。Java(登録商標)アプリケーションは一つ以上のクラスファイルより構成されるが、Java(登録商標)アプリケーションの著作権保護を行う必要がある場合、一つ以上のクラスファイルが暗号化される。暗号化されていないクラスファイルは拡張子「class」を利用する。また、暗号化されているクラスファイルは拡張子「secure」を利用する。暗号化されているクラスファイルは、復号鍵(後述)がなければリバースエンジニアリングを利用しJava(登録商標)アプリケーションを復元することが不可能である。
(1) XXX. JAR ("XXX" is variable, extension "JAR" is fixed)
It is a Java (registered trademark) archive file conforming to the Jar file specification (hereinafter referred to as a Jar file). A Jar file stores a plurality of files in a directory structure. One Jar file stores data such as one or more class files, a metafile indicating attributes of the Jar file, and an image. Basically, one Java (registered trademark) application is stored in one Jar file, and the Java (registered trademark) application can be executed on the Java (registered trademark) virtual machine. A Java (registered trademark) application is composed of one or more class files. When it is necessary to protect the copyright of a Java (registered trademark) application, one or more class files are encrypted. An unencrypted class file uses the extension “class”. The encrypted class file uses the extension “secure”. An encrypted class file cannot restore a Java (registered trademark) application using reverse engineering without a decryption key (described later).

(2) XXX.KEY(「XXX」は可変、拡張子「KEY」は固定)
クラスファイルの復号化に必要な一つ以上の復号鍵の暗号化形式である。複数の復号鍵が同じファイルに存在することが可能。ファイル全体がタイトル鍵で暗号化されており、再生装置で復号化できるようになっている。再生装置はCopy Protection for Recordable Media(CPRM)を利用し、再生装置が持っているデバイス鍵を元に光ディスクのタイトル鍵を取得することができる。
(2) XXX. KEY ("XXX" is variable, extension "KEY" is fixed)
This is an encryption format for one or more decryption keys necessary for decrypting class files. Multiple decryption keys can exist in the same file. The entire file is encrypted with the title key and can be decrypted by the playback device. The playback apparatus can use Copy Protection for Recordable Media (CPRM) to acquire the title key of the optical disc based on the device key possessed by the playback apparatus.

図10は図2に示すマニフェストファイル405の内容の一例である。マニフェストファイル405に情報を記載する文法に関してはJarファイル仕様の中で公開されている。本実施の形態では通常のマニフェストファイルにキー「Key−ID」を追加することを特徴とする。キー「Key−ID」はファイルの復号化に利用する復号鍵のIDを示す。   FIG. 10 shows an example of the contents of the manifest file 405 shown in FIG. The grammar for describing information in the manifest file 405 is disclosed in the Jar file specification. The present embodiment is characterized in that a key “Key-ID” is added to a normal manifest file. The key “Key-ID” indicates the ID of the decryption key used for decrypting the file.

キー「Key−ID」を複数指定することにより、異なる暗号化されたクラスファイルを復号するために異なる復号鍵を用いて復号することが可能となり、複数の復号鍵が存在した場合一つ目の鍵を0番、二つ目の鍵を1番、と順番によりIDを設定する。マニフェストファイルでは復号化に必要な復号鍵のIDを指定する。マニフェストファイルのメインセッションにデフォルトの鍵IDを設定し、個別セッションに個別のファイルの鍵IDを設定する。たとえば、図10の例ではデフォルトの鍵は0番の鍵IDに対応する復号鍵を用い、「Protected.secure」ファイルの復号に用いる復号鍵は1番の鍵IDに対応する復号鍵を用いることを示すものである。   By specifying a plurality of keys “Key-ID”, it is possible to decrypt using different decryption keys to decrypt different encrypted class files. The ID is set according to the order of 0 for the key and 1 for the second key. In the manifest file, the ID of the decryption key necessary for decryption is designated. The default key ID is set for the main session of the manifest file, and the key ID of the individual file is set for the individual session. For example, in the example of FIG. 10, the default key uses the decryption key corresponding to the key number 0, and the decryption key used for decrypting the “Protected.secure” file uses the decryption key corresponding to the key number 1. Is shown.

再生制御のレイヤモデルは図3に示したとおりである。図3の第1層は、物理層であり、処理対象たるJarファイルの供給制御である。この第1層に示すように、処理対象たるJarファイルは、BD−ROMだけではなく、HD、メモリカード、ネットワークといったあらゆる記録媒体、通信媒体を供給源としている。これらHD、メモリカード、ネットワークといった供給源に対する制御(ディスクアクセス、カードアクセス、ネットワーク通信)が第1層の制御である。   The layer model for playback control is as shown in FIG. The first layer in FIG. 3 is a physical layer and is supply control of a Jar file to be processed. As shown in the first layer, the Jar file to be processed uses not only the BD-ROM but also any recording medium such as HD, memory card, network, and communication medium as the supply source. The control of the supply sources such as HD, memory card, network (disk access, card access, network communication) is the first layer control.

第2層は、ミドルウェアのレイアである。第1層で供給されたJarファイルを、どのように実行するのかを規定しているのがこの第2層である。たとえばオペレーティングシステムやJava(登録商標)バーチャルマシーンやCPUに依存したネイティブライブラリや実行ファイルなどがミドルウェア層に存在する。   The second layer is a middleware layer. It is this second layer that defines how to execute the Jar file supplied in the first layer. For example, an operating system, a Java (registered trademark) virtual machine, a CPU-dependent native library, an execution file, and the like exist in the middleware layer.

第3層は、Java(登録商標)のレイアである。Java(登録商標)バーチャルマシーン上で実行されるJava(登録商標)アプリケーションおよびクラスライブラリは第3層に存在する。Java(登録商標)アプリケーションはユーザ入力に基づき処理を行いオーディオやビデオの出力を行う。クラスライブラリはJava(登録商標)アプリケーションに対してJava(登録商標)のプロファイルで定義されているアプリケーションプログラミングインターフェース(API)を提供する。Java(登録商標)アプリケーションおよびクラスライブラリはJava(登録商標)の中間コードで書かれていて、第2層のJava(登録商標)バーチャルマシーンにより解釈実行される。Java(登録商標)アプリケーションは複数のクラスファイルにより構成されるが解釈実行されるためにクラスファイルがクラスオブジェクトに変換される必要がある。クラスオブジェクトはクラスファイルの内部表現とも言える。   The third layer is a Java (registered trademark) layer. Java applications and class libraries that run on Java virtual machines exist in the third layer. The Java (registered trademark) application performs processing based on user input and outputs audio and video. The class library provides an application programming interface (API) defined by a Java (registered trademark) profile for a Java (registered trademark) application. Java (registered trademark) applications and class libraries are written in Java (registered trademark) intermediate code, and are interpreted and executed by the Java (registered trademark) virtual machine in the second layer. A Java (registered trademark) application is composed of a plurality of class files, but needs to be converted into class objects in order to be interpreted and executed. A class object is also an internal representation of a class file.

本実施の形態の再生装置の構成は図4に示すとおりである。図4に示すように、再生装置は、BD−ROMドライブ601、ヒープメモリ104、インタプリタ103、デクリプタローダ602、ローダ105、UO検知モジュール603、出力エンジン604から構成される。   The configuration of the playback apparatus of the present embodiment is as shown in FIG. As shown in FIG. 4, the playback device includes a BD-ROM drive 601, a heap memory 104, an interpreter 103, a decrypter loader 602, a loader 105, a UO detection module 603, and an output engine 604.

BD−ROMドライブ601は、BD−ROMのローディング/イジェクトを行い、BD−ROMに対するアクセスを実行する。BD−ROMドライブ601の内部でCPRMで定義しているデバイス鍵を持っており、BD−ROMドライブ601はBD−ROMのタイトル鍵を復元することができる。   The BD-ROM drive 601 performs loading / ejecting of the BD-ROM and accesses the BD-ROM. The BD-ROM drive 601 has a device key defined by CPRM, and the BD-ROM drive 601 can restore the title key of the BD-ROM.

ヒープメモリ104は、Jarファイルを格納しJava(登録商標)層に必要なメモリである。ヒープメモリ104にクラスファイルの内部形式であるクラスオブジェクトも格納される。   The heap memory 104 stores Jar files and is necessary for the Java (registered trademark) layer. A class object which is an internal format of the class file is also stored in the heap memory 104.

インタプリタ103はJava(登録商標)バーチャルマシーンの中核であり、クラスオブジェクトの中にあるバイトコードの解釈実行を行う。インタプリタ103はJava(登録商標)アプリケーションの実行速度に直接影響を与える重要な部分である。解釈実行の高速化を図るためにバイトコードをネイティブコードに変換するJITコンパイラを備えたインタプリタやインタプリタの一部をハードウェアで実装される製品も市販されている。また、インタプリタの実装は高速化を考えた実装となっているため著作権保護の観点では解析されやすい点を、設計上考慮する必要がある。   The interpreter 103 is the core of the Java (registered trademark) virtual machine, and interprets and executes byte codes in the class object. The interpreter 103 is an important part that directly affects the execution speed of the Java (registered trademark) application. An interpreter having a JIT compiler that converts byte code into native code in order to speed up interpretation execution and a product in which a part of the interpreter is implemented in hardware are also commercially available. In addition, since the interpreter is implemented in consideration of high speed, it is necessary to consider that it is easy to analyze from the viewpoint of copyright protection.

ローディング判定部(図示せず)はクラスオブジェクトの生成(ロードともいう)の必要性を判定する。ローディング判定部はインタプリタ103上解釈実行される。クラスオブジェクトが必要な場合、インタプリタ103がローディング判定部の解釈実行を行う。解釈実行により、インタプリタがヒープメモリ104上のクラスファイルのロードをデクリプタローダまたはローダに要求する。また、ローディング判定部はクラスオブジェクトのキャッシュを持っている。ローディング判定部はJava(登録商標)層にあるClassLoaderクラスまたはその継承クラスとして実装される。ローディング判定部はJava(登録商標)層にあるClassLoaderクラスまたはその継承クラスとして実装される。尚ローディング判定部は高速化のため、一部ミドルウェア層で実装されることもある。   A loading determination unit (not shown) determines the necessity for generation (also referred to as loading) of class objects. The loading determination unit is interpreted and executed on the interpreter 103. When a class object is necessary, the interpreter 103 interprets and executes the loading determination unit. By executing the interpretation, the interpreter requests the descriptor loader or loader to load the class file on the heap memory 104. The loading determination unit has a cache of class objects. The loading determination unit is implemented as a ClassLoader class in the Java (registered trademark) layer or its inheritance class. The loading determination unit is implemented as a ClassLoader class in the Java (registered trademark) layer or its inheritance class. Note that the loading determination unit may be partially implemented in the middleware layer for speeding up.

デクリプタローダ602はBD−ROMドライブ601より平文形式のタイトル鍵を受け取る。BD−ROMドライブ601がデクリプタローダ602にタイトル鍵を渡すときに、鍵が傍受される可能性があるのでBD−ROMドライブ601がデクリプタローダ602を認証し、お互いの暗号化チャネル(SAC:Secure Authenticated Channel)を開き、開いた暗号化チャネルを通じて平文形式のタイトル鍵を受け取る。このとき、暗号化チャネルの実現には楕円曲線暗号化(ECC:Ellipic Curve Cryptosystem)とDiffie−Hellmanアルゴリズムとを利用することができる。   The decrypter loader 602 receives a plaintext title key from the BD-ROM drive 601. When the BD-ROM drive 601 passes the title key to the decrypter loader 602, the key may be intercepted, so the BD-ROM drive 601 authenticates the decrypter loader 602, and the mutual encryption channel (SAC: Open the Secure Authenticated Channel) and receive the plaintext title key through the open encrypted channel. At this time, elliptic curve encryption (ECC) and Diffie-Hellman algorithm can be used to realize the encrypted channel.

デクリプタローダ602はさらにタイトル鍵で暗号化された復号鍵をBD−ROMを読み込んだBD−ROMドライブ601より受け取る。暗号化された復号鍵を先に受け取ったタイトル鍵にて復号した後、この復号鍵を用いて、暗号化クラスファイルを復号することができる。暗号化クラスファイルを平文のクラスファイルへ復号した後、ヒープメモリ104上にクラスオブジェクトを生成する。   The decrypter loader 602 further receives the decryption key encrypted with the title key from the BD-ROM drive 601 that has read the BD-ROM. After decrypting the encrypted decryption key with the previously received title key, the encryption class file can be decrypted using this decryption key. After decrypting the encrypted class file into a plain text class file, a class object is generated on the heap memory 104.

デクリプタローダ602は著作権保護を行う上で重要な部分である。デクリプタローダ602内にあるSACで利用される暗号鍵、タイトル鍵、復号鍵などが第3者より傍受されてしまうとシステム全体として著作権保護ができなくなる。また、内部に一時的に保持する平文クラスファイルが傍受されてしまう危険性があり、実装にセキュリティの配慮が必要である。   The decrypter loader 602 is an important part for copyright protection. If an encryption key, title key, decryption key, etc. used by the SAC in the decrypter loader 602 are intercepted by a third party, the copyright protection as a whole system cannot be performed. In addition, there is a risk that a plain text class file temporarily stored inside may be intercepted, and security considerations are required for implementation.

ローダ105は平文クラスファイルを対応するクラスオブジェクトに変換し、ヒープメモリ104上へ配置する。ヒープメモリ104上に配置されたクラスオブジェクトはインタプリタ103より解釈実行が可能である。   The loader 105 converts the plain text class file into a corresponding class object and arranges it on the heap memory 104. The class object placed on the heap memory 104 can be interpreted and executed by the interpreter 103.

UO検知モジュール603は、リモコン(図示せず)や再生装置のフロントパネルなどの入力手段(図示せず)に対してなされたユーザ操作を検知して、検知した入力があったことをJava(登録商標)バーチャルマシーンへ通知する。   The UO detection module 603 detects a user operation performed on an input unit (not shown) such as a remote controller (not shown) or a front panel of a playback apparatus, and indicates that the detected input has been received by Java (registered). (Trademark) Notify the virtual machine.

出力エンジン604はJava(登録商標)バーチャルマシーンにより解釈実行された結果、要求されるオーディオやビデオの出力を行う。   The output engine 604 outputs required audio and video as a result of interpretation and execution by a Java (registered trademark) virtual machine.

インタプリタ103による解釈実行を行う中、クラスオブジェクトを必要とした場合、インタプリタがローディング判定部の解釈実行を行う。要求はClassLoaderクラスが持つメソッドloadClass(クラス名)の呼び出しより開始される。   If interpretation is performed by the interpreter 103 and a class object is required, the interpreter performs interpretation by the loading determination unit. The request is started by calling a method loadClass (class name) possessed by the ClassLoader class.

ローディング判定部とJava(登録商標)バーチャルマシーンとのインターフェースは、図5に示すとおりである。但し、ローディング判定部はロードすべきクラスファイルが暗号化されていると判断した場合、API呼び出しdefineEncryptedClass(クラス名、暗号化クラスファイル、鍵ID)を行い、引数としてクラス名、暗号化クラスファイル、鍵IDを指定して暗号化クラスファイルのロードをミドルウェア層のデクリプタローダ602に依頼する。   The interface between the loading determination unit and the Java (registered trademark) virtual machine is as shown in FIG. However, if the loading determination unit determines that the class file to be loaded is encrypted, it performs an API call defineEncryptedClass (class name, encrypted class file, key ID), and the class name, encrypted class file, The middleware layer decryptor loader 602 is requested to load the encryption class file by designating the key ID.

また、ローディング判定部はロードすべきクラスファイルが暗号化されていないと判断した場合、API呼び出しdefineClass(クラス名、平文クラスファイル)を行い、引数としてクラス名、クラスファイルを指定し、クラスファイルのロードをミドルウェア層のローダ105に依頼する。ローディング判定部は解釈実行されるため、これらの依頼はインタプリタ103を通して行われる。   If the loading determination unit determines that the class file to be loaded is not encrypted, it performs an API call defineClass (class name, plain text class file), specifies the class name and class file as arguments, and The load is requested to the loader 105 of the middleware layer. Since the loading determination unit is interpreted and executed, these requests are made through the interpreter 103.

Java(登録商標)層で実行されるローディング判定部がクラスオブジェクトを返す制御フローは基本的には図6に示すものに同じである。   The control flow in which the loading determination unit executed in the Java (registered trademark) layer returns the class object is basically the same as that shown in FIG.

但し、S605による判定の結果、ローディング判定部はクラスファイルが暗号化されていると判断した場合、暗号化クラスファイルのロードを依頼する(S606)場合、暗号化クラスファイルのロードはAPIであるdefineEncryptedClassを呼び出すことにより行われるが、この場合引数としてクラス名、暗号化クラスファイル、鍵IDを指定する必要がある点が実施の形態1に説明したものとは異なる(つまり、defineEncryptedClass(クラス名、暗号化クラスファイル、鍵ID)として、APIであるdefineEncryptedClassを呼び出す)。より行われる。   However, if the loading determination unit determines that the class file is encrypted as a result of the determination in S605, and requests the loading of the encrypted class file (S606), the load of the encrypted class file is definedEncryptedClass, which is an API. Is different from that described in the first embodiment in that it is necessary to specify a class name, an encrypted class file, and a key ID as arguments (that is, defineEncryptedClass (class name, encryption API class, defineEncryptedClass, is called as the conversion class file and key ID). More done.

ここで、クラス名は再生すべきクラスオブジェクトの名前である。暗号化クラスファイルはJarファイルより取得されたファイルである。鍵IDは図10に示すメタファイルより得られたクラス名に対応する鍵IDである。暗号化クラスファイルのロードによりヒープメモリ104上の一つのクラスオブジェクトを取得する。   Here, the class name is the name of the class object to be reproduced. The encryption class file is a file acquired from the Jar file. The key ID is a key ID corresponding to the class name obtained from the metafile shown in FIG. One class object on the heap memory 104 is acquired by loading the encrypted class file.

暗号化クラスファイルのロードを行うためのAPI呼び出しdefineEncryptedClass(クラス名、暗号化クラスファイル、鍵ID)はデクリプタローダ602より処理される。デクリプタローダ602が暗号化クラスファイルよりヒープメモリ104上にクラスオブジェクトを生成する制御フローは基本的には図7に示すものに同じである。   The API call defineEncryptedClass (class name, encrypted class file, key ID) for loading the encrypted class file is processed by the decrypter loader 602. The control flow in which the decrypter loader 602 generates a class object on the heap memory 104 from the encrypted class file is basically the same as that shown in FIG.

但し、本実施の形態においては、複数の復号鍵をマニフェストファイルにて指定できるようにしたので、S701において、デクリプタローダ602は引数にて指定される鍵IDに相当する復号鍵を用いて受け取った暗号化されたクラスファイルを平文のクラスファイルに復号する。   However, in this embodiment, since a plurality of decryption keys can be specified by the manifest file, the decrypter loader 602 receives the decryption key corresponding to the key ID specified by the argument in S701. Decrypt encrypted class file into plain text class file.

たとえば鍵IDが0の場合、一つ目の復号鍵を利用する。鍵IDが1の場合、二つ目の復号鍵を利用する。   For example, when the key ID is 0, the first decryption key is used. When the key ID is 1, the second decryption key is used.

S702、S703については実施の形態1の説明と重複するためここでは、詳しい説明を省略する。   Since S702 and S703 overlap with the description of the first embodiment, a detailed description thereof is omitted here.

デクリプタローダ602は著作権保護対象のクラスファイルを一時的に内部で保持している間はクラスファイルの傍受を避ける。クラスファイルの傍受を避けるために第2層や第1層の物理層に存在しなければならない。デクリプタローダは第3層のJava(登録商標)層に平文クラスファイルや復号鍵などを渡してはならない。第2層のミドルウェア層では処理中にメモリのダンプが行われクラスファイルが傍受されてしまう危険性がある。傍受されないために、インタプリタ103等のほかのモジュールとのインタラクションを避け、なんらかのソフトウェア難読化技術を適用することが望ましい。また、ソフトウェア難読化技術の適応以外にCPUがセキュアな実行モードを提供するものもある。セキュアな実行モードで実行されるソフトウェアは他のソフトよりメモリを傍受されることが困難になるため、CPUがその機能を提供する場合はデクリプタローダはセキュアな実行モードで実行されることが望ましい。   The decrypter loader 602 avoids intercepting the class file while temporarily holding the class file subject to copyright protection. In order to avoid interception of class files, it must exist in the physical layer of the second layer or the first layer. The decryptor loader must not pass a plain text class file, a decryption key, or the like to the third Java layer. In the middleware layer of the second layer, there is a risk that a memory file is dumped during processing and the class file is intercepted. In order not to be intercepted, it is desirable to avoid some interaction with other modules such as the interpreter 103 and apply some software obfuscation technique. In addition to the application of software obfuscation technology, the CPU provides a secure execution mode. Since software executed in the secure execution mode is more difficult to intercept the memory than other software, it is desirable that the decrypter loader is executed in the secure execution mode when the CPU provides the function. .

平文クラスファイルのロードを行うためのAPI呼び出しdefineClass(クラス名、平文クラスファイル)はローダ105より処理される。その具体的な説明は実施の形態1にて説明したので、ここではその詳細な説明を省略する。   An API call defineClass (class name, plaintext class file) for loading a plaintext class file is processed by the loader 105. Since the specific description thereof has been described in Embodiment 1, the detailed description thereof is omitted here.

ローダ105とデクリプタローダ602はクラスオブジェクトの生成に共通点が多く存在するがローダが生成するクラスオブジェクトは著作権保護の配慮を行う必要が特にないため、実装の高速化を計るためのチューニングが可能になる。ただし開発コストを考えた場合、実装上ローダ105とデクリプタローダ602が共通のライブラリを共有することが考えられる。   The loader 105 and the decrypter loader 602 have a lot in common with the generation of class objects. However, since the class objects generated by the loader do not need to pay attention to copyright protection, tuning for speeding up the implementation is not necessary. It becomes possible. However, when considering the development cost, it is conceivable that the loader 105 and the decrypter loader 602 share a common library in terms of mounting.

図11は再生装置で再生されるBD−ROMのマスタリングを行うマスタリング装置の構成の一例を示す図である。   FIG. 11 is a diagram illustrating an example of a configuration of a mastering device that performs mastering of a BD-ROM played back by a playback device.

図11に示すように、マスタリング装置は、クラスファイル取得モジュール1101、暗号化判定部1102、鍵生成部1103、クラスファイルエンクリプタ1104、アーカイバ1105、CPRMモジュール1301、復号鍵エンクリプタ1107、BD−ROMバーナー1108から構成される。   As shown in FIG. 11, the mastering device includes a class file acquisition module 1101, an encryption determination unit 1102, a key generation unit 1103, a class file encryptor 1104, an archiver 1105, a CPRM module 1301, a decryption key encryptor 1107, and a BD-ROM burner. 1108.

クラスファイル取得モジュール1101は処理対象のJava(登録商標)アプリケーションを構成するクラスファイルを順次取得する。   A class file acquisition module 1101 sequentially acquires class files that constitute a Java (registered trademark) application to be processed.

暗号化判定部1102はクラスファイル取得モジュール1101より取得されたクラスファイルの暗号化の必要性を判断する。暗号化の必要性はクラスファイルの属性情報を用いたり、暗号化を行う前にユーザに問い合わせることで実現することが可能である。   The encryption determination unit 1102 determines the necessity of encryption of the class file acquired from the class file acquisition module 1101. The necessity of encryption can be realized by using attribute information of a class file or by inquiring a user before performing encryption.

鍵生成部1103は復号鍵および暗号鍵を生成する。対称暗号化を利用するため暗号鍵と復号鍵が同じである。   The key generation unit 1103 generates a decryption key and an encryption key. Since symmetric encryption is used, the encryption key and the decryption key are the same.

クラスファイルエンクリプタ1104は暗号化判定部1102より暗号化する必要があると判断されたクラスファイルを、鍵生成部1103より生成された暗号鍵で暗号化する。暗号鍵には鍵IDがついており、クラスファイルエンクリプタ1104は利用した鍵のIDを記憶する。   The class file encryptor 1104 encrypts the class file determined to be encrypted by the encryption determination unit 1102 with the encryption key generated by the key generation unit 1103. The encryption key has a key ID, and the class file encryptor 1104 stores the ID of the key used.

アーカイバ1105はクラスファイルを一つのJarファイルに格納する。暗号化の必要がないクラスファイルを拡張子「class」で格納し、クラスファイルエンクリプタ1104より得られた暗号化クラスファイルを拡張子「secure」で格納する。   The archiver 1105 stores the class file in one Jar file. A class file that does not need to be encrypted is stored with an extension “class”, and an encrypted class file obtained from the class file encryptor 1104 is stored with an extension “secure”.

また、暗号に用いた暗号鍵の鍵IDの情報をクラスファイルエンクリプタ1104より受け取り、その情報をメタファイルに格納する。メタファイルはJarファイルのMETA−INFディレクトリにあるMANIFEST.MFファイルである。   Also, the key ID information of the encryption key used for encryption is received from the class file encryptor 1104, and the information is stored in the metafile. The metafile is MANIFEST.NET in the META-INF directory of the Jar file. It is an MF file.

CPRMモジュール1301はCPRMに必要な鍵生成および情報保持を行う。CPRMモジュール1301はタイトル鍵を復号鍵エンクリプタ1107に渡す。また、CPRMの仕様で定められている情報をBD−ROMバーナー1108に渡す。CPRMの仕様は、例えば「http://www.4centity.com/tech/cprm/」より入手することができる。   The CPRM module 1301 performs key generation and information holding necessary for CPRM. The CPRM module 1301 passes the title key to the decryption key encryptor 1107. In addition, information defined in the CPRM specification is passed to the BD-ROM burner 1108. The specification of CPRM can be obtained from, for example, “http://www.4centity.com/tech/cprm/”.

復号鍵エンクリプタ1107は必要な復号鍵をタイトル鍵で暗号化する。鍵ID=0の復号鍵より順番に連結した上でタイトル鍵で暗号化を行い復号鍵ファイルを生成する。   The decryption key encryptor 1107 encrypts the necessary decryption key with the title key. The decryption key file is generated by concatenating with the title key after sequentially concatenating the decryption keys with the key ID = 0.

BD−ROMバーナー1108はJarファイルと復号鍵ファイルとCPRM用情報を一つのBD−ROMに焼き付ける。   The BD-ROM burner 1108 burns the Jar file, the decryption key file, and CPRM information on one BD-ROM.

マスタリング装置より作成された光ディスクは図3に示す構成を持つ。Jarファイルの中の暗号化クラスファイルは、リバースエンジニアリングを利用しての解析が不可能である。CPRMが定めるデバイス鍵がなければタイトル鍵を取得することができないため、Jarファイルの中の暗号化クラスファイルを復号化するためには復号鍵を用いることなく暗号化されたクラスファイルを復号する必要が有り、きわめて困難である。   An optical disc created from the mastering apparatus has the configuration shown in FIG. The encryption class file in the Jar file cannot be analyzed using reverse engineering. Since the title key cannot be obtained without the device key defined by CPRM, it is necessary to decrypt the encrypted class file without using the decryption key in order to decrypt the encrypted class file in the Jar file. It is extremely difficult.

本発明は光ディスクやSDカードといった記録媒体またはインターネットといった通信媒体を介して受け取ったJava(登録商標)アプリケーションの著作権保護に利用できる。   The present invention can be used for copyright protection of a Java (registered trademark) application received via a recording medium such as an optical disk or an SD card or a communication medium such as the Internet.

本発明の実施の形態におけるBD−ROMのデータ階層の一例を示す図The figure which shows an example of the data hierarchy of BD-ROM in embodiment of this invention 本実施の形態におけるJarファイルのファイル構造の一例を示す図The figure which shows an example of the file structure of the Jar file in this Embodiment 本実施の形態におけるソフトウェアのレイヤの一例を示す図The figure which shows an example of the layer of the software in this Embodiment 本発明の実施の形態における再生装置の構成の一例を示す図The figure which shows an example of a structure of the reproducing | regenerating apparatus in embodiment of this invention 本実施の形態におけるローディング判定部とデクリプタローダとローダとの間のインターフェースの一例を示す図The figure which shows an example of the interface between the loading determination part in this Embodiment, a decryptor loader, and a loader 本実施の形態におけるローディング判定部の処理の一例を示す図The figure which shows an example of the process of the loading determination part in this Embodiment. 本実施の形態におけるデクリプタローダがクラスオブジェクトを生成する処理の一例を示す図The figure which shows an example of the process in which the decrypter loader in this Embodiment produces | generates a class object 本実施の形態におけるローダがクラスオブジェクトを生成する処理の一例を示す図The figure which shows an example of the process in which the loader in this Embodiment produces | generates a class object 本実施の形態におけるマスタリング装置の構成の一例を示す図The figure which shows an example of a structure of the mastering apparatus in this Embodiment 本実施の形態におけるメタファイルの中身の一例を示す図The figure which shows an example of the content of the metafile in this Embodiment 本発明の二つ目の実施の形態におけるマスタリング装置の構成の一例を示す図The figure which shows an example of a structure of the mastering apparatus in 2nd embodiment of this invention. 従来のJava(登録商標)アプリケーションの著作権保護を行う再生装置の構成の一例を示す図1 is a diagram illustrating an example of a configuration of a playback device that performs copyright protection of a conventional Java (registered trademark) application. 暗号化クラスファイルからクラスオブジェクトに変更される処理の一例を示す図Diagram showing an example of processing to change from an encrypted class file to a class object

符号の説明Explanation of symbols

101 仮想マシン
102 Java(登録商標)アプリケーション
103 インタプリタ
104 ヒープメモリ
105 ローダ
107 復号クラスローダ
108 保護対象クラスファイル
109 復号鍵
401 ルートディレクトリ
402 META−INFディレクトリ
403 暗号化されていないクラスファイル
404 暗号化されたクラスファイル
405 マニフェストファイル
601 BD−ROMドライブ
602 デクリプタローダ
603 UO検知モジュール
604 出力エンジン
1101 クラスファイル取得モジュール
1102 暗号化判定部
1103 鍵生成部
1104 クラスファイルエンクリプタ
1105 アーカイバ
1106 マスター鍵取得モジュール
1107 復号鍵エンクリプタ
1108 BD−ROMバーナー
1301 CPRMモジュール
DESCRIPTION OF SYMBOLS 101 Virtual machine 102 Java (registered trademark) application 103 Interpreter 104 Heap memory 105 Loader 107 Decryption class loader 108 Protected class file 109 Decryption key 401 Root directory 402 META-INF directory 403 Unencrypted class file 404 Encrypted Class file 405 Manifest file 601 BD-ROM drive 602 Decryptor loader 603 UO detection module 604 Output engine 1101 Class file acquisition module 1102 Encryption determination unit 1103 Key generation unit 1104 Class file encryptor 1105 Archiver 1106 Master key acquisition module 1107 Decryption key Encrypter 1108 BD-ROM burner 1301 C RM module

Claims (10)

オブジェクト指向型のプログラムで記述されたアプリケーションの実行を行うアプリケーション実行装置であって、
入力される前記アプリケーションに含まれる暗号化クラスファイルを復号し平文のクラスファイルとした後、クラスオブジェクトに変換してヒープメモリへロードするデクリプタローダ、入力される前記アプリケーション内の平文クラスファイルをクラスオブジェクトに変換して前記ヒープメモリへロードするローダおよび前記ヒープメモリへロードされたクラスオブジェクトを解釈実行するインタプリタを有する仮想マシンと、
前記インタプリタにて実行すべきクラスファイルが暗号化されたクラスファイルまたは平文クラスファイルかを判定するローディング判定部とを備え、
前記ローディング判定部において、前記インタプリタにて実行すべきクラスファイルが暗号化されたクラスファイルであると判定された場合には前記クラスファイルを前記デクリプタローダへ送り、
前記ローディング判定部において前記仮想マシンへ送られるクラスファイルが平文クラスファイルであると判定された場合には前記クラスファイルを前記ローダへ送るように構成したことを特徴とするアプリケーション実行装置。
An application execution device that executes an application described in an object-oriented program,
A decryptor loader that decrypts the encrypted class file included in the input application and converts it into a plain text class file, then converts it into a class object and loads it into the heap memory, and classifies the plain text class file in the input application A virtual machine having a loader that converts into an object and loads it into the heap memory, and an interpreter that interprets and executes the class object loaded into the heap memory;
A loading determination unit that determines whether a class file to be executed by the interpreter is an encrypted class file or a plaintext class file;
In the loading determination unit, when it is determined that the class file to be executed by the interpreter is an encrypted class file, the class file is sent to the decryptor loader,
An application execution apparatus configured to send the class file to the loader when the loading judgment unit judges that the class file sent to the virtual machine is a plain text class file.
前記アプリケーションは記録媒体内に記録され、かつ前記記録媒体は、前記アプリケーションに含まれる暗号化されたクラスファイルを復号するための復号鍵をマスター鍵にて暗号化して記録し、かつ
前記デクリプタローダは前記マスター鍵を予め保持しており、前記暗号化されたクラスファイルが入力されると暗号化されたクラスファイルに対応する暗号化された復号鍵を前記記録媒体から取得し、
前記暗号化された復号鍵を前記予め保持するマスター鍵を用いて復号し、前記復号された復号鍵を用いて前記暗号化されたクラスファイルを復号することを特徴とする請求項1記載のアプリケーション実行装置。
The application is recorded in a recording medium, and the recording medium encrypts and records a decryption key for decrypting an encrypted class file included in the application with a master key, and the decrypter loader Holds the master key in advance, and when the encrypted class file is input, obtains an encrypted decryption key corresponding to the encrypted class file from the recording medium,
2. The application according to claim 1, wherein the encrypted decryption key is decrypted using the master key held in advance, and the encrypted class file is decrypted using the decrypted decryption key. Execution device.
前記デクリプタローダは前記記録媒体から前記暗号化された復号鍵を取得し、暗号化されたクラスファイルが入力される前に前記マスター鍵を用いて前記暗号化された復号鍵を復号し、キャッシュするようにしたことを特徴とする請求項1記載のアプリケーション実行装置。 The decrypter loader obtains the encrypted decryption key from the recording medium, decrypts the encrypted decryption key using the master key before the encrypted class file is input, The application execution apparatus according to claim 1, wherein: 前記アプリケーションは記録媒体内に記録され、かつ前記記録媒体は、前記アプリケーションに含まれる暗号化されたクラスファイルを復号するための復号鍵であってタイトル鍵で暗号化された復号鍵および前記復号鍵を取り出すための情報を記述したメタファイルを記録し、
前記ローディング判定部は前記アプリケーション実行時に前記アプリケーションに含まれる前記暗号化されたクラスファイルに対応する復号鍵を取り出すための情報を記述したメタファイルに基づいて対応する復号鍵を取り出すための情報を前記デクリプタローダへ送り、
前記デクリプタローダは前記復号鍵を取り出すための情報に基づき前記暗号化された復号鍵を前記記録媒体から取得し、
前記デクリプタローダが保持するタイトル鍵を用いて復号した復号鍵を用いて前記暗号化されたクラスファイルを復号することを特徴とする請求項1記載のアプリケーション実行装置。
The application is recorded in a recording medium, and the recording medium is a decryption key for decrypting an encrypted class file included in the application, the decryption key encrypted with a title key and the decryption key Record a metafile that describes the information to retrieve
The loading determination unit includes information for extracting a corresponding decryption key based on a metafile describing information for extracting a decryption key corresponding to the encrypted class file included in the application when the application is executed. To the decryptor loader
The decryptor loader acquires the encrypted decryption key from the recording medium based on information for extracting the decryption key,
The application execution apparatus according to claim 1, wherein the encrypted class file is decrypted using a decryption key decrypted using a title key held by the decryptor loader.
前記デクリプタローダは前記記録媒体から取得した復号鍵を保持するようにしたことを特徴とする請求項4記載のアプリケーション実行装置。 The application execution apparatus according to claim 4, wherein the decrypter loader holds a decryption key acquired from the recording medium. オブジェクト指向型のプログラムで記述されたアプリケーションの実行を行うアプリケーション実行装置であって、
入力される前記アプリケーションに含まれる暗号化されたクラスファイルを復号し、平文クラスファイルをローダへ送るためのデクリプタおよび入力される前記アプリケーション内の平文クラスファイルまたは前記デクリプタにより復号された平文クラスファイルをクラスオブジェクトに変換しヒープメモリへロードするローダおよび前記ヒープメモリへロードされたクラスオブジェクトを解釈実行するインタプリタを有する仮想マシンと、
前記インタプリタにて実行すべきクラスファイルが暗号化されたクラスファイルか平文クラスファイルかを判定するローディング判定部とを備え、
前記ローディング判定部により前記インタプリタにて実行すべきクラスファイルが暗号化されたクラスファイルであると判定された場合、前記暗号化されたクラスファイルを前記デクリプタへ送り、
前記ローディング判定部により前記仮想マシンへ送られるクラスファイルが平文クラスファイルであると判定された場合には前記クラスファイルを前記ローダへ送るように構成したことを特徴とするアプリケーション実行装置。
An application execution device that executes an application described in an object-oriented program,
A decryptor for decrypting the encrypted class file included in the input application and sending the plaintext class file to the loader, and a plaintext class file in the input application or a plaintext class file decrypted by the decryptor A virtual machine having a loader for converting into a class object and loading it into a heap memory and an interpreter for interpreting and executing the class object loaded into the heap memory;
A loading determination unit that determines whether a class file to be executed by the interpreter is an encrypted class file or a plain text class file;
When it is determined by the loading determination unit that the class file to be executed by the interpreter is an encrypted class file, the encrypted class file is sent to the decryptor,
An application execution apparatus configured to send the class file to the loader when the loading judgment unit judges that the class file sent to the virtual machine is a plain text class file.
前記アプリケーションは記録媒体内に記録され、かつ前記記録媒体は、前記アプリケーションに含まれる暗号化されたクラスファイルを復号するための復号鍵をマスター鍵にて暗号化して記録し、
前記デクリプタは前記マスター鍵を予め保持しており、前記暗号化されたクラスファイルが入力されると、前記暗号化されたクラスファイルを復号するための復号鍵を前記記録媒体から取得し、
前記取得した暗号化された復号鍵を前記予め保持するマスター鍵を用いて復号し、前記復号された復号鍵を用いて前記暗号化されたクラスファイルを復号することを特徴とする請求項6記載のアプリケーション実行装置。
The application is recorded in a recording medium, and the recording medium is recorded by encrypting a decryption key for decrypting an encrypted class file included in the application with a master key,
The decryptor holds the master key in advance, and when the encrypted class file is input, obtains a decryption key for decrypting the encrypted class file from the recording medium,
7. The obtained encrypted decryption key is decrypted using the master key held in advance, and the encrypted class file is decrypted using the decrypted decryption key. Application execution device.
前記デクリプタは前記記録媒体から前記暗号化された復号鍵を取得し、前記暗号化されたクラスファイルが入力される前に前記復号鍵をキャッシュするようにしたことを特徴とする請求項7記載のアプリケーション実行装置。 8. The decryptor according to claim 7, wherein the decryptor acquires the encrypted decryption key from the recording medium and caches the decryption key before the encrypted class file is input. Application execution device. 前記アプリケーションは記録媒体内に記録され、かつ前記記録媒体は、前記アプリケーションに含まれる暗号化されたクラスファイルを復号するための復号鍵であってタイトル鍵で暗号化された復号鍵および前記復号鍵を取り出すための情報を記述したメタファイルを記録し、
前記ローディング判定部は前記アプリケーション実行時に前記アプリケーションに含まれる前記暗号化されたクラスファイルに対応する復号鍵を取り出すための情報を記述したメタファイルに基づいて対応する復号鍵を取り出すための情報を前記デクリプタへ送り、
前記デクリプタは前記復号鍵を取り出すための情報に基づき前記暗号化された復号鍵を前記記録媒体から取得し、
前記デクリプタが保持するタイトル鍵を用いて復号した復号鍵を用いて前記暗号化されたクラスファイルを復号することを特徴とする請求項6記載のアプリケーション実行装置。
The application is recorded in a recording medium, and the recording medium is a decryption key for decrypting an encrypted class file included in the application, the decryption key encrypted with a title key and the decryption key Record a metafile that describes the information to retrieve
The loading determination unit includes information for extracting a corresponding decryption key based on a metafile describing information for extracting a decryption key corresponding to the encrypted class file included in the application when the application is executed. To the decryptor
The decryptor obtains the encrypted decryption key from the recording medium based on information for extracting the decryption key,
7. The application execution apparatus according to claim 6, wherein the encrypted class file is decrypted using a decryption key decrypted using a title key held by the decryptor.
前記デクリプタは前記記録媒体から取得した復号鍵を保持するようにしたことを特徴とする請求項9記載のアプリケーション実行装置。 The application execution apparatus according to claim 9, wherein the decryptor holds a decryption key acquired from the recording medium.
JP2006216861A 2006-08-09 2006-08-09 Application execution device Pending JP2009258772A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP2006216861A JP2009258772A (en) 2006-08-09 2006-08-09 Application execution device
PCT/JP2007/064851 WO2008018310A1 (en) 2006-08-09 2007-07-30 Application execution device, method, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2006216861A JP2009258772A (en) 2006-08-09 2006-08-09 Application execution device

Publications (1)

Publication Number Publication Date
JP2009258772A true JP2009258772A (en) 2009-11-05

Family

ID=39032844

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2006216861A Pending JP2009258772A (en) 2006-08-09 2006-08-09 Application execution device

Country Status (2)

Country Link
JP (1) JP2009258772A (en)
WO (1) WO2008018310A1 (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013511077A (en) * 2009-11-13 2013-03-28 イルデト カナダ コーポレーション System and method for protecting Java bytecode from static and dynamic attacks within a malicious execution environment
JP2016522489A (en) * 2013-05-15 2016-07-28 ソフトキャンプ カンパニー,リミテッド Data processing system security apparatus and security method
US10275592B2 (en) 2013-11-15 2019-04-30 Kabushiki Kaisha Toshiba Information processing device, information processing method, and computer program product
JP2020016926A (en) * 2018-07-23 2020-01-30 キヤノン株式会社 Information processing device, control method of information processing device, and program
WO2020196959A1 (en) * 2019-03-28 2020-10-01 라인플러스 주식회사 Method and system for protecting executable file by using heap memory

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010217975A (en) * 2009-03-13 2010-09-30 Nec System Technologies Ltd Information processor, application program, and method for executing application program
KR101471589B1 (en) * 2013-08-22 2014-12-10 (주)잉카엔트웍스 Method for Providing Security for Common Intermediate Language Program

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007233426A (en) * 2004-04-05 2007-09-13 Matsushita Electric Ind Co Ltd Application execution device
WO2006009081A1 (en) * 2004-07-16 2006-01-26 Matsushita Electric Industrial Co., Ltd. Application execution device and application execution device application execution method

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013511077A (en) * 2009-11-13 2013-03-28 イルデト カナダ コーポレーション System and method for protecting Java bytecode from static and dynamic attacks within a malicious execution environment
US9213826B2 (en) 2009-11-13 2015-12-15 Irdeto B.V. System and method to protect Java bytecode code against static and dynamic attacks within hostile execution environments
JP2016522489A (en) * 2013-05-15 2016-07-28 ソフトキャンプ カンパニー,リミテッド Data processing system security apparatus and security method
US10275592B2 (en) 2013-11-15 2019-04-30 Kabushiki Kaisha Toshiba Information processing device, information processing method, and computer program product
JP2020016926A (en) * 2018-07-23 2020-01-30 キヤノン株式会社 Information processing device, control method of information processing device, and program
US11474855B2 (en) 2018-07-23 2022-10-18 Canon Kabushiki Kaisha Information processing apparatus, information processing method, and storage medium
JP7195796B2 (en) 2018-07-23 2022-12-26 キヤノン株式会社 Information processing device, control method for information processing device, and program
WO2020196959A1 (en) * 2019-03-28 2020-10-01 라인플러스 주식회사 Method and system for protecting executable file by using heap memory

Also Published As

Publication number Publication date
WO2008018310A1 (en) 2008-02-14

Similar Documents

Publication Publication Date Title
US9767322B2 (en) Data transcription in a data storage device
KR101192546B1 (en) Use of media storage structure with multiple pieces of content in a content-distribution system
CN104581214B (en) Multimedia content guard method based on ARM TrustZone systems and device
US6789177B2 (en) Protection of data during transfer
EP1944905B1 (en) An encrypted transmission method and equipment system for preventing copying the data resource
TWI394419B (en) System and method for managing encrypted content using logical partitions
EP1612988A1 (en) Apparatus and/or method for encryption and/or decryption for multimedia data
EP2466511B1 (en) Media storage structures for storing content and devices for using such structures
JP2001256113A (en) Contents processing system and contents protection method
KR20060047953A (en) Secure storage on recordable medium in a content protection system
JP2009258772A (en) Application execution device
JP2005512258A (en) System data integrity verification method and apparatus
US20160204939A1 (en) Media storage structures for storing content, devices for using such structures, systems for distributing such structures
TWI352976B (en) Record carrier comprising encryption indication in
JP2005505853A (en) Apparatus and method for reading or writing user data
KR20080091785A (en) Method for recording and distributing digital data and related device
US9009489B2 (en) Device archiving of past cluster binding information on a broadcast encryption-based network
US8929547B2 (en) Content data reproduction system and collection system of use history thereof
CN107688729B (en) Application program protection system and method based on trusted host
JP5175494B2 (en) Encrypted content editing method and content management apparatus
TWI375160B (en) Method and system for locally activating a drm engine
US10929549B1 (en) System and method for protecting audio and video files
JP6992437B2 (en) Log recording device, log recording method, log decoding device, and log decoding method
US8689014B2 (en) Data encryption device and control method thereof
WO2011012594A1 (en) Content encryption using broadcast encryption