Watermark detection method and device
By detecting the status of the watermark sub-form, including the coverage area and whether it is stuck, the problem of protection failure caused by the failure of the watermark sub-form is solved, ensuring the normal operation of the watermark device and the security of electronic content.
Patent Information
- Application Number
- CN202411060504.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-02
- Publication Date
- 2024-10-29
AI Technical Summary
The watermark subform is prone to malfunctions during runtime, which affects the protection of electronic content and causes the watermark to become invalid.
The detection of the watermark subform is achieved by obtaining the display form data of the application to be detected, determining the subform data, and judging the status of the watermark subform based on the preset watermark form attribute conditions, including the coverage area and whether it is stuck. .
This ensures the normal operation of the watermark device and the effective protection of electronic content.
Smart Images

Figure CN118862027A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a watermark detection method and device. Background Art
[0002] In modern technology, in order to ensure the security of important content, sensitive information and other materials, and to prevent information from being stolen, watermarks are usually used to add watermarks of specific content to the content that needs to be protected to protect the unauthorized theft and dissemination of the content.
[0003] In electronic devices, the protection of electronic content can be achieved by adding a watermark to the display window of the application through a watermark sub-window generated by a watermark device. However, if a failure occurs during the operation of the watermark sub-window, the watermark addition will be affected, and the protection of the electronic content will be lost. Summary of the invention
[0004] In view of this, an embodiment of the present invention provides a watermark detection method, which can identify a watermark sub-window in a display window and detect the state of the watermark sub-window to ensure the normal operation of a watermark device.
[0005] To achieve the above object, according to a first aspect of an embodiment of the present invention, a watermark detection method is provided, comprising:
[0006] Acquire the data of the display window of the application to be detected according to the monitoring strategy;
[0007] Determine the data of the sub-window based on the data of the display window of the application to be detected;
[0008] Determining the data of the watermark sub-window in the data of the sub-window according to the condition of the preset watermark window attribute;
[0009] The state of the watermark sub-window is judged based on the data of the watermark sub-window, and the detection result of the watermark sub-window is obtained.
[0010] Optionally, the determining the data of the watermark subwindow in the data of the subwindow according to the condition of the preset watermark window attribute includes:
[0011] Determine whether there is target data in the data of the sub-window that meets the conditions of the preset watermark window attribute;
[0012] In response to the judgment result that there is target data that meets the condition of the preset watermark window attribute, the target data is determined to be data of the watermark subwindow.
[0013] Optionally, judging the state of the watermark sub-window based on the data of the watermark sub-window to obtain the detection result of the watermark sub-window includes:
[0014] Determine whether the coverage area of the watermark sub-window is a preset area based on the data of the watermark sub-window, and obtain a first determination result;
[0015] Determine whether the watermark sub-window is stuck based on the data of the watermark sub-window, and obtain a second determination result;
[0016] The detection result of the watermark sub-window is determined according to the first judgment result and the second judgment result.
[0017] Optionally, before acquiring the data of the display window of the application to be detected, the method further includes:
[0018] Sending a monitoring request to a server, so that the server determines a corresponding monitoring strategy based on the monitoring request;
[0019] Receive the monitoring strategy sent by the server.
[0020] Optionally, judging whether the coverage area of the watermark sub-window is a preset area based on the data of the watermark sub-window to obtain a first judgment result includes:
[0021] Determining a coverage area of the watermark sub-window based on the data of the watermark sub-window;
[0022] Based on the data of the display window of the application to be detected, determining that the coverage area of the target window in the display window of the application to be detected is a preset area, and the target window is the parent window of the watermark subwindow;
[0023] It is determined whether the coverage area of the watermark sub-window includes the preset area to obtain a first determination result.
[0024] Optionally, the determining, based on the data of the display window of the application to be detected, that the coverage area of the target window in the display window of the application to be detected is a preset area includes:
[0025] Based on the data of the display window of the application to be detected, determining the coverage area of each target window in the display window of the application to be detected;
[0026] The coverage area of each target window is merged.
[0027] Optionally, judging whether the watermark sub-window is stuck based on the data of the watermark sub-window to obtain a second judgment result includes:
[0028] Sending a detection message to the watermark sub-window;
[0029] If no feedback message sent by the watermark sub-window based on the detection message is received within a preset time period, determining that the second judgment result is that the watermark sub-window is stuck;
[0030] If a feedback message sent by the watermark sub-window based on the detection message is received within a preset time period, it is determined that the second judgment result is that the watermark sub-window is not stuck.
[0031] Optionally, if a feedback message sent by the watermark sub-window based on the detection message is received within a preset time period, determining that the second judgment result is that the watermark sub-window is not stuck includes:
[0032] If a feedback message sent by the watermark sub-window based on the detection message is received within a preset time period, and the time difference between receiving the feedback message and sending the detection message is greater than a preset threshold, it is determined that the second judgment result includes that the watermark sub-window is not stuck and there is a refresh problem in the watermark sub-window.
[0033] Optionally, the watermark window attribute includes at least one of a transparency attribute, a visibility attribute, a mouse penetration attribute, and a watermark content attribute.
[0034] According to a second aspect of an embodiment of the present invention, there is provided a watermark detection device, comprising:
[0035] An acquisition module, used to acquire data of a display window of an application to be detected according to a monitoring strategy;
[0036] A determination module, configured to determine the data of the sub-window based on the data of the display window of the application to be detected; and determine the data of the watermark sub-window in the data of the sub-window according to the condition of the preset watermark window attribute;
[0037] The judging module is used to judge the state of the watermark sub-window based on the data of the watermark sub-window, and obtain the detection result of the watermark sub-window.
[0038] According to a third aspect of an embodiment of the present invention, there is provided an electronic device, including:
[0039] One or more processors; a storage device for storing one or more programs,
[0040] When the one or more programs are executed by the one or more processors, the one or more processors implement the method provided in the first aspect of the embodiment of the present invention.
[0041] According to a fourth aspect of an embodiment of the present invention, a computer-readable medium is provided, on which a computer program is stored, and when the program is executed by a processor, the method provided by the first aspect of the embodiment of the present invention is implemented.
[0042] An embodiment of the above invention has the following advantages or beneficial effects: the watermark sub-window in the display window is determined by presetting the conditions of the watermark window attributes, and the status of the watermark sub-window, such as the coverage area and whether it is stuck, is judged to obtain the detection data of the watermark sub-window, thereby realizing the detection of the operating status of the watermark device and ensuring the normal use of the watermark.
[0043] The further effects of the above-mentioned non-conventional optional manner will be described below in conjunction with the specific implementation manner. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] The accompanying drawings are used to better understand the present invention and do not constitute an improper limitation of the present invention.
[0045] Figure 1 is a schematic diagram of the main process of the watermark detection method according to an embodiment of the present invention;
[0046] Figure 2 is a schematic diagram of main modules of a watermark detection device according to an embodiment of the present invention;
[0047] Figure 3 is an exemplary system architecture diagram to which embodiments of the present invention may be applied;
[0048] Figure 4 It is a schematic diagram of the structure of a computer system of a terminal device or a server suitable for implementing an embodiment of the present invention. DETAILED DESCRIPTION
[0049] The following is a description of exemplary embodiments of the present invention in conjunction with the accompanying drawings, including various details of the embodiments of the present invention to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present invention. Similarly, for clarity and conciseness, the description of well-known functions and structures is omitted in the following description.
[0050] It should be noted that the collection, collection, updating, analysis, processing, use, transmission, storage and other aspects of user personal information involved in the technical solution of this disclosure are in compliance with the provisions of relevant laws and regulations, are used for legitimate purposes, and do not violate public order and good morals. Necessary measures are taken for user personal information to prevent illegal access to user personal information data and maintain the security of user personal information, network security and national security.
[0051] Figure 1 FIG. 1 is a schematic diagram of the main process of the watermark detection method according to an embodiment of the present invention. Figure 1 As shown, including:
[0052] Step S101, obtaining data of a display window of an application to be detected according to a monitoring strategy.
[0053] According to the acquired monitoring strategy, the monitored application corresponding to the monitoring strategy, that is, the application to be detected, is determined. The data of the display window of the application to be detected is obtained, specifically including all currently displayed windows: parent window and child window.
[0054] Step S102: determining the data of the sub-window based on the data of the display window of the application to be detected.
[0055] After obtaining the data of the display window of the application to be detected, the subwindow therein is determined, and the data of the subwindow is determined.
[0056] Specifically, when acquiring data of a display window, data of all subwindows are acquired level by level according to the Z order of the window.
[0057] Step S103, determining the watermark sub-window data in the sub-window data according to the preset watermark window attribute condition.
[0058] According to the preset watermark window attribute conditions, the watermark subwindow among all the subwindows of the application to be detected is determined, and the data of the watermark subwindow is further determined. Among them, the attributes of the watermark window that are different from other subwindows can be used as the set judgment conditions to distinguish the watermark window from other ordinary subwindows. For example, the watermark subwindow has attributes such as mouse penetrability and window transparency. Based on the above attributes, the window with the attributes of mouse penetrability and window transparency among all subwindows can be determined as the watermark subwindow.
[0059] Step S104, judging the state of the watermark sub-window based on the data of the watermark sub-window, and obtaining the detection result of the watermark sub-window.
[0060] The running state of the current watermark sub-window is judged according to the determined data of the watermark sub-window, including whether the display window of the current application to be detected contains the watermark sub-window, whether the watermark sub-window covers the display window of the application to be detected, etc. The detection result of the watermark sub-window is determined according to the state data of the watermark sub-window obtained by judgment.
[0061] The method for watermark detection provided in an embodiment of the present invention can determine the data of the watermark sub-window based on the data of the display window of the application to be detected, and judge the coverage area of the watermark sub-window and whether the watermark sub-window is stuck in combination with the data of the watermark sub-window, thereby realizing the detection of the running status of the watermark sub-window and ensuring the normal operation of the watermark.
[0062] Optionally, according to the condition of the preset watermark window attribute, determining the data of the watermark subwindow in the data of the subwindow includes: judging whether there is target data satisfying the condition of the preset watermark window attribute in the data of the subwindow; in response to the judgment result that there is target data satisfying the condition of the preset watermark window attribute, determining the target data as the data of the watermark subwindow. Before obtaining the data of the watermark subwindow, firstly judging whether the obtained display window of the application to be detected contains the data of the watermark subwindow, when judging that there is a window with the same attribute as the watermark subwindow in the obtained display window data, it is determined that there is a watermark subwindow, and the data of the watermark subwindow is obtained therefrom.
[0063] The watermark detection method provided by the embodiment of the present invention can monitor the existence of the watermark sub-window through the conditions of the watermark sub-window attributes, prevent the watermark sub-window from being cleared or hidden by other software, thereby causing the watermark to become invalid, and help to achieve accurate watermark detection.
[0064] Optionally, the state of the watermark sub-window is judged based on the data of the watermark sub-window to obtain the detection result of the watermark sub-window, including: judging whether the coverage area of the watermark sub-window is a preset area based on the data of the watermark sub-window to obtain a first judgment result; judging whether the watermark sub-window is stuck based on the data of the watermark sub-window to obtain a second judgment result; determining the detection result of the watermark sub-window according to the first judgment result and the second judgment result.
[0065] The coverage area of the watermark sub-window is determined according to the data of the determined watermark sub-window, and the coverage area of the watermark sub-window is compared with the preset area to determine whether they completely overlap, and a judgment result is obtained. Among them, the preset area is generally set to the display area of the parent window of the watermark sub-window. If there are two or more parent windows, it is set to the union of the coverage areas of all parent windows.
[0066] Specifically, when determining whether the coverage area of the watermark sub-window and the preset area overlap, the position information (coordinate range) of the sub-window is compared with the position information (coordinate range) of the preset area to obtain a first determination result. When the two areas do not completely overlap, the first determination result is that the watermark sub-window is wrong, or the cause of the error (the coverage area of the watermark sub-window is wrong).
[0067] According to the running status data of the watermark sub-window, it is determined whether the watermark sub-window is stuck, and a second judgment result is obtained. The running status data is data fed back by the watermark sub-window based on the received detection message. When the feedback data is that the watermark sub-window is stuck, the second judgment result is determined to be a watermark sub-window error, or an error cause (window stuck).
[0068] Combine the first judgment result and the second judgment result to comprehensively judge the detection result of the watermark subwindow. For example, when any of the first judgment result and the second judgment result is that the watermark subwindow is wrong, the detection result of the watermark subwindow is determined to be an operation state error; when the first judgment result and the second judgment result are specific error causes, the determined detection result displays the cause of the error in addition to displaying the operation state error.
[0069] According to the watermark detection method provided by the embodiment of the present invention, the data of the watermark sub-window can be determined according to the data of the display window of the application to be detected, and the coverage area of the watermark sub-window and whether the watermark sub-window is stuck can be judged in combination with the data of the watermark sub-window. In combination with the above judgment results, the running state of the watermark sub-window can be detected to ensure the normal operation of the watermark.
[0070] Optionally, before obtaining the data of the display window of the application to be detected, the method further includes: sending a monitoring request to the server, so that the server determines a corresponding monitoring strategy based on the monitoring request; and receiving the monitoring strategy sent by the server.
[0071] Before the running status detection of the watermark sub-window is performed, a network request is sent to the server to request the monitoring strategy corresponding to the application to be detected. The monitoring strategy corresponding to the network request sent by the server is received. Among them, the monitoring strategy has a one-to-one correspondence with the device generated by the watermark sub-window, and personalized monitoring strategies can be set for different watermark devices.
[0072] Optionally, judging whether the coverage area of the watermark sub-window is a preset area based on the data of the watermark sub-window to obtain a first judgment result includes: determining the coverage area of the watermark sub-window based on the data of the watermark sub-window; determining that the coverage area of the target window in the display window of the application to be detected is the preset area based on the data of the display window of the application to be detected, the target window being the parent window of the watermark sub-window; judging whether the coverage area of the watermark sub-window includes the preset area to obtain the first judgment result.
[0073] According to the determined data of the watermark sub-window, the coordinate range of the coverage area of the watermark sub-window is determined. According to the determined data of the display window of the application to be detected, the parent window of the watermark sub-window is determined, and further, the coordinate range of the coverage area of the parent window is determined to be the coordinate range of the preset area. Compare the coordinate range of the watermark sub-window and the coordinate range of the preset area to see if they are included, and obtain a comparison result as the first judgment result.
[0074] Optionally, when comparing the coordinate range of the watermark sub-window and the coordinate range of the preset area, in order to obtain a more accurate result, it can be determined whether the two ranges are the same, and the corresponding result can be obtained as the first determination result.
[0075] The method for watermark detection provided by the embodiment of the present invention can determine the operating status of the watermark sub-window by judging the coverage relationship between the coverage range of the watermark sub-window and the range of the preset area, and obtain a first judgment result for accurate subsequent watermark detection to obtain accurate results.
[0076] Optionally, based on the data of the display window of the application to be detected, determining the coverage area of the target window in the display window of the application to be detected as a preset area includes: based on the data of the display window of the application to be detected, determining the coverage area of each target window in the display window of the application to be detected; and merging the coverage area of each target window.
[0077] After determining the watermark sub-window in the display window of the application to be detected, determine the target window corresponding to the watermark sub-window. The target window can be determined as the only parent window corresponding to the watermark sub-window; or when the parent window corresponding to the watermark sub-window also has a corresponding parent window, the target window includes the parent window corresponding to the watermark sub-window and the parent window corresponding to the parent window. When the number of target windows exceeds 1, determine the coverage area of each target window, and merge the coverage areas of all target windows, and the obtained union is used as the final target window coverage area.
[0078] Optionally, judging whether the watermark sub-window is stuck based on the data of the watermark sub-window to obtain a second judgment result includes: sending a detection message to the watermark sub-window; if no feedback message sent by the watermark sub-window based on the detection message is received within a preset time period, determining that the second judgment result is that the watermark sub-window is stuck; if a feedback message sent by the watermark sub-window based on the detection message is received within the preset time period, determining that the second judgment result is that the watermark sub-window is not stuck.
[0079] When judging whether the watermark sub-window is stuck, a detection message, such as a WIN_NULL message, is sent to the watermark sub-window through the system interface, and a feedback message from the watermark sub-window is waited for. If a feedback message from the watermark sub-window is received within a preset time period, it means that the watermark sub-window is not stuck; if no feedback message is received, it means that the watermark sub-window is stuck.
[0080] Optionally, if a feedback message sent by the watermark sub-window based on the detection message is received within a preset time period, the second judgment result is determined to be that the watermark sub-window is not stuck, including: if a feedback message sent by the watermark sub-window based on the detection message is received within a preset time period, and the time difference between receiving the feedback message and sending the detection message is greater than a preset threshold, the second judgment result is determined to include that the watermark sub-window is not stuck and there is a refresh problem in the watermark sub-window.
[0081] If a feedback message is received within a preset time period, but the time for receiving the feedback message is relatively long, that is, exceeds a preset threshold, it indicates that there is a refresh efficiency problem in the watermark sub-window.
[0082] Optionally, the watermark window attribute includes at least one of a transparency attribute, a visible attribute, a mouse-penetrable attribute, and a watermark content attribute. For a watermark subwindow, its attributes include attributes such as window transparency, window content visibility, window mouse-penetrable, and single and consistent watermark content in the window. When setting the watermark subwindow judgment condition, it can be set according to at least one of the above attributes. In order to ensure the accuracy of the watermark subwindow judgment, a window that satisfies the above four attribute conditions at the same time can be set as a watermark subwindow.
[0083] According to the watermark detection method provided by the embodiment of the present invention, the data of the watermark sub-window can be determined according to the data of the display window of the application to be detected, and the coverage area of the watermark sub-window and whether the watermark sub-window is stuck can be judged in combination with the data of the watermark sub-window. The running state of the watermark can be judged by identifying the coverage area of the watermark sub-window, and the running state of the watermark can be more accurately determined by the feedback of the water factor window to the detection message. Combining the judgment results corresponding to the two methods can realize the detection of the running state of the watermark sub-window and ensure the normal operation of the watermark.
[0084] Figure 2 FIG. 2 is a schematic diagram of the main process of the watermark detection device 200 according to an embodiment of the present invention. Figure 2 As shown, including:
[0085] The acquisition module 201 is used to acquire the data of the display window of the application to be detected according to the monitoring strategy;
[0086] The determination module 202 is used to determine the data of the sub-window based on the data of the display window of the application to be detected; and determine the data of the watermark sub-window in the data of the sub-window according to the condition of the preset watermark window attribute;
[0087] The judgment module 203 is used to judge the state of the watermark sub-window based on the data of the watermark sub-window, and obtain the detection result of the watermark sub-window.
[0088] According to the watermark detection device provided by the embodiment of the present invention, the data of the watermark sub-window can be determined according to the data of the display window of the application to be detected, and the coverage area of the watermark sub-window and whether the watermark sub-window is stuck can be determined in combination with the data of the watermark sub-window. In combination with the above judgment results, the running state of the watermark sub-window can be detected to ensure the normal operation of the watermark.
[0089] Optionally, the determination module 202 is used to determine the data of the watermark subwindow in the data of the subwindow according to the conditions of the preset watermark window attributes, including: a judgment module 203 is used to judge whether there is data of the watermark subwindow according to the conditions of the preset watermark window attributes, and obtain a judgment result; the determination module 202 is used to determine the watermark subwindow in the subwindow data in response to the judgment result that the data of the watermark subwindow exists.
[0090] Optionally, the judgment module 203 is used to judge the state of the watermark sub-window based on the data of the watermark sub-window to obtain the detection result of the watermark sub-window, including: the judgment module 203 is used to judge whether the coverage area of the watermark sub-window is a preset area based on the data of the watermark sub-window to obtain a first judgment result; the judgment module 203 is used to judge whether the watermark sub-window is stuck based on the data of the watermark sub-window to obtain a second judgment result; the determination module 202 is used to determine the detection result of the watermark sub-window according to the first judgment result and the second judgment result.
[0091] Optionally, the device further includes: a sending module 204, used to send a monitoring request to the server, so that the server determines a corresponding monitoring strategy based on the monitoring request; and a receiving module 205, used to receive the monitoring strategy sent by the server.
[0092] Optionally, the judgment module 203 is used to judge whether the coverage area of the watermark sub-window is a preset area based on the data of the watermark sub-window to obtain a first judgment result, including: a determination module 202 is used to determine the coverage area of the watermark sub-window based on the data of the watermark sub-window; based on the data of the display window of the application to be detected, determine that the coverage area of the target window in the display window of the application to be detected is the preset area, and the target window is the parent window of the watermark sub-window; the judgment module 203 is used to judge whether the coverage area of the watermark sub-window includes the preset area to obtain a first judgment result.
[0093] Optionally, the determination module 202 is used to determine, based on the data of the display window of the application to be detected, that the coverage area of the target window in the display window of the application to be detected is a preset area, including: the determination module 202 is used to determine, based on the data of the display window of the application to be detected, the coverage area of each target window in the display window of the application to be detected; and the processing module 206 is used to merge the coverage area of each target window.
[0094] Optionally, a judgment module 203 is used to judge whether the watermark sub-window is stuck based on the data of the watermark sub-window to obtain a second judgment result, including: a sending module 204, used to send a detection message to the watermark sub-window; a determination module 202, used to determine that the second judgment result is that the watermark sub-window is stuck if no feedback message sent by the watermark sub-window based on the detection message is received within a preset time period; if a feedback message sent by the watermark sub-window based on the detection message is received within the preset time period, determine that the second judgment result is that the watermark sub-window is not stuck.
[0095] Optionally, the determination module 202 is used to determine that the second judgment result is that the watermark sub-window is not stuck if a feedback message sent by the watermark sub-window based on the detection message is received within a preset time period, including: the determination module 202 is used to determine that the second judgment result includes that the watermark sub-window is not stuck and there is a refresh problem in the watermark sub-window if a feedback message sent by the watermark sub-window based on the detection message is received within a preset time period, and the time difference between receiving the feedback message and sending the detection message is greater than a preset threshold.
[0096] Optionally, the watermark window attribute includes at least one of a transparency attribute, a visibility attribute, a mouse penetration attribute, and a watermark content attribute.
[0097] According to the watermark detection device provided by the embodiment of the present invention, the data of the watermark sub-window can be determined according to the data of the display window of the application to be detected, and the coverage area of the watermark sub-window and whether the watermark sub-window is stuck can be judged in combination with the data of the watermark sub-window. The running state of the watermark can be judged by identifying the coverage area of the watermark sub-window, and the running state of the watermark can be more accurately determined by the feedback of the water factor window to the detection message. Combining the judgment results corresponding to the two methods can realize the detection of the running state of the watermark sub-window and ensure the normal operation of the watermark.
[0098] Figure 3 An exemplary system architecture 300 is shown to which the watermark detection method or watermark detection apparatus according to the embodiment of the present invention can be applied.
[0099] like Figure 3 As shown, the system architecture 300 may include terminal devices 301, 302, 303, a network 304 and a server 305. The network 304 is used to provide a medium for communication links between the terminal devices 301, 302, 303 and the server 305. The network 304 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.
[0100] Users can use terminal devices 301, 302, 303 to interact with server 305 through network 304 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 301, 302, 303, such as shopping applications, web browser applications, search applications, instant messaging tools, email clients, social platform software, etc. (only for example).
[0101] The terminal devices 301 , 302 , and 303 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop computers, and desktop computers, etc.
[0102] The server 305 may be a server that provides various services, such as a background management server (only an example) that provides support for shopping websites browsed by users using the terminal devices 301, 302, and 303. The background management server may analyze and process the received watermark detection request and other data, and feed back the processing results (such as watermark detection results - only an example) to the terminal device.
[0103] It should be noted that the watermark detection method provided in the embodiment of the present invention is generally executed by the server 305 , and accordingly, the watermark detection device is generally arranged in the server 305 .
[0104] It should be understood that Figure 3 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to implementation requirements.
[0105] Reference below Figure 4 , which shows a schematic diagram of the structure of a computer system 400 of a terminal device suitable for implementing an embodiment of the present invention. Figure 4 The terminal device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.
[0106] like Figure 4 As shown, the computer system 400 includes a central processing unit (CPU) 401, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 402 or a program loaded from a storage part 408 into a random access memory (RAM) 403. In the RAM 403, various programs and data required for the operation of the system 400 are also stored. The CPU 401, the ROM 402, and the RAM 403 are connected to each other through a bus 404. An input / output (I / O) interface 405 is also connected to the bus 404.
[0107] The following components are connected to the I / O interface 405: an input section 406 including a keyboard, a mouse, etc.; an output section 407 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 408 including a hard disk, etc.; and a communication section 409 including a network interface card such as a LAN card, a modem, etc. The communication section 409 performs communication processing via a network such as the Internet. A drive 410 is also connected to the I / O interface 405 as needed. A removable medium 411, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 410 as needed, so that a computer program read therefrom is installed into the storage section 408 as needed.
[0108] In particular, according to the embodiments disclosed in the present invention, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present invention include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program contains program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 409, and / or installed from the removable medium 411. When the computer program is executed by the central processing unit (CPU) 401, the above-mentioned functions defined in the system of the present invention are executed.
[0109] It should be noted that the computer-readable medium shown in the present invention may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present invention, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In the present invention, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.
[0110] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present invention. In this regard, each box in the flow chart or block diagram can represent a module, a program segment, or a part of a code, and the above-mentioned module, program segment, or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0111] The modules involved in the embodiments of the present invention may be implemented by software or hardware. The modules described may also be arranged in a processor, for example, they may be described as: a processor including an acquisition module, a determination module and a judgment module. The names of these modules do not constitute a limitation on the modules themselves in certain cases, for example, the acquisition module may also be described as "a module for acquiring data of a display window of an application to be detected according to a monitoring strategy".
[0112] As another aspect, the present invention further provides a computer-readable medium, which may be included in the device described in the above embodiment; or may exist independently without being assembled into the device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by a device, the device includes: obtaining data of a display window of a to-be-detected application according to a monitoring strategy;
[0113] Determine the data of the sub-window based on the data of the display window of the application to be detected;
[0114] According to the condition of the preset watermark window attribute, the data of the watermark sub-window in the data of the sub-window is determined;
[0115] Based on the data of the watermark sub-window, it is determined whether the coverage area of the watermark sub-window is a preset area, and a first determination result is obtained;
[0116] Determine whether the watermark sub-window is stuck based on the data of the watermark sub-window, and obtain a second determination result;
[0117] The detection result of the watermark sub-window is determined according to the first judgment result and the second judgment result.
[0118] According to the technical solution of the embodiment of the present invention, the watermark subwindow in the display window can be identified, and the state of the watermark subwindow can be detected to ensure the normal operation of the watermark device.
[0119] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may occur depending on design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A watermark detection method, characterized in that: include: Acquire the data of the display window of the application to be detected according to the monitoring strategy; Determine the data of the sub-window based on the data of the display window of the application to be detected; Determining the data of the watermark sub-window in the data of the sub-window according to the condition of the preset watermark window attribute; The state of the watermark sub-window is judged based on the data of the watermark sub-window, and the detection result of the watermark sub-window is obtained.
2. The method according to claim 1, characterized in that The step of determining the watermark sub-window data in the sub-window data according to the condition of the preset watermark window attribute includes: Determine whether there is target data in the data of the sub-window that meets the conditions of the preset watermark window attribute; In response to the judgment result that there is target data that meets the condition of the preset watermark window attribute, the target data is determined to be data of the watermark subwindow.
3. The method according to claim 1, characterized in that: The determining the state of the watermark sub-window based on the data of the watermark sub-window to obtain the detection result of the watermark sub-window includes: Determine whether the coverage area of the watermark sub-window is a preset area based on the data of the watermark sub-window, and obtain a first determination result; Determine whether the watermark sub-window is stuck based on the data of the watermark sub-window, and obtain a second determination result; The detection result of the watermark sub-window is determined according to the first judgment result and the second judgment result.
4. The method according to claim 1, characterized in that: Before obtaining the data of the display window of the application to be detected, the method further includes: Sending a monitoring request to a server, so that the server determines a corresponding monitoring strategy based on the monitoring request; Receive the monitoring strategy sent by the server.
5. The method according to claim 3, characterized in that: The determining, based on the data of the watermark sub-window, whether the coverage area of the watermark sub-window is a preset area to obtain a first determination result includes: Determining a coverage area of the watermark sub-window based on the data of the watermark sub-window; Based on the data of the display window of the application to be detected, determining that the coverage area of the target window in the display window of the application to be detected is a preset area, and the target window is the parent window of the watermark subwindow; It is determined whether the coverage area of the watermark sub-window includes the preset area to obtain a first determination result.
6. The method according to claim 5, characterized in that The determining, based on the data of the display window of the application to be detected, that the coverage area of the target window in the display window of the application to be detected is a preset area comprises: Based on the data of the display window of the application to be detected, determining the coverage area of each target window in the display window of the application to be detected; The coverage area of each target window is merged.
7. The method according to claim 3, characterized in that The determining whether the watermark sub-window is stuck based on the data of the watermark sub-window to obtain a second determination result includes: Sending a detection message to the watermark sub-window; If no feedback message sent by the watermark sub-window based on the detection message is received within a preset time period, determining that the second judgment result is that the watermark sub-window is stuck; If a feedback message sent by the watermark sub-window based on the detection message is received within a preset time period, it is determined that the second judgment result is that the watermark sub-window is not stuck.
8. The method according to claim 7, characterized in that If a feedback message sent by the watermark sub-window based on the detection message is received within a preset time period, determining that the second judgment result is that the watermark sub-window is not stuck includes: If a feedback message sent by the watermark sub-window based on the detection message is received within a preset time period, and the time difference between receiving the feedback message and sending the detection message is greater than a preset threshold, it is determined that the second judgment result includes that the watermark sub-window is not stuck and there is a refresh problem in the watermark sub-window.
9. The method according to any one of claims 1 to 8, characterized in that: The watermark window attribute includes at least one of a transparency attribute, a visibility attribute, a mouse penetration attribute, and a watermark content attribute.
10. A watermark detection device, characterized in that: include: An acquisition module, used to acquire data of a display window of an application to be detected according to a monitoring strategy; A determination module, used to determine the data of the sub-window based on the data of the display window of the application to be detected; Determining the data of the watermark sub-window in the data of the sub-window according to the condition of the preset watermark window attribute; The judging module is used to judge the state of the watermark sub-window based on the data of the watermark sub-window, and obtain the detection result of the watermark sub-window.
11. An electronic device, characterized in that: include: one or more processors; a storage device for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 9.
12. A computer readable medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 9 is implemented.
