JP2021089607A - Information processing apparatus - Google Patents

Information processing apparatus Download PDF

Info

Publication number
JP2021089607A
JP2021089607A JP2019219857A JP2019219857A JP2021089607A JP 2021089607 A JP2021089607 A JP 2021089607A JP 2019219857 A JP2019219857 A JP 2019219857A JP 2019219857 A JP2019219857 A JP 2019219857A JP 2021089607 A JP2021089607 A JP 2021089607A
Authority
JP
Japan
Prior art keywords
timer
cpu
time
program
reset
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
JP2019219857A
Other languages
Japanese (ja)
Inventor
学 小澤
Manabu Ozawa
学 小澤
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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP2019219857A priority Critical patent/JP2021089607A/en
Publication of JP2021089607A publication Critical patent/JP2021089607A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Debugging And Monitoring (AREA)

Abstract

To provide an information processing apparatus that, after performing restoration processing on a program from which alteration is detected through verification, prevents reset by a WDT from being executed at the start-up of the apparatus.SOLUTION: An information processing apparatus MFP 1 has: a main CPU that executes and controls a program; a sub CPU that verifies the program; a WDT unit that includes a first timer for performing time counting during the operation of the apparatus and outputting a reset signal when clearing control of time counting is not performed within a first predetermined time, and a second timer for performing time counting when the sub CPU detects an abnormality during the verification of the program, and outputting a reset signal when clearing control for time counting is not performed within a second predetermined time; and a reset circuit that generates reset signals to the main CPU and the sub CPU based on the reset signals from the WDT unit. When detecting an abnormality during the verification of the program, the sub CPU stops time counting performed by the first timer, and starts time counting performed by the second timer to perform restoration processing on the program.SELECTED DRAWING: Figure 1

Description

本発明は、情報処理装置に関するものである。 The present invention relates to an information processing device.

ソフトウェアのハングアップ等が原因でシステムの正常動作が難しくなった場合、システム全体のリセットを実行して自動復旧を試みることを目的として、ウォッチドッグタイマ(Watch Dog Timer:WDT)が活用されてきた。WDTは、システムの動作中にカウンタ等によって計時を行い、そのカウンタに対するクリア制御が一定時間内に行われない場合、システムに異常が発生しているとみなし、強制的にシステムリセットを実行する。一般的に、カウンタに対するクリア制御は、システム制御を統括するメインCPUにより行われる。WDTはカウント値のクリア制御を受けると、それまでの計時値をリセットして、初期値から計時を再開する。例えば、特許文献1には、複数のCPUが同時に動作する場合に、各CPUが適切に動作していることを確認できるWDTが記載されている。 The Watch Dog Timer (WDT) has been used for the purpose of resetting the entire system and attempting automatic recovery when the normal operation of the system becomes difficult due to software hang-up or the like. .. The WDT measures the time with a counter or the like during the operation of the system, and if the clear control for the counter is not performed within a certain period of time, the WDT considers that an abnormality has occurred in the system and forcibly executes a system reset. Generally, the clear control for the counter is performed by the main CPU that controls the system control. When the WDT receives the clear control of the count value, it resets the previous timekeeping value and restarts the timekeeping from the initial value. For example, Patent Document 1 describes a WDT that can confirm that each CPU is operating properly when a plurality of CPUs are operating at the same time.

一方で、起動プログラムが改竄されていないことを検証しながらシステムを起動するセキュアブートを導入したMFP(Multi-function peripheral)が近年導入されつつある。このようなMFPは、ユーザによる電源スイッチのオン等によって行われるシステム起動の中で、最初にBIOS(Basi Input/Output System)やファームウェアに対する改竄の有無を検証することで、システムの起動中に、ソフトウェアの安全性を担保する。ここで検証の結果NGが発生すると、システムの起動の強制停止や、改竄されていると判定されたソフトウェアの復旧を実施する。ソフトウェアの復旧は、予め外部からの書き込みが不可能な領域にマスタデータを保持しておき、ソフトウェアの復旧が必要になった場合、そのNGと判定されたデータをマスタデータで上書きすることで、ソフトソフトウェアを復旧する。尚、上述したプログラムの改竄の有無の検証は、起動プログラムを実行するCPU自身は、その起動プログラムの改竄を検知できないため、起動プログラムを実行するCPUとは異なるサブCPUにより、その起動プログラムの改竄の有無を検証している。 On the other hand, in recent years, MFPs (Multi-function peripherals) that have introduced secure boot to boot the system while verifying that the boot program has not been tampered with have been introduced. Such an MFP first verifies whether or not the BIOS (Basi Input / Output System) and firmware have been tampered with during system startup performed by the user turning on the power switch, etc., so that during system startup, Ensure software safety. If NG occurs as a result of verification here, the system startup is forcibly stopped and the software determined to have been tampered with is restored. To recover the software, the master data is held in advance in an area that cannot be written from the outside, and when the software needs to be recovered, the data determined to be NG is overwritten with the master data. Recover software software. In the above-mentioned verification of whether or not the program has been tampered with, the CPU that executes the startup program itself cannot detect the alteration of the startup program, so that the startup program is tampered with by a sub CPU different from the CPU that executes the startup program. We are verifying the existence of.

特開2009−53952号公報Japanese Unexamined Patent Publication No. 2009-53952

上述したプログラムの改竄の有無を検証するシステムでは、サブCPUがブートコードの改竄の有無を検証する間、WDTをクリアできるメインCPUが動作できない。そのため、ブートコードの復旧が必要となった場合、メインCPUの起動までに要する時間が更に長くなる。そのため、システムとしては正常に動作しているにも拘わらず、WDTのタイムアウト時間に到達してしまい、不必要なリセットが実行されてしまうおそれがあった。 In the system for verifying the presence or absence of falsification of the program described above, the main CPU capable of clearing the WDT cannot operate while the sub CPU verifies the presence or absence of falsification of the boot code. Therefore, when it is necessary to recover the boot code, the time required to start the main CPU becomes longer. Therefore, even though the system is operating normally, the WDT timeout time may be reached and an unnecessary reset may be executed.

本発明の目的は、上記従来技術の問題点の少なくとも一つを解決することにある。 An object of the present invention is to solve at least one of the problems of the prior art.

本発明の目的は、プログラムの検証により異常が検出され、そのプログラムの復旧処理を行った後、装置が起動するときにWDTによるリセットが実行されるのを防止する技術を提供することにある。 An object of the present invention is to provide a technique for preventing an abnormality is detected by verification of a program, and after the recovery process of the program is performed, a reset by WDT is executed when the device is started.

上記目的を達成するために本発明の一態様に係る情報処理装置は以下のような構成を備える。即ち、
情報処理装置であって、
プログラムを実行して前記情報処理装置を制御する第1CPUと、
前記プログラムを検証する第2CPUと、
前記情報処理装置の動作中に計時を行い、当該計時のクリア制御が第1所定時間内に行われない場合にリセット信号を出力する第1タイマ手段と、
前記第2CPUが前記プログラムの検証で異常を検知したときに計時を行い、当該計時のクリア制御が第2所定時間内に行われない場合にリセット信号を出力する第2タイマ手段と、
前記第1タイマ手段及び前記第2タイマ手段からのリセット信号に基づいて前記第1CPU及び前記第2CPUへのリセット信号を生成するリセット手段と、を有し、
前記第2CPUは、前記プログラムの検証で異常を検知すると前記第1タイマ手段による計時を停止させ、前記第2タイマ手段による計時を開始させて前記プログラムの復旧処理を行うことを特徴とする。
In order to achieve the above object, the information processing apparatus according to one aspect of the present invention has the following configuration. That is,
It is an information processing device
A first CPU that executes a program and controls the information processing device,
The second CPU that verifies the program and
A first timer means that measures time during the operation of the information processing device and outputs a reset signal when the clear control of the time is not performed within the first predetermined time.
A second timer means that measures the time when the second CPU detects an abnormality in the verification of the program and outputs a reset signal when the clear control of the time is not performed within the second predetermined time.
It has a reset means for generating a reset signal to the first CPU and the second CPU based on the reset signal from the first timer means and the second timer means.
The second CPU is characterized in that when an abnormality is detected in the verification of the program, the time counting by the first timer means is stopped, the time counting by the second timer means is started, and the recovery process of the program is performed.

本発明によれば、プログラムの改竄が検出されて、その復旧処理を実行する場合でも、WDTを適切に動作させることができるという効果がある。 According to the present invention, there is an effect that the WDT can be properly operated even when the falsification of the program is detected and the recovery process is executed.

本発明のその他の特徴及び利点は、添付図面を参照とした以下の説明により明らかになるであろう。なお、添付図面においては、同じ若しくは同様の構成には、同じ参照番号を付す。 Other features and advantages of the present invention will become apparent in the following description with reference to the accompanying drawings. In the attached drawings, the same or similar configurations are designated by the same reference numbers.

添付図面は明細書に含まれ、その一部を構成し、本発明の実施形態を示し、その記述と共に本発明の原理を説明するために用いられる。
本発明の実施形態に係る複合機(MFP)のハードウェアの構成を説明するブロック図。 実施形態に係るメインCPUの構成を説明するブロック図。 実施形態に係るサブCPUの構成を説明するブロック図。 実施形態に係るフラッシュROMのメモリマップを示す図。 実施形態に係るWDT部の内部構成を説明するブロック図。 実施形態において、サブCPUによる改竄検証処理が実施されてメインCPUが起動するまでのMFPの起動処理を説明するシーケンス図。 実施形態において、サブCPUによる改竄検証処理の結果、改竄されていると判定され、復旧処理が行われるときのMFPの起動処理を説明するシーケンス図。 実施形態に係るサブCPUの処理を説明するフローチャート。 実施形態に係るMFPのメインCPUの処理を説明するフローチャート。 実施形態に係るWDT部の処理を説明するフローチャート。 実施形態に係るリセット回路による処理を説明するフローチャート。
The accompanying drawings are included in the specification and are used to form a part thereof, show an embodiment of the present invention, and explain the principle of the present invention together with the description thereof.
The block diagram explaining the hardware structure of the multifunction device (MFP) which concerns on embodiment of this invention. The block diagram explaining the structure of the main CPU which concerns on embodiment. The block diagram explaining the structure of the sub CPU which concerns on embodiment. The figure which shows the memory map of the flash ROM which concerns on embodiment. The block diagram explaining the internal structure of the WDT part which concerns on embodiment. In the embodiment, a sequence diagram illustrating the operation of starting the MFP from the falsification verification process performed by the sub CPU to the start of the main CPU. In the embodiment, a sequence diagram illustrating the operation of starting the MFP when it is determined that the device has been tampered with as a result of the tampering verification process by the sub CPU and the recovery process is performed. The flowchart explaining the processing of the sub CPU which concerns on embodiment. The flowchart explaining the processing of the main CPU of the MFP which concerns on embodiment. The flowchart explaining the processing of the WDT part which concerns on embodiment. The flowchart explaining the process by the reset circuit which concerns on embodiment.

以下、添付図面を参照して本発明の実施形態を詳しく説明する。尚、以下の実施形態は特許請求の範囲に係る発明を限定するものでない。実施形態には複数の特徴が記載されているが、これら複数の特徴の全てが発明に必須のものとは限らず、また、複数の特徴は任意に組み合わせられてもよい。さらに、添付図面においては、同一もしくは同様の構成に同一の参照番号を付し、重複した説明は省略する。なお、実施形態では、ブートコードの改竄検知時における改竄検知方法の一実施形態として、複合機(MFP)を例に本発明に係る情報処理装置の一例を説明する。尚、特に断らない限り、本発明の機能が実行されるのであれば、単体の機器であっても、複数の機器からなるシステムであっても、本発明を適用できることは言うまでもない。 Hereinafter, embodiments of the present invention will be described in detail with reference to the accompanying drawings. The following embodiments do not limit the invention according to the claims. Although a plurality of features are described in the embodiment, not all of the plurality of features are essential to the invention, and the plurality of features may be arbitrarily combined. Further, in the attached drawings, the same or similar configurations are designated by the same reference numbers, and duplicate explanations are omitted. In the embodiment, as an embodiment of the falsification detection method at the time of falsification detection of the boot code, an example of the information processing apparatus according to the present invention will be described by taking a multifunction device (MFP) as an example. It goes without saying that the present invention can be applied to a single device or a system composed of a plurality of devices as long as the functions of the present invention are executed unless otherwise specified.

図1は、本発明の実施形態に係る複合機(MFP)1のハードウェアの構成を説明するブロック図である。 FIG. 1 is a block diagram illustrating a hardware configuration of a multifunction device (MFP) 1 according to an embodiment of the present invention.

メインCPU(Central Processing Unit)101は、MFP1全体の制御を司る。DRAM(Dynamic Random Access Memory)102は、メインCPU101で実行されるプログラムを格納すると共に、一時的に各種データを保存するワークエリアとして機能する。操作部103は、操作部I/F113を介してメインCPU101にユーザによる操作を通知する。ネットワークI/F104は、LAN130と接続して外部機器と通信を行う。プリンタ部105は、画像データを紙面上に印刷する。スキャナ部106は、紙面上の画像を光学的に読み取り電気信号に変換してスキャン画像データを生成する。FAX部107は、公衆回線110と接続して外部機器とファクシミリ通信を行う。HDD(ハードデスクドライブ)108は、メインCPU101で実行されるプログラムを格納すると共に、プリントジョブやスキャンジョブ等のスプール領域としても利用される。また、スキャン画像を保管し再利用するための領域としても利用される。信号バス109は、各モジュールを相互に接続して通信を行う。公衆回線110は、FAX部107と外部機器を相互接続する。画像処理部111は、ネットワークI/F104を介して受信したプリントジョブをプリンタ部105で印刷するのに適した画像データに変換したり、スキャナ部106で読み取ったスキャン画像のノイズ除去や色空間変換、回転、圧縮等の処理を実行する。更に画像処理部111は、HDD108に保管されたスキャン画像の画像処理を実行する。フラッシュROM112は、メインCPU101で実行されるブートコードを含むプログラムを格納すると共に、MFP1のデフォルト設定値等を記憶する。操作部I/F113は、操作部103と信号バス109を相互接続する。SPIバス114は、メインCPU101、フラッシュROM112、サブCPU115を相互接続する。 The main CPU (Central Processing Unit) 101 controls the entire MFP1. The DRAM (Dynamic Random Access Memory) 102 stores a program executed by the main CPU 101 and functions as a work area for temporarily storing various data. The operation unit 103 notifies the main CPU 101 of the operation by the user via the operation unit I / F 113. The network I / F 104 connects to the LAN 130 and communicates with an external device. The printer unit 105 prints the image data on the paper surface. The scanner unit 106 optically reads an image on a paper surface and converts it into an electric signal to generate scanned image data. The FAX unit 107 connects to the public line 110 and performs facsimile communication with an external device. The HDD (hard disk drive) 108 stores a program executed by the main CPU 101, and is also used as a spool area for a print job, a scan job, and the like. It is also used as an area for storing and reusing scanned images. The signal bus 109 connects the modules to each other for communication. The public line 110 interconnects the fax unit 107 and an external device. The image processing unit 111 converts the print job received via the network I / F 104 into image data suitable for printing by the printer unit 105, noise removal and color space conversion of the scanned image read by the scanner unit 106. , Rotate, compress, etc. Further, the image processing unit 111 executes image processing of the scanned image stored in the HDD 108. The flash ROM 112 stores a program including a boot code executed by the main CPU 101, and also stores a default setting value of the MFP1 and the like. The operation unit I / F 113 interconnects the operation unit 103 and the signal bus 109. The SPI bus 114 interconnects the main CPU 101, the flash ROM 112, and the sub CPU 115.

サブCPU115は、MFP1の起動時に、メインCPU101が起動する前にフラッシュROM112からブートコードを読み出して、ブートコードが改竄されていないか検証を行う。改竄の検知方法としては、例えばブートコードのデジタル署名の公開鍵情報(ハッシュ値を公開鍵暗号化した値)を、製造時にサブCPU115のOTP(One Time Programable)304領域(図3)に記憶させておき、読み出したブートコードをこの公開鍵情報で復号化して検証を行う。公開鍵暗号の方法としてはRSA2048、ECDSAなどがある。 The sub CPU 115 reads the boot code from the flash ROM 112 at the time of starting the MFP 1 before the main CPU 101 starts, and verifies whether the boot code has been tampered with. As a method for detecting tampering, for example, the public key information (value obtained by public key encryption of the hash value) of the digital signature of the boot code is stored in the OTP (One Time Programable) 304 area (FIG. 3) of the sub CPU 115 at the time of manufacture. Then, the read boot code is decrypted with this public key information and verified. Public key cryptography methods include RSA2048 and ECDSA.

メインCPUのリセット信号117は、電源制御部118のGPIOポートから出力されて、メインCPU101のリセット端子に接続される。リセット信号117は、後に図7で詳細に説明する改竄検証が完了し、改竄無しとサブCPU115が判定した場合に、ロウレベルからハイレベルに遷移する。ここで、ロウレベルとは「0」を示す電気信号の状態を示す。またハイレベルとは「1」を示す電気信号の状態を表す。リセット信号117がハイレベルになると、メインCPU101はリセットが解除されて起動を開始する。 The reset signal 117 of the main CPU is output from the GPIO port of the power supply control unit 118 and is connected to the reset terminal of the main CPU 101. The reset signal 117 transitions from the low level to the high level when the falsification verification described in detail later in FIG. 7 is completed and the sub CPU 115 determines that there is no falsification. Here, the low level indicates the state of an electric signal indicating "0". The high level represents the state of the electric signal indicating "1". When the reset signal 117 reaches a high level, the main CPU 101 is released from the reset and starts to start.

電源制御部118は、MFP1内の各モジュールの電力供給を制御するとともに、その内部に、後述するWDT部140及びリセット回路122を有している。また電源制御部118は信号バス109に接続されており、メインCPU101で動作するソフトウェアによる各種制御レジスタへのアクセスが可能な構成になっている。電源線119は、各モジュールに電力を供給する。電源供給線120は、商業用AC電源を供給している。 The power supply control unit 118 controls the power supply of each module in the MFP 1, and has a WDT unit 140 and a reset circuit 122, which will be described later, inside the power supply control unit 118. Further, the power supply control unit 118 is connected to the signal bus 109, and has a configuration in which various control registers can be accessed by software running on the main CPU 101. The power line 119 supplies power to each module. The power supply line 120 supplies commercial AC power.

リセット回路122は、サブCPU115、及びメインCPU101に対するリセット信号の制御を行う。リセット回路122は、システムの電源がオンされると、サブCPUのリセット信号123をロウレベルからハイレベルに遷移する。サブCPU115のリセット信号123は、リセット回路122から出力されてサブCPU115のリセット端子に接続される。サブCPU115のリセット信号123がハイレベルになると、サブCPU115はリセットが解除されて起動を開始する。またリセット回路122は、後述する改竄検証完了通知信号131がサブCPU115から入力されると、メインCPU101のリセット信号117をハイレベルにしてリセットを解除する。更に、リセット回路122は、後述するWDT部140からの制御によりメインCPU101、及びサブCPU115をリセットする。 The reset circuit 122 controls the reset signal for the sub CPU 115 and the main CPU 101. The reset circuit 122 transitions the reset signal 123 of the sub CPU from the low level to the high level when the power of the system is turned on. The reset signal 123 of the sub CPU 115 is output from the reset circuit 122 and connected to the reset terminal of the sub CPU 115. When the reset signal 123 of the sub CPU 115 reaches a high level, the reset of the sub CPU 115 is released and the sub CPU 115 starts to start. Further, when the falsification verification completion notification signal 131 described later is input from the sub CPU 115, the reset circuit 122 raises the reset signal 117 of the main CPU 101 to a high level and releases the reset. Further, the reset circuit 122 resets the main CPU 101 and the sub CPU 115 under the control of the WDT unit 140, which will be described later.

改竄検証完了通知信号131は、サブCPU115がブートコードに改竄がないことを確認し、正常に検証が完了したことを通知するための信号である。改竄検証完了通知信号131は、サブCPU115のGPIOポートから出力されて、電源制御部118に備えられるリセット回路122に接続される。実施形態において、改竄検証完了通知信号131の初期値はロウレベルであり、通知を行う場合はハイレベルとする。リセット回路122は、改竄検証完了通知信号131がハイレベルになると、メインCPU101のリセット信号117をハイレベルとすることでメインCPU101のリセット解除する。 The falsification verification completion notification signal 131 is a signal for the sub CPU 115 to confirm that the boot code has not been tampered with and to notify that the verification has been completed normally. The falsification verification completion notification signal 131 is output from the GPIO port of the sub CPU 115 and is connected to the reset circuit 122 provided in the power supply control unit 118. In the embodiment, the initial value of the falsification verification completion notification signal 131 is a low level, and when notifying, it is set to a high level. When the falsification verification completion notification signal 131 reaches a high level, the reset circuit 122 releases the reset of the main CPU 101 by setting the reset signal 117 of the main CPU 101 to a high level.

ネットワークI/F用フラッシュROM133は、ネットワークI/F104が動作するために必要なファームウェアを記憶している。WDT部140は、システムの電源がオンされると、所定の遅延時間後にWDT部140の内部に備えられるタイマ回路によるカウントを開始する。WDT部140は、予め設定されたタイムアウト値にカウント値が到達すると、強制システムリセット信号132をハイレベルにすることで、リセット回路122にシステムリセットを実行するよう指示する。WDT部140は、後述するタイマ切り替え信号141(図5)の信号レベルによって、内部に保有する2つのタイマの内の一つを選択してカウントを行う。タイマ切り替え信号141の信号レベルは、サブCPU115による改竄検証処理の結果、改竄の形跡が有り、復旧が必要と判断された場合の復旧処理の前後でサブCPU115によってハイレベル又はロウレベルに変更される。実施形態において、通常時に用いられるタイマは、タイマ切り替え信号141の信号レベルがロウレベルの場合に選択される。 The network I / F flash ROM 133 stores the firmware required for the network I / F 104 to operate. When the power of the system is turned on, the WDT unit 140 starts counting by the timer circuit provided inside the WDT unit 140 after a predetermined delay time. When the count value reaches the preset timeout value, the WDT unit 140 sets the forced system reset signal 132 to a high level, thereby instructing the reset circuit 122 to perform a system reset. The WDT unit 140 selects and counts one of the two timers held internally according to the signal level of the timer switching signal 141 (FIG. 5) described later. The signal level of the timer switching signal 141 is changed to a high level or a low level by the sub CPU 115 before and after the recovery process when there is evidence of falsification as a result of the falsification verification process by the sub CPU 115 and it is determined that recovery is necessary. In the embodiment, the timer normally used is selected when the signal level of the timer switching signal 141 is low.

また実施形態において、サブCPU115が処理完了までに時間を要する処理を実行する際に選択する、タイムアウトまでの時間が長いタイマはタイマ切り替え信号141の信号レベルがハイレベルの場合に選択されるものとする。実施形態におけるタイマ切り替え信号141の初期値はロウレベルであるものとする。 Further, in the embodiment, the timer with a long time-out time selected when the sub CPU 115 executes a process that requires time to complete the process is selected when the signal level of the timer switching signal 141 is high. To do. It is assumed that the initial value of the timer switching signal 141 in the embodiment is a low level.

WDT部140は、CPU101からのタイマ502(図5)のクリア制御レジスタへの書き込み、もしくはタイマ切り替え信号141の信号レベルが変化してカウントに使用されるタイマが切り替わることをトリガとして、カウント値を初期値へ戻して再度カウントを行うように構成される。 The WDT unit 140 sets the count value by writing from the CPU 101 to the clear control register of the timer 502 (FIG. 5) or by switching the timer used for counting by changing the signal level of the timer switching signal 141. It is configured to return to the initial value and count again.

リセット回路122は、強制システムリセット信号132がハイレベルになると、リセット信号117、リセット信号123をロウレベルに変更することで、メインCPU101、及びサブCPU115をリセットする。リセット回路122は更に不図示のリセット信号を通じて、MFP1を構成する各モジュールをリセットできるようにすることもできる。WDTクリア信号141は、WDT部140に設定されているタイムアウト時間間隔よりも短い間隔でサブCPU115からWDT部140に出力される。 When the forced system reset signal 132 reaches a high level, the reset circuit 122 resets the main CPU 101 and the sub CPU 115 by changing the reset signal 117 and the reset signal 123 to a low level. The reset circuit 122 can also make it possible to reset each module constituting the MFP 1 through a reset signal (not shown). The WDT clear signal 141 is output from the sub CPU 115 to the WDT unit 140 at intervals shorter than the timeout time interval set in the WDT unit 140.

図2は、実施形態に係るメインCPU101の構成を説明するブロック図である。 FIG. 2 is a block diagram illustrating a configuration of the main CPU 101 according to the embodiment.

CPUコア201は、CPUの基本機能を担っている。実施形態では、CPU101が起動すると、信号バス109を通じてWDT部140にタイマ502(図5)のクリア制御を行うことで、WDT部140によるリセット制御を抑制する。SPIマスタ202は、SPIマスタ202と外部SPIデバイスとを電気的に接続するSPIバス114を介し、外部のSPIデバイスとのデータの読み書きを行う。信号バスインターフェース203は、信号バス109とメインCPU101内の信号バス209とを接続する。信号バス209は、メインCPU101内の各モジュールを接続する。リセット信号117がロウレベルのときはメインCPU101はリセット状態となり、リセット信号117がハイレベルのとき、メインCPU101はリセット解除状態となる。 The CPU core 201 is responsible for the basic functions of the CPU. In the embodiment, when the CPU 101 is started, the WDT unit 140 is controlled to clear the timer 502 (FIG. 5) through the signal bus 109, thereby suppressing the reset control by the WDT unit 140. The SPI master 202 reads and writes data to and from the external SPI device via the SPI bus 114 that electrically connects the SPI master 202 and the external SPI device. The signal bus interface 203 connects the signal bus 109 and the signal bus 209 in the main CPU 101. The signal bus 209 connects each module in the main CPU 101. When the reset signal 117 is at the low level, the main CPU 101 is in the reset state, and when the reset signal 117 is at the high level, the main CPU 101 is in the reset release state.

実施形態では、サブCPU115によって、サブCPUファームウェア(FW)404(図4)及び、メインCPU BIOS401(図4)が改竄されてないことが確認されると、サブCPU115と電源制御部118とによってリセット信号117が制御されてメインCPU101のリセットが解除される。これによりメインCPU101は、自身の起動プログラムに一切の改竄がないことを保証された状態で起動を開始することができる。リセット信号117がリセット状態(ロウレベル)からリセット解除状態(ハイレベル)に遷移すると、CPUコア201は先ず、フラッシュROM112に記憶されているメインCPU BIOS404をDRAM102にロードして実行する。 In the embodiment, when it is confirmed that the sub CPU firmware (FW) 404 (FIG. 4) and the main CPU BIOS401 (FIG. 4) have not been tampered with by the sub CPU 115, the sub CPU 115 and the power supply control unit 118 reset the sub CPU 115. The signal 117 is controlled to release the reset of the main CPU 101. As a result, the main CPU 101 can start booting in a state where it is guaranteed that its boot program has not been tampered with. When the reset signal 117 transitions from the reset state (low level) to the reset release state (high level), the CPU core 201 first loads the main CPU BIOS404 stored in the flash ROM 112 into the DRAM 102 and executes it.

図3は、実施形態に係るサブCPU115の構成を説明するブロック図である。 FIG. 3 is a block diagram illustrating the configuration of the sub CPU 115 according to the embodiment.

CPUコア301は、CPUの基本機能を担っている。SPIマスタ302は、SPIマスタ302と外部SPIデバイスとを電気的に接続するSPIバス114を介し、外部のSPIデバイスとのデータの読み書きを行う。GPIO(General-purpose Input/Output)303は、外部のデバイスと相互に接続してデータの送信を行う。GPIO303には2本の信号が接続されていて、一つ目はサブCPU115がブートコードの検証が正常に完了したことを示す、改竄検証完了通知信号131である。2つ目はWDT部140が持つタイマを切り替えるためのタイマ切り替え信号141である。 The CPU core 301 is responsible for the basic functions of the CPU. The SPI master 302 reads and writes data to and from the external SPI device via the SPI bus 114 that electrically connects the SPI master 302 and the external SPI device. The GPIO (General-purpose Input / Output) 303 transmits data by interconnecting with an external device. Two signals are connected to the GPIO 303, and the first is a falsification verification completion notification signal 131 indicating that the sub CPU 115 has normally completed the verification of the boot code. The second is a timer switching signal 141 for switching the timer of the WDT unit 140.

OTPメモリ領域304には、製造時にサブCPUファームウェア404(図4)のハッシュ値を公開鍵で暗号化した値、及びTagのアドレスが書き込まれる。この領域に書き込まれたデータは一度書き込まれると二度と書換えることはできない。SRAM305は、サブCPU115のワークメモリとして使用される。暗号/復号処理部308は、公開鍵で暗号化した値からサブCPUファームウェア404のハッシュ値を復号するほか、公開鍵で暗号化したメインCPU BIOSのハッシュ値を復号する。信号バス309は、サブCPU115の各モジュールを接続する。ブートROM(Read Only Memory)310は、サブCPU115のブートコードを記憶する。 At the time of manufacture, the hash value of the sub CPU firmware 404 (FIG. 4) encrypted with the public key and the Tag address are written in the OTP memory area 304. The data written in this area cannot be rewritten once it has been written. The SRAM 305 is used as the work memory of the sub CPU 115. The encryption / decryption processing unit 308 decrypts the hash value of the sub CPU firmware 404 from the value encrypted with the public key, and also decrypts the hash value of the main CPU BIOS encrypted with the public key. The signal bus 309 connects each module of the sub CPU 115. The boot ROM (Read Only Memory) 310 stores the boot code of the sub CPU 115.

サブCPU115には、図1で説明したリセット信号123が入力される。サブCPU115のCPUコア301は、リセット信号123がロウレベルのときリセット状態となり、リセット信号123がハイレベルのときにリセット解除状態となる。リセット信号123がリセット状態からリセット解除状態に遷移すると、CPUコア301は先ず、ブートROM310から自身のブートコードを読み出し実行する。Crypto RAM311は、暗号/復号処理部308で利用する機密性の高いデータ等の一時記憶が可能なワーク領域として用いられる。 The reset signal 123 described with reference to FIG. 1 is input to the sub CPU 115. The CPU core 301 of the sub CPU 115 is in the reset state when the reset signal 123 is at the low level, and is in the reset release state when the reset signal 123 is at the high level. When the reset signal 123 transitions from the reset state to the reset release state, the CPU core 301 first reads its own boot code from the boot ROM 310 and executes it. The Cryptto RAM 311 is used as a work area capable of temporarily storing highly confidential data or the like used by the encryption / decryption processing unit 308.

図4は、実施形態に係るフラッシュROM112のメモリマップを示す図である。 FIG. 4 is a diagram showing a memory map of the flash ROM 112 according to the embodiment.

メインCPU BIOS401は、メインCPU101で実行されるコードを記憶している。BIOS署名402は、メインCPU BIOS401のハッシュ値に対するRSA署名値を記憶している。Tag403は、サブCPUファームウェア404の先頭アドレスを記憶している。Tag403自体のアドレスは、OTP304に記憶されている。サブCPUファームウェア404は、サブCPU115で実行されるコードを記憶している。ファームウェア(FW)署名405は、サブCPUファームウェア404、またはサブCPUファームウェア404の先頭の特定部分のECDSA署名値を記憶している。ROM−ID406は、メインCPU BIOS401の先頭アドレス、サイズ及びBIOS署名のアドレスを記憶している。407〜411は、これまでに説明したメインCPU BIOS401からROM−ID406までの各データの復旧用GoldenMasterデータで、WriteProtect等の外部からの書き換えが不可能な記憶領域に保持されている。実施形態では、一続きのアドレスの一部に対して、WriteProtect設定ができるデバイスを使用することを想定した図として記載している。 The main CPU BIOS 401 stores the code executed by the main CPU 101. The BIOS signature 402 stores the RSA signature value for the hash value of the main CPU BIOS 401. The Tag 403 stores the start address of the sub CPU firmware 404. The address of Tag403 itself is stored in OTP304. The sub CPU firmware 404 stores the code executed by the sub CPU 115. The firmware (FW) signature 405 stores the sub CPU firmware 404 or the ECDSA signature value of a specific portion at the beginning of the sub CPU firmware 404. The ROM-ID 406 stores the start address, size, and BIOS signature address of the main CPU BIOS 401. Reference numerals 407 to 411 are Golden Master data for recovery of each data from the main CPUs BIOS401 to ROM-ID406 described so far, and are held in a storage area such as WriteProtect that cannot be rewritten from the outside. In the embodiment, it is described as a diagram assuming that a device capable of setting WriteProtect is used for a part of a series of addresses.

図5は、実施形態に係るWDT部140の内部構成を説明するブロック図である。 FIG. 5 is a block diagram illustrating an internal configuration of the WDT unit 140 according to the embodiment.

WDT制御部501は、次に説明するタイマ502、及びタイマ503のクリア制御と、これら2つのタイマの中から、タイムアウト判定に使うタイマを選択するタイマ切り替え信号141の信号レベルに応じて選択する。 The WDT control unit 501 selects the timer 502 and the timer 503, which will be described next, from the two timers according to the signal level of the timer switching signal 141 that selects the timer to be used for the timeout determination.

タイマ502は、タイマ切り替え信号141の信号レベルがロウレベルの場合にWDT制御部501によって選択される。タイマ502は、自身に予め設定されたタイムアウト値とタイマ回路によるカウント値を比較しながら、タイムアウト値とカウント値が等しくなった場合に、WDT制御部501へタイムアウトが発生したことを通知する。またWDT制御部501からカウント値のクリア制御によって、カウント値を初期値に戻して再度カウントを開始する。 The timer 502 is selected by the WDT control unit 501 when the signal level of the timer switching signal 141 is low. The timer 502 notifies the WDT control unit 501 that a timeout has occurred when the timeout value and the count value become equal to each other while comparing the timeout value set in advance with the count value by the timer circuit. Further, the count value is returned to the initial value by the clear control of the count value from the WDT control unit 501, and the count is started again.

タイマ503は、タイマ切り替え信号141の信号レベルがハイレベルの場合にWDT制御部501によって選択される。タイマ503は、自身に予め設定されたタイムアウト値とタイマ回路によるカウント値を比較しながら、タイムアウト値とカウント値が等しくなった場合に、WDT制御部501へタイムアウトが発生したことを通知する。またWDT制御部501からカウント値のクリア制御によって、カウント値を初期値に戻して再度カウントを開始する。 The timer 503 is selected by the WDT control unit 501 when the signal level of the timer switching signal 141 is high. The timer 503 compares the timeout value preset in itself with the count value by the timer circuit, and notifies the WDT control unit 501 that a timeout has occurred when the timeout value and the count value become equal. Further, the count value is returned to the initial value by the clear control of the count value from the WDT control unit 501, and the count is started again.

実施形態では、タイマ502は、通常用いられるタイマとし、タイムアウト値はサブCPU115が改竄検証処理を実施するのに必要な時間に、CPU101が起動してからシステムバス109を介したカウントクリア制御が実施可能になるまでの時間を加算し、更に、マージン時間を追加して設定される。一方タイマ503は、サブCPU115が改竄検証を行った結果、改竄されていると判定した場合の復旧処理に要する時間にマージン時間を加算した時間に設定される。タイマ502及びタイマ503がタイマ切り替え信号141によって切り替えられるタイミングについては図1で説明した通りである。 In the embodiment, the timer 502 is a normally used timer, and the timeout value is the time required for the sub CPU 115 to perform the falsification verification process, and the count clear control is performed via the system bus 109 after the CPU 101 is started. The time until it becomes possible is added, and the margin time is added and set. On the other hand, the timer 503 is set to a time obtained by adding a margin time to the time required for the recovery process when it is determined that the sub CPU 115 has been tampered with as a result of the tampering verification. The timing at which the timer 502 and the timer 503 are switched by the timer switching signal 141 is as described with reference to FIG.

WDT制御部501は、タイマ502とタイマ503の内、入力されるタイマ切り替え信号141の信号レベルに応じて選択しているタイマからのタイムアウト発生を検出すると、強制システムリセット信号132をリセット回路122へ出力する。更に、システムバス109を介してメインCPU101から行われるカウントクリア設定をトリガとして、WDT制御部501が選択しているタイマのタイマ値のクリアを実行する。 When the WDT control unit 501 detects the occurrence of a timeout from the timer selected according to the signal level of the input timer switching signal 141 among the timer 502 and the timer 503, the WDT control unit 501 sends the forced system reset signal 132 to the reset circuit 122. Output. Further, the timer value of the timer selected by the WDT control unit 501 is cleared by using the count clear setting performed from the main CPU 101 via the system bus 109 as a trigger.

実施形態においては、タイマ502とタイマ503は排他的に使用するため、不要なタイマの動作を停止する例で説明するが、WDT制御部501が選択しているタイマからのタイムアウトのみを検出するように構成すれば、タイマを切り替える際にタイマの動作を停止する動作が必要なくなるため、より簡単な制御で実施可能となる。 In the embodiment, since the timer 502 and the timer 503 are used exclusively, the operation of the unnecessary timer will be stopped. However, only the timeout from the timer selected by the WDT control unit 501 is detected. If it is configured as, it is not necessary to stop the operation of the timer when switching the timer, so that the operation can be performed with simpler control.

また実施形態では、サブCPU115が改竄検証処理を実施中、メインCPU101がリセット状態であって動作できないため、サブCPU115が改竄検証処理中にメインCPU101によるクリア設定は行われない。これはサブCPU115が改竄検証を行った結果、改竄されていると判定すると、改竄が発見されたデータに対してGoldenMasterデータを上書きすることによる復旧処理中も同じこととなる。 Further, in the embodiment, since the main CPU 101 is in the reset state and cannot operate while the sub CPU 115 is performing the falsification verification process, the main CPU 101 does not perform the clear setting during the falsification verification process. If the sub CPU 115 determines that the data has been tampered with as a result of the tampering verification, the same applies during the recovery process by overwriting the GoldenMaster data with respect to the data in which the tampering is found.

一方でサブCPU115による改竄検証が完了してメインCPU101による制御が開始されると、メインCPU101はシステムバス109を介して定期的にカウントクリア設定を行うことで、タイムアウトの発生を防ぎ、システムの動作を継続させることができる。 On the other hand, when the falsification verification by the sub CPU 115 is completed and the control by the main CPU 101 is started, the main CPU 101 periodically sets the count clear via the system bus 109 to prevent the occurrence of a timeout and operate the system. Can be continued.

次に、実施形態におけるMFP1の起動処理の中で、これまでに説明してきた主要なコンポーネント間の処理関係を時系列に説明する。 Next, in the startup process of the MFP 1 in the embodiment, the processing relationship between the main components described so far will be described in chronological order.

図6Aは、実施形態において、サブCPU115による改竄検証処理が実施されてメインCPU101が起動するまでのMFP1の起動処理を説明するシーケンス図である。 FIG. 6A is a sequence diagram illustrating the activation process of the MFP 1 from the falsification verification process performed by the sub CPU 115 to the activation of the main CPU 101 in the embodiment.

まずS601で、MFP1はユーザによって起動操作がなされる。これによりS602で電源制御部118に電源が供給され、各モジュールへ電源が分配される。これにより、WDT部140、リセット回路122、サブCPU115、メインCPU101へ電力の供給が開始される。この状態では、リセット回路122は、サブCPU115へ接続されるサブCPUリセット信号123と、メインCPU101へ接続されるメインCPU101のリセット信号117をともにロウレベルにキープし、リセット継続する。 First, in S601, the MFP1 is started by the user. As a result, power is supplied to the power supply control unit 118 in S602, and the power supply is distributed to each module. As a result, power supply to the WDT unit 140, the reset circuit 122, the sub CPU 115, and the main CPU 101 is started. In this state, the reset circuit 122 keeps both the sub CPU reset signal 123 connected to the sub CPU 115 and the reset signal 117 of the main CPU 101 connected to the main CPU 101 to a low level, and continues resetting.

こうして電源が供給されると、WDT部140はS603でタイマ切り替え信号141の信号レベルを確認してタイマを選択し、ここではタイマ502を選択してタイマ502によるによるカウントを開始する。ここでタイマ502が選択されているのは、タイマ切り替え信号141の初期値がロウレベルであるためである。これと並列して、リセット回路122はS604で、サブCPU115へ接続されるサブCPUリセット信号123をハイレベルに変更することで、サブCPU115のリセットを解除する。 When the power is supplied in this way, the WDT unit 140 confirms the signal level of the timer switching signal 141 in S603 and selects a timer, and here the timer 502 is selected and counting by the timer 502 is started. The timer 502 is selected here because the initial value of the timer switching signal 141 is low level. In parallel with this, the reset circuit 122 releases the reset of the sub CPU 115 by changing the sub CPU reset signal 123 connected to the sub CPU 115 to a high level in S604.

これによりS605でサブCPU115は、サブCPUファームウェア404の検証を開始する。これと同時に、サブCPU115はリセットが解除されると、S606でメインCPU BIOS401の改竄検証を開始する。そして、改竄が検知されなかった場合はS607で、サブCPU115は改竄検証終了信号131をハイレベルに変更する。こうして、改竄の事実が無く起動可能なことをリセット回路122に通知し、S608で省電力状態へ移行する。 As a result, in S605, the sub CPU 115 starts the verification of the sub CPU firmware 404. At the same time, when the reset is released, the sub CPU 115 starts tampering verification of the main CPU BIOS401 in S606. Then, when tampering is not detected, in S607, the sub CPU 115 changes the tampering verification end signal 131 to a high level. In this way, the reset circuit 122 is notified that it can be started without the fact of falsification, and the power saving state is entered in S608.

こうして改竄検証終了信号131がアサートされたリセット回路122はS609で、メインCPU101のリセット信号117をロウレベルからハイレベルに変更することにより、メインCPU101のリセットを解除する。そして、リセットが解除されたメインCPU101はS610で、自身が起動するのに必要なメインCPU BIOS401をフラッシュROM112から読み出してメインCPU101の起動を開始する。そしてS611でメインCPU101は、メインCPU BIOS401の読み出しを行って、BIOS起動を行うと、その後はOSの起動を含むシステムの起動を開始する。 In S609, the reset circuit 122 in which the falsification verification end signal 131 is asserted releases the reset of the main CPU 101 by changing the reset signal 117 of the main CPU 101 from the low level to the high level. Then, the reset-released main CPU 101 is S610, which reads the main CPU BIOS401 necessary for its own activation from the flash ROM 112 and starts the activation of the main CPU 101. Then, in S611, the main CPU 101 reads out the main CPU BIOS 401 to start the BIOS, and then starts the system startup including the OS startup.

次に、メインCPU101はWDT制御ソフトウェアが起動するとS612で、システムバス109を介してWDT140のタイマ502のカウント値をクリアする。それとともにS614で、WDT140が持つタイマのクリア制御を行う間隔を生成するためのタイマを起動する。このタイマはCPU101上で動作するソフトウェアで実現するとして説明を続けるが、メインCPU1010内部にカウンタ回路がある場合はそれを活用してもよいことは言うまでもない。またWDT140はS613で、メインCPU101からのタイマ502のカウント値のクリアに応じて、タイマ502,503のカウント値をクリアし、タイマ502によるカウントを開始する。 Next, when the WDT control software is started, the main CPU 101 clears the count value of the timer 502 of the WDT 140 via the system bus 109 in S612. At the same time, in S614, a timer for generating an interval for clear control of the timer of the WDT 140 is activated. The explanation will be continued assuming that this timer is realized by software running on the CPU 101, but it goes without saying that if there is a counter circuit inside the main CPU 1010, it may be used. Further, in S613, the WDT 140 clears the count values of the timers 502 and 503 in response to the clearing of the count value of the timer 502 from the main CPU 101, and starts counting by the timer 502.

そしてS615で、メインCPU101で動作するタイマがタイムアウトに到達するとS616で、WDT部140へ信号バス109を介してアクセスし、図示しないWDTクリアレジスタに「1」を書き込むことで、WDT部140のタイマ502をクリアする。WDT部140は、WDTクリアレジスタが「1」に変化するとS617で、タイマ502,503のカウント値のクリア制御を実施し、再度、タイマ502によるカウントを開始する。 Then, in S615, when the timer operating in the main CPU 101 reaches the timeout, in S616, the WDT unit 140 is accessed via the signal bus 109, and "1" is written to the WDT clear register (not shown) to write the timer of the WDT unit 140. Clear 502. When the WDT clear register changes to "1", the WDT unit 140 performs clear control of the count values of the timers 502 and 503 in S617, and starts counting by the timer 502 again.

このとき、S607までにサブCPU115による処理に異常が発生した場合、WDT部140のタイマ502によるカウント値が予め定められたタイムアウト値を超過してしまうため、タイムアウトが発生する。また、メインCPU101で動作するソフトウェアがハングアップ等によりWDTクリアレジスタの設定を行えなくなった場合も、WDT部140のタイマ502によるカウント値が予め定められたタイムアウト値を超過してしまうため、タイムアウトが発生する。このようにして一度タイムアウトが発生すると、WDT部140のWDT制御部501は、リセット回路122へ強制システムリセット信号132を出力し、メインCPU101とサブCPU115をリセットするように制御する。リセット回路122によるリセット処理は予め定められた時間継続し、リセット回路122によるリセットが解除されると、S603以降の動作を再度実施する。 At this time, if an abnormality occurs in the processing by the sub CPU 115 by S607, the count value by the timer 502 of the WDT unit 140 exceeds the predetermined timeout value, so that a timeout occurs. Further, even if the software running on the main CPU 101 cannot set the WDT clear register due to a hang or the like, the count value by the timer 502 of the WDT unit 140 exceeds the predetermined timeout value, so that the timeout occurs. appear. Once a timeout occurs in this way, the WDT control unit 501 of the WDT unit 140 outputs a forced system reset signal 132 to the reset circuit 122 to control the main CPU 101 and the sub CPU 115 to be reset. The reset process by the reset circuit 122 continues for a predetermined time, and when the reset by the reset circuit 122 is released, the operations after S603 are performed again.

次に図6Bを参照して、サブCPU115による改竄検証処理の結果、改竄されていると判定されて復旧処理が行われる場合で、CPU101が起動するまでのMFP1の起動処理に関するシーケンスについて説明する。 Next, with reference to FIG. 6B, a sequence relating to the startup process of the MFP 1 until the CPU 101 is started will be described when it is determined that the sub CPU 115 has been tampered with and the recovery process is performed as a result of the tampering verification process.

図6Bは、実施形態において、サブCPU115による改竄検証処理の結果、改竄されていると判定され、復旧処理が行われるときのMFP1の起動処理を説明するシーケンス図である。 FIG. 6B is a sequence diagram for explaining the activation process of the MFP 1 when it is determined that the sub CPU 115 has been tampered with as a result of the tampering verification process and the recovery process is performed in the embodiment.

まず、S601からS617までは図6Aと同様であるため、その説明を割愛し、差分となるS618以降の処理を説明する。 First, since S601 to S617 are the same as those in FIG. 6A, the description thereof will be omitted, and the processing after S618, which is the difference, will be described.

S606におけるサブCPU115によるメインCPU BIOS401の検証の結果、メインCPU BIOS401に何らかの改竄が発見されていた場合、サブCPU115はS618でメインCPU BIOS401の復旧処理を開始する。そしてS619で、タイマ切り替え信号141の信号レベルを初期値であるロウレベルからハイレベルに変更する。これにより、WDT140内のWDT制御部501は、サブCPU115によってCPU BIOS401の復旧処理が開始されたことを認識し、S620で、タイマ503を使ってカウントを開始する。ここでタイマ503は既に説明した通り、サブCPU115によるメインCPU BIOS401の復旧処理が完了するのに必要な時間にマージン時間を加算した値をタイムアウト値として保持している。 As a result of verification of the main CPU BIOS401 by the sub CPU 115 in S606, if any tampering is found in the main CPU BIOS401, the sub CPU 115 starts the recovery process of the main CPU BIOS401 in S618. Then, in S619, the signal level of the timer switching signal 141 is changed from the low level, which is the initial value, to the high level. As a result, the WDT control unit 501 in the WDT 140 recognizes that the recovery process of the CPU BIOS 401 has been started by the sub CPU 115, and starts counting by using the timer 503 in S620. Here, as described above, the timer 503 holds as a timeout value a value obtained by adding a margin time to the time required for the recovery process of the main CPU BIOS 401 by the sub CPU 115 to be completed.

こうしてサブCPU115によるメインCPU BIOS401の復旧処理が滞りなく完了するとS607で、サブCPU115は既に説明した改竄検証終了信号131をリセット回路122へアサートする。更にサブCPU115はS621で、タイマ切り替え信号141をハイレベルからロウレベルへ変更する。これにより、WDT140内のWDT制御部501は、サブCPU115によるCPU BIOS401の復旧処理が完了し、通常動作が開始されたことを認識し、S622で、タイマ502を使ってカウントを再開することができる。 When the restoration process of the main CPU BIOS 401 by the sub CPU 115 is completed without delay, the sub CPU 115 asserts the falsification verification end signal 131 already described to the reset circuit 122 in S607. Further, the sub CPU 115 changes the timer switching signal 141 from the high level to the low level in S621. As a result, the WDT control unit 501 in the WDT 140 recognizes that the recovery process of the CPU BIOS 401 by the sub CPU 115 has been completed and the normal operation has started, and the timer 502 can be used to restart the count in S622. ..

ここで仮にメインCPU BIOS401の復旧処理中に何等かの異常が発生して処理が停止してしまった場合、S620で開始したWDT部140のタイマ503によるカウント値が予め定められたタイムアウト値を超過してしまう。これによりタイムアウトが発生する。こうして一度タイムアウトが発生すると、WDT部140のWDT制御部501は、リセット回路122へ強制システムリセット信号132を出力して、メインCPU101とサブCPU115をリセットするように制御する。リセット回路122によるリセット処理は、予め定められた時間継続し、リセット回路122によるリセットが解除されると、S603以降の動作を再度実施する。 Here, if some abnormality occurs during the recovery process of the main CPU BIOS401 and the process is stopped, the count value by the timer 503 of the WDT unit 140 started in S620 exceeds the predetermined timeout value. Resulting in. This causes a timeout. Once a timeout occurs in this way, the WDT control unit 501 of the WDT unit 140 outputs a forced system reset signal 132 to the reset circuit 122 to control the main CPU 101 and the sub CPU 115 to be reset. The reset process by the reset circuit 122 continues for a predetermined time, and when the reset by the reset circuit 122 is released, the operations after S603 are performed again.

次に、実施形態に係るサブCPU115の詳細な処理手順を図7のフローチャートを参照して説明する。 Next, a detailed processing procedure of the sub CPU 115 according to the embodiment will be described with reference to the flowchart of FIG.

図7は、実施形態に係るサブCPU115の処理を説明するフローチャートである。尚、このフローチャートで示す処理は、CPUコア301がフラッシュROM112からSRAM305に展開したプログラムを実行することにより実現される。 FIG. 7 is a flowchart illustrating the processing of the sub CPU 115 according to the embodiment. The process shown in this flowchart is realized by executing the program expanded from the flash ROM 112 to the SRAM 305 by the CPU core 301.

まずS701でCPUコア301は起動すると直ちにブートROM310内のコードを実行し、SPIバス114を介してフラッシュROM112からサブCPUファームウェア404とFW署名405をSRAM305に読み込む。そして、GPIOポートの初期化を行って改竄検証完了通知信号131とタイマ切り替え信号141を初期状態であるロウレベルにセットする。続いてS702に進みCPUコア301は、暗号/復号処理部308によってFW署名405をOTP304内の公開鍵で復号化して、正解となるハッシュ値を得る。そしてS703に進みCPUコア301は、暗号/復号処理部308によってサブCPUファームウェア404のハッシュ値を計算する。次にS704に進みCPUコア301は、S702で得られたハッシュ値と、S703で計算したハッシュ値とを比較し、これらが不一致の場合は、後に説明するS718へ進む。 First, as soon as the CPU core 301 is started in S701, the code in the boot ROM 310 is executed, and the sub CPU firmware 404 and the FW signature 405 are read into the SRAM 305 from the flash ROM 112 via the SPI bus 114. Then, the GPIO port is initialized, and the falsification verification completion notification signal 131 and the timer switching signal 141 are set to the low level in the initial state. Subsequently, the process proceeds to S702, and the CPU core 301 decrypts the FW signature 405 with the public key in the OTP 304 by the encryption / decryption processing unit 308 to obtain a hash value that is the correct answer. Then, the process proceeds to S703, and the CPU core 301 calculates the hash value of the sub CPU firmware 404 by the encryption / decryption processing unit 308. Next, the process proceeds to S704, and the CPU core 301 compares the hash value obtained in S702 with the hash value calculated in S703, and if they do not match, proceeds to S718, which will be described later.

一方、これが一致した場合はS705に進みCPUコア301は、サブCPUファームウェア404をSRAM305に読み込む。次にS706に進みCPUコア301は、SRAM305に読み込んだサブCPUファームウェア404を実行する。次にS707に進みCPUコア301は、実行したサブCPUファームウェア404の制御に基づき、ROM−ID406をフラッシュROM112からCrypto RAM311に読み込む。そしてS708に進みCPUコア301は、ROM−ID406からメインCPU BIOS401のアドレスとBIOS署名402のアドレスを得る。そしてS709に進みCPUコア301は、BIOS署名402をSRAM305に読み込む。続いてS710に進みCPUコア301は、暗号/復号処理部308によってBIOS署名402をサブCPUファームウェア404に付属している公開鍵で復号化してハッシュ値を得る。次にS711に進みCPUコア301は、メインCPU BIOS401をSRAM305に読み込む。そしてS712に進みCPUコア301は、暗号/復号処理部308によってメインCPU BIOS401のハッシュ値を計算する。そしてS713に進みCPUコア301は、S710で得たハッシュ値とS712で算出したハッシュ値とを比較し、これらが一致した場合はS714に進み、GPIO303を制御して改竄検証完了通知信号131をハイレベルにセットしてS715に進む。一方、これらが不一致の場合はS718へ進む。 On the other hand, if they match, the process proceeds to S705, and the CPU core 301 reads the sub CPU firmware 404 into the SRAM 305. Next, the process proceeds to S706, and the CPU core 301 executes the sub CPU firmware 404 read into the SRAM 305. Next, the process proceeds to S707, and the CPU core 301 reads the ROM-ID 406 from the flash ROM 112 into the Crypt RAM 311 based on the control of the executed sub CPU firmware 404. Then, the process proceeds to S708, and the CPU core 301 obtains the address of the main CPU BIOS 401 and the address of the BIOS signature 402 from the ROM-ID 406. Then, the process proceeds to S709, and the CPU core 301 reads the BIOS signature 402 into the SRAM 305. Subsequently, the process proceeds to S710, and the CPU core 301 decrypts the BIOS signature 402 with the public key attached to the sub CPU firmware 404 by the encryption / decryption processing unit 308 to obtain a hash value. Next, the process proceeds to S711, and the CPU core 301 reads the main CPU BIOS401 into the SRAM 305. Then, the process proceeds to S712, and the CPU core 301 calculates the hash value of the main CPU BIOS 401 by the encryption / decryption processing unit 308. Then, the process proceeds to S713, and the CPU core 301 compares the hash value obtained in S710 with the hash value calculated in S712, and if they match, proceeds to S714, controls GPIO303, and sets the falsification verification completion notification signal 131 to high. Set to level and proceed to S715. On the other hand, if these do not match, the process proceeds to S718.

S715でCPUコア301は、改竄検証完了通知信号131をハイレベルにセットすると、それからタイマ切り替え信号141をロウレベルにセットする。そしてS716でGPIO303を制御してリセット信号をハイレベルで出力する。その後S717でCPUコア301は、電力消費の最も少ないスリープ状態に移行し、その状態を維持する。尚、このスリープ状態では、GPIO303の出力状態を維持している。また、一度スリープ状態に入った後は通常状態に戻る必要はないが、サブCPU115を改竄検証以外の用途にも利用するのであれば、図示しない割り込み信号の受信を許可して通常状態へ復帰させることも可能である。 In S715, the CPU core 301 sets the falsification verification completion notification signal 131 to the high level, and then sets the timer switching signal 141 to the low level. Then, GPIO 303 is controlled by S716 to output a reset signal at a high level. After that, in S717, the CPU core 301 shifts to the sleep state with the least power consumption and maintains that state. In this sleep state, the output state of GPIO 303 is maintained. In addition, it is not necessary to return to the normal state once it goes into the sleep state, but if the sub CPU 115 is used for purposes other than tampering verification, it is allowed to receive an interrupt signal (not shown) and returned to the normal state. It is also possible.

またS704、もしくはS713で不一致の場合はS718に進みCPUコア301は、タイマ切り替え信号141をハイレベルにセットする。その後S719でCPUコア301は、改竄が検出されたデータを、WriteProtect等が施されたセキュアな領域に保持されているGoldenMasterデータで上書きするデータの復旧処理を行う。こうしてサブCPU115によるGoldenMasterデータによる上書き処理が完了すると、S714へ進みサブCPU115による処理の終了シーケンスを実施する。 If there is a mismatch in S704 or S713, the process proceeds to S718, and the CPU core 301 sets the timer switching signal 141 to a high level. After that, in S719, the CPU core 301 performs a data recovery process of overwriting the data for which tampering has been detected with the Golden Master data held in the secure area provided with WriteProtect or the like. When the overwrite process using the Golden Master data by the sub CPU 115 is completed in this way, the process proceeds to S714 and the end sequence of the process by the sub CPU 115 is executed.

尚、実施形態ではGoldenMasterデータによる上書き処理が完了すると、サブCPU115による改竄検証処理が完了するとして説明しているが、上書き処理が完了した後にS701から再度フローを進めることで、より時間を要するが、よりセキュアなブートシーケンスを組むことも可能である。 In the embodiment, it is explained that the falsification verification process by the sub CPU 115 is completed when the overwrite process by the Golden Master data is completed. However, it takes more time by proceeding with the flow again from S701 after the overwrite process is completed. , It is also possible to form a more secure boot sequence.

次に実施形態におけるメインCPU101の処理手順を図8のフローチャートを用いて説明する。 Next, the processing procedure of the main CPU 101 in the embodiment will be described with reference to the flowchart of FIG.

図8は、実施形態に係るMFP1のメインCPU101の処理を説明するフローチャートである。 FIG. 8 is a flowchart illustrating the processing of the main CPU 101 of the MFP 1 according to the embodiment.

メインCPU101はリセットが解除されるとS801で、フラッシュROM112に記憶されたメインCPU BIOS401をDRAM102に読み込む。次にS802に進みメインCPU101は、DRAM102へ読み込んだメインCPU BIOS401を実行し、メインCPU101内の入出力の初期化を行う。次にS803に進みメインCPU101は、HDD108からOS(オペレーティングシステム)をDRAM102に読み込む。読み取り後S804でメインCPU101は、OSを起動する。続いてS805に進みメインCPU101は、プリンタ部105、スキャナ部106、FAX部107、画像処理部111、ネットワークI/F104操作部103を初期化するとともに、WDT140のタイマ502を定期的にクリア制御するソフトウェアを起動し、MFP1として機能可能な状態にする。 When the reset is released, the main CPU 101 reads the main CPU BIOS401 stored in the flash ROM 112 into the DRAM 102 in S801. Next, the process proceeds to S802, and the main CPU 101 executes the main CPU BIOS401 read into the DRAM 102 to initialize the input / output in the main CPU 101. Next, the process proceeds to S803, and the main CPU 101 reads the OS (operating system) from the HDD 108 into the DRAM 102. After reading, the main CPU 101 starts the OS in S804. Subsequently, the process proceeds to S805, and the main CPU 101 initializes the printer unit 105, the scanner unit 106, the FAX unit 107, the image processing unit 111, and the network I / F 104 operation unit 103, and periodically clears and controls the timer 502 of the WDT 140. Start the software and make it functional as MFP1.

次に、実施形態におけるWDT部140の処理手順を図9のフローチャートを用いて説明する。 Next, the processing procedure of the WDT unit 140 in the embodiment will be described with reference to the flowchart of FIG.

図9は、実施形態に係るWDT部140の処理を説明するフローチャートである。 FIG. 9 is a flowchart illustrating the processing of the WDT unit 140 according to the embodiment.

WDT部140は、電源の供給が始まるとS901でタイマ502を起動し、カウントを開始する。次にS902に進みWDT部140は、改竄検証完了通知信号131を監視して、改竄検証が完了したか否かを判定する。ここで改竄検証が完了していた場合はS903に進み、タイマ502によるカウントを選択してタイマ502によるカウントを開始し、タイマ503の動作を停止してS910に進む。このときタイマ502は、メインCPU101が適切に動作していることを確認できる所定時間を計時し、その所定時間内にクリア制御が実行されないとS911でタイムアウトになることになる。 When the power supply starts, the WDT unit 140 starts the timer 502 in S901 and starts counting. Next, the process proceeds to S902, and the WDT unit 140 monitors the falsification verification completion notification signal 131 to determine whether or not the falsification verification has been completed. If the falsification verification has been completed, the process proceeds to S903, the count by the timer 502 is selected, the count by the timer 502 is started, the operation of the timer 503 is stopped, and the process proceeds to S910. At this time, the timer 502 clocks a predetermined time during which it can be confirmed that the main CPU 101 is operating properly, and if the clear control is not executed within the predetermined time, the timer 502 will time out in S911.

一方、で改竄検証が完了していなかった場合はS904に進み、サブCPU115からのタイマ切り替え信号141がハイレベルであるか否か判定する。ハイレベルであればS907に進んでタイマ503によるカウントを実施中であるか否かを判定する。ここでタイマ503によるカウントを実施していない場合はS908に進み、タイマ503によるカウントを開始するとともに、タイマ502による計時を止める。 On the other hand, if the falsification verification is not completed in, the process proceeds to S904, and it is determined whether or not the timer switching signal 141 from the sub CPU 115 is at a high level. If it is a high level, the process proceeds to S907 to determine whether or not counting by the timer 503 is being performed. Here, if the counting by the timer 503 is not performed, the process proceeds to S908, the counting by the timer 503 is started, and the time counting by the timer 502 is stopped.

一方、S904でタイマ切り替え信号141がロウレベルであった場合S905に進み、タイマ502がタイムアウトしたかどうか判定する。タイマ502がタイムアウトしたときはS906に進み、強制システムリセット信号132を出力して、この処理を終える。一方、S905でタイマ502がタイムアウトしていない場合はS902に進んでカウントを継続する。 On the other hand, if the timer switching signal 141 is at a low level in S904, the process proceeds to S905 to determine whether the timer 502 has timed out. When the timer 502 times out, the process proceeds to S906, a forced system reset signal 132 is output, and this process is completed. On the other hand, if the timer 502 has not timed out in S905, the process proceeds to S902 to continue counting.

またS907でタイマ503によるカウント中であった場合はS909に進み、タイマ503がタイムアウトしたかどうか判定する。タイマ503がタタイムアウトした場合はS906に進み、強制システムリセット信号132を出力して、この処理を終える。またS909でタイマ503がタイムアウトしていない場合はS902に進んで、カウントを継続する。 If the timer 503 is counting in S907, the process proceeds to S909 to determine whether the timer 503 has timed out. When the timer 503 has timed out, the process proceeds to S906, a forced system reset signal 132 is output, and this process is completed. If the timer 503 has not timed out in S909, the process proceeds to S902 to continue counting.

S910では、サブCPU115による改竄検証処理が完了し、タイマ502によるカウントが開始され、またメインCPU101の起動が開始されている。よってWDT部140は、WDT制御部501に実装されるWDTクリアレジスタに「1」が書き込まれた否かを判定する。ここでWDTクリアレジスタが「1」に設定されていた場合はS912に進み、タイマ502のカウント値をクリアし、タイマ502によるカウントを再開する。一方、WDTクリアレジスタが「0」であった場合はS911に進み、タイマ502がタイムアウトしたかどうかを判定する。ここでタイムアウトしていた場合はS906に進み、強制システムリセット信号132を出力して、この処理を終える。一方S911で、タイマ502がタイムアウトしていない場合はS910に進み、タイマ502によるカウントを継続する。 In S910, the falsification verification process by the sub CPU 115 is completed, the counting by the timer 502 is started, and the activation of the main CPU 101 is started. Therefore, the WDT unit 140 determines whether or not "1" is written in the WDT clear register mounted on the WDT control unit 501. If the WDT clear register is set to "1", the process proceeds to S912, the count value of the timer 502 is cleared, and the count by the timer 502 is restarted. On the other hand, if the WDT clear register is "0", the process proceeds to S911, and it is determined whether or not the timer 502 has timed out. If the time-out has occurred here, the process proceeds to S906, the forced system reset signal 132 is output, and this process ends. On the other hand, in S911, if the timer 502 has not timed out, the process proceeds to S910 and the counting by the timer 502 is continued.

以上のように制御することで、サブCPUによるプログラムの改竄検証処理の結果、改竄が発生したと判定し、GoldenMasterデータを使った復旧処理を行う間、WDTによる強制システムリセットの出力を防止できる。そして復旧処理後、メインCPUが正常に起動すると、メインCPUによってWDT(タイマ502)が制御されるためMFPを適切に制御できるようになる。 By controlling as described above, it is possible to determine that falsification has occurred as a result of the falsification verification process of the program by the sub CPU, and prevent the output of the forced system reset by the WDT while performing the recovery process using the GoldenMaster data. Then, when the main CPU starts normally after the recovery process, the WDT (timer 502) is controlled by the main CPU, so that the MFP can be appropriately controlled.

またサブCPUによるプログラムの改竄検証処理の結果、プログラムの改竄が発生していない、即ちプログラムの異常が検知されないときは、タイマ502によるウオッチドッグタイマ機能が実行され、メインCPUが正常に動作している限り、タイマ502がタイムアウトすることによる強制システムリセット信号が出力されることはない。 Further, as a result of the program tampering verification processing by the sub CPU, when the program tampering has not occurred, that is, when the program abnormality is not detected, the watchdog timer function by the timer 502 is executed and the main CPU operates normally. As long as the timer 502 times out, the forced system reset signal is not output.

次に、本実施形態におけるリセット回路122の処理手順を図10のフローチャートを用いて説明する。 Next, the processing procedure of the reset circuit 122 in this embodiment will be described with reference to the flowchart of FIG.

図10は、実施形態に係るリセット回路122による処理を説明するフローチャートである。 FIG. 10 is a flowchart illustrating processing by the reset circuit 122 according to the embodiment.

リセット回路122は電源の供給が始まるとS1001で、リセット信号123をハイレベルにしてサブCPU115のリセットを解除する。次にS1002で、改竄検証完了通知信号131がハイレベルになったか否かを判定する。ここで改竄検証完了通知信号131がハイレベルになって改竄の検証が成功、即ち、正常に終了したと判定したときはS1003に進む。S1003でリセット回路122は、リセット信号117をハイレベルにしてメインCPU101のリセットを解除して、この処理を終了する。 When the supply of power is started, the reset circuit 122 sets the reset signal 123 to a high level in S1001 to release the reset of the sub CPU 115. Next, in S1002, it is determined whether or not the falsification verification completion notification signal 131 has reached a high level. Here, when the falsification verification completion notification signal 131 becomes high level and it is determined that the falsification verification is successful, that is, that the falsification verification is completed normally, the process proceeds to S1003. In S1003, the reset circuit 122 sets the reset signal 117 to a high level, releases the reset of the main CPU 101, and ends this process.

一方、S1002で改竄検証完了通知信号131がハイレベルにならず、改竄検証が継続中の場合はS1004に進み、WDT部140が強制システムリセット信号132が入力されて、強制システムリセットを実行するように制御されたか否かを判定する。リセット回路122は、強制システムリセット信号132が入力されると、何らかの異常が発生して処理が停止しているとみなして、メインCPU101とサブCPU115をリセットして処理を終える。一方、S1004で強制システムリセット信号132が入力されていないときはS1002へ戻り処理を継続する。 On the other hand, if the falsification verification completion notification signal 131 does not reach the high level in S1002 and the falsification verification is continuing, the process proceeds to S1004, and the WDT unit 140 receives the forced system reset signal 132 to execute the forced system reset. Judges whether or not it is controlled by. When the forced system reset signal 132 is input, the reset circuit 122 considers that some abnormality has occurred and the process has stopped, resets the main CPU 101 and the sub CPU 115, and ends the process. On the other hand, when the forced system reset signal 132 is not input in S1004, the system returns to S1002 and the processing is continued.

このように制御することにより、WDT部140でタイムアウトが発生した場合、速やかにCPU101とサブCPU115をリセットすることができる。ここで、リセットするのはメインCPU101とサブCPU115と説明してきたが、関連する機能モジュール、もしくはMFP1全体をリセットしてしまっても問題無いことは言うまでもない。 By controlling in this way, when a timeout occurs in the WDT unit 140, the CPU 101 and the sub CPU 115 can be quickly reset. Here, the main CPU 101 and the sub CPU 115 have been described as resetting, but it goes without saying that there is no problem even if the related functional modules or the entire MFP1 are reset.

以上説明したように実施形態によれば、サブCPUが実行期間が長い復旧処理を実行する場合でも、不必要なリセット実行を回避することできるようになる。更に、プログラムの改竄を検証している間にサブCPUに何らかの問題が発生して処理が停止してしまった場合でも、WDTによって適切にリカバリ動作を実行できるようになる。 As described above, according to the embodiment, even when the sub CPU executes the recovery process having a long execution period, it is possible to avoid unnecessary reset execution. Further, even if a problem occurs in the sub CPU and the process is stopped while verifying the falsification of the program, the WDT can appropriately execute the recovery operation.

また、サブCPUが、メインCPUをリセット状態に保ちながらプログラムの改竄を検証する際、その検証に要する時間が、所定時間よりも長くなるとWDTからのタイムアウトによるリセット制御が実行される。これにより、検証中のサブCPUの異常も検出できる。 Further, when the sub CPU verifies the falsification of the program while keeping the main CPU in the reset state, if the time required for the verification becomes longer than the predetermined time, the reset control due to the timeout from the WDT is executed. Thereby, the abnormality of the sub CPU under verification can be detected.

さらに、サブCPUがプログラムの改竄を検証して異常(改竄)を検出すると、検証に要する時間を計時していた第1タイマに代わって、プログラムの復旧処理に要る時間を計時する第2タイマによる計時を行うことで、サブCPUによるプログラムの復旧処理中に、WDTからのタイムアウトによるリセット制御の発生を防止できる。 Further, when the sub CPU verifies the tampering of the program and detects an abnormality (tampering), the second timer that clocks the time required for the program recovery process replaces the first timer that clocks the time required for verification. By performing the time counting according to the above, it is possible to prevent the occurrence of reset control due to a timeout from the WDT during the program recovery process by the sub CPU.

尚、実施形態で記載した信号の極性はシステムの定めに応じて変更してもよいことは言うまでもない。 Needless to say, the polarity of the signal described in the embodiment may be changed according to the system.

また実施形態では、WDT部140、及びリセット回路122を電源制御部118の内部に含む構成を代表例として説明したが、これに限らず、それぞれが信号バス109に接続された形態をとってもよい。 Further, in the embodiment, the configuration in which the WDT unit 140 and the reset circuit 122 are included in the power supply control unit 118 has been described as a typical example, but the present invention is not limited to this, and each may be connected to the signal bus 109.

また実施形態で説明した構成要素の一部がSOC(System On Chip)に集積された場合でも、サブCPU115がメインCPU101の起動を制御しつつ、メインCPU BIOS401の改竄検証を行う場合に、実施形態が適用できることは言うまでもない。 Further, even when some of the components described in the embodiment are integrated in the SOC (System On Chip), when the sub CPU 115 controls the activation of the main CPU 101 and verifies the falsification of the main CPU BIOS 401, the embodiment Needless to say, is applicable.

また実施形態は、タイマ503を省略し、サブCPU115による復旧処理中はタイマを動作させないという形態をとることで、より少ない回路規模で不要なリセット処理を回避できる。しかしながら、この場合、復旧処理中に何らかの異常が発生した場合の検知ができなくなるため、本実施形態に記載した構成のように2つのタイマを備えた構成とするのが望ましい。 Further, in the embodiment, the timer 503 is omitted and the timer is not operated during the restoration process by the sub CPU 115, so that unnecessary reset processing can be avoided with a smaller circuit scale. However, in this case, if any abnormality occurs during the recovery process, it cannot be detected. Therefore, it is desirable to have a configuration including two timers as in the configuration described in the present embodiment.

(その他の実施形態)
本発明は、上述の実施形態の1以上の機能を実現するプログラムを、ネットワーク又は記憶媒体を介してシステム又は装置に供給し、そのシステム又は装置のコンピュータにおける1つ以上のプロセッサがプログラムを読出し実行する処理でも実現可能である。また、1以上の機能を実現する回路(例えば、ASIC)によっても実現可能である。
(Other embodiments)
The present invention supplies a program that realizes one or more functions of the above-described embodiment to a system or device via a network or storage medium, and one or more processors in the computer of the system or device reads and executes the program. It can also be realized by the processing to be performed. It can also be realized by a circuit (for example, ASIC) that realizes one or more functions.

本発明は上記実施形態に制限されるものではなく、本発明の精神及び範囲から逸脱することなく、様々な変更及び変形が可能である。従って、本発明の範囲を公にするために、以下の請求項を添付する。 The present invention is not limited to the above embodiments, and various modifications and modifications can be made without departing from the spirit and scope of the present invention. Therefore, in order to make the scope of the present invention public, the following claims are attached.

1…MFP,101…メインCPU、112…フラッシュROM、115…サブCPU、118…電源制御部、122…リセット回路、140…WDT部、501…WDT制御部、502,503…タイマ、131…改竄検証完了通知信号、132…強制システムリセット信号、141…タイマ切り替え信号 1 ... MFP, 101 ... Main CPU, 112 ... Flash ROM, 115 ... Sub CPU, 118 ... Power supply control unit, 122 ... Reset circuit, 140 ... WDT unit, 501 ... WDT control unit, 502, 503 ... Timer, 131 ... Tampering Verification completion notification signal, 132 ... forced system reset signal, 141 ... timer switching signal

Claims (11)

情報処理装置であって、
プログラムを実行して前記情報処理装置を制御する第1CPUと、
前記プログラムを検証する第2CPUと、
前記情報処理装置の動作中に計時を行い、当該計時のクリア制御が第1所定時間内に行われない場合にリセット信号を出力する第1タイマ手段と、
前記第2CPUが前記プログラムの検証で異常を検知したときに計時を行い、当該計時のクリア制御が第2所定時間内に行われない場合にリセット信号を出力する第2タイマ手段と、
前記第1タイマ手段及び前記第2タイマ手段からのリセット信号に基づいて前記第1CPU及び前記第2CPUへのリセット信号を生成するリセット手段と、を有し、
前記第2CPUは、前記プログラムの検証で異常を検知すると前記第1タイマ手段による計時を停止させ、前記第2タイマ手段による計時を開始させて前記プログラムの復旧処理を行うことを特徴とする情報処理装置。
It is an information processing device
A first CPU that executes a program and controls the information processing device,
The second CPU that verifies the program and
A first timer means that measures time during the operation of the information processing device and outputs a reset signal when the clear control of the time is not performed within the first predetermined time.
A second timer means that measures the time when the second CPU detects an abnormality in the verification of the program and outputs a reset signal when the clear control of the time is not performed within the second predetermined time.
It has a reset means for generating a reset signal to the first CPU and the second CPU based on the reset signal from the first timer means and the second timer means.
Information processing characterized in that, when the second CPU detects an abnormality in the verification of the program, the time counting by the first timer means is stopped, the time counting by the second timer means is started, and the recovery process of the program is performed. apparatus.
前記第1所定時間は、前記第2CPUが前記プログラムの検証に要する時間に、前記第1CPUが起動してから前記第1タイマ手段のクリア制御が実施可能になるまでの時間を加算し、更に、マージン時間を追加した時間であることを特徴とする請求項1に記載の情報処理装置。 In the first predetermined time, the time required for the second CPU to verify the program is added to the time from the start of the first CPU until the clear control of the first timer means can be performed, and further. The information processing apparatus according to claim 1, wherein the time is an addition of a margin time. 前記第2所定時間は、前記復旧処理が完了するのに必要な時間にマージン時間を加算した時間であることを特徴とする請求項1又は2に記載の情報処理装置。 The information processing apparatus according to claim 1 or 2, wherein the second predetermined time is a time obtained by adding a margin time to the time required to complete the recovery process. 前記リセット信号は、少なくとも前記第1CPUと前記第2CPUをリセットする信号であることを特徴とする請求項1に記載の情報処理装置。 The information processing apparatus according to claim 1, wherein the reset signal is at least a signal for resetting the first CPU and the second CPU. 前記リセット手段は、前記第2CPUが前記プログラムの検証を実行している間、前記第1CPUをリセットし、前記第2CPUが前記プログラムの検証で異常を検知しないときは前記第1CPUのリセットを解除することを特徴とする請求項1乃至4のいずれか1項に記載の情報処理装置。 The reset means resets the first CPU while the second CPU is executing the verification of the program, and releases the reset of the first CPU when the second CPU does not detect an abnormality in the verification of the program. The information processing apparatus according to any one of claims 1 to 4. 前記第2CPUは、前記プログラムのハッシュ値に基づいて前記プログラムを検証することを特徴とする請求項1乃至5のいずれか1項に記載の情報処理装置。 The information processing apparatus according to any one of claims 1 to 5, wherein the second CPU verifies the program based on a hash value of the program. 第1CPUと、
前記第1CPUが実行するプログラムを検証する第2CPUと、
第1タイマと第2タイマとを有し、当該第1タイマ或いは前記第2タイマの計時に対するリセット制御が所定時間内に行われない場合に、前記第1CPU及び前記第2CPUをリセットするリセット信号を出力するタイマ手段と、を有し、
前記タイマ手段は、前記第2CPUが前記プログラムの検証で異常を検知したときに前記第1タイマによる計時を停止させて前記第2タイマにより計時を行い、前記第2タイマが第1所定時間を計時してタイムアウトすると前記リセット信号を出力することを特徴とする情報処理装置。
With the first CPU
A second CPU that verifies the program executed by the first CPU,
A reset signal for resetting the first CPU and the second CPU when the first timer and the second timer are provided and the reset control for the timing of the first timer or the second timer is not performed within a predetermined time. Has a timer means to output,
When the second CPU detects an abnormality in the verification of the program, the timer means stops the time counting by the first timer and uses the second timer to measure the time, and the second timer measures the first predetermined time. An information processing device characterized in that the reset signal is output when the time-out occurs.
前記タイマ手段は、前記第2CPUによる前記プログラムの検証に要する時間を前記第1タイマにより計時させ、前記第1タイマの計時が第2所定時間を超えてタイムアウトすると前記リセット信号を出力することを特徴とする請求項7に記載の情報処理装置。 The timer means is characterized in that the time required for verification of the program by the second CPU is timed by the first timer, and when the time of the first timer times out beyond the second predetermined time, the reset signal is output. The information processing apparatus according to claim 7. 前記タイマ手段は、前記第2CPUが前記プログラムの検証に成功したときは、前記第2タイマによる計時を停止させて、前記第1タイマによる前記第1CPUの動作を検証するための計時を開始させることを特徴とする請求項7又は8に記載の情報処理装置。 When the second CPU succeeds in verifying the program, the timer means stops the time counting by the second timer and starts the time counting for verifying the operation of the first CPU by the first timer. The information processing apparatus according to claim 7 or 8. 前記第1タイマによる前記第1CPUの動作を検証するための計時では、前記第1CPUは所定時間ごとに前記第1タイマのリセット制御を行うことを特徴とする請求項9に記載の情報処理装置。 The information processing apparatus according to claim 9, wherein when the timekeeping for verifying the operation of the first CPU by the first timer is performed, the first CPU performs reset control of the first timer at predetermined time intervals. 前記第1所定時間は、前記プログラムの復旧処理が完了するのに必要な時間にマージン時間を加算した時間であることを特徴とする請求項7乃至10のいずれか1項に記載の情報処理装置。 The information processing apparatus according to any one of claims 7 to 10, wherein the first predetermined time is a time obtained by adding a margin time to the time required to complete the recovery process of the program. ..
JP2019219857A 2019-12-04 2019-12-04 Information processing apparatus Pending JP2021089607A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2019219857A JP2021089607A (en) 2019-12-04 2019-12-04 Information processing apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2019219857A JP2021089607A (en) 2019-12-04 2019-12-04 Information processing apparatus

Publications (1)

Publication Number Publication Date
JP2021089607A true JP2021089607A (en) 2021-06-10

Family

ID=76220177

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2019219857A Pending JP2021089607A (en) 2019-12-04 2019-12-04 Information processing apparatus

Country Status (1)

Country Link
JP (1) JP2021089607A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2022249820A1 (en) 2021-05-27 2022-12-01 京セラ株式会社 Communication control method, wireless terminal, base station, and ris device

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2022249820A1 (en) 2021-05-27 2022-12-01 京セラ株式会社 Communication control method, wireless terminal, base station, and ris device

Similar Documents

Publication Publication Date Title
US11657125B2 (en) Information processing apparatus and reset control method
US11006013B2 (en) Image processing apparatus, having second processor to verify boot program has been altered, method of controlling the same, and storage medium
US20210011660A1 (en) Information processing apparatus and control method
JP2020177539A (en) Information processing device and control method thereof
US11418671B2 (en) Information processing apparatus, and method of controlling the same
JP2021089607A (en) Information processing apparatus
JP7321795B2 (en) Information processing device, information processing method and program
JP2013041458A (en) Data processing apparatus and control method therefor
US20220321724A1 (en) Information processing apparatus and method of notifying verification result of program
JP6590722B2 (en) Electronic device, control method thereof, and program
JP2008229977A (en) Image processor, image processing method, program, and recording medium
JP7210238B2 (en) Information processing device, control method for information processing device, and program
JP2020187649A (en) Information processing system, control method, and program
US20230273798A1 (en) Information processing apparatus and method for controlling information processing apparatus
JP2023167086A (en) Information processing apparatus and control method of information processing apparatus
JP7465107B2 (en) Information processing device and method
JP2021051713A (en) Information processing apparatus and reset control method
JP2022182838A (en) Information processing device and control method thereof
JP2021111916A (en) Information processing device and program restoration method
JP2023167825A (en) Information processing device, and control method for information processing device
JP2020102129A (en) Information processing device, control method of information processing device, and program
JP2023124500A (en) Information processing apparatus, method for controlling information processing apparatus, and program
JP2023124088A (en) Information processor and control method thereof
JP6291983B2 (en) Recovery device and recovery method
JP2022066083A (en) Information processing apparatus

Legal Events

Date Code Title Description
RD01 Notification of change of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7421

Effective date: 20210103

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20210113