Abnormal request detection method and device, computer equipment and storage medium
By constructing frequent feature item sets and calculating anomaly degrees, and identifying abnormal requests, the problem of low abnormal request detection coverage and accuracy in the existing technology is solved, and the effect of content promotion is improved.
Patent Information
- Application Number
- CN202310340839.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-31
- Publication Date
- 2024-10-01
AI Technical Summary
Existing abnormal request detection methods have low coverage and accuracy during the content promotion process, making it difficult to effectively identify cheating requests and affecting the effectiveness of advertising promotion.
By obtaining the log record data of object requests, extracting feature data items, constructing frequent feature item sets, calculating the abnormality degree based on historical abnormal data, and determining it as an abnormal request when the abnormality degree reaches the threshold.
It improves the coverage and accuracy of abnormal request detection, can effectively identify and exclude cheating requests, and ensure the effectiveness of content promotion.
Smart Images

Figure CN118740662A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to an abnormal request detection method, apparatus, computer equipment, storage medium and computer program product. Background Art
[0002] With the development of computer technology and network technology, network-based content promotion technology has emerged. However, in the process of content promotion, there are cases of traffic fraud through abnormal requests, which affects the effect of content promotion. For example, in advertising promotion, cheaters can use automated scripts or software to control dozens or even hundreds of mobile phones through one or more computers to control abnormal users to click on advertisements. Therefore, detecting abnormal cheating requests during content promotion can effectively ensure the effect of content promotion.
[0003] However, current abnormal request detection methods generally use result-oriented indicators such as click-through rate to make judgments. Generally, the worse the conversion rate of content promotion, the higher the possibility of abnormal requests. However, this abnormal request detection method can only mine users with extremely abnormal click volume, and the detection coverage and accuracy are low. Summary of the invention
[0004] Based on this, it is necessary to provide an abnormal request detection method, device, computer equipment, computer-readable storage medium and computer program product that can effectively improve the coverage and accuracy of abnormal request detection in response to the above technical problems.
[0005] In a first aspect, the present application provides a method for detecting abnormal requests. The method comprises:
[0006] Gets the logging data for recording object requests;
[0007] Based on the characteristic data items of each object request in the log record data, determining a characteristic data item set matching the traffic carrier recorded in the log record data;
[0008] Performing association analysis on the association relationships between the feature data items in the feature data item set to construct a frequent feature item set;
[0009] Based on the historical abnormal object data, determining the abnormality of the frequent feature item set, wherein the abnormality is determined according to the proportion of abnormal objects in the objects corresponding to the frequent feature item set, and the abnormal objects in the objects are determined based on the historical abnormal object data;
[0010] When the abnormality degree of the frequent feature item set is greater than or equal to the abnormality degree threshold, the object request whose feature data items conform to the frequent feature item set is determined as an abnormal request.
[0011] In a second aspect, the present application also provides an abnormal request detection device. The device comprises:
[0012] A log acquisition module, used to acquire log record data for recording object requests;
[0013] A feature identification module, configured to determine a feature data item set matching a traffic carrier recorded in the log record data based on feature data items of each object request in the log record data;
[0014] A frequent item set construction module, used to perform association analysis on the association relationship between the feature data items in the feature data item set to construct a frequent feature item set;
[0015] An abnormality identification module, used to determine the abnormality of the frequent feature item set based on historical abnormal object data, wherein the abnormality is determined according to the proportion of abnormal objects in the objects corresponding to the frequent feature item set, and the abnormal objects in the objects are determined based on the historical abnormal object data;
[0016] The abnormal request detection module is used to determine an object request whose feature data items conform to the frequent feature item set as an abnormal request when the abnormality of the frequent feature item set is greater than or equal to an abnormality threshold.
[0017] In a third aspect, the present application further provides a computer device. The computer device includes a memory and a processor, the memory stores a computer program, and the processor implements the following steps when executing the computer program:
[0018] Gets the logging data for recording object requests;
[0019] Based on the characteristic data items of each object request in the log record data, determining a characteristic data item set matching the traffic carrier recorded in the log record data;
[0020] Performing association analysis on the association relationships between the feature data items in the feature data item set to construct a frequent feature item set;
[0021] Based on the historical abnormal object data, determining the abnormality of the frequent feature item set, wherein the abnormality is determined according to the proportion of abnormal objects in the objects corresponding to the frequent feature item set, and the abnormal objects in the objects are determined based on the historical abnormal object data;
[0022] When the abnormality degree of the frequent feature item set is greater than or equal to the abnormality threshold, the object request whose feature data items conform to the frequent feature item set is determined as an abnormal request.
[0023] In a fourth aspect, the present application further provides a computer-readable storage medium. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the following steps are implemented:
[0024] Gets the logging data for recording object requests;
[0025] Based on the characteristic data items of each object request in the log record data, determining a characteristic data item set matching the traffic carrier recorded in the log record data;
[0026] Performing association analysis on the association relationships between the feature data items in the feature data item set to construct a frequent feature item set;
[0027] Based on the historical abnormal object data, determining the abnormality of the frequent feature item set, wherein the abnormality is determined according to the proportion of abnormal objects in the objects corresponding to the frequent feature item set, and the abnormal objects in the objects are determined based on the historical abnormal object data;
[0028] When the abnormality of the frequent feature item set is greater than or equal to the abnormality threshold, the object request whose feature data item conforms to the frequent feature item set is determined as an abnormal request.
[0029] In a fifth aspect, the present application further provides a computer program product. The computer program product includes a computer program, and when the computer program is executed by a processor, the following steps are implemented:
[0030] Gets the logging data for recording object requests;
[0031] Based on the characteristic data items of each object request in the log record data, determine a characteristic data item set matching the traffic carrier recorded in the log record data;
[0032] Performing association analysis on the association relationships between the feature data items in the feature data item set to construct a frequent feature item set;
[0033] Based on the historical abnormal object data, determining the abnormality of the frequent feature item set, wherein the abnormality is determined according to the proportion of abnormal objects in the objects corresponding to the frequent feature item set, and the abnormal objects in the objects are determined based on the historical abnormal object data;
[0034] When the abnormality of the frequent feature item set is greater than or equal to the abnormality threshold, the object request whose feature data item conforms to the frequent feature item set is determined as an abnormal request.
[0035] The above-mentioned abnormal request detection method, device, computer equipment, storage medium and computer program product, after obtaining log record data for recording object requests; first determine the feature data item set that matches the traffic carrier recorded in the log record data based on the feature data items of each object request in the log record data; that is, first extract the features possessed by different object requests from the log record data of the object request, so as to determine the feature data item set of the traffic carrier, and then perform association analysis on the association relationship between the feature data items in the feature data item set to construct a frequent feature item set, and determine the frequent feature item set of features that frequently co-occur in object requests under the traffic carrier through association analysis, and then determine the abnormality of the frequent feature item set based on historical abnormal object data; that is, obtain the abnormality by comparing the object of the object request with the abnormal object in the historical data, so as to judge whether the object with the frequent feature item set is abnormal, and when the abnormality of the frequent feature item set is greater than or equal to the abnormality threshold, it means that the object that meets the frequent feature item set is an abnormal object, and its corresponding object request is determined as an abnormal request. In this application, frequent feature item sets of object requests are automatically discovered by generating frequent items that match traffic carriers, and the co-occurring frequent feature item sets are scored for abnormality, so as to identify the frequent feature item sets of abnormal requests, thereby effectively improving the coverage and accuracy of abnormal request detection. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] Figure 1 An application environment diagram of an abnormal request detection method in an embodiment;
[0037] Figure 2 A flowchart of an abnormal request detection method in one embodiment;
[0038] Figure 3 A schematic diagram of the relationship between an object and a traffic carrier in an embodiment;
[0039] Figure 4 is a schematic diagram of a characteristic data summary table in one embodiment;
[0040] Figure 5 is a schematic diagram of a feature data item set in one embodiment;
[0041] Figure 6 A schematic diagram of a process for generating frequent feature item sets in one embodiment;
[0042] Figure 7 A schematic diagram of the relationship between a publishing platform and a traffic carrier in an embodiment;
[0043] Figure 8 A schematic diagram of content published by a traffic carrier in one embodiment;
[0044] Fig. 9The following is a schematic diagram of the overall process of an abnormal request detection method in an embodiment;
[0045] Fig.10 is a flow chart of an abnormal request detection method in another embodiment;
[0046] Fig.11 is a structural block diagram of an abnormal request detection device in an embodiment;
[0047] Fig.12 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0048] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0049] It should be noted that the user information (including but not limited to user device information, user personal information, user IP address information, user application scenario information, user-related log data, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data need to comply with relevant laws, regulations and standards of relevant countries and regions.
[0050] In this article, it is important to understand that the terms involved are:
[0051] Real-time computing: Real-time computing is a continuous, low-latency, event-triggered computing mode. The data faced by real-time computing is real-time and streaming. These data are subscribed and consumed by real-time computing in chronological order, and the results are generally required to be returned within seconds.
[0052] Flink: Flink is a distributed real-time computing framework that supports high-throughput, low-latency, and high-performance real-time computing. It is used to perform stateful computing on real-time and streaming data streams. Flink can run in all common cluster environments and can perform calculations at memory speed and at any scale.
[0053] The abnormal request detection method provided in the embodiment of the present application can be applied to Figure 1In the application environment shown. Among them, the terminal 102 communicates with the access layer server 104 through the network. When the user exposes or clicks the specified content through the terminal, the terminal will generate a corresponding object request according to the current time, object number, scene, terminal address, traffic carrier number and other information, and submit it to the access layer server 104, and the access layer is connected to the request database 106 and the real-time computing server 108 respectively. When the access layer server 104 receives the request, it first stores the log record data of the object request in the request database, and then requests the real-time computing server 108 to determine whether the user request is an abnormal request. At the same time, the real-time computing server 108 extracts the log record data including the user's object request within a period of time from the request database, and calculates whether the user and other users under the traffic carrier have frequent co-occurrence features as an abnormal user, and returns the detection result at the same time. Specifically, the real-time computing server 108 first obtains the log record data for recording the object request; based on the feature data items of each object request in the log record data, determines the feature data item set that matches the traffic carrier recorded in the log record data; performs association analysis on the association relationship between the feature data items in the feature data item set to construct a frequent feature item set; based on the historical abnormal object data, determines the abnormality of the frequent feature item set; when the abnormality of the frequent feature item set is greater than or equal to the abnormality threshold, the object request whose feature data item meets the frequent feature item set is determined as an abnormal request. The request database 106 can store the data that the real-time computing server 108 needs to process. The request database 106 can be integrated on the access layer server 104 or the real-time computing server 108, or it can be placed on the cloud or other servers. Among them, the terminal 102 can be, but is not limited to, various desktop computers, laptops, smart phones, tablet computers, Internet of Things devices and portable wearable devices. The Internet of Things devices can be smart speakers, smart TVs, smart air conditioners, smart car-mounted devices, etc. Portable wearable devices can be smart watches, smart bracelets, head-mounted devices, etc. The access layer server 104 or the real-time computing server 108 may be implemented as an independent server or a server cluster consisting of multiple servers.
[0054] In one embodiment, Figure 2 As shown, a method for detecting abnormal requests is provided, and the method is applied to Figure 1 Taking the real-time computing server 108 in the example as an example, the following steps are included:
[0055] Step 201: Obtain log record data for recording object requests.
[0056] Among them, the object request refers to a request submitted by the terminal 102 to the access layer server 104 to request the access layer server 104 to provide corresponding content or services. For example, in one embodiment, the solution of the present application is applied to the field of advertising anti-cheating. At this time, the object request can specifically be a request to click on an advertisement, or a request to expose an advertisement. The log record data is the corresponding log data generated based on the content requested by the object request and the information carried by the request. The characteristics of the object request can be effectively extracted through the log record data of the object request. The traffic carrier is the traffic master, and the traffic master is the carrier that provides user traffic, usually referring to media, websites or software. For example, on a content platform, the traffic master refers to a public account with a certain number of fans. As for advertising cheating, in the links of advertising exposure, clicks, effects, etc., users have the behavior of brushing advertising exposure, clicks, and effects for some malicious purposes. This malicious behavior that is not the real intention of the user is called advertising cheating. Advertising anti-cheating refers to checking the links of advertising exposure, clicks, effects, etc. to determine whether the advertising exposure, clicks, effects, etc. are normal. In one of the embodiments, the log record data of the object request specifically records the request time, object number, scene, terminal address and traffic carrier number.
[0057] Specifically, the scheme of the present application specifically identifies abnormal requests from object requests submitted by users. When users submit exposure requests or click requests, since these exposure requests or click requests may be requests submitted by automated script manipulation, it is necessary to identify them. For example, in the field of platform advertising, users can use automated scripts or software to control dozens or even hundreds of mobile phones through one or more computers, and control abnormal users to initiate requests to click on advertisements, thereby affecting the publishing effect of advertisements. This is an abnormal request. When the user terminal 102 initiates an object request to the access layer server 104, the access layer server 104 will directly generate log record data of the object request based on the relevant information of the object request, and save the generated log record data to the request database 106, and at the same time request the real-time computing server 108 to perform cheating detection related to the request, and the real-time computing server 108 can directly obtain the log record data of the object request from the request database 106 based on the detection request after the access layer server 104 submits the detection request. The log record data of the object request here can be all object requests within a period of time, including not only the object request requested to be detected by the access layer server 104, but also other requests within the same time period. In another embodiment, the present application is applicable to performing anomaly detection on all object requests within a time period, and in this case, the detection request is a request to detect object requests within a target time period.
[0058] Step 203: Based on the characteristic data items of each object request in the log record data, determine a characteristic data item set that matches the traffic carrier recorded in the log record data.
[0059] Among them, the feature data item set is an item set (ltemset), which refers to a feature set data constructed for the features possessed by each traffic carrier. The item set is a concept of a set. In a basket of goods, a consumer product is an item, and a collection of several items is called an item set. For example, {beer, biscuits} constitutes a binary item set, and the feature data item set is a collection of multiple features. Traffic carriers are also called traffic hosts, which refer to carriers that provide user traffic, usually media, websites or software.
[0060] Specifically, the log record data records the characteristic data items of different object requests. There are the same characteristics and different characteristics between different requests. At the same time, the information of the traffic corresponding to the object request is also recorded. Therefore, the real-time computing server 108 can also determine the traffic carrier of the object request. The work of determining the traffic carrier of the object request can be determined by parsing the log record data. The log record data of the object request contains the traffic carrier number of the object request. Therefore, the characteristic data item set matching the traffic carrier recorded in the log record data can be determined by parsing the log record data. At the same time, for different traffic carriers, the corresponding characteristic data items of each traffic carrier can be determined based on the characteristics they have. The object request can be effectively classified by identifying the characteristic data items, and then the characteristic items of each traffic carrier can be identified, so as to obtain the co-occurrence features that exist frequently. In one embodiment, the features in the characteristic data items include request terminal features and click operation features. Therefore, when constructing the characteristic items, the characteristic items corresponding to each carrier can be constructed based on the combination of the request terminal features and click operation features under each traffic carrier.
[0061] Step 205: Perform association analysis on the association relationships between the feature data items in the feature data item set to construct a frequent feature item set.
[0062] Among them, association analysis, also known as association mining, is to find frequent patterns, associations, correlations or causal structures between sets of items or sets of objects in transaction data, relational data or other information carriers. In this application, the association analysis is mainly performed on the association relationships between feature data items in the feature data item set to determine the feature data item set that frequently appears in the feature item, thereby constructing the frequent item features. As for the constructed frequent feature item set, it refers to the item set, sequence or substructure that frequently appears in the data set. It also refers to a set whose support is greater than or equal to the minimum support (min_sup). Among them, support refers to the frequency of a certain set appearing in all transactions.
[0063] Specifically, after obtaining the feature items corresponding to each traffic carrier, the correlation analysis between different features in the feature items can be performed based on the feature items, so as to obtain the frequently appearing item sets, sequences or substructures in the feature data item set through correlation analysis, and construct the frequent feature item set. The correlation analysis in this application can be implemented specifically through the association rule (Apriori) algorithm or the FP-growth algorithm.
[0064] Step 207, based on the historical abnormal object data, determine the abnormality of the frequent feature item set, the abnormality is determined according to the proportion of abnormal objects in the objects corresponding to the frequent feature item set, and the abnormal objects in the objects are determined based on the historical abnormal object data.
[0065] Among them, historical abnormal object data refers to objects with abnormal conditions in historical data. Historical abnormal objects can be identified through abnormal request detection in history, or they can be identified through other abnormal detection methods, such as objects with forged click data and forged exposure data identified through detection platform data. The abnormality degree is used to characterize the proportion of abnormal objects in frequent feature item sets. The higher the abnormality degree, the higher the proportion of identified abnormal objects with the frequent feature item set to the total number of objects, which means that the object with the frequent feature item set is more likely to be an abnormal object.
[0066] Specifically, the applicant found that in the field of content push, there are behavioral differences between normal objects and abnormal objects. Since normal objects only click on the pushed content that they are interested in, the normal objects’ clicks on pushed content often have the following characteristics: the time when normal objects click on pushed content is relatively scattered. Since the pushed content will appear randomly, and the object only clicks on the pushed content that it is interested in, the time interval between the object’s clicks on pushed content is relatively scattered, and will not show regularity or periodicity. The IP, device, operating system and other characteristics of normal objects’ clicks on pushed content are relatively scattered. Since each object sees the pushed content of interest randomly, the timing of clicking on the pushed content is also random. The IP, device, operating system and other characteristics of normal objects’ clicks on pushed content are relatively scattered and will not show aggregation. The traffic carriers clicked by normal objects are relatively scattered. Since the pushed content seen by each object under each traffic carrier appears randomly, the object’s clicks will not be concentrated on certain traffic carriers. The pushed content clicked by normal objects is relatively scattered. Normal objects will only click on the pushed content that they are interested in, so they will not click on all the pushed content that has been exposed. The clicked pushed content is relatively scattered, so there will be no collaborative or gang-like click behavior between normal objects. Unlike normal objects, abnormal objects often click a large number of times or concentrate on certain traffic carriers to click on pushed content due to profit-driven reasons, so that the same features will appear between abnormal objects. For example, the traffic carriers clicked by two abnormal objects are the same, the time periods of clicks are the same, the IP addresses of clicks are the same, and the time spent on the pushed content page after clicking is extremely short or fixed at a certain time interval, etc., that is, there will be frequent co-occurrence features between abnormal objects. Therefore, by performing association analysis on the association relationship between feature data items in the feature data item set, a frequent feature item set can be constructed, and then based on the abnormality of the constructed frequent feature item set, it can be determined whether the object is abnormal and whether the object request issued by the object is abnormal. In one embodiment, the proportion of abnormal objects in the frequent feature item set to the total request objects can be determined based on historical abnormal object data, so as to obtain the abnormality of each frequent feature item set.
[0067] Step 209: When the abnormality of the frequent feature item set is greater than or equal to the abnormality threshold, the object request whose feature data item meets the frequent feature item set is determined as an abnormal request.
[0068] Specifically, the abnormality is used to characterize the abnormal object ratio data in the frequent feature item set. The higher the abnormality, the higher the number of identified abnormal objects with the frequent feature item set in the total number of objects, which means that the object with the frequent feature item set is more likely to be an abnormal object. When the abnormality of the frequent feature item set is greater than or equal to the abnormality threshold, the object request whose feature data item meets the frequent feature item set can be determined as an abnormal request. In one embodiment, the abnormality threshold can be set according to the requirements of abnormality detection accuracy. The higher the accuracy requirement, the larger the abnormality threshold. In one embodiment, it is identified that there is only one frequent feature item set with an abnormality greater than or equal to the abnormality threshold. At this time, the object request that meets the frequent feature item set can be determined as an abnormal request. In another embodiment, it is identified that there are multiple frequent feature item sets with an abnormality greater than or equal to the abnormality threshold. At this time, the abnormal request can be identified in the object request set based on each frequent feature item set, and the abnormal request corresponding to each frequent feature item set is obtained. Then, these abnormal requests found are processed by seeking the union to obtain all the abnormal requests in the end.
[0069] The above-mentioned abnormal request detection method, after obtaining the log record data for recording the object request; first determine the feature data item set that matches the traffic carrier recorded in the log record data based on the feature data items of each object request in the log record data; that is, first extract the features of different object requests from the log record data of the object request, so as to determine the feature data item set of the traffic carrier, and then perform association analysis on the association relationship between the feature data items in the feature data item set to construct a frequent feature item set, and determine the frequent feature item set of features that frequently co-occur in the object request under the traffic carrier through association analysis, and then determine the abnormality of the frequent feature item set based on the historical abnormal object data; that is, by comparing the object of the object request with the abnormal object in the historical data to obtain the abnormality, so as to judge whether the object with the frequent feature item set is abnormal, when the abnormality of the frequent feature item set is greater than or equal to the abnormality threshold, it means that the object that meets the frequent feature item set is an abnormal object, and its corresponding object request is determined to be an abnormal request. In this application, frequent feature item sets of object requests are automatically discovered by generating frequent items that match traffic carriers, and the co-occurring frequent feature item sets are scored for abnormality, so as to identify the frequent feature item sets of abnormal requests, thereby effectively improving the coverage and accuracy of abnormal request detection.
[0070] In one embodiment, step 201 includes: obtaining a detection request for a target object request; searching for request log data of the target object request based on the detection request; identifying the traffic carrier number carried in the target object request through the request log data; searching for at least one request log data representing the traffic carrier number; and summarizing the request log data obtained by the search to obtain log record data of the object request.
[0071] Among them, the target object request refers to the request submitted in real time, and the present application can directly perform anomaly detection on the request submitted in real time to determine whether the target object request is an abnormal request. The detection request carries relevant information of the target object request, so the request log data of the target object request can be found through the target object request information carried in the detection request. The request log data refers to the log data corresponding to the target object request, which carries information such as request time, object number, scene, terminal address, and traffic carrier number.
[0072] Specifically, Figure 2As shown, the scheme of the present application can be applied to abnormal detection of real-time target object requests. When the object initiates an object request in real time through the terminal 102 and submits it to the access layer server 104, the real-time initiated request can be regarded as a target object request. The relevant data of the target object request will be saved in the request database 106, and the access layer server 104 will initiate a detection request to the real-time computing server based on the target object request. The real-time computing server 108 receives the detection request for the target object request submitted by the access layer server 104, and then searches the request log data of the target object request from the request database 106 based on the request information carried in the detection request, and then identifies the traffic carrier number carried in the target object request through the request log data, that is, determines the carrier corresponding to the target object request. Then, based on the traffic carrier number, an associated search is performed in the request database 106 to find at least one request log data whose traffic carrier number represents the traffic carrier; finally, the request log data obtained by the search are summarized to obtain the log record data of the object request. Thus, real-time abnormal request detection is performed through the log record data of the object request. In one of the embodiments, the real-time computing of this embodiment can be specifically implemented based on Flink. Flink is a distributed real-time computing framework that supports high-throughput, low-latency, and high-performance real-time computing. It is used to perform stateful computing on real-time and streaming data streams. Flink can run in all common cluster environments and can perform calculations at memory speed and any scale. In other embodiments, real-time computing can also be implemented through real-time computing frameworks such as spark streaming and storm. In this embodiment, the request log data of the target object request is searched by detecting the request, so as to obtain at least one request log data of its corresponding traffic carrier, and then abnormal request detection is performed by summarizing the found log data, providing basic data guarantee for the abnormal detection process, thereby effectively ensuring the efficiency and accuracy of abnormal detection.
[0073] In one embodiment, step 201 includes: obtaining a detection request for an object request within a target period; and searching for log record data of each object request within the target period based on the detection request.
[0074] The target period refers to a pre-set time period during which request detection is required. The target period can be set according to actual detection requirements and the amount of request data that needs to be processed.
[0075] Specifically, in addition to being applied to real-time abnormal request detection, the solution of the present application can also be applied to non-real-time request detection, for example, it can be applied to the field of timed detection. In the next period after the end of the timed period, the period that has just ended can be used as the target period, and then the object requests received in the target period are detected. By obtaining a detection request for the object request in the target period; then searching for the log record data of each object request in the target period based on the detection request. For timed detection, the length of the timed period can be set according to the request rate and the server calculation rate that processes the request. Figure 3 As shown, for the object requests submitted by different objects u1, u2 and u3 through traffic carriers a1 and a2, an association relationship diagram between objects and traffic carriers can be established based on the detection requests of object requests in the target time period. In this embodiment, by searching the log record data of each object request in the target time period, and then performing abnormal request detection through the found log record data, basic data guarantee is provided for the abnormal detection process, thereby effectively ensuring the efficiency and accuracy of abnormal detection.
[0076] In one embodiment, the characteristic data items include request terminal characteristics and click operation characteristics. Based on the characteristic data items of each object request in the log record data, determining the characteristic data item set of the traffic carrier in the log record data includes: determining the traffic carrier number, request terminal characteristics and click operation characteristics of each object request in the log record data; classifying the object requests based on the traffic carrier number of each object request to obtain the carrier classification result of each object request; determining the characteristic data item set of each traffic carrier based on the characteristic attribute value in the request terminal characteristic, the characteristic attribute value in the click operation characteristic, and the carrier classification result of each object request.
[0077] The request terminal feature refers to the feature of the terminal that initiates the object request, such as the feature data of the terminal model, operating system, and application version. The click operation feature refers to the feature corresponding to the click operation, such as click coordinates, click application scenario, etc. The carrier classification result refers to the request set for different traffic carriers obtained by classifying all object requests into different traffic carriers through the traffic carrier number.
[0078] Specifically, after obtaining the log record data of the object request, in order to perform association analysis on the object request, a frequent feature item set is constructed. It is necessary to first construct a feature data item set based on the feature data items corresponding to the object request as the basic data used for association analysis, and the final item in the feature data is the traffic carrier, and the object request also analyzes the frequent co-occurrence features of the object request under the same traffic carrier. Therefore, the object request can be classified based on the traffic carrier number of each object request to obtain the carrier classification result of each object request. Then, for the object request under each traffic carrier, it can be classified based on the feature attribute values in the request terminal characteristics and the feature attribute values in the click operation characteristics, so as to determine the feature data item set of each traffic carrier. In a specific embodiment, the present application is applied to anomaly detection in the field of content recommendation. At this time, the traffic carrier includes a1 and a2, and the request terminal characteristics include the model, operating system and application version. The request terminal characteristics include click coordinates and click scenes. At this time, by combining these features, the following can be obtained: Figure 4 The feature summary table shown in the figure is then obtained by classifying the traffic carriers to obtain the features of the object requests under the two types of traffic carriers a1 and a2. Then, based on the feature attribute values in the request terminal features and the feature attribute values in the click operation features, the feature data item set of each traffic carrier is determined, and the following can be obtained: Figure 5 In this embodiment, the characteristic data item set of each traffic carrier in the log record data is determined by the traffic carrier number, request terminal feature and click operation feature, thereby providing an effective data basis for association analysis, and further effectively ensuring the accuracy of anomaly detection.
[0079] In one embodiment, step 205 includes: constructing a frequent pattern tree based on feature data item sets; traversing the feature data items in the frequent pattern tree to obtain conditional pattern bases for each feature data item set; and constructing frequent feature item sets based on each conditional pattern base.
[0080] Among them, the frequent pattern tree (FP tree) is a dictionary tree, and the frequent pattern tree can be constructed by reading in the characteristic data items one by one and mapping the characteristic data items into paths. In a specific embodiment, before the establishment, each item can be counted first, and the items with the number of occurrences less than the support are removed, and then the frequent pattern tree is constructed by sorting, and the support of the node is recorded at each node in the book. The conditional pattern base is a set of prefix paths that appear together with the suffix pattern in the frequent pattern tree. Each node in the frequent pattern tree has a prefix, that is, a set of nodes on the path from the root node to the parent node of the node.
[0081] Specifically, the scheme of the present application specifically implements the association analysis of the feature data item set through the FP-Growth algorithm. Therefore, when performing the association analysis, a frequent pattern tree can be first constructed based on the feature data item set. For the construction process, the frequency data of each feature data item in the feature data item set in the log record data can be determined first; and the feature data items are screened based on the frequency data and the target support, and the payment degree is higher than the target support, which can be used as the target feature data item determined as a frequent item; then the initial frequent pattern tree containing the root node is obtained, and the child nodes of the initial frequent pattern tree are constructed based on the root node and the target feature data item to obtain the frequent pattern tree, and then the feature data items in the frequent pattern tree can be traversed to obtain the conditional pattern base of each feature data item set. In a specific embodiment, the feature data items in the frequent pattern tree can be traversed to obtain the node position and node path of each feature data item; based on the node position and the node path, the conditional pattern base of each feature data item can be obtained. That is, the prefix path set corresponding to each node in the frequent pattern tree can be constructed through the node position and the node path of each feature data item. The conditional pattern base corresponding to each feature data item is essentially an item set, so they can be regarded as a new transaction set. Therefore, the feature data item set of the original problem is converted into the sub-transaction set corresponding to each feature data item, and the final frequent item set is generated from the sub-transaction set corresponding to each feature data item, and the problem is divided and conquered by each feature data item. Finally, based on each conditional pattern base, a frequent feature item set is constructed. Specifically, each feature data item can be pruned based on the conditional pattern base to obtain a reconstructed feature item. That is, branches with too low support are removed by pruning, and then, based on the conditional pattern base of each reconstructed feature item, a conditional frequent item set tree of each feature data item can be constructed; then, each conditional frequent item set tree is traversed separately to determine the frequent item set of each reconstructed feature item; finally, a frequent feature item set can be obtained based on the frequent item set of each reconstructed feature item. In one embodiment, for Figure 5 The process of generating frequent feature item sets through FP-Growth algorithm can refer to Figure 6 As shown, first, based on the target support, model 1 and operating system under a1 can be filtered out as the filtered feature data items, operating system 2 and application system 2 under a2 can be filtered out as the filtered feature data items, and then a frequent pattern tree with a root node of null (empty) can be constructed, and the filtered frequent items are a1|model 1+a1|operating system 1, a2|operating system 2+a1|application version 2. In this embodiment, by constructing a frequent pattern tree and then constructing a conditional pattern base for the feature data items, a frequent feature item set in the feature data item set is obtained, and the frequently co-occurring features in the feature data item set can be accurately identified, thereby ensuring the accuracy of abnormal request detection.
[0082] In one embodiment, determining the abnormality of a frequent feature item set based on historical abnormal object data includes: obtaining the number of request objects corresponding to the frequent feature item set; identifying the number of abnormal objects in the number of request objects based on the historical abnormal object data; and obtaining the abnormality of the frequent feature item set based on the ratio of the number of abnormal objects to the number of request objects.
[0083] The number of request objects refers to the number of request objects whose issued object requests satisfy all feature data items in the frequent feature item set, and the number of abnormal objects refers to the number of abnormal objects recorded in the historical abnormal object data among these request objects.
[0084] Specifically, the scheme of the present application can specifically determine the abnormality of the frequent feature item set based on the historical abnormal object data. The abnormality can be identified by comparing the ratio of the identified abnormal objects and all the requested objects in the number of request objects corresponding to the frequent feature item set. First, through the number of request objects corresponding to the frequent feature item set, the relevant information of all object requests can be obtained through log record data, and then the object requests that meet all the features in the frequent feature item set are identified in the object requests, and then based on all the object numbers in these object requests, the number of request objects corresponding to the frequent feature item set can be identified. Then, by comparing the object numbers in the historical abnormal object data with the object numbers in these object requests, the number of abnormal objects in the number of request objects can be determined, and then based on the ratio of the number of abnormal objects to the number of request objects, the abnormality of the frequent feature item set is obtained. In one embodiment, the present application is applied to the field of content recommendation. When applied, the abnormality ε of the frequent feature item set can be calculated to determine whether ε is greater than a specified abnormality threshold (usually 0.5) to perform abnormal detection of user-related recommended content click requests. Assuming that f1+f2+f3 represents a frequent feature item set that appears on a user on a traffic carrier a, the number of users who meet the frequent feature item set is N, and the number of users who meet the frequent feature item set and hit the historical abnormal object library is M, then:
[0085]
[0086] An example of calculating the abnormality of frequent feature item sets is shown in Table 1:
[0087] Table 1: Abnormality calculation table of frequent feature item sets
[0088]
[0089] According to the calculation results in Table 1, the abnormality of the frequent item "a1|machine type 1+a1|operating system 1+a1|IP1" is 0.5, which is greater than or equal to the threshold value (0.5). Therefore, all subsequent users on the traffic master a1 who meet "machine type = machine type 1" and "operating system = operating system 1" and "IP = IP1" hit the abnormal frequent feature item set and are abnormal users. In this embodiment, the abnormality is identified by the ratio of the number of abnormal objects to the number of request objects, which can accurately determine the abnormality of the frequent feature item set and ensure the accuracy and effectiveness of abnormality identification.
[0090] In one embodiment, the method further includes: identifying an abnormal object corresponding to the abnormal request; obtaining object description data of the abnormal object; and updating historical abnormal object data based on the object description data.
[0091] The object description data refers to the relevant data used to characterize the identity information of the abnormal object, such as the object number, the device number of the object, etc. The abnormal object can be located and identified through the object description data.
[0092] Specifically, the solution of the present application can also update the historical abnormal object data based on the detected abnormal request. If some object requests are identified as abnormal requests, it means that the objects corresponding to these abnormal requests are also abnormal objects. Therefore, the abnormal objects corresponding to the abnormal requests can be identified first; then the object description data of the abnormal objects are obtained, and then these object description data are recorded in the historical abnormal object database to achieve the update of the historical abnormal object data. In this embodiment, by updating the historical abnormal object data recorded in the database through the detected abnormal request, the real-time abnormal object update can be effectively completed, and the accuracy of the subsequent abnormal object detection through the historical abnormal object data can be calmly guaranteed.
[0093] In one embodiment, it also includes: determining the request abnormality rate corresponding to each traffic carrier based on the abnormal request; and generating a traffic carrier evaluation report based on the request abnormality rate corresponding to each traffic carrier.
[0094] Specifically, since the traffic carrier may be one of the reasons for the request anomaly, it is necessary to determine the request anomaly rate corresponding to each traffic carrier by the number of abnormal requests / total number of requests of the traffic carrier after identifying the abnormal request, and then generate a traffic carrier evaluation report based on the request anomaly rate corresponding to each traffic carrier. The generated traffic carrier evaluation report becomes the data basis for the subsequent detection process, and the staff can identify whether each traffic carrier is abnormal based on the generated traffic carrier evaluation report. For example, in a specific embodiment, the present application is applied to the anomaly detection in the field of clicks on short video platforms, and the traffic carrier is a user with a certain fan group on the short video platform, because these users can obtain click benefits based on the click-through rate of short videos, so there is a certain motivation to increase the click-through rate of short videos through abnormal short video click requests. At this time, the request anomaly rate of these users can be determined by abnormal requests, and then the traffic carrier evaluation report can be generated by the rate, and the platform can perform subsequent processing on the relevant users involved through the traffic carrier evaluation report. In this embodiment, the traffic carrier evaluation report is generated by the request anomaly rate corresponding to each traffic carrier, which can effectively distinguish the traffic carriers involved in the abnormal request, thereby ensuring the fairness of the request environment.
[0095] The present application also provides an application scenario, which applies the above-mentioned abnormal request detection method.
[0096] Specifically, the application of the abnormal request detection method in this application scenario is as follows:
[0097] When an advertisement is published on an advertising platform, Figure 7 As shown, some accounts, websites or traffic carriers of small program software that post advertisements may use automated scripts or software to control multiple terminals through one or more computers to control abnormal users to click on such Figure 8 The advertisements posted on the traffic carriers shown in the figure are fake click requests for advertisements through abnormal cheating behaviors, thereby affecting the publishing effect of the advertisement content. The solution of this application can detect these abnormal click requests, thereby ensuring the publishing effect of the advertisement content. The overall detection process in this embodiment can refer to Fig. 9As shown, it includes: step 902, sending the object request for clicking the advertisement to the Flink real-time computing module of the anomaly detection in real time. Step 904, extracting the click records of the object in the past period of time, and generating the object-traffic carrier click relationship graph. Step 906, expanding the object features, including the object model, operating system, application version, click coordinates, and click scene. Step 908, using the FPGrowth algorithm to generate a frequent feature item set for the feature data item set. Step 910, calculating the abnormality of the frequent item, judging whether it is greater than the threshold, and then identifying the object that hits the frequent feature item set under the traffic carrier. Specifically, first, after the user initiates an object request for the advertisement through the traffic carrier, the real-time computing server of the platform will use the object request as the target object request for detection, and then obtain the detection request for the target object request from the request database; search for the request log data of the target object request based on the detection request; identify the traffic carrier number carried in the target object request through the request log data; search for at least one request log data of the traffic carrier represented by the traffic carrier number; summarize the request log data obtained from the search, and obtain the log record data of the object request. Then determine the traffic carrier number, request terminal feature and click operation feature of each object request in the log record data to complete the expansion of the object feature; and classify the object request based on the traffic carrier number of each object request to obtain the carrier classification result of each object request; determine the feature data item set of each traffic carrier based on the feature attribute value in the request terminal feature, the feature attribute value in the click operation feature, and the carrier classification result of each object request. Then determine the frequency data of each feature data item in the feature data item set in the log record data; filter the feature data items based on the frequency data and the target support to obtain the target feature data item; obtain the initial frequent pattern tree containing the root node, and construct the child nodes of the initial frequent pattern tree based on the root node and the target feature data item to obtain the frequent pattern tree. Traverse the feature data items in the frequent pattern tree to obtain the node position and node path of each feature data item; based on the node position and node path, obtain the conditional pattern base of each feature data item. Based on the conditional pattern base, each feature data item is trimmed to obtain a reconstructed feature item; based on the conditional pattern base of each reconstructed feature item, a conditional frequent item set tree of each feature data item is constructed; each conditional frequent item set tree is traversed separately to determine the frequent item set of each reconstructed feature item; based on the frequent item set of each reconstructed feature item, a frequent feature item set is obtained. The number of request objects corresponding to the frequent feature item set is obtained; based on the historical abnormal object data, the number of abnormal objects in the number of request objects is identified; based on the ratio of the number of abnormal objects to the number of request objects, the abnormality of the frequent feature item set is obtained. When the abnormality of the frequent feature item set is greater than or equal to the abnormality threshold, the object request whose feature data item meets the frequent feature item set is determined as an abnormal request.In addition, the abnormal object corresponding to the abnormal request can be identified; the object description data of the abnormal object can be obtained; and the historical abnormal object data can be updated based on the object description data. At the same time, the request abnormality rate corresponding to each traffic carrier can be determined based on the abnormal request; a traffic carrier evaluation report can be generated based on the request abnormality rate corresponding to each traffic carrier, so as to analyze and process the traffic carriers related to the platform.
[0098] The complete process of the abnormal request detection method of this application can be referred to Fig.10 As shown, it includes: step 1001, obtaining a detection request for a target object request. Step 1003, searching for request log data of the target object request based on the detection request. Step 1005, identifying the traffic carrier number carried in the target object request through the request log data. Step 1007, searching for at least one request log data of the traffic carrier represented by the traffic carrier number. Step 1009, summarizing the request log data obtained by the search to obtain the log record data of the object request. Step 1011, determining the traffic carrier number, request terminal feature and click operation feature of each object request in the log record data. Step 1013, classifying the object request based on the traffic carrier number of each object request, and obtaining the carrier classification result of each object request. Step 1015, determining the feature data item set of each traffic carrier based on the feature attribute value in the request terminal feature, the feature attribute value in the click operation feature, and the carrier classification result of each object request. Step 1017, constructing a frequent pattern tree based on the feature data item set. Step 1019, traverse the feature data items in the frequent pattern tree to obtain the conditional pattern base of each feature data item set. Step 1021, build a frequent feature item set based on each conditional pattern base. Step 1023, obtain the number of request objects corresponding to the frequent feature item set. Step 1025, identify the number of abnormal objects in the number of request objects based on historical abnormal object data. Step 1027, obtain the abnormality of the frequent feature item set based on the ratio of the number of abnormal objects to the number of request objects. Step 1029, when the abnormality of the frequent feature item set is greater than or equal to the abnormality threshold, determine the object request whose feature data item meets the frequent feature item set as an abnormal request.
[0099] It should be understood that, although the steps in the flowcharts involved in the above embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps is not strictly limited in order, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above embodiments may include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0100] Based on the same inventive concept, the embodiment of the present application also provides an abnormal request detection device for implementing the abnormal request detection method involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in one or more abnormal request detection device embodiments provided below can refer to the limitations of the abnormal request detection method above, and will not be repeated here.
[0101] In one embodiment, Fig.11 As shown, an abnormal request detection device is provided, comprising:
[0102] The log acquisition module 1102 is used to acquire log record data for recording object requests.
[0103] The feature identification module 1104 is used to determine a feature data item set matching the traffic carrier recorded in the log record data based on the feature data items of each object request in the log record data.
[0104] The frequent item set construction module 1106 is used to perform association analysis on the association relationship between the feature data items in the feature data item set to construct a frequent feature item set.
[0105] The abnormality identification module 1108 is used to determine the abnormality of the frequent feature item set based on the historical abnormal object data. The abnormality is determined according to the proportion of abnormal objects in the objects corresponding to the frequent feature item set. The abnormal objects in the objects are determined based on the historical abnormal object data.
[0106] The abnormal request detection module 1110 is configured to determine an object request whose feature data items conform to the frequent feature item set as an abnormal request when the abnormality of the frequent feature item set is greater than or equal to an abnormality threshold.
[0107] In one embodiment, the log acquisition module 1102 is specifically used to: obtain a detection request for a target object request; search for request log data of the target object request based on the detection request; identify the traffic carrier number carried in the target object request through the request log data; search for at least one request log data representing the traffic carrier number; and summarize the request log data obtained by the search to obtain log record data of the object request.
[0108] In one embodiment, the log acquisition module 1102 is specifically used to: acquire a detection request for an object request within a target period; and search for log record data of each object request within the target period based on the detection request.
[0109] In one embodiment, the feature data items include request terminal features and click operation features, and the feature identification module 1104 is specifically used to: determine the traffic carrier number, request terminal features, and click operation features of each object request in the log record data; classify the object requests based on the traffic carrier number of each object request to obtain the carrier classification result of each object request; determine the feature data item set of each traffic carrier based on the feature attribute value in the request terminal feature, the feature attribute value in the click operation feature, and the carrier classification result of each object request.
[0110] In one embodiment, the log acquisition module 1106 is specifically used to: construct a frequent pattern tree based on feature data item sets; traverse the feature data items in the frequent pattern tree to obtain conditional pattern bases of each feature data item set; and construct frequent feature item sets based on each conditional pattern base.
[0111] In one embodiment, the log acquisition module 1106 is specifically used to: determine the frequency data of each feature data item in the feature data item set in the log record data; filter the feature data items based on the frequency data and the target support to obtain the target feature data items; obtain an initial frequent pattern tree including a root node, and construct child nodes of the initial frequent pattern tree based on the root node and the target feature data items to obtain a frequent pattern tree.
[0112] In one embodiment, the log acquisition module 1106 is specifically used to: traverse the feature data items in the frequent pattern tree to obtain the node position and node path of each feature data item; and obtain the conditional pattern base of each feature data item based on the node position and node path.
[0113] In one embodiment, the log acquisition module 1106 is specifically used to: perform trimming processing on each feature data item based on a conditional pattern base to obtain a reconstructed feature item; construct a conditional frequent item set tree for each feature data item based on the conditional pattern base of each reconstructed feature item; traverse each conditional frequent item set tree separately to determine the frequent item set of each reconstructed feature item; and obtain a frequent feature item set based on the frequent item set of each reconstructed feature item.
[0114] In one embodiment, the abnormality identification module 1108 is specifically used to: obtain the number of request objects corresponding to the frequent feature item set; identify the number of abnormal objects in the number of request objects based on historical abnormal object data; and obtain the abnormality of the frequent feature item set based on the ratio of the number of abnormal objects to the number of request objects.
[0115] In one embodiment, a database update module is also included, which is used to: identify the abnormal object corresponding to the abnormal request; obtain object description data of the abnormal object; and update the historical abnormal object data based on the object description data.
[0116] In one embodiment, it also includes a carrier evaluation module, which is used to: determine the request abnormality rate corresponding to each traffic carrier based on the abnormal request; and generate a traffic carrier evaluation report based on the request abnormality rate corresponding to each traffic carrier.
[0117] Each module in the above abnormal request detection device can be implemented in whole or in part by software, hardware, or a combination thereof. Each module can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute operations corresponding to each module.
[0118] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as follows: Fig.12 As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. Among them, the processor, the memory and the input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store data related to abnormal request detection. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, an abnormal request detection method is implemented.
[0119] Those skilled in the art will understand that Fig.12The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0120] In one embodiment, a computer device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above method embodiments when executing the computer program.
[0121] In one embodiment, a computer-readable storage medium is provided, storing a computer program, which implements the steps in the above method embodiments when executed by a processor.
[0122] In one embodiment, a computer program product or computer program is provided, the computer program product or computer program includes computer instructions, the computer instructions are stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device performs the steps in the above-mentioned method embodiments.
[0123] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.
[0124] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0125] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A method for detecting abnormal requests, characterized in that: The method comprises: Gets the logging data for recording object requests; Based on the characteristic data items of each object request in the log record data, determining a characteristic data item set matching the traffic carrier recorded in the log record data; Performing association analysis on the association relationships between the feature data items in the feature data item set to construct a frequent feature item set; Based on the historical abnormal object data, determining the abnormality of the frequent feature item set, wherein the abnormality is determined according to the proportion of abnormal objects in the objects corresponding to the frequent feature item set, and the abnormal objects in the objects are determined based on the historical abnormal object data; When the abnormality degree of the frequent feature item set is greater than or equal to the abnormality threshold, the object request whose feature data items conform to the frequent feature item set is determined as an abnormal request.
2. The method according to claim 1, characterized in that The obtaining of log record data for recording object requests includes: Obtain a detection request for a target object request; Searching for request log data of the target object request based on the detection request; Identifying the traffic carrier number carried in the target object request through the request log data; Searching for at least one request log data of a traffic carrier represented by the traffic carrier number; The request log data obtained by the search are summarized to obtain the log record data of the object request.
3. The method according to claim 1, characterized in that: The obtaining of log record data for recording object requests includes: Obtaining a detection request for an object request within a target time period; The log record data of each object request within the target time period is searched based on the detection request.
4. The method according to claim 1, characterized in that: The characteristic data items include request terminal characteristics and click operation characteristics; the characteristic data item set of determining the traffic carrier in the log record data based on the characteristic data items of each object request in the log record data includes: Determine the traffic carrier number, request terminal characteristics, and click operation characteristics of each object request in the log record data; Classifying the object requests based on the traffic carrier numbers of the object requests to obtain carrier classification results of the object requests; Based on the characteristic attribute value in the request terminal feature, the characteristic attribute value in the click operation feature, and the carrier classification result of each object request, a characteristic data item set of each traffic carrier is determined.
5. The method according to claim 1, characterized in that The performing association analysis on the association relationship between the feature data items in the feature data item set to construct a frequent feature item set comprises: Constructing a frequent pattern tree based on the feature data item set; Traversing the feature data items in the frequent pattern tree to obtain conditional pattern bases of respective feature data item sets; Based on each of the conditional pattern bases, a frequent feature item set is constructed.
6. The method according to claim 5, characterized in that The constructing of a frequent pattern tree based on the feature data item set comprises: Determine frequency data of each characteristic data item in the characteristic data item set in the log record data; Filtering the feature data items based on the frequency data and the target support to obtain target feature data items; An initial frequent pattern tree including a root node is obtained, and child nodes of the initial frequent pattern tree are constructed based on the root node and the target feature data item to obtain a frequent pattern tree.
7. The method according to claim 5, characterized in that The traversing of the feature data items in the frequent pattern tree to obtain the conditional pattern base of each feature data item set comprises: Traversing the characteristic data items in the frequent pattern tree to obtain the node position and node path of each characteristic data item; Based on the node position and the node path, a conditional pattern base of each feature data item is obtained.
8. The method according to claim 5, characterized in that The constructing of frequent feature item sets based on the conditional pattern base includes: Performing a trimming process on each feature data item based on the conditional pattern base to obtain a reconstructed feature item; Based on the conditional pattern base of each reconstructed feature item, a conditional frequent item set tree of each feature data item is constructed; Traversing each of the conditional frequent item set trees respectively to determine the frequent item sets of each reconstructed feature item; Frequent feature item sets are obtained based on the frequent item sets of each reconstructed feature item.
9. The method according to claim 1, characterized in that: The determining the abnormality degree of the frequent feature item set based on the historical abnormal object data includes: Obtaining the number of request objects corresponding to the frequent feature item set; Based on historical abnormal object data, identifying the number of abnormal objects in the number of requested objects; Based on the ratio of the number of abnormal objects to the number of request objects, the abnormality degree of the frequent feature item set is obtained.
10. The method according to any one of claims 1 to 9, characterized in that: Also includes: Identify an abnormal object corresponding to the abnormal request; Obtain object description data of the abnormal object; The historical abnormal object data is updated based on the object description data.
11. The method according to any one of claims 1 to 9, characterized in that: Also includes: Determine a request abnormality rate corresponding to each traffic carrier based on the abnormal request; A traffic carrier assessment report is generated based on the request anomaly rate corresponding to each traffic carrier.
12. An abnormal request detection device, characterized in that: The device comprises: A log acquisition module, used to acquire log record data for recording object requests; A feature identification module, configured to determine a feature data item set matching a traffic carrier recorded in the log record data based on feature data items of each object request in the log record data; A frequent item set construction module, used to perform association analysis on the association relationship between the feature data items in the feature data item set to construct a frequent feature item set; An abnormality identification module, used to determine the abnormality of the frequent feature item set based on historical abnormal object data, wherein the abnormality is determined according to the proportion of abnormal objects in the objects corresponding to the frequent feature item set, and the abnormal objects in the objects are determined based on the historical abnormal object data; The abnormal request detection module is used to determine an object request whose feature data items conform to the frequent feature item set as an abnormal request when the abnormality of the frequent feature item set is greater than or equal to an abnormality threshold.
13. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 11 are implemented.
14. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 11 are implemented.
15. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 11 are implemented.
Citation Information
Cited By
Advertisement click flow analysis and anomaly recognition system and method
CN120634640A
An advertisement click flow analysis and anomaly identification system and method
CN120634640B
