Application program running method based on virtual machine and terminal

By creating dependency files and environments in the virtual machine and using the environment-dependent interface to enable applications to run independently in the virtual machine, the problem of insufficient security protection of dependency environment and interfaces in the existing technology is solved, and the independent application environment is realized. Security.

CN119473490APending Publication Date: 2025-02-18FUJIAN TQ ONLINE INTERACTIVE INC
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411345976.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-26
Publication Date
2025-02-18

AI Technical Summary

Technical Problem

The prior art has shortcomings in providing security protection between dependent environments and interfaces, and it is difficult to achieve independent and secure application operation environment.

Method used

By creating dependency files and dependency environments in the virtual machine, using the environment dependency interface enables applications to run in the virtual machine without installing environment packages locally, realizing the operation environment and providing protection for the environment dependency interface by monitoring data calls .

Benefits of technology

It enables the application to run in a complete and secure environment without the need to install the environment package locally, ensuring the integrity and consistency of the result data, and enhancing the security and stability of the application operation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119473490A_ABST
    Figure CN119473490A_ABST
Patent Text Reader

Abstract

The invention discloses an application program running method and terminal based on a virtual machine, and the method comprises the steps: monitoring and responding to an application program calling event, and obtaining a dependency library type of an application program; generating a corresponding dependent file or dependent environment according to the dependent library type, so that the application program accesses the generated dependent file or dependent environment to run through an environment dependent interface; according to a configuration rule, processing operation result data of the application program, and returning the processed result data to the application program. According to the method, the dependency file and the dependency environment are created in the virtual machine, so that the application program is called through the environment dependency interface, an environment package does not need to be installed locally, the independence of the application program running environment is achieved, the data calling condition is monitored, and protection is provided for the environment dependency interface.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of virtual machines, and in particular to a method and terminal for running an application based on a virtual machine. Background Art

[0002] At present, the operation of applications depends on specific files and configuration environments. The application calls are satisfied by configuring the environment package locally. These dependent files usually include "dynamic link libraries (DLL)", "data files (DAT)" and "object linking and embedding controls (OCX)", collectively referred to as box files, and the environment they require is called "box system". Although existing technologies such as Sandboxie run programs by creating an isolated environment to protect users' computers from potential dangers, they are still insufficient in providing security protection between dependent environments and interfaces. Therefore, there is an urgent need for a virtual machine-based application operation method and terminal that can solve the above problems. Summary of the invention

[0003] The technical problem to be solved by the present invention is: to provide an application running method and terminal based on a virtual machine, by creating dependent files and a dependent environment in the virtual machine, so that the application can be called through the environment dependent interface without installing the environment package locally, thereby realizing the independence of the application running environment, and monitoring the data calling status to provide protection for the environment dependent interface.

[0004] In order to solve the above technical problems, the technical solution adopted by the present invention is:

[0005] A method for running an application based on a virtual machine, comprising the steps of:

[0006] S1. Listen to and respond to application call events to obtain the dependent library type of the application;

[0007] S2. Generate a corresponding dependency file or dependency environment according to the dependency library type, so that the application accesses the generated dependency file or dependency environment through the environment dependency interface to run;

[0008] S3. Process the result data of the application program running according to the configuration rules, and return the processed result data to the application program.

[0009] In order to solve the above technical problems, another technical solution adopted by the present invention is:

[0010] A virtual machine-based application running terminal comprises a memory, a processor and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, each step of the above-mentioned virtual machine-based application running method is implemented.

[0011] The beneficial effects of the present invention are as follows: a method and terminal for running an application based on a virtual machine provided by the present invention accurately identify the type of dependency library required by the application by monitoring and responding to the calling events of the application, ensure that subsequent dependency files or configuration environments are accurately generated, and generate corresponding dependency files or dependency environments according to the dependency library types, access the generated dependency resources through the environment dependency interface, ensure that the application can run in a complete and secure environment, and do not need to install the environment package locally, thereby realizing the independence of the running environment; process the result data of the application running according to the configuration rules, and copy or map the processed result data back to the application, thereby ensuring the integrity and consistency of the result data, while avoiding the impact on the configuration environment, and enhancing the security and stability of the application running. BRIEF DESCRIPTION OF THE DRAWINGS

[0012] Figure 1 A flowchart of a method for running an application based on a virtual machine according to an embodiment of the present invention;

[0013] Figure 2 A schematic diagram of an application running terminal based on a virtual machine according to an embodiment of the present invention;

[0014] Figure 3 This is an overall flow chart of a method for running an application based on a virtual machine according to an embodiment of the present invention;

[0015] Figure 4 An internal flow chart of a method for running an application based on a virtual machine according to an embodiment of the present invention;

[0016] Description of labels:

[0017] 1. A terminal for running an application based on a virtual machine; 2. A memory; 3. A processor. DETAILED DESCRIPTION

[0018] In order to explain the technical content, achieved objectives and effects of the present invention in detail, the following is an explanation in combination with the implementation modes and the accompanying drawings.

[0019] Please refer to Figure 1 The embodiment of the present invention provides a method for running an application based on a virtual machine, comprising the steps of:

[0020] S1. Listen to and respond to application call events to obtain the dependent library type of the application;

[0021] S2. Generate a corresponding dependency file or dependency environment according to the dependency library type, so that the application accesses the generated dependency file or dependency environment through the environment dependency interface to run;

[0022] S3. Process the result data of the application program running according to the configuration rules, and return the processed result data to the application program.

[0023] From the above description, it can be seen that the beneficial effects of the present invention are: by listening to and responding to the call events of the application, the type of dependent library required by the application is accurately identified, ensuring that subsequent dependent files or configuration environments are accurately generated, and generating corresponding dependent files or dependent environments according to the dependent library type, accessing the generated dependent resources through the environment dependency interface, ensuring that the application can run in a complete and secure environment, without the need to install the environment package locally, and realizing the independence of the operating environment; processing the result data of the application running according to the configuration rules, and copying or mapping the processed result data back to the application, ensuring the integrity and consistency of the result data, while avoiding affecting the configuration environment, and enhancing the security and stability of the application running.

[0024] Furthermore, generating a corresponding dependency file or dependency environment according to the dependency library type includes:

[0025] An environment structure and an environment directory are created, wherein the environment structure is a dependent library required to be loaded by the application, and the environment directory is data created when the dependent library is called.

[0026] From the above description, it can be seen that by creating an environment structure and an environment directory, the dependent files that the application needs to call are clearly displayed, and the data during the call process is recorded, so that the virtual machine environment can be correctly built to meet the application requirements, improve development efficiency, and promote the orderliness of application management.

[0027] Further, processing the result data of the application program running according to the configuration rules and returning the processed result data to the application program includes:

[0028] If the configuration rule corresponding to the application is to copy the application, then the result data of the running of the copied application is obtained, and the result data is returned to the application;

[0029] If the configuration rule corresponding to the application is a mapping application, the result data of the running of the mapped application is obtained and the result data is returned to the application.

[0030] From the above description, it can be seen that the copy return method is adopted to prevent the result data from being modified externally and maintain the independence of the data. The mapping return method is adopted to reduce memory usage and optimize the application running performance. By setting two different data return methods, the processed result data is processed accordingly according to the application requirements to realize the privatization of the application environment.

[0031] Furthermore, the step S2 further includes:

[0032] The generation process of the dependency file or the dependency environment is monitored, an environment dependency interface is obtained according to the generated dependency file or the dependency environment, and the application is linked to the environment dependency interface.

[0033] From the above description, it can be seen that the monitoring system takes over the environment dependency interface and connects the application to the environment dependency interface. The application accesses the target dependency file or target dependency environment through the environment dependency interface, isolates the direct interaction between the application and the dependency file or dependency environment, avoids the impact of environmental changes on the application, ensures the stable operation of the application, and at the same time can monitor the application access status and provide protection for the link between the application and the environment dependency interface.

[0034] Furthermore, the configuration rule is determined according to the application operation type.

[0035] From the above description, it can be seen that by associating configuration rules with operation types, the corresponding configuration rules can be quickly matched according to the operation type, the data processing process can be simplified, resource utilization can be optimized, and it can be ensured that each operation has corresponding configuration rule support, thereby improving the accuracy of data processing.

[0036] Please refer to Figure 2 Another embodiment of the present invention provides an application running terminal based on a virtual machine, including a memory, a processor, and a computer program stored in the memory and executable on the processor, and when the processor executes the computer program, each step of the above-mentioned application running based on a virtual machine is implemented.

[0037] The above-mentioned virtual machine-based application running method and terminal of the present invention are suitable for creating dependent files or dependent environments of virtual machines to realize the independence of application environment, which is described below through specific implementation methods:

[0038] Embodiment 1

[0039] Please refer to Figure 1 and Figure 3 , a method for running an application based on a virtual machine, comprising the steps of:

[0040] S1. Listen to and respond to application call events, and obtain the dependent library type of the application.

[0041] In this embodiment, by monitoring and responding to the calling events of the application, the calling events specifically include: the next step of the application's running process requires opening a file, the application needs to call a dependent file to run, and the type of dependent library required by the application is accurately identified. The dependent library type is the environment attribute, ensuring that subsequent dependent files or configuration environments are accurately generated.

[0042] S2. Generate a corresponding dependency file or dependency environment according to the dependency library type, so that the application accesses the generated dependency file or dependency environment through an environment dependency interface to run.

[0043] Please refer to Figure 4 , Figure 4 The present invention is an internal flow chart of an application running method based on a virtual machine according to an embodiment of the present invention. In this embodiment, a corresponding dependent file or dependent environment is generated according to the dependent library type, and the application accesses the dependent resources generated in the virtual machine through the environment dependency interface, that is, the application runs in the virtual machine, and the virtual machine provides an environment for the application to use, ensuring that the application can run in a complete and safe environment, without the need to install an environment package locally, and realizing the independence of the running environment. For example, when the dependent library type is DLL, the import and export table information is obtained, wherein the import table is used to obtain the relevant DLL, and the export table is used to obtain the relevant interface, the dependent file is configured with the virtual machine, the above structure is copied to the virtual machine, and the corresponding import table information and export function directory are generated, so that the application obtains the same system environment as the original system or an environment that meets the operating conditions of the dependent file, and continues to create relevant dependency attributes, that is, the dependent library associated with the dependent library, for example, calling 1.dll, its related is 2.dll, and 2.dll is composed of 3.dll and 4.dat, at this time, 3.dll and 4.dat need to be created, and the monitoring system monitors the data information generated when the application accesses according to the environment dependency interface. In addition, for other files of the application, a copy is made as a backup so that the running result of the application only affects the data in the virtual machine and avoids affecting the actual files.

[0044] Furthermore, in this embodiment, the corresponding dependent file or dependent environment is generated according to the dependent library type, including: creating an environment structure and creating an environment directory, the environment structure is the dependent library required to be loaded by the application, and the environment directory is the data created when the dependent library is called. For example, the dependent file of file 1.exe is 1.dll, and 1.dll calls the dependent file 2.dll and the dependent file 3.dll, then the dependent library required by 1.dll is called the environment structure; the data created when file 1.exe or dependent file 1.dll calls the dependent library is called the environment directory, specifically: dependent file 1.dll calls 2.dll, 2.dll will create directory "2" during use, and reading dependent file 2.dll also requires creating directory "2".

[0045] Furthermore, in this embodiment, the step S2 also includes: monitoring the generation process of the dependent file or dependent environment, obtaining the environment dependent interface according to the generated dependent file or dependent environment, linking the application with the environment dependent interface, taking over the environment dependent interface through the monitoring system, linking the application with the environment dependent interface, the application accesses the target dependent file or target dependent environment through the environment dependent interface, isolating the direct interaction between the application and the dependent file or dependent environment, avoiding the impact of environmental changes on the application, ensuring the stable operation of the application, and at the same time being able to monitor the application access status to provide protection for the link between the application and the environment dependent interface.

[0046] S3. Process the result data of the application program running according to the configuration rules, and return the processed result data to the application program.

[0047] In this embodiment, the result data of the application running is processed according to the configuration rules, and the processed result data is copied or mapped back to the application, ensuring the integrity and consistency of the result data while avoiding affecting the configuration environment, thereby enhancing the security and stability of the application running.

[0048] Furthermore, in this embodiment, the configuration rules are determined according to the application operation type, and the application operation type includes access, read, and delete. By associating the configuration rules with the operation type, the corresponding configuration rules are quickly matched according to the operation type, which simplifies the data processing process, optimizes resource utilization, and ensures that each operation has corresponding configuration rule support, thereby improving the accuracy of data processing.

[0049] Furthermore, in the present embodiment, the processing of the result data of the application running according to the configuration rules and returning the processed result data to the application includes: if the configuration rule corresponding to the application is to copy the application, then the result data of the copied application running is obtained and the result data is returned to the application; if the configuration rule corresponding to the application is to map the application, then the result data of the mapped application running is obtained and the result data is returned to the application. By setting two different data return methods, the processed result data is processed accordingly according to the application requirements, thereby realizing the privatization of the application environment.

[0050] Embodiment 2

[0051] Please refer to Figure 2 , an application running terminal 1 based on a virtual machine, including a memory 2, a processor 3, and a computer program stored in the memory 2 and executable on the processor 3. When the processor 3 executes the computer program, each step of a method for running an application based on a virtual machine in embodiment 1 is implemented.

[0052] In summary, the present invention provides an application running method and terminal based on a virtual machine, which utilizes a monitoring system to listen to and respond to application call events, obtains the application's dependency library type, and ensures that subsequent dependency files or configuration environments are accurately generated; generates corresponding dependency files or dependency environments according to the dependency library type, including creating an environment structure and creating an environment directory, and monitors the generation process through a monitoring system, obtains an environment dependency interface according to the generated dependency files or dependency environments, links the application with the environment dependency interface, so as to facilitate monitoring of data generated when the application calls the dependency files, provides protection for the link between the application and the environment dependency interface, and accesses the generated dependency resources through the environment dependency interface, ensuring that the application can run in a complete and secure environment without the need to install an environment package locally, thereby achieving independence of the running environment, and also utilizing The environment dependency interface isolates the direct interaction between the application and the dependent files or dependent environment, avoids the impact of environmental changes on the application, and ensures the stable operation of the application; the configuration rules are determined according to the application operation type, and the result data of the application operation is processed according to the configuration rules, and the processed result data is copied or mapped back to the application, and two different data return methods are set. The processed result data is processed accordingly according to the application requirements to realize the privatization of the application environment, and the corresponding configuration rules are quickly matched according to the operation type, which simplifies the data processing process, optimizes resource utilization, ensures that each operation has corresponding configuration rule support, improves the accuracy of data processing, ensures the integrity and consistency of the result data, and avoids affecting the configuration environment, enhancing the security and stability of the application operation.

[0053] The above descriptions are merely embodiments of the present invention and are not intended to limit the patent scope of the present invention. Any equivalent transformations made using the contents of the present invention's specification and drawings, or directly or indirectly applied in related technical fields, are also included in the patent protection scope of the present invention.

Claims

1. A method for running an application based on a virtual machine, characterized in that: Includes steps: S1. Listen to and respond to application call events to obtain the dependent library type of the application; S2. Generate a corresponding dependency file or dependency environment according to the dependency library type, so that the application accesses the generated dependency file or dependency environment through the environment dependency interface to run; S3. Process the result data of the application program running according to the configuration rules, and return the processed result data to the application program.

2. The method for running an application based on a virtual machine according to claim 1, characterized in that: The generating a corresponding dependency file or dependency environment according to the dependency library type includes: An environment structure and an environment directory are created, wherein the environment structure is a dependent library required to be loaded by the application, and the environment directory is data created when the dependent library is called.

3. The method for running an application based on a virtual machine according to claim 1, characterized in that: The processing of the result data of the application program according to the configuration rules and returning the processed result data to the application program comprises: If the configuration rule corresponding to the application is to copy the application, then the result data of the running of the copied application is obtained, and the result data is returned to the application; If the configuration rule corresponding to the application is a mapping application, the result data of the running of the mapped application is obtained and the result data is returned to the application.

4. The method for running an application based on a virtual machine according to claim 1, characterized in that: The step S2 further comprises: The generation process of the dependency file or the dependency environment is monitored, an environment dependency interface is obtained according to the generated dependency file or the dependency environment, and the application is linked to the environment dependency interface.

5. The method for running an application based on a virtual machine according to claim 1, characterized in that: The configuration rule is determined according to the application operation type.

6. An application program running terminal based on a virtual machine, 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: S1. Listen to and respond to application call events to obtain the dependent library type of the application; S2. Generate a corresponding dependency file or dependency environment according to the dependency library type, so that the application accesses the generated dependency file or dependency environment through the environment dependency interface to run; S3. Process the result data of the application program running according to the configuration rules, and return the processed result data to the application program.

7. The application program running terminal based on a virtual machine according to claim 6, characterized in that: The generating a corresponding dependency file or dependency environment according to the dependency library type includes: An environment structure and an environment directory are created, wherein the environment structure is a dependent library required to be loaded by the application, and the environment directory is data created when the dependent library is called.

8. The application program running terminal based on a virtual machine according to claim 6, characterized in that: The processing of the result data of the application program according to the configuration rules and returning the processed result data to the application program comprises: If the configuration rule corresponding to the application is to copy the application, then the result data of the running of the copied application is obtained, and the result data is returned to the application; If the configuration rule corresponding to the application is a mapping application, the result data of the running of the mapped application is obtained and the result data is returned to the application.

9. The application program running terminal based on a virtual machine according to claim 6, characterized in that: The step S2 further comprises: The generation process of the dependency file or the dependency environment is monitored, an environment dependency interface is obtained according to the generated dependency file or the dependency environment, and the application is linked to the environment dependency interface.

10. The application program running terminal based on a virtual machine according to claim 6, characterized in that: The configuration rule is determined according to the application operation type.