CN114675840A - Method and electronic equipment for generating installation package of application program - Google Patents
Method and electronic equipment for generating installation package of application program Download PDFInfo
- Publication number
- CN114675840A CN114675840A CN202011557385.3A CN202011557385A CN114675840A CN 114675840 A CN114675840 A CN 114675840A CN 202011557385 A CN202011557385 A CN 202011557385A CN 114675840 A CN114675840 A CN 114675840A
- Authority
- CN
- China
- Prior art keywords
- file
- app
- smali
- installation package
- authentication
- 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.)
- Pending
Links
- 238000009434 installation Methods 0.000 title claims abstract description 91
- 238000000034 method Methods 0.000 title claims abstract description 66
- 238000012545 processing Methods 0.000 claims abstract description 37
- 230000003068 static effect Effects 0.000 claims description 49
- 230000015654 memory Effects 0.000 claims description 30
- 238000004590 computer program Methods 0.000 claims description 7
- 238000012827 research and development Methods 0.000 abstract description 6
- 239000002699 waste material Substances 0.000 abstract description 4
- 230000006870 function Effects 0.000 description 13
- 238000004891 communication Methods 0.000 description 8
- 238000010586 diagram Methods 0.000 description 4
- 239000000243 solution Substances 0.000 description 4
- 230000001360 synchronised effect Effects 0.000 description 4
- 230000008878 coupling Effects 0.000 description 3
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 230000009286 beneficial effect Effects 0.000 description 2
- 230000010354 integration Effects 0.000 description 2
- 238000003491 array Methods 0.000 description 1
- 230000005540 biological transmission Effects 0.000 description 1
- 230000006835 compression Effects 0.000 description 1
- 238000007906 compression Methods 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 238000002347 injection Methods 0.000 description 1
- 239000007924 injection Substances 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000000717 retained effect Effects 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/40—Transformation of program code
- G06F8/53—Decompilation; Disassembly
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/70—Software maintenance or management
- G06F8/73—Program documentation
Landscapes
- Engineering & Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Software Systems (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Library & Information Science (AREA)
- Stored Programmes (AREA)
Abstract
The application provides a method and electronic equipment for generating an installation package of an APP (application), the installation package of the APP submitted by a developer is subjected to decompiling processing by a service end of a developer portal, authentication SDK (software development kit) is injected into an intermediate file obtained after the decompiling processing, the intermediate file is finally compiled, the installation package of the APP integrated with the authentication SDK is obtained, and therefore the energy of the developer of the APP in the aspect of integrating the authentication SDK is saved, and the waste of research and development resources is avoided.
Description
Technical Field
The present application relates to the field of terminals, and more particularly, to a method and an electronic device for generating an installation package of an application in the field of terminals.
Background
Currently, most electronic devices support Applications (APPs) installed thereon, and for example, users can download various APPs through the APP of the APP market.
Some of the APPs issued by the APP in the APP market may be downloaded for free to the user, and some may be downloaded after paying a fee, or the APP in the APP market may provide a VIP (VIP) function, for example, the APP in the APP market may authorize some APPs to be used as an APP combination package to a VIP user, in other words, if the user is a VIP user of the APP in the APP combination package, the APPs in the APP combination package may be downloaded for free.
For APPs that need to be downloaded with a fee or can be downloaded by a VIP user, the APP needs to have an authentication capability so as to determine whether the user has paid or belongs to the VIP user when the user uses the APP, for example, such APP developers may integrate an authentication Software Development Kit (SDK) into an installation package of the APP, provide the APP integrated with the authentication SDK to an APP of an APP market, and publish the APP by the APP market APP, after the user downloads such APP on an electronic device, if the APP is started, the APP may initiate an authentication process to determine whether the user has paid or belongs to the VIP user, and in the case that the authentication is passed, the user may use such APP.
However, as these kinds of APPs increase, the energy of the APP developer in integrating the authentication SDK will inevitably increase, and further, the research and development resources will be wasted.
Disclosure of Invention
The embodiment of the application provides a method for generating an installation package of an application program, which can save the energy of an APP developer in the aspect of integrating authentication SDKs and avoid the waste of research and development resources.
In a first aspect, a method for generating an installation package of an application program is provided, including: the method comprises the steps that a server side of a developer portal obtains a first installation package and an authentication Software Development Kit (SDK) of an application program (APP), then the first installation package is subjected to decompiling processing to obtain a first file set, the authentication SDK is injected into the first file set to obtain a second file set, and finally the second installation package of the APP is generated according to the second file set.
Based on above-mentioned technical scheme, the installation package of the APP that the developer submitted is carried out decompilation by the service end of developer portal, and the first file that obtains after will authenticating SDK injection decompilation handles is concentrated, obtains the second file set, compiles the second file set finally, obtains the installation package of the APP that integrates and have authenticating SDK to save the developer of APP in the aspect of the energy of integrating authenticating SDK input, avoid the waste of research and development resource.
With reference to the first aspect, in some implementation manners of the first aspect, the first file set includes a first configuration file of an APP, and the injecting the authentication SDK into the first file set to obtain a second file set includes: and declaring a starting page of the authentication SDK in the first configuration file to obtain a second configuration file, wherein the second file set comprises the second configuration file.
Based on the technical scheme, the starting page of the authentication SDK is declared in the configuration file of the APP, so that the APP can call the starting page of the authentication SDK to execute the authentication process after being started.
With reference to the first aspect and the foregoing implementation manners of the first aspect, in some implementation manners of the first aspect, the declaring, in the first configuration file, a start page of the authentication SDK includes: and declaring the starting page of the authentication SDK as the starting page of the APP in the first configuration file.
Based on the technical scheme, the starting page of the authentication SDK is declared as the starting page of the APP in the configuration file of the APP, so that the APP executes the authentication process firstly after starting, and the influence on the self function of the APP is avoided.
With reference to the first aspect and the foregoing implementation manners of the first aspect, in some implementation manners of the first aspect, the injecting the authentication SDK into the first set of files includes: performing decompiling processing on the authentication SDK to obtain a static resource file of the authentication SDK; and merging the first static resource file and the static resource file of the authentication SDK to obtain a second static resource file, wherein the second file set comprises the second static resource file.
With reference to the first aspect and the foregoing implementations of the first aspect, in certain implementations of the first aspect, the method further includes: creating a loading module, wherein the loading module is used for loading the static resource file of the authentication SDK; the step of injecting the authentication SDK into the first file set to obtain a second file set includes: and injecting the authentication SDK and the loading module into the first file set to obtain the second file set.
Based on the technical scheme, the loading module is created and injected into the first file set, so that the static resource files in the authentication SDK can be loaded through the loading module when the APP executes the authentication process.
With reference to the first aspect and the foregoing implementations of the first aspect, in certain implementations of the first aspect, the method further includes: processing the loading module to obtain a smali file of the loading module; the first file set comprises a first smali file, and the step of injecting the authentication SDK and the loading module into the first file set to obtain a second file set comprises the following steps: and merging the first smali file and the smali file of the loading module to obtain a second smali file, wherein the second file set comprises the second smali file.
The load module is processed to obtain the smali file of the load module, so that the smali file of the load module can be merged with the first smali file to obtain a second smali file in the second file set, and the load module is injected into the first file set.
With reference to the first aspect and the foregoing implementations of the first aspect, in certain implementations of the first aspect, the method further includes: performing decompiling processing on the authentication SDK to obtain a smali file of a starting page of the authentication SDK; the merging the first smali file and the smali file of the loading module to obtain a second smali file comprises the following steps: and combining the smali file of the starting page of the authentication SDK, the first smali file and the smali file of the loading module to obtain the second smali file.
With reference to the first aspect and the foregoing implementations of the first aspect, in certain implementations of the first aspect, the method further includes: decompressing the first installation package to obtain a media resource file of the APP; generating a second installation package of the APP according to the second file set, including: and generating a second installation package of the APP according to the media resource file and the second file set.
Based on the above technical scheme, through the original resource package to APP decompress the processing to obtain APP's media resource file, add APP's media resource file again in order to add APP's media resource file in the installation package of the APP that the integration has authentication SDK, thereby make the integration have in the installation package of authentication SDK APP can contain APP's media resource file, avoid causing the influence to APP's self function.
In a second aspect, the present application provides an apparatus, included in an electronic device, having functionality to implement the above aspects and possible implementations of the above aspects. The functions may be implemented by hardware, or by hardware executing corresponding software. The hardware or software includes one or more modules or units corresponding to the above-described functions.
In a third aspect, the present application provides an electronic device comprising one or more processors and one or more memories. The one or more memories are coupled to the one or more processors for storing computer program code comprising computer instructions that, when executed by the one or more processors, cause the electronic device to perform the method of generating an installation package of an APP in any one of the possible implementations of the above aspects.
In a fourth aspect, the present application provides a computer-readable storage medium including computer instructions, which, when executed on an electronic device, cause the electronic device to perform any one of the above possible video playing methods.
In a fifth aspect, the present application provides a computer program product, which when run on an electronic device, causes the electronic device to execute any one of the above possible methods for generating an installation package of an APP.
Drawings
FIG. 1 is a schematic block diagram of an electronic device provided by an embodiment of the application;
fig. 2 is a schematic diagram of a method for generating an installation package of an APP according to an embodiment of the present application;
Fig. 3 is a schematic structural diagram of a file obtained after decompiling an original installation package of an APP according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be described below with reference to the drawings in the embodiments of the present application.
Generally, for other APPs that need to be published on the APP in the application market, an installation package of the APP needs to be submitted to a developer portal, and the developer portal submits the installation package of the APP to a server of the APP in the application market, and finally publishes the APP on the APP in the application market.
For example, the APP of the APP market may authorize some APPs as an APP combination package to the VIP user, or in other words, if the user is a VIP user of the APP market, the APPs in the APP combination package may be downloaded freely.
For APPs that need to be downloaded with a fee or can be downloaded only by a VIP user, the APP needs to have an authentication capability so as to determine whether the user has paid or belongs to the VIP user when the user uses the APP, for example, such APP developers can integrate an authentication SDK into an installation package of the APPs, then provide the installation package of the APPs integrated with the authentication SDK to a developer portal, the developer portal submits the installation package of the APPs integrated with the authentication SDK to a service end of the APP in an application market, and finally issue the APPs integrated with the authentication SDK on the APP in the application market.
However, with the increasing of these kinds of APPs, the energy of the APP developers in integrating the authentication SDK is inevitably increased, and further, the resource of research and development is wasted.
In view of this, the embodiment of the present application provides a method for generating an installation package of an APP, where an authentication SDK is injected into the installation package of the APP submitted by a developer by a service end of a developer portal to obtain the installation package of the APP integrated with the authentication SDK, so that energy input by the developer of the APP in integrating the authentication SDK is saved, and waste of research and development resources is avoided.
Fig. 1 is a schematic structural diagram of an example of an electronic device 100 according to an embodiment of the present disclosure. The electronic device 100 may be a service of a developer portal, and the electronic device 100 may include a processor 101, a memory 102, a communication interface 103, a bus 104, and the like.
The processor 101, the memory 102, and the communication interface 103 communicate with each other via the bus 104, or may communicate with each other by other means such as wireless transmission. The memory 102 is used for storing instructions, and the processor 101 is used for executing the instructions stored in the memory 102. The memory 102 stores program codes 1021, and the processor 101 may call the program codes 1021 stored in the memory 102 to execute the method for generating the installation package of APP shown in fig. 2.
It should be understood that in the embodiment of the present application, the processor 101 may be a CPU, and the processor 101 may also be other general processors, Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, and the like. The general purpose processor may be a microprocessor or any conventional processor or the like.
The memory 102 may include both read-only memory and random access memory and provides instructions and data to the processor 101. The memory 102 may also include non-volatile random access memory. The memory 102 may be either volatile memory or nonvolatile memory, or may include both volatile and nonvolatile memory. The non-volatile memory may be a read-only memory (ROM), a Programmable ROM (PROM), an Erasable PROM (EPROM), an electrically Erasable EPROM (EEPROM), or a flash memory. Volatile memory can be Random Access Memory (RAM), which acts as external cache memory. By way of example, but not limitation, many forms of RAM are available, such as static random access memory (static RAM, SRAM), Dynamic Random Access Memory (DRAM), Synchronous Dynamic Random Access Memory (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), and direct bus RAM (DR RAM).
The bus 104 may include a power bus, a control bus, a status signal bus, and the like, in addition to a data bus. But for clarity of illustration the various busses are labeled in figure 1 as the bus 104.
A method for generating an installation package of an APP according to an embodiment of the present application is described below with reference to fig. 2, where fig. 2 shows a schematic flowchart of a method 200 for generating an installation package of an APP, where the method is executed by a server of a developer portal.
Step 201, the server obtains a first installation package and an authentication SDK of the APP.
Step 202, the server performs decompiling processing on the first installation package to obtain a first file set.
Step 203, the server side injects the authentication SDK into the first file set to obtain a second file set.
And 204, the server generates a second installation package of the APP according to the second file set.
Specifically, after a developer submits an original installation package of an APP to a developer portal, a server of the developer portal can perform decompiling processing on the original installation package to obtain a first file set, the first file set comprises a plurality of intermediate files from the original installation package of the APP to a source code of the APP, the server of the developer portal injects an authentication SDK into the first file set to obtain a second file set, and finally the installation package of the APP integrated with the authentication SDK of the APP is obtained according to the second file set. The original installation package of the APP corresponds to the first installation package, and the installation package integrated with the authentication SDK of the APP corresponds to the second installation package of the APP. Hereinafter, for convenience of description, the service side of the developer portal is simply referred to as a service side.
The following describes in detail a process in which the server side injects the authentication SDK into the first file set to obtain the second file set.
Illustratively, the first file set obtained by the service-side decompiling the first installation package includes a first configuration file of the APP, taking an android architecture as an example, the first configuration file of the APP may be, for example, an android manifest.
In order to call the starting page of the authentication SDK to execute the authentication process after the APP is started, the server may declare the starting page of the authentication SDK in an android manifest.
For example, in order to avoid affecting the self function of the APP, the start page of the authentication SDK may be executed before the start page of the APP, so the server may declare the start page of the authentication SDK as the start page of the APP in an android manifest. In the embodiment of the present application, an android manifest file of an APP declared on a start page of an authentication SDK is referred to as a second configuration file, and the second file set includes the second configuration file.
For example, in order to inject the authentication SDK into the first file set, the server may perform decompiling processing on the authentication SDK to obtain a static resource file of the authentication SDK, and in addition, after performing decompiling processing on the first installation package of the APP, the obtained first file set includes the static resource file of the APP, and the server may add the static resource file of the authentication SDK in a file directory where the static resource file of the APP is located, in other words, the server merges the static resource file of the authentication SDK and the static resource file of the APP to obtain a second static resource file of the second file set. In the embodiment of the application, the static resource file of the APP corresponds to the first static resource file.
In order to enable the APP to load the static resource files of the authentication SDK when the authentication process is executed, the server may create a loading module and inject the loading module into the first file set, where the loading module is used to load the static resource files of the authentication SDK when the APP executes the authentication process, for example, the static resource files of the authentication SDK may include pictures, codes and entries corresponding to the authentication process, and the loading module may load the static resource files when the APP executes the authentication process.
The loading module created by the server may include, for example, a dexsaltloader loader of an android, and when the APP executes the authentication procedure, the dexsaltloader loader may load, for example, a code corresponding to the authentication procedure in the static resource file of the authentication SDK.
For example, in order to inject the loading module into the first file set, the server may process the loading module after creating the loading module to obtain a smali file of the loading module, and in addition, after performing decompilation processing on the first installation package of the APP, the server may add the smali file of the loading module in a file directory where the smali file of the APP is located, in other words, the server merges the smali file of the loading module and the smali file of the APP together to obtain a second smali file of the second file set. In the embodiment of the application, the smali file of the APP corresponds to the first smali file.
Illustratively, after performing decompiling processing on the authentication SDK, the server may also obtain a smali file of a start page of the authentication SDK, and the server may add the smali file of the start page of the authentication SDK and the smali file of the load module to a file directory where the smali file of the APP is located, in other words, the server merges the smali file of the start page of the authentication SDK, the smali file of the load module, and the smali file of the APP to obtain a second smali file in the second file set.
After decompiling the original resource package of the APP, a plurality of intermediate state files are obtained, and since the embodiment of the present application only relates to the first configuration file, the first static resource file, and the first smali file, no other intermediate state files are listed, but it should be understood that these files are only part of the files in the first file set, and the first file set also includes other intermediate state files other than these files, and accordingly, the second configuration file, the second static resource file, and the second smali file are also only part of the files in the second file set, and the second file set also includes other intermediate state files not listed.
After the second file set is obtained, the server side can compile the second file set to obtain a second installation package of the APP.
However, for some APPs that include media resource files in an original installation package, for example, game APPs, the installation package generally includes audio files and video files, and such resource files are not generally stored in a regular path, so after performing decompiling processing on the original installation package of the APP, a server cannot acquire such resource files.
For example, for such resource files, the server may obtain such resource files by decompressing the original installation package of the APP, for example, the server decompresses the original installation package of the APP, obtains such resource files, and copies the resource files into the second installation package of the APP after compression processing.
After obtaining the second installation package of APP, the server can sign the second installation package of APP, and the server can use the signature file provided by the developer portal to sign the second installation package of APP, or the server can also use the signature file provided by the developer of APP to sign the second installation package of APP.
The following describes in detail an installation package method for generating APP provided in the embodiment of the present application, taking a game APP as an example.
Assuming that a developer uploads a file youxi.apk of an original installation package of a game APP to a developer portal, a server of the developer portal firstly uses an apktool to perform decompiling processing on the youxi.apk, and the structure of an obtained intermediate state file is shown in fig. 3, wherein a static resource file of the game APP is stored in a res directory, a smali file of the game APP is stored in a smali directory, and it needs to be noted that only part of the intermediate state file obtained after decompiling processing on the youxi.apk is shown in fig. 3.
The server may modify android manifest.xml of the game APP, for example, the server may declare a start page of the authentication SDK in an android manifest.xml file on the premise that the declaration of the start page of the APP in the android manifest.xml file is retained.
In order to avoid influencing the functions of the APP, the start page of the authentication SDK may be executed before the start page of the APP, so the server may declare the start page of the authentication SDK as the start page of the APP in the android manifest. For example, the name of the start page of the authentication SDK is "com.sdk.game.shell.shell.shellproxactivity", and the server may add the following code to the android manifest.xml file:
and after the code is added into the android manifest.
In order to inject the authentication SDK into the first file set, the server may perform decompilation processing on the authentication SDK, and obtain the static resource file of the authentication SDK after the decompilation processing, and the server may copy the static resource file of the authentication SDK to the res entry in fig. 3, in other words, the server merges the static resource file of the authentication SDK and the static resource file of the game APP.
In order to enable the game APP to load the static resource file of the authentication SDK when the authentication process is executed, the server may create a loading module, and inject the loading module into the intermediate state file shown in fig. 3, where the loading module is used to load the static resource file of the authentication SDK when the game APP executes the authentication process, for example, the static resource file of the authentication SDK may include a picture, a code corresponding to the authentication process, and a vocabulary entry, and the loading module may load the static resource files when the APP executes the authentication process.
The loading module created by the server may include, for example, a dexClassLoader loader of an android, and when the game APP executes the authentication procedure, the dexClassLoader loader may, for example, load a code corresponding to the authentication procedure in the static resource file of the authentication SDK.
In order to inject the loading module into the intermediate state file shown in fig. 3, after the loading module is created, the server may use the apktool to process the loading module to obtain a smali file of the loading module, and copy the smali file of the loading module into the smali directory in fig. 3, in other words, the server merges the smali file of the loading module and the smali file of the game APP.
After the service end performs decompiling processing on the authentication SDK, the service end also obtains a smali file of a starting page of the authentication SDK, and the service end can copy the smali file of the starting page of the authentication SDK and the smali file of the loading module to a smali directory in fig. 3, in other words, the service end merges the smali file of the starting page of the authentication SDK, the smali file of the loading module and the smali file of the game APP.
After the flow is completed, the server side uses the apktool to compile a plurality of intermediate state files of the game APP into which the authentication SDK is injected, and an installation package of the game APP integrated with the authentication SDK is obtained.
For a game APP, a file youxi.apk of an original installation package generally contains an audio file and a video file, and such resource files are generally not stored in a regular path and cannot be obtained by performing decompilation processing on the original installation package, so that the file directory shown in fig. 3 does not contain such resource files.
For the resource files, the server can obtain the resource files by decompressing the files youxi.apk of the original installation package of the game APP, and the resource files are compressed and copied into the installation package of the game APP integrated with the authentication SDK.
After the installation package of the game APP integrated with the authentication SDK is obtained, the server can sign the installation package of the game APP integrated with the authentication SDK, the server can use the signature file provided by the developer portal to sign the installation package of the game APP integrated with the authentication SDK, or the server can also use the signature file provided by the developer portal to sign the installation package of the game APP integrated with the authentication SDK, and the signed installation package of the game APP integrated with the authentication SDK is obtained.
And then the server side can provide the signed installation package of the game APP integrated with the authentication SDK to the server side of the application market APP, and finally the signed game APP integrated with the authentication SDK is released on the application market APP.
In this embodiment, the electronic device may be divided into functional modules according to the above method example, for example, each functional module may be divided corresponding to each function, or two or more functions may be integrated into one processing module. The integrated module may be implemented in the form of hardware. It should be noted that, the division of the modules in this embodiment is schematic, and is only one logic function division, and another division manner may be available in actual implementation.
For example, the method for generating an installation package of an APP provided in this embodiment may be performed by a Business Flow Manager (BFM) module in an electronic device.
It should be noted that all relevant contents of each step related to the method embodiment may be referred to the functional description of the corresponding functional module, and are not described herein again.
The electronic device provided by this embodiment is configured to execute the method for generating the installation package of the APP, so that the same effect as that of the implementation method can be achieved. Where an integrated unit is employed, the electronic device may include a processing module, a memory module, and a communication module. The processing module may be configured to control and manage actions of the electronic device, and for example, may be configured to support the electronic device to execute steps executed by the processing unit. The memory module can be used to support the electronic device for storing program codes and data, etc. The communication module can be used for supporting the communication between the electronic equipment and other equipment.
The processing module may be a processor or a controller. Which may implement or perform the various illustrative logical blocks, modules, and circuits described in connection with the disclosure. A processor may also be a combination of computing functions, e.g., a combination of one or more microprocessors, a Digital Signal Processing (DSP) and a microprocessor, or the like. The storage module may be a memory. The communication module may specifically be a radio frequency circuit, a bluetooth chip, a Wi-Fi chip, or other devices that interact with other electronic devices.
In an embodiment, when the processing module is a processor and the storage module is a memory, the electronic device according to this embodiment may be a device having a structure shown in fig. 1.
The present embodiment also provides a computer-readable storage medium, where a computer instruction is stored in the computer-readable storage medium, and when the computer instruction runs on an electronic device, the electronic device is caused to execute the relevant method steps to implement the method for generating an installation package of an APP in the foregoing embodiments.
The present embodiment also provides a computer program product, which when running on a computer, causes the computer to execute the above related steps to implement the method for generating an installation package of an APP in the above embodiments.
In addition, embodiments of the present application also provide an apparatus, which may be specifically a chip, a component or a module, and may include a processor and a memory connected to each other; the memory is used for storing computer execution instructions, and when the apparatus runs, the processor may execute the computer execution instructions stored in the memory, so as to enable the chip to execute the method for generating the installation package of the APP in the above-mentioned method embodiments.
The electronic device, the computer storage medium, the computer program product, or the chip provided in this embodiment are all configured to execute the corresponding method provided above, so that the beneficial effects achieved by the electronic device, the computer storage medium, the computer program product, or the chip may refer to the beneficial effects in the corresponding method provided above, and are not described herein again.
Through the description of the above embodiments, those skilled in the art will understand that, for convenience and simplicity of description, only the division of the above functional modules is used as an example, and in practical applications, the above function distribution may be completed by different functional modules as needed, that is, the internal structure of the device may be divided into different functional modules to complete all or part of the above described functions.
In the several embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. For example, the above-described embodiments of the apparatus are merely illustrative, and for example, a module or a unit may be divided into only one logic function, and may be implemented in other ways, for example, a plurality of units or components may be combined or integrated into another apparatus, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
Units described as separate parts may or may not be physically separate, and parts displayed as units may be one physical unit or a plurality of physical units, may be located in one place, or may be distributed to a plurality of different places. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit may be implemented in the form of hardware, or may also be implemented in the form of a software functional unit.
The integrated unit, if implemented as a software functional unit and sold or used as a separate product, may be stored in a readable storage medium. Based on such understanding, the technical solutions of the embodiments of the present application may be essentially or partially contributed to by the prior art, or all or part of the technical solutions may be embodied in the form of a software product, where the software product is stored in a storage medium and includes several instructions to enable a device (which may be a single chip, a chip, or the like) or a processor (processor) to execute all or part of the steps of the methods of the embodiments of the present application. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The above description is only for the specific embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present application, and shall be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.
Claims (18)
1. A method of generating an installation package for an application, the method comprising:
acquiring a first installation package and an authentication Software Development Kit (SDK) of an application program (APP);
performing decompiling processing on the first installation package to obtain a first file set;
injecting the authentication SDK into the first file set to obtain a second file set;
and generating a second installation package of the APP according to the second file set.
2. The method of claim 1, wherein the first set of files comprises a first configuration file of an APP, and wherein the injecting the authentication SDK into the first set of files to obtain a second set of files comprises:
and declaring a starting page of the authentication SDK in the first configuration file to obtain a second configuration file, wherein the second file set comprises the second configuration file.
3. The method according to claim 2, wherein said declaring in said first configuration file a start page of said authentication SDK comprises:
and declaring the starting page of the authentication SDK as the starting page of the APP in the first configuration file.
4. The method of any of claims 1 to 3, wherein the first set of files comprises a first static resource file, and wherein the injecting the authentication SDK into the first set of files comprises:
performing decompiling processing on the authentication SDK to obtain a static resource file of the authentication SDK;
and merging the first static resource file and the static resource file of the authentication SDK to obtain a second static resource file, wherein the second file set comprises the second static resource file.
5. The method of claim 4, further comprising:
creating a loading module, wherein the loading module is used for loading the static resource file of the authentication SDK;
the step of injecting the authentication SDK into the first file set to obtain a second file set includes:
and injecting the authentication SDK and the loading module into the first file set to obtain the second file set.
6. The method of claim 5, further comprising:
processing the loading module to obtain a smali file of the loading module;
the first file set comprises a first smali file, and the step of injecting the authentication SDK and the loading module into the first file set to obtain a second file set comprises the following steps:
and merging the first smali file and the smali file of the loading module to obtain a second smali file, wherein the second file set comprises the second smali file.
7. The method of claim 6, further comprising:
performing decompiling processing on the authentication SDK to obtain a smali file of a starting page of the authentication SDK;
the merging the first smali file and the smali file of the loading module to obtain a second smali file comprises the following steps:
and combining the smali file of the starting page of the authentication SDK, the first smali file and the smali file of the loading module to obtain the second smali file.
8. The method according to any one of claims 1 to 7, further comprising:
Decompressing the first installation package to obtain a media resource file of the APP;
generating a second installation package of the APP according to the second file set, including:
and generating a second installation package of the APP according to the media resource file and the second file set.
9. An electronic device, comprising: one or more processors; a memory; and one or more programs, wherein the one or more programs are stored in the memory, which when executed by the processor, cause the electronic device to perform the steps of:
acquiring a first installation package and an authentication Software Development Kit (SDK) of an application program APP;
performing decompiling processing on the first installation package to obtain a first file set;
injecting the authentication SDK into the first file set to obtain a second file set;
and generating a second installation package of the APP according to the second file set.
10. The electronic device of claim 9, wherein the first set of files includes a first configuration file of an APP, and wherein the one or more programs, when executed by the processor, cause the electronic device to perform the steps of:
And declaring a starting page of the authentication SDK in the first configuration file to obtain a second configuration file, wherein the second file set comprises the second configuration file.
11. The electronic device of claim 10, wherein the one or more programs, when executed by the processor, cause the electronic device to perform the steps of:
and declaring the starting page of the authentication SDK as the starting page of the APP in the first configuration file.
12. The electronic device of any of claims 9-11, wherein the first set of files includes a first static resource file, and wherein the one or more programs, when executed by the processor, cause the electronic device to perform the steps of:
performing decompiling processing on the authentication SDK to obtain a static resource file of the authentication SDK;
and combining the first static resource file and the static resource file of the authentication SDK to obtain a second static resource file, wherein the second file set comprises the second static resource file.
13. The electronic device of claim 12, wherein the one or more programs, when executed by the processor, cause the electronic device to perform the steps of:
Creating a loading module, wherein the loading module is used for loading the static resource file of the authentication SDK;
and injecting the authentication SDK and the loading module into the first file set to obtain the second file set.
14. The electronic device of claim 13, wherein the one or more programs, when executed by the processor, cause the electronic device to perform the steps of:
processing the loading module to obtain a smali file of the loading module;
and merging the first smali file and the smali file of the loading module to obtain a second smali file, wherein the second file set comprises the second smali file.
15. The electronic device of claim 14, wherein the one or more programs, when executed by the processor, cause the electronic device to perform the steps of:
performing decompiling processing on the authentication SDK to obtain a smali file of a starting page of the authentication SDK;
and combining the smali file of the starting page of the authentication SDK, the first smali file and the smali file of the loading module to obtain a second smali file.
16. The electronic device of any of claims 9-15, wherein the one or more programs, when executed by the processor, cause the electronic device to perform the steps of:
decompressing the first installation package to obtain a media resource file of the APP;
and generating a second installation package of the APP according to the media resource file and the second file set.
17. A computer-readable storage medium storing computer instructions which, when run on an electronic device, cause the electronic device to perform the method of generating an installation package for an application program of any one of claims 1 to 8.
18. A computer program product, characterized in that it causes a computer to carry out the method of generating an installation package of an application program according to any one of claims 1 to 9, when said computer program product is run on said computer.
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011557385.3A CN114675840A (en) | 2020-12-24 | 2020-12-24 | Method and electronic equipment for generating installation package of application program |
PCT/CN2021/137943 WO2022135227A1 (en) | 2020-12-24 | 2021-12-14 | Method for generating installation package of application and electronic device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011557385.3A CN114675840A (en) | 2020-12-24 | 2020-12-24 | Method and electronic equipment for generating installation package of application program |
Publications (1)
Publication Number | Publication Date |
---|---|
CN114675840A true CN114675840A (en) | 2022-06-28 |
Family
ID=82071023
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202011557385.3A Pending CN114675840A (en) | 2020-12-24 | 2020-12-24 | Method and electronic equipment for generating installation package of application program |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN114675840A (en) |
WO (1) | WO2022135227A1 (en) |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102760219A (en) * | 2011-12-20 | 2012-10-31 | 北京安天电子设备有限公司 | Android platform software protecting system, method and equipment |
CN108427552A (en) * | 2018-03-01 | 2018-08-21 | 深圳市创梦天地科技有限公司 | Android application installation package producing device, method, electronic equipment and storage medium |
CN108897562A (en) * | 2018-06-27 | 2018-11-27 | 腾讯科技(深圳)有限公司 | Installation kit update method, device, medium and equipment |
CN109614107A (en) * | 2018-11-01 | 2019-04-12 | 同盾控股有限公司 | A kind of integrated approach and device of Software Development Kit |
CN110784474A (en) * | 2019-10-31 | 2020-02-11 | 苏州思必驰信息科技有限公司 | Embedded product access authorization method and device |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106155717A (en) * | 2015-04-01 | 2016-11-23 | 北京蓝海讯通科技有限公司 | A kind of method and apparatus that SDK is integrated into third party APK |
KR20180015535A (en) * | 2016-08-03 | 2018-02-13 | 주식회사 엔에스에이치씨 | Obfuscation method of android application using partial encryption of dex file in android application package |
CN106445509A (en) * | 2016-09-09 | 2017-02-22 | 厦门雅基软件有限公司 | SDK batch quick access tool |
CN109960509A (en) * | 2019-03-06 | 2019-07-02 | 江苏通付盾信息安全技术有限公司 | Using the method, apparatus of reinforcing, calculate equipment and computer storage medium |
-
2020
- 2020-12-24 CN CN202011557385.3A patent/CN114675840A/en active Pending
-
2021
- 2021-12-14 WO PCT/CN2021/137943 patent/WO2022135227A1/en active Application Filing
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102760219A (en) * | 2011-12-20 | 2012-10-31 | 北京安天电子设备有限公司 | Android platform software protecting system, method and equipment |
CN108427552A (en) * | 2018-03-01 | 2018-08-21 | 深圳市创梦天地科技有限公司 | Android application installation package producing device, method, electronic equipment and storage medium |
CN108897562A (en) * | 2018-06-27 | 2018-11-27 | 腾讯科技(深圳)有限公司 | Installation kit update method, device, medium and equipment |
CN109614107A (en) * | 2018-11-01 | 2019-04-12 | 同盾控股有限公司 | A kind of integrated approach and device of Software Development Kit |
CN110784474A (en) * | 2019-10-31 | 2020-02-11 | 苏州思必驰信息科技有限公司 | Embedded product access authorization method and device |
Also Published As
Publication number | Publication date |
---|---|
WO2022135227A1 (en) | 2022-06-30 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10831460B2 (en) | System and method for extending the functionality of an application | |
CN102804194B (en) | For providing method and the device of application security | |
WO2015055074A1 (en) | Method and device for dynamically loading and invoking program | |
KR101759801B1 (en) | Software application delivery and launching system | |
CN104375849A (en) | Core loading method and device | |
US8799889B2 (en) | Application downloading | |
WO2016119548A1 (en) | Method for preventing software decompilation, and method and apparatus for preventing decompilation software from starting | |
US9513762B1 (en) | Static content updates | |
CN111290740B (en) | Application program development method and device, computer equipment and storage medium | |
Kaur et al. | Implementation of Linux Optimization Technique for ARM Based System on Chip | |
KR20190109979A (en) | Electronic device and method for controling update thereof | |
CN113709185B (en) | Method and system for realizing Android cloud streaming | |
CN108536444B (en) | Plug-in compiling method and device, computer equipment and storage medium | |
CN102214105B (en) | Parallelization quick start method and the electronic installation with multiplied unit | |
CN114675840A (en) | Method and electronic equipment for generating installation package of application program | |
CN112199208B (en) | Method and terminal for providing additional function interface on android system | |
CN113157337A (en) | Application program starting method and device, terminal equipment and storage medium | |
CN111338708A (en) | Application program processing method, client and system based on android plug-in | |
US20170371595A1 (en) | Preemptive decompression scheduling for a nand storage device | |
WO2019157891A1 (en) | Application installation method and application installer generating method | |
CN112148296B (en) | Compiling and running method and device and compiling and running device | |
CN111399926A (en) | Method and device for downloading starting program | |
US20180239894A1 (en) | Universal application composed of multiple universal applications | |
CN110035322A (en) | A kind of method, apparatus and computer readable storage medium of activation system | |
CN114995847A (en) | Hot update method, device, equipment and computer readable storage medium |
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 |