JP7011637B2 - Illegal signal detection device - Google Patents
Illegal signal detection device Download PDFInfo
- Publication number
- JP7011637B2 JP7011637B2 JP2019190291A JP2019190291A JP7011637B2 JP 7011637 B2 JP7011637 B2 JP 7011637B2 JP 2019190291 A JP2019190291 A JP 2019190291A JP 2019190291 A JP2019190291 A JP 2019190291A JP 7011637 B2 JP7011637 B2 JP 7011637B2
- Authority
- JP
- Japan
- Prior art keywords
- signal
- determination unit
- input
- predetermined range
- predetermined
- 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.)
- Active
Links
Images
Description
本発明は、通信網に入力される不正な信号を検出する不正信号検出装置に関する。 The present invention relates to an illegal signal detection device that detects an illegal signal input to a communication network.
従来、データ信号の受信間隔に基づいて不正な信号を検出するようにした装置が知られている(例えば特許文献1参照)。この特許文献1記載の装置は、データ信号の受信間隔を、予め設定された正規のデータ信号の送受信間隔と比較することで、所定の時期以外に受信したデータ信号を不正な信号と判定するように構成される。
Conventionally, there are known devices that detect an invalid signal based on a data signal reception interval (see, for example, Patent Document 1). The apparatus described in
しかしながら、特許文献1記載の装置では、一定の周期で送信される正常な信号と不定期に送信される正常な信号とが混在する状況では、不正な信号を検出することが難しい。
However, in the apparatus described in
本発明の一態様である不正信号検出装置は、互いに同一の識別子を有する第1信号と第2信号とが入力される通信網に、同一の識別子を有する不正信号が入力されたことを検出する。第1信号は、所定状態が継続しているときに所定周期で入力される正常信号であり、第2信号は、所定状態が他の状態に変化するときに入力される正常信号である。不正信号検出装置は、通信網に入力された連続する複数の信号間の時間間隔を時系列に計測する計測部と、計測部により計測された時間間隔を時系列に記憶する記憶部と、計測部により計測された時間間隔が第1所定値以上かつ第2所定値以下の所定範囲内であるか否かを判定する第1判定部と、第1判定部により、計測部により計測された時間間隔が所定範囲内でないと判定されると、計測部により計測された時間間隔と記憶部に記憶された時間間隔との和が第1所定値以上となるまで、記憶部に記憶された時間間隔を新しい順に順次加算して、加算後の合計時間を算出する算出部と、算出部により算出された合計時間が所定範囲内であるか否かを判定する第2判定部と、通信網に入力された信号の種別を判定する信号種別判定部と、を備える。信号種別判定部は、第1判定部により、計測部により計測された時間間隔が所定範囲内であると判定されると、第1信号が入力されたと判定し、第2判定部により、算出部により算出された合計時間が所定範囲内であると判定されると、不正信号が入力されたと判定し、第2判定部により、算出部により算出された合計時間が所定範囲内でないと判定されると、第2信号が入力されたと判定する。 The fraudulent signal detection device according to one aspect of the present invention detects that a fraudulent signal having the same identifier is input to a communication network in which a first signal and a second signal having the same identifier are input. .. The first signal is a normal signal input at a predetermined cycle while the predetermined state continues, and the second signal is a normal signal input when the predetermined state changes to another state. The fraudulent signal detection device has a measurement unit that measures the time interval between a plurality of consecutive signals input to the communication network in time series, and a storage unit that stores the time interval measured by the measurement unit in time series. The time measured by the measurement unit by the first determination unit and the first determination unit, which determines whether or not the time interval measured by the unit is within the predetermined range of the first predetermined value or more and the second predetermined value or less. If it is determined that the interval is not within the predetermined range, the time interval stored in the storage unit is stored until the sum of the time interval measured by the measuring unit and the time interval stored in the storage unit becomes the first predetermined value or more. Are sequentially added in the order of newest, and the calculation unit that calculates the total time after addition, the second determination unit that determines whether the total time calculated by the calculation unit is within the predetermined range, and the communication network are input. It is provided with a signal type determination unit for determining the type of the signal. When the signal type determination unit determines that the time interval measured by the measurement unit is within a predetermined range by the first determination unit, the signal type determination unit determines that the first signal has been input, and the second determination unit determines that the calculation unit. If it is determined that the total time calculated by the calculation unit is within the predetermined range, it is determined that an invalid signal has been input, and the second determination unit determines that the total time calculated by the calculation unit is not within the predetermined range. , It is determined that the second signal has been input.
本発明によれば、一定の周期で送信される正常な信号と不定期に送信される正常な信号とが混在する状況で不正な信号を検出することができる。 According to the present invention, an illegal signal can be detected in a situation where a normal signal transmitted at a fixed cycle and a normal signal transmitted irregularly are mixed.
以下、図1~図6を参照して本発明の実施形態について説明する。本発明の実施形態に係る不正信号検出装置は、一定の周期で送信される正常な信号と不定期に送信される正常な信号とが混在する通信網に適用することができる。以下では特に、CAN(コントローラエリアネットワーク)通信線等のシリアル通信線を介して車両の動作を制御するECU(電子制御ユニット)が接続された車載通信網に適用する例を説明する。 Hereinafter, embodiments of the present invention will be described with reference to FIGS. 1 to 6. The fraudulent signal detection device according to the embodiment of the present invention can be applied to a communication network in which normal signals transmitted at regular intervals and normal signals transmitted irregularly are mixed. In particular, an example of application to an in-vehicle communication network to which an ECU (electronic control unit) for controlling the operation of a vehicle via a serial communication line such as a CAN (controller area network) communication line will be described will be described below.
図1は、本発明の実施形態に係る不正信号検出装置が適用される通信網の構成の一例を概略的に示す図であり、一例として、車両1に搭載された車載通信網(以下、通信網)100を示す。図1に示すように、車両1には複数(図では4個)のECU2が搭載される。複数のECU2には、エンジン制御用ECU、変速機制御用ECU、操舵制御用ECUなどの車両の動作に直接的な影響を与えるECU、エアコンやナビゲーションなどの車両の動作に直接的な影響を与えない機器の制御用ECU等、機能の異なるECUが含まれる。
FIG. 1 is a diagram schematically showing an example of a communication network configuration to which an unauthorized signal detection device according to an embodiment of the present invention is applied. As an example, an in-vehicle communication network mounted on a vehicle 1 (hereinafter, communication). Net) 100 is shown. As shown in FIG. 1, a plurality of (4 in the figure)
各ECU2は、CAN通信線等の通信線10を介して互いに通信可能に接続されて通信網100を構成する。各ECU2は、演算処理を行うCPU,ROM,RAM、その他の周辺回路を有するコンピュータを含んで構成される。各ECU2は、予めメモリに記憶されたプログラムに従い、各種センサや他のECU2からの信号等に基づいて各種制御を実行する。
Each
各ECU2にはさらに、通信線10を介して、外部との無線通信を行うTCU(テレマティクス制御ユニット)3、車両1の故障診断やECU2のプログラムの更新を行う診断機を接続可能なDLC(データリンクコネクタ)4が接続される。各ECU2、TCU3およびDLC4の間にはGW(ゲートウェイ)5が設けられ、通信網100と車外との通信あるいは複数の通信線10間の通信を中継する。
DLC (data) capable of connecting a TCU (telematics control unit) 3 that performs wireless communication with the outside and a diagnostic device that diagnoses a failure of the
各ECU2やTCU3、DLC4を介して接続された診断機等は、送信側ノードとして、送信元やデータ種別等の識別情報を示すIDを付したデータ信号を通信網100に入力する。また、受信側ノードとして、通信網100に入力されたデータ信号のうち、予め自身が受信すべきものとして設定されたIDが付されたデータ信号のみを受信する。また、GW5は、通信網100に入力された各データ信号をIDに基づいて中継する。
A diagnostic device or the like connected via each
通信網100に入力される正規のデータ信号には、互いに同一のIDが付された、一定の周期で入力される周期信号と、不定期に入力されるイベント信号とが含まれる。例えば、特定のスイッチの状態を示す周期信号は、スイッチの切り換え操作がなく、オン、オフ等の所定状態が継続しているときに、予め定められた規定周期T(例えば、200ms)毎に通信網100に入力される。また、特定のスイッチの状態を示すイベント信号は、スイッチの切り換え操作があり、スイッチのオン、オフ等の状態が変化するときに入力される。このような信号には、特定のスイッチの状態を示す信号の他、特定のセンサ値やコマンド値等の状態を示す信号等が含まれる。
The regular data signal input to the
図2は、通信網100に入力される正規のデータ信号について説明するための図であり、互いに同一のIDが付された周期信号およびイベント信号の一例を示す。図2に示すように、イベント信号は、スイッチの状態が例えばオフ状態からオン状態に変化すると通信網100に入力される。一方、各周期信号は、スイッチの状態が変化しないと、前回の周期信号の入力から規定周期T後に入力され、スイッチの状態が変化してイベント信号が入力されると、イベント信号の入力から規定周期T後に入力される。
FIG. 2 is a diagram for explaining a regular data signal input to the
ところで、通信網100に対しては、悪意のある第三者が不正信号を入力することがある。例えば、正規のデータ信号に付されるIDを付した不正信号(なりすまし信号)を大量に入力して正規信号の送受信を妨害する、いわゆるDoS攻撃(Denial of Service attack)が行われることがある。
By the way, a malicious third party may input an unauthorized signal to the
通信網100に周期信号のみが入力される場合は、連続して入力された信号間の時間間隔をID毎の規定周期Tと比較することで不正信号を検出することができる。しかしながら、通信網100に同一IDの周期信号とイベント信号とが入力される場合は、同様の手法により不正信号を検出することが難しい。そこで、本実施形態では、通信網100に同一IDの周期信号とイベント信号とが入力される場合でも不正信号を検出できるよう、以下のように不正信号検出装置を構成する。
When only a periodic signal is input to the
図3は、本発明の実施形態に係る不正信号検出装置の要部構成を示すブロック図であり、一例として、通信網100に入力されたデータ信号を中継するGW5(図1)が不正信号検出装置として機能する場合を示す。図3に示すように、GW5は、CPU等の演算部50と、ROM,RAM等の記憶部51と、その他の周辺回路とを有するコンピュータを含んで構成される。演算部50は、機能的構成として、検出部52と、計測部53と、判定部54と、算出部55とを有する。
FIG. 3 is a block diagram showing a main configuration of the fraudulent signal detection device according to the embodiment of the present invention. As an example, the GW 5 (FIG. 1) relaying a data signal input to the
検出部52は、通信網100に入力された全てのデータ信号および各データ信号に付されたIDを検出する。すなわち、各ECU2やTCU3、DLC4を介して接続された診断機から入力される正規信号だけでなく、改ざんされたECUや通信網100に挿入された不正な外部機器から入力される不正信号を含む、あらゆるデータ信号とそのIDを検出する。
The
図4は、検出部52により検出されるデータ信号の一例を模式的に示す図であり、特定のIDが付されたデータ信号のみを示す。図4の例では、時刻t0から時刻t11にかけて、互いに同一のIDが付された11個のデータ信号が検出される。
FIG. 4 is a diagram schematically showing an example of a data signal detected by the
計測部53は、特定のIDが付された、連続する複数のデータ信号間の時間間隔を時系列に計測する。具体的には、検出部52により特定のIDが付されたデータ信号が検出される度にタイマによる計時を行い、前回の検出時刻tn-1から今回の検出時刻tnまでの時間間隔Tnを計測する。図4の例では、時刻t0から時刻t11にかけて11個の時間間隔T1~T11が計測される。
The measuring
計測部53により計測された時間間隔Tnは、記憶部51のバッファ領域にバッファ値として時系列に記憶される。図4に示すように、記憶部51には、データ信号のID毎に、正常な状態における最大の通信頻度を考慮して設定された所定数のバッファ領域が設けられる。例えば、200msの規定周期Tにわたり、10ms間隔のデータ信号が継続して入力されるような状態に対応する20個(図4では5個のみ示す)のバッファ領域が設けられる。これにより記憶部51には、データ信号のID毎に所定数までのバッファ値(時間間隔Tn)を記憶することができる。バッファ領域を所定数に制限することで、DoS攻撃等によって過剰にバッファ値が蓄積されることを防止することができる。
The time interval T n measured by the measuring
図3の判定部54は、記憶部51に記憶されたバッファ値(時間間隔Tn)に基づいて、通信網100に入力されたデータ信号の信号種別を判定する。具体的には、連続する正規信号間の規定周期T内にデータ信号の割込みがあったか否かを判定する第1判定と、割り込んだデータ信号が正規のイベント信号であるか不正信号であるかを判定する第2判定とを行うことで、信号種別を判定する。
The
判定部54は、第1判定として、記憶部51に記憶された最新のバッファ値(以下、最新バッファ値)Tnが規定周期Tと一致するか否かを判定する。具体的には、最新バッファ値Tnが規定周期Tを基準とする所定範囲内であるか否かを判定する。換言すると、最新バッファ値Tnが所定範囲の下限値(T-Th)以上かつ上限値(T+Th)以下であるか否かを判定する。最新バッファ値Tnが規定周期Tに一致すると判定されると、規定周期T内にデータ信号の割込みがなく、時刻tnにおいて正規の周期信号が検出されたと判定される。
As the first determination, the
より具体的には、先ず、最新バッファ値Tnが、通信調停等、他の通信の影響を考慮して設定された第1所定範囲内(例えば、±5%以内)であるか否かを判定する。すなわち、最新バッファ値Tnが第1所定範囲の下限値(T-Th1)以上かつ上限値(T+Th1)以下であるか否かを判定する。最新バッファ値Tnが第1所定範囲内であると判定されると、規定周期T内にデータ信号の割込みがなく、時刻tnにおいて正規の周期信号が検出されたと判定され、記憶部51のバッファ領域に記憶された全てのバッファ値がクリアされる。
More specifically, first, whether or not the latest buffer value T n is within the first predetermined range (for example, within ± 5%) set in consideration of the influence of other communication such as communication arbitration. judge. That is, it is determined whether or not the latest buffer value T n is equal to or greater than the lower limit value (T—Th 1 ) and equal to or less than the upper limit value (T + Th 1 ) in the first predetermined range. When it is determined that the latest buffer value T n is within the first predetermined range, it is determined that there is no data signal interrupt within the specified period T and a normal periodic signal is detected at time t n , and the
最新バッファ値Tnが第1所定範囲内でないと判定されると、さらに、第2所定範囲内(例えば、±20%以内)であるか否かを判定する。すなわち、第2所定範囲の下限値(T-Th2)以上かつ第1所定範囲の下限値(T-Th1)未満、または、第1所定範囲の上限値(T+Th1)より大きく第2所定範囲の上限値(T+Th2)以下であるか否かを判定する。この判定で肯定される場合は、規定周期Tの通信に正規のイベント信号が入力された可能性や、何らかの理由で通信周期が変化した可能性等が考えられるため、記憶部51のバッファ領域に記憶されたバッファ値がクリアされずに次回の信号検出まで保持される。
When it is determined that the latest buffer value T n is not within the first predetermined range, it is further determined whether or not it is within the second predetermined range (for example, within ± 20%). That is, the second predetermined value is greater than or equal to the lower limit value (T-Th 2 ) of the second predetermined range and less than the lower limit value (T-Th 1 ) of the first predetermined range, or larger than the upper limit value (T + Th 1 ) of the first predetermined range. It is determined whether or not it is equal to or less than the upper limit of the range (T + Th 2 ). If this determination is affirmative, it is possible that a regular event signal was input to the communication with the specified cycle T, or the communication cycle may have changed for some reason, so the buffer area of the
例えば、図4の時刻t1,t7,t11では、最新バッファ値T1,T7,T11が規定周期Tに一致すると判定される。この場合、規定周期Tに相当する時刻t0~t1,t6~t7,t10~t11にデータ信号の割込みがなく、各時刻t1,t7,t11において正規の周期信号が検出されたと判定され、記憶部51のバッファ領域に記憶された全てのバッファ値がクリアされる。
For example, at times t 1 , t 7 , and t 11 in FIG. 4, it is determined that the latest buffer values T 1 , T 7 , and T 11 coincide with the specified period T. In this case, there is no data signal interrupt at times t 0 to t 1 , t 6 to t 7 , and t 10 to t 11 corresponding to the specified period T, and regular period signals are used at each time t 1 , t 7 , and t 11 . Is determined to have been detected, and all the buffer values stored in the buffer area of the
一方、時刻t2,t4,t5,t8,t9では、最新バッファ値T2,T4,T5,T8,T9が第2所定範囲の下限値(T-Th2)より小さく、規定周期Tに満たないと判定される。この場合、時刻t2,t4,t5,t8,t9において検出されたデータ信号は、規定周期Tの間に割り込んだ正規のイベント信号または不正信号であると判定される。このように、第1判定で否定され、規定周期Tの間に割り込んだ正規のイベント信号または不正信号が検出されたと判定される場合は、記憶部51のバッファ領域に記憶されたバッファ値がクリアされずに次回の信号検出まで保持される。
On the other hand, at times t 2 , t 4 , t 5 , t 8 , and t 9 , the latest buffer values T 2 , T 4 , T 5 , T 8 , and T 9 are the lower limit values of the second predetermined range (T-Th 2 ). It is determined that it is smaller and does not meet the specified period T. In this case, the data signal detected at the times t 2 , t 4 , t 5 , t 8 , and t 9 is determined to be a normal event signal or an invalid signal interrupted during the specified period T. As described above, when it is determined in the first determination that a normal event signal or an invalid signal interrupted during the specified period T is detected, the buffer value stored in the buffer area of the
図3の算出部55は、判定部54による第1判定で否定され、記憶部51のバッファ領域に新たなバッファ値Tnが記憶されると、新たに記憶された最新バッファ値に、前回以前に記憶されたバッファ値を順次加算して、加算後の合計時間TSを算出する。より具体的には、合計時間TSが所定範囲の下限値(T-Th)以上となるまで、最新バッファ値Tnに前回以前のバッファ値Tn-1,Tn-2,…を新しい順に順次加算する。
The
例えば、図4の時刻t3,t5,t6,t9,t10では、最新バッファ値T3,T5,T6,T9,T10に前回のバッファ値T2,T4,T5,T8,T9を加算して合計時間TSを算出する。図4に示すように、時刻t6では、最新バッファ値T6に前回のバッファ値T5を加算した合計時間TSが所定範囲の下限値(T-Th)に満たないことから、さらに前々回のバッファ値T4を加算して合計時間TSを算出する。時刻t5では、最新バッファ値T5に前回のバッファ値T4を加算した合計時間TSが所定範囲の下限値(T-Th)に満たないが前々回以前のバッファ値が記憶されていないため、次回のデータ信号が検出されて新たなバッファ値が記憶されるまで待機する。 For example, at the times t 3 , t 5 , t 6 , t 9 , and t 10 in FIG. 4, the latest buffer values T 3 , T 5 , T 6 , T 9 , and T 10 are set to the previous buffer values T 2 , T 4 , Add T 5 , T 8 , and T 9 to calculate the total time T S. As shown in FIG. 4, at time t 6 , the total time T S obtained by adding the previous buffer value T 5 to the latest buffer value T 6 is less than the lower limit value (T-Th) in the predetermined range. The total time T S is calculated by adding the buffer values T 4 of. At time t 5 , the total time TS obtained by adding the previous buffer value T 4 to the latest buffer value T 5 is less than the lower limit value (T-Th) in the predetermined range, but the buffer value before the previous time is not stored. , Waits until the next data signal is detected and a new buffer value is stored.
判定部54は、第2判定として、算出部55により算出された所定範囲の下限値(T-Th)以上の合計時間TSが規定周期Tと一致するか否か、すなわち上限値(T+Th)以下であるか否かを判定する。合計時間TSが上限値(T+Th)以下であると判定されると、規定周期T内に不正信号が割り込んだと判定され、記憶部51のバッファ領域に記憶された全てのバッファ値がクリアされる。
As a second determination, the
例えば、図4の時刻t3,t6,t10では、合計時間TS(T3+T2,T6+T5+T4,T10+T9)が規定周期Tに一致すると判定され、規定周期Tに相当する時刻t1~t3,t3~t6,t8~t10において不正信号が割り込んだと判定される。この場合、記憶部51のバッファ領域に記憶された全てのバッファ値(T2~T3,T4~T6,T9~T10)がクリアされる。
For example, at the times t 3 , t 6 , and t 10 in FIG. 4, it is determined that the total time T S (T 3 + T 2 , T 6 + T 5 + T 4 , T 10 + T 9 ) coincides with the specified cycle T, and the specified cycle T is determined. It is determined that an invalid signal is interrupted at times t 1 to t 3 , t 3 to t 6 , and t 8 to t 10 corresponding to T. In this case, all the buffer values (T 2 to T 3 , T 4 to T 6 , T 9 to T 10 ) stored in the buffer area of the
なお、判定部54は、記憶部51のバッファ領域に記憶されるバッファ値が所定数(バッファ領域の数)を超えたときも、規定周期T内に不正信号が割り込んだと判定し、全てのバッファ値をクリアする。
The
判定部54は、さらに、規定周期Tに不正信号が割り込んだと判定された回数をカウントする。すなわち、不正信号が割り込んだと判定される度にカウント値を第1所定量(例えば、1)インクリメントする。また、第1判定で最新バッファ値Tnが第2所定範囲内であると判定される度にカウント値を第2所定量(例えば、1/5)インクリメントする。そして、カウント値が所定値(例えば、10)に達すると、通信網100に不正信号が入力されたと確定的に判定し、例えば、不正信号が検出されたことを示すDTC(Diagnostic Trouble Code)を記憶部51に記録する。
The
このように、規定周期T毎の不正信号の検出回数をカウントしてカウント値が所定値に達したときに検出を確定することで、通信網100への攻撃を企図して連続的に入力されるDoS攻撃等の不正信号を正確に検出することができる。
In this way, by counting the number of detections of illegal signals in each specified cycle T and confirming the detection when the count value reaches a predetermined value, the signals are continuously input in an attempt to attack the
一方、第1判定で肯定されて規定周期T内にデータ信号の割込みがないと判定されるときは、連続的な信号入力がないことからカウント値をリセットする。例えば、図4の時刻t7,t11では、規定周期Tに相当する時刻t6~t7,t10~t11においてデータ信号の割込みがないと判定され、カウント値が0にリセットされる。カウント値は、車両1のイグニションスイッチがオフされたときにもリセットされる。また、DLC4を介して診断機からDTCクリア信号が入力されたときにもリセットされる。連続的な信号入力がないときはカウント値をリセットすることで、不正信号の誤検出を防止することができる。
On the other hand, when the first determination is affirmed and it is determined that there is no data signal interrupt within the specified period T, the count value is reset because there is no continuous signal input. For example, at times t 7 and t 11 in FIG. 4, it is determined that there is no data signal interrupt at times t 6 to t 7 and t 10 to t 11 corresponding to the specified period T, and the count value is reset to 0. .. The count value is also reset when the ignition switch of the
判定部54は、第2判定で合計時間TSが上限値(T+Th)を超えると判定すると、規定周期T内に正規のイベント信号が割り込んだと判定し、記憶部51のバッファ領域に記憶された最旧のバッファ値(以下、最旧バッファ値)のみをクリアする。例えば、図4の時刻t9では、合計時間TS(T9+T8)が規定周期Tを超えると判定され、規定周期Tに相当する時刻t7~t9において正規のイベント信号が割り込んだと判定される。この場合、記憶部51のバッファ領域に記憶された最旧バッファ値T8のみがクリアされる。
When the
図4の例に示すように、時刻t7の周期信号に続いて時刻t8でイベント信号が発生すると、次回の周期信号は時刻t8のイベント信号の規定周期T後である時刻t10に発生する。このような場合の合計時間TS(T9+T8)は、規定周期Tを超える可能性が高い。すなわち、合計時間TSが規定周期Tを超えたときに、最後に加算された最旧バッファ値T8が、イベント信号が発生するまでの時間間隔である可能性が高い。このような最旧バッファ値T8のみをクリアすることで、新たな規定周期Tの起点を時刻t7から時刻t8に調整することができる。 As shown in the example of FIG. 4, when an event signal is generated at time t 8 following the periodic signal at time t 7 , the next periodic signal is at time t 10 which is after the specified period T of the event signal at time t 8 . Occur. In such a case, the total time TS (T 9 + T 8 ) is likely to exceed the specified period T. That is, when the total time T S exceeds the specified period T, it is highly possible that the oldest buffer value T 8 added last is the time interval until the event signal is generated. By clearing only the oldest buffer value T 8 , the starting point of the new specified period T can be adjusted from the time t 7 to the time t 8 .
図5および図6は、不正信号検出装置として機能するGW50の演算部50により、予めメモリに記憶されたプログラムに従い実行される処理の一例を示すフローチャートである。このフローチャートに示す処理は、特定のIDが付されたデータ信号が検出されると開始され、所定時間毎に繰り返される。
5 and 6 are flowcharts showing an example of processing executed according to a program stored in advance in the memory by the
図5に示すように、先ずステップS1で、データ信号が検出されてからの時間経過の計測を開始する。次いでステップS2で、特定のIDが付された新たなデータが検出されるまで待機する。ステップS2で新たなデータ信号が検出されると、ステップS3に進み、計測された時間間隔Tnを記憶部51のバッファ領域に最新バッファ値Tnとして記憶する。次いでステップS4に進み、信号種別判定処理を実行する。
As shown in FIG. 5, first, in step S1, the measurement of the passage of time since the data signal is detected is started. Then, in step S2, it waits until new data with a specific ID is detected. When a new data signal is detected in step S2, the process proceeds to step S3, and the measured time interval T n is stored in the buffer area of the
図6に示すように、信号種別判定処理では、先ずステップS40において、記憶部51のバッファ領域に記憶された最新バッファ値Tnが所定範囲の下限値(T-Th)以上かつ上限値(T+Th)以下であるか否かを判定する。ステップS40で肯定されるとステップS41に進み、規定周期T内にデータ信号の割込みがなく正規の周期信号が検出されたと判定するとともに、全てのバッファ値をクリアし、カウント値をリセットする。
As shown in FIG. 6, in the signal type determination process, first, in step S40, the latest buffer value T n stored in the buffer area of the
一方、ステップS40で否定されるとステップS42に進み、記憶部51のバッファ領域に、より旧いバッファ値が記憶されているか否かを判定する。ステップS42で肯定されるとステップS43に進み、否定されるとステップS46に進む。ステップS43では、最新バッファ値に前回以前のバッファ値を順次加算して加算後の合計時間TSを算出する。
On the other hand, if it is denied in step S40, the process proceeds to step S42, and it is determined whether or not an older buffer value is stored in the buffer area of the
次いでステップS44で、ステップS43で算出された合計時間TSが所定範囲の下限値(T-Th)以上であるか否かを判定する。ステップS44で否定されるとステップS45に進み、記憶部51のバッファ領域に、より旧いバッファ値が記憶されているか否かを判定する。ステップS45で肯定されるとステップS43に戻り、否定されるとステップS46に進み、信号種別判定を保留する。
Next, in step S44, it is determined whether or not the total time TS calculated in step S43 is equal to or greater than the lower limit value ( T -Th) in the predetermined range. If it is denied in step S44, the process proceeds to step S45, and it is determined whether or not an older buffer value is stored in the buffer area of the
一方、ステップS44で肯定されるとステップS47に進み、ステップS43で算出された合計時間TSが所定範囲の上限値(T+Th)以下であるか否かを判定する。ステップS47で肯定されるとステップS48に進み、規定周期T内に不正信号が割り込んだと判定するとともに、全てのバッファ値をクリアし、カウント値をインクリメントする。一方、ステップS47で否定されるとステップS49に進み、規定周期T内に正規のイベント信号が割り込んだと判定するとともに、最旧バッファ値のみをクリアする。 On the other hand, if affirmed in step S44, the process proceeds to step S47, and it is determined whether or not the total time TS calculated in step S43 is equal to or less than the upper limit value ( T + Th) in the predetermined range. If affirmed in step S47, the process proceeds to step S48, it is determined that an invalid signal has been interrupted within the specified period T, all buffer values are cleared, and the count value is incremented. On the other hand, if it is denied in step S47, the process proceeds to step S49, it is determined that the regular event signal is interrupted within the specified period T, and only the oldest buffer value is cleared.
ステップS41,S48,S49で信号種別が判定され、あるいはステップS46で信号種別判定が保留されると、図5のステップS5に進み、記憶部51のバッファ領域に空きがあるか否かを判定する。ステップS5で肯定されるとステップS2に戻り、否定されるとステップS6に進み、正常な通信頻度を超えるデータ信号が検出されたとして不正信号が入力されたと判定するとともに、全てのバッファ値をクリアし、カウント値をインクリメントする。
When the signal type is determined in steps S41, S48, and S49, or the signal type determination is suspended in step S46, the process proceeds to step S5 in FIG. 5, and it is determined whether or not there is a vacancy in the buffer area of the
次いでステップS7で、カウント値が所定値に達したか否かを判定する。ステップS7で否定されるとステップS2に戻り、肯定されるとステップS8に進み、不正信号の検出を確定する。 Next, in step S7, it is determined whether or not the count value has reached a predetermined value. If it is denied in step S7, the process returns to step S2, and if it is affirmed, the process proceeds to step S8 to confirm the detection of the illegal signal.
このように、規定周期T内にデータ信号の割込みがあったか否かを判定するとともに(S40,S41)、割り込んだデータ信号が正規のイベント信号であるか不正信号であるかを判定することで(S44,S47,S48,S49)、信号種別を判定する。これにより、一定の周期で送信される正規の周期信号と不定期に送信される正規のイベント信号とが混在する通信網100への不正信号の入力を検出することができる。
In this way, it is determined whether or not the data signal is interrupted within the specified period T (S40, S41), and whether the interrupted data signal is a regular event signal or an invalid signal (S40, S41). S44, S47, S48, S49), the signal type is determined. As a result, it is possible to detect the input of an illegal signal to the
本発明の実施形態によれば以下のような作用効果を奏することができる。
(1)不正信号検出装置として機能するGW5は、互いに同一のIDを有する周期信号とイベント信号とが入力される通信網100に、同一のIDを有する不正信号が入力されたことを検出する。周期信号は、所定状態が継続しているときに規定周期Tで入力される正常信号であり、イベント信号は、所定状態が他の状態に変化するときに入力される正常信号である。
According to the embodiment of the present invention, the following effects can be obtained.
(1) The
GW5は、通信網100に入力された連続する複数の信号間の時間間隔Tnを時系列に計測する計測部53と、計測部53により計測された時間間隔Tnを時系列に記憶する記憶部51と、計測部53により計測された時間間隔Tnが下限値(T-Th)以上かつ上限値(T+Th)以下の所定範囲内であるか否かを判定する第1判定を行う判定部54と、判定部54により、計測部53により計測された時間間隔Tnが所定範囲内でないと判定されると、計測部53により計測された時間間隔Tnと記憶部51に記憶された時間間隔Tn-1,Tn-2,…との和が所定範囲の下限値(T-Th)以上となるまで、記憶部51に記憶された時間間隔Tnを新しい順に順次加算して、加算後の合計時間TSを算出する算出部55と、算出部55により算出された合計時間TSが所定範囲内であるか否かを判定する第2判定を行う判定部54と、通信網100に入力された信号の種別を判定する信号種別判定を行う判定部54と、を備える(図3)。
The
判定部54は、計測部53により計測された時間間隔Tnが所定範囲内であると判定されると、周期信号が入力されたと判定する。また、算出部55により算出された合計時間TSが所定範囲内であると判定されると、不正信号が入力されたと判定する。また、算出部55により算出された合計時間TSが所定範囲内でないと判定されると、イベント信号が入力されたと判定する。これにより、一定の周期で送信される正規の周期信号と不定期に送信される正規のイベント信号とが混在する通信網100への不正信号の入力を検出することができる。
When the
(2)記憶部51は、判定部54により、計測部53により計測された時間間隔Tnが所定範囲内であると判定されると、記憶された時間間隔Tnを全て消去する。また、判定部54により、算出部55により算出された合計時間TSが所定範囲内であると判定されると、記憶された時間間隔Tnを全て消去する。また、判定部54により、算出部55により算出された合計時間TSが所定範囲内でないと判定されると、記憶された時間間隔Tnのうち、最も旧い時間間隔Tnを消去する。これにより、規定周期T毎に不正信号の入力を検出することができる。
(2) When the
(3)判定部54は、さらに、記憶部51に所定数の時間間隔Tnが記憶されると、通信網100に不正信号が入力されたと判定する。例えば、バッファ領域の数を正常な通信頻度を考慮して設定された所定数に制限することで、通信網100への攻撃を企図して連続的に入力されるDoS攻撃等の不正信号を検出できるとともに、過剰なバッファ値が蓄積されることを防止することができる。
(3) Further, when the
(4)判定部54は、算出部55により算出された合計時間TSが所定範囲内であると判定される度にカウント値をインクリメントし、インクリメントされたカウント値が所定値に達すると、通信網100に不正信号が入力されたと判定する。すなわち、規定周期T毎の不正信号の検出回数をカウントしてカウント値が所定値に達したときに検出を確定することで、通信網100への攻撃を企図して連続的に入力されるDoS攻撃等の不正信号を正確に検出することができる。
(4) The
(5)判定部54は、計測部53により計測された時間間隔Tnが所定範囲内であると判定されると、カウント値をリセットする。すなわち、連続的な信号入力がないときはカウント値をリセットすることで、誤検出を防止することができる。
(5) The
(6)判定部54は、算出部55により算出された合計時間TSの規定周期Tとの差が第1所定範囲(±Th1)内であると判定されると、第1所定量のカウント値をインクリメントする。また、算出部55により算出された合計時間TSの規定周期Tとの差が第1所定範囲(±Th1)内でなく、かつ、第1所定範囲よりも大きい第2所定範囲(±Th2)内であると判定されると、第1所定量より小さい第2所定量のカウント値をインクリメントする。すなわち、規定周期Tの通信に正規のイベント信号が入力された可能性や、何らかの理由で通信周期が変化した可能性が考えられるときはインクリメントするカウント値を小さくすることで、誤検出を防止し、不正信号を正確に検出することができる。
(6) When the
上記実施形態は種々の形態に変形することができる。以下、変形例について説明する。上記実施形態では、判定部54が第1判定部として規定周期T内の割込み信号の有無を判定し、第2判定部として割込み信号の種別を判定し、信号種別判定部として信号種別判定を行うとしたが、第1、第2判定部、信号種別判定部はこのようなものに限らない。
The above embodiment can be transformed into various forms. Hereinafter, a modified example will be described. In the above embodiment, the
上記実施形態では、不正信号検出装置を車載通信網100に適用する例を説明したが、互いに同一の識別子を有する第1信号と第2信号とが入力される通信網は車載通信網に限らない。また、GW5が不正信号検出装置として機能する例を説明したが、不正信号が入力されたことを検出する不正信号検出装置はこのようなものに限らない。例えば、データ信号の中継を行わない各ノードのいずれかが不正信号検出装置として機能するようにしてもよい。
In the above embodiment, an example of applying the fraudulent signal detection device to the vehicle-mounted
上記実施形態では、DoS攻撃による不正信号を検出するようにしたが、正常信号と同一の識別子を有する不正信号は、正常な通信頻度を超えて通信網に入力されるものであればよく、DoS攻撃による不正信号に限らない。 In the above embodiment, an illegal signal due to a DoS attack is detected, but the illegal signal having the same identifier as the normal signal may be input to the communication network in excess of the normal communication frequency, and is DoS. It is not limited to fraudulent signals due to attacks.
以上の説明はあくまで一例であり、本発明の特徴を損なわない限り、上述した実施形態および変形例により本発明が限定されるものではない。上記実施形態と変形例の一つまたは複数を任意に組み合わせることも可能であり、変形例同士を組み合わせることも可能である。 The above description is merely an example, and the present invention is not limited to the above-described embodiments and modifications as long as the features of the present invention are not impaired. It is also possible to arbitrarily combine one or a plurality of the above embodiments and the modified examples, and it is also possible to combine the modified examples.
1 車両、2 ECU(電子制御ユニット)、3 TCU(テレマティクス制御ユニット)、4 DLC(データリンクコネクタ)、5 GW(ゲートウェイ)、10 通信線、50 演算部、51 記憶部、52 検出部、53 計測部、54 判定部、55 算出部、100 車載通信網(通信網) 1 vehicle, 2 ECU (electronic control unit), 3 TCU (telematics control unit), 4 DLC (data link connector), 5 GW (gateway), 10 communication lines, 50 calculation unit, 51 storage unit, 52 detection unit, 53 Measurement unit, 54 judgment unit, 55 calculation unit, 100 in-vehicle communication network (communication network)
Claims (6)
前記第1信号は、所定状態が継続しているときに所定周期で入力される正常信号であり、前記第2信号は、前記所定状態が他の状態に変化するときに入力される正常信号であり、
前記通信網に入力された連続する複数の信号間の時間間隔を時系列に計測する計測部と、
前記計測部により計測された時間間隔を時系列に記憶する記憶部と、
前記計測部により計測された時間間隔が第1所定値以上かつ第2所定値以下の所定範囲内であるか否かを判定する第1判定部と、
前記第1判定部により、前記計測部により計測された時間間隔が前記所定範囲内でないと判定されると、前記計測部により計測された時間間隔と前記記憶部に記憶された時間間隔との和が前記第1所定値以上となるまで、前記記憶部に記憶された時間間隔を新しい順に順次加算して、加算後の合計時間を算出する算出部と、
前記算出部により算出された合計時間が前記所定範囲内であるか否かを判定する第2判定部と、
前記通信網に入力された信号の種別を判定する信号種別判定部と、を備え、
前記信号種別判定部は、
前記第1判定部により、前記計測部により計測された時間間隔が前記所定範囲内であると判定されると、前記第1信号が入力されたと判定し、
前記第2判定部により、前記算出部により算出された合計時間が前記所定範囲内であると判定されると、不正信号が入力されたと判定し、
前記第2判定部により、前記算出部により算出された合計時間が前記所定範囲内でないと判定されると、前記第2信号が入力されたと判定することを特徴とする不正信号検出装置。 An illegal signal detection device that detects that an illegal signal having the same identifier is input to a communication network in which a first signal and a second signal having the same identifier are input.
The first signal is a normal signal input at a predetermined cycle when the predetermined state continues, and the second signal is a normal signal input when the predetermined state changes to another state. can be,
A measurement unit that measures the time interval between a plurality of consecutive signals input to the communication network in chronological order.
A storage unit that stores the time interval measured by the measurement unit in chronological order,
A first determination unit for determining whether or not the time interval measured by the measurement unit is within a predetermined range of the first predetermined value or more and the second predetermined value or less.
When the first determination unit determines that the time interval measured by the measurement unit is not within the predetermined range, the sum of the time interval measured by the measurement unit and the time interval stored in the storage unit. A calculation unit that calculates the total time after addition by sequentially adding the time intervals stored in the storage unit in the order of newest until the value becomes equal to or more than the first predetermined value.
A second determination unit that determines whether or not the total time calculated by the calculation unit is within the predetermined range, and
A signal type determination unit for determining the type of signal input to the communication network is provided.
The signal type determination unit
When the first determination unit determines that the time interval measured by the measurement unit is within the predetermined range, it is determined that the first signal has been input.
When the second determination unit determines that the total time calculated by the calculation unit is within the predetermined range, it is determined that an invalid signal has been input.
A fraudulent signal detection device, characterized in that, when the second determination unit determines that the total time calculated by the calculation unit is not within the predetermined range, it is determined that the second signal has been input.
前記記憶部は、
前記第1判定部により、前記計測部により計測された時間間隔が前記所定範囲内であると判定されると、記憶された時間間隔を全て消去し、
前記第2判定部により、前記算出部により算出された合計時間が前記所定範囲内であると判定されると、記憶された時間間隔を全て消去し、
前記第2判定部により、前記算出部により算出された合計時間が前記所定範囲内でないと判定されると、記憶された時間間隔のうち、最も旧い時間間隔を消去することを特徴とする不正信号検出装置。 In the fraudulent signal detection device according to claim 1,
The storage unit is
When the first determination unit determines that the time interval measured by the measurement unit is within the predetermined range, all the stored time intervals are erased.
When the second determination unit determines that the total time calculated by the calculation unit is within the predetermined range, all the stored time intervals are erased.
When the second determination unit determines that the total time calculated by the calculation unit is not within the predetermined range, an invalid signal characterized by erasing the oldest time interval among the stored time intervals. Detection device.
前記信号種別判定部は、さらに、前記記憶部に所定数の時間間隔が記憶されると、前記通信網に不正信号が入力されたと判定することを特徴とする不正信号検出装置。 In the fraudulent signal detection device according to claim 2,
The signal type determination unit is further characterized by determining that an unauthorized signal has been input to the communication network when a predetermined number of time intervals are stored in the storage unit.
前記信号種別判定部は、前記第2判定部により、前記算出部により算出された合計時間が前記所定範囲内であると判定される度にカウント値をインクリメントし、インクリメントされたカウント値が所定値に達すると、前記通信網に不正信号が入力されたと判定することを特徴とする不正信号検出装置。 In the fraudulent signal detection device according to any one of claims 1 to 3.
The signal type determination unit increments the count value each time the second determination unit determines that the total time calculated by the calculation unit is within the predetermined range, and the incremented count value is a predetermined value. When it reaches, it is determined that an illegal signal has been input to the communication network.
前記信号種別判定部は、前記第1判定部により、前記計測部により計測された時間間隔が前記所定範囲内であると判定されると、前記カウント値をリセットすることを特徴とする不正信号検出装置。 In the fraudulent signal detection device according to claim 4,
The signal type determination unit resets the count value when the first determination unit determines that the time interval measured by the measurement unit is within the predetermined range. Device.
前記信号種別判定部は、前記第2判定部により、前記算出部により算出された合計時間の前記所定周期との差が第1所定範囲内であると判定されると、第1所定量のカウント値をインクリメントし、前記第2判定部により、前記算出部により算出された合計時間の前記所定周期との差が前記第1所定範囲内でなく、かつ、前記第1所定範囲よりも大きい第2所定範囲内であると判定されると、前記第1所定量より小さい第2所定量のカウント値をインクリメントすることを特徴とする不正信号検出装置。 In the fraudulent signal detection device according to claim 4 or 5.
When the second determination unit determines that the difference between the total time calculated by the calculation unit and the predetermined period is within the first predetermined range, the signal type determination unit counts the first predetermined amount. The second value is incremented, and the difference between the total time calculated by the second determination unit and the predetermined period is not within the first predetermined range and is larger than the first predetermined range. A fraudulent signal detection device, characterized in that, when it is determined to be within a predetermined range, a count value of a second predetermined amount smaller than the first predetermined amount is incremented.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2019190291A JP7011637B2 (en) | 2019-10-17 | 2019-10-17 | Illegal signal detection device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2019190291A JP7011637B2 (en) | 2019-10-17 | 2019-10-17 | Illegal signal detection device |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2021064921A JP2021064921A (en) | 2021-04-22 |
JP7011637B2 true JP7011637B2 (en) | 2022-01-26 |
Family
ID=75486596
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2019190291A Active JP7011637B2 (en) | 2019-10-17 | 2019-10-17 | Illegal signal detection device |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP7011637B2 (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2022270240A1 (en) * | 2021-06-24 | 2022-12-29 | 住友電気工業株式会社 | In-vehicle device, detection device, transmission control method, and detection method |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2019024227A (en) | 2014-05-08 | 2019-02-14 | パナソニック インテレクチュアル プロパティ コーポレーション オブ アメリカPanasonic Intellectual Property Corporation of America | In-vehicle network system, electronic control unit, and fraud detection method |
JP2019068253A (en) | 2017-09-29 | 2019-04-25 | 株式会社デンソー | Abnormality detection device, abnormality detection method, program, and communication system |
WO2019142602A1 (en) | 2018-01-17 | 2019-07-25 | 日本電信電話株式会社 | Detection device, detection method, and program |
-
2019
- 2019-10-17 JP JP2019190291A patent/JP7011637B2/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2019024227A (en) | 2014-05-08 | 2019-02-14 | パナソニック インテレクチュアル プロパティ コーポレーション オブ アメリカPanasonic Intellectual Property Corporation of America | In-vehicle network system, electronic control unit, and fraud detection method |
JP2019068253A (en) | 2017-09-29 | 2019-04-25 | 株式会社デンソー | Abnormality detection device, abnormality detection method, program, and communication system |
WO2019142602A1 (en) | 2018-01-17 | 2019-07-25 | 日本電信電話株式会社 | Detection device, detection method, and program |
Also Published As
Publication number | Publication date |
---|---|
JP2021064921A (en) | 2021-04-22 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR102030397B1 (en) | Network monitoring device | |
EP3758302A1 (en) | Abnormality detection device | |
JP6369341B2 (en) | In-vehicle communication system | |
WO2017038422A1 (en) | Communication device | |
JP7011637B2 (en) | Illegal signal detection device | |
CN110147090B (en) | Method and system for processing controller local area network bus closing fault | |
CN110915170B (en) | Ecu | |
JP2010093676A (en) | Gateway device, vehicle network, and one-side breaking detection method | |
WO2021260984A1 (en) | Information processing device, information processing method, and program | |
US20170272451A1 (en) | Monitoring apparatus and communication system | |
JP6913869B2 (en) | Surveillance equipment, surveillance systems and computer programs | |
JP2009147555A (en) | Failure prediction system for in-vehicle electronic control unit | |
JP6866317B2 (en) | Electronics, message sending methods and programs | |
WO2022124069A1 (en) | Onboard device, fraudulence sensing method, and computer program | |
CN113328983B (en) | Illegal signal detection device | |
JP2020096320A (en) | Illegal signal processing device | |
CN112751822B (en) | Communication apparatus, operation method, abnormality determination apparatus, abnormality determination method, and storage medium | |
JP2020145547A (en) | Unauthorized transmission data detection device | |
JP2020096322A (en) | Illegal signal processing device | |
JP7444223B2 (en) | In-vehicle device, program and information processing method | |
JP7097347B2 (en) | Fraud diagnostic machine detector | |
WO2022270240A1 (en) | In-vehicle device, detection device, transmission control method, and detection method | |
JP2018056980A (en) | Attack detection device, attack detection method, and attack detection program | |
JP2020092325A (en) | Unauthorized signal processing device | |
JP7035791B2 (en) | Anomaly detection device and anomaly detection method to detect cyber attacks |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20210329 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20211213 |
|
TRDD | Decision of grant or rejection written | ||
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 Effective date: 20211228 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20220114 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 7011637 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |