An anti-crawler method, device, computer-readable storage medium, and electronic device

By encapsulating the page information policy data and rendering the front-end disguised data, the problem that anti-crawler strategies in the existing technology are easily bypassed, and the efficiency and flexibility of anti-crawlers are improved.

CN113791965BActive Publication Date: 2025-06-20BEIJING WODONG TIANJUN INFORMATION TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202110120768.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-01-28
Publication Date
2025-06-20
Estimated Expiration
2041-01-28

AI Technical Summary

Technical Problem

In the prior art, anti-crawler strategies are easily bypassed by cheating teams, and the regular changes of fields and front-end burial methods are poor in flexibility, and the policy changes are costly.

Method used

The page information is encapsulated based on the policy data through the backend, and the page information is generated and sent to the frontend. The front-end determines the camouflage data in the encapsulated page information based on the preset data segment, and configures the buried point value according to the buried point field and the obfuscation algorithm, adds the target camouflage style of the camouflage data, and renders it.

Benefits of technology

The efficiency and accuracy of anti-crawlers are improved. Through the unfixed regular packaged page information and flexible burying point value configuration, it is difficult for crawlers to grasp the rules, reducing system consumption.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113791965B_ABST
    Figure CN113791965B_ABST
Patent Text Reader

Abstract

The present disclosure relates to the field of computer technologies, and provides an anti-crawler method, apparatus, computer-readable storage medium, and electronic device. The method includes: the backend encapsulates page information according to policy data to obtain encapsulated page information, and sends the encapsulated page information to the frontend, where the policy data includes buried point fields, an obfuscation algorithm, and a preset data segment; the frontend determines camouflage data in the encapsulated page information according to the preset data segment, and configures a buried point value according to the buried point fields and the obfuscation algorithm; the frontend adds a target camouflage style of the camouflage data according to the buried point value, and renders the camouflage data according to the target camouflage style. The present disclosure can configure the buried point value through policy data and add a target camouflage style, realizing flexible configuration of page data, thereby improving the accuracy of anti-crawler.
Need to check novelty before this filing date? Find Prior Art

Description

Background Art

[0002] With the development of computer technology, there have emerged business systems that charge fees based on the number of user clicks. In these business systems, there is a situation where machines simulate user clicks by scraping page data of the business system, resulting in false click counts.

[0003] In the prior art, the front end and the back end of the business system agree on a fixed field as the identifier of the disguised data. The back end attaches the disguise identifier to the disguised data, and the front end uses this disguise identifier to determine whether the obtained page data is disguised data. Based on the judgment result, the front end further controls whether to display or hide the page data. Additionally, the front end and the back end regularly update the identifier field used as the disguised data, as well as the front-end data embedding method. However, cheating teams can optimize the crawler script to remove such page data before simulating clicks, or simulate clicks on data links to identify the disguised data identifier, thus evading the anti-crawler strategies in the prior art. Moreover, the anti-crawler technologies in the prior art regularly change the fields and the front-end data embedding method, which requires both the front end and the back end to cooperate in modification and go live, resulting in poor flexibility and high strategy change costs.

[0004] In view of this, there is an urgent need in the art to develop a new anti-crawler method and device.

[0005] It should be noted that the information disclosed in the above Background Art section is only used to enhance the understanding of the background of the present disclosure, and thus may include information that does not constitute the prior art known to those of ordinary skill in the art. Summary of the Invention

[0006] The purpose of the present disclosure is to provide an anti-crawler method, an anti-crawler device, a computer-readable storage medium, and an electronic device, thereby at least to a certain extent improving the efficiency of anti-crawling.

[0007] Other features and advantages of the present disclosure will become apparent through the following detailed description, or will be partially learned through the practice of the present disclosure.

[0008] According to one aspect of the present disclosure, there is provided an anti-crawler method, the method including: the back end encapsulates page information according to policy data to obtain encapsulated page information, and sends the encapsulated page information to the front end, where the policy data includes a data embedding field, an obfuscation algorithm, and a preset data segment; the front end determines disguised data in the encapsulated page information according to the preset data segment, and configures a data embedding value according to the data embedding field and the obfuscation algorithm; the front end adds a target disguise style to the disguised data according to the data embedding value, and renders the disguised data according to the target disguise style.

[0009] In some exemplary embodiments of the present disclosure, the page information includes multiple pieces of page data, and the page data includes real data and the disguised data; the backend encapsulates the page information according to the policy data to obtain the encapsulated page information, including: the backend obtains the page information, as well as the buried point field, the obfuscation algorithm, and the preset data segment; generates target data corresponding to the real data and the disguised data through a first random function and the preset data segment; encapsulates the page information according to the target data and the policy data to generate the encapsulated page information.

[0010] In some exemplary embodiments of the present disclosure, generating target data corresponding to the real data and the disguised data through a first random function and the preset data segment includes: if the page data is the real data, generate first data outside the range of the preset data segment through the first random function, and configure the first data as the target data corresponding to the real data; if the page data is the disguised data, generate second data within the range of the preset data segment through the first random function, and configure the second data as the target data corresponding to the disguised data.

[0011] In some exemplary embodiments of the present disclosure, the front end determines the disguised data in the encapsulated page information according to the preset data segment, including: the front end obtains the target data in the encapsulated page information, and determines the disguised data in the encapsulated page information according to the target data and the preset data segment.

[0012] In some exemplary embodiments of the present disclosure, determining the disguised data in the encapsulated page information according to the target data and the preset data segment includes: determining whether the target data is within the range of the preset data segment: if so, determine that the page data corresponding to the target data is the disguised data; if not, determine that the page data corresponding to the target data is the real data.

[0013] In some exemplary embodiments of the present disclosure, the front end configures the buried point value according to the buried point field and the obfuscation algorithm, including: the front end processes the buried point field by using the obfuscation algorithm to generate the buried point value.

[0014] In some exemplary embodiments of the present disclosure, the front end adds the target disguise style of the disguised data according to the buried point value, including: the front end inserts the buried point value into the block corresponding to the disguised data, and controls the block to add the target disguise style, where the target disguise style is obtained from the disguise style database according to a second random function.

[0015] In some exemplary embodiments of the present disclosure, the policy center updates the buried point fields, the obfuscation algorithm, and the preset data segments by using a third random function.

[0016] According to one aspect of the present disclosure, there is provided an anti-crawler method, the method comprising: encapsulating page information according to policy data to obtain encapsulated page information, and sending the encapsulated page information to the front end, wherein the policy data includes buried point fields, an obfuscation algorithm, and preset data segments; determining, by the front end, disguised data in the encapsulated page information according to the preset data segments, and configuring buried point values according to the buried point fields and the obfuscation algorithm; adding, by the front end, a target disguise style of the disguised data according to the buried point values, and rendering the disguised data according to the target disguise style.

[0017] In some exemplary embodiments of the present disclosure, the page information includes multiple pieces of page data, and the page data includes real data and the disguised data; encapsulating the page information according to the policy data to obtain the encapsulated page information includes: obtaining the page information, and the buried point fields, the obfuscation algorithm, and the preset data segments; generating target data corresponding to the real data and the disguised data by using a first random function and the preset data segments; and encapsulating the page information according to the target data and the policy data to generate the encapsulated page information.

[0018] In some exemplary embodiments of the present disclosure, generating target data corresponding to the real data and the disguised data by using a first random function and the preset data segments includes: if the page data is the real data, generating first data outside the range of the preset data segments by using the first random function, and configuring the first data as the target data corresponding to the real data; if the page data is the disguised data, generating second data within the range of the preset data segments by using the first random function, and configuring the second data as the target data corresponding to the disguised data.

[0019] According to one aspect of the present disclosure, there is provided an anti-crawler method, the method comprising: receiving the encapsulated page information sent by the back end, the encapsulated page information being generated by encapsulating the page information according to the policy data, wherein the policy data includes buried point fields, an obfuscation algorithm, and preset data segments; determining, according to the preset data segments, the disguised data in the encapsulated page information, and configuring buried point values according to the buried point fields and the obfuscation algorithm; adding a target disguise style of the disguised data according to the buried point values, and rendering the disguised data according to the target disguise style.

[0020] In some exemplary embodiments of the present disclosure, determining the camouflage data according to the preset data segment in the encapsulated page information includes: obtaining the target data in the encapsulated page information, and determining the camouflage data in the encapsulated page information according to the target data and the preset data segment.

[0021] In some exemplary embodiments of the present disclosure, determining the camouflage data according to the target data and the preset data segment in the encapsulated page information includes: determining whether the target data is within the range of the preset data segment: if so, determining the page data corresponding to the target data as the camouflage data; if not, determining the page data corresponding to the target data as the real data.

[0022] In some exemplary embodiments of the present disclosure, configuring the buried point value according to the buried point field and the obfuscation algorithm includes: processing the buried point field by using the obfuscation algorithm to generate the buried point value.

[0023] In some exemplary embodiments of the present disclosure, adding the target camouflage style of the camouflage data according to the buried point value includes: inserting the buried point value into the block corresponding to the camouflage data, and controlling the block to add the target camouflage style, where the target camouflage style is obtained from the camouflage style database according to the second random function.

[0024] According to one aspect of the present disclosure, there is provided an anti-crawler device, the anti-crawler device includes: a first encapsulation module, configured to encapsulate page information by the backend according to policy data to obtain encapsulated page information, and send the encapsulated page information to the frontend, where the policy data includes a buried point field, an obfuscation algorithm, and a preset data segment; a first configuration module, configured to determine camouflage data in the encapsulated page information by the frontend according to the preset data segment, and configure a buried point value according to the buried point field and the obfuscation algorithm; a first rendering module, configured to add the target camouflage style of the camouflage data by the frontend according to the buried point value, and render the camouflage data according to the target camouflage style.

[0025] According to one aspect of the present disclosure, there is provided an anti-crawler device, which includes: a second encapsulation module for encapsulating page information according to policy data to obtain encapsulated page information and sending the encapsulated page information to the front end, where the policy data includes buried point fields, an obfuscation algorithm, and a preset data segment; a second configuration module for determining camouflage data in the encapsulated page information by the front end according to the preset data segment, and configuring buried point values according to the buried point fields and the obfuscation algorithm; a second rendering module for adding a target camouflage style of the camouflage data by the front end according to the buried point values and rendering the camouflage data according to the target camouflage style.

[0026] According to one aspect of the present disclosure, there is provided an anti-crawler device, which includes: a third encapsulation module for receiving the encapsulated page information sent by the back end, where the encapsulated page information is generated by encapsulating page information according to policy data, and the policy data includes buried point fields, an obfuscation algorithm, and a preset data segment; a third configuration module for determining camouflage data in the encapsulated page information according to the preset data segment, and configuring buried point values according to the buried point fields and the obfuscation algorithm; a third rendering module for adding a target camouflage style of the camouflage data according to the buried point values and rendering the camouflage data according to the target camouflage style.

[0027] According to one aspect of the present disclosure, there is provided a computer-readable medium having a computer program stored thereon, and when the program is executed by a processor, it implements the anti-crawler method as described in the above embodiments.

[0028] According to one aspect of the present disclosure, there is provided an electronic device, which includes: one or more processors; a storage device for storing one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors implement the anti-crawler method as described in the above embodiments.

[0029] As can be seen from the above technical solutions, the anti-crawler method and device, computer-readable storage medium, and electronic device in the exemplary embodiments of the present disclosure at least have the following advantages and positive effects:

[0030] The anti-crawler method of the present disclosure first encapsulates page information by the backend according to policy data to obtain encapsulated page information, and sends the encapsulated page information to the front end. The policy data includes buried point fields, obfuscation algorithms, and preset data segments. Then, the front end determines camouflage data in the encapsulated page information according to the preset data segment, and configures the buried point value according to the buried point fields and the obfuscation algorithm. Finally, the front end adds the target camouflage style of the camouflage data according to the buried point value, and renders the camouflage data according to the target camouflage style. On the one hand, in the anti-crawler method of the present disclosure, the backend can encapsulate page information according to policy data, and the front end receives encapsulated page information without a fixed pattern, so that when the crawler crawls the front-end data and simulates clicks, it cannot grasp the pattern, improving the accuracy of anti-crawling. On the other hand, it can configure the buried point value through policy data, and complete the rendering of page data according to the buried point value, realizing flexible configuration of page data, and no need for re-development during the configuration process, reducing system consumption.

[0031] It should be understood that the above general description and the following detailed description are only exemplary and explanatory, and cannot limit the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] The accompanying drawings herein are incorporated into the specification and constitute a part of this specification, showing embodiments consistent with the present disclosure, and are used together with the specification to explain the principles of the present disclosure. Obviously, the accompanying drawings in the following description are only some embodiments of the present disclosure, and those of ordinary skill in the art can obtain other drawings based on these drawings without creative efforts.

[0033] Figure 1 Schematically shows a flowchart of an anti-crawler method according to an embodiment of the present disclosure;

[0034] Figure 2 Schematically shows a flowchart of encapsulating page information according to an embodiment of the present disclosure;

[0035] Figure 3 Schematically shows a flowchart of determining camouflage data according to an embodiment of the present disclosure;

[0036] Figure 4 Schematically shows a structural diagram of an anti-crawler system according to an embodiment of the present disclosure;

[0037] Figure 5 Schematically shows a flowchart of an anti-crawler method according to an embodiment of the present disclosure;

[0038] Figure 6 Schematically shows a flowchart of an anti-crawler method according to an embodiment of the present disclosure;

[0039] Figure 7 Schematically shows a block diagram of an anti-crawler device according to an embodiment of the present disclosure;

[0040] Figure 8 Schematically shows a block diagram of an anti-crawler device according to an embodiment of the present disclosure;

[0041] Figure 9 Schematically shows a block diagram of an anti-crawler device according to an embodiment of the present disclosure;

[0042] Figure 10 Schematically shows a module diagram of an electronic device according to an embodiment of the present disclosure;

[0043] Figure 11 Schematically shows a schematic diagram of a program product according to an embodiment of the present disclosure. Detailed implementation manners

[0044] Example embodiments will now be described more fully with reference to the accompanying drawings. However, the example embodiments can be implemented in various forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that this disclosure will be more complete and comprehensive, and will fully convey the concept of the example embodiments to those skilled in the art.

[0045] In addition, the described features, structures, or characteristics can be combined in any suitable manner in one or more embodiments. In the following description, numerous specific details are provided to give a thorough understanding of the embodiments of the present disclosure. However, those skilled in the art will realize that the technical solutions of the present disclosure can be practiced without one or more of the specific details, or other methods, components, devices, steps, etc. can be employed. In other cases, well-known methods, devices, implementations, or operations are not shown or described in detail to avoid obscuring aspects of the present disclosure.

[0046] The block diagrams shown in the drawings are merely functional entities and do not necessarily correspond to physically independent entities. That is, these functional entities can be implemented in software form, or in one or more hardware modules or integrated circuits, or in different networks and / or processor devices and / or microcontroller devices.

[0047] The flowcharts shown in the drawings are merely illustrative and do not necessarily include all the content and operations / steps, nor do they necessarily have to be executed in the order described. For example, some operations / steps can be decomposed, while some operations / steps can be combined or partially combined, so the actual execution order may change according to the actual situation.

[0048] In an embodiment of the present disclosure, an anti-crawler method is proposed. Figure 1The flowchart of the anti-crawler method is shown, as Figure 1 shown. The anti-crawler method at least includes the following steps:

[0049] Step S110: The backend encapsulates the page information according to the policy data to obtain the encapsulated page information, and sends the encapsulated page information to the frontend. Among them, the policy data includes the buried point field, the obfuscation algorithm, and the preset data segment;

[0050] Step S120: The frontend determines the disguised data in the encapsulated page information according to the preset data segment, and configures the buried point value according to the buried point field and the obfuscation algorithm;

[0051] Step S130: The frontend adds the target disguise style of the disguised data according to the buried point value, and renders the disguised data according to the target disguise style.

[0052] In the information recommendation method of the embodiments of the present disclosure, on the one hand, it can encapsulate the page information according to the policy data, and what the frontend receives is the encapsulated page information without a fixed pattern, so that when the crawler crawls the backend data for simulated clicks, it cannot grasp the pattern, improving the accuracy of anti-crawler; on the other hand, it can configure the buried point value through the policy data and complete the rendering of the page data according to the buried point value, realizing the flexible configuration of the page data, and there is no need for re-development during the configuration process, reducing the system consumption.

[0053] In order to make the technical solution of the present disclosure clearer, the following will explain each step of the anti-crawler method.

[0054] In step S110, the backend encapsulates the page information according to the policy data to obtain the encapsulated page information, and sends the encapsulated page information to the frontend. Among them, the policy data includes the buried point field, the obfuscation algorithm, and the preset data segment.

[0055] In the exemplary embodiments of the present disclosure, the frontend faces the user and includes a human-computer interaction interface. For example, the frontend can be a browser, an application program, a web page, etc., and the present disclosure does not make specific limitations thereto. The backend performs logical operations and sends data to the frontend to control the frontend. For example, the backend can be a server, a database, etc., and the present disclosure does not make specific limitations thereto.

[0056] In the exemplary embodiments of the present disclosure, the page information includes multiple pieces of page data. The multiple pieces of page data can include one or more pieces of disguised data and one or more pieces of real data. The page data can be page information displayed on the human-computer interaction interface in any form. For example, it can be commodity data on the human-computer interaction interface, or it can also be advertisement data, etc., and the present disclosure does not make specific limitations thereto.

[0057] In an exemplary embodiment of the present disclosure, policy data is configured through a policy center, and the backend obtains the policy data from the policy center. The policy data includes buried point fields, obfuscation algorithms, and preset data segments.

[0058] Among them, the buried point fields may include class names or custom attribute values, etc. For example, the class name may be any character or string representing a class selector, which may be "intro", or "hometown", etc. The present disclosure does not make specific limitations thereto; the custom attribute value may be any character or string set according to actual situations, and the present disclosure does not make specific limitations thereto.

[0059] In addition, the obfuscation algorithm may be any obfuscation algorithm. For example, it may be a forward and reverse order algorithm, an md5 encryption algorithm, or a base64-bit encryption algorithm, etc. The present disclosure does not make specific limitations thereto.

[0060] Furthermore, the preset data segment may be any data range, including a first endpoint value and a second endpoint value. The first endpoint value and the second endpoint value may be any real numbers. For example, the preset data segment may be a data range composed of a first endpoint value of 0 and a second endpoint value of 5, or may be a data range composed of a first endpoint value of 50 and a second endpoint value of 100. The present disclosure does not make specific limitations to the first endpoint value and the second endpoint value in the preset data segment.

[0061] In an exemplary embodiment of the present disclosure, the policy center may use a third random function to update the buried point fields, obfuscation algorithms, and preset data segments. Specifically, the policy center may use the third random function to determine the time interval for each update. For example, if the third random function generates a random number 2, the policy center will update the buried point fields, obfuscation algorithms, and preset data segments after 2 hours or 2 minutes. With different random numbers generated by the second random function, the buried point fields, obfuscation algorithms, and preset data segments are updated at irregular times.

[0062] Among them, the third random function may be any random function that can generate random numbers. For example, it may be the "random" function, or the "rand" function, the "srand" function, etc. The present disclosure does not make specific limitations thereto.

[0063] In an exemplary embodiment of the present disclosure, the policy center may also use a third random function to randomly update the current buried point field, the current obfuscation algorithm, and the current preset data segment. For example, for the update of the current buried point field, a random character may be randomly generated using the third random function, and the random character may be used as the new buried point field to update the current buried point field; for the update of the current preset data segment, a first random number and a second random number may also be generated using the third random function, and the first random number and the second random number may be used as a range interval to generate a new preset data segment to update the current preset data segment.

[0064] In addition, the update of the buried point field, the obfuscation algorithm, and the preset data segment in the policy center may also be randomly set by an engineer to achieve random and irregular update of the policy data.

[0065] In an exemplary embodiment of the present disclosure, the policy center may include an obfuscation algorithm database, which includes multiple obfuscation algorithms. The policy center randomly selects an obfuscation algorithm from the obfuscation algorithm database according to the third random function for updating the current obfuscation algorithm. In addition, the same update method as the above update of the obfuscation algorithm may also be used to update the buried point field and the preset data segment, which will not be elaborated herein in the present disclosure.

[0066] In an exemplary embodiment of the present disclosure, after the backend obtains the policy data and the page information, it is necessary to encapsulate the page information according to the policy data to obtain the encapsulated page information.

[0067] Specifically, Figure 2 shows a schematic flowchart of encapsulating the page information, as Figure 2 shown, this process at least includes steps S210 to S230, which are introduced in detail as follows:

[0068] In step S210, the backend obtains the page information, as well as the buried point field, the obfuscation algorithm, and the preset data segment.

[0069] In an exemplary embodiment of the present disclosure, the backend obtains the page information, as well as the buried point field, the obfuscation algorithm, and the preset data segment from the policy center. In practical applications, when the backend obtains the page information, it already knows whether multiple pieces of data in the page information are real data or disguised data, or the backend customizes multiple pieces of page data to determine one or more pieces of real data and one or more pieces of disguised data.

[0070] In an exemplary embodiment of the present disclosure, the policy center may also be configured with a buried point field database, an obfuscation algorithm database, and a preset data segment database. The backend may randomly obtain a buried point field, an obfuscation algorithm, and a preset data segment from the buried point field database, the obfuscation algorithm database, and the preset data segment database of the policy center respectively by using a random function. For example, the random function generates a random number, and according to this random number, a buried point field, an obfuscation algorithm, and a preset data segment with the same serial number as the random number are obtained from the buried point field database.

[0071] In step S220, target data corresponding to the real data and the disguised data is generated through a first random function and a preset data segment.

[0072] In an exemplary embodiment of the present disclosure, if the page data is real data, a first data outside the preset data segment range is generated through a first random function, and the first data is configured as the target data corresponding to the real data. Specifically, a first data outside the preset data segment range is generated according to the first random function, and this first data is used as the target data corresponding to the real data. If there are multiple pieces of real data, for each piece of real data, a first data corresponding to each piece of real data is generated respectively through the first random function.

[0073] If the page data is disguised data, a second data within the preset data segment range is generated through a first random function, and the second data is configured as the target data corresponding to the disguised data. Specifically, a second data within the preset data segment range is generated according to the first random function, and this second data is used as the target data corresponding to the disguised data. If there are multiple pieces of disguised data, for each piece of disguised data, a second data corresponding to each piece of disguised data is generated respectively through the first random function.

[0074] For example, assume that the preset data segment is 0 - 5. If the obtained page data is disguised data, any number between 0 and 5 is generated through the first random function. For example, the random number 2 is generated as the target data for this disguised data; if the obtained page data is real data, any number outside 0 - 5 is generated through the first random function. For example, the random number 10 is generated as the target data for this real data. The target data corresponding to the page data changes according to the change of the preset data segment. If the preset data segment shows irregular random changes, then the target data corresponding to the page data also shows irregular random changes.

[0075] Among them, the first random function and the second random function may be the same or different, and the present disclosure does not make specific limitations on this.

[0076] In step S230, the page information is encapsulated according to the target data and the policy data to generate encapsulated page data.

[0077] In an exemplary embodiment of the present disclosure, page information can be data-encapsulated according to buried-point fields, an obfuscation algorithm, a preset data segment, and target data corresponding to each piece of page data to form encapsulated page information. Among them, the encapsulated page information includes multiple pieces of page data, target data corresponding to each piece of page data, and buried-point fields, an obfuscation algorithm, and a preset data segment.

[0078] In addition, a set of encapsulated page information can include a set of policy data, that is, a set of policy data can be used to encapsulate a set of page information. A human-computer interaction interface can include a set of page information, that is, each human-computer interaction interface corresponds to a set of policy data. A set of policy data can also be used to encapsulate multiple sets of page data, that is, multiple sets of page information in multiple human-computer interaction interfaces can be encapsulated using the same set of policy data, or multiple sets of page information in a website and a system can be encapsulated using the same set of policy data. The present disclosure does not make specific limitations in this regard.

[0079] In an exemplary embodiment of the present disclosure, multiple pieces of page data in page information can be separately encapsulated, that is, buried-point fields, an obfuscation algorithm, a preset data segment, and target data corresponding to each piece of page information are respectively added to each piece of page data to form multiple encapsulated page data. Among them, each encapsulated page data includes page data, target data corresponding to the page data, and buried-point fields, an obfuscation algorithm, and a preset data segment. The policy data in each encapsulated page data can be the same or different. The present disclosure does not make specific limitations in this regard.

[0080] In step S120, the front end determines disguised data in the encapsulated page data according to the preset data segment, and configures the buried-point value according to the buried-point field and the obfuscation algorithm.

[0081] In an exemplary embodiment of the present disclosure, the front end receives the encapsulated page data sent by the back end, obtains the target data in the encapsulated page data, and determines the disguised data in the encapsulated page data according to the target data and the preset data segment.

[0082] Specifically, Figure 3 shows a schematic flow diagram for determining disguised data, as Figure 3 shown. In step S310, it is determined whether the target data is within the range of the preset data segment: in step S320, if the target data is within the range of the preset data segment, it is determined that the page data corresponding to the target data is disguised data; in step S330, if the target data is not within the range of the preset data segment, it is determined that the page data corresponding to the target data is real data.

[0083] In an exemplary embodiment of the present disclosure, the buried point fields corresponding to the disguised data and the obfuscation algorithm are obtained, and the buried point values are configured according to the buried point fields and the obfuscation algorithm in the disguised data. Specifically, the front end processes the buried point fields by using the obfuscation algorithm corresponding to the disguised data to generate the buried point values corresponding to the disguised data.

[0084] For example, if the obfuscation algorithm corresponding to the disguised data is the forward and reverse order algorithm and the buried point field is abc, then the buried point field abc is processed by using the forward and reverse order algorithm, and the obtained buried point value is cba.

[0085] Since the disguised data included in the same page information can be encapsulated by using the same set of policy data, the buried point values corresponding to the disguised data in the same page information are the same. Of course, multiple disguised data in the same page information can be encapsulated by using different policy data, and each disguised data corresponds to a set of policy data. Therefore, the buried point values corresponding to each disguised data will also be different, and the present disclosure does not make specific limitations on this.

[0086] In step S130, the front end adds the target disguise style of the disguised data according to the buried point value, and renders the disguised data according to the target disguise style.

[0087] In an exemplary embodiment of the present disclosure, the target disguise style is obtained from the disguise style database according to the second random function. The disguise style database may include various types in the hidden style List-style. For example, it may be hidden by setting display:none, the style is floated and placed at the bottom of the page, or hidden by using absolute positioning, etc. That is, it may include any style in a series of methods for the front end to hide elements through styles, and the present disclosure does not make specific limitations on this.

[0088] Among them, a random number is generated according to the second random function, and a disguise style is selected from the disguise style database according to the random number as the target disguise style. The second random function may be the same as or different from the first random function and the third random function, and the present disclosure does not make specific limitations on this.

[0089] In an exemplary embodiment of the present disclosure, the front end inserts the buried point value into the block corresponding to the disguised data and controls the block to add the target disguise style. Specifically, the buried point value is dynamically inserted into the block corresponding to the disguised data by using the characteristics of dynamic attributes, and the block is controlled to add the target disguise style according to the second random function. Among them, the block includes the target position where the disguised data is located in the display page, that is, a mark is made at the target position of the disguised data according to the buried point value, and the target disguise style is added to the target position.

[0090] In an exemplary embodiment of the present disclosure, the front end can control each block corresponding to the camouflage data to randomly add a target camouflage style respectively, that is, each block corresponding to the camouflage data adds the target camouflage style according to the second random function. The target camouflage styles corresponding to each camouflage data can be the same or different, and the present disclosure does not make specific limitations on this.

[0091] In the anti-crawler method of the present disclosure, the back end can randomly encapsulate the page data according to the policy data to generate encapsulated page information without a fixed pattern. The front end can receive the encapsulated page information without a fixed pattern, generate a buried point value for the page information according to the encapsulated page information without a fixed pattern, and display a random style through the buried point value. Through the data interaction between the front end and the back end, no matter whether the crawler crawls the front-end data or the back-end data, it cannot grasp the pattern, improving the accuracy of anti-crawler.

[0092] In a specific embodiment of the present disclosure, the anti-crawler method is applied to an anti-crawler system. Figure 4 The structural schematic diagram of the anti-crawler system of the present disclosure is shown as Figure 4 As shown, the anti-crawler system 400 includes a policy center 401, a back end 402, and a front end 403, where:

[0093] The policy center 401 is used to configure policy data, that is, buried point fields, obfuscation algorithms, and preset data segments.

[0094] In an exemplary embodiment of the present disclosure, the policy center can use a third random function to randomly update the current buried point field, the current obfuscation algorithm, and the current preset data segment, and the policy center can also use the third random function to determine the time interval for each update.

[0095] The back end 402 is used to obtain the policy data of the policy center 401, determine the target data corresponding to the page information according to the preset data segment, and encapsulate the page information according to the policy data and the target data to obtain encapsulated page information, and send the encapsulated page information to the front end.

[0096] In an exemplary embodiment of the present disclosure, the back end obtains page information, where the page information includes multiple pieces of page data, and the page data includes real data and camouflage data. Configure the target data corresponding to the real data and the camouflage data according to the first random function and the preset data segment, and encapsulate the page information according to the target data and the policy data to generate encapsulated page information.

[0097] The front end 403 is used to determine the camouflage data in the page information according to the preset data segment and the target data, configure the buried point value according to the buried point field and the obfuscation algorithm, dynamically insert the buried point value into the camouflage data, and add a target camouflage style to render the camouflage data according to the target camouflage style to form HTML corresponding to the camouflage style.

[0098] In an exemplary embodiment of the present disclosure, the front end obtains target data in the encapsulated page information and determines whether the target data corresponding to the page data is within a preset data segment range; if the target data is within the preset data segment range, the page data is disguised data; if the target data is not within the preset data segment range, the page data is real data.

[0099] In an exemplary embodiment of the present disclosure, the front end determines a target disguise style database in the disguise style database according to a second random function, inserts the buried point value into the block corresponding to the disguised data, and controls the block corresponding to the disguised data to add the target disguise style.

[0100] In an embodiment of the present disclosure, an anti-crawler method is also proposed. Figure 5 The flowchart of the anti-crawler method is shown. It should be noted that the execution subject of the anti-crawler method in the embodiments of the present disclosure is the back end. As Figure 5 shown, the anti-crawler method at least includes the following steps:

[0101] In step S510, the page information is encapsulated according to the policy data to obtain the encapsulated page information, and the encapsulated page information is sent to the front end, where the policy data includes buried point fields, confusion algorithms, and preset data segments.

[0102] In an exemplary embodiment of the present disclosure, the page information includes multiple pieces of page data, and the page data includes real data and disguised data. The back end obtains the page information, as well as the buried point fields, confusion algorithms, and preset data segments; generates target data corresponding to the real data and the disguised data through a first random function and the preset data segment; and encapsulates the page information according to the target data and the policy data to generate the encapsulated page information.

[0103] Among them, generating target data corresponding to the real data and the disguised data through a first random function and the preset data segment includes: if the page data is real data, generating a first data within the preset data segment range through the first random function and configuring the first data as the target data corresponding to the real data; if the page data is disguised data, generating a second data within the preset data segment range through the first random function and configuring the second data as the target data corresponding to the disguised data.

[0104] In an exemplary embodiment of the present disclosure, the policy center updates the buried point fields, confusion algorithms, and preset data segments by using a third random function. Specifically, the policy center can randomly update the current buried point fields, the current confusion algorithm, and the current preset data segment by using the third random function, and the policy center can also use the third random function to determine the time interval for each update.

[0105] In step S520, the front end determines the disguised data in the encapsulated page information according to the preset data segment, and configures the buried point value according to the buried point field and the obfuscation algorithm.

[0106] In an exemplary embodiment of the present disclosure, the back end sends the encapsulated page information to the front end, the front end obtains the target data in the encapsulated page information, and the front end determines the disguised data in the encapsulated page information according to the target data and the preset data segment.

[0107] Among them, determining the disguised data in the encapsulated page information by the front end according to the target data and the preset data segment includes: the front end determines whether the target data is within the range of the preset data segment; if the target data is within the range of the preset data segment, it is determined that the page data corresponding to the target data is disguised data; if the target data is not within the range of the preset data segment, it is determined that the page data corresponding to the target data is real data.

[0108] In an exemplary embodiment of the present disclosure, the front end uses the obfuscation algorithm to process the buried point field to generate the buried point value. The buried point field is obfuscated according to the obfuscation algorithm corresponding to the disguised data to generate the buried point value, and the buried point value corresponds to the obfuscation algorithm and the buried point field. For example, if the obfuscation algorithm corresponding to the disguised data is the forward and reverse order algorithm and the buried point field is abc, then the forward and reverse order algorithm is used to process the buried point field abc, and the generated buried point value is cba.

[0109] In step S530, the front end adds the target disguise style of the disguised data according to the buried point value, and renders the disguised data according to the target disguise style.

[0110] In an exemplary embodiment of the present disclosure, the front end inserts the buried point value into the block corresponding to the disguised data, and controls the block to add the target disguise style, where the target disguise style is obtained from the disguise style database according to the second random function.

[0111] Specifically, the buried point value is dynamically inserted into the block corresponding to the disguised data by using the characteristics of dynamic attributes, and the block is controlled to add the target disguise style according to the second random function. Among them, the block includes the target position where the disguised data is located in the display page, that is, a mark will be made at the target position of the disguised data according to the buried point value, and the target disguise style will be added to the target position. In addition, the target disguise style is obtained from the disguise style database according to the second random function. The disguise style database may include various types in the hidden style List-style. For example, it may be set to display: none to hide, set the style to float and place it at the bottom of the page, or hide it using absolute positioning, etc. That is, it may include any style in a series of methods for the front end to hide elements by styles, and the present disclosure does not make specific limitations thereto.

[0112] It should be noted that the first random function, the second random function, and the third random function can be any random function that generates random numbers. For example, it can be the random function, or it can also be the rand function, the srand function, etc. The first random function, the second random function, and the third random function can be the same or different. The present disclosure does not make specific limitations on the first random function, the second random function, and the third random function.

[0113] In an embodiment of the present disclosure, an anti-crawler method is also proposed. Figure 6 The flowchart of the anti-crawler method is shown. It should be noted that the execution subject of the anti-crawler method in the embodiments of the present disclosure is the front end. As Figure 6 shown, the anti-crawler method at least includes the following steps:

[0114] In step S610, the encapsulated page information sent by the backend is received. The encapsulated page information is generated by encapsulating the page information according to the policy data, where the policy data includes buried point fields, confusion algorithms, and preset data segments.

[0115] In an exemplary embodiment of the present disclosure, the encapsulated page is generated by the backend encapsulating the page information according to the policy data. Specifically, the page data includes multiple pieces of page data, and the page data includes real data and disguised data. The backend obtains the page information, as well as the buried point fields, confusion algorithms, and preset data segments; generates target data corresponding to the real data and the disguised data through the first random function and the preset data segment; and encapsulates the page information according to the target data and the policy data to generate the encapsulated page information.

[0116] Among them, generating target data corresponding to the real data and the disguised data through the first random function and the preset data segment includes: if the page data is real data, generating a first data outside the range of the preset data segment through the first random function, and configuring the first data as the target data corresponding to the real data; if the page data is disguised data, generating a second data within the range of the preset data segment through the first random function, and configuring the second data as the target data corresponding to the disguised data.

[0117] In addition, the policy center updates the buried point fields, confusion algorithms, and preset data segments using the third random function. Specifically, the policy center can randomly update the current buried point fields, current confusion algorithms, and current preset data segments using the third random function, and the policy center can also use the third random function to determine the time interval for each update. In step S620, the disguised data is determined in the encapsulated page information according to the preset data segment, and the buried point value is configured according to the buried point field and the confusion algorithm.

[0118] In an exemplary embodiment of the present disclosure, after the front end receives the encapsulated page information sent by the back end, the front end obtains the target data in the encapsulated page information and determines the disguised data in the encapsulated page information according to the target data and the preset data segment.

[0119] Specifically, determining the disguised data in the encapsulated page information according to the target data and the preset data segment includes: judging whether the target data is within the range of the preset data segment; if the target data is within the range of the preset data segment, determining that the page data corresponding to the target data is disguised data; if the target data is not within the range of the preset data segment, determining that the page data corresponding to the target data is real data.

[0120] In an exemplary embodiment of the present disclosure, the front end processes the buried point field by using a confusion algorithm to generate a buried point value. Specifically, obtain the buried point field corresponding to the disguised data and the confusion algorithm, and process the buried point field by using the confusion algorithm corresponding to the disguised data to generate a buried point value corresponding to the disguised data.

[0121] In step S630, add the target disguise style of the disguised data according to the buried point value, and render the disguised data according to the target disguise style.

[0122] In an exemplary embodiment of the present disclosure, the front end inserts the buried point value into the block corresponding to the disguised data and controls the block to add the target disguise style, where the target disguise style is obtained from the disguise style database according to the second random function. The disguise style database may include various types in the hidden style List-style. For example, it may be set to display: none to hide, set the style to float and place it at the bottom of the page, or use absolute positioning to hide, etc. That is, it may include any style in a series of methods for the front end to hide elements through styles. The present disclosure does not make specific limitations on this. In addition, the block includes the target position where the disguised data is located in the display page, that is, a mark will be made at the target position of the disguised data according to the buried point value, and the target disguise style will be added to the target position.

[0123] Those skilled in the art can understand that all or part of the steps of implementing the above embodiments are implemented as a computer program executed by a CPU. When the computer program is executed by the CPU, the above functions defined by the above method provided by the present invention are executed. The program can be stored in a computer-readable storage medium, and the storage medium can be a read-only memory, a disk, an optical disc, etc.

[0124] In addition, it should be noted that the above-mentioned drawings are only schematic illustrations of the processes included in the method according to the exemplary embodiments of the present invention, rather than for restrictive purposes. It is easy to understand that the processes shown in the above-mentioned drawings do not indicate or limit the chronological order of these processes. Additionally, it is also easy to understand that these processes can be executed synchronously or asynchronously in, for example, multiple modules.

[0125] The following introduces the device embodiments of the present disclosure, which can be used to execute the above-mentioned anti-crawler method of the present disclosure. For details not disclosed in the device embodiments of the present disclosure, please refer to the embodiments of the above-mentioned anti-crawler method of the present disclosure.

[0126] Figure 7 The block diagram of an anti-crawler device according to an embodiment of the present disclosure is schematically shown.

[0127] Referring to Figure 7 As shown, the anti-crawler device 700 according to an embodiment of the present disclosure includes: a first encapsulation module 701, a first configuration module 702, and a first rendering module 703. Specifically:

[0128] The first encapsulation module 701 is used for the backend to encapsulate the page information according to the policy data to obtain the encapsulated page information, and send the encapsulated page information to the frontend, where the policy data includes buried point fields, obfuscation algorithms, and preset data segments;

[0129] The first configuration module 702 is used for the frontend to determine the disguise data in the encapsulated page information according to the preset data segment, and configure the buried point values according to the buried point fields and the obfuscation algorithm;

[0130] The first rendering module 703 is used for the frontend to add the target disguise style of the disguise data according to the buried point value, and render the disguise data according to the target disguise style.

[0131] In the exemplary embodiment of the present disclosure, the first encapsulation module 701 can also be used for the backend to encapsulate the page information according to the policy data to obtain the encapsulated page information, including: the backend obtains the page information, as well as the buried point fields, the obfuscation algorithm, and the preset data segment; generates target data corresponding to the real data and the disguise data through a first random function and the preset data segment; encapsulates the page information according to the target data and the policy data to generate the encapsulated page information, where the page information includes multiple page data, and the page data includes real data and disguise data.

[0132] In an exemplary embodiment of the present disclosure, the first encapsulation module 701 may also be used to generate target data corresponding to real data and disguised data through a first random function and a preset data segment, including: if the page data is real data, generating first data outside the range of the preset data segment through the first random function, and configuring the first data as the target data corresponding to the real data; if the page data is disguised data, generating second data within the range of the preset data segment through the first random function, and configuring the second data as the target data corresponding to the disguised data.

[0133] In an exemplary embodiment of the present disclosure, the first configuration module 702 may also be used for the front end to determine disguised data in the encapsulated page information according to the preset data segment, including: the front end obtains the target data in the encapsulated page information, and determines the disguised data in the encapsulated page information according to the target data and the preset data segment.

[0134] In an exemplary embodiment of the present disclosure, the first configuration module 702 may also be used to determine disguised data in the encapsulated page information according to the target data and the preset data segment, including: determining whether the target data is within the range of the preset data segment: if so, determining that the page data corresponding to the target data is disguised data; if not, determining that the page data corresponding to the target data is real data.

[0135] In an exemplary embodiment of the present disclosure, the first configuration module 702 may also be used for the front end to configure the buried point value according to the buried point field and the obfuscation algorithm, including: the front end processes the buried point field by using the obfuscation algorithm to generate the buried point value.

[0136] In an exemplary embodiment of the present disclosure, the first rendering module 703 may also be used for the front end to add a target disguise style to the disguised data according to the buried point value, including: the front end inserts the buried point value into the block corresponding to the disguised data, and controls the block to add the target disguise style, where the target disguise style is obtained from the disguise style database according to the second random function.

[0137] In an exemplary embodiment of the present disclosure, the anti-crawler device 700 further includes a first update module (not shown in the figure), which is used for the policy center to update the buried point field, the obfuscation algorithm, and the preset data segment by using a third random function.

[0138] The specific details of the above anti-crawler devices have been described in detail in the corresponding anti-crawler methods, so they will not be elaborated here.

[0139] The following introduces another device embodiment of the present disclosure, which can be used to execute the above anti-crawler method of the present disclosure. For the details not disclosed in the device embodiment of the present disclosure, please refer to the embodiment of the above anti-crawler method of the present disclosure.

[0140] Figure 8A block diagram of an anti-crawler device according to an embodiment of the present disclosure is schematically shown.

[0141] Referring to Figure 8 As shown, the anti-crawler device 800 according to an embodiment of the present disclosure, the anti-crawler device 800 includes: a second encapsulation module 801, a second configuration module 802, and a second rendering module 803. Specifically:

[0142] The second encapsulation module 801 is configured to encapsulate page information according to policy data to obtain encapsulated page information, and send the encapsulated page information to the front end, where the policy data includes buried point fields, obfuscation algorithms, and preset data segments;

[0143] The second configuration module 802 is configured to determine camouflage data in the encapsulated page information by the front end according to the preset data segment, and configure the buried point value according to the buried point field and the obfuscation algorithm;

[0144] The second rendering module 803 is configured to add a target camouflage style of the camouflage data by the front end according to the buried point value, and render the camouflage data according to the target camouflage style.

[0145] In an exemplary embodiment of the present disclosure, the second encapsulation module 801 may also be configured to encapsulate page information according to policy data to obtain encapsulated page information, including: obtaining page information, and buried point fields, obfuscation algorithms, and preset data segments; generating target data corresponding to real data and camouflage data through a first random function and the preset data segment; encapsulating the page information according to the target data and the policy data to generate encapsulated page information, where the page information includes multiple page data, and the page data includes real data and camouflage data.

[0146] In an exemplary embodiment of the present disclosure, the second encapsulation module 801 may also be configured to generate target data corresponding to real data and camouflage data through a first random function and the preset data segment, including: if the page data is real data, generating a first data outside the preset data segment range through the first random function, and configuring the first data as the target data corresponding to the real data; if the page data is camouflage data, generating a second data within the preset data segment range through the first random function, and configuring the second data as the target data corresponding to the camouflage data.

[0147] In an exemplary embodiment of the present disclosure, the second configuration module 802 may also be configured to determine camouflage data in the encapsulated page information by the front end according to the preset data segment, including: obtaining the target data in the encapsulated page information by the front end, and determining the camouflage data in the encapsulated page information according to the target data and the preset data segment.

[0148] In an exemplary embodiment of the present disclosure, the second configuration module 802 may further be configured to determine spoofing data in the encapsulated page information according to target data and a preset data segment, including: judging by the front end whether the target data is within the range of the preset data segment: if so, determining that the page data corresponding to the target data is spoofing data; if not, determining that the page data corresponding to the target data is real data.

[0149] In an exemplary embodiment of the present disclosure, the second configuration module 802 may further be configured to configure the buried point value by the front end according to the buried point field and the obfuscation algorithm, including: processing the buried point field by the front end using the obfuscation algorithm to generate the buried point value.

[0150] In an exemplary embodiment of the present disclosure, the second rendering module 803 may further be configured to add a target spoofing style of the spoofing data by the front end according to the buried point value, including: inserting the buried point value into the block corresponding to the spoofing data by the front end, and controlling the block to add the target spoofing style, where the target spoofing style is obtained from the spoofing style database according to the second random function.

[0151] In an exemplary embodiment of the present disclosure, the anti-crawler device 800 further includes a second update module (not shown in the figure), configured to update the buried point field, the obfuscation algorithm, and the preset data segment by the policy center using a third random function.

[0152] The specific details of the above anti-crawler devices have been described in detail in the corresponding anti-crawler methods, so they will not be elaborated here. The following introduces another device embodiment of the present disclosure, which can be used to execute the above anti-crawler method of the present disclosure. For the details not disclosed in the device embodiment of the present disclosure, please refer to the embodiment of the above anti-crawler method of the present disclosure.

[0153] Figure 9 A block diagram of an anti-crawler device according to an embodiment of the present disclosure is schematically shown.

[0154] Refer to Figure 9 As shown, an anti-crawler device 900 according to an embodiment of the present disclosure, the anti-crawler device 900 includes: a third encapsulation module 901, a third configuration module 902, and a third rendering module 903. Specifically:

[0155] The third encapsulation module 901 is configured to receive the encapsulated page information sent by the backend, where the encapsulated page information is generated by encapsulating the page information according to the policy data, and the policy data includes a buried point field, an obfuscation algorithm, and a preset data segment;

[0156] The third configuration module 902 is configured to determine spoofing data in the encapsulated page information according to the preset data segment, and configure the buried point value according to the buried point field and the obfuscation algorithm;

[0157] The third rendering module 903 is configured to add a target disguise style to the disguise data according to the buried point value, and render the disguise data according to the target disguise style.

[0158] In an exemplary embodiment of the present disclosure, the third encapsulation module 901 may further be configured to obtain page information, as well as buried point fields, an obfuscation algorithm, and a preset data segment through the backend; generate target data corresponding to the real data and the disguise data through a first random function and the preset data segment; encapsulate the page information according to the target data and the policy data to generate encapsulated page information, where the page information includes multiple pieces of page data, and the page data includes real data and disguise data.

[0159] In an exemplary embodiment of the present disclosure, the third encapsulation module 901 may further be configured to generate target data corresponding to the real data and the disguise data through a first random function and the preset data segment, including: if the page data is real data, generate first data outside the range of the preset data segment through the first random function, and configure the first data as the target data corresponding to the real data; if the page data is disguise data, generate second data within the range of the preset data segment through the first random function, and configure the second data as the target data corresponding to the disguise data.

[0160] In an exemplary embodiment of the present disclosure, the third configuration module 902 may further be configured to determine disguise data in the encapsulated page information according to the preset data segment, including: obtaining the target data in the encapsulated page information, and determining the disguise data in the encapsulated page information according to the target data and the preset data segment.

[0161] In an exemplary embodiment of the present disclosure, the third configuration module 902 may further be configured to determine disguise data in the encapsulated page information according to the target data and the preset data segment, including: determining whether the target data is within the range of the preset data segment: if so, determining that the page data corresponding to the target data is disguise data; if not, determining that the page data corresponding to the target data is real data.

[0162] In an exemplary embodiment of the present disclosure, the third configuration module 902 may further be configured to configure the buried point value according to the buried point field and the obfuscation algorithm, including: processing the buried point field by using the obfuscation algorithm to generate the buried point value.

[0163] In an exemplary embodiment of the present disclosure, the third rendering module 903 may further be configured to add a target disguise style to the disguise data according to the buried point value, including: inserting the buried point value into the block corresponding to the disguise data, and controlling the block to add the target disguise style, where the target disguise style is obtained from the disguise style database according to a second random function.

[0164] In an exemplary embodiment of the present disclosure, the anti-crawler device 900 further includes a third update module (not shown in the figure), which is used to update the buried point fields, obfuscation algorithms, and preset data segments through the policy center by using a third random function.

[0165] The specific details of each of the above anti-crawler devices have been described in detail in the corresponding anti-crawler method, and thus will not be elaborated here.

[0166] It should be noted that although several modules or units of the devices for execution are mentioned in the above detailed description, this division is not mandatory. In fact, according to the embodiments of the present disclosure, the features and functions of two or more of the above-mentioned modules or units can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided and embodied by multiple modules or units.

[0167] In an exemplary embodiment of the present disclosure, an electronic device capable of implementing the above method is also provided.

[0168] Those skilled in the art to which the present invention pertains can understand that various aspects of the present invention can be implemented as a system, a method, or a program product. Therefore, various aspects of the present invention can be specifically implemented in the following forms, namely: a complete hardware implementation, a complete software implementation (including firmware, microcode, etc.), or an implementation combining hardware and software aspects, which can be collectively referred to herein as "circuitry", "module", or "system".

[0169] The following refers to Figure 10 to describe the electronic device 1000 according to this embodiment of the present invention. Figure 10 The electronic device 1000 shown is merely an example and should not impose any limitation on the functions and usage scope of the embodiments of the present invention.

[0170] As Figure 10 shown, the electronic device 1000 is presented in the form of a general-purpose computing device. The components of the electronic device 1000 may include, but are not limited to: at least one of the above-mentioned processing units 1010, at least one of the above-mentioned storage units 1020, a bus 1030 connecting different system components (including the storage unit 1020 and the processing unit 1010), and a display unit 1040.

[0171] Among them, the storage unit stores program codes, and the program codes can be executed by the processing unit 1010, so that the processing unit 1010 executes the steps according to various exemplary embodiments of the present invention described in the above "Exemplary Method" section of this specification. For example, the processing unit 1010 can execute as Figure 1In step S110 shown in the figure, the backend encapsulates the page data according to the policy data to obtain the encapsulated page data, and sends the encapsulated page data to the frontend. The policy data includes buried point fields, an obfuscation algorithm, and preset data segments. In step S120, the frontend configures the buried point values according to the buried point fields and the obfuscation algorithm, and determines the disguise style according to the buried point values. In step S130, the frontend determines the disguise data in the encapsulated page data according to the preset data segments, and renders the disguise data according to the disguise style.

[0172] The storage unit 1020 may include a readable medium in the form of a volatile storage unit, such as a random access storage unit (RAM) 10201 and / or a cache storage unit 10202, and may further include a read only storage unit (ROM) 10203.

[0173] The storage unit 1020 may further include a program / utilities 10204 having a set (at least one) of program modules 10205. Such program modules 10205 include, but are not limited to: an operating system, one or more application programs, other program modules, and program data. Each or some combination of these examples may include an implementation of a network environment.

[0174] The bus 1030 may represent one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus structures.

[0175] The electronic device 1000 may also communicate with one or more external devices 1200 (such as a keyboard, a pointing device, a Bluetooth device, etc.), may also communicate with one or more devices that enable a viewer to interact with the electronic device 1000, and / or may communicate with any device that enables the electronic device 1000 to communicate with one or more other computing devices (such as a router, a modem, etc.). Such communication may be through an input / output (I / O) interface 1050. And, the electronic device 1100 may also communicate with one or more networks (such as a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) through a network adapter 1060. As shown in the figure, the network adapter 1060 communicates with other modules of the electronic device 1000 through the bus 1030. It should be understood that although not shown in the figure, other hardware and / or software modules may be used in conjunction with the electronic device 1000, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, etc.

[0176] Based on the descriptions of the above embodiments, those skilled in the art can easily understand that the exemplary embodiments described herein can be implemented by software or by a combination of software and necessary hardware. Therefore, the technical solutions according to the embodiments of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (such as a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, including several instructions to enable a computing device (such as a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the embodiments of the present disclosure.

[0177] In an exemplary embodiment of the present disclosure, there is also provided a computer-readable storage medium having a program product stored thereon that can implement the above method of this specification. In some possible implementation manners, various aspects of the present invention can also be implemented in the form of a program product, which includes program code. When the program product runs on a terminal device, the program code is used to cause the terminal device to execute the steps according to various exemplary embodiments of the present invention described in the above "Exemplary Method" section of this specification.

[0178] Reference Figure 11 As shown, a program product 1100 for implementing the above method according to an embodiment of the present invention is described. It can be a portable compact disc read-only memory (CD-ROM) and includes program code, and can run on a terminal device, such as a personal computer. However, the program product of the present invention is not limited thereto. In this document, the readable storage medium can be any tangible medium that contains or stores a program that can be used by or in combination with an instruction execution system, apparatus, or device.

[0179] The program product can adopt any combination of one or more readable media. The readable medium can be a readable signal medium or a readable storage medium. The readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the above. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection having one or more wires, a portable 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 disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.

[0180] A computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which readable program code is carried. Such a propagated data signal may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the foregoing. The readable signal medium may also be any readable medium other than a readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device.

[0181] The program code contained on the readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wired, optical fiber cable, RF, etc., or any suitable combination of the foregoing.

[0182] The program code for performing the operations of the present invention may be written in any combination of one or more programming languages, including object-oriented programming languages such as Java, C++, etc., and also including conventional procedural programming languages such as the "C" language or similar programming languages. The program code may be executed entirely on the user's computing device, partially on the user's device, executed as a stand-alone software package, partially on the user's computing device and partially on a remote computing device, or entirely on a remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user's computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device (e.g., by connecting through the Internet using an Internet service provider).

[0183] In addition, the above drawings are only schematic illustrations of the processes included in the method according to the exemplary embodiments of the present invention and are not for limiting purposes. It is easy to understand that the processes shown in the above drawings do not indicate or limit the chronological order of these processes. Additionally, it is also easy to understand that these processes may be executed synchronously or asynchronously, for example, in multiple modules.

[0184] Those skilled in the art will readily conceive of other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of the present disclosure that follow the general principles of the present disclosure and include known common knowledge or conventional technical means in the technical field not disclosed in the present disclosure. The specification and embodiments are only to be considered exemplary, and the true scope and spirit of the present disclosure are pointed out by the claims.

[0185] It should be understood that the present disclosure is not limited to the exact structures described above and shown in the drawings, and various modifications and changes can be made without departing from its scope. The scope of the present disclosure is only limited by the appended claims.

Claims

1. A method for preventing web crawlers, characterized in that, Including: The backend encapsulates the page information according to the policy data to obtain the encapsulated page information, and sends the encapsulated page information to the frontend, where the policy data includes buried point fields, obfuscation algorithms, and preset data segments; The frontend determines the disguised data in the encapsulated page information according to the preset data segment, and configures the buried point value according to the buried point fields and the obfuscation algorithm; The frontend adds the target disguise style of the disguised data according to the buried point value, and renders the disguised data according to the target disguise style.

2. The method for preventing web crawlers according to claim 1, characterized in that, The page information includes multiple pieces of page data, and the page data includes real data and the disguised data; The backend encapsulates the page information according to the policy data to obtain the encapsulated page information, including: The backend obtains the page information, as well as the buried point fields, the obfuscation algorithm, and the preset data segment; Generates target data corresponding to the real data and the disguised data through a first random function and the preset data segment; Encapsulates the page information according to the target data and the policy data to generate the encapsulated page information.

3. The method for preventing web crawlers according to claim 2, characterized in that, Generating target data corresponding to the real data and the disguised data through a first random function and the preset data segment, including: If the page data is the real data, generate a first data outside the range of the preset data segment through the first random function, and configure the first data as the target data corresponding to the real data; If the page data is the disguised data, generate a second data within the range of the preset data segment through the first random function, and configure the second data as the target data corresponding to the disguised data.

4. The method for preventing web crawlers according to claim 3, characterized in that, The frontend determines the disguised data in the encapsulated page information according to the preset data segment, including: The frontend obtains the target data in the encapsulated page information, and determines the disguised data in the encapsulated page information according to the target data and the preset data segment.

5. The method for preventing web crawlers according to claim 4, characterized in that, Determining the disguised data in the encapsulated page information according to the target data and the preset data segment, including: Judge whether the target data is within the range of the preset data segment: If so, determine that the page data corresponding to the target data is the disguised data; If not, determine that the page data corresponding to the target data is the real data.

6. The method for preventing web crawlers according to claim 1, characterized in that, The frontend configures the buried point value according to the buried point fields and the obfuscation algorithm, including: The frontend processes the buried point fields by using the obfuscation algorithm to generate the buried point value.

7. The method for preventing web crawlers according to claim 1, characterized in that, The frontend adds the target disguise style of the disguised data according to the buried point value, including: The frontend inserts the buried point value into the block corresponding to the disguised data, and controls the block to add the target disguise style, where the target disguise style is obtained from the disguise style database according to a second random function.

8. The method for preventing web crawlers according to claim 1, characterized in that, The method further includes: The policy center updates the buried point fields, the obfuscation algorithm, and the preset data segment by using a third random function.

9. A method for preventing web crawlers, characterized in that, Including: Encapsulate the page information according to the policy data to obtain the encapsulated page information, and send the encapsulated page information to the front end, where the policy data includes buried point fields, obfuscation algorithms, and preset data segments; The front end determines the disguised data in the encapsulated page information according to the preset data segment, and configures the buried point value according to the buried point field and the obfuscation algorithm; The front end adds the target disguise style of the disguised data according to the buried point value, and renders the disguised data according to the target disguise style.

10. A method for preventing web crawlers, characterized in that, It includes: Receive the encapsulated page information sent by the back end, which is generated by encapsulating the page information according to the policy data, where the policy data includes buried point fields, obfuscation algorithms, and preset data segments; Determine the disguised data in the encapsulated page information according to the preset data segment, and configure the buried point value according to the buried point field and the obfuscation algorithm; Add the target disguise style of the disguised data according to the buried point value, and render the disguised data according to the target disguise style.

11. A anti-crawler device, characterized in that, It includes: The first encapsulation module is used for the back end to encapsulate the page information according to the policy data to obtain the encapsulated page information, and send the encapsulated page information to the front end, where the policy data includes buried point fields, obfuscation algorithms, and preset data segments; The first configuration module is used for the front end to determine the disguised data in the encapsulated page information according to the preset data segment, and configure the buried point value according to the buried point field and the obfuscation algorithm; The first rendering module is used for the front end to add the target disguise style of the disguised data according to the buried point value, and render the disguised data according to the target disguise style.

12. A anti-crawler device, characterized in that, It includes: The second encapsulation module is used for encapsulating the page information according to the policy data to obtain the encapsulated page information, and sending the encapsulated page information to the front end, where the policy data includes buried point fields, obfuscation algorithms, and preset data segments; The second configuration module is used for the front end to determine the disguised data in the encapsulated page information according to the preset data segment, and configure the buried point value according to the buried point field and the obfuscation algorithm; The second rendering module is used for the front end to add the target disguise style of the disguised data according to the buried point value, and render the disguised data according to the target disguise style.

13. A anti-crawler device, characterized in that, It includes: The third encapsulation module is used for receiving the encapsulated page information sent by the back end, which is generated by encapsulating the page information according to the policy data, where the policy data includes buried point fields, obfuscation algorithms, and preset data segments; The third configuration module is used for the front end to determine the disguised data in the encapsulated page information according to the preset data segment, and configure the buried point value according to the buried point field and the obfuscation algorithm; The third rendering module is used for the front end to add the target disguise style of the disguised data according to the buried point value, and render the disguised data according to the target disguise style.

14. A computer-readable storage medium, on which a computer program is stored, characterized in that, When the program is executed by a processor, it implements the anti-crawler method according to any one of claims 1 to 10.

15. An electronic device, characterized in that, It includes: One or more processors; A storage device for storing one or more programs, which, when executed by the one or more processors, cause the one or more processors to implement the anti-crawler method according to any one of claims 1 to 10.

Citation Information

Patent Citations

  • Network attack protection method and device, electronic equipment and medium

    CN110049035A

  • Buried point data processing method and device, equipment and storage medium

    CN110727572A