CN112988353B - Application program running control method and device - Google Patents

Application program running control method and device Download PDF

Info

Publication number
CN112988353B
CN112988353B CN202110272048.8A CN202110272048A CN112988353B CN 112988353 B CN112988353 B CN 112988353B CN 202110272048 A CN202110272048 A CN 202110272048A CN 112988353 B CN112988353 B CN 112988353B
Authority
CN
China
Prior art keywords
application program
access
target
function
instance
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202110272048.8A
Other languages
Chinese (zh)
Other versions
CN112988353A (en
Inventor
彭洪涛
赵晶
喻波
王志海
王志刚
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Wondersoft Technology Co Ltd
Original Assignee
Beijing Wondersoft Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Wondersoft Technology Co Ltd filed Critical Beijing Wondersoft Technology Co Ltd
Priority to CN202110272048.8A priority Critical patent/CN112988353B/en
Publication of CN112988353A publication Critical patent/CN112988353A/en
Application granted granted Critical
Publication of CN112988353B publication Critical patent/CN112988353B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/50Monitoring users, programs or devices to maintain the integrity of platforms, e.g. of processors, firmware or operating systems
    • G06F21/52Monitoring users, programs or devices to maintain the integrity of platforms, e.g. of processors, firmware or operating systems during program execution, e.g. stack integrity ; Preventing unwanted data erasure; Buffer overflow

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Stored Programmes (AREA)

Abstract

The application discloses an application program operation control method and device. The method comprises the following steps: intercepting access operation of an application program to an application program instance in the process of starting the application program of the computer, wherein the application program instance is used for representing the starting state of the application program; redirecting an access address of the access operation to a target address and receiving a target access result returned based on the target address, wherein the target access result is used for indicating that no application program instance exists; and controlling the application program to finish starting based on the target access result. The application solves the problem that a plurality of identical application programs cannot be started and run simultaneously under LINUX system in the related technology.

Description

Application program running control method and device
Technical Field
The application relates to the technical field of application program operation control, in particular to an application program operation control method and device.
Background
In daily work and life, it is a common requirement to realize the separation and multiple opening of application programs. For example, in daily work, a person needs to log in a plurality of chat accounts on a computer, or needs one program to open one document, i.e. a plurality of documents and a plurality of programs. However, most application programs are designed in a single-instance mode, i.e. a current user only allows to log in one account (such as social chat software), or a plurality of files of the same type can be opened only through one process (such as different types of office software), so that the application programs cannot meet the individual and multi-open use requirements of the application programs in the use situation.
In order to solve the problems, some software products appear on the windows platform, so that the function of application program splitting can be realized, and the aim of simultaneous login of a plurality of accounts of certain chat applications and one process of office software is fulfilled. However, on the LINUX platform, because the system architecture and the implementation method of the LINUX system and the windows system are different, the requirements of users for the application program to be used separately and widely are difficult to meet, and the user experience is poor.
Aiming at the problem that a plurality of identical application programs cannot be started and run simultaneously under a LINUX system in the related art, no effective solution is proposed at present.
Disclosure of Invention
The application provides an operation control method and device of an application program, which are used for solving the problem that a plurality of same application programs cannot be started and run simultaneously under a LINUX system in the related art.
According to one aspect of the present application, there is provided a method of controlling operation of an application program. The method comprises the following steps: intercepting access operation of an application program to an application program instance in the process of starting the application program of the computer, wherein the application program instance is used for representing the starting state of the application program; redirecting an access address of the access operation to a target address and receiving a target access result returned based on the target address, wherein the target access result is used for indicating that no application program instance exists; and controlling the application program to finish starting based on the target access result.
Optionally, before intercepting an access operation of the application program to the application program instance in the process of starting the application program of the computer, the method further comprises: starting an operating system of the computer and starting a process corresponding to the application program; and injecting a hook function into the memory space of the started process, wherein the hook function is used for monitoring an interface function called by the application program when the process runs and controlling the execution behavior of the interface function.
Optionally, after intercepting an access operation of the application program to the application program instance during starting of the application program of the computer, the method further includes: judging whether an application program instance exists in an access address of the access operation; in the presence of an application instance, the step of redirecting the access address of the access operation to the target address is performed.
Optionally, in the process of starting the application program of the computer, intercepting the access operation of the application program to the application program instance includes: and intercepting a first dynamic link library called by the application program through the hook function, wherein the first dynamic link library comprises a first access function, and the first access function is used for accessing the application program instance.
Optionally, redirecting the access address of the access operation to the target address and receiving the target access result returned based on the target address includes: the control application program obtains target function parameters of a second access function in the second dynamic link library, wherein the target function parameters comprise access addresses, and the access addresses of the second access function are different from those of the first access function; and receiving an access result of the non-existing application program instance returned by the first access function based on the target function parameter execution access behavior.
Optionally, the address where the application instance is located is one of: the target file address under the installation path of the application program, and the memory address of the target server of the application program is monitored.
Optionally, the operating system of the computer is a LINUX system.
According to another aspect of the present application, there is provided an operation control apparatus of an application program. The device comprises:
And the interception unit is used for intercepting the access operation of the application program to the application program instance in the process of starting the application program of the computer, wherein the existence of the application program instance is used for representing that the application program is started.
And the redirection unit is used for redirecting the access address of the access operation to the target address and receiving a target access result returned based on the target address, wherein the target access result is used for indicating that the application program instance does not exist.
And the control unit is used for controlling the application program to finish starting based on the target access result.
According to another aspect of the embodiment of the present invention, there is also provided a nonvolatile storage medium including a stored program, where the program is run to control a device in which the nonvolatile storage medium is located to execute a running control method of an application program.
According to another aspect of the embodiment of the present invention, there is also provided an electronic device including a processor and a memory; the memory stores computer readable instructions, and the processor is configured to execute the computer readable instructions, where the computer readable instructions execute a method for controlling the operation of an application program.
According to the application, the following steps are adopted: intercepting access operation of an application program to an application program instance in the process of starting the application program of the computer, wherein the application program instance is used for representing the starting state of the application program; redirecting an access address of the access operation to a target address and receiving a target access result returned based on the target address, wherein the target access result is used for indicating that no application program instance exists; the method and the device control the application program to finish starting based on the target access result, and solve the problem that a plurality of same application programs cannot be started and run simultaneously under a LINUX system in the related technology. By intercepting the access operation of the application program to the application program instance and redirecting the access address of the access operation, the effect that a plurality of identical application programs can be started and simultaneously run under the LINUX system is achieved.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this specification, illustrate embodiments of the application and together with the description serve to explain the application. In the drawings:
FIG. 1 is a flow chart of a method of controlling the operation of an application provided in accordance with an embodiment of the present application;
FIG. 2 is a flow chart of another method of controlling the operation of an application provided in accordance with an embodiment of the present application;
FIG. 3 is a flow chart of an alternative method of controlling operation of an application provided in accordance with an embodiment of the present application; and
Fig. 4 is a schematic diagram of an operation control device of an application program according to an embodiment of the present application.
Detailed Description
It should be noted that, without conflict, the embodiments of the present application and features of the embodiments may be combined with each other. The application will be described in detail below with reference to the drawings in connection with embodiments.
In order that those skilled in the art will better understand the present application, a technical solution in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in which it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present application without making any inventive effort, shall fall within the scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and the claims of the present application and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate in order to describe the embodiments of the application herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
For convenience of description, the following will describe some terms or terminology involved in the embodiments of the present application:
Hook technology: the method is also called as a hook function, the hook program captures the message before the system calls the function, the hook function obtains control right first, and at the moment, the hook function can process the execution behavior of the function and can forcedly finish the transfer of the message.
X Window System: x is abbreviated as X, or X11, or X-Windows. The reason for this is called X because X is located after W in the alphabet, and W is the GUI system used by MIT before X. The reason for this is called X11, because X Window System has evolved to version 11 in 1987, and all subsequent X's have evolved based on version X11.
According to an embodiment of the present application, there is provided an operation control method of an application program.
Fig. 1 is a flowchart of an operation control method of an application according to an embodiment of the present application. As shown in fig. 1, the method comprises the steps of:
Step S102, in the process of starting the application program of the computer, intercepting the access operation of the application program to the application program instance, wherein the application program instance is used for representing the starting state of the application program.
Specifically, when the application program is started, an application program instance corresponding to the application program is stored at a preset address, the application program accesses the preset address, when the corresponding application program instance is accessed, the application program is indicated to be started, when the corresponding application program instance is not accessed, the application program is indicated to be not started, and the current starting is the first starting.
Optionally, in the method for controlling operation of an application program provided by the embodiment of the present application, an operating system of a computer is a LINUX system.
Specifically, under the LINUX system, the starting of the application program is controlled through a single-instance implementation mechanism of the application program, that is, when the corresponding application program instance is accessed in the process of the current starting, the starting of the application program is prevented, and when the corresponding application program instance is not accessed, the starting of the application program is allowed.
Optionally, in the method for controlling operation of an application program provided by the embodiment of the present application, an address where an application program instance is located is one of the following: the target file address under the installation path of the application program, and the memory address of the target server of the application program is monitored.
Specifically, under the LINUX system, on the one hand, after the application program is started, the application program instance may be stored in a specific form under a specific path, for example, in a file form under an installation path of the application program, that is, an address where the application program instance is located may be a target file address under the installation path of the application program.
On the other hand, the platform of the LINUX system controls all application programs through a dbus protocol (in a message bus manner), the application programs are supervised by Dbus services, and after the application programs are started, application program instances can exist in a memory of the dbus service of the system, namely, an address where the application program instances are located can be a memory address of the dbus service.
Thus, in the LINUX system, the single instance implementation mechanism of the application program may be implemented by detecting whether a certain file exists in a special path, and in some application programs using Dbus buses, it may also be implemented by detecting whether a specific service name of a service connected by Dbus buses exists.
In the method for controlling the operation of the application program provided by the embodiment of the application, before the access operation of the application program to the application program instance is intercepted in the process of starting the application program of the computer, the method further comprises the following steps: starting an operating system of the computer and starting a process corresponding to the application program; and injecting a hook function into the memory space of the started process, wherein the hook function is used for monitoring an interface function called by the application program when the process runs and controlling the execution behavior of the interface function.
Specifically, after the operating system of the computer is started, and after the user starts the application program, the hook function is injected into the internal space of the started process, so as to monitor and control the interface function called in the process.
For example, in the LINUX system, the loading of the interception module can be completed by using a ld_ preload mechanism under the operating system, i.e. the path of the library file where the processing function of the interface function to be intercepted is located is written into the/etc/so.preload file.
Optionally, in the method for controlling operation of an application program provided by the embodiment of the present application, intercepting an access operation of the application program to an application program instance in a process of starting the application program of a computer includes: and intercepting a first dynamic link library called by the application program through the hook function, wherein the first dynamic link library comprises a first access function, and the first access function is used for accessing the application program instance.
Specifically, in the case that the operating system of the computer is a LINUX system, the interface function corresponding to the access operation is stored in a libc.so library or a libdbus.so library, and an open function in the libc.so library or a dbus_bus_request_name function in the libdbus.so library is intercepted by using an inline hook technology to intercept the access operation of the application program to the application program instance.
Specifically, for an application program which determines whether an instance is running by detecting whether a file exists, the access of the application program to the file under a specific path is intercepted, for the application program which determines whether the instance is running by detecting Dbus service names exists, the access of the application program to the memory of Dbus service is intercepted, so that whether the application program instance is running is checked, if the application program instance is not running, the interception is released, otherwise, the access address of the access operation is redirected, the limitation of the application program single instance is released, the application program can be started again, and the separation of the application program or the application of multiple applications are realized.
Step S104, the access address of the access operation is redirected to the target address, and a target access result returned based on the target address is received, wherein the target access result is used for indicating that no application program instance exists.
Specifically, the file accessed by the application program or Dbus service names are redirected, so that the application program accesses the target address, and an access result without the application program instance is received, thereby bypassing the detection mechanism of the single instance of the application program and realizing the separation or multiple separation of the application program.
In order to avoid unnecessary redirection operations, optionally, in the method for controlling operation of an application program provided in the embodiment of the present application, after intercepting an access operation of an application program to an application program instance in a process of starting the application program of a computer, the method further includes: judging whether an application program instance exists in an access address of the access operation; in the presence of an application instance, the step of redirecting the access address of the access operation to the target address is performed.
That is, when an application program instance exists in the access address of the access operation, the access address redirection operation for the access operation is executed again, and when an application program instance does not exist in the access address of the access operation, the access address redirection operation for the access operation is not executed.
Optionally, in the method for controlling operation of an application program provided by the embodiment of the present application, redirecting an access address of an access operation to a target address and receiving a target access result returned based on the target address includes: the control application program obtains target function parameters of a second access function in the second dynamic link library, wherein the target function parameters comprise access addresses, and the access addresses of the second access function are different from those of the first access function; and receiving an access result of the non-existing application program instance returned by the first access function based on the target function parameter execution access behavior.
It should be noted that when an application program runs, multiple modules are required to be called through an API interface of the application program to load the corresponding functions of the program, the first dynamic link library and the second dynamic link library are corresponding sets formed by 1 module or N modules, each function is running in a certain module, and one module includes multiple API functions, such as an access function, and replacement of the access result can be achieved by adjusting the calling process of the API functions in the dynamic link library.
In an alternative embodiment, the first access function is an Open function, the Open function is in the first link library libc.so library, to change the access address of the Open function, the Open function in the first link library libc.so library is intercepted, for example, the address in the memory space where the Open function in the first link library libc.so is located is set, and when the Open function is called by the application program, the Open function is redirected to the memory space where the second access function corresponding to the libc.so library is located, that is, the call is performed by jumping to the memory space where the second access function is located, so as to achieve the purpose of adjusting the call process of the access function. For example, the original file under the c disc is called instead of the file in the d disc, and the returned access result of the application program instance does not exist because the file in the d disc does not exist, so that the replacement of the returned value of the access function is realized.
And step S106, controlling the application program to finish starting based on the target access result.
Specifically, an access result of the second access function executing access behavior, which is returned by the second access function executing access behavior and is free of the application program instance, is received, and the current starting of the application program is allowed.
According to the running control method of the application program, the access operation of the application program to the application program instance is intercepted in the process of starting the application program of the computer, wherein the application program instance is used for representing the starting state of the application program; redirecting an access address of the access operation to a target address and receiving a target access result returned based on the target address, wherein the target access result is used for indicating that no application program instance exists; the method and the device control the application program to finish starting based on the target access result, and solve the problem that a plurality of same application programs cannot be started and run simultaneously under a LINUX system in the related technology. By intercepting the access operation of the application program to the application program instance and redirecting the access address of the access operation, the effect that a plurality of identical application programs can be started and simultaneously run under the LINUX system is achieved.
Fig. 2 is a schematic diagram of another method of controlling the operation of an application according to an embodiment of the present application. As shown in fig. 2, the method includes:
And after the LINUX system is started, the hook installation module is operated to complete the hook module installation.
When a user starts chat application or office software and a process is started, an interception processing module is loaded to intercept open and dbus_bus_request_name functions.
The state of the program running in the system is checked to see if an instance of the user initiated program already exists.
If the file or Dbus is accessed, the interception module calls a redirection module to redirect the access of the file or Dbus to realize the restarting of the application when the program is started; if not, the interception module releases the file or Dbus access request, and the program started by the user is loaded and operated.
During the running process of the program, whether the system is exited is checked, and if so, the system is exited.
According to the embodiment, an open function in a libc.so library and a dbus_bus_request_name function in the libdbus.so library are intercepted by using an inline hook technology, a single-instance detection mechanism of an application program is broken, the application program is split or the application is more open, and special requirements of users are met.
Fig. 3 is a schematic diagram of an alternative application program operation control method according to an embodiment of the present application. As shown in fig. 3, the method includes:
After entering the LINUX operating system, logging in the account system, and verifying the post-synchronization ciphertext control strategy.
Under the condition that a user double clicks to open the file, checking whether the opened file is ciphertext, if so, starting a new process to open the ciphertext file; if not, the description is plaintext, a plaintext process is started or the file is opened by using the existing plaintext process.
Then, whether the system is exited is checked, and if so, the system is exited.
By the embodiment, the problem that the plaintext process exists when the office software opens the ciphertext file, and the ciphertext content is possibly leaked due to the copying of the plaintext is avoided, and meanwhile, the problem that the plaintext is encrypted when the opened plaintext is edited in the ciphertext process is avoided. In addition, a ciphertext is opened, then the ciphertext is opened, if the security levels are the same, a plurality of programs can be opened, and the programs can be displayed by adopting only one program, wherein the specific strategy is determined by the ciphertext control strategy.
It should be noted that the steps illustrated in the flowcharts of the figures may be performed in a computer system such as a set of computer executable instructions, and that although a logical order is illustrated in the flowcharts, in some cases the steps illustrated or described may be performed in an order other than that illustrated herein.
The embodiment of the application also provides an operation control device of the application program, and the operation control device of the application program can be used for executing the operation control method for the application program. The following describes an operation control device for an application program provided in an embodiment of the present application.
Fig. 4 is a schematic diagram of an operation control apparatus of an application program according to an embodiment of the present application. As shown in fig. 4, the apparatus includes: an interception unit 10, a redirection unit 20 and a control unit 30.
Optionally, the intercepting unit 10 is configured to intercept, during starting of an application program of the computer, an access operation of the application program to an application program instance, where the existence of the application program instance is used to characterize that the application program has been started.
And a redirection unit 20, configured to redirect an access address of the access operation to a target address, and receive a target access result returned based on the target address, where the target access result is used to indicate that the application program instance does not exist.
And a control unit 30 for controlling the application program to finish the startup based on the target access result.
According to the running control device for the application program, provided by the embodiment of the application, the access operation of the application program to the application program instance is intercepted by the interception unit 10 in the process of starting the application program of the computer, wherein the existence of the application program instance is used for representing that the application program is started; the redirection unit 20 redirects the access address of the access operation to a target address and receives a target access result returned based on the target address, wherein the target access result is used for indicating that no application program instance exists; the control unit 30 controls the application program to finish starting based on the target access result, solves the problem that a plurality of identical application programs cannot be started and run simultaneously under the LINUX system in the related art, and achieves the effect that a plurality of identical application programs can be started and run simultaneously under the LINUX system by intercepting the access operation of the application program to the application program instance and redirecting the access address of the access operation.
Optionally, in the running control device for an application program provided by the embodiment of the present application, a starting unit is configured to start an operating system of a computer and start a process corresponding to the application program before intercepting an access operation of the application program to an application program instance in a process of starting the application program of the computer; and the injection unit is used for injecting the hook function into the memory space of the started process, wherein the hook function is used for monitoring the interface function called by the application program when the process runs and controlling the execution behavior of the interface function.
Optionally, in the operation control device for an application program provided in the embodiment of the present application, the device further includes: the judging unit is used for judging whether the application program instance exists in an access address of the access operation after intercepting the access operation of the application program to the application program instance in the process of starting the application program of the computer; and the execution unit is used for executing the step of redirecting the access address of the access operation to the target address in the case of the application program instance.
Optionally, in the operation control device for an application program provided in the embodiment of the present application, the interception unit 10 is configured to intercept, by using a hook function, a first dynamic link library invoked by the application program, where the first dynamic link library includes a first access function, and the first access function is used to access an application program instance.
Optionally, in the operation control device for an application provided in the embodiment of the present application, the redirecting unit 20 includes: the first control module is used for controlling the application program to acquire target function parameters of a second access function in the second dynamic link library, wherein the target function parameters comprise access addresses, and the access addresses of the second access function are different from those of the first access function; and the receiving module is used for receiving an access result of the non-existing application program instance returned by the first access function executing the access behavior based on the target function parameter.
Optionally, in the operation control device for an application provided in the embodiment of the present application, an address where an application instance is located is one of the following: the target file address under the installation path of the application program, and the memory address of the target server of the application program is monitored.
Optionally, in the operation control device for an application program provided by the embodiment of the present application, an operating system of the computer is a LINUX system.
The running control device of the application program comprises a processor and a memory, wherein the interception unit 10, the redirection unit 20, the control unit 30 and the like are all stored in the memory as program units, and the processor executes the program units stored in the memory to realize corresponding functions.
The processor includes a kernel, and the kernel fetches the corresponding program unit from the memory. The kernel can be provided with one or more than one kernel, and the problem that a plurality of identical application programs cannot be started and run simultaneously under the LINUX system is solved by adjusting kernel parameters.
The memory may include volatile memory, random Access Memory (RAM), and/or nonvolatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM), among other forms in computer readable media, the memory including at least one memory chip.
The embodiment of the application also provides a nonvolatile storage medium, which comprises a stored program, wherein the program is used for controlling equipment where the nonvolatile storage medium is located to execute an operation control method of an application program when running.
The embodiment of the application also provides an electronic device, which comprises a processor and a memory; the memory stores computer readable instructions, and the processor is configured to execute the computer readable instructions, where the computer readable instructions execute a method for controlling the operation of an application program. The electronic device herein may be a server, a PC, a PAD, a mobile phone, etc.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In one typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include volatile memory in a computer-readable medium, random Access Memory (RAM) and/or nonvolatile memory, etc., such as Read Only Memory (ROM) or flash RAM. Memory is an example of a computer-readable medium.
Computer readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of storage media for a computer include, but are not limited to, phase change memory (PRAM), static Random Access Memory (SRAM), dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), read Only Memory (ROM), electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium, which can be used to store information that can be accessed by a computing device. Computer-readable media, as defined herein, does not include transitory computer-readable media (transmission media), such as modulated data signals and carrier waves.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises an element.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The foregoing is merely exemplary of the present application and is not intended to limit the present application. Various modifications and variations of the present application will be apparent to those skilled in the art. Any modification, equivalent replacement, improvement, etc. which come within the spirit and principles of the application are to be included in the scope of the claims of the present application.

Claims (7)

1. An operation control method of an application program, comprising:
Intercepting access operation of an application program to an application program instance in the process of starting the application program of a computer, wherein an operating system of the computer is a LINUX system, the application program instance is used for representing the starting state of the application program, the application program is started under the condition that the application program instance is accessed, and the application program is not started under the condition that the application program instance is not accessed, and the current starting is the first starting;
redirecting an access address of the access operation to a target address and receiving a target access result returned based on the target address, wherein the target access result is used for indicating that the application program instance does not exist;
controlling the application program to finish starting based on the target access result, wherein receiving the target access result allows the current starting of the application program;
The intercepting the access operation of the application program to the application program instance in the process of starting the application program of the computer comprises the following steps: intercepting a first dynamic link library called by the application program through a hook function, wherein the first dynamic link library comprises a first access function, and the first access function is used for accessing the application program instance;
the redirecting the access address of the access operation to the target address and receiving the target access result returned based on the target address includes: controlling the application program to acquire target function parameters of a second access function in a second dynamic link library, wherein the target function parameters comprise access addresses, and the access addresses of the second access function are different from those of the first access function; and receiving an access result which is returned by the first access function and does not exist in the application program instance based on the target function parameter execution access behavior.
2. The method of claim 1, wherein the intercepting the access operation of the application program to the application program instance during the starting of the application program of the computer further comprises:
starting an operating system of the computer and starting a process corresponding to the application program;
And injecting a hook function into the memory space of the started process, wherein the hook function is used for monitoring an interface function called by the application program when the process runs and controlling the execution behavior of the interface function.
3. The method of claim 1, wherein after intercepting an access operation of the application program to an application program instance during a process of starting the application program of the computer, the method further comprises:
judging whether the application program instance exists in the access address of the access operation;
In the presence of the application instance, the step of redirecting the access address of the access operation to a target address is performed.
4. The method of claim 1, wherein the application instance is located at an address that is one of: and the target file address under the installation path of the application program monitors the memory address of the target server of the application program.
5. An operation control device for an application program, comprising:
The system comprises an interception unit, a storage unit and a control unit, wherein the interception unit is used for intercepting access operation of an application program to an application program instance in the process of starting the application program of a computer, the operating system of the computer is a LINUX system, the existence of the application program instance is used for representing that the application program is started, the application program is started under the condition that the application program instance is accessed, the application program is not started under the condition that the application program instance is not accessed, and the current starting is the first starting;
A redirection unit, configured to redirect an access address of the access operation to a target address, and receive a target access result returned based on the target address, where the target access result is used to indicate that the application program instance does not exist;
the control unit is used for controlling the application program to finish starting based on the target access result, wherein the current starting of the application program is allowed by the target access result;
The interception unit is used for intercepting a first dynamic link library called by the application program through a hook function, wherein the first dynamic link library comprises a first access function, and the first access function is used for accessing the application program instance;
The redirection unit comprises: the first control module is used for controlling the application program to acquire target function parameters of a second access function in a second dynamic link library, wherein the target function parameters comprise access addresses, and the access addresses of the second access function are different from those of the first access function; and the receiving module is used for receiving an access result which is returned by the first access function and does not exist the application program instance based on the target function parameter execution access behavior.
6. A nonvolatile storage medium, characterized in that the nonvolatile storage medium includes a stored program, wherein the program, when executed, controls a device in which the nonvolatile storage medium is located to execute the operation control method of the application program according to any one of claims 1 to 4.
7. An electronic device comprising a processor and a memory, the memory having stored therein computer readable instructions for executing the computer readable instructions, wherein the computer readable instructions when executed perform the method of controlling the operation of an application program according to any one of claims 1 to 4.
CN202110272048.8A 2021-03-12 2021-03-12 Application program running control method and device Active CN112988353B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110272048.8A CN112988353B (en) 2021-03-12 2021-03-12 Application program running control method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110272048.8A CN112988353B (en) 2021-03-12 2021-03-12 Application program running control method and device

Publications (2)

Publication Number Publication Date
CN112988353A CN112988353A (en) 2021-06-18
CN112988353B true CN112988353B (en) 2024-06-14

Family

ID=76335385

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110272048.8A Active CN112988353B (en) 2021-03-12 2021-03-12 Application program running control method and device

Country Status (1)

Country Link
CN (1) CN112988353B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114070820B (en) * 2021-11-11 2023-09-01 南京指掌易信息科技有限公司 Domain name redirection method, device, medium and electronic equipment

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104375857A (en) * 2014-10-22 2015-02-25 腾讯科技(深圳)有限公司 Method and device for enabling application program to operate multiple instances and terminal equipment

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070261044A1 (en) * 2006-05-04 2007-11-08 Jonathan Clark Chained Hook Function Serving Multiple Versions Of Identically Named Dynamically Loaded Libraries
US8255931B2 (en) * 2008-02-11 2012-08-28 Blue Coat Systems, Inc. Method for implementing ejection-safe API interception
US8769156B2 (en) * 2009-12-23 2014-07-01 Citrix Systems, Inc. Systems and methods for maintaining transparent end to end cache redirection
US9183111B2 (en) * 2011-05-10 2015-11-10 Microsoft Technology Licensing, Llc Methods and computer program products for collecting storage resource performance data using file system hooks
CN104199734B (en) * 2014-09-12 2017-11-14 上海斐讯数据通信技术有限公司 A kind of more open pipe reason method and systems of application program based on Android intelligent terminal
CN109491725B (en) * 2018-11-12 2022-12-27 火烈鸟网络(广州)股份有限公司 Interactive multi-opening method and system of application program, storage medium and electronic equipment
CN109614165B (en) * 2018-12-04 2020-05-05 山东财经大学 Multi-version parallel operation method and device for COM (component object model) component
CN111324386B (en) * 2018-12-13 2024-08-20 北京奇虎科技有限公司 Method and device for starting split application program, electronic equipment and storage medium
CN110888724B (en) * 2019-11-20 2023-05-02 北京明略软件系统有限公司 Split setting method and device, electronic equipment and readable storage medium

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104375857A (en) * 2014-10-22 2015-02-25 腾讯科技(深圳)有限公司 Method and device for enabling application program to operate multiple instances and terminal equipment

Also Published As

Publication number Publication date
CN112988353A (en) 2021-06-18

Similar Documents

Publication Publication Date Title
US10681050B2 (en) Ephemeral applications
CN107832100B (en) APK plug-in loading method and terminal thereof
US20230110179A1 (en) System Function Invoking Method and Apparatus, and Terminal
CN109491725B (en) Interactive multi-opening method and system of application program, storage medium and electronic equipment
CN107104923B (en) Account binding and service processing method and device
EP3089068A1 (en) Application program management method, device, terminal, and computer storage medium
CN112651040A (en) Permission application method, component, device and computer readable storage medium
CN112988353B (en) Application program running control method and device
US10599409B2 (en) Application lifecycle operation queueing
CN113938527A (en) Extension processing method of API gateway, computing equipment and storage medium
CN117093977A (en) User authentication method, system, device, storage medium and electronic equipment
CN108470125B (en) OLE redirection method and system based on virtual desktop
US10776133B2 (en) Preemptive loading of code dependencies for improved performance
CN116450373A (en) Code running method, device, equipment and computer readable storage medium
US10496598B2 (en) Data access control based on storage validation
CN111459687B (en) Method and system for monitoring file transfer from host machine to virtual machine
CN111475763B (en) Webpage running method and device, storage medium and equipment
CN114070820A (en) Domain name redirection method, device, medium and electronic equipment
CN112632534A (en) Malicious behavior detection method and device
CN113596600A (en) Security management method, device, equipment and storage medium for live broadcast embedded program
CN111008375B (en) Data protection method and device
CN116204398B (en) Page caching method, processing device and computer readable storage medium
EP4184326A1 (en) Local service provision method and apparatus, device, and storage medium
CN117762430B (en) Processing method and device based on application program, computer equipment and storage medium
CN115795570B (en) Method for configuring security lock of PC end service system window

Legal Events

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