Website security protection method and device based on sensitive information, equipment and medium
By pre-calculating and detecting the sensitivity of web page content and finding and distributing content in the local content distribution database, the problem of inability to effectively detect and monitor sensitive words in web page content in the prior art is solved, and the website security protection capabilities are improved The effect of access speed.
Patent Information
- Application Number
- CN202411347418.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-26
- Publication Date
- 2025-02-07
- Estimated Expiration
- 2044-09-26
AI Technical Summary
Existing website security technology cannot effectively detect whether there are sensitive words in web page content, and the real-time monitoring and review capabilities of web page content are insufficient, resulting in the inability to effectively protect the health of the network environment.
By pre-requesting the content of the source site and calculating the sensitivity, the sensitivity detection of web page content is realized, and the web page content is found and distributed in the pre-stored content distribution database is avoided requesting content from the source site and reviewing it.
It improves the security protection capability and access speed of the website, reduces the overhead of sensitive detection, reduces the load on the source site, and realizes rapid monitoring and audit of web page content.
Smart Images

Figure CN119402226A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of network security technology, and more specifically, to a website security protection method, device, equipment and medium based on sensitive information. Background Art
[0002] Sensitive words refer to words or uncivilized language with sensitive political tendencies, violent tendencies, unhealthy overtones, or uncivilized language. With the development and popularization of Internet technology, a large number of problematic web pages with sensitive political tendencies, violent tendencies, unhealthy overtones, or uncivilized language have appeared. Therefore, it is imperative to maintain a healthy online environment.
[0003] Related website security technologies can only intercept attack requests and cannot detect whether there are sensitive words in the web page content; at the same time, normal requests need to request the web page content from the source server in real time before returning it to the user. Therefore, it is urgent to provide a website security protection technology that can both detect the sensitivity of web page content and improve access speed. Summary of the invention
[0004] In view of this, one of the technical problems solved by the embodiments of the present application is to provide a website security protection method, device, equipment and medium based on sensitive information, which improves the website security protection capability and access speed by pre-requesting source site content and calculating sensitivity.
[0005] In a first aspect of the embodiments of the present application, a website security protection method based on sensitive information is disclosed, the method comprising:
[0006] Based on the web page access request initiated by the client, determine the access URL of the target web page pointed to by the web page access request;
[0007] Determine the webpage content type corresponding to the visited URL;
[0008] If the webpage content type is static content, the sensitivity of the static content is determined based on the correspondence between the pre-stored URL and its sensitivity;
[0009] If the sensitivity of the static content is less than a preset sensitivity value threshold, the target webpage content of the target webpage is determined in a pre-stored content distribution database, and the target webpage content is sent to the client so that the client displays the target webpage content.
[0010] In a second aspect of the embodiment of the present application, a website security protection device based on sensitive information is disclosed, the device comprising:
[0011] A request URL determination module is used to determine the access URL of the target web page pointed to by the web page access request based on the web page access request initiated by the client;
[0012] A content type determination module, used to determine the webpage content type corresponding to the accessed URL;
[0013] A static sensitivity module, for determining the sensitivity of the static content according to the correspondence between the pre-stored URL and its sensitivity if the webpage content type is static content;
[0014] The security protection processing module is used to determine the target web page content of the target web page in the pre-stored content distribution database if the sensitivity of the static content is less than the preset sensitivity value threshold, and send the target web page content to the client so that the client can display the target web page content.
[0015] In a third aspect of an embodiment of the present application, an electronic device is disclosed. The electronic device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the above method are implemented.
[0016] In a fourth aspect of the embodiments of the present application, a computer-readable storage medium is disclosed, which stores a computer program. When the computer program is executed by a processor, the steps of the above method are implemented.
[0017] The present application has the following advantages: by determining the web page content type of the access URL of the target web page pointed to by the web page access request initiated by the client, and in the case where the web page content type is static content, the sensitivity of the static content is determined according to the correspondence between the pre-stored URL and its sensitivity. If the sensitivity of the static content is less than the preset sensitivity value threshold, the target web page content of the target web page is determined in the pre-stored content distribution database, and the target web page content is sent to the client, so that the client can display the target web page content. This method of pre-calculating the sensitivity of the website content can quickly determine the sensitivity of the access URL, and can directly find the corresponding web page content locally under the condition of meeting the response to the client request. Not only does it not need to request web page content from the source station, but it also does not need to review its web page content. It not only improves the website protection capability, reduces the overhead of sensitive detection, and achieves the purpose of reducing time complexity, but also realizes the content distribution from the source station to the website security protection end, solving the problem that the source station is heavily loaded, has a slow response speed, and cannot monitor and review the web page content due to the content distribution being the responsibility of the source station. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] Figure 1 A schematic diagram of a process flow of a website security protection method based on sensitive information provided by an embodiment of the present application;
[0019] Figure 2 A flowchart of a website security protection method based on sensitive information provided by another embodiment of the present application;
[0020] Figure 3 A flowchart of a website security protection method based on sensitive information provided by another embodiment of the present application;
[0021] Figure 4 A schematic diagram of a timing flow of a website security protection method based on sensitive information provided in yet another embodiment of the present application;
[0022] Figure 5 A schematic diagram of the structure of a website security protection device based on sensitive information provided by one embodiment of the present application. DETAILED DESCRIPTION
[0023] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0024] It should be noted that although the functional modules are divided in the device schematic and the logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the device or the order in the flowchart.
[0025] In order to make the objectives, technical solutions and advantages of the present application clearer, the implementation methods of the present application will be further described in detail below in conjunction with the accompanying drawings.
[0026] According to an embodiment of the present application, a website security protection method based on sensitive information is provided, such as Figure 1 As shown, the method includes steps S101 to S104.
[0027] Step S101: based on a web page access request initiated by a client, determining an access URL of a target web page pointed to by the web page access request.
[0028] Step S102: Determine the webpage content type corresponding to the accessed URL.
[0029] In the embodiment of the present application, the web page content type includes static content and dynamic content, and the two types are used to distinguish whether the web page display content changes with time, environment or database operation.
[0030] Specifically, the webpage content type can be determined according to the predefined type identifiers of different URLs, or can be determined by reading the format of the file corresponding to the URL pre-stored locally. For example, if the webpage file is an html format file, a js format file, a css format file, a jpg format file, etc., the webpage content type can be determined to be static content; if the webpage file is an asp format file or a php format file, the webpage content type can be determined to be dynamic content.
[0031] Step S103: If the webpage content type is static content, the sensitivity of the static content is determined according to the pre-stored correspondence between the URL and its sensitivity.
[0032] In specific implementation, the correspondence between all URLs and their sensitivity can be cached, or only URLs with high sensitivity can be stored. When applied, if the correspondence records all websites and their sensitivity, the sensitivity of the target web page can be queried in the correspondence for the access URL, so as to meet the sensitivity requirements of different scenarios for whether to perform interception. When applied, if the correspondence records a URL with a sensitivity higher than the sensitivity threshold, and the access URL of the target web page hits the URL included in the correspondence, it can be directly determined that the target web page needs to be intercepted, that is, the interception process is performed in step S104.
[0033] Step S104: if the sensitivity of the static content is less than a preset sensitivity threshold, the target webpage content of the target webpage is determined in a pre-stored content distribution database, and the target webpage content is sent to the client so that the client displays the target webpage content.
[0034] Specifically, the content distribution database may be stored in one or more pre-configured storage nodes. When applied, the webpage contents of different webpages may be stored according to the source station, and may be stored according to the website or website identifier.
[0035] The embodiment of the present application stores the web page content requested from the source site in advance locally, so that when the sensitivity of the static content is less than the preset sensitivity threshold, the content is distributed directly from the local side, thereby delegating the content distribution business of the source site to the web page request protection end, which not only reduces the load of the source site but also improves the response speed to the request, thereby achieving the purpose of improving the user's access experience.
[0036] The embodiment of the present application determines the web page content type of the access URL of the target web page pointed to by the web page access request initiated by the client, and when the web page content type is static content, determines the sensitivity of the static content according to the correspondence between the pre-stored URL and its sensitivity. If the sensitivity of the static content is less than the preset sensitivity value threshold, the target web page content of the target web page is determined in the pre-stored content distribution database, and the target web page content is sent to the client, so that the client displays the target web page content. This method of pre-calculating the sensitivity of the website content can quickly determine the sensitivity of the access URL, and can directly find the corresponding web page content locally under the condition of meeting the response to the client request. Not only does it not need to request the web page content from the source station, but it also does not need to review its web page content. It not only improves the website protection capability, reduces the overhead of sensitive detection, and achieves the purpose of reducing time complexity, but also realizes the content distribution from the source station to the website security protection end, solves the problem that the source station is heavily loaded, responds slowly, and cannot monitor and review the web page content due to the source station being responsible for content distribution.
[0037] In some embodiments, before step S103, the method further includes:
[0038] Step S1031 (not shown in the figure): sending a static content acquisition request to different URL source sites;
[0039] Step S1032 (not shown in the figure): obtaining static response files fed back by the URL source stations corresponding to different web pages in response to the static content acquisition request;
[0040] Step S1033 (not shown in the figure): determining the sensitivity scores of the texts and images included in the static response files fed back by the URL source stations corresponding to the different web pages in response to the static content acquisition request;
[0041] Step S1034 (not shown): The sensitivity scores of the texts and images included in the static response files fed back by the URL source stations corresponding to the different web pages in response to the static content acquisition request are added and calculated to obtain the sensitivity of the static content of the different web pages.
[0042] Specifically, a static content acquisition request can be sent to different URL source sites according to a predetermined strategy (such as every 48 hours) to obtain a real-time updated static response file, thereby executing steps S1031 to S1034 to obtain the sensitivity of different web pages and store them, and then obtain the sensitivity of the static content of the target web page through query, shorten the sensitivity determination time, and improve the efficiency of web page content sensitivity detection. When applied, the web page content can include text, or text and images, or only images. In specific implementation, if the web page content includes audio, the audio can be converted into text to calculate the sensitivity of the text; if the web page content includes video, the sum of the sensitivities of each video frame image can be used as the sensitivity of the video.
[0043] In some embodiments, determining the sensitivity scores of the texts included in the static response files fed back by the URL source stations corresponding to the different web pages in response to the static content acquisition request in step S104 includes:
[0044] Using multiple preset regular expressions for sensitive content, extract the text included in the static response file fed back by the URL source station corresponding to different web pages in response to the static content acquisition request, and obtain the sensitive content corresponding to each of the several URLs;
[0045] Perform word segmentation on the sensitive contents corresponding to the respective URLs, and obtain a second array including the respective URLs and their respective sensitive word segmentation sets according to the word segmentation results;
[0046] Determine a first array including website identifiers and corresponding website addresses;
[0047] Determine, based on the first array and the second array, a set of URL identifiers including a plurality of segmented words and their respective corresponding ones;
[0048] If any word hits the preset sensitive word library, the word is determined as a sensitive word, and a number of URLs and their corresponding sensitive word sets are obtained according to each sensitive word hit and determined in the sensitive word library;
[0049] The sensitivity of each of the several URLs is determined according to the sensitivity scores of each sensitive word in the several URLs and their corresponding sensitive word sets.
[0050] Specifically, it may include a regular expression that matches at least one of Chinese, English, letters, etc. The embodiment of the present application provides Chinese regular expressions, English regular expressions, and letter regular expressions, and simultaneously extracts content from the text to obtain sensitive content that may be included in the text.
[0051] Specifically, any word segmentation algorithm can be used to segment text for sensitive content. When applied, the Jieba word segmentation algorithm can be used for processing, such as taking each character in the Chinese text as the initial state, and initializing the state transition table and the result table; according to the known corpus, the probability of occurrence between adjacent characters is counted to construct a state transition table; starting from the initial state, the maximum probability word segmentation result of each state is calculated step by step according to the state transition table, and the result table is updated; finally, the final word segmentation result is extracted according to the result table. In addition, when applied, the sensitive content corresponding to each of the several web addresses is segmented to obtain the respective word segments corresponding to the several web addresses. At this time, each web address may correspond to multiple same word segments. In order to make each word segmented corresponding to each web address unique, the hash values of the respective word segments corresponding to the several web addresses can also be used for deduplication processing. After deduplication processing, the word segmentation phrases corresponding to the several web addresses are obtained, for example, {word segmentation 1, word segmentation 2...word segmentation n}, and the word segmentation and its corresponding web address identifier are used to construct a key-value pair to obtain a second array, for example, the second array is word segmentation 1 {web address identifier 1, web address identifier 2...web address identifier n}.
[0052] Specifically, the sensitivity scores corresponding to each sensitive word in the sensitive word set can be added and calculated to obtain a total sensitivity score, which is used as the sensitivity. When applied, the sensitivity scores corresponding to each sensitive word in the sensitive word set can also be input into a preset sensitivity calculation model, and the output of the model can be used as the sensitivity. For example, the static content sensitivity of a web page is S=ax+by, where a and b are weight coefficients, x is the text sensitivity score, and y is the image sensitivity score.
[0053] The embodiment of the present application provides a regular expression to extract the three contents in which sensitive words may appear, namely Chinese characters, English and numbers, thereby reducing useless matches and eliminating ambiguous matches, and uses network identifiers to replace URLs to save space, uses an inverted index to save the relationship between URLs and segmented words, uses a hash algorithm to remove repeated segmented words in the same URL, removes repeated segmented words between different URLs through a hash algorithm and a union method, and determines whether a segmented word hits a preset sensitive word library by counting and taking intersections, thereby achieving the purpose of restoring the sensitive words hit by the URL through a forward index.
[0054] In some embodiments, determining the sensitivity scores of images included in the static response files fed back by the URL source stations corresponding to the different web pages in response to the static content acquisition request in step S104 includes:
[0055] Extract features of images included in static response files fed back by URL source stations corresponding to different web pages in response to static content acquisition requests, and obtain image feature matrices corresponding to different web pages;
[0056] Calculate the similarity between the image feature matrices corresponding to different web pages and the feature matrices of several sensitive images;
[0057] The image sensitivity of different web pages is determined based on the similarity calculation results.
[0058] Specifically, the image can be input into a pre-built image feature extraction model, and the image feature matrix can be obtained according to the output of the image feature extraction model. When applied, the image can be standardized first so that the image of the input image feature matrix meets the input requirements. For example, the image is guaranteed to be 5*5 in size through standardization. The image feature extraction model is a CNN model. The CNN model uses a 3*3 convolution kernel to perform a convolution operation on the standardized image to obtain a feature mapping matrix.
[0059] In some embodiments, step S102 further includes at least one of the following steps:
[0060] Based on the webpage content file formats corresponding to the pre-stored plurality of webpages, respectively, determining the webpage content file type pointed to by the webpage content file format corresponding to the accessed webpage;
[0061] The access identifier is converted into a website identifier, and the webpage content type is determined according to the webpage content types corresponding to the pre-stored multiple website identifiers.
[0062] When applied, the corresponding web page file can be determined according to the accessed URL. For example, if the accessed URL is zh ihu.com / abc.html, then the web page content file is abc.html, and its web page content file type is a static web page; for another example, if the accessed URL is zh ihu.com / abc.php, its web page content file is abc.php, and its web page content type is a dynamic web page. Alternatively, the web page content types corresponding to different URLs can be pre-stored, so that the web page content type of the target web page can be obtained by URL matching. More specifically, the hash value of the accessed URL can be calculated first, and the hash value can be queried in the hash value table pre-stored in different URLs, so that the web page content type corresponding to the queried hash value can be used as the web page content type of the target web page.
[0063] When applied, the correspondence between the URL and the webpage content file format displayed on the page can be pre-stored, and the webpage content file format corresponding to the accessed URL can be quickly found through this correspondence, so as to determine the webpage content file type. For example, if the webpage file is an html format file, a js format file, a css format file, a jpg format file, etc., the webpage content type can be determined to be static content; if the webpage file is an asp format file or a php format file, the webpage content type can be determined to be dynamic content.
[0064] According to an embodiment of the present application, a website security protection method based on sensitive information is provided, such as Figure 2 As shown, the method includes:
[0065] Step S201: based on a web page access request initiated by a client, determining an access URL of a target web page pointed to by the web page access request;
[0066] Step S202: Determine the webpage content type corresponding to the accessed URL;
[0067] Step S203: If the webpage content type is static content, the sensitivity of the static content is determined according to the pre-stored correspondence between the URL and its sensitivity;
[0068] Step S205: If the sensitivity of the static content is not less than the preset sensitivity threshold, the access request is intercepted.
[0069] Specifically, when the sensitivity of the accessed URL meets the preset conditions (i.e., not less than the sensitivity threshold), the web page access request can be directly intercepted and processed, or when the sensitivity meets the preset conditions, a secondary review (such as manual review) can be conducted, that is, the web page content is sent to the review center, and the review center is processed after the feedback result is obtained. For example, if the review result is passed, the corresponding web page service is provided, otherwise it is intercepted. In specific implementation, control can be carried out according to business needs.
[0070] Specifically, before intercepting the access request, the user group of the client can be determined first, and whether to intercept is determined based on the user group. For example, if the user group is underage, the access request is intercepted. When applied, targeted interception can also be performed based on the type of static content. For example, if the text is sensitive, the text is intercepted, and if the image is sensitive, the image is intercepted.
[0071] According to an embodiment of the present application, a website security protection method based on sensitive information is provided, such as Figure 3 As shown, the method also includes:
[0072] Step S301: based on a web page access request initiated by a client, determining an access URL of a target web page pointed to by the web page access request;
[0073] Step S302: Determine the webpage content type corresponding to the accessed URL;
[0074] Step S303: If the webpage content type is dynamic content, a dynamic content acquisition request is sent to the URL source site of the target webpage;
[0075] Step S304: obtaining the dynamic response content fed back by the URL source station of the target web page according to the dynamic content acquisition request;
[0076] Step S305: performing sensitivity analysis on the dynamic response content to obtain the sensitivity of the dynamic response content;
[0077] Step S306: Execute corresponding processing according to the sensitivity of the dynamic response content.
[0078] When applied, the sensitivity analysis of the dynamic response content can be performed with reference to the above steps S1033 and S1034, that is, the dynamic response content is first segmented, and then the segmentation results are matched with the pre-built sensitive word library, so as to obtain the sensitive word group of the dynamic response content according to the hit result, and then the sensitivity score of each sensitive word in the dynamic response content is accumulated, and the total value of the accumulated sensitivity score is used as the sensitivity value of the dynamic response content. When applied, the dynamic response content can also be sent to a pre-built sensitivity value calculation center, and the sensitivity of the dynamic response content is determined according to the results fed back from the sensitivity value calculation center.
[0079] The embodiment of the present application performs sensitivity monitoring on the content updated in real time on the website by analyzing the dynamic response content acquired in real time, thereby avoiding the problem of poor web page supervision and affected user experience caused by the difference between the pre-calculated sensitivity value and the sensitivity value of the URL updated content.
[0080] In order to further illustrate the website security protection method based on sensitive information provided by the embodiment of the present application, Figure 4 For detailed description. Figure 4, the cloud protection system (providing website protection services) pre-requests the source site content from different URL source sites, stores the source site content, and analyzes the content returned by different URL source sites, analyzes the sensitive words contained in the URL, and calculates the sensitivity value of the website according to the weight of the sensitive words, and finally obtains the corresponding relationship between different URLs and their sensitivity. In this way, after the cloud protection center receives the request for accessing the URL initiated by the user through the client, if the accessed URL is a static page, it queries the corresponding relationship between different URLs and their sensitivity pre-stored locally in the cloud protection system, and determines whether the sensitivity of the accessed URL is greater than the sensitivity threshold. If the sensitivity of the accessed URL is not less than the sensitivity threshold, the user's request to access the URL initiated by the client is intercepted, and an error page is fed back or a 404 interface of "the web page cannot be displayed normally" is fed back to the user client. If the sensitivity of the accessed URL is less than the sensitivity threshold, the website content of the accessed URL stored locally in the cloud protection system is fed back to the user client. If the URL to be accessed is a dynamic page, a request for the URL source site content needs to be sent to the URL source site. After receiving the returned dynamic response content, it is analyzed to see if the sensitivity in the dynamic response is not less than the sensitivity threshold. If it is, it is intercepted and an error page is fed back or a 404 interface "the webpage cannot be displayed normally" is fed back to the user client. Otherwise, the dynamic response content is provided to the user client so that the user client can load and display the dynamic response content. This method of distributing website content directly to user customers by the cloud protection system plays the role of sinking the content distribution network CDN technology from the network source site to the cloud protection system, achieving the purpose of taking into account sensitivity detection and improving content distribution efficiency.
[0081] An embodiment of the present application provides a website security protection device based on sensitive information, such as Figure 5 As shown, the device 50 includes: a data acquisition module 501, a data preprocessing module 502, a trend prediction module 503, and a navigation orientation module 504.
[0082] A request URL determination module is used to determine the access URL of the target web page pointed to by the web page access request based on the web page access request initiated by the client;
[0083] A content type determination module, used to determine the webpage content type corresponding to the accessed URL;
[0084] A static sensitivity module, for determining the sensitivity of the static content according to the correspondence between the pre-stored URL and its sensitivity if the webpage content type is static content;
[0085] The security protection processing module is used to determine the target web page content of the target web page in the pre-stored content distribution database if the sensitivity of the static content is less than the preset sensitivity value threshold, and send the target web page content to the client so that the client can display the target web page content.
[0086] The embodiment of the present application determines the web page content type of the access URL of the target web page pointed to by the web page access request initiated by the client, and when the web page content type is static content, determines the sensitivity of the static content according to the correspondence between the pre-stored URL and its sensitivity. If the sensitivity of the static content is less than the preset sensitivity value threshold, the target web page content of the target web page is determined in the pre-stored content distribution database, and the target web page content is sent to the client, so that the client displays the target web page content. This method of pre-calculating the sensitivity of the website content can quickly determine the sensitivity of the access URL, and can directly find the corresponding web page content locally under the condition of meeting the response to the client request. Not only does it not need to request the web page content from the source station, but it also does not need to review its web page content. It not only improves the website protection capability, reduces the overhead of sensitive detection, and achieves the purpose of reducing time complexity, but also realizes the content distribution from the source station to the website security protection end, solves the problem that the source station is heavily loaded, responds slowly, and cannot monitor and review the web page content due to the source station being responsible for content distribution.
[0087] Furthermore, before the static sensitivity module determines the sensitivity of the static content according to the correspondence between the pre-stored URLs and their sensitivities, it further includes:
[0088] The content request submodule is used to send static content acquisition requests to different URL source sites;
[0089] The content acquisition submodule is used to obtain the static response files fed back by the URL source stations corresponding to different web pages in response to the static content acquisition request;
[0090] The content analysis submodule is used to determine the sensitivity scores of the texts and images included in the static response files fed back by the URL source stations corresponding to the different web pages in response to the static content acquisition request;
[0091] The sensitivity determination submodule uses a static response file of the URL source station corresponding to each web page to obtain the static content request feedback to add up the sensitivity scores of the text and image, and obtains the sensitivity of the static content of each web page.
[0092] Furthermore, the sensitivity determination submodule includes:
[0093] A sensitive content extraction unit is used to extract the text included in the static response file fed back by the URL source station corresponding to each of the different web pages in response to the static content acquisition request by using a plurality of preset regular expressions for sensitive content, so as to obtain sensitive content corresponding to each of the plurality of URLs;
[0094] A sensitive content phrase determination unit is used to segment the sensitive content corresponding to each of the plurality of URLs, and obtain a second array including the plurality of URLs and their respective sensitive segmented word sets according to the segmentation results;
[0095] A first array determination unit, used to determine a first array including a website identifier and a corresponding website;
[0096] A second number determination unit, used to determine a set of website identifiers including a plurality of segmented words and their respective corresponding ones according to the first array and the second array;
[0097] A sensitive word determination unit is used to determine any word as a sensitive word if it hits a preset sensitive word library, and obtain a number of URLs and their corresponding sensitive word sets according to each sensitive word that hits the sensitive word library and is determined;
[0098] The text sensitivity determination unit is used to determine the sensitivity corresponding to a number of URLs according to the sensitivity scores corresponding to each sensitive word in the sensitive word sets corresponding to the URLs.
[0099] Furthermore, the sensitivity determination submodule includes:
[0100] An image feature extraction unit is used to extract features of images included in static response files fed back by URL source stations corresponding to different web pages in response to static content acquisition requests, so as to obtain image feature matrices corresponding to different web pages;
[0101] An image similarity calculation unit, used to calculate the similarity between the image feature matrices corresponding to different web pages and the feature matrices of several sensitive images;
[0102] The image sensitivity determination unit is used to determine the image sensitivity of different web pages according to the similarity calculation result.
[0103] Furthermore, the content type determination module includes at least one of the following submodules:
[0104] A first determination submodule is used to determine the webpage content file type pointed to by the webpage content file format corresponding to the accessed URL based on the webpage content file formats corresponding to the pre-stored plurality of URLs;
[0105] The second determination submodule is used to convert the access identifier into a website identifier, and determine the webpage content type according to the webpage content types corresponding to the pre-stored multiple website identifiers.
[0106] Furthermore, the device also includes:
[0107] A dynamic content request module, used to send a dynamic content acquisition request to the URL source site of the target web page if the web page content type is dynamic content;
[0108] A dynamic content acquisition module is used to obtain dynamic response content fed back from the URL source station of the target web page according to the dynamic content acquisition request;
[0109] The dynamic content sensitivity determination module is used to perform sensitivity analysis on the dynamic response content to obtain the sensitivity of the dynamic response content.
[0110] The dynamic content processing module is used to perform corresponding processing according to the sensitivity of the dynamic response content.
[0111] Furthermore, the security protection processing module also includes:
[0112] The interception processing submodule is used to perform interception processing on the access request if the sensitivity of the static content is not less than a preset sensitivity threshold.
[0113] Another embodiment of the present application provides a terminal, including: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the above-mentioned search engine-based data processing method when executing the computer program.
[0114] Specifically, the processor may be a CPU, a general-purpose processor, a DSP, an ASIC, an FPGA or other programmable logic device, a transistor logic device, a hardware component or any combination thereof. It may implement or execute various exemplary logic blocks, modules and circuits described in conjunction with the disclosure of this application. The processor may also be a combination that implements computing functions, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, etc.
[0115] Specifically, the processor is connected to the memory via a bus, and the bus may include a path for transmitting information. The bus may be a PCI bus or an EISA bus, etc. The bus may be divided into an address bus, a data bus, a control bus, etc.
[0116] The memory can be a ROM or other type of static storage device that can store static information and instructions, a RAM or other type of dynamic storage device that can store information and instructions, or an EEPROM, CD-ROM or other optical disk storage, optical disk storage (including compressed optical disk, laser disk, optical disk, digital versatile disk, Blu-ray disk, etc.), magnetic disk storage medium or other magnetic storage device, or any other medium that can be used to carry or store the desired program code in the form of instructions or data structures and can be accessed by a computer, but is not limited to this.
[0117] Optionally, the memory is used to store the code of the computer program for executing the solution of the present application, and the execution is controlled by the processor. The processor is used to execute the application program code stored in the memory to implement Figure 5The illustrated embodiments provide for the operation of the apparatus.
[0118] Another embodiment of the present application provides a computer-readable storage medium storing computer-executable instructions for executing the above-mentioned Figure 1-Figure 3 The method shown.
[0119] The device embodiments described above are only illustrative, and the units described as separate components may or may not be physically separated, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0120] It will be appreciated by those skilled in the art that all or some of the steps and systems in the disclosed method above may be implemented as software, firmware, hardware and appropriate combinations thereof. Some physical components or all physical components may be implemented as software executed by a processor, such as a central processing unit, a digital signal processor or a microprocessor, or may be implemented as hardware, or may be implemented as an integrated circuit, such as an application specific integrated circuit. Such software may be distributed on a computer-readable medium, which may include a computer storage medium (or a non-transitory medium) and a communication medium (or a temporary medium). As known to those skilled in the art, the term computer storage medium includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules or other data). Computer storage media include, but are not limited to, RAM, ROM, EEPROM, flash memory or other memory technologies, CD-ROM, digital versatile disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tapes, disk storage or other magnetic storage devices, or any other medium that may be used to store desired information and may be accessed by a computer. Furthermore, it is well known to those skilled in the art that communication media typically embodies computer readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media.
[0121] The above is a specific description of the preferred implementation of the present application, but the present application is not limited to the above-mentioned implementation mode. Technical personnel familiar with the field can also make various equivalent deformations or substitutions without violating the spirit of the present application. These equivalent deformations or substitutions are all included in the scope defined by the claims of the present application.
Claims
1. A website security protection method based on sensitive information, characterized in that: The method comprises: Based on the webpage access request initiated by the client, determining the access URL of the target webpage pointed to by the webpage access request; Determine the webpage content type corresponding to the accessed URL; If the webpage content type is static content, the sensitivity of the static content is determined according to the correspondence between the pre-stored URL and its sensitivity; If the sensitivity of the static content is less than a preset sensitivity value threshold, the target webpage content of the target webpage is determined in a pre-stored content distribution database, and the target webpage content is sent to the client so that the client displays the target webpage content.
2. The method according to claim 1, characterized in that: Before determining the sensitivity of the static content according to the correspondence between the pre-stored URLs and their sensitivities, the method further includes: Send static content acquisition requests to different URL origins; Obtaining static response files fed back by URL source stations corresponding to different web pages in response to the static content acquisition request; Determine the sensitivity scores of the texts and images included in the static response files fed back by the URL source stations corresponding to the different web pages in response to the static content acquisition request; The sensitivity scores of the texts and images included in the static response files fed back by the URL source stations corresponding to the different web pages in response to the static content acquisition request are added and calculated to obtain the sensitivity of the static content of the different web pages.
3. The method according to claim 2, characterized in that Determining the sensitivity scores of the texts included in the static response files fed back by the URL source stations corresponding to the different web pages in response to the static content acquisition request includes: Using multiple preset regular expressions for sensitive content, extract the text included in the static response file fed back by the URL source station corresponding to each of the different web pages in response to the static content acquisition request, and obtain the sensitive content corresponding to each of the several URLs; Perform word segmentation on the sensitive contents corresponding to the respective URLs, and obtain a second array including the respective URLs and their respective sensitive word segmentation sets according to the word segmentation results; Determine a first array including website identifiers and corresponding website addresses; Determine, based on the first array and the second array, a set of URL identifiers including a plurality of segmented words and their respective corresponding ones; If any word hits a preset sensitive word library, the word is determined as a sensitive word, and a number of URLs and their corresponding sensitive word sets are obtained according to each sensitive word hit and determined in the sensitive word library; The sensitivity of each of the several URLs is determined according to the sensitivity scores of each sensitive word in the several URLs and their corresponding sensitive word sets.
4. The method according to claim 2, characterized in that: Determining the sensitivity scores of images included in the static response files fed back by the URL source stations corresponding to the different web pages in response to the static content acquisition request includes: Extracting features of images included in the static response files fed back by the URL source stations corresponding to the different web pages in response to the static content acquisition request, and obtaining image feature matrices corresponding to the different web pages; Calculate the similarity between the image feature matrices corresponding to different web pages and the feature matrices of several sensitive images; The image sensitivity of different web pages is determined based on the similarity calculation results.
5. The method according to claim 1, characterized in that The determining of the webpage content type corresponding to the accessed URL includes at least one of the following: Based on the webpage content file formats corresponding to the pre-stored plurality of webpages, respectively, determining the webpage content file type pointed to by the webpage content file format corresponding to the accessed webpage; The access identifier is converted into a website identifier, and the webpage content type is determined according to the webpage content types corresponding to the pre-stored multiple website identifiers.
6. The method according to claim 1, characterized in that The method further comprises: If the webpage content type is dynamic content, a dynamic content acquisition request is sent to the URL source site of the target webpage; Obtaining dynamic response content fed back by the URL source station of the target webpage according to the dynamic content acquisition request; Performing sensitivity analysis on the dynamic response content to obtain the sensitivity of the dynamic response content; Corresponding processing is performed according to the sensitivity of the dynamic response content.
7. The method according to claim 1, characterized in that The method further comprises: If the sensitivity of the static content is not less than a preset sensitivity threshold, interception processing is performed on the access request.
8. A website security protection device based on sensitive information, characterized in that: include: A request website address determination module, used to determine the access website address of the target web page pointed to by the web page access request based on the web page access request initiated by the client; A content type determination module, used to determine the webpage content type corresponding to the accessed URL; A static sensitivity module, for determining the sensitivity of the static content according to a pre-stored correspondence between a URL and its sensitivity if the webpage content type is static content; The security protection processing module is used to determine the target web page content of the target web page in a pre-stored content distribution database if the sensitivity of the static content is less than a preset sensitivity value threshold, and send the target web page content to the client so that the client can display the target web page content.
9. An electronic device, characterized in that: The method comprises a processor and a memory, wherein the memory stores computer-readable instructions, and the processor is used to execute the computer-readable instructions, wherein the computer-readable instructions execute the method according to any one of claims 1 to 7 when executed.
10. A computer-readable storage medium storing computer-executable instructions, wherein the computer-executable instructions are used to execute the method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Website security monitoring method and device
CN107547555A
Method and device for recognizing sensitive webpage, computer system and medium
CN113378172A
Flow monitoring data throughput management and control system and method
CN117955917A
Sensitive webpage content detection
US20080320010A1