Software product reinforcement method, apparatus and system

By separating the reinforcement tools of iOS software products, only primary compilation is completed on the client side, and the core code of the reinforcement process is retained on the server side, the local legality verification, frequent adaptation and reverse of the reinforcement solution in the existing technology is solved. The risk issue has achieved cross-platform compilation and reinforcement, improving compatibility and deployment convenience.

WO2024230414A1PCT designated stage expired Publication Date: 2024-11-14NETEASE (HANGZHOU) NETWORK CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2024/087767
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-05-09
Filing Date
2024-04-15
Publication Date
2024-11-14

AI Technical Summary

Technical Problem

The existing iOS software product reinforcement solutions have local legality verification defects, frequent adaptation to Xcode versions, huge packages and easy to be reversed, and the size limitations of online solutions based on bitcode and uncertainty in the future.

Method used

Separate the client's reinforcement tool, complete only the primary compilation process, retain the core code of the reinforcement process on the server, realize cross-platform compilation and reinforcement, reduce the size of the package body and reduce the risk of reverse.

Benefits of technology

Improves platform compatibility and deployment ease, reduces the need for frequent adaptation, reduces cracking risks, and unconsciously and safely intervenes in the project.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024087767_14112024_PF_FP_ABST
    Figure CN2024087767_14112024_PF_FP_ABST
Patent Text Reader

Abstract

A software product reinforcement method, apparatus and system. The method is applied to a client, and comprises: receiving a reinforcement request of a target software product, wherein the request carries an engineering configuration file corresponding to the target software product (S102); reading configuration information from the engineering configuration file, and sending same to a server, such that the server performs verification according to the configuration information, and returns, after the verification is successful, a reinforcement parameter corresponding to the target software product (S104); performing compilation pre-processing on the engineering configuration file on the basis of the reinforcement parameter, and performing compilation on the basis of the engineering configuration file which has been subjected to compilation pre-processing, so as to obtain intermediate representation files (S106); sending some specified intermediate representation files to the server, such that the server performs compilation reinforcement processing on the specified intermediate representation files, and returns compilation-reinforced files (S108); and integrating the compilation-reinforced files to the engineering configuration file, so as to obtain a reinforced engineering file corresponding to the target software product (S110). By means of separate compilation of a front end and a back end, the platform compatibility and deployment convenience are improved, and a generated packet is relatively small, such that frequent adaption is not required, and reversion is not easily performed by an opponent.
Need to check novelty before this filing date? Find Prior Art

Description

Software product reinforcement method, device and system

[0001] CROSS-REFERENCE TO RELATED APPLICATIONS

[0002] This disclosure claims priority to Chinese patent application number 202310518390.0, filed on May 9, 2023, entitled “Method, device and system for strengthening software products”, the entire contents of which are incorporated herein by reference. Technical Field

[0003] The present disclosure relates to the field of software technology, and in particular to a method, device, and system for reinforcing a software product. Background Art

[0004] Currently, the available hardening solutions for iOS software products typically use either an offline Toolchain-based solution or an online solution based on bitcode hardening. The offline Toolchain solution, which integrates the necessary tools and libraries into the offline Toolchain, has several drawbacks: 1. Because it operates offline, local validity verification is flawed; 2. It requires frequent Xcode version updates, making the process difficult to control; 3. Due to the large number of compiler dependencies, the released package size is large; 4. Exposed executables are easily reverse-engineered by hackers and adversaries. Online solutions based on bitcode hardening have size limitations, making them unsuitable for gaming software. Furthermore, Apple's decision to deprecate bitcode makes its future uncertain.

[0005] Summary of the Invention

[0006] The purpose of the present disclosure is to provide a method, device and system for reinforcing software products, which separate the entire set of client-side reinforcement tools in related technologies, so that the client only completes the primary compilation process, while retaining the core code of the reinforcement process on the server side, thereby realizing cross-platform compilation reinforcement, improving platform compatibility and deployment convenience, and generating a smaller package body, which does not require frequent adaptation and is not easily reverse-engineered by opponents.

[0007] In a first aspect, an embodiment of the present disclosure provides a method for reinforcing a software product, which is applied to a client; the method includes: receiving a reinforcement request for a target software product; the request carries a project configuration file corresponding to the target software product; reading configuration information from the project configuration file and sending it to a server, so that the server verifies according to the configuration information, and returns reinforcement parameters corresponding to the target software product after successful verification; based on the reinforcement parameters, compile and preprocess the project configuration file, and compile based on the preprocessed project configuration file to obtain an intermediate code file; sending a portion of the specified intermediate code file to the server, so that the server compiles and reinforces the portion of the specified intermediate code file, and returns the compiled and reinforced file; integrating the compiled and reinforced file into the project configuration file to obtain a reinforced project file corresponding to the target software product.

[0008] In a second aspect, an embodiment of the present disclosure also provides a method for reinforcing a software product, which is applied to a server; the method includes: receiving configuration information sent by a client, performing verification based on the configuration information, and returning reinforcement parameters corresponding to the target software product to the client after successful verification, so that the client compiles and pre-processes the project configuration file based on the reinforcement parameters, and compiles based on the pre-processed project configuration file to obtain an intermediate code file; the configuration information is read from the corresponding project configuration file after the client receives a reinforcement request for the target software product; receiving a partially specified intermediate code file sent by the client, performing secondary compilation and reinforcement processing on the partially specified intermediate code file, and returning the compiled reinforcement file, so that the client integrates the compiled reinforcement file into the project configuration file to obtain a reinforced project file corresponding to the target software product.

[0009] In a third aspect, an embodiment of the present disclosure also provides a reinforcement device for a software product, which is applied to a client; the device includes: a request receiving module for receiving a reinforcement request for a target software product; the request carries a project configuration file corresponding to the target software product; an information sending module for reading configuration information from the project configuration file and sending it to a server, so that the server performs verification according to the configuration information, and returns the reinforcement parameters corresponding to the target software product after successful verification; a compilation module for pre-compilation processing of the project configuration file based on the reinforcement parameters, and compiles the project configuration file based on the pre-compiled project configuration file to obtain an intermediate code file; a file sending module for sending a portion of the specified intermediate code file to the server, so that the server performs secondary compilation and reinforcement processing on the portion of the specified intermediate code file, and returns the compiled reinforcement file; an integration module for integrating the compiled reinforcement file into the project configuration file to obtain a reinforcement project file corresponding to the target software product.

[0010] In a fourth aspect, an embodiment of the present disclosure also provides a reinforcement device for a software product, which is applied to a server; the device includes: a verification module, which is used to receive configuration information sent by a client, perform verification according to the configuration information, and return the reinforcement parameters corresponding to the target software product to the client after successful verification, so that the client can compile and preprocess the project configuration file based on the reinforcement parameters, and compile based on the preprocessed project configuration file to obtain an intermediate code file; the configuration information is read from the corresponding project configuration file after the client receives a reinforcement request for the target software product; the reinforcement module is used to receive a part of the specified intermediate code file sent by the client, compile and reinforce the part of the specified intermediate code file, and return the compiled reinforcement file, so that the client can integrate the compiled reinforcement file into the project configuration file to obtain the reinforcement project file corresponding to the target software product.

[0011] In a fifth aspect, an embodiment of the present disclosure further provides a software product reinforcement system, the system comprising a client and a server; the client is used to execute the method as described in the first aspect; the server is used to execute the method as described in the second aspect.

[0012] In a sixth aspect, an embodiment of the present disclosure further provides a computer-readable storage medium, which stores computer-executable instructions. When the computer-executable instructions are called and executed by a processor, the computer-executable instructions prompt the processor to implement the method described in the first or second aspect above.

[0013] In the reinforcement method, device and system of the software product provided by the embodiment of the present disclosure, the method is applied to the client; first, a reinforcement request for the target software product is received; the request carries the engineering configuration file corresponding to the target software product; then, configuration information is read from the engineering configuration file and sent to the server, so that the server verifies according to the configuration information, and returns the reinforcement parameters corresponding to the target software product after successful verification; based on the reinforcement parameters, the engineering configuration file is compiled and preprocessed, and the engineering configuration file after compilation and preprocessing is compiled to obtain an intermediate code file; finally, part of the specified intermediate code file is sent to the server, so that the server compiles and reinforces the part of the specified intermediate code file and returns the compiled reinforcement file; the compiled reinforcement file is integrated into the engineering configuration file to obtain the reinforcement engineering file corresponding to the target software product. In the above method, the entire set of reinforcement tools of the client in the related technology is separated, so that the client only completes the primary compilation process, and the core code of the reinforcement process is retained on the server, thereby realizing cross-platform compilation reinforcement, improving platform compatibility and deployment convenience, and the resulting package is smaller, does not need to be frequently adapted and is not easily reversed by the opponent. BRIEF DESCRIPTION OF THE DRAWINGS

[0014] In order to more clearly illustrate the specific embodiments of the present disclosure or the technical solutions in the related technologies, the following briefly introduces the drawings required for use in the specific embodiments or related technical descriptions. Obviously, the drawings described below are some embodiments of the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0015] FIG1 is a flow chart of a method for reinforcing a software product provided by an embodiment of the present disclosure;

[0016] FIG2 is a schematic diagram of a software product reinforcement process provided by an embodiment of the present disclosure;

[0017] FIG3 is a flow chart of another software product reinforcement method provided by an embodiment of the present disclosure;

[0018] FIG4 is a structural block diagram of a software product reinforcement device provided by an embodiment of the present disclosure;

[0019] FIG5 is a structural block diagram of another software product reinforcement device provided by an embodiment of the present disclosure;

[0020] FIG6 is a schematic diagram of the structure of a software product reinforcement system provided by an embodiment of the present disclosure. DETAILED DESCRIPTION

[0021] The following will clearly and completely describe the technical solutions of the present disclosure in conjunction with the embodiments. Obviously, the embodiments described are only a part of the embodiments of the present disclosure, not all of them. Based on the embodiments of the present disclosure, all other embodiments obtained by ordinary technicians in this field without making any creative efforts are within the scope of protection of the present disclosure.

[0022] One of the current iOS hardening solutions on the market involves integrating the necessary tools and libraries into an offline toolchain. This approach has several drawbacks: 1. Because it's an offline approach, local validation is flawed; 2. It requires constant adaptation to Xcode (the integrated development tool IDE running on Mac OS X), which frequently updates and makes the process difficult to control; 3. Because the compiler relies on numerous libraries, the released package size is large; and 4. Exposed executables are easily reverse engineered by hackers and adversaries.

[0023] The other method is an online solution reinforced with bitcode (an intermediate code introduced by LLVM). However, it has a size limit and is not suitable for game software products. In addition, its future is uncertain because Apple has decided to abandon bitcode (Xcode 14.0 no longer builds bitcode by default. In future versions of Xcode, the function of building with bitcode will be removed. IPA Apple application files containing bitcode will be stripped before being submitted to the App Store).

[0024] Based on this, the disclosed embodiments provide a software product hardening method, device, and system. These methods separate the entire client-side hardening tool set used in related technologies, allowing the client to complete only the primary compilation process while retaining the core hardening code on the server. This enables cross-platform compilation and hardening, improving platform compatibility and deployment convenience. The resulting package size is smaller, requiring less frequent adaptation and making it less susceptible to reverse engineering by adversaries. To facilitate understanding of this embodiment, a detailed description of the software product hardening method disclosed in this embodiment is first provided.

[0025] FIG1 is a flowchart of a method for hardening a software product provided by an embodiment of the present disclosure, which is applied to a client. The method specifically includes the following steps:

[0026] Step S102: receiving a reinforcement request for a target software product; the request carries a project configuration file corresponding to the target software product.

[0027] The target software product can be a game or other software product. In practice, before initiating a request, the user can download a local executable program and double-click it to install it. This program will detect the local environment and install the entire nebuildtool suite to a designated location recognized by Xcode. Prior to this, a service has already been deployed on the server, enabling interaction with the local nebuildtool and data upload and download.

[0028] In other words, the client is pre-installed with a custom local command line tool, namely, the nebuildtool tool. This tool is a self-developed executable terminal command tool that follows the official Xcode project compilation style. When the access party converts the conventional `xcodebuild archive-workspace Demo.xcworkspace` to `nebuildtool archive-workspace Demo.xcworkspace`, the project can be quickly compiled and reinforced.

[0029] After specifying the project path for the target software product in the workspace, users can call nebuildtool from the command line to initiate a hardening request. The request includes the project configuration file (.pbx file) corresponding to the target software product, which contains the configuration and references for the entire project.

[0030] Step S104: read configuration information from the project configuration file and send it to the server, so that the server performs verification according to the configuration information and returns the corresponding reinforcement parameters of the target software product after successful verification.

[0031] The configuration information read includes the target software product's identifier and token information. This information is sent to the server for verification. Upon successful verification, the server automatically returns the corresponding hardening parameters for the target software product. The hardening parameters include parameters related to the functions required during the hardening process.

[0032] Step S106 , performing compilation preprocessing on the project configuration file based on the reinforcement parameters, and performing compilation based on the preprocessed project configuration file to obtain an intermediate code file.

[0033] During the packaging process, nebuildtool automatically imports relevant functional dependencies and parameters after verification, compiling intermediate products at the target granularity. After triggering the hardening rules, the local products are uploaded to the server. The compilation preprocessing mentioned above automatically imports relevant functional dependencies and parameters, completing some pre-compilation preparations based on the hardening parameters, namely, processing the project configuration files. Compilation is performed based on the preprocessed project configuration files to produce intermediate code files.

[0034] Step S108: Send the designated intermediate code files to the server, so that the server compiles and reinforces the designated intermediate code files and returns the compiled and reinforced files.

[0035] In this solution, the key reinforcement process is completed on the server side. When the server monitors the uploaded files, that is, some specified intermediate code files, it starts clang to compile and reinforce the corresponding functions, and then sends them to the client's nebuildtool after completion.

[0036] Step S110 , integrating the compiled reinforcement file into the project configuration file to obtain a reinforcement project file corresponding to the target software product.

[0037] In the reinforcement method for software products provided in the embodiments of the present disclosure, a custom reinforcement tool, nebuildtool, is used to maintain the same parameters and style as the system compilation command. Only one call command needs to be replaced, and the core operations are moved to the server. This allows various protection functions to be seamlessly and safely introduced into the project, reducing the difficulty of access and the risk of cracking, and having little impact on the performance of games and applications. In this solution, the entire set of reinforcement tools on the client side in the related technology is separated, so that the client only completes the primary compilation process, while the core code of the reinforcement process is retained on the server side, thereby achieving cross-platform compilation reinforcement and improving platform compatibility and deployment convenience. In addition, the tool package is small, and the recompilation process on the server side does not need to be frequently adapted.

[0038] The embodiment of the present disclosure also provides a method for reinforcing a software product. The method is implemented on the basis of the previous embodiment. This embodiment focuses on describing the compilation process on the client side.

[0039] In a preferred embodiment of the present disclosure, the step of compiling and preprocessing the project configuration file based on the reinforcement parameters includes:

[0040] (1) Enable related reinforcement functions according to the reinforcement parameters, introduce the anti-cheating software development toolkit, configure the project configuration file identifier and add dynamic macros, and encapsulate the reinforcement information into a preset format.

[0041] As shown in Figure 2, the client-side hardening tool, nebuildtool, reads the configuration information and receives the hardening parameters returned by the server. It then parses the parameters, which are divided into required and optional parameters. Required parameters can be specified on the command line, automatically obtained, or configured and passed in, such as the hardening parameters returned by the server mentioned above. Non-required parameters are obtained from hidden parameters in the interface and then concatenated after parsing. The specific concatenation process is as follows: enabling the relevant hardening features, introducing the anti-cheating SDK, setting bids, and adding dynamic macros. Finally, the parameters are packaged into custom parameters, which are hardening information in a pre-defined format (such as JSON).

[0042] (2) Compile and preprocess the project configuration file based on the reinforcement information. Specifically, insert the hookfile into the project configuration file, back up the project configuration file, and add the reference corresponding to the reinforcement information to the project configuration file. The specific process of inserting hookfiles and processing the pbx file is shown in Figure 2, resulting in a compiled and preprocessed project configuration file.

[0043] After the step of encapsulating the reinforcement information into a preset format, the process further includes: writing the reinforcement information into a project configuration file; and writing the ipa reinforcement information as shown in FIG2 .

[0044] In addition, the method further includes, in response to turning on the upload switch for the project configuration file, uploading the project configuration file to the server. Before the step of compiling and preprocessing the project configuration file, the method further includes: removing the cached workspace to facilitate subsequent compilation processes.

[0045] The software product hardening method provided in the disclosed embodiments utilizes a custom hardening tool for the software product in need of hardening, seamlessly and securely integrating various protection features into the project. This reduces access difficulty and the risk of cracking, while minimizing the impact on the performance of games and applications. By separating the entire client-side hardening tool set from related technologies, the client only completes the initial compilation process, while retaining the core hardening code on the server. This enables cross-platform compilation and hardening, improving platform compatibility and ease of deployment.

[0046] The advantages of the above solution are: 1. It is not easy to be bypassed, and the server can actively disconnect the compilation process even if an abnormality is detected; 2. The external version is controllable, and there is no need to follow the LLVM version for client adaptation iteration. Instead, the adaptation is updated to Docker at one time; 3. The package size is reduced from approximately 3.3G to 15M, saving download traffic; 4. It also supports one-click installation and easy access; 5. It improves functional safety; 6. It supports multi-platform compilation, which facilitates subsequent cluster deployment and maintenance; 7. It supports one-click and imperceptible access to the anti-cheating function.

[0047] Through this solution, game developers no longer need to worry about game security issues, the risk of cracking and leaking is reduced, and the resource investment of game developers in security can be directly reduced.

[0048] Based on the above method embodiment, the present disclosure also provides a method for reinforcing a software product, which is applied to a server. Referring to FIG3 , the method includes:

[0049] Step S302: receive the configuration information sent by the client, perform verification based on the configuration information, and return the reinforcement parameters corresponding to the target software product to the client after successful verification, so that the client can compile and preprocess the project configuration file based on the reinforcement parameters, and compile based on the preprocessed project configuration file to obtain an intermediate code file; the configuration information is read from the corresponding project configuration file after the client receives the reinforcement request for the target software product.

[0050] Step S304, receiving part of the designated intermediate code files sent by the client, performing secondary compilation and reinforcement processing on the part of the designated intermediate code files, and returning the compiled and reinforced files so that the client can integrate the compiled and reinforced files into the project configuration file to obtain the reinforced project file corresponding to the target software product.

[0051] In a preferred embodiment, the server is configured with a Linux operating system and a container; the step of performing secondary compilation and reinforcement processing on some specified intermediate code files includes: performing secondary compilation and reinforcement processing on the intermediate code files by executing the reinforcement program in the container.

[0052] In related technologies, servers must be installed on a MAC platform or on a MAC device. However, the server provided in the embodiment of the present disclosure can be placed on Linux, that is, configured with a Linux operating system and a container, and a reinforcement program is pre-stored in the container, thereby realizing the compilation and reinforcement processing of the server in a cross-platform manner.

[0053] The purpose of the docker subroutine is to recompile the client's source intermediate product. When notified that there is a file task to be processed, the uniqueness is first guaranteed by adding a timestamp to the file name. Then the corresponding zip is extracted to obtain the configuration file and IR (Intermediate Representation). During this period, various exception judgments and processing will be performed to return error codes, such as the non-existence of the configuration file, the lack of source IR, the expiration of the passkey, the sysroot mapping error, etc. After passing the verification, the compilation script is called for recompilation. The compilation script re-joins the parameters and assembles the local path, and finally makes an executable call and throws an exception. After all files are compiled, they are finally merged, built, and compressed, and the interface program is notified that the task has been completed. At this time, the compiled and reinforced file is returned to the client so that the client can finally integrate it into the reinforced project file corresponding to the target software product.

[0054] The method provided in the embodiment of the present disclosure has the same implementation principle and technical effects as those in the aforementioned method embodiment. For the sake of brief description, for matters not mentioned in the embodiment of the method, reference may be made to the corresponding contents in the aforementioned method embodiment.

[0055] In the software product reinforcement method provided by the embodiment of the present disclosure, the entire set of client reinforcement tools in the related technology is separated, so that the client only completes the primary compilation process, while the core code of the reinforcement process is retained on the server side, and the reinforcement program code is added to the container under the Linux system, thereby realizing cross-platform compilation reinforcement and improving platform compatibility and deployment convenience.

[0056] Based on the above method embodiment, the embodiment of the present disclosure also provides a reinforcement device for a software product, which is applied to a client; as shown in Figure 4, the device includes: a request receiving module 402, which is used to receive a reinforcement request for a target software product; the request carries a project configuration file corresponding to the target software product; an information sending module 404, which is used to read configuration information from the project configuration file and send it to the server, so that the server verifies according to the configuration information, and returns the reinforcement parameters corresponding to the target software product after successful verification; a compilation module 406, which is used to compile and pre-process the project configuration file based on the reinforcement parameters, and compile based on the pre-processed project configuration file to obtain an intermediate code file; a file sending module 408, which is used to send a portion of the specified intermediate code file to the server, so that the server performs secondary compilation and reinforcement processing on the portion of the specified intermediate code file, and returns the compiled reinforcement file; an integration module 410, which is used to integrate the compiled reinforcement file into the project configuration file to obtain a reinforcement project file corresponding to the target software product.

[0057] In a preferred embodiment of the present disclosure, the above-mentioned compilation module 406 is used to enable relevant reinforcement functions according to the reinforcement parameters, introduce an anti-cheating software development toolkit, configure the project configuration file identifier and add dynamic macros, and encapsulate the reinforcement information in a preset format; and compile and pre-process the project configuration file based on the reinforcement information.

[0058] In a preferred embodiment of the present disclosure, the compilation module 406 is configured to insert the interception file into the project configuration file, back up the project configuration file, and add a reference corresponding to the reinforcement information into the project configuration file.

[0059] In a preferred embodiment of the present disclosure, the above-mentioned device also includes: an upload module, which is used to write the reinforcement information into the project configuration file after the step of encapsulating the reinforcement information into a preset format; and upload the project configuration file to the server in response to the upload switch opening operation for the project configuration file.

[0060] In a preferred embodiment of the present disclosure, the above-mentioned device further includes: a space removal module, which is used to remove the cached workspace before the step of compiling and preprocessing the project configuration file.

[0061] In a preferred embodiment of the present disclosure, the above configuration information includes an identifier and tocken information corresponding to the target software product.

[0062] The device provided in the embodiment of the present disclosure has the same implementation principle and technical effects as those in the aforementioned method embodiment. For the sake of brief description, for parts not mentioned in the embodiment of the device, reference may be made to the corresponding contents in the aforementioned method embodiment.

[0063] Based on the above method embodiment, the embodiment of the present disclosure also provides a reinforcement device for a software product, which is applied to a server; as shown in Figure 5, the device includes: a verification module 52, which is used to receive configuration information sent by the client, perform verification according to the configuration information, and return the reinforcement parameters corresponding to the target software product to the client after successful verification, so that the client can compile and preprocess the project configuration file based on the reinforcement parameters, and compile based on the preprocessed project configuration file to obtain an intermediate code file; the configuration information is read from the corresponding project configuration file after the client receives the reinforcement request for the target software product; the reinforcement module 54 is used to receive a portion of the specified intermediate code file sent by the client, compile and reinforce the portion of the specified intermediate code file, and return the compiled and reinforced file, so that the client can integrate the compiled and reinforced file into the project configuration file to obtain the reinforced project file corresponding to the target software product.

[0064] In a preferred embodiment of the present disclosure, the server is configured with a Linux operating system and a container; the reinforcement module 54 is used to perform secondary compilation and reinforcement processing on the intermediate code file by executing the reinforcement program in the container.

[0065] The device provided in the embodiment of the present disclosure has the same implementation principle and technical effects as those in the aforementioned method embodiment. For the sake of brief description, for parts not mentioned in the embodiment of the device, reference may be made to the corresponding contents in the aforementioned method embodiment.

[0066] Based on the above method embodiment, the embodiment of the present disclosure further provides a software product reinforcement system. Referring to FIG6 , the system includes a client 62 and a server 64. The client 62 is used to execute the method described in the client method embodiment:

[0067] Receive a reinforcement request for a target software product; the request carries a project configuration file corresponding to the target software product; read configuration information from the project configuration file and send it to a server, so that the server verifies it according to the configuration information, and returns reinforcement parameters corresponding to the target software product after successful verification; based on the reinforcement parameters, compile and preprocess the project configuration file, and compile based on the preprocessed project configuration file to obtain an intermediate code file; send part of the specified intermediate code file to the server, so that the server compiles and reinforces the part of the specified intermediate code file, and returns the compiled and reinforced file; integrate the compiled and reinforced file into the project configuration file to obtain a reinforcement project file corresponding to the target software product.

[0068] In a preferred embodiment of the present disclosure, the above-mentioned step of compiling and preprocessing the project configuration file based on the reinforcement parameters includes: enabling relevant reinforcement functions according to the reinforcement parameters, introducing an anti-cheating software development toolkit, configuring the project configuration file identifier and adding dynamic macros, and encapsulating the reinforcement information in a preset format; compiling and preprocessing the project configuration file based on the reinforcement information.

[0069] In a preferred embodiment of the present disclosure, the above-mentioned step of compiling and preprocessing the project configuration file based on the reinforcement information includes: inserting the interception file into the project configuration file, backing up the project configuration file, and adding a reference corresponding to the reinforcement information to the project configuration file.

[0070] In a preferred embodiment of the present disclosure, after the above step of encapsulating the reinforcement information into a preset format, the method further includes: writing the reinforcement information into a project configuration file; and uploading the project configuration file to a server in response to turning on an upload switch for the project configuration file.

[0071] In a preferred embodiment of the present disclosure, before the above step of compiling and preprocessing the project configuration file, the method further includes: removing the cached workspace.

[0072] In a preferred embodiment of the present disclosure, the above configuration information includes an identifier and tocken information corresponding to the target software product.

[0073] The server 64 is used to execute the method described in the server-side method embodiment:

[0074] Receive configuration information sent by the client, perform verification based on the configuration information, and return the corresponding reinforcement parameters of the target software product to the client after successful verification, so that the client can compile and preprocess the project configuration file based on the reinforcement parameters, and compile based on the preprocessed project configuration file to obtain an intermediate code file; the configuration information is read from the corresponding project configuration file after the client receives the reinforcement request for the target software product;

[0075] Receive some designated intermediate code files sent by the client, perform secondary compilation and reinforcement processing on some designated intermediate code files, and return the compiled and reinforced files so that the client can integrate the compiled and reinforced files into the project configuration file to obtain the reinforcement project file corresponding to the target software product.

[0076] In a preferred embodiment of the present disclosure, the above-mentioned server is configured with a Linux operating system and a container; the step of performing secondary compilation and reinforcement processing on some specified intermediate code files includes: performing secondary compilation and reinforcement processing on the intermediate code files by executing the reinforcement program in the container.

[0077] The system provided by the embodiment of the present disclosure has the same implementation principle and technical effects as those of the aforementioned method embodiment. For the sake of brief description, for parts not mentioned in the embodiment of the system, reference may be made to the corresponding contents in the aforementioned method embodiment.

[0078] An embodiment of the present disclosure also provides a computer-readable storage medium, which stores computer-executable instructions. When the computer-executable instructions are called and executed by a processor, the computer-executable instructions prompt the processor to implement the above-mentioned method. The specific implementation can be found in the above-mentioned method embodiment, which will not be repeated here.

[0079] The computer program products of the methods, devices, and electronic devices provided in the embodiments of the present disclosure include a computer-readable storage medium storing program code. The instructions included in the program code can be used to execute the methods described in the previous method embodiments. For specific implementation, please refer to the method embodiments and will not be repeated here.

[0080] Unless otherwise specifically stated, the relative steps, numerical expressions and numerical values ​​of the components and steps set forth in these embodiments do not limit the scope of the present disclosure.

[0081] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a non-volatile computer-readable storage medium that is executable by a processor. Based on this understanding, the technical solution of the present disclosure, or the part that contributes to the relevant technology or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present disclosure. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0082] In the description of this disclosure, it should be noted that the terms "center," "upper," "lower," "left," "right," "vertical," "horizontal," "inner," and "outer," etc., indicating orientations or positional relationships, are based on the orientations or positional relationships shown in the accompanying drawings and are intended solely to facilitate the description of this disclosure and simplify the description. They do not indicate or imply that the devices or components referred to must have a specific orientation, be constructed, or operate in a specific orientation. Therefore, they should not be construed as limitations on this disclosure. Furthermore, the terms "first," "second," and "third" are used for descriptive purposes only and should not be construed as indicating or implying relative importance.

[0083] Finally, it should be noted that the above-described embodiments are only specific implementation methods of the present disclosure, which are used to illustrate the technical solutions of the present disclosure, rather than to limit them. The scope of protection of the present disclosure is not limited thereto. Although the present disclosure has been described in detail with reference to the above-described embodiments, those skilled in the art should understand that any person skilled in the art can modify or easily conceive of changes to the technical solutions described in the above-described embodiments within the technical scope disclosed in the present disclosure, or replace some of the technical features therein with equivalents. Such modifications, changes, or replacements do not deviate from the spirit and scope of the technical solutions of the embodiments of the present disclosure, and should be included in the scope of protection of the present disclosure. Therefore, the scope of protection of the present disclosure shall be subject to the scope of protection of the claims.

Claims

1. A method for reinforcing a software product, the method being applied to a client; the method comprising: Receive reinforcement requests for target software products; The request carries a project configuration file corresponding to the target software product; Reading configuration information from the project configuration file and sending it to the server, so that the server performs verification according to the configuration information, and returns the reinforcement parameters corresponding to the target software product after successful verification; Based on the reinforcement parameters, the project configuration file is compiled and preprocessed, and the project configuration file is compiled based on the preprocessed project configuration file to obtain an intermediate code file; Sending a portion of the designated intermediate code files to a server, so that the server compiles and reinforces the portion of the designated intermediate code files, and returns the compiled and reinforced files; The compiled reinforcement file is integrated into the project configuration file to obtain a reinforcement project file corresponding to the target software product.

2. The method according to claim 1, wherein: The step of compiling and preprocessing the project configuration file based on the reinforcement parameters includes: Enable relevant reinforcement functions according to the reinforcement parameters, introduce an anti-plug-in software development toolkit, configure the project configuration file identifier, add dynamic macros, and encapsulate the reinforcement information in a preset format; The project configuration file is compiled and preprocessed based on the reinforcement information.

3. The method according to claim 2, wherein: The step of compiling and preprocessing the project configuration file based on the reinforcement information includes: Inserting the interception file into the project configuration file, backing up the project configuration file, and adding the reference corresponding to the reinforcement information to the project configuration file.

4. The method according to claim 2, wherein: After the step of encapsulating the reinforcement information into a preset format, the following steps are also included: Writing the reinforcement information into the project configuration file; In response to an upload switch opening operation for the project configuration file, the project configuration file is uploaded to a server.

5. The method according to claim 1, wherein: Before the step of compiling and preprocessing the project configuration file, the method further includes: removing the cached workspace.

6. The method according to claim 1, wherein: The configuration information includes the identifier and token information corresponding to the target software product.

7. A method for reinforcing a software product, wherein: The method is applied to a server; the method comprises: Receive configuration information sent by the client, perform verification according to the configuration information, and return the reinforcement parameters corresponding to the target software product to the client after successful verification, so that the client compiles and preprocesses the project configuration file based on the reinforcement parameters, and compiles based on the preprocessed project configuration file to obtain an intermediate code file; the configuration information is read from the corresponding project configuration file after the client receives the reinforcement request for the target software product; Receive the partially specified intermediate code files sent by the client, perform secondary compilation and reinforcement processing on the partially specified intermediate code files, and return the compiled and reinforced files so that the client can integrate the compiled and reinforced files into the project configuration file to obtain the reinforced project file corresponding to the target software product.

8. The method according to claim 7, wherein: The server is configured with a Linux operating system and a container; the step of performing secondary compilation and reinforcement processing on the part of the specified intermediate code files includes: By executing the reinforcement program in the container, the intermediate code file is recompiled and reinforced.

9. A software product reinforcement device, the device being applied to a client; the device comprising: A request receiving module, configured to receive a hardening request for a target software product; The request carries a project configuration file corresponding to the target software product; An information sending module is configured to read configuration information from the project configuration file and send it to the server, so that the server performs verification according to the configuration information and returns the reinforcement parameters corresponding to the target software product after successful verification; A compiling module is configured to perform compiling preprocessing on the project configuration file based on the reinforcement parameters, and compile based on the preprocessed project configuration file to obtain an intermediate code file; A file sending module is configured to execute sending of a portion of the designated intermediate code files to a server, so that the server performs secondary compilation and reinforcement processing on the portion of the designated intermediate code files, and returns a compiled and reinforced file; The integration module is used to integrate the compiled reinforcement file into the project configuration file to obtain the reinforcement project file corresponding to the target software product.

10. A software product reinforcement device, the device being applied to a server; the device comprising: A verification module is configured to execute and receive configuration information sent by a client, perform verification according to the configuration information, and return a reinforcement parameter corresponding to the target software product to the client after successful verification, so that the client compiles and pre-processes the project configuration file based on the reinforcement parameter, and compiles based on the pre-processed project configuration file to obtain an intermediate code file; The configuration information is read from the corresponding project configuration file by the client after receiving the reinforcement request of the target software product; The reinforcement module is configured to execute and receive a portion of the designated intermediate code files sent by the client, compile and reinforce the portion of the designated intermediate code files, and return the compiled and reinforced files, so that the client can integrate the compiled and reinforced files into the project configuration file to obtain the reinforced project file corresponding to the target software product.

11. A software product reinforcement system, the system comprising a client and a server; the client is used to execute the method according to any one of claims 1-6; the server is used to execute the method according to any one of claims 7-8.

12. A computer-readable storage medium storing computer-executable instructions, wherein when the computer-executable instructions are called and executed by a processor, the computer-executable instructions prompt the processor to implement the method according to any one of claims 1 to 8.

Citation Information

Patent Citations

  • Method and apparatus for hardening an application program

    CN108985017A

  • Software security reinforcement method and device, electronic equipment and storage medium

    CN112559983A

  • Security reinforcement method and system for Java application program

    CN115129361A

  • Software product reinforcement method, device and system

    CN116595497A

  • Ios application-based reinforcement method, apparatus, device, and storage medium

    WO2021151347A1