DETECTION DEVICE, ON-VEHICLE SYSTEM, AND DETECTION METHOD
The detection device measures and analyzes CAN bus signal waveforms to accurately detect abnormalities, including new device connections, using a probability density function to ensure precise detection without interrupting bus communication.
Patent Information
- Application Number
- JP2021569726
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Priority Date
- 2020-01-09
- Filing Date
- 2020-09-09
- Publication Date
- 2024-11-06
- Estimated Expiration
- 2040-09-09
AI Technical Summary
Existing technologies struggle to accurately detect abnormalities related to a CAN bus in an in-vehicle network, particularly when new devices are connected, and often require complex configurations or stop communication on the bus.
A detection device that measures signal waveforms on a CAN bus, calculates multiple types of feature quantities, and detects abnormalities based on these features, using a probability density function to determine if an abnormality has occurred.
This approach allows for more accurate detection of CAN bus abnormalities with a simple configuration, enabling detection of minute changes without disrupting communication.
Smart Images

Figure 0007578108000013 
Figure 0007578108000014 
Figure 0007578108000015
Abstract
Description
[Technical field]
[0001] The present disclosure relates to a detection device, an in-vehicle system, and a detection method. This application claims priority based on Japanese Patent Application No. 2020-2244, filed on January 9, 2020, the disclosure of which is incorporated herein in its entirety. [Background technology]
[0002] Patent Document 1 discloses the following detection method: That is, the detection method is a detection method for detecting a fault in a faulty network component in a bus network including two or more transmitters, and includes the steps of transmitting a first signal of a predetermined parameter from a first transmitter of the two or more transmitters to the bus network, receiving the first signal by at least one receiver, and determining whether the first signal is followed by a first tail that is an echo indicative of the faulty network component.
[0003] Furthermore, Non-Patent Document 1 discloses a technique for detecting the connection of unauthorized devices by observing the impedance of a network using a TDR (Time Domain Reflectometry) technique. [Prior art documents] [Patent documents]
[0004] [Patent Document 1] US Patent Application Publication No. 2008 / 0043629 [Non-patent literature]
[0005] [Non-Patent Document 1] Yuta Atobe and 3 others, "A Study on Detecting Unauthorized Devices Connected to Vehicle Networks Using TDR," 2019 Symposium on Cryptography and Information Security, The Institute of Electronics, Information and Communication Engineers Summary of the Invention
[0006] The detection device disclosed herein is a detection device used in an in-vehicle network including a CAN (Controller Area Network) bus and a plurality of functional units connected to the CAN bus, and includes a measurement unit that measures a signal waveform of a frame transmitted on the CAN bus, a calculation unit that calculates multiple types of features of the signal waveform measured by the measurement unit, and a detection unit that detects an abnormality related to the CAN bus based on each of the features calculated by the calculation unit.
[0007] The in-vehicle system of the present disclosure includes a plurality of functional units connected to a CAN bus and a detection device, wherein the functional units transmit frames to other functional units via the CAN bus, the detection device measures a signal waveform of the frame transmitted on the CAN bus, the detection device calculates multiple types of features of the measured signal waveform, and the detection device detects an abnormality related to the CAN bus based on each of the calculated features.
[0008] The detection method disclosed herein is a detection method in a detection device used in an in-vehicle network including a CAN bus and a plurality of functional units connected to the CAN bus, and includes the steps of measuring a signal waveform of a frame transmitted on the CAN bus, calculating multiple types of features of the measured signal waveform, and detecting an abnormality related to the CAN bus based on each of the calculated features.
[0009] One aspect of the present disclosure may be realized not only as a detection device having such a characteristic processing unit, but also as a semiconductor integrated circuit that realizes all or part of the detection device. Also, one aspect of the present disclosure may be realized not only as an in-vehicle system having such a characteristic processing unit, but also as a method having such characteristic processing steps, or as a semiconductor integrated circuit that realizes all or part of the in-vehicle system. [Brief description of the drawings]
[0010] [Figure 1] FIG. 1 is a diagram showing a configuration of an in-vehicle communication system according to an embodiment of the present disclosure. [Diagram 2] FIG. 2 is a diagram illustrating a configuration of a bus connection device group according to an embodiment of the present disclosure. [Diagram 3] FIG. 3 is a diagram illustrating an example of a CAN frame transmitted in a CAN bus according to an embodiment of the present disclosure. [Figure 4] FIG. 4 is a diagram illustrating another example of a frame transmitted in the CAN bus according to the embodiment of the present disclosure. [Diagram 5] FIG. 5 is a diagram illustrating a configuration of a detection device according to an embodiment of the present disclosure. [Figure 6] FIG. 6 is a diagram illustrating an example of a signal waveform of a CAN frame transmitted in a CAN bus according to an embodiment of the present disclosure. [Figure 7] FIG. 7 is a diagram illustrating an example of a distribution of determination features calculated in a detection device according to an embodiment of the present disclosure. [Figure 8] FIG. 8 is a diagram illustrating an example of a distribution of scores calculated in a detection device according to an embodiment of the present disclosure. [Figure 9] FIG. 9 is a diagram illustrating another example of the distribution of determination features calculated in the detection device according to the embodiment of the present disclosure. [Figure 10] FIG. 10 is a diagram illustrating another example of the distribution of the scores calculated in the detection device according to the embodiment of the present disclosure. [Figure 11]FIG. 11 is a flowchart defining an example of an operation procedure when the detection device in the in-vehicle system according to the embodiment of the present disclosure performs the detection process. [Figure 12] FIG. 12 is a diagram illustrating an example of a sequence of a detection process in the in-vehicle system according to the embodiment of the present disclosure. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0011] Conventionally, techniques have been developed to improve security in networks.
[0012] [Problem that this disclosure aims to solve] There is a need for a technology that goes beyond the technologies described in Patent Document 1 and Non-Patent Document 1 and that enables more accurate detection of abnormalities related to the CAN bus in an in-vehicle network with a simple configuration.
[0013] The present disclosure has been made to solve the above-mentioned problems, and its purpose is to provide a detection device, an in-vehicle system, and a detection method that are capable of more accurately detecting abnormalities related to a CAN bus in an in-vehicle network with a simple configuration.
[0014] [Effects of this disclosure] According to the present disclosure, it is possible to more accurately detect anomalies related to a CAN bus in an in-vehicle network with a simple configuration.
[0015] [Description of the embodiments of the present disclosure] First, the contents of the embodiments of the present disclosure will be listed and described.
[0016] (1) A detection device according to an embodiment of the present disclosure is a detection device used in an in-vehicle network including a CAN bus and a plurality of functional units connected to the CAN bus, and includes a measurement unit that measures a signal waveform of a frame transmitted on the CAN bus, a calculation unit that calculates a plurality of types of features of the signal waveform measured by the measurement unit, and a detection unit that detects an abnormality related to the CAN bus based on each of the features calculated by the calculation unit.
[0017] In this way, by focusing on the feature values of the signal waveforms of frames transmitted through the CAN bus and calculating multiple types of feature values to detect abnormalities related to the CAN bus, it is possible to detect minute changes related to the CAN bus during operation, for example, without using a device that applies a pulse signal to the CAN bus, etc. Therefore, it is possible to more accurately detect abnormalities related to the CAN bus in an in-vehicle network with a simple configuration.
[0018] (2) Preferably, the detection device further includes an acquisition unit that acquires a reference distribution, which is a distribution of each of the feature quantities generated in advance, and the detection unit detects an anomaly related to the CAN bus based on each of the feature quantities calculated by the calculation unit and the reference distribution acquired by the acquisition unit.
[0019] With this configuration, the degree of abnormality of a feature when a normal state is used as a reference can be detected based on a reference distribution generated in advance, making it possible to detect anomalies related to the CAN bus with simple processing.
[0020] (3) Preferably, the calculation unit calculates at least two of the mean, variance, skewness, kurtosis, Klichkoff irregularity, Jensen irregularity, spectral crest factor, and root mean square of the voltage value obtained by sampling the signal waveform as the feature quantities.
[0021] With this configuration, it is possible to more accurately detect abnormalities related to the CAN bus by using various feature quantities.
[0022] (4) Preferably, the measurement unit measures a pulse signal waveform in a range from a Control field to a CRC field in the frame.
[0023] With this configuration, the pulse signal waveform can be measured at a timing that is unlikely to overlap with frames from other functional units, making it possible to more accurately detect abnormalities related to the CAN bus.
[0024] (5) Preferably, the measurement unit measures the signal waveform of each of the multiple frames transmitted from the multiple functional units, the calculation unit calculates multiple types of the feature amounts of each of the signal waveforms measured by the measurement unit, and the detection unit detects an abnormality related to the CAN bus based on the multiple types of the feature amounts of each of the signal waveforms calculated by the calculation unit.
[0025] The accuracy of detecting an abnormality in a CAN bus depends on the distance between the location of the abnormality and the connection position of the functional unit, so this configuration makes it possible to detect abnormalities in a wide range of locations on the CAN bus.
[0026] (6) An in-vehicle system according to an embodiment of the present disclosure includes a plurality of functional units connected to a CAN bus and a detection device, wherein the functional units transmit frames to other functional units via the CAN bus, the detection device measures a signal waveform of the frame transmitted on the CAN bus, the detection device calculates a plurality of types of features of the measured signal waveform, and the detection device detects an abnormality related to the CAN bus based on each of the calculated features.
[0027] In this way, by focusing on the feature values of the signal waveforms of frames transmitted through the CAN bus and calculating multiple types of feature values to detect abnormalities related to the CAN bus, it is possible to detect minute changes related to the CAN bus during operation, for example, without using a device that applies a pulse signal to the CAN bus, etc. Therefore, it is possible to more accurately detect abnormalities related to the CAN bus in an in-vehicle network with a simple configuration.
[0028] (7) A detection method according to an embodiment of the present disclosure is a detection method in a detection device used in an in-vehicle network including a CAN bus and a plurality of functional units connected to the CAN bus, and includes the steps of measuring a signal waveform of a frame transmitted on the CAN bus, calculating multiple types of features of the measured signal waveform, and detecting an abnormality related to the CAN bus based on each of the calculated features.
[0029] In this way, by focusing on the feature values of the signal waveforms of frames transmitted through the CAN bus and calculating multiple types of feature values to detect anomalies related to the CAN bus, it is possible to detect minute changes related to the CAN bus during operation, for example, without using a device that applies a pulse signal to the CAN bus, etc. Therefore, it is possible to more accurately detect anomalies related to the CAN bus in an in-vehicle network with a simple configuration.
[0030] Hereinafter, embodiments of the present disclosure will be described with reference to the drawings. In the drawings, the same or corresponding parts are denoted by the same reference numerals, and the description thereof will not be repeated. In addition, at least some of the embodiments described below may be arbitrarily combined.
[0031] [Configuration and basic operation] FIG. 1 is a diagram showing a configuration of an in-vehicle communication system according to an embodiment of the present disclosure.
[0032] 1, the in-vehicle system 301 includes a gateway device 101, a plurality of in-vehicle communication devices 111, and a plurality of bus connection device groups 121. The in-vehicle system 301 is mounted on a vehicle 1.
[0033] The in-vehicle communication device 111 is connected to the gateway device 101 via a bus 14. The bus 14 is a bus conforming to standards such as CAN (registered trademark), FlexRay (registered trademark), MOST (Media Oriented Systems Transport) (registered trademark), Ethernet (registered trademark), and LIN (Local Interconnect Network).
[0034] Moreover, the bus connection device group 121 is connected to the gateway device 101 via a CAN bus 13 that is a bus conforming to the CAN standard.
[0035] The in-vehicle network 12 includes a gateway device 101, an in-vehicle communication device 111, a bus connection device group 121, a CAN bus 13, and a bus 14. Note that the in-vehicle network 12 may be configured not to include at least one of the gateway device 101, the in-vehicle communication device 111, and the bus 14.
[0036] In the in-vehicle network 12, the in-vehicle communication device 111 communicates with, for example, a device outside the vehicle 1. Specifically, the in-vehicle communication device 111 is, for example, a TCU (Telematics Communication Unit), a short-range wireless terminal device, and an ITS (Intelligent Transport Systems) wireless device.
[0037] 2 is a diagram showing a configuration of a bus connection device group according to an embodiment of the present disclosure, showing one CAN bus 13 and a corresponding bus connection device group 121.
[0038] 2, bus connection device group 121 includes a plurality of control devices 122 connected to corresponding CAN buses 13, and detection device 200. In the example shown in FIG. 2, bus connection device group 121 includes control devices 122A, 122B, and 122C as control devices 122. Control devices 122 and gateway device 101 are examples of functional units. Control device 122 is, for example, an ECU (Electronic Control Unit).
[0039] The CAN bus 13 is provided for each system, for example. Specifically, the CAN bus 13 is, for example, a drive system bus, a chassis / safety system bus, a body / electrical system bus, and an AV / information system bus.
[0040] An engine control device, an AT (Automatic Transmission) control device, and an HEV (Hybrid Electric Vehicle) control device, which are examples of the control device 122, are connected to the drive system bus. The engine control device, the AT control device, and the HEV control device control the engine, the AT, and switching between the engine and the motor, respectively.
[0041] A brake control device, a chassis control device, and a steering control device, which are examples of the control device 122, are connected to the chassis / safety system bus. The brake control device, the chassis control device, and the steering control device control the brakes, the chassis, and the steering, respectively.
[0042] An instrument display control device, an air conditioner control device, an anti-theft control device, an air bag control device, and a smart entry control device, which are examples of the control device 122, are connected to the body / electrical system bus. The instrument display control device, the air conditioner control device, the anti-theft control device, the air bag control device, and the smart entry control device control the instruments, the air conditioner, the anti-theft mechanism, the air bag mechanism, and the smart entry, respectively.
[0043] A navigation control device, an audio control device, an ETC (Electronic Toll Collection System) (registered trademark) control device, and a telephone control device, which are examples of the control device 122, are connected to the AV / information bus. The navigation control device, the audio control device, the ETC control device, and the telephone control device control the navigation device, the audio device, the ETC device, and the mobile phone, respectively.
[0044] The bus connection device group 121 may include devices other than the control device 122 and the detection device 200 that are connected to the CAN bus 13 .
[0045] The control device 122 transmits a frame to another control device 122 or the gateway device 101 via the CAN bus 13. Hereinafter, a frame transmitted on the CAN bus is also referred to as a CAN frame.
[0046] FIG. 3 is a diagram illustrating an example of a CAN frame transmitted in a CAN bus according to an embodiment of the present disclosure.
[0047] Referring to FIG. 3, the CAN frame has a Start Of Frame (SOF), an Arbitration field, a Control field, a Data field, a Cyclic Redundancy Check (CRC) field, an Acknowledgement (ACK) field, and an End Of Frame (EOF).
[0048] The Arbitration field includes an ID and a Remote Transmission Request (RTR). The Control field includes an Identifier Extension (IDE), an FD Format (FDF), and a Data Length Code (DLC). The CRC field includes a CRC and a CRC Delimiter. The ACK field includes an ACK and an ACK Delimiter.
[0049] FIG. 4 is a diagram illustrating another example of a frame transmitted in the CAN bus according to the embodiment of the present disclosure.
[0050] Referring to Fig. 4, this CAN frame has the same field configuration as the CAN frame shown in Fig. 3. The Arbitration field has an ID and a Remote Request Substitution (RRS). The Control field has an IDE, an FDF, a reserved bit, a Bit Rate Indicator (BRS), an Error State Indicator (ESI), and a DLC. The CRC field has a Stuff Count, a CRC, and a CRC Delimiter. The ACK field has an ACK and an ACK Delimiter.
[0051] Referring back to FIG. 1, the gateway device 101 is, for example, a central gateway (CGW) and is capable of communicating with other in-vehicle devices.
[0052] The gateway device 101 performs relay processing, for example, to relay information exchanged between control devices 122 connected to different CAN buses 13 in the vehicle 1, information exchanged between each in-vehicle communication device 111, and information exchanged between the control device 122 and the in-vehicle communication device 111.
[0053] [Detection device] FIG. 5 is a diagram illustrating a configuration of a detection device according to an embodiment of the present disclosure.
[0054] 5, the detection device 200 includes a measurement unit 210, a calculation unit 220, an acquisition unit 230, a detection unit 240, a notification unit 250, and a storage unit 260.
[0055] The measuring unit 210, the calculating unit 220, the acquiring unit 230, the detecting unit 240, and the notifying unit 250 are realized by a processor such as a CPU (Central Processing Unit) and a DSP (Digital Signal Processor), etc. The storage unit 260 is, for example, a non-volatile memory.
[0056] The detection device 200 is used in the in-vehicle network 12 including the CAN bus 13 and a plurality of functional units connected to the CAN bus 13, and performs a detection process to detect an abnormality related to the CAN bus 13. For example, the detection device 200 performs the detection process every time the user of the vehicle 1 turns on the accessory power supply or the ignition power supply. Note that the detection device 200 may be configured to perform the detection process periodically or irregularly, for example, after the power supply of the vehicle 1 is turned on until the power supply is turned off.
[0057] [Measurement section] The measurement unit 210 measures the signal waveform of the CAN frame transmitted on the CAN bus 13 .
[0058] For example, the CAN bus 13 is a twisted pair of wires composed of a high-voltage side bus and a low-voltage side bus. The signal waveform of the CAN frame transmitted on the CAN bus 13 is a pulse signal waveform in which the differential voltage Vd between the voltages of the high-voltage side bus and the low-voltage side bus is zero V or 2 V.
[0059] In the detection process, the measurement unit 210 measures the signal waveform of the CAN frame by sampling the differential voltage Vd on the CAN bus 13 in accordance with a predetermined sampling period.
[0060] FIG. 6 is a diagram illustrating an example of a signal waveform of a CAN frame transmitted in a CAN bus according to an embodiment of the present disclosure.
[0061] 6, the measurement unit 210 detects the SOF of a CAN frame transmitted from a certain control device 122 by monitoring the differential voltage Vd on the CAN bus 13. When the measurement unit 210 detects the SOF of the CAN frame, it sets a measurement period Tm based on the detection timing of the SOF and samples the differential voltage Vd during the measurement period Tm.
[0062] For example, the measurement unit 210 measures the pulse signal waveform in the range from the Control field to the CRC field in the CAN frame. More specifically, the measurement unit 210 samples the differential voltage Vd in the rising period of the signal waveform and the differential voltage Vd in the falling period of the signal waveform in the range from the Control field to the CRC field of the CAN frame.
[0063] Here, the data transfer rate in the CAN bus 13 is, for example, 500 kbps. Furthermore, the data length of the Arbitration field, which is a field between the SOF and the Control field in the CAN frame, is 12 bits.
[0064] Therefore, when the measurement unit 210 detects the SOF of the CAN frame at time t0, it samples the differential voltage Vd during the rising period of the signal waveform and the differential voltage Vd during the falling period of the signal waveform during the measurement period Tm, which is the period between time ts, which is 28 μsec after time t0, which is the time required to transfer, for example, 14 bits of data, and time te, which is a predetermined time after time ts.
[0065] The measurement section 210 stores in the storage section 260 a plurality of sampling data Vsmp obtained by sampling the differential voltage Vd during the measurement period Tm.
[0066] Then, based on the sampling data Vsmp in the storage unit 260, the measurement unit 210 detects the time ta at which the differential voltage Vd rises from zero V to 1 V during the measurement period Tm.
[0067] The measurement unit 210 selects the sampling data Vsmp of the differential voltage Vd in the target period Ta, which is the period between time ta0, which is 80 n seconds before the time ta, and time ta1, which is 125 n seconds after the time ta, from the multiple sampling data Vsmp in the storage unit 260. Hereinafter, the sampling data Vsmp of the differential voltage Vd in the target period Ta selected by the measurement unit 210 is also referred to as target data Sa.
[0068] Similarly, based on the sampling data Vsmp in the storage unit 260, the measurement unit 210 detects the time tb at which the differential voltage Vd drops from 2V to 1V during the measurement period Tm.
[0069] The measurement unit 210 selects the sampling data Vsmp of the differential voltage Vd in a target period Tb, which is a period between time tb0, which is 80 n seconds before time tb, and time tb1, which is 125 n seconds after time tb, from the multiple sampling data Vsmp in the storage unit 260. Hereinafter, the sampling data Vsmp of the differential voltage Vd in the target period Tb selected by the measurement unit 210 is also referred to as target data Sb.
[0070] For example, when the measurement section 210 detects an SOF in a certain CAN frame, it selects one pair of target data Sa, Sb from the multiple sampling data Vsmp in the CAN frame, as described above.
[0071] Furthermore, the measurement unit 210 acquires the ID of the control device 122 that is the transmission source of the CAN frame transmitted through the CAN bus 13. More specifically, the measurement unit 210 acquires the ID of the Arbitration field in the CAN frame that is the measurement target.
[0072] The measurement unit 210 generates measurement information including the acquired ID and the selected target data Sa, Sb, and outputs the generated measurement information to the calculation unit 220.
[0073] For example, the measurement unit 210 measures the signal waveform of each of a plurality of CAN frames transmitted from a plurality of control devices 122, respectively.
[0074] More specifically, the measurement unit 210 selects target data Sa, Sb from the sampling data Vsmp of the differential voltage Vd in the CAN frame transmitted from the control device 122A, and generates measurement information MA including the ID of the control device 122A and the selected target data Sa, Sb.
[0075] Furthermore, the measurement unit 210 selects target data Sa, Sb from the sampling data Vsmp of the differential voltage Vd in the CAN frame transmitted from the control device 122B, and generates measurement information MB including the ID of the control device 122B and the selected target data Sa, Sb.
[0076] Furthermore, the measurement unit 210 selects target data Sa, Sb from the sampling data Vsmp of the differential voltage Vd in the CAN frame transmitted from the control device 122C, and generates measurement information MC including the ID of the control device 122C and the selected target data Sa, Sb.
[0077] Hereinafter, each of the control devices 122A, 122B, 122C that are the transmission sources of the CAN frames to be measured will also be referred to as a target control device 122.
[0078] The measurement section 210 outputs the generated measurement information MA, MB, and MC to the calculation section 220.
[0079] [Calculation section] The calculation section 220 calculates a plurality of types of feature quantities of the signal waveform of the CAN frame measured by the measurement section 210.
[0080] For example, the calculation unit 220 calculates at least two of the mean, variance, skewness, kurtosis, Klichkoff irregularity, Jensen irregularity, spectral crest factor, and root mean square of the voltage value obtained by sampling the signal waveform of the CAN frame as the above-mentioned feature quantities.
[0081] More specifically, when the calculation unit 220 receives measurement information from the measurement unit 210, it performs calculations using the target data Sa, Sb indicated by the received measurement information to calculate multiple types of feature quantities of the signal waveform of the CAN frame during the target periods Ta, Tb.
[0082] Here, the average, which is an example of a feature amount, is expressed by the following formula (1).
number
[0083] Moreover, variance, which is an example of a feature quantity, is expressed by the following formula (2).
number
[0084] Moreover, the skewness, which is an example of a feature amount, is expressed by the following formula (3).
number
[0085] Moreover, kurtosis, which is an example of a feature amount, is expressed by the following formula (4).
number
[0086] Moreover, Klichkoff irregularity, which is an example of a feature, is expressed by the following equation (5).
number
[0087] Moreover, Jensen's irregularity, which is an example of a feature, is expressed by the following equation (6).
number
[0088] Moreover, the spectral crest factor, which is an example of a feature quantity, is expressed by the following equation (7).
number
[0089] Moreover, the root mean square, which is an example of a feature quantity, is expressed by the following formula (8).
number
[0090] In equations (1) to (8), L is the sum of the number of voltage values included in the target data Sa and the number of voltage values included in the target data Sb. yh is the h-th voltage value in the target data Sa, Sb. ybar is the average value of the voltage values in the target data Sa, Sb. σ is the standard deviation of the voltage values in the target data Sa, Sb. Furthermore, ah indicates the h-th intensity in the spectrum obtained by Fourier transforming the voltage values in the target data Sa, Sb. h is an integer from 1 to L.
[0091] Hereinafter, a set of multiple types of feature amounts calculated by the calculation unit 220 is also referred to as a determination feature amount. The determination feature amount is, for example, a mean and a variance.
[0092] For example, the calculation section 220 calculates, for each target control device 122, a determination feature amount of the signal waveform measured by the measurement section 210.
[0093] More specifically, the calculation unit 220 receives measurement information MA including the ID of the control device 122A from the measurement unit 210, and performs calculations using the target data Sa, Sb included in the received measurement information MA to calculate a judgment feature FA of the CAN frame transmitted from the control device 122A, and generates calculation information CA including the calculated judgment feature FA and the ID of the control device 122A.
[0094] In addition, the calculation unit 220 receives measurement information MB including the ID of the control device 122B from the measurement unit 210, and performs calculations using the target data Sa, Sb included in the received measurement information MB to calculate a judgment feature FB of the CAN frame transmitted from the control device 122B, and generates calculation information CB including the calculated judgment feature FB and the ID of the control device 122B.
[0095] In addition, the calculation unit 220 receives measurement information MC including the ID of the control device 122C from the measurement unit 210, and performs calculations using the target data Sa, Sb included in the received measurement information MC to calculate a judgment feature FC of the CAN frame transmitted from the control device 122C, and generates calculation information CC including the calculated judgment feature FC and the ID of the control device 122C.
[0096] The calculation unit 220 outputs the generated calculation information CA, CB, and CC to the detection unit 240.
[0097] [Acquisition Department] The acquiring unit 230 acquires a reference distribution, which is a distribution of each feature amount generated in advance.
[0098] For example, the reference distribution is a distribution of determination features of signal waveforms of a plurality of CAN frames transmitted from the target control device 122, which is generated in advance in another device before the vehicle 1 is shipped.
[0099] For example, the acquiring section 230 acquires, as a reference distribution, a probability density function p(x) of a mixed normal distribution with a variable x, as shown in the following formula (9).
number
[0100] The probability density function N of the k-th multivariate normal distribution in equation (9) is expressed by the following equation (10).
number
[0101] Here, x is [x1, x2, x3, ... xm], x1, x2, x3, ... xm are the values of each judgment feature, and m is the number of types of features.
[0102] n is the mixture number of normal distributions. n is a value corresponding to the number of target control devices 122, for example, 3. μk is a 1×m average vector in the k-th normal distribution. Sigma k is an m×m variance-covariance matrix in the k-th normal distribution. πk is a mixture ratio of the probability density function N of the k-th multivariate normal distribution, and satisfies the following formula (11). k is an integer from 1 to n.
number
[0103] For example, before shipping vehicle 1, the manufacturer of vehicle 1 controls the three target control devices 122 to transmit CAN frames a total of 500 times, and generates a distribution of judgment features of the signal waveforms of a total of 500 CAN frames transmitted from the three target control devices 122, which are calculated by the detection device 200.
[0104] Fig. 7 is a diagram illustrating an example of a distribution of determination features calculated in a detection device according to an embodiment of the present disclosure. Fig. 7 illustrates a two-dimensional distribution of two types of determination features, namely, "average" and "variance," as an example of the distribution of the determination features.
[0105] 7, the two-dimensional distribution of the mean and variance of the signal waveform of the CAN frame calculated in the detection device 200 has three clusters. The number of clusters in the two-dimensional distribution corresponds to the number of target control devices 122.
[0106] Specifically, for example, the cluster formed within the dashed frame CLA corresponds to the distribution of the mean and variance of the signal waveform of the CAN frame transmitted from the target control device 122A, the cluster formed within the dashed frame CLB corresponds to the distribution of the mean and variance of the signal waveform of the CAN frame transmitted from the target control device 122B, and the cluster formed within the dashed frame CLC corresponds to the distribution of the mean and variance of the signal waveform of the CAN frame transmitted from the target control device 122C.
[0107] The manufacturer of the vehicle 1 generates a probability density function p(x) of a mixed normal distribution using a Gaussian Mixture Model (GMM) based on the generated two-dimensional distribution. The manufacturer of the vehicle 1 may generate the probability density function p(x) using a simulation technique without actually causing the target control device 122 to transmit a CAN frame.
[0108] In addition, the manufacturer of vehicle 1 uses the generated probability density function p(x) to calculate a score value s shown in the following equation (12) for the value x of the determination feature calculated from the 500 CAN frames.
number
[0109] Fig. 8 is a diagram showing an example of the distribution of scores calculated in a detection device according to an embodiment of the present disclosure. In Fig. 8, the vertical axis represents the score s, and the horizontal axis represents the frame numbers from 1 to 500 assigned to 500 CAN frames.
[0110] Referring to FIG. 8, the manufacturer of vehicle 1 sets a threshold value Th for determining that the bottom 1% in a distribution of 500 score values s corresponding to 500 CAN frames is abnormal, and registers the set threshold value Th in memory unit 260 of detection device 200.
[0111] When the acquiring section 230 receives a reference distribution request from the detecting section 240, the acquiring section 230 acquires the probability density function p(x) and the threshold value Th from the storage section 260 and outputs them to the detecting section 240 in response to the received reference distribution request.
[0112] [Detection unit] The detection unit 240 detects an abnormality related to the CAN bus 13 based on the determination feature calculated by the calculation unit 220.
[0113] The detection unit 240 detects, as abnormalities related to the CAN bus 13, the connection of new devices, such as an ECU or measuring device, to the CAN bus 13, a physical abnormality in the CAN bus 13 itself, and an abnormality in the control device 122.
[0114] More specifically, upon receiving the calculation information from the calculation unit 220, the detection unit 240 detects an abnormality related to the CAN bus 13 based on the received calculation information.
[0115] For example, the detection unit 240 detects an abnormality related to the CAN bus 13 based on the determination feature calculated by the calculation unit 220 and the probability density function p(x) acquired by the acquisition unit 230.
[0116] For example, the detection unit 240 detects an abnormality related to the CAN bus 13 based on a plurality of sets of determination features and a probability density function p(x) calculated by the calculation unit 220 for each target control device 122.
[0117] More specifically, when the detection unit 240 receives the calculation information CA, CB, and CC from the calculation unit 220, the detection unit 240 acquires the determination features FA, FB, FC, and ID from the received calculation information CA, CB, and CC, respectively. In addition, the detection unit 240 outputs a reference distribution request to the acquisition unit 230.
[0118] When the detection unit 240 receives the probability density function p(x) and the threshold value Th from the acquisition unit 230, it calculates three score values s according to equations (9), (10), and (12) based on the received probability density function p(x) and each value x of the judgment features FA, FB, and FC.
[0119] Then, the detection unit 240 compares the three calculated score values s with the threshold value Th received from the acquisition unit 230, and if all of the three score values s are equal to or greater than the threshold value Th, it determines that no abnormality has occurred regarding the CAN bus 13. On the other hand, if at least one of the three score values s is smaller than the threshold value Th, the detection unit 240 determines that an abnormality has occurred regarding the CAN bus 13.
[0120] Fig. 9 is a diagram showing another example of the distribution of the determination feature calculated in the detection device according to the embodiment of the present disclosure. Fig. 9 shows a two-dimensional distribution of the "average" and "variance" calculated by the calculation unit 220 in a state in which a new device is connected to the CAN bus 13 after the shipment of the vehicle 1. The dashed-line frames CLA, CLB, and CLC in Fig. 9 are the same as the dashed-line frames CLA, CLB, and CLC shown in Fig. 7.
[0121] Referring to Figure 9, when a new device is connected to the CAN bus 13, the distribution of judgment features calculated by the calculation unit 220 falls outside the dashed frames CLA, CLB, and CLC in which the distribution of judgment features in the normal state before the vehicle 1 was shipped was contained.
[0122] Fig. 10 is a diagram showing another example of the distribution of the scores calculated in the detection device according to the embodiment of the present disclosure. Fig. 10 shows the score values s corresponding to 500 CAN frames calculated by the calculation unit 220 in a state in which a new device is connected to the CAN bus 13 after the shipment of the vehicle 1.
[0123] 10, when a new device is connected to CAN bus 13, score value s calculated by calculation unit 220 becomes a value less than threshold value Th.
[0124] The detection unit 240 outputs the determination result of the abnormality regarding the CAN bus 13 to the notification unit 250.
[0125] When the notification unit 250 receives a determination result from the detection unit 240 indicating that an abnormality has occurred regarding the CAN bus 13, the notification unit 250 transmits warning information indicating the occurrence of the abnormality to a higher-level device within or outside the vehicle 1.
[0126] [Operation flow] Each device in the in-vehicle communication system according to the embodiment of the present disclosure includes a computer including a memory, and a processor such as a CPU in the computer reads out from the memory and executes a program including some or all of the steps in the following flowcharts and sequences. Each of the programs for the devices can be installed from the outside. Each of the programs for the devices is distributed in a state in which it is stored in a recording medium.
[0127] FIG. 11 is a flowchart defining an example of an operation procedure when the detection device in the in-vehicle system according to the embodiment of the present disclosure performs the detection process.
[0128] Referring to FIG. 11, first, the detection device 200 obtains a probability density function p(x) and a threshold value Th (step S102).
[0129] Next, the detection device 200 waits for a CAN frame transmitted from a certain control device 122 (NO in step S104), and when it detects an SOF of the CAN frame transmitted from a certain control device 122 (YES in step S104), it measures the signal waveform of the CAN frame. More specifically, the detection device 200 generates target data Sa, Sb in the rising and falling periods of the CAN frame (step S106).
[0130] Next, the detection device 200 calculates a determination feature of the signal waveform of the CAN frame. More specifically, the detection device 200 calculates the determination feature by performing an operation using the generated target data Sa and Sb (step S108).
[0131] Next, the detection device 200 calculates a score value s based on the acquired probability density function p(x) and the calculated determination feature amount (step S110).
[0132] Next, the detection device 200 compares the calculated score value s with the obtained threshold value Th (step S112).
[0133] Next, if the score value s is equal to or greater than the threshold value Th (YES in step S114), the detection device 200 determines that no abnormality has occurred regarding the CAN bus 13 (step S116).
[0134] On the other hand, if the score value s is less than the threshold value Th (NO in step S114), the detection device 200 determines that an abnormality has occurred regarding the CAN bus 13 (step S118).
[0135] FIG. 12 is a diagram illustrating an example of a sequence of a detection process in the in-vehicle system according to the embodiment of the present disclosure.
[0136] Referring to FIG. 12, first, the detection device 200 obtains a probability density function p(x) and a threshold value Th (step S202).
[0137] Next, the control device 122A transmits a CAN frame F1 addressed to the other control device 122 via the CAN bus 13 (step S204).
[0138] Next, the detection device 200 monitors the differential voltage Vd on the CAN bus 13, and upon detecting the SOF of the CAN frame F1 transmitted from the control device 122A, measures the signal waveform of the CAN frame F1 (step S206).
[0139] Next, the control device 122B transmits a CAN frame F2 addressed to the other control device 122 via the CAN bus 13 (step S208).
[0140] Next, the detection device 200 monitors the differential voltage Vd on the CAN bus 13, and upon detecting the SOF of the CAN frame F2 transmitted from the control device 122B, measures the signal waveform of the CAN frame F2 (step S210).
[0141] Next, the control device 122C transmits a CAN frame F3 addressed to the other control device 122 via the CAN bus 13 (step S212).
[0142] Next, the detection device 200 detects the SOF of the CAN frame F3 transmitted from the control device 122C by monitoring the differential voltage Vd on the CAN bus 13, and then measures the signal waveform of the CAN frame F3 (step S214).
[0143] Next, the detection device 200 calculates determination feature quantities of the signal waveforms of the CAN frames F1, F2, and F3 (step S216).
[0144] Next, the detection device 200 calculates a score value s corresponding to each determination feature based on the acquired probability density function p(x) and each of the calculated determination features (step S218).
[0145] Next, the detection device 200 compares the calculated three score values s with a threshold value Th, and determines whether or not an abnormality has occurred regarding the CAN bus 13 based on the comparison result. More specifically, when all of the three score values s are equal to or greater than the threshold value Th, the detection device 200 determines that an abnormality has occurred regarding the CAN bus 13. On the other hand, when at least one of the three score values s is smaller than the threshold value Th, the detection unit 240 determines that an abnormality has occurred regarding the CAN bus 13 (step S220).
[0146] In the in-vehicle system 301 according to the embodiment of the present disclosure, the detection device 200 is a device separate from the control device 122, but this is not limited thereto. The detection device 200 may be included in the control device 122 or the gateway device 101.
[0147] In addition, in the detection device 200 according to the embodiment of the present disclosure, the acquiring unit 230 is configured to acquire the probability density function p(x) and the threshold value Th from the storage unit 260 in the detection device 200, but this is not limited to the above. The acquiring unit 230 may be configured to acquire the probability density function p(x) and the threshold value Th from a storage unit outside the detection device 200.
[0148] In addition, in the detection device 200 according to the embodiment of the present disclosure, the detection unit 240 is configured to calculate the score value s based on a reference distribution, i.e., a probability density function p(x), generated using GMM, and detect an abnormality related to the CAN bus 13 based on a comparison result between the calculated score value s and a threshold value, but this is not limited to the above. The detection unit 240 may be configured to detect an abnormality related to the CAN bus 13 using, for example, a Local Outlier Factor (LOF), a One-Class Support Vector Machine (OCSVM), or an Isolation Forest (IF).
[0149] In addition, in the detection device 200 according to the embodiment of the present disclosure, the calculation unit 220 is configured to calculate at least two of the mean, variance, skewness, kurtosis, Cliffkoff's irregularity, Jensen's irregularity, spectral crest factor, and root mean square as the determination feature by performing an operation using the target data Sa and Sb indicated by the measurement information received from the measurement unit 210, but is not limited to this. The calculation unit 220 may be configured to calculate a feature other than the above as the determination feature instead of the above feature. Furthermore, the calculation unit 220 may be configured to calculate a feature other than the above as the determination feature in addition to the above feature.
[0150] In addition, in the detection device 200 according to the embodiment of the present disclosure, the measurement unit 210 is configured to measure a pulse signal waveform in a range from the Control field to the CRC field in the CAN frame, but this is not limited thereto. The measurement unit 210 may be configured to measure a pulse signal waveform in an ACK field in the CAN frame, for example. The measurement unit 210 may also be configured to measure a signal waveform in a portion other than the rising or falling edge in the CAN frame. The measurement unit 210 may also be configured to measure at least one of the signal waveform in the rising portion and the signal waveform in the falling portion in the CAN frame.
[0151] Furthermore, in the detection device 200 according to the embodiment of the present disclosure, the detection unit 240 is configured to detect an abnormality related to the CAN bus 13 based on multiple sets of determination feature amounts and the probability density function p(x) calculated for each target control device 122 by the calculation unit 220, but this is not limited to this. The detection unit 240 may be configured to detect an abnormality related to the CAN bus 13 based on one set of determination feature amounts and the probability density function p(x) calculated by the calculation unit 220.
[0152] Furthermore, in the detection device 200 according to the embodiment of the present disclosure, the measurement unit 210 is configured to generate measurement information including the ID of the control device 122 that is the source of the CAN frame and the selected target data Sa, Sb, and output the generated measurement information to the calculation unit 220, but this is not limited to this. The measurement unit 210 may be configured to generate measurement information that includes the target data Sa, Sb and does not include the ID of the control device 122 that is the source of the CAN frame, and output the generated measurement information to the calculation unit 220.
[0153] Furthermore, in the detection device 200 according to the embodiment of the present disclosure, the calculation unit 220 is configured to generate calculation information including the ID of the control device 122 that is the transmission source of the CAN frame and the calculated determination feature, and output the generated calculation information to the detection unit 240; however, this is not limited to the above. The calculation unit 220 may be configured to generate calculation information that includes the determination feature and does not include the ID of the control device 122 that is the transmission source of the CAN frame, and output the generated calculation information to the detection unit 240.
[0154] In addition, in the detection device 200 according to the embodiment of the present disclosure, the detection unit 240 is configured to calculate three score values s based on the values x of the determination feature quantities FA, FB, and FC of the CAN frames transmitted from the multiple target control devices 122, and detect an abnormality related to the CAN bus 13 based on a comparison result between the calculated three score values s and a threshold value Th, but this is not limited to the above. The detection unit 240 may also be configured to calculate one score value s based on the value x of the determination feature quantity of the CAN frame transmitted from one target control device 122, and detect an abnormality related to the CAN bus 13 based on a comparison result between the calculated score value s and a threshold value Th.
[0155] More specifically, for example, every time the detection unit 240 receives calculation information that does not include the ID of the control device 122 that is the transmission source of the CAN frame from the calculation unit 220, the detection unit 240 acquires a determination feature from the received calculation information and calculates one score value s based on the value x of the acquired determination feature. Then, the detection unit 240 detects an abnormality related to the CAN bus 13 based on a result of comparing the calculated score value s with a threshold value Th.
[0156] Meanwhile, there is a demand for a technology that enables more accurate detection of abnormalities related to the CAN bus in an in-vehicle network with a simple configuration.
[0157] For example, in the technology described in Non-Patent Document 1, in order to detect the connection of an unauthorized device to a network using a TDR, it is necessary to separately use a pulse signal generator that applies a pulse signal to the network. Also, in the technology described in Non-Patent Document 1, when performing a process to detect the connection of an unauthorized device, it is necessary to stop communication, for example, on a CAN bus.
[0158] In addition, with the technology described in Patent Document 1, it is not easy to detect minute changes related to the CAN bus, such as the connection of a new device to the CAN bus, and therefore it may not be possible to accurately detect abnormalities related to the CAN bus.
[0159] In contrast, in the detection device 200 according to the embodiment of the present disclosure, the measurement unit 210 measures the signal waveform of a frame transmitted through the CAN bus 13. The calculation unit 220 calculates a plurality of types of feature quantities of the signal waveform measured by the measurement unit 210. The detection unit 240 detects an abnormality related to the CAN bus 13 based on each feature quantity calculated by the calculation unit 220.
[0160] In an in-vehicle system 301 according to an embodiment of the present disclosure, a control device 122 transmits a frame to another control device 122 via the CAN bus 13. A detection device 200 measures a signal waveform of the frame transmitted through the CAN bus 13. The detection device 200 calculates a plurality of types of feature quantities of the measured signal waveform. The detection device 200 detects an abnormality related to the CAN bus 13 based on each calculated feature quantity.
[0161] A detection method according to an embodiment of the present disclosure is a detection method in a detection device used in an in-vehicle network 12 including a CAN bus 13 and a plurality of control devices 122 connected to the CAN bus 13. In this detection method, first, the detection device 200 measures a signal waveform of a frame transmitted through the CAN bus 13. Next, the detection device 200 calculates a plurality of types of feature quantities of the measured signal waveform. Next, the detection device 200 detects an abnormality related to the CAN bus 13 based on each of the calculated feature quantities.
[0162] In this way, by focusing on the characteristics of the signal waveform of the frame transmitted on the CAN bus 13 and calculating multiple types of characteristics to detect abnormalities related to the CAN bus 13, it is possible to detect minute changes related to the CAN bus, for example, during operation, without using a device that applies a pulse signal to the CAN bus 13.
[0163] Therefore, the detection device, in-vehicle system, and detection method according to the embodiments of the present disclosure can more accurately detect anomalies related to the CAN bus in an in-vehicle network with a simple configuration.
[0164] The above-described embodiments should be considered as illustrative and not restrictive in all respects. The scope of the present invention is defined by the claims, not the above description, and is intended to include all modifications within the meaning and scope of the claims.
[0165] The above description includes the following additional features. [Appendix 1] A detection device for use in an in-vehicle network including a CAN bus and a plurality of functional units connected to the CAN bus, A measurement unit that measures a signal waveform of a frame transmitted on the CAN bus; a calculation unit that calculates a plurality of types of feature quantities of the signal waveform measured by the measurement unit; a detection unit that detects an abnormality related to the CAN bus based on each of the feature amounts calculated by the calculation unit, The measurement unit, the calculation unit, and the detection unit are realized by a processor.
[0166] [Appendix 2] A detection device for use in an in-vehicle network including a CAN bus and a plurality of functional units connected to the CAN bus, A measurement unit that measures a signal waveform of a frame transmitted on the CAN bus; a calculation unit that calculates a plurality of types of feature quantities of the signal waveform measured by the measurement unit; a detection unit that detects an abnormality related to the CAN bus based on each of the feature amounts calculated by the calculation unit, The detection device further comprises: an acquisition unit that acquires a probability density function that is a distribution of each of the feature amounts that is generated before a new device is connected to the CAN bus; The detection unit calculates a score value for each of the feature amounts using the feature amounts calculated by the calculation unit and the probability density function acquired by the acquisition unit, and detects an abnormality related to the CAN bus based on the calculated score values.
[0167] [Appendix 3] A plurality of functional units connected to a CAN bus; A detection device, The functional unit transmits a frame to another functional unit via the CAN bus; The detection device measures a signal waveform of the frame transmitted on the CAN bus, the detection device calculates a plurality of types of feature quantities of the measured signal waveform; The detection device detects an abnormality related to the CAN bus based on each of the calculated feature amounts, The functional unit is a gateway device or an ECU.
[0168] [Appendix 4] A plurality of functional units connected to a CAN bus; A detection device, The functional unit transmits a frame to another functional unit via the CAN bus; The detection device measures a signal waveform of the frame transmitted on the CAN bus, the detection device calculates a plurality of types of feature quantities of the measured signal waveform; The detection device detects an abnormality related to the CAN bus based on each of the calculated feature amounts, The detection device obtains a probability density function, which is a distribution of each of the feature amounts that is generated in advance before the new device is connected to the CAN bus; The detection device calculates a score value for each of the calculated feature amounts using the calculated feature amounts and the acquired probability density function, and detects an abnormality related to the CAN bus based on the calculated score values. [Explanation of symbols]
[0169] 1 vehicle 12 In-vehicle network 13 CAN Bus 14 Bus 101 Gateway device 111 Vehicle communication device 121 Bus connection devices 122, 122A, 122B, 122C Control device 200 Detection Device 210 Measurement Division 220 Calculation Unit 230 Acquisition Department 240 Detection Unit 250 Notification Department 260 Storage section 301 In-vehicle systems
Claims
1. A detection device for use in an in-vehicle network including a CAN (Controller Area Network) bus and a plurality of functional units connected to the CAN bus, A measurement unit that measures a signal waveform of a frame transmitted on the CAN bus; a calculation unit that calculates a plurality of types of feature quantities of the signal waveform measured by the measurement unit; a detection unit that detects an abnormality related to the CAN bus based on each of the feature amounts calculated by the calculation unit, The measurement unit measures a pulse signal waveform in a range from a control field to a CRC (Cyclic Redundancy Check) field in the frame.
2. The detection device further comprises: An acquisition unit that acquires a reference distribution, which is a distribution of each of the feature amounts generated in advance, The detection device according to claim 1 , wherein the detection unit detects an anomaly related to the CAN bus based on the feature amounts calculated by the calculation unit and the reference distribution acquired by the acquisition unit.
3. A detection device as described in claim 1 or claim 2, wherein the calculation unit calculates at least two of the mean, variance, skewness, kurtosis, Klichkoff's irregularity, Jensen's irregularity, spectral crest factor and root mean square of the voltage value obtained by sampling the signal waveform as the respective feature quantities.
4. The measurement unit measures the signal waveform of each of the plurality of frames transmitted from the plurality of functional units, the calculation unit calculates a plurality of types of feature amounts of each of the signal waveforms measured by the measurement unit, The detection device according to claim 1 , wherein the detection unit detects an abnormality related to the CAN bus based on the plurality of types of feature amounts of each of the signal waveforms calculated by the calculation unit.
5. A plurality of functional units connected to a CAN bus; A detection device, The functional unit transmits a frame to another functional unit via the CAN bus, The detection device measures a signal waveform of the frame transmitted on the CAN bus, the detection device calculates a plurality of types of feature quantities of the measured signal waveform; The detection device detects an abnormality related to the CAN bus based on each of the calculated feature amounts, The detection device measures a pulse signal waveform in the range from a Control field to a CRC field in the frame.
6. A detection method for a detection device used in an in-vehicle network including a CAN bus and a plurality of functional units connected to the CAN bus, comprising: Measuring a signal waveform of a frame transmitted on the CAN bus; calculating a plurality of types of feature quantities of the measured signal waveform; detecting an abnormality related to the CAN bus based on each of the calculated feature amounts; In the step of measuring the signal waveform, a pulse signal waveform in a range from a Control field to a CRC field in the frame is measured.
Citation Information
Patent Citations
Failure detecting method and failure detection system of communication network
JP2009302783A
System and method for detecting and locating faults in electronic communication bus systems
US20080043629A1
Microcontroller network diagnostic system
US20100082805A1
In-vehicle network anomaly detection
US20180248766A1
