Database detection method, device, electronic device and storage medium

By extracting behavioral characteristics of database traffic data and using a preset detection rule base for security detection, the problem of difficulty in database detection in the existing technology is solved, unified security detection of multiple types of databases is achieved, and detection efficiency and accuracy are improved. , reducing the difficulty of operation and maintenance.

CN114186225BActive Publication Date: 2024-10-29BEIJING TOPSEC NETWORK SECURITY TECH +2
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111482967.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-07
Publication Date
2024-10-29
Estimated Expiration
2041-12-07

AI Technical Summary

Technical Problem

When the existing database audit system detects database password attacks, it needs to be configured separately according to different database types, which makes detection and operation and maintenance difficult, and it is impossible to uniformly detect different types of databases.

Method used

By obtaining traffic data, extracting behavioral characteristics and using a preset detection rule base for security detection, using rotating tree matching and life cycle management, we can uniformly detect similar attack behaviors in multiple types of databases, reducing the difficulty of detection and operation and maintenance.

Benefits of technology

It realizes unified security detection of multiple types of databases, improves detection efficiency and accuracy, reduces the difficulty of operation and maintenance, and can effectively identify and block security threats.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114186225B_ABST
    Figure CN114186225B_ABST
Patent Text Reader

Abstract

The present application provides a database detection method, device, electronic device and storage medium. The method includes: obtaining traffic data for the current database; extracting a first behavior feature for the current database from the traffic data through a preset extraction strategy; performing a security detection on the first behavior feature through a preset detection rule library to obtain a detection result that characterizes whether the traffic data poses a security threat to the current database. Since the detection rules in the preset detection rule library can detect similar attack behaviors for multiple types of databases, security detection can be uniformly performed on different types of databases. In this way, there is no need to deploy corresponding detection rules separately for different types of databases, which can reduce the difficulty of detecting and operating and maintaining the database.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of network security technology, and in particular to a database detection method, device, electronic device and storage medium. Background Art

[0002] In the Internet era, database security has attracted more and more attention. As a medium for storing data, database protection has become an important part of data protection. Currently, the database audit system or database firewall on the market can realize the audit function and some detection functions of the database. However, for the detection of database password attacks, the system needs to extract the database password attack behavior according to different database types, and then configure database instances for different types of databases to detect the extracted information related to the database, which makes detection and operation and maintenance difficult. Summary of the invention

[0003] The purpose of the embodiments of the present application is to provide a database detection method, device, electronic device and storage medium, which can improve the problem of difficulty in detection and operation and maintenance when performing security detection on multiple types of databases.

[0004] In order to achieve the above purpose, the embodiments of the present application are implemented in the following ways:

[0005] In a first aspect, an embodiment of the present application provides a database detection method, the method comprising: obtaining traffic data for a current database; extracting a first behavior feature for the current database from the traffic data through a preset extraction strategy; performing a security detection on the first behavior feature through a preset detection rule library to obtain a detection result characterizing whether the traffic data poses a security threat to the current database, wherein the preset detection rule library includes multiple detection rules, and each detection rule is used to detect similar attack behaviors against multiple types of databases.

[0006] In the above implementation, the first behavior feature for the current database is extracted from the traffic data, and then the first behavior feature is security tested using the preset detection rule library. Since the detection rules in the preset detection rule library can detect the same type of attack behaviors for multiple types of databases, security tests can be performed on different types of databases in a unified manner. In this way, there is no need to deploy corresponding detection rules for different types of databases separately, which can reduce the difficulty of database detection and operation and maintenance.

[0007] In combination with the first aspect, in some optional implementations, before obtaining the traffic data for the current database, the method further includes:

[0008] Obtaining behavioral data for multiple types of databases; extracting second behavioral features corresponding to each type of attack behavior for the multiple types of databases based on the behavioral data; creating detection rules corresponding to each type of attack behavior based on the second behavioral features to form the preset detection rule library.

[0009] In the above-mentioned implementation, by extracting the second behavior features of the same type of attack behaviors against multiple types of databases, and then creating detection rules for detecting the second behavior features, in this way, in the process of detecting attack behaviors against databases, one detection rule can be used to achieve unified detection of the same type of attack behaviors against different types of databases, thereby eliminating the impact of different types of databases being unable to be uniformly detected due to different behavior data.

[0010] In combination with the first aspect, in some optional implementations, performing security detection on the first behavior feature through a preset detection rule library to obtain a detection result indicating whether the traffic data poses a security threat to the current database includes:

[0011] Perform password attack detection on the first behavior feature by using a preset detection rule library;

[0012] When the first behavior feature representation satisfies a preset condition that the password is wrong, matching a target node corresponding to the first behavior feature on a rotation tree, wherein the rotation tree includes a plurality of preset nodes, each preset node includes a corresponding type of data set;

[0013] When the number or frequency of matching the target node reaches a corresponding set value, the detection result indicating that the traffic data poses a security threat to the current database is output.

[0014] In the above implementation, the rotation tree storage node can improve the node matching efficiency. Therefore, the combination of the preset detection rule base and the rotation tree is conducive to improving the detection efficiency.

[0015] In conjunction with the first aspect, in some optional implementations, matching a target node corresponding to the first behavior feature on the rotation tree includes:

[0016] The first behavior feature is matched with a node in a live state on the rotation tree, wherein a node having a key-value relationship with the first behavior feature is used as the matching target node, and each node on the rotation tree has a corresponding life cycle.

[0017] In combination with the first aspect, in some optional implementations, the method further includes:

[0018] The node representing the end of the life cycle is removed from the rotation tree.

[0019] In combination with the first aspect, in some optional implementations, the method further includes:

[0020] When the detection result indicates that the traffic data poses a security threat to the current database, the traffic data is blocked.

[0021] In combination with the first aspect, in some optional implementations, the method further includes:

[0022] When the detection result indicates that the traffic data poses a security threat to the current database, an alarm prompt is output.

[0023] In a second aspect, the present application further provides a database detection device, the device comprising:

[0024] An acquisition unit, used for acquiring traffic data for the current database;

[0025] A feature extraction unit, configured to extract a first behavior feature for the current database from the traffic data by using a preset extraction strategy;

[0026] A detection unit is used to perform security detection on the first behavior feature through a preset detection rule base to obtain a detection result characterizing whether the traffic data poses a security threat to the current database, wherein the preset detection rule base includes multiple detection rules, and each detection rule is used to detect similar attack behaviors against multiple types of databases.

[0027] In a third aspect, the present application further provides an electronic device, comprising a processor and a memory coupled to each other, wherein the memory stores a computer program, and when the computer program is executed by the processor, the electronic device performs the above method.

[0028] In a fourth aspect, the present application further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program runs on a computer, the computer executes the above method. BRIEF DESCRIPTION OF THE DRAWINGS

[0029] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments of the present application will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.

[0030] Figure 1 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application.

[0031] Figure 2 A flowchart of a database detection method provided in an embodiment of the present application.

[0032] Figure 3 It is a flowchart of the sub-steps of step S130.

[0033] Figure 4 A block diagram of a database detection device provided in an embodiment of the present application.

[0034] Icons: 10 - electronic device; 11 - processing module; 12 - storage module; 13 - communication module; 200 - database detection device; 210 - acquisition unit; 220 - feature extraction unit; 230 - detection unit. DETAILED DESCRIPTION

[0035] The technical solutions in the embodiments of the present application will be described below in conjunction with the accompanying drawings in the embodiments of the present application. It should be noted that the terms "first", "second", etc. are only used to distinguish the description and cannot be understood as indicating or implying relative importance. In the absence of conflict, the following embodiments and features in the embodiments can be combined with each other.

[0036] Please refer to Figure 1 The present application provides an electronic device 10 that can perform security supervision on multiple types of databases to improve the security of database operations.

[0037] The electronic device 10 may include a processing module 11 and a storage module 12. The storage module 12 stores a computer program, and when the computer program is executed by the processing module 11, the electronic device 10 can perform each step of the following database detection method.

[0038] The electronic device 10 may be, but is not limited to, a personal computer, a server, etc., and may collect flow data corresponding to operations on a database.

[0039] It should be noted that Figure 1 The structure shown is only a schematic diagram of a structure of the electronic device 10. The electronic device 10 may also include Figure 1 More components are shown. Figure 1 The components shown in the figure can be implemented by hardware, software or a combination thereof. For example, the electronic device 10 can also include a communication module 13 for establishing a communication connection with other devices. For example, the electronic device 10 can establish a communication connection with a user terminal, a server with a database, and other devices.

[0040] Please refer to Figure 2 The present application provides a database detection method, which can be applied to the above-mentioned electronic device 10. The electronic device 10 executes or implements each step in the method. The method may include the following steps:

[0041] Step S110, obtaining traffic data for the current database;

[0042] Step S120, extracting a first behavior feature for the current database from the traffic data by using a preset extraction strategy;

[0043] Step S130, performing security detection on the first behavior feature through a preset detection rule library to obtain a detection result characterizing whether the traffic data poses a security threat to the current database, wherein the preset detection rule library includes multiple detection rules, and each detection rule is used to detect similar attack behaviors against multiple types of databases.

[0044] In the above implementation, the first behavior feature for the current database is extracted from the traffic data, and then the first behavior feature is security tested using the preset detection rule library. Since the detection rules in the preset detection rule library can detect the same type of attack behaviors for multiple types of databases, security tests can be performed on different types of databases in a unified manner. In this way, there is no need to deploy corresponding detection rules for different types of databases separately, which can reduce the difficulty of database detection and operation and maintenance.

[0045] The following is a detailed description of each step of the method:

[0046] Before step S110, the method may include the step of creating a preset detection rule base. For example, before step S110, the method may include:

[0047] Step S101, obtaining behavior data for multiple types of databases;

[0048] Step S102, extracting a second behavior feature corresponding to each type of attack behavior for the multiple types of databases according to the behavior data;

[0049] Step S103: creating a detection rule corresponding to each type of attack behavior according to the second behavior feature to form the preset detection rule library.

[0050] In step S101, the behavior data may be historical data collected from traffic data of multiple types of databases. The types of databases in the multiple types of databases may be flexibly determined according to actual conditions. For example, the databases include but are not limited to MySQL databases, Oracle databases, and other databases well known to those skilled in the art.

[0051] Behavior data may include, but is not limited to, source user information, destination database server information, database information, database operation commands, database server response information, etc., and can be flexibly determined based on actual conditions.

[0052] For example, when a user needs to log in to a database, the behavior data may include field content corresponding to the login behavior. Among them, the field content corresponding to the login behavior is usually different in different types of databases.

[0053] In step S102, when the same type of behavior is reflected in different types of databases, the corresponding behavior data usually differs. For example, when logging into a MySQL database due to a login password error, an error code is automatically generated; when logging into an Oracle database due to a login password error, an error code is also automatically generated. The contents of these two error codes are different, but they represent the same behavior characteristics, namely: the login password is wrong.

[0054] The second behavior feature can be understood as a feature that characterizes possible attack behavior. For example, the above-mentioned "incorrect login password" can be regarded as a second behavior feature.

[0055] The types of attack behaviors can be flexibly determined according to the actual situation, including but not limited to data tampering, brute force password cracking, etc. By abstracting the behavioral data of similar attack behaviors of multiple types of databases, the behavioral features required for password attack detection can be formed (for example, the behavioral data of the above-mentioned "error code" is abstracted into the behavioral features of "login password error"). In this way, the behavioral features of the behavioral data of various databases can be detected, eliminating the impact of the inability to uniformly detect various databases due to different database types.

[0056] In step S103, the detection rules can be flexibly determined according to the actual situation, and can be but not limited to regular expressions for detecting various types of behavior characteristics. Each detection rule can have a unique number for easy identification and indexing. The detection rules corresponding to each type of attack behavior can form a rule library as a preset detection rule library.

[0057] In this way, in the process of detecting attack behaviors against databases, a detection rule can be used to achieve unified detection of attack behaviors against different types of databases, thereby eliminating the impact that different types of databases cannot be uniformly detected due to different behavior data.

[0058] In step S110 , the electronic device 10 may obtain traffic data generated by various operations performed by the user on the current database.

[0059] In this embodiment, an electronic device 10 can simultaneously obtain traffic data for one or more types of databases, so as to detect and analyze multiple types of databases at the same time. The traffic data can be real-time data generated by operators or attackers performing real-time operations on the corresponding databases, or historical data.

[0060] Traffic data includes but is not limited to user information of the operating user, device information, information of the server where the current database is located, information of the current database, database operation commands, and database server response information.

[0061] In step S120, the preset extraction strategy can be flexibly determined according to actual conditions to extract data or key fields related to the operation behavior in the traffic data, and then based on the extracted key fields or data, determine the behavior characteristics corresponding to the key fields as the first behavior characteristics.

[0062] For example, the preset extraction strategy can extract an error code in the traffic data that indicates an error in the password of the user logging into the database, and then based on the error code, obtain a behavior feature indicating "an error in the login password" as the first behavior feature.

[0063] In step S130, after the first behavior feature is extracted, the first behavior feature may be detected using a corresponding detection rule in a preset detection rule library to obtain a corresponding detection result.

[0064] Please refer to Figure 3 , the sub-steps included in step S130 may be as follows:

[0065] Step S131, performing password attack detection on the first behavior feature through a preset detection rule library;

[0066] Step S132, when the first behavior feature representation satisfies a preset condition of a wrong password, matching a target node corresponding to the first behavior feature on a rotation tree, wherein the rotation tree includes a plurality of preset nodes, each preset node includes a corresponding type of data set;

[0067] Step S133: When the number or frequency of matching the target node reaches a corresponding set value, the detection result indicating that the traffic data poses a security threat to the current database is output.

[0068] In step S131, the detection rules in the preset detection rule library can be used to detect whether the first behavior feature meets the corresponding preset conditions. Different detection rules can correspond to different preset conditions.

[0069] For example, the detection rule may detect whether the first behavior feature is a behavior feature of "within a preset time period, the number of incorrect login passwords exceeds a preset upper limit".

[0070] If the first behavior feature meets the corresponding preset condition, it means that the first behavior feature is a feature of a password attack, and then the process proceeds to step S132.

[0071] In step S132, the rotation tree is a structure of the password attack detection engine cache detection status in the electronic device 10. A node on the rotation tree may correspond to a type of data set. For example, a node corresponds to relevant behavior data of an operating user.

[0072] It is understandable that the nodes in the rotation tree are pre-created. In the process of creating the rotation tree nodes, the detection rules and the behavior data or behavior features that match the detection rules can be used as a node and stored on the rotation tree. Nodes corresponding to multiple detection rules can form multiple nodes on the rotation tree. In this way, there can be a key-value relationship between the nodes on the rotation tree and the behavior features corresponding to the behavior data. Among them, the behavior feature can be used as the "Key" of the index node, and the behavior data in the node can be used as the "Value". Based on the Key-Value correspondence, the node corresponding to the second behavior feature can be indexed on the rotation tree.

[0073] Among them, using a rotation tree to store nodes can improve the retrieval efficiency when the key value is not complex, which is beneficial to improving the performance problems that may occur due to adding a detection engine to the electronic device 10.

[0074] Step S132 may include: matching the first behavior feature with a node in a live state on the rotation tree, wherein a node having a key-value relationship with the first behavior feature is used as the matching target node, and each node on the rotation tree has a corresponding life cycle.

[0075] Understandably, each node on the rotation tree has a corresponding life cycle, and the life cycles of different nodes may be different, and may be flexibly set according to actual conditions. When matching the first behavior feature with the nodes on the rotation tree, the matched nodes are all nodes in a surviving state, so that the timeliness and reliability of the detection can be improved.

[0076] In step S133, the set value may be a threshold value corresponding to the number of times or a threshold value corresponding to the frequency, which may be flexibly determined according to the actual situation. When the number of times or the frequency of matching the target node reaches the corresponding set value, it indicates that the traffic data will pose a security threat to the current database, and at this time, a detection result indicating that the database has a security threat may be output.

[0077] For example, within a set period of time, it is detected that the number of incorrect login passwords of the same user (for example, the same IP address or the same account) reaches a set number while logging into the database. At this time, there is a risk of brute force password cracking. Therefore, the electronic device 10 can output a detection result indicating that the current operation (or traffic data) poses a security threat to the database.

[0078] As an optional implementation, the method may further include: removing, from the rotation tree, nodes representing that a life cycle has ended.

[0079] After removing the nodes whose lifecycles have ended on the rotation tree, invalid nodes can be prevented from participating in the matching and affecting the matching efficiency.

[0080] As an optional implementation, the method may further include:

[0081] When the detection result indicates that the traffic data poses a security threat to the current database, the traffic data is blocked.

[0082] In the above implementation, when the traffic data may pose a security threat to the current database, the network security of the current database may be improved and the risk of being attacked may be reduced by blocking the traffic data.

[0083] As an optional implementation, the method may further include:

[0084] When the detection result indicates that the traffic data poses a security threat to the current database, an alarm prompt is output.

[0085] When traffic data poses a security threat to the current database, issuing an alarm will help managers to promptly investigate the current situation to avoid or reduce losses caused by password attacks.

[0086] Please refer to Figure 4 The embodiment of the present application also provides a database detection device 200, which can be applied to the above-mentioned electronic device 10 to execute each step in the method. The database detection device 200 includes at least one software function module that can be stored in the storage module 12 in the form of software or firmware or solidified in the operating system (OS) of the electronic device 10. The processing module 11 is used to execute the executable module stored in the storage module 12, such as the software function module and computer program included in the database detection device 200.

[0087] The database detection device 200 may include an acquisition unit 210, a feature extraction unit 220, and a detection unit 230. The functions of each unit may be as follows:

[0088] An acquisition unit 210 is used to acquire traffic data for the current database;

[0089] A feature extraction unit 220, configured to extract a first behavior feature for the current database from the traffic data by using a preset extraction strategy;

[0090] The detection unit 230 is used to perform security detection on the first behavior feature through a preset detection rule base to obtain a detection result characterizing whether the traffic data poses a security threat to the current database, wherein the preset detection rule base includes multiple detection rules, and each detection rule is used to detect similar attack behaviors against multiple types of databases.

[0091] The database detection device 200 may further include a rule base building unit. Before the acquisition unit 210 acquires the traffic data for the current database, the acquisition unit 210 is also used to acquire behavior data for multiple types of databases; the feature extraction unit 220 is used to extract the second behavior feature corresponding to each type of attack behavior for the multiple types of databases based on the behavior data; the rule base building unit is used to create a detection rule corresponding to each type of attack behavior based on the second behavior feature to form the preset detection rule base.

[0092] Optionally, the detection unit 230 may also be used for:

[0093] Performing password attack detection on the first behavior feature by using the preset detection rule library;

[0094] When the first behavior feature representation satisfies a preset condition that the password is wrong, matching a target node corresponding to the first behavior feature on a rotation tree, wherein the rotation tree includes a plurality of preset nodes, each preset node includes a corresponding type of data set;

[0095] When the number or frequency of matching the target node reaches a corresponding set value, the detection result indicating that the traffic data poses a security threat to the current database is output.

[0096] Optionally, the detection unit 230 can also be used to: match the first behavior feature with a node in a surviving state on the rotation tree, wherein the node having a key-value relationship with the first behavior feature is used as the matching target node, and each node on the rotation tree has a corresponding life cycle.

[0097] Optionally, the database detection device 200 may further include a node updating unit, which is used to remove nodes representing the end of life cycle from the rotation tree.

[0098] Optionally, the database detection device 200 may further include an interception unit, configured to block the traffic data when the detection result indicates that the traffic data poses a security threat to the current database.

[0099] Optionally, the database detection device 200 may further include a prompt unit, configured to output an alarm prompt when the detection result indicates that the traffic data poses a security threat to the current database.

[0100] In this embodiment, the processing module 11 may be an integrated circuit chip having the ability to process signals. The processing module 11 may be a general-purpose processor. For example, the processor may be a central processing unit (CPU), a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, and may implement or execute the methods, steps and logic block diagrams disclosed in the embodiments of the present application.

[0101] The storage module 12 may be, but is not limited to, a random access memory, a read-only memory, a programmable read-only memory, an erasable programmable read-only memory, an electrically erasable programmable read-only memory, etc. In this embodiment, the storage module 12 may be used to store a preset extraction strategy, a preset detection rule library, etc. Of course, the storage module 12 may also be used to store a program, and the processing module 11 executes the program after receiving the execution instruction.

[0102] It should be noted that those skilled in the art can clearly understand that, for the convenience and simplicity of description, the specific working process of the electronic device 10 and the database detection device 200 described above can refer to the corresponding process of each step in the aforementioned method, and will not be elaborated here.

[0103] The embodiment of the present application further provides a computer-readable storage medium. The computer-readable storage medium stores a computer program, and when the computer program is run on a computer, the computer executes the database detection method described in the above embodiment.

[0104] Through the description of the above implementation methods, technical personnel in this field can clearly understand that the present application can be implemented by hardware, and can also be implemented by means of software plus a necessary general hardware platform. Based on such an understanding, the technical solution of the present application can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.), including a number of instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each implementation scenario of the present application.

[0105] In summary, in this solution, the first behavior feature for the current database is extracted from the traffic data, and then the first behavior feature is security tested using the preset detection rule library. Since the detection rules in the preset detection rule library can detect the same type of attack behaviors for multiple types of databases, different types of databases can be uniformly security tested. In this way, there is no need to deploy corresponding detection rules for different types of databases separately, which can reduce the difficulty of database detection and operation and maintenance management.

[0106] In the embodiments provided in the present application, it should be understood that the disclosed device, system and method can also be implemented in other ways. The above-described device, system and method embodiments are merely schematic, for example, the flowchart and block diagram in the accompanying drawings show the possible architecture, function and operation of the system, method and computer program product according to the multiple embodiments of the present application. In this regard, each box in the flowchart or block diagram can represent a part of a module, a program segment or a code, and a part of the module, program segment or code contains one or more executable instructions for implementing the specified logical function. It should also be noted that each box in the block diagram and / or the flowchart, and the combination of the boxes in the block diagram and / or the flowchart can be implemented by a dedicated hardware-based system that performs the specified function or action, or can be implemented by a combination of dedicated hardware and computer instructions. In addition, each functional module in each embodiment of the present application can be integrated together to form an independent part, or each module can exist separately, or two or more modules can be integrated to form an independent part.

[0107] The above description is only an embodiment of the present application and is not intended to limit the protection scope of the present application. For those skilled in the art, the present application may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims

1. A database detection method, characterized in that: The method comprises: Get traffic data for the current database; Extracting a first behavior feature for the current database from the traffic data by using a preset extraction strategy; Performing security detection on the first behavior feature through a preset detection rule library to obtain a detection result indicating whether the traffic data poses a security threat to the current database, wherein the preset detection rule library includes multiple detection rules, each detection rule being used to detect similar attack behaviors against multiple types of databases; Before obtaining the traffic data for the current database, the method further includes: Obtain behavioral data for multiple types of databases; Extracting, according to the behavior data, a second behavior feature corresponding to each type of attack behavior for the multiple types of databases; A detection rule corresponding to each type of attack behavior is created according to the second behavior feature to form the preset detection rule library.

2. The method according to claim 1, characterized in that Performing a security detection on the first behavior feature through a preset detection rule library to obtain a detection result indicating whether the traffic data poses a security threat to the current database includes: Performing password attack detection on the first behavior feature by using the preset detection rule library; When the first behavior feature representation satisfies a preset condition that the password is wrong, matching a target node corresponding to the first behavior feature on a rotation tree, wherein the rotation tree includes a plurality of preset nodes, each preset node includes a corresponding type of data set; When the number or frequency of matching the target node reaches a corresponding set value, the detection result indicating that the traffic data poses a security threat to the current database is output.

3. The method according to claim 2, characterized in that Matching a target node corresponding to the first behavior feature on the rotation tree includes: The first behavior feature is matched with a node in a live state on the rotation tree, wherein a node having a key-value relationship with the first behavior feature is used as the matching target node, and each node on the rotation tree has a corresponding life cycle.

4. The method according to claim 3, characterized in that The method further comprises: The node representing the end of the life cycle is removed from the rotation tree.

5. The method according to claim 1, characterized in that The method further comprises: When the detection result indicates that the traffic data poses a security threat to the current database, the traffic data is blocked.

6. The method according to claim 1, characterized in that The method further comprises: When the detection result indicates that the traffic data poses a security threat to the current database, an alarm prompt is output.

7. A database detection device, characterized in that: The device comprises: An acquisition unit, used for acquiring traffic data for the current database; A feature extraction unit, configured to extract a first behavior feature for the current database from the traffic data by using a preset extraction strategy; a detection unit, configured to perform a security detection on the first behavior feature through a preset detection rule base, and obtain a detection result indicating whether the traffic data poses a security threat to the current database, wherein the preset detection rule base includes a plurality of detection rules, each of which is used to detect similar attack behaviors against multiple types of databases; Among them, the device also includes: a rule base establishment unit, which is used to obtain behavior data for multiple types of databases before obtaining traffic data for the current database; extract second behavior features corresponding to each type of attack behavior for the multiple types of databases based on the behavior data; create detection rules corresponding to each type of attack behavior based on the second behavior features to form the preset detection rule base.

8. An electronic device, characterized in that: The electronic device comprises a processor and a memory coupled to each other, wherein the memory stores a computer program. When the computer program is executed by the processor, the electronic device executes the method according to any one of claims 1 to 6.

9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed on a computer, the computer is enabled to execute the method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Detection method and device of cloud-based database

    CN106407830A

  • Attack behavior detection method and device, equipment and medium

    CN113486343A