Log auditing method and device
By analyzing the number of operations in the user operation log, the regularity of the user's operation behavior is identified, which solves the problem of low efficiency in identifying operations within the scope of user authority in the existing technology, and enables accurate abnormal judgment of user operations and timely discovery of security risks. .
Patent Information
- Application Number
- CN202410595384.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-14
- Publication Date
- 2024-10-18
- Estimated Expiration
- 2044-05-14
AI Technical Summary
Existing log audit technology has low efficiency in identifying operations within the scope of user permissions, and cannot accurately determine whether there are abnormal user operations, making it difficult to detect security risks in a timely manner.
By obtaining the operation log of the target user, counting the number of user operations in different time periods, judging the user as an abnormal user based on the regularity of the number of operations, using image analysis methods to identify the regularity of operation behavior, and improving the efficiency of log analysis.
It achieves accurate and regular identification of user operating behaviors, improves log audit efficiency, can detect potential security risks in a timely manner, and avoids inefficiencies caused by processing large amounts of log content.
Smart Images

Figure CN118802470A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of computer technology, and in particular to a log auditing method and device. Background Art
[0002] Log auditing can help users timely discover security risks in the network and accurately collect evidence afterwards, thereby more effectively ensuring the safe operation of their own networks. There are two main types of log auditing methods: one is based on the audit of the operation content recorded in the operation log, and the other is through processing the original logs collected from major data platform components.
[0003] However, the log auditing method of related technologies usually determines whether the user's operation is illegal based on the legality of the operation content. However, if the user operates within the scope of authority, it is impossible to accurately determine whether the user's operation is abnormal, making the log auditing efficiency of related technologies low. Summary of the invention
[0004] The present invention provides a log audit method and device.
[0005] According to a first aspect of the present disclosure, a log audit method is provided, the method comprising:
[0006] Acquire an operation log of a target user, wherein the operation log includes the number of operations of the target user within a target time period, wherein the target time period includes a plurality of unit time periods, and each unit time period includes a plurality of sub-unit time periods;
[0007] Based on the number of operations of the target user in each unit time period, when it is determined that the number of operations of the target user in M adjacent unit time periods in the target time period is regular, counting the number of operations of the target user in each sub-unit time period;
[0008] Based on the number of operations of the target user in each sub-unit time period, when it is determined that the number of operations of the target user in N adjacent sub-unit time periods in each unit time period is regular, the target user is determined to be an abnormal user; wherein M and N are both positive integers.
[0009] According to a second aspect of the present disclosure, a log auditing device is provided, the device comprising:
[0010] A log acquisition module, used to acquire an operation log of a target user, wherein the operation log includes the number of operations of the target user within a target time period, wherein the target time period includes a plurality of unit time periods, and each unit time period includes a plurality of sub-unit time periods;
[0011] An operation count counting module, for counting the operation count of the target user in each sub-unit time period based on the operation count of the target user in each unit time period, when it is determined that the operation count of the target user in M adjacent unit time periods in the target time period has regularity;
[0012] An abnormal user determination module is used to determine that the target user is an abnormal user based on the number of operations of the target user in each sub-unit time period, when it is determined that the number of operations of the target user in N adjacent sub-unit time periods in each unit time period is regular; wherein M and N are both positive integers.
[0013] According to a third aspect of the present disclosure, an electronic device is provided, which includes a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the program, the method described above is implemented.
[0014] According to a fourth aspect of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored, and when the program is executed by a processor, the above method of the present disclosure is implemented.
[0015] The log audit method and device provided by the embodiment of the present disclosure obtain the operation log of the target user, and based on the number of operations of the target user in each unit time period, when it is determined that the number of operations of the target user in the adjacent M unit time periods in the target time period has regularity, count the number of operations of the target user in each sub-unit time period. Based on the number of operations of the target user in each sub-unit time period, when it is determined that the number of operations of the target user in the adjacent N sub-unit time periods in each unit time period has regularity, the target user is determined to be an abnormal user. In this way, by counting the number of operations in the user operation log, the regularity of the user's operation behavior can be accurately determined, and the situation of low log analysis efficiency caused by processing a large amount of log content can be avoided. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] Further details, features and advantages of the present disclosure are disclosed in the following description of exemplary embodiments in conjunction with the accompanying drawings, in which:
[0017] Figure 1 A schematic diagram of a graph corresponding to daily statistics of operation times provided by an exemplary embodiment of the present disclosure;
[0018] Figure 2 A schematic diagram of a graph corresponding to the number of operations counted by hour provided by an exemplary embodiment of the present disclosure;
[0019] Figure 3 A schematic diagram of a time matrix provided for an exemplary embodiment of the present disclosure;
[0020] Figure 4 A schematic diagram of time matrix division provided for an exemplary embodiment of the present disclosure;
[0021] Figure 5 A schematic diagram of non-empty matrix comparison provided for an exemplary embodiment of the present disclosure;
[0022] Figure 6 A flow chart of a log audit method provided for an exemplary embodiment of the present disclosure;
[0023] Figure 7 A schematic block diagram of the functional modules of a log auditing device provided for an exemplary embodiment of the present disclosure;
[0024] Figure 8 A structural block diagram of an electronic device provided for an exemplary embodiment of the present disclosure;
[0025] Fig. 9 A structural block diagram of a computer system provided for an exemplary embodiment of the present disclosure. DETAILED DESCRIPTION
[0026] Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although certain embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as being limited to the embodiments described herein, which are instead provided for a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not intended to limit the scope of protection of the present disclosure.
[0027] It should be understood that the various steps described in the method embodiments of the present disclosure may be performed in different orders and / or in parallel. In addition, the method embodiments may include additional steps and / or omit the steps shown. The scope of the present disclosure is not limited in this respect.
[0028] The term "including" and its variations used in this document are open inclusions, that is, "including but not limited to". The term "based on" means "based at least in part on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one other embodiment"; the term "some embodiments" means "at least some embodiments". Relevant definitions of other terms will be given in the description below. It should be noted that the concepts of "first", "second", etc. mentioned in this disclosure are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units.
[0029] It should be noted that the modifications of "one" and "plurality" mentioned in the present disclosure are illustrative rather than restrictive, and those skilled in the art should understand that unless otherwise clearly indicated in the context, it should be understood as "one or more".
[0030] The names of the messages or information exchanged between multiple devices in the embodiments of the present disclosure are only used for illustrative purposes and are not used to limit the scope of these messages or information.
[0031] It is understandable that before using the technical solutions disclosed in the embodiments of the present disclosure, the types, scope of use, usage scenarios, etc. of the personal information involved in the present disclosure should be informed to the user and the user's authorization should be obtained in an appropriate manner in accordance with relevant laws and regulations.
[0032] For example, in response to receiving an active request from a user, a prompt message is sent to the user to clearly prompt the user that the operation requested to be performed will require obtaining and using the user's personal information. Thus, the user can autonomously choose whether to provide personal information to software or hardware such as an electronic device, application, server, or storage medium that performs the operation of the technical solution of the present disclosure according to the prompt message.
[0033] As an optional but non-limiting implementation, in response to receiving an active request from the user, the method of sending a prompt message to the user may be, for example, a pop-up window, in which the prompt message may be presented in text. In addition, the pop-up window may also carry a selection control for the user to choose "agree" or "disagree" to provide personal information to the electronic device. It is understandable that the above notification and the process of obtaining user authorization are only illustrative and do not constitute a limitation on the implementation of the present disclosure. Other methods that meet relevant laws and regulations may also be applied to the implementation of the present disclosure.
[0034] In order to maintain network security, the log auditing methods of related technologies are mainly divided into the following categories: One is based on the audit of the operation content recorded in the operation log, decomposing the operation command, issuing a warning message when an illegal operation is detected, and extracting illegal operations, thereby discovering the user operation risk behavior in the operation log. One is to parse the original logs collected from major data platform components, standardize the field mapping, and divide the operation type and operation details of the logs, standardize the initial logs, and use the corresponding audit rules and analysis strategies to perform automated audit analysis on the standardized logs. One is to use user basic information data, user behavior data, and business data as user behavior feature data to build a user behavior prediction model. When the user behavior log does not match the prediction model, an alarm is issued in time, or relevant measures are taken to stop the user from continuing abnormal operations in time.
[0035] The log audit strategies in related technologies all require the definition of abnormal behavior content in advance, or the use of machine learning methods to train models of normal user operations, and then discover abnormal risks in the logs based on the rules of the audit strategy. However, related technologies have problems such as poor detection of regular user operations, high model training costs, and poor applicability to large-scale users.
[0036] Specifically, the log auditing method of the relevant technology, no matter what key content is used for auditing, ultimately determines whether the user operation is illegal based on the legality of the operation content. However, if the user operates within the scope of authority, no matter whether the operation is performed multiple times (such as frequent, uninterrupted or batch, etc.), and whether the operation is reasonable and meets the actual business needs, no problem can be audited, so that illegal operations of the relevant technology within the scope of the user's authority will still occur.
[0037] In addition, related technologies generally have very fixed rules for identifying regular operations, such as the number of operations within a certain time range being consistent or the time interval between operations being consistent, etc. However, after these rules are identified once, users can quickly change access policies after receiving feedback such as restrictions to avoid the risk of being audited again. In addition, after setting up an automated program to operate, if users insert manual operations into it, the regularity of log records will be broken, resulting in identification failure, making related technologies less efficient in identifying regular operations.
[0038] Therefore, in order to solve the above technical problems, the embodiment of the present disclosure marks the time of the operation log of a unified user to form an operation time distribution graph per unit time, and identifies the regular operation behavior of the user through correlation analysis of the time distribution graph. When analyzing the operation log, the user name and operation time in the operation log can be extracted only according to the operation type, which can greatly improve the efficiency of log analysis when processing a large number of logs.
[0039] It should be noted that the user involved in the embodiments of the present disclosure may be an operator user, that is, a person who can log in to the system and operate the system to operate the system, and can help ordinary system users to perform transaction processing and other related work. The user can query the personal data or business data of ordinary users through the system login, and the embodiments are not limited to this.
[0040] The operation log in the embodiment may be a log recorded by the system when the user operates through the system, and its content may at least include: user name, operation time and operation content. Key information may be the user name, operation time and operation content in the user operation log recorded by the system, such as login information, query information and download content.
[0041] Specifically, in the embodiment, the user's operation log within a period of time can be obtained, and key information can be extracted and processed from the user's operation log, and the operation time of each user can be extracted according to the operation type. The operation type can be data downloading or data viewing, etc., and the embodiment is not limited thereto.
[0042] In order to identify some users who use their own user rights to download or view the user data of individual users by writing scripts and other means, and then obtain illegal benefits, it is necessary to identify the regularity of the user's operation behavior. By obtaining the user's operation log, it is possible to identify whether the user's operation behavior has regular behavior.
[0043] Specifically, the number of user operations is obtained through the user's operation log. For example, statistics can be made on a daily basis. The number of operations per day within a period of time can be: D1, D2, D3...D x ; and convert the number of operations per day of the above users into a bar chart, such as Figure 1 As shown, 30 is used as an example to illustrate, and the image analysis method is used to determine whether the graph composed of the maximum number of adjacent days m (m is greater than or equal to 2) appears repeatedly in the bar graph. D errors are allowed every day. Generally, d is set to a certain proportion of all operations in m days. If the same graph appears, it means that the operations of m adjacent days are regular, such as D4 to D8. Among them, x, m and d are integers.
[0044] Similarly, after determining that the operation of m consecutive days is regular, we need to further analyze D x ~D (x+m) Make an analysis and judgment. x The number of operations is counted by hour: H1, H2, H3...H x ;, transform and map to the labels in the bar chart, such as Figure 2 , and use the image analysis method to determine whether the graph composed of the maximum number of adjacent hours n (n is greater than or equal to 2 and less than or equal to 12) appears repeatedly in the bar chart (an error of h times is allowed per hour, and h is generally set to a certain proportion of all operations in n hours). If the same graph appears, it means that the operations in n adjacent hours are regular, such as H7 to H9. Among them, n and h are integers.
[0045] In the embodiment, if it can be determined through the above method that there are more than y days in x days with n consecutive hours of operation, it can be determined that the user's operation behavior has regular behavior in the hour dimension. Wherein, y is an integer greater than zero and less than x, and y can be a threshold set as needed.
[0046] Through the judgment of the above embodiment, when it is determined that the user's operation behavior has regular behavior in the hour dimension, the operation log in the hour dimension can be further analyzed, and the user's operation time per hour is mapped in a 60*60 matrix T with the vertical axis as minutes and the horizontal axis as seconds, such as Figure 3 As shown in the figure, if a user has multiple operation logs in the same second, statistics are collected based on one operation log to form a user operation time matrix T0~T 23 .in, Figure 3 In the matrix, each grid on the horizontal axis represents 1 second from left to right, that is, the horizontal axis represents 0 to 59 seconds. Each grid on the vertical axis represents 1 minute, that is, the horizontal axis represents 0 to 59 minutes. ab represents the operation log of the user at the bth second in the ath minute. If T ab If it is not empty, it can be set to 1, otherwise it is set to 0. Figure 3 The filled spaces in indicate that there are corresponding operation logs.
[0047] For a non-empty matrix, such as Figure 4 As shown, T x Divided into 9 sub-areas: T x00 , T x01 , T x02 , T x10 , T x11 , T x12 , T x20 , T x21 and T x22 .
[0048] In an embodiment, it can be determined in turn whether the above 9 sub-areas are empty. If they are empty, they will not be considered (such as Tx20 and Tx21), and the non-empty sub-areas can be checked and judged. For example, it can be compared whether the non-empty sub-areas in each hour are similar. If the non-empty sub-area of a certain hour has a similarity greater than a threshold with the non-empty sub-areas of other C hours, it can be determined that there is regularity in the user's operation log.
[0049] For example, Figure 5 As shown, the non-empty sub-region is checked and judged: the non-empty sub-region in the matrix is moved up, down, left, and right to see whether the sub-region appears in other operation time matrices of the user. If so (such as Tx00), it means that the operation has regularity.
[0050] Based on the above embodiments, the present disclosure also provides a log audit method, such as Figure 6 As shown, the method may include the following steps:
[0051] In step S610, an operation log of a target user is obtained, where the operation log includes the number of operations performed by the target user within a target time period.
[0052] The target time period includes a plurality of unit time periods, and each unit time period includes a plurality of sub-unit time periods.
[0053] In the embodiment, the target time period can be set as needed, for example, the target time period can be 30 days, but the embodiment is not limited thereto. The target time period includes multiple unit time periods, and the unit time period can be 1 day or a week, etc., and can be set as needed. Each unit time period includes multiple sub-unit time periods. If the unit time period is a week, the sub-unit time period can be 1 day; if the unit time period is 1 day, the sub-unit time period can be 1 hour, and can be set as needed, but the embodiment is not limited thereto.
[0054] In step S620, based on the number of operations of the target user in each unit time period, when it is determined that the number of operations of the target user in M adjacent unit time periods in the target time period is regular, the number of operations of the target user in each sub-unit time period is counted.
[0055] In the embodiment, by obtaining the number of operations of the target user in each unit time period, if the number of operations of the user is repeated every M unit time periods, it means that the number of operations of the target user in the M adjacent unit time periods in the target time period is regular. In this way, the number of operations of the target user in each sub-unit time period can be further counted.
[0056] Specifically, the number of operations of the target user in each unit time period may be counted, and the number of operations of the target user in each unit time period may be converted into a target graph. By obtaining the similarity between the target graphs in M adjacent unit time periods, and when the similarity is greater than a first threshold, it is determined that the number of operations of the target user in M adjacent unit time periods in the target time period has regularity.
[0057] like Figure 1 As shown, the target graph can specifically be a bar graph. Taking the target time period of 30 days as an example, by counting the number of operations of the user every day, a sliding window containing M days can be set, and the sliding window is slid on the target graph. The M can be incremented from 1. When the window slides, when the similarity between the bar graph corresponding to the number of operations in the first M days and the bar graph corresponding to the number of operations in the next M days is greater than a first threshold, it indicates that the number of operations of the target user in the adjacent M unit time periods in the target time period is regular.
[0058] In step S630, based on the number of operations of the target user in each sub-unit time period, if it is determined that the number of operations of the target user in N adjacent sub-unit time periods in each unit time period is regular, the target user is determined to be an abnormal user.
[0059] In an embodiment, after determining that the number of operations of the target user in M adjacent unit time periods in a target time period is regular, the number of operations of the target user in each sub-unit time period can be further counted, and it can be determined whether the number of operations of the target user in N adjacent sub-unit time periods in each unit time period is regular. When it is determined that the number of operations of the target user in N adjacent sub-unit time periods in each unit time period is regular, the target user can be determined to be an abnormal user.
[0060] Specifically, the number of operations of the target user in each sub-unit time period in the target unit time period can be counted, and the number of operations in each sub-unit time period can be converted into a target graph. By obtaining the similarity between the target graphs in N adjacent sub-unit time periods, and when the similarity is greater than a second threshold, it is determined that the number of operations of the target user in N adjacent sub-unit time periods in the target unit time period has regularity. In this way, the number of target unit time periods with this regularity can be counted, and when the proportion of the target time periods is greater than a preset proportion, it can be determined that the number of operations of the target user in N adjacent sub-unit time periods in each unit time period has regularity, and then the target user can be determined to be an abnormal user, and an early warning can be issued at this time so as to take reasonable measures to avoid further risks such as leakage of related data.
[0061] Can be combined Figure 2 As shown, the target graph can be specifically a bar graph, which can count the number of operations of the user per hour and convert the number of operations into a bar graph. Similarly, a sliding window containing N hours can be set, and the sliding window can be used to slide on the target graph. When the similarity between the bar graph corresponding to the number of operations in the first N hours and the bar graph corresponding to the number of operations in the last N hours is greater than a second threshold during the sliding process of the window, it indicates that the number of operations of the target user in the adjacent N unit time periods in the target time period is regular. N can be incremented from 1. If there is no regular number of operations, the value contained in the sliding window is added by 1, and the maximum value can be 60, until the number of operations of the target user in the adjacent N unit time periods in the target time period is regular.
[0062] The log audit method provided by the embodiment of the present disclosure obtains the operation log of the target user, and based on the number of operations of the target user in each unit time period, when it is determined that the number of operations of the target user in the adjacent M unit time periods in the target time period has regularity, the number of operations of the target user in each sub-unit time period is counted. Based on the number of operations of the target user in each sub-unit time period, when it is determined that the number of operations of the target user in the adjacent N sub-unit time periods in each unit time period has regularity, the target user is determined to be an abnormal user. In this way, by counting the number of operations in the user operation log, the regularity of the user's operation behavior can be accurately determined, and the situation where the log analysis efficiency is low due to processing a large amount of log content can be avoided.
[0063] Based on the above embodiment, when it is determined that the number of operations of the target user in N adjacent sub-unit time periods in each unit time period is regular, the method may further include the following steps:
[0064] In step S640, it is determined whether there is regularity in the number of operations of the target user in the target sub-unit time period in the target unit time period;
[0065] In step S650 , when there is regularity in the number of operations performed by the target user in the target sub-unit time period in the target unit time period, the target user is determined to be an abnormal user.
[0066] In the embodiment, when it is determined that the number of operations of the target user in N adjacent sub-unit time periods in each unit time period is regular, in order to more accurately determine whether the target user is an abnormal user, it is possible to further determine whether there is regularity in the number of operations of the target user in a target sub-unit time period in a target unit time period. If there is regularity in the number of operations of the target user in a target sub-unit time period in the target unit time period, it can be determined that the target user is an abnormal user, which can improve the accuracy of abnormal user judgment.
[0067] Specifically, in the embodiment, the number of operations of the target user in the target sub-unit time period in the target unit time period can be obtained, and a target matrix is generated based on the number of operations in the target sub-unit time period. The rows of the target matrix represent the number of operations of the target user per minute, and the columns of the target matrix represent the number of operations of the target user per second. The target matrix is divided into multiple sub-regions, and the similarity between the multiple sub-regions is calculated. When it is determined based on the similarity that there is a sub-region with a similarity greater than a third threshold value among the multiple sub-regions, it is determined that there is regularity in the number of operations of the target user in the target sub-unit time period.
[0068] In the embodiment, the target sub-unit time period may be 1 day, or several hours, or 1 hour, etc., and may be set as required, and the embodiment is not limited thereto.
[0069] By obtaining the number of operations of the target user in the target unit time period, the number of operations can be converted into a target matrix. For example, if the target unit sub-time period can be 1 day, the number of operations of the user per minute and second in the 24 hours of the day can be obtained, and by generating a target matrix corresponding to the number of user operations within the 24 hours, the positions containing user operations in the target matrix can be set to a certain value, such as 1, and the positions that do not contain the number of user operations in the target matrix can be set to empty or 0, and the target matrix can be divided into multiple sub-areas. By determining the similarity of the corresponding graphics between the sub-areas, such as by translating or moving up and down, whether the similarity between the sub-areas is greater than the third threshold value, the target matrix can be combined with the target matrix to obtain the number of operations of the target user. Figure 5 As shown, if there is, it can be determined that there is regularity in the number of operations of the target user within the target sub-unit time period.
[0070] In an embodiment, it is specifically possible to detect whether there are empty sub-regions that do not contain the number of operations in multiple sub-regions. If there are empty sub-regions that do not contain the number of operations in multiple sub-regions, the empty sub-regions are removed from the multiple sub-regions, and the interference caused by the empty sub-regions is avoided by comparing the similarities between the non-empty sub-regions. This can improve the detection efficiency of whether there is regularity in the number of operations of the target user within the target sub-unit time period.
[0071] In the case of dividing each functional module according to each function, an embodiment of the present disclosure provides a log auditing device, which may be a server, a terminal, or a chip applied to a server. Figure 7 A schematic block diagram of the functional modules of a log audit device provided by an exemplary embodiment of the present disclosure. Figure 7 As shown, the log audit device includes:
[0072] The log acquisition module 10 is used to acquire the operation log of the target user, wherein the operation log includes the number of operations of the target user in a target time period, wherein the target time period includes a plurality of unit time periods, and each unit time period includes a plurality of sub-unit time periods;
[0073] The operation number counting module 20 is used to count the operation number of the target user in each sub-unit time period based on the operation number of the target user in each unit time period, if it is determined that the operation number of the target user in the M adjacent unit time periods in the target time period has regularity;
[0074] The abnormal user determination module 30 is used to determine that the target user is an abnormal user based on the number of operations of the target user in each sub-unit time period, when it is determined that the number of operations of the target user in N adjacent sub-unit time periods in each unit time period is regular; wherein M and N are both positive integers.
[0075] In another embodiment provided by the present disclosure, the device further includes:
[0076] A first graphic conversion module, used for counting the number of operations of the target user in each unit time period, and converting the number of operations of the target user in each unit time period into a target graphic;
[0077] The second regularity determination module is used to obtain the similarity between the target graphics in M adjacent unit time periods, and when the similarity is greater than a first threshold, determine that the number of operations of the target user in the M adjacent unit time periods in the target time period has regularity.
[0078] In another embodiment provided by the present disclosure, the device further includes:
[0079] A second graphic conversion module is used to count the number of operations of the target user in each sub-unit time period of the target unit time period, and convert the number of operations in each sub-unit time period into a target graphic;
[0080] A second regularity determination module is configured to obtain the similarity between the target graphics in the adjacent N sub-unit time periods, and determine that the number of operations of the target user in the adjacent N sub-unit time periods in the target unit time period is regular if the similarity is greater than a second threshold value;
[0081] The third regularity determination module determines that the number of operations of the target user in N adjacent sub-unit time periods in each unit time period has regularity when the proportion of the target time period is greater than a preset proportion.
[0082] In another embodiment provided by the present disclosure, when it is determined that the number of operations of the target user in N adjacent sub-unit time periods in each unit time period has regularity, the device further includes:
[0083] A regularity determination module, used to determine whether there is regularity in the number of operations performed by the target user within a target sub-unit time period in the target unit time period;
[0084] The abnormal user determination module is further configured to determine that the target user is an abnormal user when there is regularity in the number of operations performed by the target user within a target sub-unit time period in the target unit time period.
[0085] In yet another embodiment provided by the present disclosure, the apparatus further includes a fourth regularity determination module, specifically configured to:
[0086] Obtaining the number of operations performed by the target user in the target unit time period;
[0087] Generate a target matrix based on the number of operations within the target sub-unit time period, wherein the rows of the target matrix represent the number of operations per minute of the target user, and the columns of the target matrix represent the number of operations per second of the target user;
[0088] Dividing the target matrix into multiple sub-regions, and calculating the similarity between the multiple sub-regions;
[0089] When it is determined based on the similarity that there is a sub-region among the multiple sub-regions whose similarity is greater than a third threshold, it is determined that there is regularity in the number of operations of the target user within the target sub-unit time period.
[0090] In another embodiment provided by the present disclosure, the device further includes a sub-region processing module, which is specifically configured to:
[0091] Detecting whether there is an empty sub-region that does not contain the number of operations among the multiple sub-regions;
[0092] There is an empty sub-region that does not contain the number of operations in the multiple sub-regions, and the empty sub-region is removed from the multiple sub-regions.
[0093] For the device part, please refer to the description of the method embodiment and will not be repeated here.
[0094] The log auditing device provided by the embodiment of the present disclosure obtains the operation log of the target user, and based on the number of operations of the target user in each unit time period, when it is determined that the number of operations of the target user in the adjacent M unit time periods in the target time period has regularity, counts the number of operations of the target user in each sub-unit time period. Based on the number of operations of the target user in each sub-unit time period, when it is determined that the number of operations of the target user in the adjacent N sub-unit time periods in each unit time period has regularity, the target user is determined to be an abnormal user.
[0095] An embodiment of the present disclosure also provides an electronic device, comprising: at least one processor; and a memory for storing instructions executable by the at least one processor; wherein the at least one processor is configured to execute the instructions to implement the above method disclosed in the embodiment of the present disclosure.
[0096] Figure 8 The structure diagram of an electronic device provided by an exemplary embodiment of the present disclosure is shown in FIG. Figure 8As shown, the electronic device 1800 includes at least one processor 1801 and a memory 1802 coupled to the processor 1801 , and the processor 1801 can execute corresponding steps in the above method disclosed in the embodiment of the present disclosure.
[0097] The processor 1801 may also be referred to as a central processing unit (CPU), which may be an integrated circuit chip having signal processing capabilities. Each step in the method disclosed in the embodiment of the present disclosure may be completed by an integrated logic circuit of hardware in the processor 1801 or by instructions in the form of software. The processor 1801 may be a general-purpose processor, a digital signal processor (DSP), an ASIC (Application Specific Integrated Circuit), a field-programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. A general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc. The steps of the method disclosed in the embodiment of the present disclosure may be directly embodied as being executed by a hardware decoding processor, or may be executed by a combination of hardware and software modules in a decoding processor. The software module may be located in a memory 1802, such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, or other mature storage media in the art. The processor 1801 reads the information in the memory 1802 and completes the steps of the method in combination with its hardware.
[0098] In addition, when various operations / processes according to the present disclosure are implemented by software and / or firmware, they can be transmitted from a storage medium or a network to a computer system having a dedicated hardware structure, such as Fig. 9 The computer system 1900 shown is installed with the programs constituting the software. When the various programs are installed, the computer system can perform various functions, including the functions described above. Fig. 9 A structural block diagram of a computer system provided for an exemplary embodiment of the present disclosure.
[0099] Computer system 1900 is intended to represent various forms of digital electronic computer devices, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. Electronic devices can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or claimed herein.
[0100] like Fig. 9 As shown, the computer system 1900 includes a computing unit 1901, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 1902 or a computer program loaded from a storage unit 1908 to a random access memory (RAM) 1903. In the RAM 1903, various programs and data required for the operation of the computer system 1900 can also be stored. The computing unit 1901, the ROM 1902, and the RAM 1903 are connected to each other via a bus 1904. An input / output (I / O) interface 1905 is also connected to the bus 1904.
[0101] A plurality of components in the computer system 1900 are connected to the I / O interface 1905, including: an input unit 1906, an output unit 1907, a storage unit 1908, and a communication unit 1909. The input unit 1906 may be any type of device capable of inputting information to the computer system 1900, and the input unit 1906 may receive input digital or character information, and generate key signal inputs related to user settings and / or function control of the electronic device. The output unit 1907 may be any type of device capable of presenting information, and may include, but is not limited to, a display, a speaker, a video / audio output terminal, a vibrator, and / or a printer. The storage unit 1908 may include, but is not limited to, a disk, an optical disk. The communication unit 1909 allows the computer system 1900 to exchange information / data with other devices over a network such as the Internet, and may include, but is not limited to, a modem, a network card, an infrared communication device, a wireless communication transceiver, and / or a chipset, such as a Bluetooth™ device, a WiFi device, a WiMax device, a cellular communication device, and / or the like.
[0102] The computing unit 1901 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the computing unit 1901 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, digital signal processors (DSPs), and any appropriate processors, controllers, microcontrollers, etc. The computing unit 1901 performs the various methods and processes described above. For example, in some embodiments, the above methods disclosed in the embodiments of the present disclosure may be implemented as a computer software program, which is tangibly included in a machine-readable medium, such as a storage unit 1908. In some embodiments, part or all of the computer program may be loaded and / or installed on an electronic device via ROM 1902 and / or communication unit 1909. In some embodiments, the computing unit 1901 may be configured to perform the above methods disclosed in the embodiments of the present disclosure in any other appropriate manner (e.g., by means of firmware).
[0103] The embodiment of the present disclosure further provides a computer-readable storage medium, wherein when instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the above method disclosed in the embodiment of the present disclosure.
[0104] The computer-readable storage medium in the disclosed embodiments may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. The computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or equipment, or any suitable combination of the foregoing. More specifically, the computer-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0105] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.
[0106] The embodiments of the present disclosure further provide a computer program product, including a computer program, wherein when the computer program is executed by a processor, the above method disclosed in the embodiments of the present disclosure is implemented.
[0107] In embodiments of the present disclosure, computer program codes for performing the operations of the present disclosure may be written in one or more programming languages or combinations thereof, including but not limited to object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" language or similar programming languages. The program code may be executed entirely on a user's computer, partially on a user's computer, as an independent software package, partially on a user's computer, partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer.
[0108] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0109] The modules, components or units involved in the embodiments described in the present disclosure may be implemented by software or hardware, wherein the names of the modules, components or units do not, in some cases, limit the modules, components or units themselves.
[0110] The functions described above herein may be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chip (SOCs), complex programmable logic devices (CPLDs), and the like.
[0111] The above descriptions are only some embodiments of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above disclosed concept. For example, a technical solution formed by replacing the above features with the technical features with similar functions disclosed in the present disclosure (but not limited to).
[0112] Although some specific embodiments of the present disclosure have been described in detail by way of example, it should be understood by those skilled in the art that the above examples are for illustration only and are not intended to limit the scope of the present disclosure. It should be understood by those skilled in the art that the above embodiments may be modified without departing from the scope and spirit of the present disclosure. The scope of the present disclosure is defined by the appended claims.
Claims
1. A log audit method, characterized in that: The method comprises: Acquire an operation log of a target user, wherein the operation log includes the number of operations of the target user within a target time period, wherein the target time period includes a plurality of unit time periods, and each unit time period includes a plurality of sub-unit time periods; Based on the number of operations of the target user in each unit time period, when it is determined that the number of operations of the target user in M adjacent unit time periods in the target time period is regular, counting the number of operations of the target user in each sub-unit time period; Based on the number of operations of the target user in each sub-unit time period, when it is determined that the number of operations of the target user in N adjacent sub-unit time periods in each unit time period is regular, the target user is determined to be an abnormal user; wherein M and N are both positive integers.
2. The method according to claim 1, characterized in that: The method further comprises: Counting the number of operations performed by the target user in each unit time period, and converting the number of operations performed by the target user in each unit time period into a target graph; The similarity between the target graphics in the adjacent M unit time periods is obtained, and when the similarity is greater than a first threshold, it is determined that the number of operations of the target user in the adjacent M unit time periods in the target time period has regularity.
3. The method according to claim 1, characterized in that The method further comprises: Counting the number of operations performed by the target user in each sub-unit time period of the target unit time period, and converting the number of operations in each sub-unit time period into a target graph; Acquire the similarity between the target graphics in the adjacent N sub-unit time periods, and if the similarity is greater than a second threshold, determine that the number of operations of the target user in the adjacent N sub-unit time periods in the target unit time period has regularity; When the proportion of the target time period is greater than a preset proportion, it is determined that the number of operations of the target user in N adjacent sub-unit time periods in each unit time period has regularity.
4. The method according to claim 3, characterized in that In the case where it is determined that the number of operations of the target user in N adjacent sub-unit time periods in each unit time period is regular, the method further includes: Determine whether there is regularity in the number of operations of the target user within the target sub-unit time period in the target unit time period; When there is regularity in the number of operations performed by the target user within the target sub-unit time period in the target unit time period, the target user is determined to be an abnormal user.
5. The method according to claim 4, characterized in that The method further comprises: Obtaining the number of operations performed by the target user in the target unit time period; Generate a target matrix based on the number of operations within the target sub-unit time period, wherein the rows of the target matrix represent the number of operations per minute of the target user, and the columns of the target matrix represent the number of operations per second of the target user; Dividing the target matrix into multiple sub-regions, and calculating the similarity between the multiple sub-regions; When it is determined based on the similarity that there is a sub-region among the multiple sub-regions whose similarity is greater than a third threshold, it is determined that there is regularity in the number of operations of the target user within the target sub-unit time period.
6. The method according to claim 5, characterized in that The method further comprises: Detecting whether there is an empty sub-region that does not contain the number of operations among the multiple sub-regions; There is an empty sub-region that does not contain the number of operations in the multiple sub-regions, and the empty sub-region is removed from the multiple sub-regions.
7. A log auditing device, characterized in that: The device comprises: A log acquisition module, used to acquire an operation log of a target user, wherein the operation log includes the number of operations of the target user within a target time period, wherein the target time period includes a plurality of unit time periods, and each unit time period includes a plurality of sub-unit time periods; An operation count counting module, for counting the operation count of the target user in each sub-unit time period based on the operation count of the target user in each unit time period, when it is determined that the operation count of the target user in M adjacent unit time periods in the target time period has regularity; An abnormal user determination module is used to determine that the target user is an abnormal user based on the number of operations of the target user in each sub-unit time period, when it is determined that the number of operations of the target user in N adjacent sub-unit time periods in each unit time period is regular; wherein M and N are both positive integers.
8. An electronic device, characterized in that: include: at least one processor; a memory for storing the at least one processor-executable instruction; The at least one processor is configured to execute the instructions to implement the method according to any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that: When the instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is enabled to perform the method as claimed in any one of claims 1 to 6.
10. A computer program product, characterized in that The method comprises a computer program, which implements the method according to any one of claims 1 to 6 when being executed by a processor.
Citation Information
Patent Citations
Computer server cluster log monitoring method and monitoring platform
CN107943668A
Risk detection method and device
CN111818066A
Abnormal behavior detection method and device and electronic device
CN112491779A
Log data auditing system, method, equipment and medium
CN115408236A
Auditing Tool For a Legacy Software Modernization System
US20090164492A1
