Single-page application dynamic vulnerability backtracking detection method based on state graph
By constructing a state graph and a cross-state backtracking mechanism, the limitations of vulnerability detection in single-page applications are overcome, enabling accurate detection of asynchronously loaded content and cross-page vulnerability chains, thereby improving the coverage and efficiency of vulnerability detection.
Patent Information
- Application Number
- CN202510402151.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-01
- Publication Date
- 2026-01-16
- Estimated Expiration
- 2045-04-01
AI Technical Summary
Existing methods for detecting vulnerabilities in single-page applications cannot effectively identify asynchronously loaded dynamic content and cross-page vulnerability chains, nor can they revert to historical states for detection.
By constructing a state graph, monitoring the front-end application, recording page navigation relationships and DOM structure, and injecting test payloads, we can achieve cross-state backtracking and DOM difference analysis to locate cross-page vulnerability chains.
It enables comprehensive detection of dynamic vulnerabilities in single-page applications, improving the coverage and efficiency of vulnerability detection. It can track vulnerability chains across pages and multiple states, and accurately capture potential vulnerabilities.
Smart Images

Figure CN120316780B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The embodiment of the present application relates to the technical field of information security, and particularly relates to a single-page application dynamic vulnerability backtracking detection method based on a state graph. BACKGROUND
[0002] At present, the vulnerability detection for SPA (Single Page Web Application) such as the crawler based on HTML analysis only analyzes the initial static structure of the page, so that the dynamic content (for example, the pop-up window triggered by user interaction, the dynamic form or the module rendered by AJAX request) loaded asynchronously is completely missed. Meanwhile, the current detection technology only supports one-way state promotion (for example, page A to page B, and then to page C), and cannot back to the historical state (for example, from page C back to page B), so as to identify the cross-page vulnerability chain (for example, the input parameter of page B triggers the XSS vulnerability when page C is rendered).
[0003] In view of this, the present application is proposed. SUMMARY
[0004] The embodiment of the present application provides a single-page application dynamic vulnerability backtracking detection method based on a state graph, so as to solve the above technical problems.
[0005] In a first aspect, the embodiment of the present application provides a single-page application dynamic vulnerability backtracking detection method based on a state graph, comprising:
[0006] A state graph is constructed by monitoring the front-end application, wherein the state graph takes each front-end application page as a node, takes the jump relationship between each front-end application page as the edge between the nodes, and the attributes of each node include the DOM structure and the timing information of each front-end application page at each time of loading;
[0007] A test load is injected into the front-end application page, and in the test process, each time a new front-end application page is detected, the following operations are sequentially performed:
[0008] S1-1, if the new front-end application page triggers a vulnerability, backtracking to the initial front-end application page in the state graph to reproduce other vulnerability entrances of the initial front-end application page;
[0009] S1-2, if the new front-end application page does not trigger a vulnerability, according to the abnormal situation of the new front-end application page, the backtracking depth of the upper front-end application page in the state graph is determined; and for the terminal page of backtracking, the DOM structure after backtracking is compared with the initial DOM structure in the state graph to determine the area where the DOM structure changes; and the area is scanned for vulnerabilities to locate the vulnerability chain caused by cross-page data transmission.
[0010] In a second aspect, an electronic device is provided, and the electronic device comprises:
[0011] one or more processors;
[0012] a memory for storing one or more programs,
[0013] When the one or more programs are executed by the one or more processors, the one or more processors implement the state graph-based dynamic vulnerability backtracking detection method for single-page application according to any embodiment.
[0014] In a third aspect, a computer-readable storage medium is provided, and the computer-readable storage medium stores a computer program, which, when executed by a processor, implements the state graph-based dynamic vulnerability backtracking detection method for single-page application according to any embodiment.
[0015] In summary, the state graph-based dynamic vulnerability backtracking detection method for single-page application is provided, and through deep integration of the runtime state tracking and automatic interaction simulation of the front-end framework, the multi-dimensional vulnerability mining and risk analysis in the SPA application are realized. Different from the traditional vulnerability detection method, the present embodiment can capture the asynchronous loading content (such as the pop-up window triggered by user clicks, dynamic forms and AJAX rendering modules) based on the dynamic execution of JavaScript code by the headless browser, and effectively breaks through the limitation of the traditional tool that only analyzes the static page structure.
[0016] The method of the present embodiment can accurately record each page jump, data change and user interaction behavior by constructing a backtracking state graph, and can backtrack between multiple historical states to track the formation process of the vulnerability chain. For example, some input data is submitted in page A, processed in page B, and may trigger an XSS vulnerability in page C. The system can backtrack to the state of page A, and through differential analysis, the vulnerability chain triggered across pages and multiple states is found. Through this backtracking mechanism, the present application breaks through the limitation of the traditional tool that cannot trigger multi-step vulnerability chain detection, and improves the vulnerability mining capability of dynamic Web applications.
[0017] Specifically, through the cross-state backtracking mechanism, the dynamic state tracking and backtracking in the single-page application are realized. Different from the traditional static analysis method, the device can accurately track and analyze the data flow when the application is rolled back from one state (such as a payment page) to a historical state (such as an order page). By constructing a state graph, the device records the change path from one state to another state, and combines the DOM differential analysis algorithm to efficiently identify the vulnerability chain that may be triggered in the state change. This innovative mechanism can accurately capture potential vulnerabilities in cross-page and cross-state interactions, significantly improving the coverage and efficiency of vulnerability detection. BRIEF DESCRIPTION OF DRAWINGS
[0018] In order to more clearly illustrate the technical solutions in the specific embodiments or prior art of the present application, the drawings required to be used in the specific embodiments or prior art description will be briefly introduced as follows. Obviously, the drawings in the following description are some embodiments of the present application, and other drawings can also be obtained by those skilled in the art without creative effort on the basis of these drawings.
[0019] Figure 1 is a flowchart of a single-page application dynamic vulnerability backtracking detection method based on a state atlas provided by an embodiment of the present application;
[0020] Figure 2 is a flowchart of another single-page application dynamic vulnerability backtracking detection method based on a state atlas provided by an embodiment of the present application;
[0021] Figure 3 is a structural schematic diagram of an electronic device provided by an embodiment of the present application. DETAILED DESCRIPTION
[0022] In order to make the objects, technical solutions and advantages of the present application clearer, the technical solutions of the present application will be described clearly and completely. Obviously, the described embodiments are only some of the embodiments of the present application, not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative effort belong to the scope of protection of the present application.
[0023] In the description of the present application, it should be noted that the orientations or positional relationships indicated by the terms "center", "upper", "lower", "left", "right", "vertical", "horizontal", "inner", "outer" and the like are based on the orientations or positional relationships shown in the drawings, and are only for the convenience of describing the present application and simplifying the description, and therefore cannot be understood as indicating or implying that the devices or elements referred to must have a particular orientation, be constructed and operated in a particular orientation, and therefore cannot be understood as limiting the present application. In addition, the terms "first", "second", "third" are only for the purpose of description, and cannot be understood as indicating or implying relative importance.
[0024] In the description of the present application, it should be noted that, unless otherwise explicitly specified and limited, the terms "mounting", "connection", "connection" should be understood broadly, for example, it can be fixedly connected, or it can be detachably connected, or integrally connected; it can be mechanically connected, or it can be electrically connected; it can be directly connected, or it can be indirectly connected through an intermediate medium; it can be the communication inside two elements. For those skilled in the art, the specific meaning of the above terms in the present application can be understood according to the specific circumstances.
[0025] Figure 1 is a flowchart of a single-page application dynamic vulnerability backtracking detection method based on a state graph provided by an embodiment of the present application. The method is suitable for vulnerability detection of SPA, and aims to improve the accuracy, efficiency and comprehensiveness of single-page application vulnerability detection, especially in dynamic interaction, state backtracking and cross-page vulnerability chain detection, to solve the problem that existing vulnerability detection methods cannot cope with the complexity and multi-state interaction of SPA. The method is executed by an electronic device, as shown in Figure 1 , and specifically includes the following steps:
[0026] S110, constructing a state graph by monitoring the front-end application, wherein the state graph takes each front-end application page as a node, and the transition relationship between each front-end application page as the edge between nodes, and each node attribute includes the DOM (Document Object Model) structure and timing information of each front-end application page at each load.
[0027] The state graph of this embodiment is used to record the dynamic transition relationship between each front-end application page in user interaction behavior and the timing change information of the page. The state graph can be gradually generated in actual user interaction, or gradually generated when specifically detecting vulnerabilities of SPA.
[0028] Optionally, each time the current page of the front-end application is loaded, if the page is not loaded for the first time, a node of the current page can be generated in the state graph of the front-end application, and the current DOM structure and timing information of the page are stored in the attribute of the node; if the page is not loaded for the first time, the current DOM structure and timing information can be directly stored in the attribute of the corresponding node. In addition, if the current front-end application page is transferred from other front-end application pages, a directed edge is established between the node and the node of the other front-end application pages in the state graph, so as to record the transition relationship between the nodes.
[0029] In a specific embodiment, when a certain SPA page is loaded, the initialization of the SPA page is first performed, and the DOM structure of the page in this loading is obtained. Then, the DOM structure is analyzed in depth, and the state management mechanism (such as Redux, Vuex) of the SPA is identified in combination with the front-end framework (such as React, Vue, Angular, etc.) of the SPA. Then, by hijacking the API, a state atlas is dynamically constructed, and the key information (such as URL, DOM hash value, global state snapshot, etc.) of each state node is recorded; when the user performs route jumping (for example, from the commodity list page to the detail page), a new node is generated and associated with the parent node to form a tree structure. In this embodiment, by analyzing the API of the framework, the state change, route jumping and user interaction sequence of the front-end application are monitored to ensure that all possible user interactions can be captured, and the state atlas generated thereby can backtrack between different states to provide a data basis for cross-page and cross-state vulnerability chain detection.
[0030] S120, a test payload is injected into the front-end application page, and the following operations are sequentially performed every time a new front-end application page is detected during the test process:
[0031] S1-1, if the new front-end application page triggers a vulnerability, backtracking to the initial front-end application page in the state atlas to reproduce other vulnerability entry points of the initial front-end application page;
[0032] S1-2, if the new front-end application page does not trigger a vulnerability, determining the backtracking depth of the upper front-end application page in the state atlas according to the abnormal situation of the new front-end application page; and comparing the DOM structure after backtracking with the initial DOM structure in the state atlas for the terminal page of backtracking to determine the area where the DOM structure has changed; performing vulnerability scanning on the area to locate the vulnerability chain caused by cross-page data transmission.
[0033] In this embodiment, the user interaction behavior is automatically simulated to trigger the interaction and jump operation in each front-end application page, and the test case for vulnerability detection is automatically injected into each front-end application page to detect and locate the vulnerability or vulnerability chain.
[0034] In a specific embodiment, the rule engine and the semantic analysis model can be used to distinguish between regular operations and high-risk operations (such as delete and reset buttons), so as to isolate the high-risk operations in the user interaction behavior to be simulated, avoid the interruption of scanning or data damage caused by accidental triggering during monitoring, and simulate the regular user interaction behavior (such as clicking buttons, submitting forms, and inputting content) to trigger the key operation and inject the test Payload (such as XSS vector <script>alert(1)< / script> ).
[0035] In this process, whenever a new state (i.e. a new front-end application page such as a payment completion page) is detected, the history state (i.e. the front-end application page of the previous level or levels of the page in the state atlas, such as an order page) is restored by backtracking the state atlas. At this time, the following two cases may occur:
[0036] Case one, a vulnerability has been triggered in the new state. In this case, the initial UI can be backtracked to ensure that the vulnerability entry is reproducible, and the detection of the next test case is continued based on the state atlas extended after backtracking, and returns to S110. Here, the vulnerability entry reproducible means that the link from the initial page to the new state has been detected, but the link from other entries in the initial page to other subordinate pages has not been detected, and these entries need to be restored to start the detection of other links by simulating user behavior.
[0037] Case two, a vulnerability has not been triggered in the new state. In this case, it cannot be considered that the current operation link does not have a vulnerability, and it is possible that the vulnerability is not reflected in the new state, but it has changed the information of the upper front-end application page. Therefore, the embodiment performs supplementary detection by page backtracking. According to the abnormal situation of the new front-end application page, the embodiment provides the following three optional implementation manners:
[0038] The first optional implementation manner is to back up to the upper level front-end application page of the new front-end application page in the state atlas if the new front-end application page finds data integrity abnormalities (such as parameter loss, form overlay). For example, after the order ID, user ID and other parameters are found to be lost in the current page, although no vulnerability warning is issued for the current page, it is possible that a vulnerability rule has been triggered in the upper level page (such as tampering with the order ID, user ID, etc.), at which time the upper level front-end application page can be backtracked according to the state atlas, and further detection is awaited.
[0039] In a second optional embodiment, if the new front-end application page finds a high-risk operation exception (such as payment, deletion, or permission change), the trigger point of the high-risk operation is determined, and the front-end application page where the trigger point is located is rolled back. Optionally, the trigger point is usually represented by a page element, such as a function entry, a button element, or the like in a page. The trigger point of the high-risk operation can be determined by analyzing the names of the function entries and button elements in the upper-level pages, so as to determine the depth of the rollback. For example, after the high-risk operation “payment” is found in the current page, the names of the function entries and button elements in the upper-level pages are detected, and if a name has the highest similarity with “payment”, the page element corresponding to the name is the trigger point. The element can be located in the upper-level page of the new front-end application page, or can be located in the upper-level pages of the new front-end application page. The page where the element is located is taken as the terminal page of the rollback, and is waiting for further detection.
[0040] In a third optional embodiment, if the new front-end application page has no obvious exception, a minimum depth rollback is performed. For example, if the minimum rollback depth is set to 1 level, the final upper-level front-end application page of the state graph is returned, and is waiting for further detection.
[0041] Further, after the rollback of the above three optional embodiments is completed, the DOM structure after the rollback of the terminal page and the original DOM of the terminal page in the state graph are analyzed, the changed area is scanned, and the vulnerability chain caused by the cross-state data transmission is accurately located. Optionally, if a vulnerability is detected in the changed area, the jump chain from the upper-level front-end application page of the terminal page to the new front-end application page is located as the vulnerability chain caused by the cross-page data transmission.
[0042] Whether it is case one or case two, after the above rollback is completed, the DOM structure after the rollback and the timing information thereof can be taken as the attributes of the terminal page of the rollback, and are included in the state graph. The DOM structure is marked as having been rolled back, so as to avoid repeated rollback in subsequent detection.
[0043] In addition to the above cross-state rollback mechanism, the front-end storage can be monitored in real time. If it is found that sensitive data is stored in plaintext or transmitted without encryption, it is marked as a potential vulnerability. For example, the LocalStorage, IndexedDB, and the like can be monitored in real time, the storage and transmission behaviors of sensitive data (such as Token, user information, and the like) in the state change process are analyzed, and if it is found that sensitive data is stored in plaintext or transmitted without encryption, an alarm can be generated and marked as a potential vulnerability.
[0044] Finally, when all DOM structures in the state graph are standard for backtracking, the state backtracking mechanism is exited; the vulnerabilities and vulnerability chains detected in the cross-state backtracking mechanism, and the potential vulnerabilities detected in the front-end storage implementation monitoring, are collectively generated into a vulnerability detection report.
[0045] The implementation process of the entire method can also be combined with Figure 2 It should be understood that, in the figure, according to the execution subject of each key step, the electronic device implementing the entire method is divided into a browser instance module, an API hijacking module, a DOM parsing module, a state graph construction module, a state management integration module, an intelligent event filtering engine, a cross-state backtracking detection module, a front-end storage monitoring module, and a vulnerability report generation module. Each module cooperates with each other to complete the method of the embodiment.
[0046] In summary, the embodiment proposes a single-page application dynamic vulnerability backtracking detection method based on a state graph. Through deep integration of runtime state tracking and automated interactive simulation of the front-end framework, multi-dimensional vulnerability mining and risk analysis in SPA applications are achieved. Unlike traditional vulnerability detection methods, the embodiment dynamically executes JavaScript code based on a headless browser, which can capture asynchronously loaded content (such as pop-ups triggered by user clicks, dynamic forms, and AJAX rendering modules), effectively breaking through the limitations of traditional tools that only analyze static page structures.
[0047] The method of the embodiment combines the front-end framework API hijacking mechanism (such as route jumping, global state changing, etc.), accurately records each page jump, data change, and user interaction behavior by constructing a backtracking state graph, and can backtrack between multiple historical states to track the formation process of vulnerability chains. For example, some input data is submitted in page A, processed in page B, and may trigger an XSS vulnerability in page C. The system can backtrack to the state of page A and find the vulnerability chain triggered across pages and multiple states through differential analysis. Through this backtracking mechanism, the invention breaks through the limitations of traditional tools that cannot trigger multi-step vulnerability chain detection, and improves the vulnerability mining capability of dynamic Web applications.
[0048] In summary, the method of the embodiment can achieve the following beneficial effects:
[0049] 1. Through the cross-state backtracking mechanism, the dynamic state tracking and backtracking in the single-page application is realized. Unlike the traditional static analysis method, the device can accurately track and analyze the data flow when the application is rolled back from one state (such as the payment page) to the historical state (such as the order page). By constructing a state atlas, the device records the change path from one state to another, and combines the DOM difference analysis algorithm to efficiently identify the vulnerability chain that may be caused by state changes. This innovative mechanism can accurately capture potential vulnerabilities in cross-page and cross-state interactions, significantly improving the coverage and efficiency of vulnerability detection;
[0050] 2. The built-in intelligent event filtering engine can accurately distinguish between regular operations and high-risk operations (such as deleting accounts, resetting permissions, form submission, etc.). The device automatically identifies and prioritizes high-risk operations for vulnerability scanning through semantic analysis technology. By simulating user interaction behaviors (such as clicking, inputting, and submitting), the device ensures comprehensive coverage of all potential vulnerabilities, especially accurate detection when sensitive data and high-risk operations are involved, reducing false triggers and redundant operations, and improving detection efficiency;
[0051] 3. Real-time monitoring of the local storage behavior of the application, analyzing the storage and transmission of sensitive data (such as Token, user information, etc.) during state changes. Through regular expression rules (such as matching Token, password, and other sensitive information), it can timely identify improper storage or transmission of sensitive data without encryption. Once sensitive data is detected to be stored in plaintext or transmitted through an insecure channel, an alarm will be generated immediately and marked as a potential vulnerability, ensuring that sensitive data is adequately protected in the application.
[0052] Figure 3 A structural diagram of an electronic device according to an embodiment of the present application is shown in Figure 3 The device includes a processor 60, a memory 61, an input device 62, and an output device 63; the number of processors 60 in the device can be one or more, Figure 3 Taking one processor 60 as an example; the processor 60, the memory 61, the input device 62, and the output device 63 in the device can be connected through a bus or other means, Figure 3 Taking connection through a bus as an example.
[0053] The memory 61 is a kind of computer readable storage medium, can be used to store software program, computer executable program and module, such as the program instruction / module corresponding to the single-page application dynamic vulnerability backtracking detection method based on state atlas in the embodiment of the present application. The processor 60 executes the software program, instruction and module stored in the memory 61, thereby performing various functions of the device and data processing, i.e. implementing the single-page application dynamic vulnerability backtracking detection method based on state atlas.
[0054] The memory 61 can include a program storage area that stores an operating system, application programs required for at least one function, and a data storage area that stores data created according to the use of the terminal, etc. In addition, the memory 61 can include a high-speed random access memory, and can further include a non-volatile memory such as at least one of a magnetic disk storage device, a flash memory device, or other non-volatile solid state memory device. In some examples, the memory 61 can further include a memory disposed remotely with respect to the processor 60, which can be connected to the device through a network. Examples of the network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0055] The input device 62 can be used to receive input digital or character information, and to generate key signal input related to user settings and function control of the device. The output device 63 can include a display device such as a display screen.
[0056] The embodiment of the present application also provides a computer readable storage medium, which stores a computer program, and the program is executed by a processor to implement the state graph-based single-page application dynamic vulnerability backtracking detection method of any embodiment.
[0057] The computer storage medium of the embodiment of the present application can adopt any combination of one or more computer readable media. The computer readable medium can be a computer readable signal medium or a computer readable storage medium. The computer readable storage medium can be, for example, but is not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or apparatus, or any combination of the above. More specific examples (non-exhaustive list) of the computer readable storage medium include an electrical connection having one or more wires, a portable computer diskette, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In this document, the computer readable storage medium can be any tangible medium that contains or stores a program that can be used by or in connection with an instruction execution system, device or apparatus.
[0058] A computer readable signal medium can include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated signal can take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium can be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate or transport program code. Program code embodied on a computer readable signal medium can be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, R.F, etc., or any suitable combination of the foregoing.
[0059] Computer readable program code embodied on a computer readable medium can be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, R.F, etc., or any suitable combination of the foregoing.
[0060] Computer program code for carrying out operations for aspects of the present application can be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C++ or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code can execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the latter scenario, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or the connection can be made to an external computer (for example, through the Internet using an Internet Service Provider). These implementations can provide for a great deal of flexibility, portability, and adaptability as well as the advantage that a new version of the program code can be deployed quickly as part of an upgrade procedure.
[0061] Finally, it should be noted that the above-mentioned embodiments are merely intended for describing and illustrating, not limiting the technical solutions of the present application; even though the technical solutions of the present application have been described in detail with reference to the above-mentioned embodiments, those skilled in the art should understand that they can still modify the technical solutions recorded in the above-mentioned embodiments, or equivalently replace some or all of the technical features thereof; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the technical solutions of the embodiments of the present application.
Claims
1. A state map-based single-page application dynamic vulnerability backtracking detection method, characterized in that, The method comprises the following steps: By monitoring the front-end application, a state graph is constructed, wherein the state graph takes each front-end application page as a node, and the transition relationship between each front-end application page as the edge between nodes, and the attributes of each node include the DOM structure and timing information of each front-end application page at each loading time; A test load is injected into the front-end application page, and during the test, each time a new front-end application page is detected, the following operations are sequentially performed: S1-1, if the new front-end application page triggers a vulnerability, backtrack to the initial front-end application page in the state graph to reproduce other vulnerability entries of the initial front-end application page; S1-2, if the new front-end application page does not trigger a vulnerability: If data integrity anomalies are found in the new front-end application page, backtrack to the previous front-end application page of the new front-end application page in the state graph; if high-risk operation anomalies are found in the new front-end application page, determine the page element triggering the high-risk operation, and backtrack to the front-end application page where the page element is located; if no anomalies are found in the new front-end application page, perform a minimum depth backtracking; For the end point page of the backtracking, compare the backtracked DOM structure with the initial DOM structure in the state graph to determine the region where the DOM structure has changed; and perform a vulnerability scan on the region to locate a vulnerability chain caused by cross-page data transmission.
2. The method of claim 1, wherein, The method of constructing a state graph by monitoring the front-end application comprises the following steps: Load the current page of the front-end application, and generate a node of the current page in the state graph of the front-end application; Store the current DOM structure and timing information of the current page in the attributes of the node; If the current page is jumped from another front-end application page, establish an edge between the node and the node of the another front-end application page in the state graph.
3. The method of claim 1, wherein, The method of performing a vulnerability scan on the region to locate a vulnerability chain caused by cross-page data transmission comprises the following steps: If a vulnerability is detected in the region, locate the jump chain from the previous front-end application page of the end point page to the new front-end application page as a vulnerability chain caused by cross-page data transmission.
4. The method of claim 1, wherein, After the method of performing a vulnerability scan on the region to locate a vulnerability chain caused by cross-page data transmission, the method further comprises the following steps: Integrate the backtracked DOM structure into the state graph and mark it as backtracked to avoid subsequent repeated backtracking.
5. The method of claim 1, wherein, The method of injecting a test load into the front-end application page comprises the following steps: Distinguish between normal operations and high-risk operations through a rule engine and a semantic analysis model area; Simulate user interaction behaviors without high-risk operations to trigger each level of front-end application page and inject a test load.
6. The method of claim 1, wherein, The method further comprises the following steps: Real-time monitor the front-end storage, and if sensitive data is found to be stored in plaintext or transmitted without encryption, mark it as a potential vulnerability.
7. The method of claim 6, wherein, After the method of real-time monitoring the front-end storage and marking a potential vulnerability if sensitive data is found to be stored in plaintext or transmitted without encryption, the method further comprises the following steps: Generate a detection report according to each potential vulnerability, and the vulnerabilities and vulnerability chains identified each time S1-1 and S1-2 are performed.
8. An electronic device, comprising: The method comprises the following steps: one or more processors; a memory for storing one or more programs, when the one or more programs are executed by the one or more processors, so that the one or more processors realize the state graph-based single-page application dynamic vulnerability backtracking detection method of any one of claims 1-7.
9. A computer-readable storage medium, characterized in that, a computer program is stored thereon, which is executed by a processor to realize the state graph-based single-page application dynamic vulnerability backtracking detection method of any one of claims 1-7.
Citation Information
Patent Citations
State transition diagram based XSS (cross-site scripting) vulnerability detection method
CN106845248A
Page fuzzing test method and device for single-page application program and electronic equipment
CN117407888A
Cross-site script vulnerability detection method, device and equipment
CN119051913A