Page detection method and device, electronic equipment and storage medium

By detecting and processing pop-ups and login elements, and combining semantic segmentation and deep search algorithms, the problem of inflexible and inefficient detection of illegal content in existing technologies is solved, and efficient traversal and detection of illegal content of all pages of the application is achieved.

CN115982017BActive Publication Date: 2026-11-24VIVO MOBILE COMM CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211659006.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-22
Publication Date
2026-11-24
Estimated Expiration
2042-12-22

AI Technical Summary

Technical Problem

Existing methods for detecting illegal content are inflexible and inefficient, unable to effectively handle interruptions in application page traversal caused by pop-ups and registration/login operations, and unable to complete the traversal of all pages.

Method used

By detecting whether pop-up and login elements exist in the target application, these elements are processed to facilitate normal access to the application page. Semantic segmentation and deep search algorithms are combined to traverse all pages and detect whether there is any illegal content.

Benefits of technology

It enables flexible and efficient detection of illegal content on all pages of the application, improving the flexibility and efficiency of detection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115982017B_ABST
    Figure CN115982017B_ABST
Patent Text Reader

Abstract

This application discloses a page detection method, apparatus, electronic device, and storage medium, belonging to the field of terminal technology. The page detection method includes: launching a target application and detecting whether a first object exists in the target application, the first object including at least one of a pop-up element and a target element, the target element including at least one of a registration element and a login element; if the first object exists in the target application, processing the first object, and traversing all pages of the target application to detect whether any pages contain illegal content.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application belongs to the field of terminal technology, specifically relating to a page detection method, apparatus, electronic device, and storage medium. Background Technology

[0002] With the widespread use of electronic devices, some applications are filled with illegal content. To prevent illegal applications from entering the market, platforms will conduct illegal detection on applications in electronic devices.

[0003] Current common methods for detecting app violations involve traversing all pages within the app, taking screenshots, performing text recognition on the screenshots to obtain the app page content, and then matching the content against a database to detect violations.

[0004] However, current methods for detecting inappropriate content typically involve manually writing scripts to control the coordinates of clicks on application pages. This approach fails to address issues where users need to register or log in to access the application's homepage. Furthermore, many applications currently experience pop-up windows during operation, preventing the traversal method from reaching the application page. Clicking some pop-ups can also cause the application process to exit, interrupting the traversal and preventing the completion of all page traversals. Manual adjustments to the script code are therefore necessary. Consequently, existing methods for detecting inappropriate content are inflexible and inefficient. Summary of the Invention

[0005] The purpose of this application is to provide a page detection method, apparatus, electronic device, and storage medium that can solve the problems of inflexibility and low efficiency of existing illegal content detection methods.

[0006] In a first aspect, embodiments of this application provide a page detection method, the method comprising: launching a target application and detecting whether a first object exists in the target application, the first object including at least one of a pop-up element and a target element, the target element including at least one of a registration element and a login element; if the first object exists in the target application, processing the first object, and traversing all pages of the target application to detect whether any illegal content exists on all pages.

[0007] Secondly, embodiments of this application provide a page detection device, which includes: a startup module, a detection module, a processing module, and a traversal module. The startup module is used to launch a target application. The detection module is used to detect whether a first object exists in the target application launched by the startup module. The first object includes at least one of a pop-up element and a target element, and the target element includes at least one of a registration element and a login element. The processing module is used to process the first object detected by the detection module if the first object exists in the target application. The traversal module is used to traverse all pages of the target application and detect whether any illegal content exists on all pages.

[0008] Thirdly, embodiments of this application provide an electronic device including a processor and a memory, wherein the memory stores programs or instructions executable on the processor, and the programs or instructions, when executed by the processor, implement the steps of the method described in the first aspect.

[0009] Fourthly, embodiments of this application provide a readable storage medium on which a program or instructions are stored, which, when executed by a processor, implement the steps of the method described in the first aspect.

[0010] Fifthly, embodiments of this application provide a chip, the chip including a processor and a communication interface, the communication interface being coupled to the processor, the processor being used to run programs or instructions to implement the method as described in the first aspect.

[0011] In a sixth aspect, embodiments of this application provide a computer program product stored in a storage medium, which is executed by at least one processor to implement the method described in the first aspect.

[0012] In this embodiment, the page detection device launches the target application and detects whether a first object exists in the target application. The first object includes at least one of a pop-up element and a target element, and the target element includes at least one of a registration element and a login element. If the first object exists in the target application, the first object is processed, and all pages of the target application are traversed to detect whether any of the pages contain illegal content. In this solution, after the page detection device launches the application to be detected (e.g., the target application) and enters the application, it can first determine whether there is a specific element in the application that prevents normal entry into the application's pages, such as at least one of a pop-up element, a registration element, and a login element. If the specific element exists in the application, the page detection device processes the specific element, thereby allowing the page detection device to normally enter the application's pages to traverse all pages of the application and detect whether each page contains illegal content. Thus, this solution can traverse all pages of the application to complete the detection of illegal content on all pages, thereby improving the flexibility and efficiency of illegal content detection. Attached Figure Description

[0013] Figure 1 This is one of the flowcharts of a page detection method provided in the embodiments of this application;

[0014] Figure 2 This is a second flowchart of a page detection method provided in an embodiment of this application;

[0015] Figure 3This is the third flowchart of a page detection method provided in the embodiments of this application;

[0016] Figure 4 This is the fourth flowchart of a page detection method provided in the embodiments of this application;

[0017] Figure 5 This is the fifth flowchart of a page detection method provided in the embodiments of this application;

[0018] Figure 6 This is a schematic diagram of the structure of a page detection device provided in an embodiment of this application;

[0019] Figure 7 This is one of the hardware structure diagrams of an electronic device provided in the embodiments of this application;

[0020] Figure 8 This is a second schematic diagram of the hardware structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0021] The technical solutions of the embodiments of this application will be clearly described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this application. All other embodiments obtained by those skilled in the art based on the embodiments of this application are within the scope of protection of this application.

[0022] The terms "first," "second," etc., used in the specification and claims of this application are used to distinguish similar objects and not to describe a specific order or sequence. It should be understood that such use of data can be interchanged where appropriate so that embodiments of this application can be implemented in orders other than those illustrated or described herein, and the objects distinguished by "first," "second," etc., are generally of the same class and the number of objects is not limited; for example, a first object can be one or more. Furthermore, in the specification and claims, "and / or" indicates at least one of the connected objects, and the character " / " generally indicates that the preceding and following objects are in an "or" relationship.

[0023] The page detection method provided in this application will be described in detail below with reference to the accompanying drawings, through specific embodiments and application scenarios.

[0024] The page detection method in this application embodiment can be applied to scenarios of detecting illegal content in application pages. This solution is also applicable to applications, quick apps, and nested web view pages.

[0025] With the rapid development of the Internet and the widespread adoption of smart mobile devices, more and more mobile applications are being installed on mobile devices for user convenience. However, among these numerous mobile applications, some contain illegal content that seriously affects users' physical and mental health. To prevent illegal applications from entering the market, platforms will conduct violation detection on applications within electronic devices.

[0026] Currently, the conventional method for detecting page violations in existing technologies is to traverse the mobile application's pages and obtain application content through screenshots to detect violations. There are three main traversal methods: one is to manually write scripts to control the coordinates of clicking on the application page; the second is to obtain the application's user interface (UI) components through development tools and traverse by clicking on UI components; and the third is to use deep learning methods to segment the application's homepage to obtain clickable elements and combine them with a depth-first search algorithm to traverse all pages of the application by clicking.

[0027] Existing technologies have certain limitations: 1. Low efficiency: Manual scripting is only applicable to one application and cannot be used in other applications. Furthermore, it requires modification if the existing interface is updated. 2. Poor applicability: The UI component acquisition method is not suitable for quick apps or mobile applications with embedded web page views. 3. Inflexibility: While deep learning methods are used to segment the application's homepage to obtain clickable areas, and a depth-first search algorithm is used to traverse all pages of the application, this method cannot address the issue of requiring registration or login to access the application's homepage. Moreover, many applications currently experience pop-up windows, and this method also cannot handle the need to process these pop-ups to access the homepage. 4. Many mobile applications currently block content based on region and device, preventing existing page violation detection technologies from traversing all pages and thus failing to detect inappropriate content within the application, impacting user experience. Therefore, none of the existing solutions can efficiently and flexibly detect inappropriate content on application pages.

[0028] This application provides a page detection method. After the page detection device starts and enters the application to be detected (e.g., the target application), it can first determine whether there is a specific element in the application that prevents normal access to the application's pages, such as at least one of pop-up elements, registration elements, and login elements. If the specific element exists in the application, the page detection device processes the specific element, thereby allowing the page detection device to normally enter the application's pages. This allows for the traversal of all pages in the application and the detection of illegal content on each page. In this way, this solution can traverse all pages of the application to complete the detection of illegal content on all pages, thereby improving the flexibility and efficiency of illegal content detection.

[0029] This application provides a page detection method. Figure 1 A flowchart of a page detection method provided in an embodiment of this application is shown. This method can be applied to a page detection device. Figure 1 As shown, the page detection method provided in this application embodiment may include the following steps 201 and 202.

[0030] Step 201: The page detection device starts the target application and detects whether the first object exists in the target application.

[0031] In this embodiment of the application, the first object mentioned above includes at least one of a pop-up element and a target element, and the target element includes at least one of a registration element and a login element.

[0032] In this embodiment of the application, after the target application is launched, the page detection device can display a page (e.g., the target page) after entering the application, and then the page detection device can detect the page to determine whether the first object exists in the target application.

[0033] Optionally, in the embodiments of this application, the aforementioned page / target page may be the first page after entering the application (which may be called the initial page), or the page displayed when the target application is last exited, or the page selected by the user in the target application.

[0034] Optionally, in this embodiment of the application, the page detection device can use a text recognition model (e.g., an OCR text recognition model) to identify the first page after entering the application, so as to obtain all the elements of the page, and thus the page detection device can determine whether the first object exists in the target application based on these elements.

[0035] Optionally, in this embodiment, the target application can be any application installed in the page detection device. Furthermore, the application installed in the page detection device can be controlled or managed by a group control platform.

[0036] It should be noted that the aforementioned group control platform refers to a platform that uses a single control device to control multiple electronic devices / page detection devices, enabling synchronized operation of these devices. For example, the group control platform can control multiple electronic devices to launch an application within each device and detect the presence of a first object within that application.

[0037] Optionally, in this embodiment, the group control platform can pre-modify the IP addresses of each page detection device using dynamic Internet Protocol (IP) technology, and modify the device identifiers of each page detection device using device switching technology, so as to realize the configuration of different devices and different users, thereby facilitating the subsequent traversal process of application pages and more completely obtaining application content to achieve violation detection.

[0038] Optionally, in this embodiment, the pop-up elements may include, but are not limited to, at least one of the following: privacy agreement pop-up, permission request pop-up, version update pop-up, and advertising pop-up. The specific elements can be determined according to actual usage needs, and this embodiment does not impose any restrictions.

[0039] It should be noted that the aforementioned registration element can be understood as: the text content of the target application's page containing registration text, registration components, or registration input boxes, or other registration-related content. Similarly, the understanding of the login element is similar to that of the registration element, and will not be elaborated upon here. Optionally, in one implementation of this application embodiment, the aforementioned first object includes the aforementioned pop-up element. Combined with... Figure 1 ,like Figure 2 As shown, step 201 can be implemented through steps 201a and 201b below.

[0040] Step 201a: The page detection device starts the target application, displays the target page of the target application, and performs text recognition on the target page through the text recognition model to obtain at least one page element.

[0041] Optionally, in this embodiment of the application, after the page detection device starts the target application and displays the target page of the target application, it can take a screenshot of the target page to obtain a screenshot image of the target page, and input the screenshot image into the text recognition model to perform text recognition on the screenshot image through the text recognition model, thereby obtaining at least one page element.

[0042] Optionally, in the embodiments of this application, the above-mentioned at least one page element may include, but is not limited to, at least one of the following: pop-up element, registration element, login element, text element, image element, link element, control / component element, etc.

[0043] Step 201b: The page detection device matches at least one page element with at least one type of preset pop-up text information to determine whether a pop-up element exists in the target application.

[0044] In this embodiment, for each of the at least one page elements, the page detection device can sequentially compare each page element with at least one type of pop-up text information to determine whether a pop-up element exists among the at least one page elements, and if a pop-up element exists, determine the type to which the pop-up element belongs. For example, if a certain page element (e.g., page element A) matches a certain type of pop-up text information (type A pop-up text information) among the at least one type of pop-up text information, then page element A is a pop-up element, and the type to which page element A belongs is type A pop-up.

[0045] It should be noted that matching a page element with a type of pop-up text information can be understood as: the similarity between the page element and the type of pop-up text information is greater than or equal to a threshold.

[0046] Optionally, in the embodiments of this application, the above-mentioned at least one type of pop-up text information includes at least one of the following: the identifier of at least one type of pop-up (e.g., name, thumbnail), the name of the type to which at least one type of pop-up belongs, the content of at least one type of pop-up, and the processing method of at least one type of pop-up, etc.

[0047] In this embodiment, the page detection device can directly perform text recognition on the target page of the target application through a text recognition model to quickly and accurately determine whether there are pop-up elements in the target application. This facilitates the subsequent detection of illegal content on all pages of the target application by the page detection device, thereby improving the efficiency of illegal content detection.

[0048] Optionally, in another implementation of this application embodiment, the first object includes the target element described above. (In conjunction with...) Figure 1 ,like Figure 3 As shown, step 201 can be implemented through steps 201c and 201d as described below.

[0049] Step 201c: The page detection device starts the target application, displays the target page of the target application, and performs text recognition on the target page through the text recognition model to obtain the text content of the target page.

[0050] Optionally, in this embodiment of the application, after the page detection device starts the target application and displays the target page of the target application, it can take a screenshot of the target page to obtain a screenshot image of the target page, and input the screenshot image into the text recognition model so as to perform text recognition on the screenshot image through the text recognition model, thereby obtaining the text content of the target page.

[0051] It should be noted that the text content of the target page mentioned above can be understood as: the text information or name contained on the target page, such as login text information, registration text information, or other text information.

[0052] Step 201d: The page detection device determines whether the target element exists in the target application based on the text content of the target page.

[0053] In this embodiment, the page detection device can compare the text content of the target page with preset login and registration text information to determine whether a target element exists in the text content of the target page, that is, whether the target application requires registration and / or login before accessing the application page. For example, if a certain text content (e.g., text content A) in the text content of the target page matches the registration text information, then a registration element exists in the target application. If a certain text content (e.g., text content B) in the text content of the target page matches the login text information, then a login element exists in the target application.

[0054] In this embodiment, the page detection device can directly perform text recognition on the target page of the target application through a text recognition model to quickly and accurately determine whether the target element exists in the target application. This facilitates the subsequent detection of illegal content on all pages of the target application by the page detection device, thereby improving the efficiency of illegal content detection.

[0055] Step 202: If the first object exists in the target application, the page detection device processes the first object and traverses all pages of the target application to detect whether there is any illegal content on all pages.

[0056] In this embodiment, the page detection device processes the page containing the first object according to the category of the first object, using a processing method corresponding to the category of the first object, so as to allow normal access to the page of the target application. Thus, the page detection device can traverse all pages in the target application to detect whether there is any illegal content on all pages in the target application.

[0057] Optionally, in the embodiments of this application, combined with Figure 2 ,like Figure 4 As shown, step 202 above can be specifically implemented through step 202a below.

[0058] Step 202a: If the target page element matches the target pop-up text information in at least one type of pop-up text information, the page detection device performs the processing corresponding to the target category on the target page element based on the target pop-up text information, and traverses all pages of the target application to detect whether there is any illegal content on all pages.

[0059] In this embodiment of the application, the target page element is any page element among at least one page element, and the target category is the pop-up category corresponding to the target pop-up text information.

[0060] It is understandable that different types of pop-up text information correspond to different pop-up processing methods. If the target page element matches the target type of pop-up text information (i.e., the target pop-up text information), the page detection device can use the pop-up processing method corresponding to the target type of pop-up text information to process the target page element.

[0061] It should be noted that the pop-up text information is used to describe the category and name of the pop-up.

[0062] Optionally, in the embodiments of this application, the above pop-up window processing method may include, but is not limited to, at least one of the following: clicking "Agree or Accept", clicking "Update", clicking "Close or Skip", and clicking "OK or Return".

[0063] For example, if the target pop-up text is a privacy agreement pop-up or a permission request pop-up (such as a youth mode pop-up), the pop-up processing method is that the page detection device uses an OCR text recognition model to recognize the pop-up content, and then clicks the text area where the pop-up content is "Agree". If the target pop-up text is a version update pop-up, the pop-up processing method is that the page detection device uses an OCR text recognition model to recognize the pop-up content, and then clicks the text area where the pop-up content is "Update". If the target pop-up text is an advertisement pop-up or a floating pop-up, the pop-up processing method is that the page detection device uses an OCR text recognition model to recognize the pop-up content, and then clicks the text area where the pop-up content is "Close".

[0064] In this embodiment, the page detection device can perform corresponding processing on the pop-up element according to the category of the pop-up element in the target page of the target application, so as to quickly enter the normal page of the target application and accurately process the pop-up element, thereby improving the flexibility and accuracy of pop-up element processing.

[0065] Optionally, in the embodiments of this application, combined with Figure 3 ,like Figure 5 As shown, step 202 above can be implemented through step 202b below.

[0066] Step 202b: If the text content of the target element is included in the text content of the target page, the page detection device ignores the target element and traverses all pages of the target application to detect whether there is any illegal content on all pages.

[0067] In this embodiment, if the page detection device does not recognize the text content of the target page, when the target page contains the text content of the target element, a registration and login operation is required before entering the target application. The traversal method cannot bypass the registration and login operation, causing the traversal process to be interrupted. Therefore, if the text content of the target page includes the text content of the target element, the page detection device determines that the application must be registered and logged in before entry. It uses Hook technology to bypass the registration and login process, enters the application page normally, and then enters the page traversal loop. That is, it can directly enter the application page without registering and logging in, thereby traversing all pages of the target application.

[0068] Optionally, in this embodiment of the application, the page detection device uses Hook technology to bypass the registration and login process, and then enters the application page normally and enters the page traversal loop.

[0069] In this embodiment of the application, when the text content of the target page includes the text content of the target element, the page detection device uses Hook technology to bypass the registration and login process, enters the application page normally, and then enters the page traversal loop. This facilitates the subsequent detection of illegal content on all pages of the target application by the page detection device, thereby improving the efficiency of illegal content detection.

[0070] Optionally, in this embodiment of the application, the step 202 above, "traversing all pages of the target application and detecting whether there is any illegal content on all pages", can be specifically implemented through the following steps 203 to 206.

[0071] Step 203: The page detection device performs segmentation processing on the first page of the target application using a semantic segmentation model to obtain at least one clickable element and detect whether there is any illegal content on the first page.

[0072] In this embodiment of the application, the first page mentioned above is any page in the target application.

[0073] In this embodiment of the application, after the page detection device normally enters the application page of the target application (i.e., the first page mentioned above), it can take a screenshot of the application page to obtain a screenshot image, and input the screenshot image into the semantic segmentation model so that the semantic segmentation model can perform semantic parsing and segmentation on the screenshot image to obtain at least one clickable element.

[0074] It should be noted that the clickable elements mentioned above can be understood as elements that the page detection device can / is able to click or process.

[0075] Optionally, in the embodiments of this application, the semantic segmentation model described above can be any of the following: Fully Convolutional Networks (FCN), Dimmed Convolutional Networks (Deeplabv3p), or Encoder-Decoder Networks (U-Net).

[0076] Step 204: The page detection device performs click processing on at least one clickable element in sequence using a depth-first search traversal algorithm, and detects whether the first page has changed.

[0077] In this embodiment, the page detection device uses a depth-first search (DFS) algorithm to perform a click operation on the first clickable element among at least one clickable element on the first page, thereby entering the page corresponding to the first clickable element. The DFS algorithm is then used to sequentially perform click operations on the clickable elements within that page, entering the corresponding page and performing click operations on the clickable elements within that page, and so on, until all clickable elements within the page corresponding to the first clickable element on the first page have been clicked. Then, the page detection device returns to the first page and performs a click operation on the second clickable element among at least one clickable element on the first page, thereby entering the page corresponding to the second clickable element. The DFS algorithm is then used to sequentially perform click operations on the clickable elements within that page, entering the corresponding page and performing click operations on the clickable elements within that page, and so on, until all clickable elements within the page corresponding to the second clickable element on the first page have been clicked. This process is repeated until all clickable elements within at least one clickable element on the first page have been clicked.

[0078] Optionally, in this embodiment of the application, when the page detection device performs click processing on at least one clickable element in sequence, it may first determine whether it has exited the target application. If it exits the target application after performing click processing on a clickable element (e.g., the first clickable element), the page detection device may return to the target application and enter the next page of the page where the first clickable element is located (i.e., the page entered after clicking the first clickable element) to continue performing click processing on the clickable elements in the page.

[0079] Optionally, in this embodiment of the application, when the page detection device performs click processing on at least one clickable element in sequence, it may use an image similarity detection model to detect whether the first page changes after each click processing on the clickable element.

[0080] Step 205: The page detection device processes the second object corresponding to the first page based on the target result and proceeds to the next page of the first page.

[0081] In this embodiment of the application, the above-mentioned target result is used to indicate whether the first page has changed or not.

[0082] Optionally, in this embodiment of the application, the second object can be the first page, a pop-up element, or a page skipped from the first page.

[0083] Optionally, in the embodiments of this application, step 205 can be implemented by step 205a or step 205b as described below.

[0084] Step 205a: If the first page remains unchanged, the page detection device determines whether the first page has entered the target mode. If it has entered the target mode, it exits the target mode and proceeds to the next page after the first page. In this embodiment, the target mode is used to indicate that the first page has entered a page jump loop.

[0085] Optionally, in this embodiment of the application, if the first page has not changed, the page detection device can determine whether the first page has entered a page jump loop. If it has entered a page jump loop, the page detection device can use Hook technology to jump out of the page jump loop and continue to execute the page traversal process.

[0086] Step 205b: When the first page changes to the second page, the page detection device detects whether there is a pop-up element on the second page. If there is a pop-up element on the second page, the pop-up element on the second page is processed, and the process proceeds to the next page after the first page.

[0087] Optionally, in this embodiment of the application, if the first page changes, the page detection device can determine whether there is a pop-up element on the first page by using a text recognition model and at least one type of preset pop-up text information. If there is a pop-up element on the first page, the device will classify the pop-up element and perform processing on the pop-up element on the first page that corresponds to the category to which the pop-up element belongs.

[0088] It should be noted that the specific processing methods for pop-up elements can be found in the descriptions in the above embodiments, and will not be repeated here.

[0089] Step 206: The page detection device traverses the remaining pages in the target application and detects whether there is any illegal content on the remaining pages.

[0090] In this embodiment of the application, the remaining pages are the pages in the target application other than the first page.

[0091] It is understood that, for the remaining pages, the page detection device can continue to execute steps 203 to 205 above to complete the traversal of all remaining pages in the target application. Optionally, in this embodiment of the application, the "detecting whether there is illegal content on all pages" in step 202 above can be specifically implemented through steps 207 and 208 below.

[0092] Step 207: For any page among all pages, the page detection device performs text recognition on any page using a text recognition model to obtain the text content of any page.

[0093] It should be noted that the specific method by which the page detection device performs text recognition on the page to obtain the text content of the page is described in the above embodiments and will not be repeated here.

[0094] Step 208: If the target text content on any page matches the target violation content in at least one of the preset violation content categories, the page detection device saves the page by taking a screenshot and records the violation category to which the target text content belongs based on the target violation content.

[0095] It is understandable that a page detection device can sequentially compare all text content of any page with at least one type of violation content information to determine whether any violation content exists on that page, and if so, determine the type of the violation content. For example, if a certain text content (e.g., target text content) of any page matches a certain type of violation content (e.g., target violation content) from at least one type of violation content, then the target text content is violation content, and the type of the target text content is category A, which is the violation content category corresponding to the target violation content.

[0096] In this embodiment of the application, the page detection device can compare the page content of each page in the target application with at least one type of illegal content to accurately determine the pages in the target application that contain illegal content, and record the types of illegal content in the pages, so as to intuitively show the pages containing illegal content to the user through screenshots.

[0097] This application provides a page detection method. After the page detection device starts and enters the application to be detected (e.g., the target application), it can first determine whether there is a specific element in the application that prevents normal access to the application's pages, such as at least one of pop-up elements, registration elements, and login elements. If the specific element exists in the application, the page detection device processes the specific element, thereby allowing the page detection device to normally enter the application's pages. This allows for the traversal of all pages in the application and the detection of illegal content on each page. In this way, this solution can traverse all pages of the application to complete the detection of illegal content on all pages, thereby improving the flexibility and efficiency of illegal content detection.

[0098] It should be noted that the page detection method provided in this application embodiment can be executed by a page detection device. This application embodiment uses a page detection device executing the page detection method as an example to illustrate the page detection device provided in this application embodiment.

[0099] Figure 6 A schematic diagram of a possible structure of the page detection device involved in an embodiment of this application is shown. For example... Figure 6 As shown, the page detection device 70 may include: a startup module 71, a detection module 72, a processing module 73, and a traversal module 74.

[0100] The system comprises the following modules: Launch module 71, which launches the target application; Detection module 72, which detects whether a first object exists within the target application launched by launch module 71, wherein the first object includes at least one of a pop-up element and a target element, and the target element includes at least one of a registration element and a login element; Processing module 73, which processes the first object detected by detection module 72 if it exists in the target application; and Traversal module 74, which traverses all pages of the target application and detects whether any pages contain inappropriate content.

[0101] This application provides a page detection device. After launching and entering the application to be detected (e.g., a target application), the page detection device can first determine whether there are specific elements in the application that prevent normal access to the application's pages, such as at least one of pop-up elements, registration elements, and login elements. If such specific elements exist in the application, the page detection device processes them, thereby allowing normal access to the application's pages. This allows the device to traverse all pages of the application and detect whether each page contains illegal content. Thus, this solution can traverse all pages of the application to complete the detection of illegal content on all pages, thereby improving the flexibility and efficiency of illegal content detection.

[0102] In one possible implementation, the first object includes a pop-up element. The startup module 71 is specifically used to launch the target application and display its target page. The detection module 72 is specifically used to perform text recognition on the target page to obtain at least one page element; and to match the at least one page element with at least one preset type of pop-up text information to determine whether a pop-up element exists in the target application.

[0103] In one possible implementation, the processing module 73 is specifically used to perform target category processing on the target page element based on the target pop-up text information when the target page element matches the target pop-up text information in at least one type of pop-up text information; wherein the target page element is any page element among at least one page element, and the target category is the pop-up category corresponding to the target pop-up text information.

[0104] In one possible implementation, the first object mentioned above includes a target element. The startup module 71 is specifically used to launch the target application and display the target page of the target application. The detection module 72 is specifically used to perform text recognition on the target page to obtain the text content of the target page; and based on the text content of the target page, to determine whether a target element exists in the target application.

[0105] In one possible implementation, the aforementioned processing module 73 is specifically used to skip the registration and login process corresponding to the target element when the text content of the target page includes the text content of the target element.

[0106] In one possible implementation, the traversal module 74 is specifically used to perform segmentation processing on the first page of the target application to obtain at least one clickable element and detect whether there is any illegal content on the first page, where the first page is any page in the target application; sequentially perform click processing on at least one clickable element and detect whether the first page has changed; process the second object corresponding to the first page based on the target result and proceed to the next page of the first page, where the target result is used to indicate whether the first page has changed or not; traverse the remaining pages in the target application and detect whether there is any illegal content on the remaining pages, where the remaining pages are pages in the target application other than the first page.

[0107] In one possible implementation, the traversal module 74 is specifically used to determine whether the first page has entered the target mode if the first page has not changed, and if it has entered the target mode, to exit the target mode and enter the next page of the first page. The target mode is used to indicate that the first page has entered a page jump infinite loop; or, if the first page changes to the second page, to detect whether there is a pop-up element in the second page, and if there is a pop-up element in the second page, to process the pop-up element in the second page and enter the next page of the first page.

[0108] In one possible implementation, the aforementioned traversal module 74 is specifically used to: for any page among all pages, perform text recognition on any page using a text recognition model to obtain the text content of any page; and if the target text content of any page matches the target violation content in at least one preset category of violation content, save any page by taking a screenshot, and record the violation category to which the target text content belongs based on the target violation content.

[0109] The page detection device in this application embodiment can be an electronic device or a component within an electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal or other devices besides a terminal. For example, the electronic device can be a mobile phone, tablet computer, laptop computer, PDA, in-vehicle electronic device, mobile internet device (MID), augmented reality (AR) / virtual reality (VR) device, robot, wearable device, ultra-mobile personal computer (UMPC), netbook, or personal digital assistant (PDA), etc. It can also be a server, network attached storage (NAS), personal computer (PC), television (TV), ATM, or self-service machine, etc. This application embodiment does not specifically limit the specific type of device.

[0110] The page detection device in this application embodiment can be a device with an operating system. This operating system can be Android, iOS, or other possible operating systems; this application embodiment does not specifically limit it.

[0111] The page detection device provided in this application embodiment can implement all the processes implemented in the above method embodiments, and will not be repeated here to avoid repetition. Optionally, as Figure 7 As shown, this application embodiment also provides an electronic device 90, including a processor 91 and a memory 92. The memory 92 stores a program or instructions that can run on the processor 91. When the program or instructions are executed by the processor 91, they implement the various steps of the above-described page detection method embodiment and can achieve the same technical effect. To avoid repetition, they will not be described again here.

[0112] It should be noted that the electronic devices in the embodiments of this application include the mobile electronic devices and non-mobile electronic devices described above.

[0113] Figure 8 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of this application.

[0114] The electronic device 100 includes, but is not limited to, components such as: radio frequency unit 101, network module 102, audio output unit 103, input unit 104, sensor 105, display unit 106, user input unit 107, interface unit 108, memory 109, and processor 110.

[0115] Those skilled in the art will understand that the electronic device 100 may also include a power supply (such as a battery) for supplying power to various components. The power supply may be logically connected to the processor 110 through a power management system, thereby enabling functions such as managing charging, discharging, and power consumption through the power management system. Figure 8 The electronic device structure shown does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown, or combine certain components, or have different component arrangements, which will not be elaborated here.

[0116] Processor 110 is configured to launch a target application and detect whether a first object exists in the target application, the first object including at least one of a pop-up element and a target element, the target element including at least one of a registration element and a login element; and, if the first object exists in the target application, process the first object and traverse all pages of the target application to detect whether there is any illegal content on all pages.

[0117] This application provides an electronic device. After launching and entering an application to be detected (e.g., a target application), the electronic device can first determine whether there are specific elements in the application that prevent normal access to the application's pages, such as at least one of pop-up elements, registration elements, and login elements. If such specific elements exist in the application, the electronic device processes them, allowing normal access to the application's pages. This allows for the traversal of all pages in the application and the detection of illegal content on each page. Thus, this solution enables the traversal of all pages in the application to complete the detection of illegal content on all pages, thereby improving the flexibility and efficiency of illegal content detection.

[0118] Optionally, the first object mentioned above includes a pop-up element. The processor 110 is specifically configured to launch the target application, display the target page of the target application; perform text recognition on the target page to obtain at least one page element; and match the at least one page element with at least one preset type of pop-up text information to determine whether a pop-up element exists in the target application.

[0119] Optionally, the processor 110 is specifically configured to perform processing corresponding to the target category on the target page element based on the target pop-up text information when the target page element matches the target pop-up text information in at least one type of pop-up text information; wherein the target page element is any page element among at least one page element, and the target category is the pop-up category corresponding to the target pop-up text information.

[0120] Optionally, the first object mentioned above includes a target element. The processor 110 is specifically configured to launch the target application, display the target page of the target application; perform text recognition on the target page to obtain the text content of the target page; and determine whether a target element exists in the target application based on the text content of the target page.

[0121] Optionally, the processor 110 is specifically used to skip the registration and login process corresponding to the target element when the text content of the target element is included in the text content of the target page.

[0122] Optionally, the processor 110 is specifically configured to perform segmentation processing on the first page of the target application to obtain at least one clickable element, and detect whether there is any illegal content on the first page, wherein the first page is any page in the target application; sequentially perform click processing on at least one clickable element, and detect whether the first page has changed; process the second object corresponding to the first page based on the target result, and proceed to the next page of the first page, wherein the target result is used to indicate whether the first page has changed or not; traverse the remaining pages in the target application, and detect whether there is any illegal content on the remaining pages, wherein the remaining pages are pages in the target application other than the first page.

[0123] Optionally, the processor 110 is specifically configured to, if the first page has not changed, determine whether the first page has entered the target mode, and if it has entered the target mode, exit the target mode and enter the next page of the first page, wherein the target mode is used to instruct the first page to enter a page jump infinite loop; or, if the first page changes to the second page, detect whether there is a pop-up element in the second page, and if there is a pop-up element in the second page, process the pop-up element in the second page and enter the next page of the first page.

[0124] Optionally, the processor 110 is specifically used to perform text recognition on any page among all pages using a text recognition model to obtain the text content of any page; and if the target text content of any page matches the target violation content in at least one preset category of violation content, the processor saves the page by taking a screenshot and records the violation category to which the target text content belongs based on the target violation content.

[0125] The electronic device provided in this application embodiment can implement the various processes implemented in the above method embodiments and achieve the same technical effect. To avoid repetition, it will not be described again here.

[0126] For details on the beneficial effects of the various implementation methods in this embodiment, please refer to the beneficial effects of the corresponding implementation methods in the above method embodiments. To avoid repetition, these will not be repeated here.

[0127] It should be understood that, in this embodiment, the input unit 104 may include a graphics processing unit (GPU) 1041 and a microphone 1042. The GPU 1041 processes image data of still images or videos obtained by an image capture device (such as a camera) in video capture mode or image capture mode. The display unit 106 may include a display panel 1061, which may be configured in the form of a liquid crystal display, an organic light-emitting diode, or the like. The user input unit 107 includes at least one of a touch panel 1071 and other input devices 1072. The touch panel 1071 is also called a touch screen. The touch panel 1071 may include a touch detection device and a touch controller. Other input devices 1072 may include, but are not limited to, a physical keyboard, function keys (such as volume control buttons, power buttons, etc.), a trackball, a mouse, and a joystick, which will not be described in detail here.

[0128] The memory 109 can be used to store software programs and various data. The memory 109 may primarily include a first storage area for storing programs or instructions and a second storage area for storing data. The first storage area may store the operating system, application programs or instructions required for at least one function (such as sound playback, image playback, etc.). Furthermore, the memory 109 may include volatile memory or non-volatile memory, or both. The non-volatile memory may be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. Volatile memory can be random access memory (RAM), static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDRSDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM), and direct memory bus RAM (DRRAM). The memory 109 in the embodiments of this application includes, but is not limited to, these and any other suitable types of memory.

[0129] Processor 110 may include one or more processing units; optionally, processor 110 integrates an application processor and a modem processor, wherein the application processor mainly handles operations involving the operating system, user interface, and applications, and the modem processor mainly handles wireless communication signals, such as a baseband processor. It is understood that the aforementioned modem processor may also not be integrated into processor 110.

[0130] This application also provides a readable storage medium storing a program or instructions. When the program or instructions are executed by a processor, they implement the various processes of the above-described page detection method embodiments and achieve the same technical effect. To avoid repetition, they will not be described again here.

[0131] The processor is the processor in the electronic device described in the above embodiments. The readable storage medium includes computer-readable storage media, such as computer read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk.

[0132] This application embodiment also provides a chip, which includes a processor and a communication interface. The communication interface is coupled to the processor. The processor is used to run programs or instructions to implement the various processes of the above-described page detection method embodiment and can achieve the same technical effect. To avoid repetition, it will not be described again here.

[0133] It should be understood that the chip mentioned in the embodiments of this application may also be referred to as a system-on-a-chip, system chip, chip system, or system-on-a-chip, etc.

[0134] This application provides a computer program product, which is stored in a storage medium and executed by at least one processor to implement the various processes of the page detection method embodiments described above, and can achieve the same technical effect. To avoid repetition, it will not be described again here.

[0135] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element. Furthermore, it should be noted that the scope of the methods and apparatuses in the embodiments of this application is not limited to performing functions in the order shown or discussed, but may also include performing functions substantially simultaneously or in the reverse order, depending on the functions involved. For example, the described methods may be performed in a different order than described, and various steps may be added, omitted, or combined. Additionally, features described with reference to certain examples may be combined in other examples.

[0136] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a computer software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods described in the various embodiments of this application.

[0137] The embodiments of this application have been described above with reference to the accompanying drawings. However, this application is not limited to the specific embodiments described above. The specific embodiments described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms under the guidance of this application without departing from the spirit and scope of the claims, and all of these forms are within the protection scope of this application.

Claims

1. A page detection method, characterized in that, The method includes: Launch the target application and detect whether a first object exists in the target application. The first object includes at least one of a pop-up element and a target element. The target element includes at least one of a registration element and a login element. If the first object exists in the target application, process the first object, and traverse all pages of the target application to detect whether there is any illegal content on all pages; The process of traversing all pages of the target application and detecting whether any pages contain illegal content includes: The first page of the target application is segmented to obtain at least one clickable element, and the first page is checked for any page in the target application. Click processing is performed on at least one clickable element in sequence, and it is detected whether the first page has changed; Based on the target result, the second object corresponding to the first page is processed, and the next page of the first page is entered. The target result is used to indicate whether the first page has changed or not. Traverse the remaining pages in the target application and detect whether there is any illegal content on the remaining pages. The remaining pages are the pages in the target application other than the first page. The step of processing the second object corresponding to the first page based on the target result and proceeding to the next page of the first page includes: If the first page remains unchanged, determine whether the first page has entered the target mode. If the first page has entered the target mode, exit the target mode and proceed to the next page of the first page. The target mode is used to indicate that the first page has entered a page jump infinite loop.

2. The method according to claim 1, characterized in that, The first object includes the pop-up element; launching the target application and detecting whether the first object exists in the target application includes: Launch the target application and display the target page of the target application; Perform text recognition on the target page to obtain at least one page element; The at least one page element is matched with at least one type of preset pop-up text information to determine whether the pop-up element exists in the target application.

3. The method according to claim 2, characterized in that, When the first object exists in the target application, the processing of the first object includes: If a target page element matches the target pop-up text information in at least one type of pop-up text information, then based on the target pop-up text information, the target page element is processed according to the target category. Wherein, the target page element is any page element among the at least one page element, and the target category is the pop-up category corresponding to the target pop-up text information.

4. The method according to claim 1, characterized in that, The first object includes the target element; launching the target application and detecting whether the first object exists in the target application includes: Launch the target application and display the target page of the target application; Perform text recognition on the target page to obtain the text content of the target page; Based on the text content of the target page, determine whether the target element exists in the target application.

5. The method according to claim 4, characterized in that, When the first object exists in the target application, the processing of the first object includes: If the text content of the target element is included in the text content of the target page, the registration and login process corresponding to the target element is skipped.

6. The method according to claim 1, characterized in that, The step of processing the second object corresponding to the first page based on the target result and proceeding to the next page of the first page includes: When the first page changes to the second page, it is detected whether there is a pop-up element on the second page. If there is a pop-up element on the second page, the pop-up element on the second page is processed, and the user proceeds to the next page after the first page.

7. The method according to claim 1 or 6, characterized in that, The detection of whether any of the pages contain illegal content includes: For any page among all the pages, a text recognition model is used to perform text recognition on the arbitrary page to obtain the text content of the arbitrary page; If the target text content on any page matches the target violation content in at least one preset category of violation content, the arbitrary page is saved by taking a screenshot, and the violation category to which the target text content belongs is recorded based on the target violation content.

8. A page detection device, characterized in that, The device includes: a startup module, a detection module, a processing module, and a traversal module; The startup module is used to launch the target application; The detection module is used to detect whether there is a first object in the target application launched by the startup module. The first object includes at least one of a pop-up element and a target element. The target element includes at least one of a registration element and a login element. The processing module is used to process the first object detected by the detection module when the first object exists in the target application. The traversal module is used to traverse all pages of the target application and detect whether there is any illegal content on all pages; The traversal module is specifically used to perform segmentation processing on the first page of the target application to obtain at least one clickable element, and to detect whether there is any illegal content on the first page, where the first page is any page in the target application; to perform click processing on the at least one clickable element in sequence, and to detect whether the first page has changed; to process the second object corresponding to the first page based on the target result, and to enter the next page of the first page, where the target result is used to indicate whether the first page has changed or not; and to traverse the remaining pages in the target application, and to detect whether there is any illegal content on the remaining pages, where the remaining pages are pages in the target application other than the first page. The traversal module is specifically used to determine whether the first page has entered the target mode if the first page has not changed, and if the first page has entered the target mode, to exit the target mode and enter the next page of the first page. The target mode is used to indicate that the first page has entered a page jump infinite loop.

9. An electronic device, characterized in that, It includes a processor and a memory, the memory storing a program or instructions that can run on the processor, the program or instructions being executed by the processor to implement the steps of the page detection method as described in any one of claims 1 to 7.

10. A readable storage medium, characterized in that, The readable storage medium stores a program or instructions that, when executed by a processor, implement the steps of the page detection method as described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • Automatic popup window processing method and device

    CN112565523A

  • Mobile application illegal content scanning method and system, equipment and medium

    CN113569861A