A user operation audit method and system for microservice architecture
By obtaining and analyzing the user's current and historical operating behaviors in the microservice architecture, and calculating the target risk operation coefficient, precise auditing and abnormal early warning of user operations are achieved, which solves the problems of low audit efficiency and inability to provide timely early warning in the existing technology. , ensuring information security.
Patent Information
- Application Number
- CN202410572736.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-10
- Publication Date
- 2024-09-03
- Estimated Expiration
- 2044-05-10
AI Technical Summary
Existing technology cannot accurately audit user operations, cannot improve audit efficiency, and cannot provide timely warnings about abnormal behaviors.
By obtaining the user's current operation behavior, index it to the virtual server to determine whether there are abnormal operations, and issue early warning reminders in real time; when there are no abnormal operations, extract historical behavior information from the log file, calculate the user's target risk operation coefficient, and based on This coefficient is subject to permission restriction.
It achieves precise auditing of user operating behaviors, improves auditing efficiency, provides timely warnings of abnormal behaviors, and ensures information security.
Smart Images

Figure CN118174960B
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of network auditing, and in particular to a user operation auditing method and system for a microservice architecture. Background Art
[0002] Microservice architecture is a software architecture style that decomposes a large application into multiple independent small services, each of which runs in its own process and is usually organized around business functions. These services can collaborate with each other through lightweight communication mechanisms such as HTTP, RESTful, API. Each service in the microservice architecture is independent and can be developed, deployed, upgraded, and expanded separately. This independence allows the team to use the technology stack that best suits a specific service, thereby improving flexibility and efficiency.
[0003] As the popularity of microservice architecture increases, the number of users is growing explosively, and network user behavior is becoming more and more complex and diverse. Appropriate analysis, management, and early warning of network user behavior are issues that need to be addressed. The current user operation audit method mainly obtains user Internet access information through the logs of various devices in the network, and then monitors and audits user behavior. Application behaviors include visiting websites and browsing web pages, sending and receiving emails, uploading and downloading, instant messaging, chatting, forums, and remote terminal access to Telnet, etc. Internet access information includes four types of information: external network information, internal network information, authentication information, and user information. The above-mentioned entire operation process is very complicated, with a huge workload, and is extremely time-consuming and labor-intensive. It is difficult to ensure the query quality, and it is impossible to issue timely early warnings for abnormal behaviors. Summary of the invention
[0004] The embodiment of the present invention provides a user operation audit method and system for a microservice architecture, which is used to solve the technical problems in the prior art that user operations cannot be accurately audited, audit efficiency cannot be improved, and abnormal behaviors cannot be promptly warned.
[0005] In order to achieve the above object, the present invention provides a user operation audit method of a microservice architecture, comprising:
[0006] Acquire the user's current operation behavior, index the current operation behavior to the virtual server, and determine whether there is an abnormal operation in the current operation behavior within a first preset time;
[0007] When there is abnormal operation, early warning reminders are issued in real time;
[0008] When there is no abnormal operation, extracting the user's historical behavior information from the log file, wherein the historical behavior information includes historical risk behavior information and historical safety behavior information;
[0009] The user's target risk operation coefficient is calculated based on the historical risk behavior information and the historical safety behavior information, and the user is restricted based on the target risk operation coefficient.
[0010] Further, when obtaining the current operation behavior of the user, indexing the current operation behavior to the virtual server, and determining whether there is an abnormal operation in the current operation behavior within a first preset time, it includes:
[0011] Obtaining the user's current operation behavior, wherein the current operation behavior includes download frequency, download time, download data volume and download speed;
[0012] Establish the current operation behavior set A1, set A1={B1, C1, D1, E1}, where B1 is the download frequency information, C1 is the download time information, D1 is the download data volume information, and E1 is the download speed information;
[0013] Establish a preset operation behavior set A0, set A0={B0, C0, D0, E0}, where B0 is the preset download frequency information, C0 is the preset download time information, D0 is the preset download data volume information, and E0 is the preset download speed information;
[0014] When B1, C1, D1 and E1 are all within B0, C0, D0 and E0, it is determined that there is no abnormal operation;
[0015] When one or more of B1, C1, D1 and E1 are not located within B0, C0, D0 and E0, it is determined that abnormal operation may exist.
[0016] Furthermore, after determining that an abnormal operation may exist, the method further includes:
[0017] Extract the current operation behaviors that are not in B0, C0, D0 and E0, and input them into the behavior simulation model to obtain the behavior simulation network;
[0018] The behavior simulation network is input into the behavior simulation network link breaking model to obtain the number of behavior simulation network link breaking, and if the number of link breaking is greater than or equal to the preset number of abnormal link breaking, it is determined that an abnormal operation exists;
[0019] If the number of broken links is less than the preset abnormal number of broken links, it is determined that there is no abnormal operation.
[0020] Furthermore, the log file construction method includes:
[0021] Obtain user information and behavior information of the microservice architecture operating system; wherein the user information includes: user name, IP address, login time;
[0022] Determine the storage path of the log file;
[0023] Creating a log file template according to the user information, and initializing the log file template;
[0024] The behavior information that conforms to the log file name pattern and is located in the log file storage path is imported into the initialized log file queue one by one in the order of modification time to obtain the log file.
[0025] Further, when calculating the user's target risk operation coefficient according to the historical risk behavior information and the historical safety behavior information, it includes:
[0026] Extract the user's historical login time from the log file and count the corresponding time numbers;
[0027] Determine the historical risk behavior information and historical safety behavior information corresponding to each historical login moment;
[0028] Performing behavior analysis on the historical risk behavior information, and determining the risk impact value corresponding to each historical risk behavior information based on the analysis result;
[0029] Construct a risk impact value set based on all risk impact values;
[0030] Count the number of moments corresponding to historical risky behavior information and the number of moments corresponding to historical safe behavior information respectively;
[0031] Calculate the user's initial risk operation coefficient based on the risk impact value set, the number of moments corresponding to the historical risk behavior information, and the number of moments corresponding to the historical safety behavior information;
[0032] Calculate the user's initial risk operation coefficient according to the following formula:
[0033] ;
[0034] Among them, h is the user's initial risk operation coefficient, t1 is the number of moments corresponding to historical risk behavior information, t2 is the number of moments corresponding to historical safety behavior information, t1+t2=n, n is the number of moments corresponding to historical login moments, Li is the i-th risk impact value in the risk impact value set, Lmax is the largest risk impact value in the risk impact value set, a is the first calculation conversion coefficient, b is the second calculation conversion coefficient, and a+b=1.
[0035] Further, after calculating the initial risk operation coefficient of the user according to the risk impact value set, the number of moments corresponding to the historical risk behavior information, and the number of moments corresponding to the historical safety behavior information, the method further includes:
[0036] Obtaining comprehensive risk operation behavior information of the microservice architecture operating system;
[0037] Determine the intersection operation behavior between the historical safety behavior information and the comprehensive risk operation behavior information, and obtain an intersection behavior set according to the intersection operation behavior;
[0038] Deleting the intersection behaviors in the historical safety behavior information, and constructing a non-intersection safety behavior information set based on the remaining historical safety behavior information;
[0039] Calculate the user's potential risk coefficient based on the intersection behavior set and the non-intersection safety behavior information set;
[0040] The initial risk operation coefficient is corrected according to the potential risk coefficient to obtain the target risk operation coefficient.
[0041] Further, when calculating the potential risk coefficient of the user according to the intersection behavior set and the non-intersection safety behavior information set, it includes:
[0042] Counting a first number of intersection behaviors in the intersection behavior set, and counting a second number of safety behavior information in the non-intersection safety behavior information set;
[0043] The potential risk factor of the user is calculated according to the first number and the second number.
[0044] Furthermore, when the initial risk operation coefficient is corrected according to the potential risk coefficient to obtain the target risk operation coefficient, it includes:
[0045] Presetting a first preset potential risk factor and a second preset potential risk factor;
[0046] Presetting a first preset initial risk operation correction coefficient, a second preset initial risk operation correction coefficient, and a third preset initial risk operation correction coefficient;
[0047] Selecting an initial risk operation correction coefficient according to the potential risk coefficient, the first preset potential risk coefficient and the second preset potential risk coefficient, and correcting the initial risk operation coefficient based on the selected initial risk operation correction coefficient to obtain a target risk operation coefficient;
[0048] When the potential risk coefficient is less than the first preset potential risk coefficient, the first preset initial risk operation correction coefficient is selected to correct the initial risk operation coefficient;
[0049] When the potential risk coefficient is greater than or equal to the first preset potential risk coefficient, and the potential risk coefficient is less than the second preset potential risk coefficient, the second preset initial risk operation correction coefficient is selected to correct the initial risk operation coefficient;
[0050] When the potential risk coefficient is greater than or equal to the second preset potential risk coefficient, the third preset initial risk operation correction coefficient is selected to correct the initial risk operation coefficient.
[0051] In order to achieve the above object, the present invention also provides a user operation audit system of a microservice architecture, comprising:
[0052] The first module is used to obtain the current operation behavior of the user, index the current operation behavior to the virtual server, and determine whether there is an abnormal operation in the current operation behavior within a first preset time;
[0053] The second module is used to issue early warning reminders in real time when there are abnormal operations;
[0054] The third module is used to extract the user's historical behavior information from the log file when there is no abnormal operation, wherein the historical behavior information includes historical risk behavior information and historical safety behavior information;
[0055] The fourth module is used to calculate the user's target risk operation coefficient based on the historical risk behavior information and the historical safety behavior information, and to limit the user's authority based on the target risk operation coefficient.
[0056] Compared with the prior art, the present invention has the following beneficial effects:
[0057] The present invention relates to the technical field of network auditing, and discloses a user operation auditing method and system of a microservice architecture, the method comprising: obtaining the current operation behavior of the user, indexing the current operation behavior to a virtual service end, and judging whether there is an abnormal operation in the current operation behavior within a first preset time; when there is an abnormal operation, issuing an early warning reminder in real time; when there is no abnormal operation, extracting the user's historical behavior information from a log file, wherein the historical behavior information includes historical risk behavior information and historical safety behavior information; calculating the user's target risk operation coefficient according to the historical risk behavior information and the historical safety behavior information, and restricting the user according to the target risk operation coefficient. The present invention can accurately audit the user's operation behavior, effectively improve the audit efficiency, and issue a timely early warning for abnormal operation behavior to ensure information security. BRIEF DESCRIPTION OF THE DRAWINGS
[0058] Various other advantages and benefits will become apparent to those of ordinary skill in the art by reading the detailed description of the preferred embodiments below. The accompanying drawings are only for the purpose of illustrating the preferred embodiments and are not to be considered as limiting the present invention. Moreover, the same reference symbols are used throughout the accompanying drawings to represent the same components. In the accompanying drawings:
[0059] Figure 1 A schematic diagram of a process flow of a user operation audit method of a microservice architecture in an embodiment of the present invention is shown;
[0060] Figure 2 A structural diagram of a user operation audit system with a microservice architecture in an embodiment of the present invention is shown. DETAILED DESCRIPTION
[0061] The specific implementation of the present invention is further described in detail below in conjunction with the accompanying drawings and examples. The following examples are used to illustrate the present invention, but are not intended to limit the scope of the present invention.
[0062] In the description of the present application, it should be understood that the terms "center", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", etc., indicating orientations or positional relationships, are based on the orientations or positional relationships shown in the accompanying drawings, and are only for the convenience of describing the present application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as a limitation on the present application.
[0063] The terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features. In the description of this application, unless otherwise specified, "plurality" means two or more.
[0064] In the description of this application, it should be noted that, unless otherwise clearly specified and limited, the terms "installed", "connected", and "connected" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be indirectly connected through an intermediate medium, or it can be the internal communication of two components. For ordinary technicians in this field, the specific meanings of the above terms in this application can be understood according to specific circumstances.
[0065] The following is a description of preferred embodiments of the present invention with reference to the accompanying drawings.
[0066] like Figure 1As shown, an embodiment of the present invention discloses a user operation audit method of a microservice architecture, comprising:
[0067] S110: Acquire the current operation behavior of the user, index the current operation behavior to the virtual server, and determine whether there is an abnormal operation in the current operation behavior within a first preset time;
[0068] In some embodiments of the present application, when obtaining the current operation behavior of the user, indexing the current operation behavior to the virtual server, and determining whether there is an abnormal operation in the current operation behavior within a first preset time, it includes:
[0069] Obtaining the user's current operation behavior, wherein the current operation behavior includes download frequency, download time, download data volume and download speed;
[0070] Establish the current operation behavior set A1, set A1={B1, C1, D1, E1}, where B1 is the download frequency information, C1 is the download time information, D1 is the download data volume information, and E1 is the download speed information;
[0071] Establish a preset operation behavior set A0, set A0={B0, C0, D0, E0}, where B0 is the preset download frequency information, C0 is the preset download time information, D0 is the preset download data volume information, and E0 is the preset download speed information;
[0072] When B1, C1, D1 and E1 are all within B0, C0, D0 and E0, it is determined that there is no abnormal operation;
[0073] When one or more of B1, C1, D1 and E1 are not located within B0, C0, D0 and E0, it is determined that abnormal operation may exist.
[0074] In this embodiment, the virtual server is a virtual system that is the same as the microservice architecture operating system.
[0075] In this embodiment, the first preset time can be set according to actual conditions, and can be 10 minutes or 20 minutes.
[0076] In this embodiment, when the download frequency, download time, download data volume, and download speed are all consistent with the preset download frequency information, preset download time information, preset download data volume information, and preset download speed information, it is determined that there is no abnormal operation.
[0077] The beneficial effect of the above technical solution is that the present invention can simply and clearly determine whether the user has performed abnormal operations, or has possible abnormal operations, thereby avoiding information leakage in the microservice architecture and ensuring data and information security.
[0078] In some embodiments of the present application, after determining that an abnormal operation may exist, the method further includes:
[0079] Extract the current operation behaviors that are not in B0, C0, D0 and E0, and input them into the behavior simulation model to obtain the behavior simulation network;
[0080] The behavior simulation network is input into the behavior simulation network link breaking model to obtain the number of behavior simulation network link breaking, and if the number of link breaking is greater than or equal to the preset number of abnormal link breaking, it is determined that an abnormal operation exists;
[0081] If the number of broken links is less than the preset abnormal number of broken links, it is determined that there is no abnormal operation.
[0082] In this embodiment, the behavior simulation network includes multiple current operation behaviors, and every two current operation behaviors are connected by a link.
[0083] In this embodiment, the simulated network disconnection model is pre-trained and is obtained through training based on different data samples, and can perform disconnection processing for abnormal operations.
[0084] In this embodiment, no matter whether the current operation behavior is one or more than one that is not in B0, C0, D0 and E0, as long as the number of broken links is greater than or equal to the preset abnormal number of broken links, it is determined that an abnormal operation exists.
[0085] The beneficial effect of the above technical solution is that the present invention can accurately determine whether the current user has any abnormal operation, realize accurate auditing, and effectively improve auditing efficiency.
[0086] In some embodiments of the present application, the method for constructing the log file includes:
[0087] Obtain user information and behavior information of the microservice architecture operating system; wherein the user information includes: user name, IP address, and login time;
[0088] Determine the storage path of the log file;
[0089] Creating a log file template according to the user information, and initializing the log file template;
[0090] The behavior information that conforms to the log file name pattern and is located in the log file storage path is imported into the initialized log file queue one by one in the order of modification time to obtain the log file.
[0091] In this embodiment, the behavior information includes all behavior information of the user, including safe behavior information and risky behavior information.
[0092] The beneficial effect of the above technical solution is that the present invention can improve data processing efficiency and accurately extract user-related behavior information by constructing log files.
[0093] S120: When there is abnormal operation, a warning reminder is issued in real time;
[0094] S130: When there is no abnormal operation, extract the user's historical behavior information from the log file, wherein the historical behavior information includes historical risk behavior information and historical safety behavior information;
[0095] S140: Calculate the user's target risk operation coefficient based on the historical risk behavior information and the historical safety behavior information, and restrict the user's authority based on the target risk operation coefficient.
[0096] In some embodiments of the present application, when calculating the user's target risk operation coefficient according to the historical risk behavior information and the historical safety behavior information, it includes:
[0097] Extract the user's historical login time from the log file and count the corresponding time numbers;
[0098] Determine the historical risk behavior information and historical safety behavior information corresponding to each historical login moment;
[0099] Performing behavior analysis on the historical risk behavior information, and determining the risk impact value corresponding to each historical risk behavior information based on the analysis result;
[0100] Construct a risk impact value set based on all risk impact values;
[0101] Count the number of moments corresponding to historical risky behavior information and the number of moments corresponding to historical safe behavior information respectively;
[0102] Calculate the user's initial risk operation coefficient based on the risk impact value set, the number of moments corresponding to the historical risk behavior information, and the number of moments corresponding to the historical safety behavior information;
[0103] Calculate the user's initial risk operation coefficient according to the following formula:
[0104] ;
[0105] Among them, h is the user's initial risk operation coefficient, t1 is the number of moments corresponding to historical risk behavior information, t2 is the number of moments corresponding to historical safety behavior information, t1+t2=n, n is the number of moments corresponding to historical login moments, Li is the i-th risk impact value in the risk impact value set, Lmax is the largest risk impact value in the risk impact value set, a is the first calculation conversion coefficient, b is the second calculation conversion coefficient, and a+b=1.
[0106] In this embodiment, the time from when a user logs in to when the user goes offline is regarded as one login time.
[0107] In this embodiment, each login moment may correspond to historical risk behavior information, historical safety behavior information, or may include both historical risk behavior information and historical safety behavior information.
[0108] In this embodiment, the risk impact value refers to the impact of historical risk behavior information on the microservice architecture operating system, which can be obtained based on historical data.
[0109] In this embodiment, when a login time includes both historical risk behavior information and historical safety behavior information, this login time is used as both the time number corresponding to the historical risk behavior information and the time number corresponding to the historical safety behavior information.
[0110] The beneficial effect of the above technical solution is: the present invention calculates the user's initial risk operation coefficient based on the risk impact value set, the number of moments corresponding to historical risk behavior information, and the number of moments corresponding to historical safety behavior information. By calculating the user's initial risk operation coefficient, it can lay the foundation for user limitation processing, ensure the accuracy of limitation, and avoid large errors.
[0111] In some embodiments of the present application, after calculating the initial risk operation coefficient of the user according to the risk impact value set, the number of moments corresponding to the historical risk behavior information, and the number of moments corresponding to the historical safety behavior information, the method further includes:
[0112] Obtaining comprehensive risk operation behavior information of the microservice architecture operating system;
[0113] Determine the intersection operation behavior between the historical safety behavior information and the comprehensive risk operation behavior information, and obtain an intersection behavior set according to the intersection operation behavior;
[0114] Deleting the intersection behaviors in the historical safety behavior information, and constructing a non-intersection safety behavior information set based on the remaining historical safety behavior information;
[0115] Calculate the user's potential risk coefficient based on the intersection behavior set and the non-intersection safety behavior information set;
[0116] The initial risk operation coefficient is corrected according to the potential risk coefficient to obtain the target risk operation coefficient.
[0117] In this embodiment, the comprehensive risk operation behavior information refers to all risk operation behavior information occurring in the microservice architecture operating system.
[0118] In this embodiment, the historical security behavior information of the current user may also be risky, but the current user did not perform any abnormal operation during the operation, but there is a corresponding precedent, such as uploading a link.
[0119] In some embodiments of the present application, when calculating the potential risk coefficient of the user according to the intersection behavior set and the non-intersection safety behavior information set, it includes:
[0120] Counting a first number of intersection behaviors in the intersection behavior set, and counting a second number of safety behavior information in the non-intersection safety behavior information set;
[0121] The potential risk factor of the user is calculated according to the first number and the second number.
[0122] In this embodiment, the potential risk coefficient of the user is calculated according to the first quantity / the second quantity.
[0123] In some embodiments of the present application, when the initial risk operation coefficient is corrected according to the potential risk coefficient to obtain the target risk operation coefficient, it includes:
[0124] Presetting a first preset potential risk factor and a second preset potential risk factor;
[0125] Presetting a first preset initial risk operation correction coefficient, a second preset initial risk operation correction coefficient, and a third preset initial risk operation correction coefficient;
[0126] Selecting an initial risk operation correction coefficient according to the potential risk coefficient, the first preset potential risk coefficient and the second preset potential risk coefficient, and correcting the initial risk operation coefficient based on the selected initial risk operation correction coefficient to obtain a target risk operation coefficient;
[0127] When the potential risk coefficient is less than the first preset potential risk coefficient, the first preset initial risk operation correction coefficient is selected to correct the initial risk operation coefficient;
[0128] When the potential risk coefficient is greater than or equal to the first preset potential risk coefficient, and the potential risk coefficient is less than the second preset potential risk coefficient, the second preset initial risk operation correction coefficient is selected to correct the initial risk operation coefficient;
[0129] When the potential risk coefficient is greater than or equal to the second preset potential risk coefficient, the third preset initial risk operation correction coefficient is selected to correct the initial risk operation coefficient.
[0130] In this embodiment, the first preset potential risk coefficient is smaller than the second preset potential risk coefficient.
[0131] In this embodiment, the first preset initial risk operation correction coefficient is smaller than the second preset initial risk operation correction coefficient, which is smaller than the third preset initial risk operation correction coefficient, and 0.8<first preset initial risk operation correction coefficient<second preset initial risk operation correction coefficient<third preset initial risk operation correction coefficient<1.2.
[0132] In this embodiment, the product value of the initial risk operation correction coefficient and the initial risk operation coefficient is used as the target risk operation coefficient.
[0133] The beneficial effect of the above technical solution is: an initial risk operation correction coefficient is selected according to the potential risk coefficient, the first preset potential risk coefficient and the second preset potential risk coefficient, and the initial risk operation coefficient is corrected based on the selected initial risk operation correction coefficient to obtain a target risk operation coefficient. The present invention can achieve accurate setting of the target risk coefficient and avoid complex manual calculations, while also ensuring setting accuracy and improving work efficiency.
[0134] In some embodiments of the present application, when the target risk operation coefficient is larger, the user's authority restriction is larger, such as setting the user's operation authority to 70% of the original; when the target risk operation coefficient is smaller, the user's authority restriction is smaller, such as setting the user's operation authority to 30% of the original, and setting the authority limit interval to [20%, 80%]. The specific setting can be made according to the actual situation.
[0135] In order to further explain the technical idea of the present invention, the technical solution of the present invention is now described in combination with specific application scenarios.
[0136] Correspondingly, such as Figure 2 As shown, the present application also provides a user operation audit system of a microservice architecture, including:
[0137] The first module is used to obtain the current operation behavior of the user, index the current operation behavior to the virtual server, and determine whether there is an abnormal operation in the current operation behavior within a first preset time;
[0138] The second module is used to issue early warning reminders in real time when there are abnormal operations;
[0139] The third module is used to extract the user's historical behavior information from the log file when there is no abnormal operation, wherein the historical behavior information includes historical risk behavior information and historical safety behavior information;
[0140] The fourth module is used to calculate the user's target risk operation coefficient based on the historical risk behavior information and the historical safety behavior information, and to limit the user's authority based on the target risk operation coefficient.
[0141] In the description of the above embodiments, specific features, structures, materials or characteristics may be combined in a suitable manner in any one or more embodiments or examples.
[0142] Although the present invention has been described above with reference to the embodiments, various modifications may be made thereto and parts thereof may be replaced with equivalents without departing from the scope of the present invention. In particular, as long as there is no structural conflict, the various features in the embodiments disclosed by the present invention may be used in combination with each other in any manner, and the fact that these combinations are not fully described in this specification is only for the sake of omitting space and saving resources.
[0143] Those skilled in the art can understand that the above are only preferred embodiments of the present invention and are not intended to limit the present invention. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art can still modify the technical solutions recorded in the aforementioned embodiments or replace some of the technical features therein by equivalents. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A user operation audit method for a microservice architecture, characterized in that: include: Acquire the user's current operation behavior, index the current operation behavior to the virtual server, and determine whether there is an abnormal operation in the current operation behavior within a first preset time; When there is abnormal operation, early warning reminders are issued in real time; When there is no abnormal operation, extracting the user's historical behavior information from the log file, wherein the historical behavior information includes historical risk behavior information and historical safety behavior information; Calculating the user's target risk operation coefficient based on the historical risk behavior information and the historical safety behavior information, and restricting the user's authority based on the target risk operation coefficient; When calculating the target risk operation coefficient of the user according to the historical risk behavior information and the historical safety behavior information, it includes: Extract the user's historical login time from the log file and count the corresponding time numbers; Determine the historical risk behavior information and historical safety behavior information corresponding to each historical login moment; Performing behavior analysis on the historical risk behavior information, and determining the risk impact value corresponding to each historical risk behavior information based on the analysis result; Construct a risk impact value set based on all risk impact values; Count the number of moments corresponding to historical risky behavior information and the number of moments corresponding to historical safe behavior information respectively; Calculate the user's initial risk operation coefficient based on the risk impact value set, the number of moments corresponding to the historical risk behavior information, and the number of moments corresponding to the historical safety behavior information; Calculate the user's initial risk operation coefficient according to the following formula: ; Wherein, h is the user's initial risk operation coefficient, t1 is the number of moments corresponding to historical risk behavior information, t2 is the number of moments corresponding to historical security behavior information, t1+t2=n, n is the number of moments corresponding to historical login moments, Li is the i-th risk impact value in the risk impact value set, Lmax is the maximum risk impact value in the risk impact value set, a is the first calculation conversion coefficient, b is the second calculation conversion coefficient, and a+b=1; After calculating the initial risk operation coefficient of the user according to the risk impact value set, the number of moments corresponding to the historical risk behavior information, and the number of moments corresponding to the historical safety behavior information, the method further includes: Obtaining comprehensive risk operation behavior information of the microservice architecture operating system; Determine the intersection operation behavior between the historical safety behavior information and the comprehensive risk operation behavior information, and obtain an intersection behavior set according to the intersection operation behavior; Deleting the intersection behaviors in the historical safety behavior information, and constructing a non-intersection safety behavior information set based on the remaining historical safety behavior information; Calculate the user's potential risk coefficient based on the intersection behavior set and the non-intersection safety behavior information set; The initial risk operation coefficient is modified according to the potential risk coefficient to obtain a target risk operation coefficient; When calculating the potential risk coefficient of the user according to the intersection behavior set and the non-intersection safety behavior information set, it includes: Counting a first number of intersection behaviors in the intersection behavior set, and counting a second number of safety behavior information in the non-intersection safety behavior information set; Calculate the potential risk factor of the user according to the first number and the second number; When the initial risk operation coefficient is corrected according to the potential risk coefficient to obtain the target risk operation coefficient, it includes: Presetting a first preset potential risk factor and a second preset potential risk factor; Presetting a first preset initial risk operation correction coefficient, a second preset initial risk operation correction coefficient, and a third preset initial risk operation correction coefficient; Selecting an initial risk operation correction coefficient according to the potential risk coefficient, the first preset potential risk coefficient and the second preset potential risk coefficient, and correcting the initial risk operation coefficient based on the selected initial risk operation correction coefficient to obtain a target risk operation coefficient; When the potential risk coefficient is less than the first preset potential risk coefficient, the first preset initial risk operation correction coefficient is selected to correct the initial risk operation coefficient; When the potential risk coefficient is greater than or equal to the first preset potential risk coefficient, and the potential risk coefficient is less than the second preset potential risk coefficient, the second preset initial risk operation correction coefficient is selected to correct the initial risk operation coefficient; When the potential risk coefficient is greater than or equal to the second preset potential risk coefficient, the third preset initial risk operation correction coefficient is selected to correct the initial risk operation coefficient.
2. The user operation audit method of the microservice architecture according to claim 1 is characterized in that: When obtaining the current operation behavior of the user, indexing the current operation behavior to the virtual server, and determining whether there is an abnormal operation in the current operation behavior within a first preset time, the method includes: Obtaining the user's current operation behavior, wherein the current operation behavior includes download frequency, download time, download data volume and download speed; Establish the current operation behavior set A1, set A1={B1, C1, D1, E1}, where B1 is the download frequency information, C1 is the download time information, D1 is the download data volume information, and E1 is the download speed information; Establish a preset operation behavior set A0, set A0={B0, C0, D0, E0}, where B0 is the preset download frequency information, C0 is the preset download time information, D0 is the preset download data volume information, and E0 is the preset download speed information; When B1, C1, D1 and E1 are all within B0, C0, D0 and E0, it is determined that there is no abnormal operation; When one or more of B1, C1, D1 and E1 are not located within B0, C0, D0 and E0, it is determined that abnormal operation may exist.
3. The user operation audit method of the microservice architecture according to claim 2 is characterized in that: After determining that there may be abnormal operations, it also includes: Extract the current operation behaviors that are not in B0, C0, D0 and E0, and input them into the behavior simulation model to obtain the behavior simulation network; The behavior simulation network is input into the behavior simulation network link breaking model to obtain the number of behavior simulation network link breaking, and if the number of link breaking is greater than or equal to the preset number of abnormal link breaking, it is determined that an abnormal operation exists; If the number of broken links is less than the preset abnormal number of broken links, it is determined that there is no abnormal operation.
4. The user operation audit method of the microservice architecture according to claim 1 is characterized in that: The log file construction method includes: Obtain user information and behavior information of the microservice architecture operating system; wherein the user information includes: user name, IP address, login time; Determine the storage path of the log file; Creating a log file template according to the user information, and initializing the log file template; The behavior information that conforms to the log file name pattern and is located in the log file storage path is imported into the initialized log file queue one by one in the order of modification time to obtain the log file.
5. A user operation audit system of a microservice architecture, applied to the user operation audit method of a microservice architecture as claimed in any one of claims 1 to 4, characterized in that: include: The first module is used to obtain the current operation behavior of the user, index the current operation behavior to the virtual server, and determine whether there is an abnormal operation in the current operation behavior within a first preset time; The second module is used to issue early warning reminders in real time when there are abnormal operations; The third module is used to extract the user's historical behavior information from the log file when there is no abnormal operation, wherein the historical behavior information includes historical risk behavior information and historical safety behavior information; The fourth module is used to calculate the user's target risk operation coefficient based on the historical risk behavior information and the historical safety behavior information, and to limit the user's authority based on the target risk operation coefficient.
Citation Information
Patent Citations
Account risk identification method and device
CN106529288A
Risk detection method and device
CN111818066A
Fault warning method for charging equipment
CN114954088A
Zero-trust security credible auditing method for 5G double-domain private network
CN116074843A
Slope safety management method and system based on digital twinning
CN116402951A
