CN111597113A - Method, device and equipment for verifying small program and storage medium - Google Patents

Method, device and equipment for verifying small program and storage medium Download PDF

Info

Publication number
CN111597113A
CN111597113A CN202010419000.0A CN202010419000A CN111597113A CN 111597113 A CN111597113 A CN 111597113A CN 202010419000 A CN202010419000 A CN 202010419000A CN 111597113 A CN111597113 A CN 111597113A
Authority
CN
China
Prior art keywords
page
applet
content
target
verification
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202010419000.0A
Other languages
Chinese (zh)
Other versions
CN111597113B (en
Inventor
陈都
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN202010419000.0A priority Critical patent/CN111597113B/en
Publication of CN111597113A publication Critical patent/CN111597113A/en
Application granted granted Critical
Publication of CN111597113B publication Critical patent/CN111597113B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3604Software analysis for verifying properties of programs
    • G06F11/3612Software analysis for verifying properties of programs by runtime analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/20Software design
    • G06F8/22Procedural
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Stored Programmes (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The application discloses a verification method, a verification device, verification equipment and a storage medium of an applet, and relates to the technical field of cloud computing. The specific implementation scheme is as follows: the test terminal acquires page display information of the target applet and sends the page display information to the server, the server carries out validity verification on the target applet according to the page snapshot of the target applet and sends an obtained content verification result to the test terminal, so that the test terminal can determine whether the target applet passes the verification. The method can automatically realize the verification of the applet through the interaction of the test terminal and the server, improves the verification efficiency, and the page snapshot of the applet is obtained based on the browsing behavior of the real operating environment, can cover all pages, solves the problem that some contents cannot be obtained due to the possible malicious setting of a developer, and improves the verification accuracy.

Description

Method, device and equipment for verifying small program and storage medium
Technical Field
The embodiment of the application relates to the technical field of cloud computing in the technical field of computers, in particular to a verification method, a verification device, verification equipment and a storage medium for an applet.
Background
The applet is a purely off-line H5 application, and as the ecosystem of applets continues to grow, more and more App applications have turned into applet-style bearers. In general, before or during use of an applet, the validity of the applet needs to be checked to ensure that the content displayed by the applet is legal.
In the prior art, the verification mode of the applet is mainly manual verification, specifically, an auditor opens the applet on a terminal, and a verification result is obtained by checking whether the content displayed by the applet is illegal.
However, the manual verification-based method is labor-consuming and inefficient, and the manual checking method cannot completely cover all the contents of the applet when the number of pages of the applet is large, so that the verification accuracy is low.
Disclosure of Invention
The embodiment of the application provides a method, a device, equipment and a storage medium for verifying an applet, which are used for solving the problem of low verification accuracy in the existing mode of manually verifying the content of the applet.
According to a first aspect, there is provided a method of validating an applet, comprising:
acquiring page display information of a target applet page, wherein the page display information comprises: the page snapshot system comprises a page snapshot, a page identifier and a page storage path, wherein the page storage path has a mapping relation with the page content;
sending a content auditing request to a server, and receiving a content verifying response fed back by the server, wherein the content auditing request comprises: the page display information of the target applet page, the content verification response including: the content verification result of the target applet page;
and determining whether the target applet passes the verification according to the content verification response.
According to a second aspect, there is provided a method of verifying an applet, comprising:
receiving a content checking request sent by a test terminal, wherein the content checking request comprises: page display information of a target applet page, the page display information comprising: the page snapshot system comprises a page snapshot, a page identifier and a page storage path, wherein the page storage path has a mapping relation with the page content;
according to the page snapshot of the target small program page, carrying out validity verification on the page content of the target small program page to obtain a content verification result of the target small program page;
and generating a content verification response according to the content verification result, the page identification and the page storage path of each page, and feeding back the content verification response to the test terminal.
According to a third aspect, there is provided an authentication apparatus of an applet, comprising: the device comprises an acquisition module, a transceiver module and a determination module;
the obtaining module is configured to obtain page display information of a target applet page, where the page display information includes: the page snapshot system comprises a page snapshot, a page identifier and a page storage path, wherein the page storage path has a mapping relation with the page content;
the transceiver module is configured to send a content audit request to a server, and receive a content verification response fed back by the server, where the content audit request includes: the page display information of the target applet page, the content verification response including: the content verification result of the target applet page;
and the determining module is used for determining whether the target applet passes the verification according to the content verification response.
According to a fourth aspect, there is provided an authentication apparatus of an applet, including: the system comprises a transceiver module, a verification module and a generation module;
the receiving and sending module is used for receiving a content checking request sent by the test terminal, and the content checking request comprises: page display information of a target applet page, the page display information comprising: the page snapshot system comprises a page snapshot, a page identifier and a page storage path, wherein the page storage path has a mapping relation with the page content;
the verification module is used for verifying the validity of the page content of the target small program page according to the page snapshot of the target small program page to obtain a content verification result of the target small program page;
the generating module is used for generating a content verification response according to the content verification result, the page identification and the page storage path of each page;
the transceiver module is further configured to feed back the content verification response to the test terminal.
In a fifth aspect, an embodiment of the present application provides a test terminal, including:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of the first aspect.
In a sixth aspect, an embodiment of the present application provides a server, including:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of the second aspect.
In a seventh aspect, the present application provides a non-transitory computer-readable storage medium storing computer instructions for causing a computer to perform the method of the first aspect.
In an eighth aspect, embodiments of the present application provide a non-transitory computer-readable storage medium storing computer instructions for causing a computer to perform the method of the second aspect.
In a ninth aspect, an embodiment of the present application provides a method for verifying an applet, including:
acquiring a page snapshot of the target applet;
and carrying out validity verification on the page snapshot of the target small program, and determining whether the target small program passes the verification.
According to the verification method, the verification device, the verification equipment and the verification medium of the small program, page display information such as page snapshots, page identifications and page storage paths of target small program pages is obtained through the test terminal and is sent to the server, the server conducts validity verification on page contents of the target small program pages according to the page snapshots of the target small program pages, and then the obtained content verification results of the target small program pages are sent to the test terminal, so that the test terminal can determine whether the target small program passes the verification. According to the method, the verification of the applet can be automatically realized through the interaction of the test terminal and the server, manual verification is not needed, the verification efficiency is improved, the page snapshot of the applet is obtained based on the browsing behavior of the real operating environment, all pages of the target applet can be covered, the problem that some contents cannot be obtained due to the fact that a developer may set maliciously can be solved, and the verification accuracy is improved.
It should be understood that the statements in this section do not necessarily identify key or critical features of the embodiments of the present disclosure, nor do they limit the scope of the present disclosure. Other features of the present disclosure will become apparent from the following description.
Drawings
The drawings are included to provide a better understanding of the present solution and are not intended to limit the present application. Wherein:
fig. 1 is a schematic view of an application scenario of an applet verification method provided in the present application;
FIG. 2 is an interaction diagram of a method for verifying an applet, provided in a first embodiment of the present application;
fig. 3 is a flowchart illustrating a method for verifying an applet according to a second embodiment of the present application;
fig. 4 is a flowchart illustrating a method for verifying an applet according to a third embodiment of the present application;
fig. 5 is a schematic flowchart of a verification method for an applet according to a fourth embodiment of the present application;
fig. 6 is a flowchart illustrating an applet verifying method according to a fifth embodiment of the present application;
fig. 7 is a schematic structural diagram of an apparatus for verifying an applet, according to a first embodiment of the present application;
fig. 8 is a schematic structural diagram of an apparatus for verifying an applet, according to a second embodiment of the present application;
fig. 9 is a schematic structural diagram of an apparatus for verifying an applet, according to a third embodiment of the present application;
fig. 10 is a schematic structural diagram of an apparatus for verifying an applet, according to a fourth embodiment of the present application;
fig. 11 is a schematic structural diagram of an apparatus for verifying an applet, according to a fifth embodiment of the present application;
FIG. 12 is a block diagram of a test terminal for implementing the applet verification method provided by the embodiments of the present application;
fig. 13 is a block diagram of a server for implementing the applet authentication method provided in the embodiment of the present application.
Detailed Description
The following description of the exemplary embodiments of the present application, taken in conjunction with the accompanying drawings, includes various details of the embodiments of the application for the understanding of the same, which are to be considered exemplary only. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the present application. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
Before the technical solution of the present application is introduced, terms and application scenarios related in the embodiments of the present application are first introduced:
with the rapid development of internet technology, an application program is opened through an application client installed in electronic equipment and information interaction is performed, so that the requirement of convenience for people to acquire information cannot be met, small programs are produced at the same time, and more apps are converted into small program form bearing. The applet is an application program which is carried on other application platforms and can be executed in the corresponding application platform without installation, so that the information interaction mode of a user through the application program is more convenient.
Specifically, the applet is a pure off-line H5 application, which is developed based on a specific programming language and can be used without downloading and installing, one of the characteristics is that the applet is convenient to use and does not need to be installed in an operating system of a terminal, but with the rapid development of the applet service, illegal contents such as fraud, pornography, gambling and the like may be transmitted and diffused along with the applet, so that in order to avoid the illegal contents from being transmitted and diffused through the applet, the legality check of the applet before the applet is put into use or in the use process is one of the key factors for ensuring the safe and stable development of the applet service.
Currently, the existing small program is usually checked manually, that is, a professional checker is required to open the small program on a special test terminal, and then whether the content displayed by the small program violates a rule or not is checked. However, the manual review method has the following problems: 1. the page coverage is incomplete, that is, a small program usually contains a lot of pages, and when an auditor checks through browsing the pages, all the pages cannot be covered, so that the purpose of comprehensive audit cannot be achieved; 2. the auditing efficiency is low, namely, with the vigorous development of the small programs, the small programs to be audited are increased continuously, the manpower consumption is large through a manual auditing mode, and certain requirements are also provided for the auditing efficiency of auditors; 3. after the small program is released, an auditor cannot audit the small program, and the problem that the small program on the line cannot be audited exists. By integrating the problems, the existing manual auditing mode has the problems of low auditing efficiency and low verification accuracy.
In order to solve the above problem, an embodiment of the present application provides a method for verifying content of a program, where a test terminal obtains page display information, such as a page snapshot, a page identifier, and a page storage path, of a target applet page, and sends the page display information to a server, and the server performs validity verification on page content of the target applet page according to the page snapshot of the target applet page, and then sends an obtained content verification result of the target applet page to the test terminal, so that the test terminal determines whether the target applet passes the verification. The method can automatically realize the verification of the applet through the interaction of the test terminal and the server, does not need manual verification, improves the verification efficiency, can cover all pages of the target applet because the page snapshot of the applet is obtained based on the browsing behavior of the real operating environment, can solve the problem that a developer can set maliciously to avoid obtaining some contents, and improves the verification accuracy.
The technical idea of the application is as follows: the method comprises the steps of triggering page display of the applet by depending on a real user or an offline real machine script simulation mode, enabling the captured page to be a page which is really seen by the user on equipment, and solving the problem that the page of some applet developed by some developers cannot be captured by a spider or forged into a normal page when the spider captures the page of some applet so that some pages cannot be captured and identified due to the fact that the spider is limited by a robots protocol. On the other hand, the method can also solve the problem that content identification cannot be performed due to the fact that a developer does not configure a robots protocol or intentionally prevents a spider from capturing the content in the Web page acquisition process, and can solve the problem that identification dead corners of the page intentionally made by a malicious developer cannot be identified, so that the accuracy and the efficiency of small program online auditing are improved.
Optionally, in an embodiment of the present application, the verification of the applet may include: and verifying the offline applet to be published and the published online applet. Optionally, the offline applet verification may trigger the applet page display event by running a script mode of the applet, so as to obtain the applet page display information, and the online applet verification may directly obtain the applet page display information based on the user page browsing behavior. The embodiment of the application does not limit the acquisition mode of the online applet and the offline applet, and the acquisition mode can be determined according to an actual scene, which is not described herein again.
Exemplarily, fig. 1 is an application scenario diagram of the applet verification method provided in the present application. As shown in fig. 1, the application scenario may include: at least one applet development platform 11, at least one test terminal 12, a network 13 and a server 14. Wherein, a developer can develop a plurality of applets on each applet development platform 11, each applet development platform 11 can correspond to at least one test terminal 12, and the test terminals 12 and the server 14 can communicate through the network 13.
For example, in the application scenario shown in fig. 1, the test terminal 12 may obtain an audit request for a target applet, which is sent by the applet development platform 11, and obtain page display information such as a page snapshot, a page identifier, and a page storage path of a page of the target applet, where the page storage path has a mapping relationship with a page content, and then, the test terminal 12 may send a content verification request to the server 14 through the network 13, so that the server 14 may perform validity verification on the page content of the target applet page according to the page snapshot of the target applet page to obtain a content verification result of the target applet page, and feed the content verification result back to the test terminal 12 through a content verification response, so that the test terminal 12 determines whether the target applet passes verification according to the content verification result.
In an embodiment of the present application, when it is determined that the target applet passes the verification based on the content verification result fed back by the server 14, in a possible design, the content verification result may also be displayed through the test terminal 12, so that an auditor 15 corresponding to the test terminal 12 performs secondary audit on the content verification result, and the verification accuracy of the target applet is further improved.
In another embodiment of the present application, if it is verified through practice that the verification accuracy determined according to the content verification result fed back by the server 14 already meets the preset requirement, the test terminal 12 may directly push an audit response that the target applet is verified to pass to the corresponding applet development platform 11, and issue the permission to run the applet.
In yet another embodiment of the present application, when the test terminal 12 determines that the target applet does not pass the verification, the test terminal 12 needs to determine that the operation authority of the target applet is in a closed state. Optionally, for the offline applet to be issued, the operation permission of the offline applet is limited, so that the offline applet is in a closed state. And for the issued online small program, closing the operation authority of the online small program, and controlling the online small program to be forcibly offline so as to prevent illegal contents of the online small program from being spread or diffused.
As can be seen from the above analysis, in the embodiment of the present application, the representation form of the target applet may be any one of the following: offline applets to be published, and online applets already published. The offline applet to be released may include a modified applet, and the modified applet may be obtained after the unmodified applet is modified or obtained after some legal applets are updated. It can be understood that the source applet corresponding to the modified applet may be an offline applet to be published, or an online applet that has been published, and is not limited herein.
It should be noted that fig. 1 is only a schematic diagram of an application scenario provided in an embodiment of the present application, and fig. 1 is illustrated by an applet development platform, a test terminal, and an auditor. The embodiment of the present application does not limit the number of devices and the types of devices included in the application scenario shown in fig. 1, and both of them may be set according to actual requirements, which is not described herein again.
In the embodiment of the present application, the applet development platform 11 may be an applet development platform operated independently by an operator of an APP carrying an applet, or may be a third-party applet development platform having a cooperative relationship with the operator of the APP carrying the applet. Alternatively, the applet development platform 11, also referred to as an applet developer tool, is a tool for producing an applet, i.e., a tool for generating an applet package. The present application is not limited to the specific embodiment of the applet development platform 11.
In practical applications, the server 14 may be a cloud server, and provides computing or application services for other clients (such as PCs, smartphones, applet development platforms, and the like) in a network. The embodiment of the present application does not limit the specific implementation and functions of the server, which can be determined according to actual requirements, and is not described herein again.
The technical solution of the present application will be described in detail below with reference to specific examples. It should be noted that the following specific embodiments may be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments.
Fig. 2 is an interaction diagram of an applet authentication method according to a first embodiment of the present application. For example, the embodiment of the present application is explained in terms of information interaction between a test terminal and a server. As shown in fig. 2, the method may include the steps of:
s201, the test terminal obtains page display information of a target small program page.
Wherein, this page show information includes: the system comprises a page snapshot, a page identifier and a page storage path, wherein the page storage path has a mapping relation with page content.
In the embodiment of the application, the test terminal is a test device butted with the applet development platform, when an applet needs to be checked, the test terminal can firstly determine a target applet to be checked, and further based on the target applet, the page content, the page identifier, the page storage path and the like of the target applet page can be obtained in the displaying process of the applet page, and further information such as the page snapshot of each page can be obtained according to the page content.
The page content is the content displayed on the page when the target applet is accessed, actually is the HTML language corresponding to the page content, is an identifying language and comprises a series of tags, and the tags can unify the document format on the network so as to connect the scattered Internet resources into a logic whole. The page identification is used for identifying a unique page, the page storage path is used for representing the storage position of each page, the page storage path can be linked to the page based on the page storage path, and the page snapshot is a page cache for identifying the original content of the page, and the content on the page cache cannot be tampered.
It can be understood that the page display information of the target applet page refers to information presented when the applet is displayed in an actual operating environment, is determined based on an actual browsing behavior of the applet page, is consistent with an operating scene after the applet is published, and can cover content that the applet will display after being published formally, so that illegal content presented on a dynamic page in the target applet can be effectively identified during subsequent verification.
In an embodiment of the present application, the page may refer to all pages of the target applet, so that the terminal device may send page display information of all pages of the target applet to the server for verification, thereby improving accuracy of content verification of the applet.
In this embodiment, for a specific implementation principle of obtaining the page display information of the target applet page, reference may be made to the following description in the embodiment shown in fig. 3 or fig. 4, which is not described herein again.
S202, the test terminal sends a content checking request to the server, wherein the content checking request comprises: page presentation information of the target applet page.
In the embodiment of the application, after the test terminal acquires the page display information of the target applet page, in order to implement automatic content verification, the page display information of the target applet page may be packaged into a content verification request and sent to the server, so that the server executes a content verification process.
S203, the server carries out validity verification on the page content of the target small program page according to the page snapshot of the target small program page, and a content verification result of the target small program page is obtained.
In this embodiment, the server may detect whether the page content of the target applet page is legal based on a preset rule, specifically, since the page snapshot of each page and the page content are in one-to-one correspondence, the content verification result of each page of the target applet may be determined by performing content verification on the page snapshot of each page.
Optionally, the content verification result of the target applet page may also be referred to as a page content verification result of the target applet, which may represent the same meaning, and the present application does not limit specific expressions.
It is understood that in the embodiment of the present application, the server verifies whether the target applet is legal, mainly determines whether the target applet carries illegal contents such as yellow, reaction, fraud, gambling, etc., and whether a Banner advertisement (Banner Ad.) with a larger space on the page of the target applet covers the display of normal contents, etc. The form of the illegal contents can be determined according to actual situations, and is not described in detail herein.
Therefore, in this embodiment, if the page content of the target applet carries any of the above illegal contents, or there is a problem that a large-sized banner advertisement on the page of the target applet is covered, it can be determined that there is illegal content on the page.
S204, the server generates a content verification response according to the content verification result, the page identification and the page storage path of each page.
In the embodiment of the application, in order to accurately represent the content verification result of each page, after the server obtains the content verification result of each page, a content verification response can be generated according to the content verification result, the page identifier and the page storage path of each page, so that the purpose of associating the content verification result of each page with the page is achieved, that is, other page display information can be determined according to the page identifier, the content verification result of the page or the page storage path.
And S205, the server feeds back the content verification response to the test terminal.
S206, the test terminal determines whether the target applet passes the verification according to the content verification response.
In the embodiment of the application, after obtaining the content verification response, the server may feed back the content verification response to the test terminal, that is, the test terminal may obtain the content verification result of the target applet page according to the received content verification response, and then determine whether the target applet passes the verification based on the content verification result of the target applet page.
Optionally, the content verification result may include a determination result of whether the page content of the target applet page is legal or not, which is determined based on the page snapshot. Therefore, in this embodiment, if the page contents of the target applet page are all legal, the target applet may be considered to be legal, and at this time, it is determined that the target applet passes the verification; correspondingly, if the target applet has illegal page content, the target applet is determined to be not verified.
In a possible design, the server may generate a content verification response based on the setting, where the applet passes the verification, the content verification result and the page identifier of each page may be carried in the generated content verification response, and where the applet does not pass the verification, the content verification result, the page identifier of each page, and the storage path and/or the page content of the page that does not pass the verification may be carried in the generated content verification response. Therefore, after the test terminal receives the content verification response, if the content verification response only includes the content verification result and the page identifier of each page, the applet can be considered to be verified to be passed, and if the content verification response includes the content verification result and the page identifier, and also includes the failed verification page storage path and/or the page content, the applet can be considered to be failed in verification.
According to the verification method of the small program, the test terminal obtains page display information such as the page snapshot, the page identification and the page storage path of the target small program page and sends the page display information to the server, and after the server verifies the validity of the page content of the target small program page according to the page snapshot of the target small program page, the server sends the obtained content verification result of the target small program page to the test terminal so that the test terminal can determine whether the target small program passes the verification. The method can automatically realize the verification of the applet through the interaction of the test terminal and the server, does not need manual verification, improves the verification efficiency, can cover all pages because the page snapshot of the applet is obtained based on the browsing behavior of a real operating environment, can solve the problem that a developer can set maliciously to avoid obtaining some contents, and improves the verification accuracy.
Further, in an embodiment of the present application, before the foregoing S201, the method may further include the following steps:
the method comprises the following steps that a test terminal receives an audit request aiming at the applet, wherein the audit request comprises: an identification of the target applet and/or a data package of the target applet.
Specifically, the test terminal is a test device which is in butt joint with the applet development platform, and when the applet needs to be checked, a developer of the applet can send a checking request to the test terminal through the applet development platform.
Optionally, in an embodiment of the application, in order to enable the test terminal to verify the data of the target applet in a targeted manner, the audit request at least needs to include an identifier of at least one target applet and a data packet of the target applet in the following information. In a specific application, a data packet of a target applet is a string of code for implementing the target applet, which is uncompiled code.
In practical applications, the terminal device may obtain an executable file (exe file) by running a data packet of the target applet, that is, by compiling a code for implementing the target applet, so that the target applet may be displayed on the terminal.
As an example, in practical application, when a developer develops a new applet through an applet development platform based on its own service requirements, a data packet of the applet may be sent to a docked test terminal through the applet development platform, so that the test terminal verifies the applet according to the received data packet.
In this example, a developer may package, upload, and submit the developed applet data package to a test terminal for auditing. The packaging of the developed applet data package specifically refers to a process of packaging an execution code of the developed applet into an executable program.
As another example, after the applet is released, in order to ensure that the applet being run is legal, the on-line applet needs to be inspected in real time, and at this time, the test terminal may receive an audit request sent by an audit staff to instruct the test terminal to audit the released applet running on the line, so as to ensure that the applet running on the line does not carry illegal contents as much as possible.
In this example, since the online applet runs on the server, the audit request may include an identifier of the target applet, so that the test terminal may locate the target applet based on the identifier of the target applet and further perform a content audit process.
It is understood that in the embodiment of the present application, the number of target applets may be one or more. The number of target applets is not limited in the present application, and may be determined according to actual situations, which is not described herein again.
Further, in this embodiment, the step S203 may be implemented by:
and the server inputs the page snapshot of each page of the target applet into the verification model and outputs the content verification result of each page. Wherein the verification model is based on a pre-trained model for verifying whether the applet content is legitimate.
In the embodiment of the application, a verification model can be run on the server, when the server obtains the page snapshot of each page of the target applet from the test terminal, the page snapshot can be input into the verification model, and the verification model borne by the server is used for carrying out validity verification on the page content of the page of the target applet, so that a content verification result is obtained. The validity of the target applet is verified through the verification model, so that the verification efficiency can be improved.
Optionally, the verification model may be obtained by machine learning, for example, by training a training sample of the model by using a deep convolutional neural network structure. The model training sample may be a page snapshot of a marked applet carrying illegal content. Optionally, the trainer may be a component integrated on the server, or may be another device independent of the server. The embodiment of the application does not limit the specific relationship between the trainer and the server, and the specific relationship can be determined according to actual requirements.
For example, in the embodiment of the present application, the target applet may be an applet to be published, or an applet that runs on a published line. The way of acquiring page presentation information of an applet page is different for different types of applets, which is described below with the embodiments shown in fig. 3 and 4, respectively.
On the basis of the foregoing embodiments, fig. 3 is a flowchart illustrating a verification method for an applet according to a second embodiment of the present application. The implementation scheme provided by the embodiment of the application is an explanation of the above S201 by the test terminal in a scenario where the target applet is the applet to be issued. As shown in fig. 3, in this embodiment, the above S201 can be implemented by the following steps:
s301, acquiring a script of the target applet.
In practical applications, when a developer develops applets, each applet has a corresponding Script (Script), which is an extension of a batch file and a plain text saving program. Thus, in the present embodiment, the script of the target applet is a combination of a series of determined control target applets performing the presentation operation actions.
In the embodiment of the application, if an applet is triggered to perform page display, after a target applet is determined, a script of the target applet may be obtained first.
S302, triggering a page display event of the target small program by running the script, wherein the page display event is used for representing that the page of the target small program is displayed.
In the embodiment of the application, the actual clicking operation of the user can be simulated by running the script corresponding to the target applet, and each page of the target applet is triggered to be sequentially displayed on the display interface of the test terminal. In the present embodiment, an event in which a page of a target applet is exposed is referred to as a page exposure event of the applet.
And S303, acquiring page display information of the target small program according to the page display event.
For example, for an applet to be issued, the test terminal may trigger each page of the target applet to be sequentially displayed by running a script of the target applet, so that page display information of the target applet may be obtained in a display process of each page.
For specific content of the page display information, reference may be made to the description in the embodiment shown in fig. 2, and details are not described here.
According to the verification method of the small program, the script of the target small program is obtained, the script is operated, the page display event of the target small program can be triggered, the page display event is used for representing the page of the target small program to be displayed, and then the page display information of the target small program is obtained according to the page display event. In the embodiment of the application, the quantity of the small programs to be issued is small, the small programs can be operated and realized by running the script, and the steps of acquiring the script and allowing the script to be automatically executed are set, so that the productivity limitation of an offline manual auditing link can be relieved, the problem of incomplete page coverage caused by manual auditing is avoided, the realization condition is provided for the subsequent legal verification of the small programs, and the foundation is laid for obtaining the verification result with higher accuracy.
On the basis of the foregoing embodiments, fig. 4 is a flowchart illustrating a verification method for an applet according to a third embodiment of the present application. The implementation scheme provided by the embodiment of the present application is an explanation of the above S201 by the test terminal in a scenario where the target applet is an online applet. As shown in fig. 4, in this embodiment, the above S201 may be implemented by the following steps:
s401, obtaining user operation behaviors of the target small program, wherein the user operation behaviors comprise browsing behaviors of the target small program.
In practical application, if the target applet is a published applet running on the online, after the target applet is determined, capturing the operation performed by a user on the target applet, and determining the user operation behavior of the target applet. Since the user can click on the target applet and browse the pages included in the target applet, the user operation behavior includes a browsing behavior of the target applet.
S402, determining a page display event of the target small program according to the user operation behavior, wherein the page display event is used for representing that the page of the target small program is displayed.
In this embodiment, after the test terminal acquires the user operation behavior for the target applet, it may determine whether the page of the target applet is displayed according to the user operation behavior. If the page is displayed, the page display event is determined, because only the displayed page is likely to be browsed by the user, and information such as a page identifier, page content, page storage path and the like of the displayed page of the target applet can be acquired.
And S403, acquiring page display information of the target applet according to the page display event.
For example, for an applet running on a line, the test terminal may obtain page display information of the target applet in the display process of each page based on a page display event of the target applet.
According to the verification method of the small program, for the target small program running on line, firstly, the user operation behavior of the target small program is obtained, the user operation behavior comprises the browsing behavior of the target small program, secondly, the page display event of the page of the target small program is determined according to the user operation behavior, and finally, the page display information of the target small program is obtained according to the page display event. The scheme is based on the actual browsing behavior of the user, so that the capturing of the page display information of the small program running on the line is realized, and a foundation is laid for the subsequent analysis of whether the target small program is legal or not.
Further, in the embodiment of the present application, S303 in the embodiment shown in fig. 3 and S403 in the embodiment shown in fig. 4 may be implemented by the following steps:
a1, acquiring a page storage path and page content of each page during display according to the page display event;
a2, determining the mapping relation between the page storage path and the page content of each page;
and A3, performing snapshot processing on the page content corresponding to each page to obtain a page snapshot corresponding to each page of the target applet.
In the embodiment of the application, the test terminal acquires the page storage path of each page and the content (page content) on the page in the page display process of the target applet based on the page display event, and records the mapping relationship between the page content of each page and the page storage path, so that the corresponding page content can be determined according to the page storage path in the following process.
Illustratively, a page snapshot may be generated by performing snapshot processing on the page content of each page, where the page snapshot is actually a backup of a web page, is a cache form of the page content, and has an association relationship with a page storage path, and the page content of a page corresponding to the page snapshot may be obtained according to the page storage path corresponding to the page snapshot.
In this embodiment, according to a page display event of an applet, a page storage path and page content corresponding to a target applet during display are first determined, and then a snapshot of the page content is performed to obtain a page snapshot of each page, which can reflect a real operating environment of the applet, thereby avoiding a problem that a verification result of the applet is inaccurate due to disguised processing of some content of the applet.
Further, in the embodiment of the present application, after obtaining the verification result for the target applet, the server feeds back the content verification passing response to the test terminal, so that the test terminal can obtain the content verification result obtained by the server, and further determine whether the target applet passes the verification based on the content verification result.
Optionally, in the embodiment of the application, when the test terminal determines that the target applet passes verification, an auditor corresponding to the target applet may perform secondary audit. Specifically, the above S206 may be implemented by the following embodiment shown in fig. 5.
Fig. 5 is a flowchart illustrating a verification method for an applet according to a fourth embodiment of the present application. The embodiment of the application is a further explanation of the verification of the applet by the test equipment. As shown in fig. 5, in this embodiment, the step S206 may be implemented by:
s501, displaying a content verification result of the target small program page.
Optionally, in an embodiment of the application, the test terminal has a human-computer interaction interface, and a content verification result obtained by the server (through a verification model running thereon) may be inaccurate, so that when the test terminal receives the content verification result for the target applet page from the server and/or determines that the target applet passes verification, the content verification result for the target applet page may be displayed through the human-computer interaction interface, so that an auditor may finally determine whether the target applet passes verification.
And S502, receiving an audit result sent by an auditor according to the content verification result of each page.
In the embodiment of the application, after the content verification result displayed on the human-computer interaction interface is checked by the auditor, an audit result for the target applet can be sent through the human-computer interaction interface, for example, the audit is passed or the audit is not passed. Therefore, the test terminal can obtain the audit result sent out after the audit personnel carry out secondary audit.
And S503, determining whether the target applet passes the verification according to the verification result.
In the embodiment of the application, after the test terminal obtains the audit result sent by the auditor, whether the target applet passes the verification or not can be finally determined according to the audit result. And the final verification result of the target small program is subjected to secondary verification by a verifier, so that the verification accuracy can be further improved.
Optionally, the result of the audit may be that the target applet has passed the verification, or that the target applet has failed the verification. When the target applet passes the verification, the applet to be issued can be issued online, and no intervention is performed on the applet running online. When the target applet is not verified, the applet to be released needs to be fed back to the applet development platform so as to modify the applet to be released, and the applet running on the line needs to be intervened, for example, the applet is forcibly offline and fed back to the applet development platform so as to modify the applet.
Specifically, as shown in fig. 5, after S206 or S503, the method may further include the following steps:
s504, when the target applet is not verified, determining that the operation authority of the target applet is in a closed state, and pushing the content verification response to the applet development platform.
Optionally, the applet development platform is a device on which the target applet is developed and modified.
In the embodiment of the application, when the target applet is not verified, on one hand, the running authority of the target applet can be determined to be in a closed state, so that the problems of violation, online and the like can be avoided; on the other hand, the verification result can be pushed to the applet development platform, so that the applet development platform can timely correct the page of the applet which cannot be verified.
Specifically, the test terminal may take corresponding measures for the applet to be released and the applet running on the line, respectively. For example, for the applet to be released, the test terminal can intercept the release flow of the applet and directly terminate the release flow, so that the problem of illegal content transmission and diffusion caused by the fact that some illegal applets are released to be on-line can be solved, and the use experience of a user is improved. For the small programs running on the online, the test terminal can directly close the running authority of the small programs to force the small programs to be offline, so that the continuous propagation of illegal contents is avoided.
According to the verification method of the small program, after the test terminal obtains the content verification response, the verification result sent by the verifier according to the content verification result of each page is received by displaying the content verification result of the target small program page, and whether the target small program passes the verification or not is determined according to the verification result. The auditing accuracy of the small program is improved by the secondary auditing of the auditors. When the target applet is not verified, the operation authority of the target applet can be determined to be in a closed state, and the verification result is pushed to the applet development platform, so that corresponding developers can timely modify the page of the target applet on the applet development platform, the legality of the issued applet is guaranteed, and the use experience of users is improved.
On the basis of the above embodiments, the following explains the overall process of verifying the content of the applet from before and after the distribution by a specific embodiment. Fig. 6 is a flowchart illustrating a verification method for an applet according to a fifth embodiment of the present application. As shown in fig. 6, the scheme may be divided into two parts, namely, an offline machine automatic audit part and an online inspection part, wherein the offline machine automatic audit part may include the following steps one to three, and the online inspection part may include the following steps four to six, specifically:
the method comprises the following steps that firstly, a test terminal obtains page display information of all pages of an applet to be issued and sends the page display information to a server;
specifically, the test terminal obtains page display information of all pages of the applet to be released by running the script of the applet.
Secondly, the server carries out validity verification on the page contents of all the pages according to the page snapshots of all the pages of the target applet to obtain a content verification result, and feeds back the content verification result to the test terminal through a content verification response;
and step three, the test terminal verifies the content verification result included in the content verification response and determines whether the small program to be issued passes verification.
Step four, the test terminal obtains the on-line small program page snapshot based on the user browsing behavior and sends the on-line small program page snapshot to the server;
fifthly, the server carries out validity verification on the online small program page snapshot to obtain a content verification result and feeds the content verification result back to the test terminal;
step six, the test terminal intervenes the small program which fails to pass the verification according to the page storage path and the page identification;
and step seven, after page rectification is carried out on the small programs which do not pass the verification by the developers, submitting the small programs, and then turning to the step one to continue execution.
To sum up, the verification method of the applet, provided by the embodiment of the application, is based on content verification of page display information acquired by the applet in a real operating environment, and can solve the problem that the page content of the applet cannot be acquired due to the fact that a developer does not configure a robots protocol or intentionally prevents crawlers from grabbing, and can be divided into an offline machine automatic verification part and an online inspection part, and the online offline verification stage and the online inspection stage of the scheme can operate together, so that the problem that a malicious developer cannot recognize timely due to setting of a page recognition dead angle is solved, accuracy and efficiency of online offline verification of the applet are improved, and for the applet after online, if a user accesses the page, the applet can be found and intervened offline timely, and the user experience is guaranteed practically.
The foregoing describes a specific implementation of the applet verifying method mentioned in the embodiments of the present application, and the following describes embodiments of an apparatus of the present application, which may be used to implement the embodiments of the method of the present application. For details which are not disclosed in the embodiments of the apparatus of the present application, reference is made to the embodiments of the method of the present application.
Fig. 7 is a schematic structural diagram of an apparatus for verifying an applet according to a first embodiment of the present application. The device can be integrated in the test terminal and can also be realized through the test terminal. As shown in fig. 7, in the present embodiment, the applet verifying device 70 may include: an acquisition module 701, a transceiver module 702 and a determination module 703.
The obtaining module 701 is configured to obtain page display information of the target applet page, where the page display information includes: the page snapshot system comprises a page snapshot, a page identifier and a page storage path, wherein the page storage path has a mapping relation with the page content;
the transceiver module 702 is configured to send a content audit request to a server, and receive a content verification response fed back by the server, where the content audit request includes: the page display information of the target applet page, the content verification response including: the content verification result of the target applet page;
the determining module 703 is configured to determine whether the target applet passes the verification according to the content verification response.
On the basis of the embodiment shown in fig. 7, fig. 8 is a schematic structural diagram of an apparatus for verifying an applet according to a second embodiment of the present application. As shown in fig. 8, the obtaining module 701 may include: an acquisition unit 801 and a trigger unit 802.
The acquiring unit 801 is used for acquiring a script of the target applet;
a triggering unit 802, configured to trigger a page display event of the target applet by running the script, where the page display event is used to represent that a page of the target applet is displayed;
the obtaining unit 801 is further configured to obtain page display information of the target applet according to the page display event.
In an embodiment of the present application, the target applet is an applet to be issued.
On the basis of the embodiment shown in fig. 7, fig. 9 is a schematic structural diagram of an apparatus for verifying an applet according to a third embodiment of the present application. As shown in fig. 9, the obtaining module 701 may include: an acquisition unit 901 and a determination unit 902.
The acquiring unit 901 is configured to acquire a user operation behavior of a target applet, where the user operation behavior includes a browsing behavior of the target applet;
a determining unit 902, configured to determine, according to the user operation behavior, a page display event of the target applet, where the page display event is used to represent that a page of the target applet is displayed;
the obtaining unit 901 is further configured to obtain page display information of the target applet according to the page display event.
In an embodiment of the application, the target applet is an online running applet.
In the embodiment shown in fig. 8 and/or fig. 9, the obtaining unit is configured to obtain, according to the page display event, page display information of the target applet, specifically:
and the obtaining unit is specifically configured to obtain a page storage path and page content of each page during display according to the page display event, determine a mapping relationship between the page storage path and the page content of each page, and perform snapshot processing on the page content corresponding to each page to obtain a page snapshot corresponding to each page of the target applet.
On the basis of any of the above embodiments, fig. 10 is a schematic structural diagram of an apparatus for verifying an applet according to a fourth embodiment of the present application. As shown in fig. 10, the determining module 703 includes: a presentation unit 1001, a receiving unit 1002 and a determining unit 1003.
The display unit 1001 is configured to display a content verification result of the target applet page;
the receiving unit 1002 is configured to receive an audit result sent by an auditor according to a content verification result of each page;
the determining unit 1003 is configured to determine whether the target applet passes the verification according to the audit result.
Further, on the basis of any one of the above embodiments, the determining module 703 is further configured to determine that the operation authority of the target applet is in a closed state;
the transceiver module 702 is further configured to push the content verification response to an applet development platform, where the applet development platform is a device in which the target applet is developed and modified.
The apparatus provided in the foregoing embodiments of the present application may be used to implement the scheme of testing the terminal in any of the foregoing method embodiments, and the implementation principle and the technical effect are similar, which are not described herein again.
Fig. 11 is a schematic structural diagram of an apparatus for verifying an applet according to a fifth embodiment of the present application. The device can be integrated in the server or realized by the server. As shown in fig. 11, in this embodiment, the applet verifying device 110 may include: a transceiver module 1101, a verification module 1102, and a generation module 1103.
The transceiver module 1101 is configured to receive a content audit request sent by a test terminal, where the content audit request includes: page display information of a target applet page, the page display information comprising: the page snapshot system comprises a page snapshot, a page identifier and a page storage path, wherein the page storage path has a mapping relation with the page content;
the verification module 1102 is configured to perform validity verification on the page content of the target applet page according to the page snapshot of the target applet page, so as to obtain a content verification result of the target applet page;
a generating module 1103, configured to generate a content verification response according to the content verification result, the page identifier, and the page storage path of each page;
the transceiver module 1101 is further configured to feed back the content verification response to the test terminal.
Optionally, in an embodiment of the present application, the verification module 1102 is configured to input the page snapshot of each page of the target applet into a verification model, and output a content verification result of each page, where the verification model is based on a pre-trained model for verifying whether the content of the applet is legal.
The apparatuses provided in the foregoing embodiments of the present application may be used to implement the scheme of the server in any of the foregoing method embodiments, and the implementation principle and the technical effect are similar, which are not described herein again.
It should be noted that the division of the modules of the above apparatus is only a logical division, and the actual implementation may be wholly or partially integrated into one physical entity, or may be physically separated. And these modules can be realized in the form of software called by processing element; or may be implemented entirely in hardware; and part of the modules can be realized in the form of calling software by the processing element, and part of the modules can be realized in the form of hardware. For example, the processing module may be a processing element separately set up, or may be implemented by being integrated in a chip of the apparatus, or may be stored in a memory of the apparatus in the form of program code, and a function of the processing module may be called and executed by a processing element of the apparatus. Other modules are implemented similarly. In addition, all or part of the modules can be integrated together or can be independently realized. The processing element described herein may be an integrated circuit having signal processing capabilities. In implementation, each step of the above method or each module above may be implemented by an integrated logic circuit of hardware in a processor element or an instruction in the form of software.
Further, according to an embodiment of the present application, an electronic device and a computer-readable storage medium are also provided.
Fig. 12 is a block diagram of a test terminal for implementing the applet verifying method provided in the embodiment of the present application. The test terminal is intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, and other suitable computers. The test terminal may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be examples only, and are not meant to limit implementations of the present application that are described and/or claimed herein.
Illustratively, as shown in fig. 12, the test terminal may include: at least one processor 1201, memory 1202 communicatively coupled to the at least one processor; the memory 1202 stores instructions executable by the at least one processor 1201, and the instructions are executed by the at least one processor 1201, so that the at least one processor 1201 can execute the above-described scheme of the test terminal in the embodiments shown in fig. 2 to 6.
Optionally, in an embodiment of the present application, the test terminal may further include: an input device 1203 and an output device 1204. The processor 1201, the memory 1202, the input device 1203, and the output device 1204 may be connected by a bus or other means, and the bus connection is exemplified in fig. 12.
Further, in this embodiment of the present application, the test terminal further includes a display 1205, where the display 1205 is configured to display the content verification result received from the server, and receive the audit result sent by the auditor.
Fig. 13 is a block diagram of a server for implementing the applet authentication method provided in the embodiment of the present application. In embodiments of the present application, server is intended to represent various forms of workstations, blade servers, mainframe computers, and other suitable computers and the like.
Illustratively, as shown in fig. 13, the server may include: at least one processor 1301, memory 1302 communicatively coupled to the at least one processor; the memory 1302 stores instructions executable by the at least one processor 1301, and the instructions are executed by the at least one processor 1301, so that the at least one processor 1301 can execute the scheme of the server in the embodiments shown in fig. 2 to 6.
Optionally, in an embodiment of the present application, the server may further include: an input device 1303 and an output device 1304. The processor 1301, the memory 1302, the input device 1303 and the output device 1304 may be connected by a bus or other means, and fig. 13 illustrates the bus connection.
It will be appreciated that the components illustrated in fig. 12 and 13, their connections and relationships, and their functions, described above, are meant to be examples only, and are not intended to limit implementations of the present application as described and/or claimed herein.
In the schematic diagrams shown in fig. 12 and 13, the test terminal and the server may each include interfaces for connecting various components, including a high-speed interface and a low-speed interface. The various components are interconnected using different buses and may be mounted on a common motherboard or in other manners as desired. The processor may process instructions for execution within the test terminal and server, including instructions stored in or on the memory to display graphical information of the GUI on an external input/output device (such as a display device coupled to the interface). In other embodiments, multiple processors and/or multiple buses may be used, along with multiple memories and multiple memories, as desired. Also, multiple electronic devices may be connected, with each device providing portions of the necessary operations (e.g., as a server array, a group of blade servers, or a multi-processor system).
In the schematic diagrams shown in fig. 12 and 13, the memory is a non-transitory computer readable storage medium provided by the present application. Wherein the memory stores instructions executable by at least one processor to cause the at least one processor to perform the applet authentication method provided herein. The non-transitory computer-readable storage medium of the present application stores computer instructions for causing a computer to execute the method of authentication of an applet provided in the present application.
The memory, as a non-transitory computer readable storage medium, may be used to store non-transitory software programs, non-transitory computer executable programs, and modules, such as program instructions/modules corresponding to the method for verifying a applet in embodiments of the present application. The processor executes various functional applications of the server and data processing by running the non-transitory software programs, instructions, and modules stored in the memory, that is, implements the applet verifying method in the above-described method embodiments.
The memory may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function; the storage data area may store data created from the use of the electronic device according to the verification of the applet, and the like. Further, the memory may include high speed random access memory, and may also include non-transitory memory, such as at least one magnetic disk storage device, flash memory device, or other non-transitory solid state storage device. In some embodiments, the memory optionally includes memory located remotely from the processor, and these remote memories may be connected over a network to a test terminal and/or server for verification of the applet. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The input device may receive input numeric or character information and generate key signal inputs related to user settings and function controls of the electronic device for verification of the applet, such as a touch screen, keypad, mouse, track pad, touch pad, pointer stick, one or more mouse buttons, track ball, joystick, or other input device. The output devices may include a display device, auxiliary lighting devices (e.g., LEDs), and haptic feedback devices (e.g., vibrating motors), among others. The display device may include, but is not limited to, a Liquid Crystal Display (LCD), a Light Emitting Diode (LED) display, and a plasma display. In some implementations, the display device can be a touch screen.
Various implementations of the systems and techniques described here can be realized in digital electronic circuitry, integrated circuitry, application specific ASICs (application specific integrated circuits), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs that are executable and/or interpretable on a programmable system including at least one programmable processor, which may be special or general purpose, receiving data and instructions from, and transmitting data and instructions to, a storage system, at least one input device, and at least one output device.
These computer programs (also known as programs, software applications, or code) include machine instructions for a programmable processor, and may be implemented using high-level procedural and/or object-oriented programming languages, and/or assembly/machine languages. As used herein, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, apparatus, and/or device (e.g., magnetic discs, optical disks, memory, Programmable Logic Devices (PLDs)) used to provide machine instructions and/or data to a programmable processor, including a machine-readable medium that receives machine instructions as a machine-readable signal. The term "machine-readable signal" refers to any signal used to provide machine instructions and/or data to a programmable processor.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic, speech, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), Wide Area Networks (WANs), and the Internet.
The computer system may include a client (terminal) and a server. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other.
Further, an embodiment of the present application further provides a method for verifying an applet, including:
acquiring a page snapshot of a target applet;
and carrying out validity verification on the page snapshot of the target small program, and determining whether the target small program passes the verification.
Optionally, an execution main body of the method may be an electronic device, and the electronic device integrates functions of the test terminal and the server, so that the technical solution may be executed. According to the technical scheme of the embodiment of the application, the page snapshot of the target small program is obtained, and then the validity of the page snapshot of the target small program is verified, so that whether the target small program passes the verification or not can be determined. The method does not need manual verification, improves verification efficiency, and the page snapshot is obtained based on the real running environment of the applet, can cover all pages, and improves verification accuracy.
It should be understood that various forms of the flows shown above may be used, with steps reordered, added, or deleted. For example, the steps described in the present application may be executed in parallel, sequentially, or in different orders, as long as the desired results of the technical solutions disclosed in the present application can be achieved, and the present invention is not limited herein.
The above-described embodiments should not be construed as limiting the scope of the present application. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made in accordance with design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims (25)

1. A method of validating an applet, comprising:
acquiring page display information of a target applet page, wherein the page display information comprises: the page snapshot system comprises a page snapshot, a page identifier and a page storage path, wherein the page storage path has a mapping relation with the page content;
sending a content auditing request to a server, and receiving a content verifying response fed back by the server, wherein the content auditing request comprises: the page display information of the target applet page, the content verification response including: the content verification result of the target applet page;
and determining whether the target applet passes the verification according to the content verification response.
2. The method of claim 1, wherein the obtaining page display information of the target applet page comprises:
acquiring a script of a target applet;
triggering a page display event of the target applet by running the script, wherein the page display event is used for representing that the page of the target applet is displayed;
and acquiring the page display information of the target small program according to the page display event.
3. The method of claim 2, wherein the target applet is an applet to be published.
4. The method of claim 1, wherein the obtaining page display information of the target applet page comprises:
acquiring user operation behaviors of a target small program, wherein the user operation behaviors comprise browsing behaviors of the target small program;
determining a page display event of the target applet according to the user operation behavior, wherein the page display event is used for representing that a page of the target applet is displayed;
and acquiring the page display information of the target small program according to the page display event.
5. The method of claim 4, wherein the target applet is an online running applet.
6. The method according to any one of claims 2-5, wherein the obtaining page display information of the target applet according to the page display event comprises:
acquiring a page storage path and page content of each page during display according to the page display event;
determining a mapping relation between a page storage path and page content of each page;
and carrying out snapshot processing on the page content corresponding to each page to obtain a page snapshot corresponding to each page of the target applet.
7. The method of any of claims 1-5, wherein said determining whether the target applet is authenticated based on the content authentication response comprises:
displaying a content verification result of the target applet page;
receiving an audit result sent by an auditor according to the content verification result of each page;
and determining whether the target applet passes the verification or not according to the auditing result.
8. The method according to any one of claims 1-5, further comprising:
and if the target applet is not verified, determining that the operating authority of the target applet is in a closed state, and pushing the content verification response to an applet development platform, wherein the applet development platform is a device for developing and modifying the target applet.
9. A method of validating an applet, comprising:
receiving a content checking request sent by a test terminal, wherein the content checking request comprises: page display information of a target applet page, the page display information comprising: the page snapshot system comprises a page snapshot, a page identifier and a page storage path, wherein the page storage path has a mapping relation with the page content;
according to the page snapshot of the target small program page, carrying out validity verification on the page content of the target small program page to obtain a content verification result of the target small program page;
and generating a content verification response according to the content verification result, the page identification and the page storage path of each page, and feeding back the content verification response to the test terminal.
10. The method according to claim 9, wherein the performing validity verification on the page snapshot of the target applet page according to the content audit request to obtain a content verification result of the target applet page includes:
and inputting the page snapshot of each page of the target small program into a verification model, and outputting a content verification result of each page, wherein the verification model is based on a pre-trained model for verifying whether the content of the small program is legal or not.
11. An apparatus for validating an applet, comprising: the device comprises an acquisition module, a transceiver module and a determination module;
the obtaining module is configured to obtain page display information of a target applet page, where the page display information includes: the page snapshot system comprises a page snapshot, a page identifier and a page storage path, wherein the page storage path has a mapping relation with the page content;
the transceiver module is configured to send a content audit request to a server, and receive a content verification response fed back by the server, where the content audit request includes: the page display information of the target applet page, the content verification response including: the content verification result of the target applet page;
and the determining module is used for determining whether the target applet passes the verification according to the content verification response.
12. The apparatus of claim 11, wherein the obtaining module comprises: an acquisition unit and a trigger unit;
the acquisition unit is used for acquiring a script of the target applet;
the triggering unit is used for triggering a page display event of the target applet by running the script, wherein the page display event is used for representing that the page of the target applet is displayed;
the obtaining unit is further configured to obtain page display information of the target applet according to the page display event.
13. The apparatus of claim 12, wherein the target applet is an applet to be published.
14. The apparatus of claim 11, wherein the obtaining module comprises: an acquisition unit and a determination unit;
the acquiring unit is used for acquiring user operation behaviors of a target applet, wherein the user operation behaviors comprise browsing behaviors of the target applet;
the determining unit is configured to determine, according to the user operation behavior, a page display event of the target applet, where the page display event is used to represent that a page of the target applet is displayed;
the obtaining unit is further configured to obtain page display information of the target applet according to the page display event.
15. The apparatus of claim 14, wherein the target applet is an applet running on-line.
16. The apparatus according to any one of claims 12 to 15, wherein the obtaining unit is configured to obtain, according to the page display event, page display information of the target applet, specifically:
the obtaining unit is specifically configured to obtain a page storage path and page content of each page during display according to the page display event, determine a mapping relationship between the page storage path and the page content of each page, and perform snapshot processing on the page content corresponding to each page to obtain a page snapshot corresponding to each page of the target applet.
17. The apparatus according to any one of claims 11-15, wherein the determining module comprises: the device comprises a display unit, a receiving unit and a determining unit;
the display unit is used for displaying the content verification result of the target applet page;
the receiving unit is used for receiving the auditing result sent by the auditor according to the content verifying result of each page;
and the determining unit is used for determining whether the target applet passes the verification according to the auditing result.
18. The apparatus according to any of claims 11-15, wherein the determining module is further configured to determine that the operating right of the target applet is in a closed state;
the transceiver module is further configured to push the content verification response to an applet development platform, where the applet development platform is a device in which the target applet is developed and modified.
19. An apparatus for validating an applet, comprising: the system comprises a transceiver module, a verification module and a generation module;
the receiving and sending module is used for receiving a content checking request sent by the test terminal, and the content checking request comprises: page display information of a target applet page, the page display information comprising: the page snapshot system comprises a page snapshot, a page identifier and a page storage path, wherein the page storage path has a mapping relation with the page content;
the verification module is used for verifying the validity of the page content of the target small program page according to the page snapshot of the target small program page to obtain a content verification result of the target small program page;
the generating module is used for generating a content verification response according to the content verification result, the page identification and the page storage path of each page;
the transceiver module is further configured to feed back the content verification response to the test terminal.
20. The apparatus according to claim 19, wherein the verification module is specifically configured to input a page snapshot of each page of the target applet into a verification model, and output a content verification result of each page, and the verification model is based on a pre-trained model for verifying whether the content of the applet is legal.
21. A test terminal, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-8.
22. A server, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of claim 9 or 10.
23. A non-transitory computer readable storage medium having stored thereon computer instructions for causing the computer to perform the method of any one of claims 1-8.
24. A non-transitory computer readable storage medium storing computer instructions for causing a computer to perform the method of claim 9 or 10.
25. A method of validating an applet, comprising:
acquiring a page snapshot of a target applet;
and carrying out validity verification on the page snapshot of the target small program, and determining whether the target small program passes the verification.
CN202010419000.0A 2020-05-18 2020-05-18 Method, device, equipment and storage medium for verifying applet Active CN111597113B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010419000.0A CN111597113B (en) 2020-05-18 2020-05-18 Method, device, equipment and storage medium for verifying applet

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010419000.0A CN111597113B (en) 2020-05-18 2020-05-18 Method, device, equipment and storage medium for verifying applet

Publications (2)

Publication Number Publication Date
CN111597113A true CN111597113A (en) 2020-08-28
CN111597113B CN111597113B (en) 2023-08-15

Family

ID=72187328

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010419000.0A Active CN111597113B (en) 2020-05-18 2020-05-18 Method, device, equipment and storage medium for verifying applet

Country Status (1)

Country Link
CN (1) CN111597113B (en)

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112333239A (en) * 2020-10-10 2021-02-05 百度(中国)有限公司 Service auditing notification method, gateway, electronic equipment and readable medium
CN112860566A (en) * 2021-03-02 2021-05-28 百度在线网络技术(北京)有限公司 Applet detection method, device, electronic equipment and readable medium
CN113760762A (en) * 2021-09-08 2021-12-07 北京房江湖科技有限公司 Method for simulating operating environment of applet, electronic device and storage medium
CN113885967A (en) * 2021-10-22 2022-01-04 北京字跳网络技术有限公司 Method, device, equipment and medium for starting small program
KR20220006126A (en) * 2020-10-10 2022-01-14 바이두 (차이나) 컴퍼니 리미티드 Transaction check notification method and gateway, electronic device, readable medium, computer program product
CN114003412A (en) * 2021-12-27 2022-02-01 支付宝(杭州)信息技术有限公司 Method and device for communicating small program and host program
CN114020992A (en) * 2021-11-09 2022-02-08 北京百度网讯科技有限公司 Page blocking method, device, system, client and storage medium
CN115203748A (en) * 2022-09-14 2022-10-18 北京锘崴信息科技有限公司 Financial privacy information auditing method and device based on information credibility verification
WO2022247226A1 (en) * 2021-05-28 2022-12-01 深圳前海微众银行股份有限公司 Applet monitoring method and device
WO2023241198A1 (en) * 2022-06-15 2023-12-21 华为技术有限公司 Communication method, apparatus and system

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103544213A (en) * 2013-09-16 2014-01-29 青岛英网资讯股份有限公司 Network content upgrading detection assessment method and system
CN106919821A (en) * 2015-12-25 2017-07-04 阿里巴巴集团控股有限公司 User authentication method and device
CN107977293A (en) * 2016-10-21 2018-05-01 英业达科技有限公司 Monitoring programme generation system and its production method
CN108932279A (en) * 2018-04-28 2018-12-04 华为技术有限公司 A kind of application page processing method and processing device
CN108959068A (en) * 2018-06-04 2018-12-07 广州视源电子科技股份有限公司 Software interface test method, equipment and storage medium
CN110390198A (en) * 2019-07-31 2019-10-29 阿里巴巴集团控股有限公司 Risk method for inspecting, device and the electronic equipment of a kind of pair of small routine
CN110674025A (en) * 2018-07-03 2020-01-10 百度在线网络技术(北京)有限公司 Interactive behavior monitoring method and device and computer equipment
US20200117577A1 (en) * 2018-10-15 2020-04-16 Sap Se Scalable ai framework for test automation

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103544213A (en) * 2013-09-16 2014-01-29 青岛英网资讯股份有限公司 Network content upgrading detection assessment method and system
CN106919821A (en) * 2015-12-25 2017-07-04 阿里巴巴集团控股有限公司 User authentication method and device
CN107977293A (en) * 2016-10-21 2018-05-01 英业达科技有限公司 Monitoring programme generation system and its production method
CN108932279A (en) * 2018-04-28 2018-12-04 华为技术有限公司 A kind of application page processing method and processing device
CN108959068A (en) * 2018-06-04 2018-12-07 广州视源电子科技股份有限公司 Software interface test method, equipment and storage medium
CN110674025A (en) * 2018-07-03 2020-01-10 百度在线网络技术(北京)有限公司 Interactive behavior monitoring method and device and computer equipment
US20200117577A1 (en) * 2018-10-15 2020-04-16 Sap Se Scalable ai framework for test automation
CN110390198A (en) * 2019-07-31 2019-10-29 阿里巴巴集团控股有限公司 Risk method for inspecting, device and the electronic equipment of a kind of pair of small routine

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
BUGLAI: ""微信小程序支持手机端提审和发布啦!"", pages 1 - 18, Retrieved from the Internet <URL:《https://mp.weixin.qq.com/s/PKv6h8xy_UJnIwfcBMr0Bg》> *
JANIS DALINS: ""Criminal motivation on the dark web: A categorisation model for law enforcement"", 《DIGITAL INVESTIGATION》, vol. 24, pages 62 - 71 *
张冉: ""支持测试预言生成的代码测试系统实用化研究"", 《中国优秀硕士学位论文全文数据库 信息科技辑》, no. 2018, pages 138 - 92 *

Cited By (17)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102651156B1 (en) * 2020-10-10 2024-03-26 바이두 (차이나) 컴퍼니 리미티드 Transaction check notification methods and gateways, electronic devices, readable media, and computer program products
KR20220006126A (en) * 2020-10-10 2022-01-14 바이두 (차이나) 컴퍼니 리미티드 Transaction check notification method and gateway, electronic device, readable medium, computer program product
CN112333239A (en) * 2020-10-10 2021-02-05 百度(中国)有限公司 Service auditing notification method, gateway, electronic equipment and readable medium
JP2023501850A (en) * 2020-10-10 2023-01-20 百度(中国)有限公司 Business audit reporting method and gateway, electronic device, readable medium and computer program
EP4009611A4 (en) * 2020-10-10 2022-09-14 Baidu (China) Co., Ltd. Service auditing notification method, gateway, electronic device, and readable medium
CN112860566A (en) * 2021-03-02 2021-05-28 百度在线网络技术(北京)有限公司 Applet detection method, device, electronic equipment and readable medium
CN112860566B (en) * 2021-03-02 2024-04-30 百度在线网络技术(北京)有限公司 Applet detection method, device, electronic equipment and readable medium
WO2022247226A1 (en) * 2021-05-28 2022-12-01 深圳前海微众银行股份有限公司 Applet monitoring method and device
CN113760762A (en) * 2021-09-08 2021-12-07 北京房江湖科技有限公司 Method for simulating operating environment of applet, electronic device and storage medium
CN113760762B (en) * 2021-09-08 2024-03-08 贝壳找房(北京)科技有限公司 Method for simulating operating environment of applet, electronic device and storage medium
CN113885967A (en) * 2021-10-22 2022-01-04 北京字跳网络技术有限公司 Method, device, equipment and medium for starting small program
CN113885967B (en) * 2021-10-22 2024-02-13 北京字跳网络技术有限公司 Method, device, equipment and medium for starting applet
CN114020992A (en) * 2021-11-09 2022-02-08 北京百度网讯科技有限公司 Page blocking method, device, system, client and storage medium
CN114003412A (en) * 2021-12-27 2022-02-01 支付宝(杭州)信息技术有限公司 Method and device for communicating small program and host program
WO2023241198A1 (en) * 2022-06-15 2023-12-21 华为技术有限公司 Communication method, apparatus and system
CN115203748B (en) * 2022-09-14 2022-12-13 北京锘崴信息科技有限公司 Financial privacy information auditing method and device based on information credibility verification
CN115203748A (en) * 2022-09-14 2022-10-18 北京锘崴信息科技有限公司 Financial privacy information auditing method and device based on information credibility verification

Also Published As

Publication number Publication date
CN111597113B (en) 2023-08-15

Similar Documents

Publication Publication Date Title
CN111597113B (en) Method, device, equipment and storage medium for verifying applet
CN111597114B (en) Method, device, equipment and storage medium for verifying applet
US10216377B2 (en) Visual regression analysis
US10318667B2 (en) Test case generation
CN108959068B (en) Software interface testing method, device and storage medium
US9720799B1 (en) Validating applications using object level hierarchy analysis
CA2691666C (en) System and method for simulating computer network attacks
CN111078554B (en) Applet debugging method, device, equipment and storage medium
US11237948B2 (en) Rendering engine component abstraction system
US11245601B2 (en) Automated integrated test system and method thereof
CN112527252A (en) Applet management method and device, applet platform, electronic device and medium
CN111881387B (en) Data processing method, device, equipment and medium for small program
CN107102885A (en) The method and device of Android simulator is detected using ADB modes
US20160275000A1 (en) System and method of automated application screen flow generation for detecting aberration in mobile application
JP2021152915A (en) Picture verification method, device, electronic facility, computer-readable storage medium, and program
CN111654495B (en) Method, apparatus, device and storage medium for determining traffic generation source
CN112035282A (en) API management method, device, equipment and storage medium applied to cloud platform
WO2022100075A1 (en) Method and apparatus for performance test, electronic device and computer-readable medium
US11368554B2 (en) Systems and methods for regulating service behavior
US10176062B2 (en) Cloud servers and methods for handling dysfunctional cloud services
CN115600213A (en) Vulnerability management method, device, medium and equipment based on application program
KR20220003625A (en) Performance detection method, apparatus, electronic device, computer readable medium and computer program product
JP7426493B2 (en) Auxiliary processing methods, equipment, electronic equipment, storage media and programs for software development
CN116109457B (en) Access system and method applied to interaction of multiple departments in smart city
CN114579976B (en) Automatic verification method and system for heap memory damage loopholes based on state transition

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant