Estimation device, estimation method, and program
The estimation device converts packet data into vector form using BERT to detect abnormal bytes in OT networks, addressing the inability of existing systems to identify such anomalies and preventing accidents.
Patent Information
- Application Number
- JP2023504910
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Filing Date
- 2021-03-09
- Publication Date
- 2024-10-17
- Estimated Expiration
- 2041-03-09
AI Technical Summary
Existing anomaly detection systems in operational technology (OT) communication networks are unable to identify abnormal bytes in abnormal packets, which can lead to serious accidents due to unauthorized rewriting.
An estimation device that converts packet data into vector data using a model like BERT, allowing for the detection of abnormal packet data by comparing it with normal vector data to estimate abnormal bytes based on similarity metrics.
Enables the detection of even small unauthorized rewrites, such as one byte, in operational technology networks, preventing potential accidents by accurately identifying abnormal bytes in packets.
Smart Images

Figure 0007568975000001 
Figure 0007568975000002 
Figure 0007568975000003
Abstract
Description
[Technical field]
[0001] The present invention relates to an estimation device, an estimation method, and a program. [Background technology]
[0002] Anomaly detection systems or intrusion detection systems (OT-IDS: Operational Technology Intrusion Detection System) are attracting attention in communication networks of operational technology (OT) in industrial and building systems. Packets sent and received in such communication networks must be detected without overlooking even small unauthorized rewrites such as one byte. For example, unauthorized rewrites can cause a temperature setting to change by one digit, and other unexpected operations can cause serious accidents.
[0003] There are tools for monitoring networks (see Non-Patent Document 1 and Non-Patent Document 2). These tools can monitor and analyze data transmitted and received over a network. [Prior art documents] [Non-patent literature]
[0004] [Non-Patent Document 1] WIRESHARK, [online], [Retrieved February 25, 2021], Internet〈URL:https: / / www.wireshark.org / 〉 [Non-Patent Document 2] zeek, [online], [Retrieved February 25, 2021], Internet〈URL:https: / / zeek.org / 〉 Summary of the Invention [Problem to be solved by the invention]
[0005] However, none of the non-patent documents can identify anomalous bytes in anomalous packets.
[0006] The present invention has been made in consideration of the above circumstances, and an object of the present invention is to provide a technique capable of estimating an abnormal byte in an abnormal packet. [Means for solving the problem]
[0007] An estimation device according to one embodiment of the present invention includes a conversion unit that converts abnormal packet data into abnormal vector data using a model that converts packet data into vector data in which each byte of the packet data is associated with a vector that represents a characteristic of the value of each byte, an extraction unit that extracts normal vector data that has a relatively high similarity to the abnormal vector data from a plurality of normal vector data obtained by converting a plurality of normal packet data using the model, and an estimation unit that estimates abnormal bytes in the abnormal packet data from the similarity between a vector corresponding to each byte of the abnormal vector data and a vector corresponding to each byte of the extracted normal vector data.
[0008] In one embodiment of the estimation method of the present invention, a computer converts abnormal packet data into abnormal vector data using a model that converts packet data into vector data in which each byte of the packet data is associated with a vector that represents a characteristic of the value of each byte, the computer extracts normal vector data that has a relatively high similarity to the abnormal vector data from a plurality of normal vector data obtained by converting a plurality of normal packet data using the model, and the computer estimates abnormal bytes in the abnormal packet data from the similarity between a vector corresponding to each byte of the abnormal vector data and a vector corresponding to each byte of the extracted normal vector data.
[0009] One aspect of the present invention is a program for causing a computer to function as the estimation device. Effect of the Invention
[0010] According to the present invention, it is possible to provide a technique capable of estimating an abnormal byte in an abnormal packet. [Brief description of the drawings]
[0011] [Figure 1] FIG. 1 is a diagram illustrating functional blocks of an estimation device according to an embodiment of the present invention. [Diagram 2] FIG. 2 is a diagram illustrating an example of data that is converted by a model. [Diagram 3] FIG. 3 is a flowchart showing an example of the process of the estimation method. [Figure 4] FIG. 4 is a diagram illustrating each device in the estimation device evaluation system. [Diagram 5] FIG. 5 is a diagram illustrating an example of a packet obtained by the evaluation system. [Figure 6] FIG. 6 is a diagram illustrating an example of a similarity matrix obtained by the evaluation system. [Figure 7] FIG. 7 is a diagram illustrating the hardware configuration of a computer used in the estimation device. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0012] Hereinafter, an embodiment of the present invention will be described with reference to the drawings. In the description of the drawings, the same parts are given the same reference numerals and the description will be omitted.
[0013] (estimation device) An estimation device 1 according to an embodiment of the present invention will be described with reference to FIG. 1. When an abnormal packet is input, the estimation device 1 estimates and outputs abnormal bytes in the abnormal packet. The estimation device 1 compares an abnormal packet determined to be abnormal by another system with a normal packet determined to be normal by the other system to estimate abnormal bytes in the input abnormal packet. For example, normal packets and abnormal packets are each collected in a communication network of one operation technology. The other system may determine whether a packet is normal or abnormal by any method, and the method of determination is not important in the embodiment of the present invention.
[0014] The estimation device 1 includes each data of model data 11, normal vector data group 12, abnormal packet data 15, abnormal vector data 16, normal vector data 17, and abnormal bytes 18, and each function of a conversion unit 21, a generation unit 22, an extraction unit 23, and an estimation unit 24. Each data is stored in a memory 902 or a storage 903. Each function is implemented in a CPU 901.
[0015] The model data 11 specifies a model for converting packet data into vector data. The vector data associates each byte of packet data with a vector that indicates the characteristics of the value of each byte. The model data 11 is generated by a generating unit 22, which will be described later, by learning the values of each byte of a plurality of normal packet data in a normal vector data group 12. The characteristics of the value of each byte are calculated by comparing the values of each byte with the values of the plurality of normal packet data.
[0016] The model data 11 specifies a model that converts each byte of the input packet data into an appropriate fixed-length vector, taking into consideration the positional relationship of each byte, etc. Here, the appropriate fixed-length vector means a vector that can estimate an abnormal byte 18 by comparing the abnormal vector data 16 with the normal vector data 17 in an estimation unit 24 described later. For example, as shown in FIG. 2, there is fixed-length packet data with a first byte value of "2e", a second byte value of "3f", a third byte value of "00", etc. Each byte of this packet data is converted into a 784-dimensional vector by the model. In the example shown in FIG. 2, the model converts each byte of the packet data into a 784-dimensional vector that represents the characteristics of the value of each byte.
[0017] The model data 11 is generated, for example, by BERT (Bidirectional Encoder Representations from Transformers). BERT is a natural language processing model. In an embodiment of the present invention, each byte of packet data is regarded as one word. The packet data is converted into vector data by the model generated using BERT.
[0018] The normal vector data group 12 includes a plurality of normal vector data. The normal vector data is data obtained by converting normal packet data determined to be normal in another system using a model specified by the model data 11. The normal vector data group 12 is referred to when the generation unit 22 generates the model data 11 or when the extraction unit 23 extracts normal vector data 17 similar to the abnormal vector data 16. The generation unit 22 and the extraction unit 23 may both refer to the plurality of normal vector data included in the normal vector data group 12. Alternatively, the plurality of normal vector data included in the normal vector data group 12 may be divided into a plurality of groups, and the generation unit 22 may refer to one group and the extraction unit 23 may refer to another group.
[0019] The abnormal packet data 15 is data of a packet that has been identified as an abnormal packet in another system. The estimation device 1 estimates an abnormal byte 18 for one abnormal packet data 15.
[0020] The abnormal vector data 16 is data obtained by converting the abnormal packet data 15 using a model specified by the model data 11. The abnormal vector data 16 associates an identifier of the position of each byte in the abnormal packet data 15 with each vector that indicates the characteristics of the value of each byte.
[0021] The normal vector data 17 is data that is relatively highly similar to the abnormal vector data 16 among the multiple normal vector data included in the normal vector data group 12. The normal vector data 17 is normal vector data that is most similar to the abnormal vector data 16 among the multiple normal vector data included in the normal vector data group 12. Alternatively, the normal vector data 17 is one of a predetermined number of normal vector data that have high similarity.
[0022] The abnormal byte 18 is data for identifying a byte that is presumed to be abnormal among the bytes of the abnormal packet data 15. The abnormal byte 18 is identified, for example, by the position of each byte of the abnormal packet data 15 counted from the beginning.
[0023] The converter 21 converts the abnormal packet data 15 into abnormal vector data 16 using a model specified by the model data 11. For example, as shown in Fig. 2, the converter 21 converts the value of each byte of the abnormal packet data 15 into a 784-dimensional vector. The converter 21 outputs the abnormal vector data 16 by associating the position of each byte of the abnormal packet data 15 with the 784-dimensional vector converted from the byte.
[0024] The generating unit 22 learns the values of each byte of a plurality of normal packet data in the normal vector data group 12, and generates a model specified by the model data 11. The model converts the packet data into vector data that associates each byte of the packet data with each vector that represents the characteristics of the value of each byte. The generating unit 22 generates the model according to, for example, BERT. The generating unit 22 may pre-learn the characteristics of the value of each byte in the normal packet data by solving auxiliary tasks such as MLM (Masked Language Model) or NSP (Next Sentence Prediction). MLM predicts the values of the missing bytes in a packet in which multiple bytes are missing. NSP determines whether two packet data are consecutive packets. The generating unit 22 identifies the validity of the data in the packet and the validity of the consecutive packets by these auxiliary tasks, and the generating unit 22 generates a model that identifies the normal vector data. The auxiliary tasks listed here are only examples, and the generating unit 22 may learn by solving other auxiliary tasks.
[0025] The extraction unit 23 extracts normal vector data having a relatively high similarity to the abnormal vector data 16 from the multiple normal vector data in the normal vector data group 12. The extraction unit 23 sets the extracted normal vector data as normal vector data 17.
[0026] The similarity being relatively high means that the similarity between the abnormal vector data 16 and a certain normal vector data is higher than the similarity between the abnormal vector data 16 and another normal vector data. The extraction unit 23 may extract normal vector data having the highest similarity to the abnormal vector data 16. Alternatively, the extraction unit 23 may extract one normal vector data from a predetermined number or a predetermined ratio of multiple normal vector data having high similarity to the abnormal vector data 16.
[0027] The extraction unit 23 calculates the similarity between the abnormal vector data 16 and each normal vector data of the normal vector data group 12. The extraction unit 23 may calculate the similarity with a part of the normal vector data of the normal vector data group 12. For example, the part of the normal vector data is a plurality of normal vector data obtained by extracting a plurality of representative packet data from a plurality of normal packet data by MMD-Critic (MMD: Maximum Mean Discrepancy) and converting each of the extracted representative packet data by a model. Alternatively, the part of the normal vector data is a plurality of normal vector data obtained by extracting normal packet data having the same packet length as the abnormal packet data 15 from a plurality of normal packet data and converting each of the extracted normal packet data by a model.
[0028] When the model is BERT, the extraction unit 23 may use BERTScore as the similarity. Alternatively, the extraction unit 23 may calculate the similarity between the vector of the abnormal vector data 16 and the vector of the normal vector data for each byte of the abnormal vector data 16, and calculate the similarity between the abnormal vector data 16 and the normal vector data from the similarity calculated for each byte. The similarity between the vectors of each byte may be Cosine similarity. The similarity between the abnormal vector data 16 and the normal vector data 17 is, for example, the average of the similarities calculated for each byte. At this time, when the number of vectors of the abnormal vector data 16 is different from the number of vectors of the normal vector data 17, the similarity may be calculated according to the number of vectors that is smaller. The number of vectors of each vector data is the number of bytes of packet data before conversion.
[0029] The estimation unit 24 estimates the abnormal bytes 18 in the abnormal packet data 15 from the similarity between the vectors corresponding to each byte of the abnormal vector data 16 and the vectors corresponding to each byte of the extracted normal vector data 17 .
[0030] Estimation part 246 is calculated between each vector included in the abnormal vector data 16 and each vector included in the normal vector data 17. The (n, m) component of the Cosine similarity matrix is the Cosine similarity between the vector corresponding to the n-th byte of the abnormal vector data 16 and the vector corresponding to the m-th byte of the normal vector data 17.
[0031] For example, when the highest similarity among the similarities between a vector corresponding to a predetermined byte of the abnormal packet data 15 and a vector corresponding to each byte of the extracted normal vector data 17 is lower than a predetermined threshold, the estimation unit 24 estimates that the predetermined byte is an abnormal byte 18. Whether the i-th byte of the abnormal packet data 15 is an abnormal byte is estimated as follows. Let m be the packet length of the normal packet data. The estimation unit 24 focuses on each of the (i, 1) component, (i, 2) component, (i, 3) component, ..., (i, m) component of the Cosine similarity matrix calculated above. If the component with the highest Cosine similarity among each correct sentence is equal to or lower than a certain threshold, the estimation unit 24 estimates that the i-th byte is an abnormal byte 18.
[0032] When the number of bytes of the abnormal packet data 15 is the same as the number of bytes of the packet data before conversion of the normal vector data 17, it is possible to compare the vectors corresponding to the same byte of the abnormal packet data 15 and the normal vector data 17. For example, when estimating whether the i-th byte of the abnormal packet data 15 is an abnormal byte, if the similarity between the vector data corresponding to the i-th byte of the abnormal packet data 15 and the vector data corresponding to the i-th byte of the normal packet data is lower than a predetermined threshold, the estimation unit 24 estimates that the i-th byte of the abnormal packet data 15 is an abnormal byte.
[0033] The threshold value for the estimation unit 24 to determine whether or not a byte is abnormal may be a fixed value such as 0.5. Alternatively, the threshold value may be determined by a predetermined calculation. For example, a plurality of pairs of two normal packets similar to each other may be extracted, and the threshold value may be determined from the lowest similarity among the similarities between the vectors of the two normal packets corresponding to a predetermined byte.
[0034] The estimation method performed by the estimation device 1 according to the embodiment of the present invention will be described with reference to FIG.
[0035] In step S1, the estimation device 1 converts the abnormal packet data 15 into abnormal vector data 16. In step S2, the estimation device 1 extracts, from the normal vector data group 12, normal vector data 17 similar to the abnormal vector data 16 converted in step S1.
[0036] The processes in steps S3 to S5 are repeated for each vector in the abnormal vector data 16, in other words, for each vector corresponding to each byte of the abnormal packet data 15.
[0037] The process of step S3 is repeated for each vector of the normal vector data 17 extracted in step S2. In step S3, the estimation device 1 calculates the similarity between the target vector of the abnormal vector data 16 and the target vector of the normal vector data 17. After the similarity is calculated, the process proceeds to step S4.
[0038] In step S4, the estimation device 1 determines whether the highest similarity among the multiple similarities calculated for the target vector in the abnormal vector data 16 and each vector in the normal vector data 17 is lower than a predetermined threshold. If the highest similarity is higher than the predetermined threshold, the estimation device 1 estimates that the target vector in the abnormal vector data 16 does not correspond to an abnormal byte. The estimation device 1 processes step S3 for the next target vector.
[0039] If the highest similarity is lower than a predetermined threshold, the estimation device 1 estimates that the target vector of the abnormal vector data 16 corresponds to an abnormal byte. In step S6, the estimation device 1 outputs the byte corresponding to the target vector of the abnormal vector data 16 as the abnormal byte 18.
[0040] When the processing of steps S3 to S5 is completed for each vector of the abnormal vector data 16, the estimation device 1 ends the processing.
[0041] 4 to 6, the evaluation of the estimation device 1 will be described. In the evaluation of the estimation device 1, a virtual evaluation system is used.
[0042] The evaluation system has four belt conveyors C1-C4 arranged in a rectangle as shown in FIG. 4, and uses a programmable logic controller (PLC) (not shown) to control the movement of luggage B1 and B2. Each device shown in FIG. 4 transmits packets to notify the PLC of its status and receives packets specifying the drive content from the PLC according to the Modbus / TCP protocol or the like. In a normal state, the PLC drives the pushers P1-P4 according to the detection status of the sensors S1-S4, so that the belt conveyors C1-C4 carry luggage B1 and B2 in a counterclockwise direction at a constant speed. The speed of the belt conveyors is continuously monitored by the PLC. If the speed of the belt conveyor exceeds a certain speed, the PLC issues an emergency stop command to each device shown in FIG. 4, and each device stops.
[0043] For example, a package B1 moves on the belt conveyor C1. At this time, the belt conveyor C1 transmits a packet notifying the PLC of the moving speed of the belt. When the package B1 comes into contact with the laser light emitted by the sensor S1, the sensor S1 transmits a packet notifying the PLC that the package has arrived. In the example shown in FIG. 4, the laser light is indicated by a dashed line. When the PLC receives the packet, it transmits a packet to turn on the pusher P1. The pusher P1 extends from the box according to the received packet and carries the package B1 to the belt conveyor C2. When the package is no longer in contact with the laser light emitted by the sensor S1, the sensor S1 transmits a packet to the PLC notifying the PLC that there is no package. When the PLC receives the packet, it transmits a packet to turn off the pusher P1. The pusher P1 shortens according to the received packet and is accommodated in the box. By repeating such processing by each device, the package B1 moves counterclockwise on the belt conveyor shown in FIG. 4. Similarly, baggage B2 moves counterclockwise on the belt conveyor shown in FIG.
[0044] The PLC collects normal packet data when each device shown in Fig. 4 is operating normally. The generator 22 learns the normal packet data collected by the PLC and generates the model data 11. In the evaluation system, the extractor 23 refers to the normal vector data converted from each normal packet data collected by the PLC. BERTScoreF1 is used as a measure of similarity.
[0045] An abnormal state is generated by manually moving the conveyor belt faster so that the speed reaches an abnormal value. A packet notifying the speed of the conveyor belt in this abnormal state is input to the PLC as abnormal packet data 15.
[0046] The extraction unit 23 extracts normal vector data that is most similar to the abnormal vector data 16 converted from the abnormal packet data 15. Fig. 5 shows a comparison between the abnormal packet data 15 and normal packet data before conversion of the normal vector data extracted by the extraction unit 23.
[0047] In Fig. 5, a communication ID is set in the first and second bytes. The communication ID is an identifier that identifies a packet transmitted and received in the system shown in Fig. 4. The speed of the conveyor belt is set in the eleventh byte. In the example shown in Fig. 5, the values of the abnormal packet and the normal packet are different in the first, second and eleventh bytes, but the values of the other bytes are the same. It can be seen that the extraction unit 23 has extracted normal vector data that is most similar to the abnormal vector data 16.
[0048] Fig. 6 shows a similarity matrix between the vectors of each byte of an abnormal packet and a normal packet. From Fig. 6, it can be seen that high similarities are arranged on the diagonal line. However, among the diagonal lines, the similarities between the first bytes, the second bytes, and the eleventh bytes are low. It is considered possible that the first byte, the second byte, or the eleventh byte of an abnormal packet is an abnormal byte.
[0049] On the other hand, when two normal vector data converted from two similar normal packets were compared, the lowest similarity among the vectors corresponding to the same byte was 0.91. This 0.91 was set as the threshold for detecting abnormal bytes.
[0050] Since the similarity between the first byte and the second byte is greater than 0.91, the estimation unit 24 estimates that the first byte and the second byte are not abnormal bytes. Since a different communication ID is set for the first byte and the second byte depending on the packet, even if different values are set for normal packets and abnormal packets, a similarity higher than the threshold is calculated.
[0051] On the other hand, since the similarity of the 11th byte is 0.827, which is smaller than 0.91, the estimation unit 24 estimates that the 11th byte is an abnormal byte. The speed of the belt conveyor is set for the 11th byte. This estimation by the estimation unit 24 matches the situation where an abnormal state occurs by manually moving the belt conveyor faster.
[0052] The estimation device 1 according to the embodiment of the present invention can estimate the abnormal byte 18 in the abnormal packet data 15. This enables the estimation device 1 to perform a precise analysis of the contents of the payload. For example, by introducing the estimation device 1 into a communication network for operational technology in industrial systems, buildings, etc., it becomes possible to detect even a small amount of unauthorized rewriting, such as one byte, without missing it.
[0053] The estimation device 1 of the present embodiment described above uses, for example, a general-purpose computer system including a CPU (Central Processing Unit, processor) 901, a memory 902, a storage 903 (HDD: Hard Disk Drive, SSD: Solid State Drive), a communication device 904, an input device 905, and an output device 906. In this computer system, the CPU 901 executes a program loaded on the memory 902, thereby realizing each function of the estimation device 1.
[0054] The estimation device 1 may be implemented in one computer, or in multiple computers, or may be a virtual machine implemented in a computer.
[0055] The program of the estimation device 1 can be stored in a computer-readable recording medium such as a HDD, SSD, USB (Universal Serial Bus) memory, CD (Compact Disc), or DVD (Digital Versatile Disc), or can be distributed via a network.
[0056] The present invention is not limited to the above-described embodiment, and various modifications are possible within the scope of the present invention. [Explanation of symbols]
[0057] 1 Estimation device 11 Model Data 12 Normal vector data set 15 Abnormal packet data 16 Abnormal Vector Data 17 Normal Vector Data 18 Abnormal bytes 21 Conversion section 22 Generation part 23 Extraction part 24 Estimation part 901 CPU 902 Memory 903 Storage 904 Communication equipment 905 Input Device 906 Output Device
Claims
1. a conversion unit that converts the abnormal packet data into abnormal vector data using a model that converts the packet data into vector data in which each byte of the packet data corresponds to each vector that represents a characteristic of the value of the each byte; an extracting unit that extracts normal vector data having a relatively high similarity to the abnormal vector data from a plurality of normal vector data obtained by converting a plurality of normal packet data using the model; an estimation unit that estimates an abnormal byte in the abnormal packet data based on a similarity between a vector corresponding to each byte of the abnormal vector data and a vector corresponding to each byte of the extracted normal vector data; An estimation device comprising:
2. The model is generated by learning the values of each byte of a plurality of normal packet data. The estimation device according to claim 1 .
3. The extraction unit calculates a similarity between a vector of the abnormal vector data and a vector of the normal vector data for each byte of the abnormal vector data, and calculates a similarity between the abnormal vector data and the normal vector data from the similarity calculated for each byte. The estimation device according to claim 1 .
4. The estimation unit estimates that a predetermined byte is an abnormal byte when the highest similarity between a vector corresponding to a predetermined byte of the abnormal packet data and a vector corresponding to each byte of the extracted normal vector data is lower than a predetermined threshold value. The estimation device according to claim 1 .
5. A computer converts the abnormal packet data into abnormal vector data using a model that converts the packet data into vector data that associates each byte of the packet data with a vector that represents a characteristic of the value of each byte; The computer extracts normal vector data having a relatively high similarity to the abnormal vector data from a plurality of normal vector data obtained by converting a plurality of normal packet data using the model, The computer estimates anomalous bytes in the anomalous packet data from a similarity between a vector corresponding to each byte of the anomalous vector data and a vector corresponding to each byte of the extracted normal vector data. Estimation method.
6. A program for causing a computer to function as the estimation device according to any one of claims 1 to 4.
Citation Information
Patent Citations
Spread unauthorized access detection method and system
JP2007074339A
Network monitoring device, and system and method therefor
JP2019004419A
Network device, method for processing packet, and program
JP2019033312A
Anomaly detection method, learning method, anomaly detection device, and learning device
JP2019110513A
