JP2015112963A - On-vehicle network system - Google Patents

On-vehicle network system Download PDF

Info

Publication number
JP2015112963A
JP2015112963A JP2013255271A JP2013255271A JP2015112963A JP 2015112963 A JP2015112963 A JP 2015112963A JP 2013255271 A JP2013255271 A JP 2013255271A JP 2013255271 A JP2013255271 A JP 2013255271A JP 2015112963 A JP2015112963 A JP 2015112963A
Authority
JP
Japan
Prior art keywords
frame
communication node
data
attached
communication
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP2013255271A
Other languages
Japanese (ja)
Other versions
JP6149716B2 (en
Inventor
智康 石川
Tomoyasu Ishikawa
智康 石川
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.)
Toyota Motor Corp
Original Assignee
Toyota Motor Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Toyota Motor Corp filed Critical Toyota Motor Corp
Priority to JP2013255271A priority Critical patent/JP6149716B2/en
Publication of JP2015112963A publication Critical patent/JP2015112963A/en
Application granted granted Critical
Publication of JP6149716B2 publication Critical patent/JP6149716B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

PROBLEM TO BE SOLVED: To improve security in an on-vehicle network system.SOLUTION: A first communication node includes: a control part that, in generating a frame to request for rewriting data of a second communication node, attaches an identification code of the first communication node, and authentication frame count information indicating the number of times of transmissions for a reception side to determine that the frame is a legitimate frame, and performs control for transmitting the same number of frames as the number of times of transmissions; and a transmission part for transmitting the frames. Further, the second communication node includes: a reception part for receiving a frame transmitted from the first communication node; and a control part that authenticates the identification code attached to the received frame, counts a frame of which data is same as data of a frame to which the same identification code is attached, and, in a case where the counted value is the same as that of the authentication frame count information, rewrites data of the second communication node in accordance with the data attached to the frame.

Description

本発明は、車載ネットワークシステムに関する。   The present invention relates to an in-vehicle network system.

車両には、電子制御ユニット(ECU: Electronic Control Unit)が搭載され、電子制御ユニットにより車両の有する各機能の制御が行われる。各ECUは、車載ネットワークを介して相互に接続され、協調して動作する。   An electronic control unit (ECU) is mounted on the vehicle, and each function of the vehicle is controlled by the electronic control unit. Each ECU is connected to each other via an in-vehicle network and operates in cooperation.

車両の制御は、車載ネットワークを多重伝送するフレームに基づいて、電子制御ユニットが動作することにより実現される。   Control of the vehicle is realized by operating the electronic control unit based on a frame that multiplex-transmits the in-vehicle network.

車載ネットワークには、異常制御フレームが所定の周期で伝送する。この異常制御フレームの周期の乱れを検出することにより、外部から車載ネットワークに何らかのフレームが侵入したことを把握できる。   An abnormal control frame is transmitted to the in-vehicle network at a predetermined cycle. By detecting the disturbance of the cycle of the abnormal control frame, it is possible to grasp that some frame has entered the in-vehicle network from the outside.

車載制御装置が保持しているデータに対して読取要求または書込要求を発行する際に、通信装置はあらかじめ認証装置による認証許可を受けることにより、各車載制御装置の処理負荷を抑えつつ車載ネットワークのセキュリティを向上させる技術が知られている(例えば、特許文献1参照)。   When issuing a read request or a write request for data held by the in-vehicle control device, the communication device receives authentication permission from the authentication device in advance, thereby reducing the processing load on each in-vehicle control device and reducing the processing load on each in-vehicle control device. A technique for improving the security of the system is known (see, for example, Patent Document 1).

特開2012−104049号公報JP 2012-104049 A

CAN(Controller Area Network)-IDなどのデータの優先度にしたがって車載ネットワークをフレームが伝送する場合には、外部から車載ネットワークにフレームが侵入しても異常制御フレームの周期の乱れが検出されない場合がある。この場合、外部から何らかのフレームが侵入した場合でも、そのフレームによる異常を検出できない。   When frames are transmitted through the in-vehicle network according to the priority of data such as CAN (Controller Area Network) -ID, even if the frame enters the in-vehicle network from the outside, the disturbance of the cycle of the abnormal control frame may not be detected. is there. In this case, even if some frame enters from the outside, an abnormality due to the frame cannot be detected.

一方、車両の修理が容易となるように、修理者がアクセスしやすい位置にダイアグコネクタを装着することが故障診断の規格により義務づけられている。このダイアグコネクタからフレームを送信することにより車載ネットワークへのアクセスが可能である。   On the other hand, in order to facilitate the repair of the vehicle, it is obliged by the standard of the fault diagnosis to install the diagnostic connector at a position that is easily accessible by the repair person. Access to the in-vehicle network is possible by transmitting a frame from this diagnostic connector.

このダイアグコネクタから、車両のメーカが認識していない外部の接続ツールによりアクセスが実施される場合、該外部の接続ツールにより車両内の制御情報が書き換えられ、改竄されたり、車両内の制御情報が取得され、解析されたりするおそれがある。   When access is performed from the diagnostic connector by an external connection tool that is not recognized by the vehicle manufacturer, the control information in the vehicle is rewritten and altered by the external connection tool, or the control information in the vehicle is May be obtained and analyzed.

また、外部の接続ツールからCAN-IDなどのデータの優先度を模倣したものを付帯したフレームが多数入力されることにより、車両の正常動作が阻害されることが懸念される。   In addition, there is a concern that normal operation of the vehicle may be hindered by inputting a large number of frames attached with imitating data priority such as CAN-ID from an external connection tool.

本発明の目的は、車載ネットワークにおけるセキュリティを向上させることである。   An object of the present invention is to improve security in an in-vehicle network.

開示の一実施例の車両制御装置は、
第1の通信ノードと第2の通信ノードとを有する車載ネットワークシステムであって、
前記第1の通信ノードは、
前記第2の通信ノードに格納されるデータの書き換えを要求するフレームを作成する際に、前記第1の通信ノードの識別コードと、該フレームを正規のものと受信側が判定するための送信回数を示す認証フレーム数情報を付帯し、該送信回数と同数のフレームを送信する制御を実行する制御部と、
前記制御部による制御に従って、前記送信回数と同数のフレームを送信する送信部と
を備え、
前記第2の通信ノードは、
前記第1の通信ノードから送信されるフレームを受信する受信部と、
前記受信部により受信したフレームに付帯される識別コードを認証するとともに、同じ識別コードが付帯されたフレームに付帯されるデータが同じであるフレームをカウントし、該カウントした値が、前記フレームに付帯される認証フレーム数情報と同じである場合に、該フレームに付帯されるデータに従って、前記第2の通信ノードに格納されるデータを書き換える制御部と
を有する。
A vehicle control device according to an embodiment of the disclosure is:
An in-vehicle network system having a first communication node and a second communication node,
The first communication node is
When creating a frame that requests rewriting of data stored in the second communication node, the identification code of the first communication node and the number of transmissions for the receiver to determine that the frame is genuine An authentication frame number information indicating, and a control unit that executes control to transmit the same number of frames as the number of transmissions;
A transmission unit that transmits the same number of frames as the number of transmissions according to control by the control unit,
The second communication node is
A receiving unit for receiving a frame transmitted from the first communication node;
The identification code attached to the frame received by the receiving unit is authenticated, the frames having the same data attached to the frame attached with the same identification code are counted, and the counted value is attached to the frame. A control unit that rewrites data stored in the second communication node according to data attached to the frame when the authentication frame number information is the same as the information.

開示の実施例によれば、車載ネットワークにおけるセキュリティを向上させることができる。   According to the disclosed embodiment, security in the in-vehicle network can be improved.

通信システムの一実施例を示す図である。It is a figure which shows one Example of a communication system. 通信ノード間で送受信されるフレームの一実施例を示す図である。It is a figure which shows one Example of the flame | frame transmitted / received between communication nodes. 通信システムの動作の一実施例を示す図である。It is a figure which shows one Example of operation | movement of a communication system. 通信ノード間で送受信されるフレームの一例を示す図である。It is a figure which shows an example of the flame | frame transmitted / received between communication nodes.

次に、本発明を実施するための形態を、以下の実施例に基づき図面を参照しつつ説明する。以下で説明する実施例は一例に過ぎず、本発明が適用される実施の形態は、以下の実施例に限られない。
なお、実施例を説明するための全図において、同一機能を有するものは同一符号を用い、繰り返しの説明は省略する。
Next, the form for implementing this invention is demonstrated, referring drawings based on the following Examples. Examples described below are merely examples, and embodiments to which the present invention is applied are not limited to the following examples.
In all the drawings for explaining the embodiments, the same reference numerals are used for those having the same function, and repeated explanation is omitted.

<実施例>
<通信システム>
図1に、車載ネットワークシステムとしての通信システムの一実施例を示す。
<Example>
<Communication system>
FIG. 1 shows an embodiment of a communication system as an in-vehicle network system.

通信システムは、第1の通信ノード100と、第2の通信ノード200と、第3の通信ノード300と、第4の通信ノード400と、第5の通信ノード500とを備える。   The communication system includes a first communication node 100, a second communication node 200, a third communication node 300, a fourth communication node 400, and a fifth communication node 500.

第1の通信ノード100−第2の通信ノード200は、第1の通信バス10により有線接続される。第4の通信ノード400−第5の通信ノード500は、第2の通信バス20により有線接続される。第1の通信バス10、第2の通信バス20の一実施例は、CANバスであり、車両内の各通信ノードを接続することにより多重通信網を構成する。多重通信網は車両に複数存在する場合もある。CANバスにより、各通信ノード間でデータを中継することができる。第3の通信ノード300は、第1の通信バス10と第2の通信バス20との間に介設される。第3の通信ノード300は、第1の通信バス10に接続された通信ノードと第2の通信バス20に接続された通信ノードとの間の通信を中継するゲートウェイ装置として機能する。   The first communication node 100 and the second communication node 200 are connected by wire through the first communication bus 10. The fourth communication node 400 to the fifth communication node 500 are connected by wire through the second communication bus 20. An example of the first communication bus 10 and the second communication bus 20 is a CAN bus, and a multiplex communication network is configured by connecting communication nodes in a vehicle. There may be a plurality of multiple communication networks in a vehicle. Data can be relayed between communication nodes via the CAN bus. The third communication node 300 is interposed between the first communication bus 10 and the second communication bus 20. The third communication node 300 functions as a gateway device that relays communication between the communication node connected to the first communication bus 10 and the communication node connected to the second communication bus 20.

さらに、第1の通信バス10には、ダイアグコネクタ600が接続される。ダイアグコネクタ600に、ツール30を介してアクセスし、データを送受信することにより、第1の通信ノード100−第5の通信ノード500の故障診断を行うことができる。しかし、ダイアグコネクタ600に、不正ツールを介してアクセスされ、不正のデータを送受信されるおそれがある。   Further, a diagnostic connector 600 is connected to the first communication bus 10. A failure diagnosis of the first communication node 100 to the fifth communication node 500 can be performed by accessing the diagnosis connector 600 via the tool 30 and transmitting / receiving data. However, there is a possibility that the diag connector 600 may be accessed via an unauthorized tool to transmit / receive unauthorized data.

図1には、5個の通信ノードにより通信システムを構成する場合について示すが、2−4個の通信ノードにより構成してもよいし、6個以上の通信ノードにより構成してもよい。第1の通信バス10に接続される通信ノードと、第2の通信バス20に接続される通信ノードと、第1の通信バス10と第2の通信バス20との間に介設される通信ノードにより通信システムを構成できる。また、第1の通信バス10に接続される複数の通信ノードにより通信システムが構成されてもよい。   Although FIG. 1 shows a case where a communication system is configured by five communication nodes, it may be configured by 2-4 communication nodes, or may be configured by six or more communication nodes. A communication node connected to the first communication bus 10, a communication node connected to the second communication bus 20, and communication interposed between the first communication bus 10 and the second communication bus 20. A communication system can be configured by nodes. In addition, a communication system may be configured by a plurality of communication nodes connected to the first communication bus 10.

第1の通信ノード100−第5の通信ノード500は、例えば車両等の移動体に搭載される。車載ネットワークシステムとしての通信システムの一実施例は、車両に搭載される。通信システムの一実施例には、CAN、LIN(Local Interconnect Network)などのLANが適用される。通信システムの一実施例が、情報系LAN、パワートレイン系LAN、ボディ系LANなどに適用されてもよい。通信システムの一実施例は、FlexRay(登録商標)に従って通信を行うようにしてもよい。   The first communication node 100 to the fifth communication node 500 are mounted on a moving body such as a vehicle, for example. One embodiment of a communication system as an in-vehicle network system is mounted on a vehicle. A LAN such as CAN or LIN (Local Interconnect Network) is applied to an embodiment of the communication system. An embodiment of the communication system may be applied to an information LAN, a powertrain LAN, a body LAN, and the like. An embodiment of the communication system may perform communication according to FlexRay (registered trademark).

各通信ノードは、電子制御ユニットなどにより実現される。また、各通信ノードに、センサ、アクチュエータなどが実装されてもよい。   Each communication node is realized by an electronic control unit or the like. Moreover, a sensor, an actuator, etc. may be mounted in each communication node.

通信ノードの一実施例は、各種制御コンピュータであり、故障診断ツールからの通信メッセージを多重通信網などの車載ネットワークを経由して受信し、通信メッセージに付帯されるデータを制御データとして使用するか否かを判断する。   An example of a communication node is various control computers, which receives a communication message from a failure diagnosis tool via an in-vehicle network such as a multiplex communication network, and uses data attached to the communication message as control data. Judge whether or not.

一例として、第1の通信ノード100からフレームが送信される場合について説明する。第1の通信ノード100から送信されるフレームの一例は、他の通信ノードに記憶されているデータを書き換える書換要求などの制御データが付帯される。第1の通信ノードから、書換要求が付帯されたフレーム以外のフレーム、例えば読取要求などの制御データが付帯されたフレームが送信されてもよい。第1の通信ノード100に限らず、第2の通信ノード200−第5の通信ノード500から書換要求または読取要求などの制御データが付帯されたフレームが送信される場合がある。第1の通信ノード100が書換要求が付帯されたフレームを送信する場合、該第1の通信ノード100は書換装置として機能する。   As an example, a case where a frame is transmitted from the first communication node 100 will be described. An example of a frame transmitted from the first communication node 100 is accompanied by control data such as a rewrite request for rewriting data stored in another communication node. From the first communication node, a frame other than the frame attached with the rewrite request, for example, a frame attached with control data such as a read request may be transmitted. Not only the first communication node 100 but also the second communication node 200 to the fifth communication node 500 may transmit a frame attached with control data such as a rewrite request or a read request. When the first communication node 100 transmits a frame attached with a rewrite request, the first communication node 100 functions as a rewrite device.

第1の通信ノード100から送信されるフレームは、第3の通信ノード300を経由して第4の通信ノード400により受信される。   The frame transmitted from the first communication node 100 is received by the fourth communication node 400 via the third communication node 300.

<第1の通信ノード100>
第1の通信ノード100の一実施例について説明する。第2の通信ノード200−第5の通信ノード500についても第1の通信ノード100を適用できる。
<First communication node 100>
An embodiment of the first communication node 100 will be described. The first communication node 100 can also be applied to the second communication node 200 to the fifth communication node 500.

第1の通信ノード100は、マイクロコントローラ(図示なし)と、トランシーバ(図示なし)とを備える。   The first communication node 100 includes a microcontroller (not shown) and a transceiver (not shown).

マイクロコントローラは、CPU、ROM、RAMなどのハードウェアを備える。   The microcontroller includes hardware such as a CPU, ROM, and RAM.

CPUは、第1の通信ノード100を制御する。具体的には、CPUは、通信相手となる第4の通信ノード400を宛先とするフレームを作成し、送信する制御を実行する。上述したように、フレームの一例は、書換要求などの制御データが付帯されたフレームである。また、CPUは、他の通信ノードから送信されたフレームを受信した場合に、該フレームを認証するとともに、該フレームに付帯されるデータを制御データとして使用するか否かを判定する。   The CPU controls the first communication node 100. Specifically, the CPU executes control for creating and transmitting a frame destined for the fourth communication node 400 as a communication partner. As described above, an example of a frame is a frame attached with control data such as a rewrite request. In addition, when receiving a frame transmitted from another communication node, the CPU authenticates the frame and determines whether or not data attached to the frame is used as control data.

ROMは、第1の通信ノード100の制御を、CPUが実行するためのプログラムを格納するためのメモリである。   The ROM is a memory for storing a program for the CPU to execute control of the first communication node 100.

RAMは、CPUが第1の通信ノード100の制御を実行する際に、データを一時的に格納するためのメモリである。   The RAM is a memory for temporarily storing data when the CPU executes control of the first communication node 100.

トランシーバは、マイクロコントローラ、第1の通信バス10と接続される。トランシーバは、CPUからのフレームを送信する。また、トランシーバは、他の通信ノードから送信されたフレームをマイクロコントローラに入力する。   The transceiver is connected to the microcontroller, the first communication bus 10. The transceiver transmits a frame from the CPU. The transceiver inputs a frame transmitted from another communication node to the microcontroller.

<第1の通信ノード100の機能>
第1の通信ノード100の機能の一実施例について説明する。ここでは、他の通信ノードにフレームを送信する処理が主に示される。他の通信ノードにフレームを送信する処理については、第2の通信ノード200−第5の通信ノード500の機能も、第1の通信ノード100の機能を適用できる。
<Function of First Communication Node 100>
An example of the function of the first communication node 100 will be described. Here, the process of transmitting a frame to another communication node is mainly shown. Regarding the process of transmitting a frame to another communication node, the functions of the first communication node 100 can be applied to the functions of the second communication node 200 to the fifth communication node 500 as well.

マイクロコントローラは、他の通信ノードを制御する際に、制御データを付帯してフレームを作成する。マイクロコントローラは、トランシーバへ、フレームを入力する。   When the microcontroller controls other communication nodes, it creates a frame with accompanying control data. The microcontroller inputs the frame to the transceiver.

フレームフォーマットの一実施例は、CANフレームフォーマットである。フレームには、受信側で該フレームに付帯されるデータを制御データとして利用するか否かを判定し、確定するための基準として、認証フレーム数を表す認証フレーム数情報が付帯される。   One example of the frame format is the CAN frame format. The frame is attached with authentication frame number information representing the number of authentication frames as a reference for determining whether or not to use the data attached to the frame as control data on the receiving side.

CANフレームは、スタートオブフレーム(SOF: Start Of Frame)ビットと、IDと、リモートトランスミッションリクエスト(RTR: Remote Transmission Request)ビットと、データ長コード(DLC: Data Length Code)と、Dataフィールドと、CRCスロットと、ACK(アクノレッジ)スロットと、エンドオブフレーム(EOF: End of Frame)とにより構成される。   The CAN frame consists of a start of frame (SOF) bit, an ID, a remote transmission request (RTR) bit, a data length code (DLC), a data field, and a CRC. The slot includes an ACK (acknowledge) slot and an end of frame (EOF).

スタートオブフレームビットは、メッセージの始めを示し、ドミナント(論理0)ビットで示される。   The start of frame bit indicates the beginning of the message and is indicated by a dominant (logic 0) bit.

IDは、メッセージを識別し、メッセージの優先順位を示す。IDは、11ビットで表されてもよいし(標準フレーム)、29ビットで表されてもよい(拡張フレーム)。IDは、データIDとも呼ばれる。   The ID identifies the message and indicates the priority of the message. The ID may be represented by 11 bits (standard frame) or 29 bits (extended frame). The ID is also called a data ID.

リモートトランスミッションリクエストビットは、リモートフレームとデータフレームを区別するのに使用される。ドミナント(論理0)のリモートトランスミッションリクエストビットはデータフレームを示す。リセッシブ(論理1)のリモートトランスミッションリクエストビットはリモートフレームを示す。   The remote transmission request bit is used to distinguish between a remote frame and a data frame. The dominant (logic 0) remote transmission request bit indicates a data frame. The recessive (logic 1) remote transmission request bit indicates a remote frame.

データ長コードは、データフィールドのバイト数を示す。   The data length code indicates the number of bytes in the data field.

Dataフィールドには、0〜8バイトのデータが付帯される。   Data of 0 to 8 bytes is attached to the Data field.

CRCは、巡回冗長検査を示す。CRCには、15ビットの巡回冗長検査コードとリセッシブデリミタビットが付帯される。CRCフィールドは、エラー検出に使用される。   CRC indicates a cyclic redundancy check. The CRC is accompanied by a 15-bit cyclic redundancy check code and a recessive delimiter bit. The CRC field is used for error detection.

ACK(アクノレッジ)スロットは、メッセージを正しく受信した場合に、メッセージの最後に送信する。送信側のノードは通信バス上でACKビットの有無をチェックし、ACKが検出されなかった場合は再度送信を試みるのが好ましい。   The ACK (acknowledge) slot is transmitted at the end of the message when the message is correctly received. The transmitting node preferably checks the presence or absence of an ACK bit on the communication bus, and if no ACK is detected, attempts to transmit again.

エンドオブフレームは、データフレームやリモートフレームの終了位置を示す。エンドオブフレームは、7ビットで構成され、ビットレベルは全て"リセッシブ"である。   The end of frame indicates the end position of the data frame or the remote frame. The end-of-frame is composed of 7 bits, and all bit levels are “recessive”.

マイクロコントローラは、宛先の通信ノードをIDにより指定し、認証フレーム数情報をデータフィールドにより指定する。また、マイクロコントローラは、宛先の通信ノードと認証フレーム数情報をIDにより指定してもよいし、データフィールドにより指定してもよい。   The microcontroller designates the destination communication node by the ID and designates the authentication frame number information by the data field. In addition, the microcontroller may specify the destination communication node and authentication frame number information by ID or by a data field.

図2は、通信ノード間で送受信されるフレームの一実施例を示す。図2には、第1の通信ノード100により送信されるフレームのIDと、Dataフィールドの一例を示す。   FIG. 2 shows an embodiment of a frame transmitted and received between communication nodes. FIG. 2 shows an example of the frame ID transmitted by the first communication node 100 and the Data field.

第1の通信ノード100のマイクロコントローラは、第4の通信ノード400にデータの書き換えを要求する書換要求などの制御データと、認証フレーム数情報とを付帯したフレームを作成する。認証フレーム数はランダムな値に設定され、ランダムな値を示す認証フレーム数情報がフレームに付帯される。   The microcontroller of the first communication node 100 creates a frame with control data such as a rewrite request for requesting the fourth communication node 400 to rewrite data and authentication frame number information. The number of authentication frames is set to a random value, and authentication frame number information indicating a random value is attached to the frame.

図2に示される例では、フレームには、IDとして「100」が付帯され、認証フレーム数情報として「3」が付帯され、データとして「1,2,3,4,5,6,7」が付帯される。マイクロコントローラは、認証フレーム数と同数のフレームを作成し、トランシーバに入力する。図2に示される例では、マイクロコントローラは、3個のフレームを作成し、トランシーバに入力する。   In the example shown in FIG. 2, “100” is attached as an ID, “3” is attached as authentication frame number information, and “1,2,3,4,5,6,7” as data. Is attached. The microcontroller creates the same number of frames as the number of authentication frames and inputs it to the transceiver. In the example shown in FIG. 2, the microcontroller creates three frames and inputs them to the transceiver.

トランシーバは、第4の通信ノード400にマイクロコントローラからのフレームを送信する。図2に示される例では、トランシーバは、第4の通信ノード400に3個のフレームを送信する。3個のフレームが送信される途中で、不正データが付帯されたフレームが送信されるのを防止する観点からは、トランシーバは、連続して3個のフレームを送信するのが好ましい。   The transceiver transmits the frame from the microcontroller to the fourth communication node 400. In the example shown in FIG. 2, the transceiver transmits three frames to the fourth communication node 400. From the viewpoint of preventing transmission of frames with illegal data in the middle of transmission of three frames, the transceiver preferably transmits three frames in succession.

<第4の通信ノード400>
第4の通信ノード400の一実施例について説明する。
<Fourth communication node 400>
An embodiment of the fourth communication node 400 will be described.

第4の通信ノード400は、第1の通信ノード100と同様に、マイクロコントローラ(図示なし)と、トランシーバ(図示なし)とを備える。   Similar to the first communication node 100, the fourth communication node 400 includes a microcontroller (not shown) and a transceiver (not shown).

マイクロコントローラは、CPU、ROM、RAMなどのハードウェアを備える。   The microcontroller includes hardware such as a CPU, ROM, and RAM.

CPUは、第4の通信ノード400を制御する。具体的には、CPUは、通信相手となる第1の通信ノード100から送信されたフレームを受信するとともに、認証する。CPUは、フレームの認証が成功した場合に、該フレームに付帯される認証フレーム数情報に基づいて、該フレームに付帯されるデータを制御データとして使用するか否かを判定する制御を実行する。   The CPU controls the fourth communication node 400. Specifically, the CPU receives and authenticates the frame transmitted from the first communication node 100 as the communication partner. When the authentication of the frame is successful, the CPU executes control for determining whether to use the data attached to the frame as control data based on the authentication frame number information attached to the frame.

また、CPUは、他の通信ノードを宛先とするフレームを作成し、送信する制御を実行する。   In addition, the CPU executes control for creating and transmitting a frame destined for another communication node.

ROMは、第4の通信ノード400の制御を、CPUが実行するためのプログラムを格納するためのメモリである。   The ROM is a memory for storing a program for the CPU to execute control of the fourth communication node 400.

RAMは、CPUが第4の通信ノード400の制御を実行する際に、データを一時的に格納するためのメモリである。   The RAM is a memory for temporarily storing data when the CPU executes control of the fourth communication node 400.

トランシーバは、マイクロコントローラ、第2の通信バス20と接続される。トランシーバは、マイクロコントローラからのフレームを送信する。また、トランシーバは、他の通信ノードから送信されたフレームをマイクロコントローラに入力する。   The transceiver is connected to the microcontroller, the second communication bus 20. The transceiver transmits a frame from the microcontroller. The transceiver inputs a frame transmitted from another communication node to the microcontroller.

<第4の通信ノード400の機能>
第4の通信ノード400の機能の一実施例について説明する。ここでは、他の通信ノードから送信されるフレームを受信する処理が主に示される。他の通信ノードから送信されるフレームを受信する処理については、第1の通信ノード100−第3の通信ノード300、第5の通信ノード500の機能も、第4の通信ノード400の機能を適用できる。
<Function of Fourth Communication Node 400>
An example of the function of the fourth communication node 400 will be described. Here, the process of receiving a frame transmitted from another communication node is mainly shown. For the process of receiving frames transmitted from other communication nodes, the functions of the first communication node 100 to the third communication node 300 and the fifth communication node 500 are also applied to the function of the fourth communication node 400. it can.

第1の通信ノード100から送信されるフレームは、トランシーバに受信され、マイクロコントローラに入力される。   The frame transmitted from the first communication node 100 is received by the transceiver and input to the microcontroller.

マイクロコントローラは、認証フレーム数をカウント(計数)するカウンタを備える。マイクロコントローラは、トランシーバからのフレームを認証する。具体的には、マイクロコントローラは、フレームに付帯されるIDを認証することにより、不正なフレームであるか否かを判定する。マイクロコントローラは、不正なフレームであると判定した場合、該フレームに付帯されているデータを制御データとして使用しない。マイクロコントローラは、不正なフレームであると判定した場合、該フレームを破棄するようにしてもよい。   The microcontroller includes a counter that counts (counts) the number of authentication frames. The microcontroller authenticates the frame from the transceiver. Specifically, the microcontroller determines whether or not the frame is an illegal frame by authenticating an ID attached to the frame. If the microcontroller determines that the frame is invalid, it does not use the data attached to the frame as control data. If the microcontroller determines that the frame is invalid, the microcontroller may discard the frame.

マイクロコントローラは、不正なフレームでないと判定した場合、該フレームを保持するとともに、該フレームに付帯されている認証フレーム数情報を取得する。マイクロコントローラは、トランシーバから入力されるフレームのうち、保持しているフレームと同じIDが付帯されたフレームを保持するとともに、該フレームに付帯されるデータが保持しているフレームに付帯されたデータと同じであるか否かを判定する。   When determining that the frame is not an illegal frame, the microcontroller holds the frame and acquires authentication frame number information attached to the frame. The microcontroller holds the frame attached with the same ID as the held frame among the frames input from the transceiver, and the data attached to the frame held by the data attached to the frame. It is determined whether or not they are the same.

マイクロコントローラは、保持しているフレームと同じIDが付帯されたフレームに付帯されるデータが、保持しているフレームに付帯されたデータと同じである場合、カウンタをカウントアップする。マイクロコントローラは、カウンタをカウントアップした後、カウンタの値が認証フレーム数情報により示される認証フレーム数と同じであるか否かを判定する。マイクロコントローラは、カウンタの値が認証フレーム数情報により示される認証フレーム数と同じであると判定した場合、カウントしている時間区間では、異常なデータは認められないと判断する。マイクロコントローラは、カウントしている時間区間に受信されたフレームに付帯されるデータを制御データとして使用する。   When the data attached to the frame attached with the same ID as the held frame is the same as the data attached to the held frame, the microcontroller counts up the counter. After counting up the counter, the microcontroller determines whether or not the value of the counter is the same as the number of authentication frames indicated by the authentication frame number information. If the microcontroller determines that the counter value is the same as the number of authentication frames indicated by the authentication frame number information, it determines that no abnormal data is recognized during the counting time interval. The microcontroller uses data attached to the frame received in the counting time interval as control data.

マイクロコントローラは、保持しているフレームと同じIDが付帯されたフレームに付帯されるデータが、保持しているフレームに付帯されたデータと異なる場合、カウンタをリセットする。マイクロコントローラは、所定の時間が経過しても、カウンタの値が認証フレーム数情報により示される認証フレーム数を満たさない場合、カウントしている時間区間で、異常なデータを受信したと判断する。マイクロコントローラは、カウントしている時間区間に受信されたフレームに付帯されるデータは制御データとして使用しない。   The microcontroller resets the counter when the data attached to the frame attached with the same ID as the held frame is different from the data attached to the held frame. If the value of the counter does not satisfy the number of authentication frames indicated by the authentication frame number information even after a predetermined time has elapsed, the microcontroller determines that abnormal data has been received during the counting time interval. The microcontroller does not use the data attached to the frame received in the counting time interval as control data.

図2に戻り、説明を続ける。   Returning to FIG. 2, the description will be continued.

第1の通信ノード100から送信されたフレームは、第4の通信ノード400に送信される。   The frame transmitted from the first communication node 100 is transmitted to the fourth communication node 400.

第4の通信ノード400のトランシーバは、第1の通信ノード100から送信されたフレームを受信し、マイクロコントローラに入力する。マイクロコントローラは、トランシーバからのフレームに付帯されているID(CAN-ID)を認証する。図2に示される例では、IDに「100」が付帯され、正規のフレームとして認証される。さらに、マイクロコントローラは、フレームに付帯されている認証フレーム数情報を取得する。図3に示される例では、マイクロコントローラは、認証フレーム数情報として「3」を取得するとともに、カウンタをカウントアップし「1」とする。   The transceiver of the fourth communication node 400 receives the frame transmitted from the first communication node 100 and inputs it to the microcontroller. The microcontroller authenticates the ID (CAN-ID) attached to the frame from the transceiver. In the example shown in FIG. 2, “100” is added to the ID and authenticated as a normal frame. Further, the microcontroller obtains authentication frame number information attached to the frame. In the example illustrated in FIG. 3, the microcontroller acquires “3” as the authentication frame number information and counts up the counter to “1”.

マイクロコントローラは、その後、トランシーバから入力されるフレームのうち、保持しているフレームと同じIDが付帯されることにより認証されたフレームを保持するとともに、該フレームに付帯されるデータが保持しているフレームに付帯されたデータと同じであるか否かを判定する。   The microcontroller then holds the frame that is authenticated by attaching the same ID as the held frame among the frames that are input from the transceiver, and holds the data that is attached to the frame. It is determined whether the data is the same as the data attached to the frame.

マイクロコントローラは、保持しているフレームと同じIDが付帯されることにより認証されたフレームに付帯されるデータが、保持しているフレームに付帯されたデータと同じである場合、カウンタをカウントアップし、カウンタの値が認証フレーム数情報により示される認証フレーム数と同じであるか否かを判定する。   The microcontroller counts up the counter when the data attached to the frame authenticated by attaching the same ID as the holding frame is the same as the data attached to the holding frame. Then, it is determined whether or not the value of the counter is the same as the number of authentication frames indicated by the authentication frame number information.

図2に示される例では、カウンタの値が認証フレーム数情報により示される認証フレーム数と同じであるとマイクロコントローラが判定した場合について示される。この場合。マイクロコントローラは、カウントしている時間区間に受信されたフレームに付帯されるデータを制御データとして使用する。   In the example shown in FIG. 2, a case where the microcontroller determines that the value of the counter is the same as the number of authentication frames indicated by the authentication frame number information is shown. in this case. The microcontroller uses data attached to the frame received in the counting time interval as control data.

<通信システムの動作>
図3は、通信システムの動作の一実施例を示す。図3には、送信側の通信ノードから送信されるフレームを受信する受信側の通信ノードの動作が主に示される。送信側の通信ノードは、認証フレーム数情報を付帯したフレームを送信する。
<Operation of communication system>
FIG. 3 shows an embodiment of the operation of the communication system. FIG. 3 mainly shows the operation of the receiving communication node that receives a frame transmitted from the transmitting communication node. The communication node on the transmission side transmits a frame with authentication frame number information.

また、図3には、フレームに付帯されるIDを認証した結果、正規のフレームであると認証された後の動作が主に示される。   Also, FIG. 3 mainly shows the operation after authentication of an ID attached to a frame as a result of authentication of a regular frame.

ステップS302では、受信側の通信ノードは、送信側の通信ノードから送信され、且つ認証されたフレームを保持するとともに、該フレームに付帯される認証フレーム数情報を設定する。認証フレーム数情報の設定の後、受信側の通信ノードは、カウンタのカウント数をカウントアップする。図3に示される例では、認証フレーム数情報として「3」が設定されるとともに、カウンタのカウント数がカウントアップされることにより「1」が設定される。   In step S302, the communication node on the receiving side holds the authenticated frame transmitted from the communication node on the transmitting side, and sets authentication frame number information attached to the frame. After setting the authentication frame number information, the communication node on the receiving side counts up the count number of the counter. In the example shown in FIG. 3, “3” is set as the authentication frame number information, and “1” is set by counting up the count number of the counter.

ステップS304では、受信側の通信ノードは、送信側の通信ノードから送信されるフレームを保持した後に受信されるフレームについて、保持しているフレームに付帯されるIDとデータが同じである場合、カウンタのカウント数をカウントアップする。つまり、受信側の通信ノードは、保持しているフレームに付帯されるIDと同じであることにより認証されたフレームに付帯されるデータが、保持しているフレームに付帯されるデータが同じである場合、カウンタのカウント数をカウントアップする。   In step S304, when the receiving communication node holds the frame transmitted from the transmitting communication node and the received frame has the same ID and data attached to the held frame, the counter Count up the count. In other words, the communication node on the receiving side has the same data attached to the authenticated frame as the data attached to the held frame because it is the same as the ID attached to the held frame. If so, the counter counts up.

ステップS306では、受信側の通信ノードは、保持しているフレームに付帯されるIDとデータが同じである場合にカウンタのカウント数をカウントアップした結果、カウント値が、認証フレーム数情報により示される認証フレーム数に達したか否かを判定する。   In step S306, the reception side communication node counts up the count number of the counter when the ID and data attached to the held frame are the same, and the count value is indicated by the authentication frame number information. It is determined whether the number of authentication frames has been reached.

ステップS308では、受信側の通信ノードは、カウント値が認証フレーム数情報により示される認証フレーム数に達したと判定した場合、保持しているフレームに付帯されるデータを制御データとして使用する。一方、カウント値が、認証フレーム数情報に表される認証フレーム数に達しないと判定した場合、保持しているフレームに付帯されるデータを制御データとして使用しない。保持しているフレームに付帯されるデータを制御データとして使用しない場合、前回の制御に使用した制御データを使用するようにしてもよい。   In step S308, when it is determined that the count value has reached the number of authentication frames indicated by the authentication frame number information, the receiving communication node uses data attached to the held frame as control data. On the other hand, when it is determined that the count value does not reach the number of authentication frames represented in the authentication frame number information, data attached to the held frame is not used as control data. When data attached to the held frame is not used as control data, the control data used for the previous control may be used.

通信システムの一実施例によれば、送信側の通信ノードは、受信側で該フレームに付帯されるデータを制御データとして利用するか否かを判定するための基準として認証フレーム数を表す認証フレーム数情報を付帯したフレームを認証フレーム数により表される回数送信する。受信側の通信ノードは、送信側の通信ノードから送信されるフレームに付帯されるIDに基づいて認証するとともに、認証フレーム数情報に基づいて、送信側の通信ノードから認証フレーム数により表される回数送信されるフレームをカウントする。受信側の通信ノードがIDと認証フレーム数情報に基づいて、送信側の通信ノードからのフレームが正規のフレームであるか否かを判定することにより、車載ネットワークにおけるセキュリティを向上させることができる。   According to one embodiment of the communication system, the communication node on the transmission side uses the authentication frame representing the number of authentication frames as a reference for determining whether or not the data attached to the frame is used as control data on the reception side. A frame with number information is transmitted a number of times represented by the number of authentication frames. The receiving communication node authenticates based on the ID attached to the frame transmitted from the transmitting communication node, and is represented by the number of authentication frames from the transmitting communication node based on the authentication frame number information. Count frames that are sent a number of times. The receiving communication node determines whether or not the frame from the transmitting communication node is a regular frame based on the ID and the authentication frame number information, whereby security in the in-vehicle network can be improved.

図4は、正規のフレームが送信されるのと同じタイミングで、正規のフレームと同様のIDを付帯し、且つデータが改竄された不正フレームが外部から送信される例を示す。図4において、正規のフレームに付帯されるデータは「1,2,3,4,5,6,7」であり、不正フレームに付帯されるデータは「9,9,9,9,9,9,9,9,9」である。   FIG. 4 shows an example in which an illegal frame with the same ID as that of a regular frame and the data falsified is transmitted from the outside at the same timing as the regular frame is transmitted. In FIG. 4, the data attached to the regular frame is “1,2,3,4,5,6,7”, and the data attached to the illegal frame is “9,9,9,9,9, 9,9,9,9 ".

フレームに付帯されるIDを認証することにより正規のフレームであるか否かを判定する方法では、このような不正フレームが外部から送信された場合、受信側の通信ノードは、不正フレームを検出できず、不正フレームを正規のフレームとして処理する場合がある。CANプロトコルでは、受信側の通信ノードでは、不正にフレームが受信されたか否かを判定できず、送信側の通信ノードの判別は、IDで実施されるためである。さらに、データが改竄されたか否かは、異常制御フレームの周期が乱れたか否かにより判断されるためである。不正フレームを正規のフレームとして処理する場合には、フェールセーフの機構がない場合、異常な制御が実行されるおそれがある。   In the method of determining whether or not the frame is a legitimate frame by authenticating the ID attached to the frame, when such an illegal frame is transmitted from the outside, the receiving communication node can detect the illegal frame. In some cases, an illegal frame is processed as a regular frame. This is because in the CAN protocol, the communication node on the receiving side cannot determine whether or not a frame has been received illegally, and the determination of the communication node on the transmitting side is performed based on the ID. Further, this is because whether or not the data has been falsified is determined by whether or not the cycle of the abnormal control frame is disturbed. When an illegal frame is processed as a regular frame, if there is no fail-safe mechanism, abnormal control may be performed.

通信システムの一実施例では、フレームに付帯されるIDに加え、認証フレーム数情報に基づいて、フレームに付帯されるデータが正規のデータであるか否かを判定し、正規のデータであると判定した場合に制御データとして使用するため、車載ネットワークにおけるセキュリティを向上させることができる。   In one embodiment of the communication system, based on the authentication frame number information in addition to the ID attached to the frame, it is determined whether or not the data attached to the frame is regular data. Since it uses as control data when it determines, the security in a vehicle-mounted network can be improved.

また、外部ツールの利用者が不正にデータを搾取しようとすることを検知できることにより、送信中のデータに制限を加えることや、不正アクセス者に警告などを行うことが可能となり、セキュリティを向上させることができる。   In addition, by detecting that an external tool user attempts to exploit data illegally, it is possible to limit the data being transmitted and to warn unauthorized users, thereby improving security. be able to.

また、外部ツールの利用者が不正にデータを送信することを検知できるため、安全に動作させるためのフェールセーフ策を講じることができるため、車両の安全確保に寄与できる。   Moreover, since it can detect that the user of an external tool transmits data illegally, a fail-safe measure for operating safely can be taken, which can contribute to ensuring the safety of the vehicle.

以上、本発明は特定の実施例を参照しながら説明されてきたが、実施例は単なる例示に過ぎず、当業者は様々な変形例、修正例、代替例、置換例等を理解するであろう。説明の便宜上、本発明の実施例に従った装置は機能的なブロック図を用いて説明されたが、そのような装置はハードウェアで、ソフトウェアで又はそれらの組み合わせで実現されてもよい。本発明は上記実施例に限定されず、本発明の精神から逸脱することなく、様々な変形例、修正例、代替例、置換例等が包含される。   Although the present invention has been described with reference to specific embodiments, the embodiments are merely illustrative, and those skilled in the art will appreciate various variations, modifications, alternatives, substitutions, and the like. Let's go. For convenience of explanation, an apparatus according to an embodiment of the present invention has been described using a functional block diagram, but such an apparatus may be implemented in hardware, software, or a combination thereof. The present invention is not limited to the above-described embodiments, and various variations, modifications, alternatives, substitutions, and the like are included without departing from the spirit of the present invention.

10 第1の通信バス
20 第2の通信バス
30 ツール
40 データアクセス
100 第1の通信ノード
200 第2の通信ノード
300 第3の通信ノード
400 第4の通信ノード
500 第5の通信ノード
600 ダイアグコネクタ
DESCRIPTION OF SYMBOLS 10 1st communication bus 20 2nd communication bus 30 Tool 40 Data access 100 1st communication node 200 2nd communication node 300 3rd communication node 400 4th communication node 500 5th communication node 600 Diag connector

Claims (1)

第1の通信ノードと第2の通信ノードとを有する車載ネットワークシステムであって、
前記第1の通信ノードは、
前記第2の通信ノードに格納されるデータの書き換えを要求するフレームを作成する際に、前記第1の通信ノードの識別コードと、該フレームを正規のものと受信側が判定するための送信回数を示す認証フレーム数情報を付帯し、該送信回数と同数のフレームを送信する制御を実行する制御部と、
前記制御部による制御に従って、前記送信回数と同数のフレームを送信する送信部と
を備え、
前記第2の通信ノードは、
前記第1の通信ノードから送信されるフレームを受信する受信部と、
前記受信部により受信したフレームに付帯される識別コードを認証するとともに、同じ識別コードが付帯されたフレームに付帯されるデータが同じであるフレームをカウントし、該カウントした値が、前記フレームに付帯される認証フレーム数情報と同じである場合に、該フレームに付帯されるデータに従って、前記第2の通信ノードに格納されるデータを書き換える制御部と
を有する、車載ネットワークシステム。
An in-vehicle network system having a first communication node and a second communication node,
The first communication node is
When creating a frame that requests rewriting of data stored in the second communication node, the identification code of the first communication node and the number of transmissions for the receiver to determine that the frame is genuine An authentication frame number information indicating, and a control unit that executes control to transmit the same number of frames as the number of transmissions;
A transmission unit that transmits the same number of frames as the number of transmissions according to control by the control unit,
The second communication node is
A receiving unit for receiving a frame transmitted from the first communication node;
The identification code attached to the frame received by the receiving unit is authenticated, the frames having the same data attached to the frame attached with the same identification code are counted, and the counted value is attached to the frame. And a controller that rewrites data stored in the second communication node according to data attached to the frame when the authentication frame number information is the same.
JP2013255271A 2013-12-10 2013-12-10 In-vehicle network system Active JP6149716B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2013255271A JP6149716B2 (en) 2013-12-10 2013-12-10 In-vehicle network system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2013255271A JP6149716B2 (en) 2013-12-10 2013-12-10 In-vehicle network system

Publications (2)

Publication Number Publication Date
JP2015112963A true JP2015112963A (en) 2015-06-22
JP6149716B2 JP6149716B2 (en) 2017-06-21

Family

ID=53527173

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2013255271A Active JP6149716B2 (en) 2013-12-10 2013-12-10 In-vehicle network system

Country Status (1)

Country Link
JP (1) JP6149716B2 (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH07311603A (en) * 1994-05-16 1995-11-28 Hitachi Ltd Controller for automobile
JP2005238950A (en) * 2004-02-25 2005-09-08 Mitsubishi Motors Corp Vehicular control device
JP2013122631A (en) * 2011-12-09 2013-06-20 Denso Corp Program rewriting method, program rewriting device, and electronic control unit
JP2013141948A (en) * 2012-01-12 2013-07-22 Denso Corp Vehicle communication system

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH07311603A (en) * 1994-05-16 1995-11-28 Hitachi Ltd Controller for automobile
JP2005238950A (en) * 2004-02-25 2005-09-08 Mitsubishi Motors Corp Vehicular control device
JP2013122631A (en) * 2011-12-09 2013-06-20 Denso Corp Program rewriting method, program rewriting device, and electronic control unit
JP2013141948A (en) * 2012-01-12 2013-07-22 Denso Corp Vehicle communication system

Also Published As

Publication number Publication date
JP6149716B2 (en) 2017-06-21

Similar Documents

Publication Publication Date Title
JP7008100B2 (en) Fraud handling methods, fraud detection electronic control units and network communication systems
JP6887040B2 (en) Fraud detection method, monitoring electronic control unit and in-vehicle network system
JP6477281B2 (en) In-vehicle relay device, in-vehicle communication system, and relay program
US10484401B2 (en) In-vehicle network attack detection method and apparatus
CN104717202B (en) Method and apparatus for enhancing the safety of vehicle-carrying communication network
JP6836340B2 (en) Fraud detection electronic control unit, in-vehicle network system and communication method
JP6126980B2 (en) Network device and network system
JP6079768B2 (en) In-vehicle communication system
US11296965B2 (en) Abnormality detection in an on-board network system
JP7182559B2 (en) Log output method, log output device and program
US11938897B2 (en) On-vehicle device, management method, and management program
JP2014236248A (en) Electronic control device and electronic control system
KR101972457B1 (en) Method and System for detecting hacking attack based on the CAN protocol
JP2017121091A (en) Ecu and network device for vehicle
JP6099269B2 (en) Data exclusion device
JP6217469B2 (en) Unauthorized data detection device, communication system, and unauthorized data detection method
JP6149716B2 (en) In-vehicle network system
US20230327907A1 (en) Relay device, communication network system, and communication control method
JP2015192216A (en) Communication device and communication method
JP2014027510A (en) Communication controller
JP5892889B2 (en) Communication control device
JP2017085197A (en) Communication system, transmitter and communication method
JP2022078868A (en) Vehicle communication system, communication method, and communication program
Lakshmi et al. Secure Communication between Arduinos using Controller Area Network (CAN) Bus

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20160118

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20161005

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20161018

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20161207

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: 20170425

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20170508

R151 Written notification of patent or utility model registration

Ref document number: 6149716

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151