A user behavior simulation method based on knowledge construction, simulation system, customization system, computer and storage medium

By capturing and learning network node user behavior data, generating simulation operation sequences and generating keyboard and mouse operation simulation programs, it solves the problem of insufficient authenticity of network traffic simulation in the existing technology, realizes efficient and multi-granularity user behavior simulation, and generates high-quality Simulated network traffic.

CN113992730BActive Publication Date: 2024-09-06HARBIN INST OF TECH +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202111254268.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-10-27
Publication Date
2024-09-06
Estimated Expiration
2041-10-27

AI Technical Summary

Technical Problem

Existing network traffic generation technology cannot achieve high-fidelity network traffic simulation. User behavior simulation methods mainly rely on keyboard and mouse operation behavior playback and script generation, lacking credibility and versatility.

Method used

By capturing network node user behavior data, generating state-operator sequences, using deep learning models such as GPT-2 to learn user behavior simulation operation sequences, and generating keyboard and mouse operation simulation programs, user behavior simulation based on knowledge is realized.

Benefits of technology

It achieves efficient, multi-granularity, and scalable user behavior simulation, generates high-simulation network traffic, can simulate real network user behavior, and improves the authenticity and credibility of network traffic simulation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113992730B
    Figure CN113992730B
Patent Text Reader

Abstract

The present invention proposes a user behavior simulation method, simulation system, customization system, computer and storage medium based on knowledge construction, which belongs to the field of behavior simulation technology. First, the user behavior data of network nodes is captured; the user behavior data includes the collection of keyboard and mouse operation data and application event operation data; secondly, a state-operation meta-sequence is generated according to the keyboard and mouse operation data and the application event operation data, and the state-operation meta-sequence is learned to generate a user behavior simulation operation sequence; finally, the keyboard and mouse operation is simulated according to the user behavior simulation operation sequence, and a keyboard and mouse operation simulation program is generated. The present invention solves the technical problem of insufficient authenticity of network traffic simulation existing in the prior art. The behavior simulation of real network users is realized, thereby generating network traffic with high simulation degree.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to a simulation method, and more particularly to a user behavior simulation method, a simulation system, a customization system, a computer and a storage medium based on knowledge construction, and belongs to the technical field of behavior simulation. Background Art

[0002] With the advancement of computer technology, the confrontation between cyberspace security technologies is becoming increasingly fierce. In order to verify the security and reliability of network security technology and conduct network technology confrontation drills, it can be achieved by building a network range and simulating real network scenarios. In the process of building a network range, it is necessary to generate network traffic with high fidelity. Network users will generate traffic in the network link when operating application software. However, the network protocol generated by network application software is generally a private protocol. Therefore, by simulating network user behavior and behavior agent to drive the application software, real network traffic can be simulated, and then a network scenario with high fidelity can be simulated.

[0003] Existing network traffic generation technology is mainly used to test network conditions and the performance of network equipment, but ignores the authenticity of network traffic simulation. In terms of user behavior simulation, keyboard and mouse operation behavior playback and script generation are generally used, which cannot achieve highly reliable and versatile network user behavior simulation. Summary of the invention

[0004] A brief overview of the present invention is provided below in order to provide a basic understanding of certain aspects of the present invention. It should be understood that this overview is not an exhaustive overview of the present invention. It is not intended to identify key or important parts of the present invention, nor is it intended to limit the scope of the present invention. Its purpose is merely to present certain concepts in a simplified form as a prelude to a more detailed description discussed later.

[0005] In view of this, in order to solve the technical problem of insufficient authenticity of network traffic simulation in the prior art, the present invention provides a user behavior simulation method, simulation system, customization system, computer and storage medium based on knowledge construction.

[0006] Solution 1: The present invention provides a user behavior simulation method based on knowledge construction, comprising the following steps:

[0007] S1. Capture network node user behavior data; the user behavior data includes the collection of keyboard and mouse operation data and application event operation data;

[0008] S2. Generate a state-operation meta-sequence based on the keyboard and mouse operation data and the application event operation data described in S1, and learn the state-operation meta-sequence to generate a user behavior simulation operation sequence;

[0009] S3. Simulate the keyboard and mouse operations according to the user behavior simulation operation sequence and generate a keyboard and mouse operation simulation program.

[0010] Preferably, the specific method of capturing in S1 comprises the following steps:

[0011] S11. Record the data of keyboard and mouse operations based on the message hook, traverse the application event operations based on the handle viewing tool, and establish an application operation handle tree; when collecting application event operation data, periodically query and record the operation status of the application according to the handle tree identifier;

[0012] S12. Segment the collected keyboard and mouse data and application event operation data;

[0013] S13. Perform data statistics on each characteristic value of the application event operation, and filter out data that does not meet the statistical characteristics.

[0014] Preferably, the specific method of segmenting the collected keyboard and mouse data and application event operation data in S12 is that for keyboard and mouse operations, they are segmented into operation data with time intervals; for application event operation data, they are segmented into different window events according to time.

[0015] Preferably, the specific method of generating a state-operation meta-sequence according to the keyboard and mouse operation data and the application event operation data according to S1 in S2 is: merging the keyboard and mouse function operation data with the application event operation data according to the timestamp to generate a state-operation meta-sequence containing the application event data operation data with a time series and the keyboard and mouse function operation data.

[0016] Preferably, the specific method of learning the state-operation meta-sequence to generate a user behavior simulation operation sequence in S2 is to input the state-operation meta-sequence into the deep learning model GPT-2 to learn the sequence pattern and output the user behavior simulation operation sequence.

[0017] Solution 2. A user behavior simulation system based on knowledge construction, which is used to implement the method described in Solution 1, and includes a user behavior data collection module, a user behavior modeling module and a keyboard and mouse operation simulation module; the behavior data collection module is used to collect keyboard and mouse operation data and application event operation data, and write the collected data into a database in real time; the user behavior modeling module is used to generate a state-operation meta-sequence from the keyboard and mouse operation data and application event operation data, learn the state-operation meta-sequence to generate a user behavior simulation operation sequence, and write the user behavior simulation operation sequence into the database; the user behavior simulation module is used to simulate the keyboard and mouse operation time according to the user behavior simulation operation sequence, and generate a keyboard and mouse operation simulation program.

[0018] Solution 3: A user behavior simulation customization system, which encapsulates the keyboard and mouse operation simulation program and dependent environment described in Solution 1 into an image using a Dockerfile file to generate a keyboard and mouse simulation program image; based on the docker container orchestration method, the docker-compose.yml file is used to start the containers in sequence with the image, and each container corresponds to a different keyboard and mouse simulation program; users can choose different containers according to the cloud service platform to customize different keyboard and mouse simulation programs.

[0019] Solution 4: A computer includes a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the steps of a user behavior simulation based on knowledge construction described in Solution 1 are implemented.

[0020] Solution 5: A computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the user behavior simulation based on knowledge construction described in Solution 1.

[0021] The beneficial effects of the present invention are as follows: The present invention provides an efficient, multi-granular, and highly scalable user behavior simulation method that can simulate real network user behavior to generate highly simulated network traffic. In terms of macro-behavior, the present invention realizes the simulation of continuous multi-application software behavior of users based on sequence prediction. In terms of meso-behavior, the simulation of single software behavior is realized through a mixture of message-driven or image recognition-driven. In terms of micro-behavior, the simulation of functional operations is realized using keyboard and mouse behavior templates. Based on the function-as-a-service cloud platform, user behavior is split into multiple behavior functions to realize and simulate customized and scalable multiple application program instances and improve simulation efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:

[0023] Figure 1 It is a schematic diagram of the process of the present invention;

[0024] Figure 2 Schematic diagram of the GPT network training process for this application;

[0025] Figure 3 This is a schematic diagram of the GPT network generation process for this application;

[0026] Figure 4 This is a schematic diagram of the system structure of this application;

[0027] Figure 5 A schematic diagram of the mirroring process for this application;

[0028] Figure 6 A diagram of the system structure customized for this application. DETAILED DESCRIPTION

[0029] In order to make the technical solutions and advantages in the embodiments of the present application more clearly understood, the exemplary embodiments of the present application are further described in detail below in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present application, rather than an exhaustive list of all the embodiments. It should be noted that the embodiments in the present application and the features in the embodiments can be combined with each other without conflict.

[0030] Example 1, reference Figure 1-3 The present embodiment describes a method for simulating user behavior based on knowledge construction, comprising the following steps:

[0031] S1. Capturing network node user behavior data; the user behavior data includes collecting keyboard and mouse operation data and application event operation data; comprising the following steps:

[0032] S11. Record the data of keyboard and mouse operations based on the message hook, traverse the application event operations based on the handle viewing tool, and establish an application operation handle tree; when collecting application event operation data, periodically query and record the operation status of the application according to the handle tree identifier;

[0033] S12. Segment the collected keyboard and mouse data and application event operation data; specifically, for keyboard and mouse operations, segment them into operation data with time intervals; for application event operation data, segment them into different window events according to time.

[0034] S13. Perform data statistics on each characteristic value of the application event operation and filter out data that does not meet the statistical characteristics. When the computer system resources (such as CPU, memory) are occupied, the user behavior data recorded by the operating system may record abnormal data or partially duplicate data, thereby affecting the accuracy of the simulated user behavior. Therefore, the present invention denoises the original data and filters out data that does not meet the statistical characteristics.

[0035] Specifically, the statistical features include the coordinate movement features of the mouse, the time and frequency features of the mouse clicks, the dragging features of the mouse while holding down a button, the keystroke features of the keyboard, and the keystroke position features of the keyboard.

[0036] S2. Generate a state-operation meta-sequence based on the keyboard and mouse operation data and application event operation data described in S1, and learn the state-operation meta-sequence to generate a user behavior simulation operation sequence; the specific method is: merge the keyboard and mouse function operation data with the application event operation data according to the timestamp, and generate a state-operation meta-sequence containing the application event data operation data with a time series and the keyboard and mouse function operation data.

[0037] Specifically, the specific method of learning the state-operation meta-sequence to generate the user behavior simulation operation sequence in S2 is to input the state-operation meta-sequence into the deep learning model GPT-2 to learn the sequence pattern and output the user behavior simulation operation sequence.

[0038] Specifically, the state-operation sequence is input into the GPT network for training (the training process refers to Figure 2 ), the GPT network first estimates and calculates the next keyboard and mouse operation state probability P, and then re-inputs the state-operation sequence into the GPT-2 network until the GPT-2 network generates a user simulation operation sequence (the generation process refers to Figure 3 ).

[0039] S3. Simulate the keyboard and mouse operations according to the user behavior simulation operation sequence and generate a keyboard and mouse operation simulation program.

[0040] Specifically, the user behavior simulation can be realized by running the keyboard and mouse operation simulation program while running the application program.

[0041] Example 2, reference Figure 4 To describe this embodiment, a user behavior simulation system based on knowledge construction is used to implement the method described in Scheme 1, including a user behavior data collection module, a user behavior modeling module and a keyboard and mouse operation simulation module; the behavior data collection module is used to collect keyboard and mouse operation data and application event operation data, and write the collected data into a database in real time; the user behavior modeling module is used to generate a state-operation meta-sequence from the keyboard and mouse operation data and application event operation data, learn the state-operation meta-sequence to generate a user behavior simulation operation sequence, and write the user behavior simulation operation sequence into the database; the user behavior simulation module is used to simulate the keyboard and mouse operation time according to the user behavior simulation operation sequence, and generate a keyboard and mouse operation simulation program.

[0042] Example 3, reference Figure 5-6This embodiment describes a user behavior simulation customization system. The keyboard and mouse operation simulation program and dependent environment described in Solution 1 are packaged into an image using a Dockerfile file to generate a keyboard and mouse simulation program image. Based on the docker container orchestration method, the docker-compose.yml file is used to start containers in sequence with the image. Each container corresponds to a different keyboard and mouse simulation program. Users can choose different containers to customize different keyboard and mouse simulation programs according to the cloud service platform. The packaging process is referenced in Figure 5 , the customization process refers to Figure 6 .

[0043] The user behavior simulation method based on knowledge construction in this application provides an efficient, multi-granular, and highly scalable user behavior simulation method that can simulate real network user behavior to generate highly simulated network traffic. Its main core contents include:

[0044] (1) Capture user behavior on network nodes. Capture the user's keyboard and mouse functions in a fine-grained manner; at the same time, collect and record the desktop status, application software status, and operation behavior of the network node host in a coarse-grained manner.

[0045] (2) Extract behavioral features from keyboard and mouse function operations and application operations respectively, and establish a behavioral knowledge base.

[0046] (3) Based on the Function as a Service cloud platform, user behavior is divided into multiple behavioral functions, and customized and scalable application instances are implemented and simulated to improve simulation efficiency.

[0047] In terms of macro behavior, this application realizes the simulation of user continuous multi-application software behavior based on sequence prediction. In terms of meso behavior, the simulation of single software behavior is realized through message drive or image recognition drive hybrid. In terms of micro behavior, the simulation of function operation is realized by using keyboard and mouse behavior templates.

[0048] Embodiment 4: A computer. The computer device of the present invention may be a device including a processor and a memory, such as a single chip microcomputer including a central processing unit. Furthermore, the processor is used to implement the steps of the above-mentioned recommendation method based on CREO software that can modify the recommendation data driven by the relationship when executing the computer program stored in the memory.

[0049] The processor may be a central processing unit (CPU), other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.

[0050] The memory may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area may store data created according to the use of the mobile phone (such as audio data, a phone book, etc.), etc. In addition, the memory may include a high-speed random access memory, and may also include a non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.

[0051] Embodiment 5: Computer readable storage medium

[0052] The computer-readable storage medium of the present invention can be any form of storage medium that can be read by a processor of a computer device, including but not limited to non-volatile memory, volatile memory, ferroelectric memory, etc. A computer program is stored on the computer-readable storage medium. When the processor of the computer device reads and executes the computer program stored in the memory, the steps of the above-mentioned modeling method of modifiable relationship-driven modeling data based on CREO software can be implemented.

[0053] The computer program includes computer program code, which may be in source code form, object code form, executable file or some intermediate form, etc. The computer readable medium may include: any entity or device capable of carrying the computer program code, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electric carrier signal, telecommunication signal and software distribution medium, etc. It should be noted that the content contained in the computer readable medium may be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, computer readable media do not include electric carrier signals and telecommunication signals.

[0054] Although the present invention has been described according to a limited number of embodiments, it will be apparent to those skilled in the art, with the benefit of the above description, that other embodiments may be envisioned within the scope of the invention thus described. In addition, it should be noted that the language used in this specification is selected primarily for readability and teaching purposes, rather than for explaining or defining the subject matter of the present invention. Therefore, many modifications and variations will be apparent to those skilled in the art without departing from the scope and spirit of the appended claims. The disclosure of the present invention is illustrative, not restrictive, with respect to the scope of the present invention, which is defined by the appended claims.

Claims

1. A user behavior simulation method based on knowledge construction, characterized in that: The following steps are involved: S1. Capturing network node user behavior data; the user behavior data includes collecting keyboard and mouse operation data and application event operation data, the method comprises the following steps: S11. Record the data of keyboard and mouse operations based on the message hook, traverse the application event operations based on the handle viewing tool, and establish an application operation handle tree; when collecting application event operation data, periodically query and record the operation status of the application according to the handle tree identifier; S12. Segment the collected keyboard and mouse data and application event operation data; for keyboard and mouse operations, segment them into operation data with time intervals; for application event operation data, segment them into different window events according to time; S13. Perform data statistics on each characteristic value of the application event operation and filter out data that does not meet the statistical characteristics; The statistical features include the coordinate movement features of the mouse, the time and frequency features of the mouse clicks, the dragging features of the mouse while holding down a button, the keystroke features of the keyboard, and the keystroke position features of the keyboard; S2. Generate a state-operation meta-sequence according to the keyboard and mouse operation data and the application event operation data described in S1, and learn the state-operation meta-sequence to generate a user behavior simulation operation sequence, by: merging the keyboard and mouse function operation data with the application event operation data according to the timestamp, and generating a state-operation meta-sequence including the application event data operation data with a time series and the keyboard and mouse function operation data; Input the state-operation meta-sequence into the deep learning model GPT-2 to learn the sequence pattern and output the user behavior simulation operation sequence; The state-operation sequence is input into the GPT network for training. The GPT network calculates the probability P of the next keyboard and mouse operation state. The state-operation sequence is input into the GPT-2 network until the GPT-2 network generates a user simulation operation sequence. S3. Simulate the keyboard and mouse operations according to the user behavior simulation operation sequence and generate a keyboard and mouse operation simulation program.

2. A user behavior simulation system based on knowledge construction, characterized in that: The system for implementing the method of claim 1 comprises a user behavior data collection module, a user behavior modeling module and a keyboard and mouse operation simulation module; the behavior data collection module is used to collect keyboard and mouse operation data and application event operation data, and write the collected data into a database in real time; the user behavior modeling module is used to generate a state-operation meta-sequence from the keyboard and mouse operation data and the application event operation data, learn the state-operation meta-sequence to generate a user behavior simulation operation sequence, and write the user behavior simulation operation sequence into the database; The user behavior simulation module is used to simulate the keyboard and mouse operation time according to the user behavior simulation operation sequence and generate a keyboard and mouse operation simulation program.

3. A user behavior simulation customization system, characterized in that: The keyboard and mouse operation simulation program and the dependent environment described in claim 1 are encapsulated into an image using the Dockerfile file to generate a keyboard and mouse simulation program image; based on the docker container orchestration method, the docker-compose.yml file is used to start the containers in sequence with the image, and each container corresponds to a different keyboard and mouse simulation program; users can select different containers according to the cloud service platform to customize different keyboard and mouse simulation programs.

4. A computer, characterized in that: The method comprises a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of the method according to claim 1 when executing the computer program.

5. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method according to claim 1 is implemented.