Data debugging output method and system based on page isolation

By creating a second program page the same as the original program page in the page isolation business system, identifying and replacing the statements to be debugged, and configuring the debug output function, the debugging cracking risks and log device bloated problems in the existing system debugging information output methods are solved, and flexible debugging output is achieved and debugging security is improved.

CN120144431APending Publication Date: 2025-06-13FUJIAN TQ ONLINE INTERACTIVE INC
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510171074.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-17
Publication Date
2025-06-13

AI Technical Summary

Technical Problem

The existing system debugging information output methods have the risk of debugging and cracking, and the log device is bloated, which affects debugging efficiency and program context processing efficiency, and requires recompilation of the program, affecting debugging flexibility.

Method used

Using the data debugging and output method based on page isolation, the debug output function is configured by creating a second program page the same as the original program page in the page isolation business system, identifying the function structure of the statement to be debugged, and replacing it with the isolated debugging statement, and configuring the debug output function.

Benefits of technology

It realizes flexible debugging and output without affecting the original program, improves debugging security, solves the problems of data bloat and program recompilation, and improves debugging efficiency and flexibility.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120144431A_ABST
    Figure CN120144431A_ABST
Patent Text Reader

Abstract

The invention discloses a data debugging output method and system based on page isolation, and the method comprises the steps: building a second program page which is the same as a first program page in a page isolation business system after determining the first program page; the method comprises the following steps: determining a to-be-debugged statement in a first program page, identifying a function structure of the to-be-debugged statement by a page isolation service system, replacing execution of the to-be-debugged statement in the first program page with execution of an isolation debugging statement corresponding to the page isolation service system after successful identification, and configuring a debugging output function for the isolation debugging statement. In this way, the debugging output tool can be created through the service system, the original program can be subjected to output debugging and debugging output configuration operation under the condition that the original program is not moved, the problems of data bloating and program recompiling in the prior art can be solved, flexible debugging output is achieved, and the debugging safety is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of data debugging output, and particularly relates to a data debugging output method and system based on page isolation. Background Art

[0002] System debugging output is a commonly used debugging method for developers, which is convenient for debugging information generated during the operation of different operating systems, application programs or services. These information can help developers or system administrators diagnose and solve problems.

[0003] Currently, for system debugging information output, a txt output log file is usually adopted and the log file is stored on the disk. However, in the log device, it is easy for attackers to find out the key points of the program through log keywords for debugging and cracking; moreover, the log device belongs to a bloated system, which not only has the problem of low efficiency of debugging output, but also affects the processing efficiency of program context. And because the code is fixed during the program compilation process, the log device and the program itself need to be recompiled, which affects the debugging flexibility. Summary of the Invention

[0004] The technical problem to be solved by the present invention is: to provide a data debugging output method and system based on page isolation, which can perform flexible debugging output without affecting the original program and can improve debugging security.

[0005] To solve the above technical problem, the technical solution adopted by the present invention is: A data debugging output method based on page isolation, comprising the steps of: Determine a first program page, and create a second program page identical to the first program page in the page isolation service system; Determine the statements to be debugged in the first program page, and let the page isolation service system identify the function structure of the statements to be debugged, and replace the statements to be debugged in the first program page with the isolation debugging statements corresponding to the page isolation service system; Configure a debugging output function for the isolation debugging statements.

[0006] To solve the above technical problem, another technical solution adopted by the present invention is: A data debugging output system based on page isolation, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, each step of the above-mentioned data debugging output method based on page isolation is implemented.

[0007] The beneficial effects of the present invention are as follows: After determining the first program page, a second program page identical to the first program page is created in the page isolation service system; the statements to be debugged in the first program page are determined, the function structure of the statements to be debugged is identified by the page isolation service system, and after successful identification, the statements to be debugged in the first program page are replaced with the isolation debug statements corresponding to the page isolation service system, and a debug output function is configured for the isolation debug statements. In this way, a debug output tool can be created through the service system, and the original program can be output and debugged and the debug output can be configured without modifying the original program, which can solve the problems of data bloat and program recompilation in the prior art, achieve flexible debug output, and improve the debug security effect. BRIEF DESCRIPTION OF THE DRAWINGS

[0008] Figure 1 It is a flowchart of a data debug output method based on page isolation according to an embodiment of the present invention; Figure 2 It is a schematic diagram of a data debug output system based on page isolation according to an embodiment of the present invention; Figure 3 It is a program flow logic diagram of a data debug output method based on page isolation according to an embodiment of the present invention; Figure 4 It is a flow logic diagram of function array generation according to an embodiment of the present invention; Figure 5 It is a flow logic diagram of function feature recognition and replacement according to an embodiment of the present invention; Figure 6 It is a flow logic diagram of service system recognition, feature replacement and debug output according to an embodiment of the present invention; Label description: 1. A data debug output system based on page isolation; 2. Memory; 3. Processor. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0009] To describe in detail the technical content, the achieved objectives and the effects of the present invention, the following is described in conjunction with the embodiments and with reference to the accompanying drawings.

[0010] Please refer to Figure 1 , an embodiment of the present invention provides a data debug output method based on page isolation, including the steps of: Determine the first program page, and create a second program page identical to the first program page in the page isolation service system; Determine the statements to be debugged in the first program page, identify the function structure of the statements to be debugged by the page isolation service system, and replace the statements to be debugged in the first program page with the isolation debug statements corresponding to the page isolation service system; Configure a debugging output function for the isolation debugging statement.

[0011] As can be seen from the above description, the beneficial effects of the present invention are as follows: after determining the first program page, create a second program page identical to the first program page in the page isolation service system; determine the statement to be debugged in the first program page, have the page isolation service system identify the function structure of the statement to be debugged, and after successful identification, replace the execution of the statement to be debugged in the first program page with the execution of the corresponding isolation debugging statement in the page isolation service system, and configure a debugging output function for the isolation debugging statement. In this way, a debugging output tool can be created through the service system, and the original program can be output debugged and the debugging output configured without modifying the original program, which can solve the problems of data bloat and program recompilation in the prior art, achieve flexible debugging output, and improve the effect of debugging security.

[0012] Further, after determining the first program page, it further includes: Obtain the first function structure in the first program page, perform preprocessing on the first function structure to obtain a first function feature, and store the first function feature in a first array; After creating a second program page identical to the first program page in the page isolation service system, it includes: Obtain the second function structure in the second program page, perform preprocessing on the second function structure to obtain a second function feature, and store the second function feature in a second array.

[0013] As can be seen from the above description, by establishing respective corresponding feature arrays for the first program page and the second program page, it is convenient to achieve data unification of the first program page and the second program page, and facilitate subsequent replacement debugging of the function features of the first program page.

[0014] Further, the page isolation service system identifying the function structure of the statement to be debugged includes: Search for and identify the corresponding second function feature as the isolation function feature in the second array according to the first function feature of the statement to be debugged, and obtain the second function structure of the isolation function feature.

[0015] As can be seen from the above description, the page isolation service system performs feature identification to facilitate capturing the function structure that needs to be debugged in the first program page.

[0016] Further, the function feature includes the function data address; Replacing the statement to be debugged in the first program page with the execution of the corresponding isolation debugging statement in the page isolation service system includes: Obtain the array address of the first array in the first program page and the first function data address of the statement to be debugged in the array address; Obtain the second function data address of the function structure with isolation function characteristics in the second array, and replace the first function data address in the first array with the second function data address.

[0017] As can be seen from the above description, by replacing features through address change, it is possible to avoid affecting the normal execution of the original program.

[0018] Furthermore, configure a debug output function for the isolated debug statement, including: Configure a debug output and its logging device according to the second function data address.

[0019] As can be seen from the above description, by configuring the debug output and its logging device according to the address, it is possible to flexibly perform on / off logging operations on the program and effectively perform flexible debug output without affecting the original program.

[0020] Please refer to Figure 2 , another embodiment of the present invention provides a data debug output system based on page isolation, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, each step of the above-mentioned data debug output method based on page isolation is implemented.

[0021] The above-mentioned data debug output method and system based on page isolation of the present invention are applicable to flexible debug output without affecting the original program and can improve debug security. The following is described through specific embodiments: Please refer to Figure 1 , Figures 3 to 6 , the first embodiment of the present invention is: A data debug output method based on page isolation, including steps: S1. Determine the first program page, and create a second program page identical to the first program page in the page isolation service system.

[0022] S11. Determine the first program page, obtain the first function structure in the first program page, preprocess the first function structure to obtain the first function feature, and store the first function feature in the first array.

[0023] Please refer to Figure 4, obtain the function structure in the program, and use the preprocessed function structure as the function feature. Since HASH has the characteristics of fast indexing and high search efficiency, the preprocessing method in this embodiment can be the HASH method. In some embodiments, function blank data is generated for the function structure. This blank data has no execution meaning and is equivalent to leaving a space to wait for the space to be filled.

[0024] Store the function feature as an array F, then F = {F1, F2, F3}, where F1, F2, and F3 are function features. Assume that F1 is the HASH value, then F1 = {data address}. The generated array can facilitate searching the array according to the HASH feature.

[0025] S12. Create a second program page identical to the first program page in the page isolation service system, obtain the second function structure in the second program page, preprocess the second function structure to obtain the second function feature, and store the second function feature in the second array.

[0026] In this embodiment, in the page isolation service system, there is also a matching function array for feature replacement during debugging. In this way, no matter where the function of the first program page is located in the program, debug log information and other information will be output due to feature replacement.

[0027] S2. Determine the statement to be debugged in the first program page. The page isolation service system identifies the function structure of the statement to be debugged, and replaces the statement to be debugged in the first program page with the isolation debug statement corresponding to the page isolation service system.

[0028] S21. Determine the statement to be debugged in the first program page, and search and identify the function structure corresponding to the isolation function feature in the second array according to the function feature of the statement to be debugged.

[0029] Please refer to Figure 5 , and the page isolation service system identifies the function feature of the statement to be debugged through the array and then identifies the function structure. In this embodiment, the function feature includes the function data address.

[0030] Specifically, assume that A is the first program and exports the structural feature, and B is the second program, which is the "output program". All functions of A are running normally before A is combined with B. When A is combined with B, the function flow of A will be captured by B because the structural feature in A is exposed. B can capture A because it recognizes the corresponding functional structure feature.

[0031] Moreover, replace the function structure in the page isolation business system, and replace the address of the position function in the second program page with the corresponding address in the page table. Then, through relay calls, that is, call the original function and return to the original environment to take effect.

[0032] S22. Obtain the array address of the first array in the first program page and the first function data address of the statement to be debugged in the array address, obtain the second function data address of the function structure with the isolation function feature in the second array, and replace the first function data address in the first array with the second function data address.

[0033] Please refer to Figure 6 , the recognition feature is used to match the function page in the isolation page that needs to be matched with it. That is, function a needs to output. At this time, there is an a1 in the isolation page that is exactly the same as function a, and a1 has the meaning of debug output. That is, as long as the execution of a is replaced with the execution of a1, a1 can be executed and the debug log of a can be output without affecting the function of a.

[0034] Obtain the HASH array address D, traverse the HASH features in the array through address D, and at the same time traverse the corresponding array address D1 in the isolation data. After obtaining the data address in D1, replace the data address in D.

[0035] S3. Configure the debug output function for the isolation debug statement.

[0036] Specifically, configure according to the second function data address, that is, it is necessary to improve the debug output system / log. Therefore, in this embodiment, the log switch operation of the compilation program can be performed by replacing the function features without changing the original function call.

[0037] Please refer to Figure 2 , Embodiment 2 of the present invention is as follows: A data debug output system 1 based on page isolation, including a memory 2, a processor 3, and a computer program stored on the memory 2 and operable on the processor 3. When the processor 3 executes the computer program, it implements each step of the data debug output method based on page isolation in Embodiment 1.

[0038] In summary, a data debugging output method and system based on page isolation provided by the present invention create a second program page identical to the first program page in a page isolation service system after determining the first program page; determine the statements to be debugged in the first program page, have the page isolation service system identify the function structure of the statements to be debugged, and after successful identification, replace the execution of the statements to be debugged in the first program page with the execution of the corresponding isolation debugging statements in the page isolation service system, and configure a debugging output function for the isolation debugging statements. In this way, a debugging output tool can be created through the service system, and the original program can be output debugged and configured for debugging output without modifying the original program, which can solve the problems of data bloat and program recompilation in the prior art, achieve flexible debugging output, and improve the debugging security effect.

[0039] The above are only embodiments of the present invention, and do not limit the patent scope of the present invention accordingly. Any equivalent transformation made using the content of the specification and drawings of the present invention, or directly or indirectly applied in related technical fields, shall equally be included in the patent protection scope of the present invention.

Claims

1. A data debugging output method based on page isolation, characterized in that: Includes steps: Determine a first program page, and create a second program page identical to the first program page in the page isolation business system; Determine the statement to be debugged in the first program page, identify the function structure of the statement to be debugged by the page isolation business system, and replace the statement to be debugged in the first program page with an isolated debugging statement corresponding to the execution of the page isolation business system; A debug output function is configured for the isolated debug statement.

2. The data debugging output method based on page isolation according to claim 1, characterized in that: Determine the first program page, followed by: Acquire a first function structure in the first program page, preprocess the first function structure to obtain a first function feature, and store the first function feature in a first array; Creating a second program page identical to the first program page in the page isolation business system, and then comprising: A second function structure in the second program page is obtained, the second function structure is preprocessed to obtain a second function feature, and the second function feature is stored in a second array.

3. The data debugging output method based on page isolation according to claim 2 is characterized in that: The page isolation service system identifies the function structure of the statement to be debugged, including: According to the first function feature of the statement to be debugged, the corresponding second function feature is searched and identified in the second array as an isolated function feature, and the second function structure of the isolated function feature is obtained.

4. The data debugging output method based on page isolation according to claim 3 is characterized in that: The function characteristics include function data addresses; Replacing the to-be-debugged statement in the first program page with an isolation debugging statement corresponding to executing the page isolation business system includes: Obtaining an array address of a first array in the first program page and a first function data address of a statement to be debugged in the array address; Obtain a second function data address of the function structure of the isolated function feature in the second array, and replace the first function data address in the first array with the second function data address.

5. The data debugging output method based on page isolation according to claim 4 is characterized in that: Configuring a debugging output function for the isolated debugging statement includes: The debugging output and its log device are configured according to the second function data address.

6. A data debugging output system based on page isolation, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the following steps are implemented: Determine a first program page, and create a second program page identical to the first program page in the page isolation business system; Determine the statement to be debugged in the first program page, identify the function structure of the statement to be debugged by the page isolation business system, and replace the statement to be debugged in the first program page with an isolated debugging statement corresponding to the execution of the page isolation business system; A debug output function is configured for the isolated debug statement.

7. A data debugging output system based on page isolation according to claim 6, characterized in that: Determine the first program page, followed by: Acquire a first function structure in the first program page, preprocess the first function structure to obtain a first function feature, and store the first function feature in a first array; Creating a second program page identical to the first program page in the page isolation business system, and then comprising: A second function structure in the second program page is obtained, the second function structure is preprocessed to obtain a second function feature, and the second function feature is stored in a second array.

8. The data debugging output system based on page isolation according to claim 7 is characterized in that: The page isolation service system identifies the function structure of the statement to be debugged, including: According to the first function feature of the statement to be debugged, the corresponding second function feature is searched and identified in the second array as an isolated function feature, and the second function structure of the isolated function feature is obtained.

9. A data debugging output system based on page isolation according to claim 8, characterized in that: The function characteristics include function data addresses; Replacing the to-be-debugged statement in the first program page with an isolation debugging statement corresponding to executing the page isolation business system includes: Obtaining an array address of a first array in the first program page and a first function data address of a statement to be debugged in the array address; Obtain a second function data address of the function structure of the isolated function feature in the second array, and replace the first function data address in the first array with the second function data address.

10. The data debugging output system based on page isolation according to claim 9, characterized in that: Configuring a debugging output function for the isolated debugging statement includes: The debugging output and its log device are configured according to the second function data address.