WO2018227798A1 - Custom system implementation method, computer device, and computer-readable storage medium - Google Patents

Custom system implementation method, computer device, and computer-readable storage medium Download PDF

Info

Publication number
WO2018227798A1
WO2018227798A1 PCT/CN2017/101788 CN2017101788W WO2018227798A1 WO 2018227798 A1 WO2018227798 A1 WO 2018227798A1 CN 2017101788 W CN2017101788 W CN 2017101788W WO 2018227798 A1 WO2018227798 A1 WO 2018227798A1
Authority
WO
WIPO (PCT)
Prior art keywords
system firmware
partition
customized
custom
resource
Prior art date
Application number
PCT/CN2017/101788
Other languages
French (fr)
Chinese (zh)
Inventor
李泽锦
Original Assignee
百富计算机技术(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 百富计算机技术(深圳)有限公司 filed Critical 百富计算机技术(深圳)有限公司
Publication of WO2018227798A1 publication Critical patent/WO2018227798A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/76Adapting program code to run in a different environment; Porting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44505Configuring for program initiating, e.g. using registry, configuration files

Definitions

  • the present application relates to the field of computer technology, and in particular, to a customized system implementation method, a computer device, and a computer readable storage medium.
  • POS Point of Sale
  • Customized content such as boot animation, system menu customization, or installation of built-in app. (Application, computer application) and so on.
  • the traditional solution is to release a system with different versions of system firmware to meet customer needs when different systems need to be customized according to the different needs of different customers.
  • a customization system implementation method, computer apparatus, and computer readable storage medium are provided.
  • a customized system implementation method including:
  • a custom resource is loaded from the custom resource partition by the system code executed.
  • a computer device comprising a memory and a processor, the memory comprising a system firmware partition and a custom resource partition, the memory storing computer readable instructions, the computer readable instructions being executed by the processor such that The processor performs the following steps:
  • a custom resource is loaded from the custom resource partition by the system code executed.
  • One or more non-transitory computer readable storage mediums storing computer readable instructions, when executed by one or more processors, cause the one or more processors to perform the following steps :
  • a custom resource is loaded from the custom resource partition by the system code executed.
  • 1 is an application environment diagram of a method for implementing a customized system in an embodiment
  • FIG. 2 is a schematic diagram showing the internal structure of a terminal in an embodiment
  • FIG. 3 is a schematic flow chart of a method for implementing a customized system in an embodiment
  • FIG. 4 is a schematic flow chart of a configuration procedure of a customized system in an embodiment
  • FIG. 5 is a schematic flow chart of a configuration procedure of a customized system in another embodiment
  • FIG. 6 is a schematic flow chart of a firmware testing procedure of a general system in an embodiment
  • FIG. 7 is a schematic flowchart of a custom resource package testing step in an embodiment
  • FIG. 8 is a schematic flow chart of a method for implementing a customized system in another embodiment.
  • FIG. 1 is an application environment diagram of a method for implementing a customized system in an embodiment.
  • the application environment includes a terminal 110 and a server 120.
  • the terminal may be a POS machine, a mobile phone, a tablet computer, or the like; the server may be an independent physical server or a server cluster composed of multiple physical servers.
  • the terminal 110 can execute a customized system implementation method, and utilizes general system firmware in the system firmware partition, combined with configuration information in the customized resource partition and corresponding customized resources to implement the customized system.
  • Terminal 110 can obtain general system firmware from server 120 and write to the system firmware partition.
  • the terminal 110 may acquire a customized resource package from the server 120, and write the customized resource and corresponding configuration information in the customized resource package into the customized resource partition.
  • FIG. 2 is a schematic diagram showing the internal structure of a terminal in an embodiment.
  • the terminal includes a processor connected through a system bus, a non-volatile storage medium, an internal memory, a camera, a display screen, a USB interface, and a network interface.
  • the non-volatile storage medium of the server includes a system firmware partition and a custom resource partition, and can store computer readable instructions that, when executed by the processor, enable the processor to implement a custom system implementation method.
  • the processor is used to provide computing and control capabilities to support the operation of the entire terminal. Also stored in the internal memory is computer readable instructions that, when executed by the processor, cause the processor to perform a custom system implementation. It will be understood by those skilled in the art that the structure shown in FIG.
  • FIG. 2 is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the terminal to which the solution of the present application is applied.
  • the specific terminal may include a ratio. More or fewer components are shown in the figures, or some components are combined, or have different component arrangements.
  • a custom system implementation method is provided. This embodiment is mainly illustrated by applying the method to the terminal in FIG. 2 described above. Referring to FIG. 3, the customized system implementation method specifically includes the following steps:
  • the system firmware partition is a partition in the terminal's memory for storing general system firmware.
  • System firmware is firmware that implements operating system functions.
  • the general system firmware is the system firmware that is implemented by different custom systems.
  • the general system firmware can be a generic Android (Android) system firmware.
  • the general system firmware has operating system basic functions such as camera scanning, network connection, touch drive, print and card reading.
  • the general system firmware has optional customization features such as application installation verification or customer privilege determination.
  • the terminal can automatically load the general system firmware from the system firmware partition into the internal memory during startup.
  • S304 Read configuration information in the customized resource partition by using the running general system firmware.
  • the custom resource partition is a partition in the memory of the terminal for storing configuration information and custom resources.
  • the custom resource partition can be in the same or a different storage medium than the system firmware partition.
  • Configuration information is information that is required to configure the functionality of a custom system based on common system firmware.
  • the terminal when running the general system firmware, can read the configuration information in the custom resource partition from the file of the custom resource partition by code instructions in the general system firmware.
  • the custom properties are properties that can be customized based on the general system firmware to implement a custom system. Based on different custom properties, different system code executions can be selected from the general system firmware to implement different customization functions.
  • a custom attribute ID is used to uniquely identify the corresponding custom attribute.
  • the custom attribute ID can be a customer name or a customer name code.
  • the customer name such as "ccb" is the English abbreviation of China Construction Bank.
  • the configuration information contains a custom attribute identifier.
  • the code execution path is the path executed by the system code that implements the customization function in the general system firmware. Different code execution paths enable different customization functions.
  • the general-purpose system firmware integrates the system code required to implement various custom systems. Different code execution paths allow different system codes to be selected and executed to implement different customization functions.
  • the terminal can read the configuration information in the customized resource partition, obtain the customized attribute identifier in the configuration information, and obtain the customized attribute identifier input path judgment condition when running the path judgment condition when running the general system firmware. Judging, thereby determining a code execution path corresponding to the acquired custom attribute identifier. For example, if the customized attribute identifier acquired by the terminal is “ccb”, the terminal selects a corresponding code execution path that determines that the condition matches the customized attribute identifier “ccb”.
  • the system code is the code that can achieve specific functions.
  • the terminal selects the corresponding system code from the general system firmware according to the selected determined code execution path and executes the logic execution code of the code according to the code.
  • S312 Load the customized resource from the customized resource partition by executing the system code.
  • custom resources are resources that can be customized in a custom system, such as customized boot animations, customized background images, or customized applications.
  • Customized applications can be configured to boot by default.
  • the terminal loads the customized resource in the customized resource partition by executing the system code corresponding to the code execution path selected in the general system firmware, so as to implement the customization function of the customized system.
  • the above customized system implementation method performs the customization of the system by executing the corresponding system code and loading the customized resource by reading the configuration information in the customized resource partition when running the general system firmware. Because the customization system of different customers is completed by the common system firmware and the customized resource package corresponding to the customer's requirements. After the development of the general-purpose system firmware, it can be used repeatedly, so that in the development of customized systems for different customers' different needs, it is only necessary to develop a customized resource package corresponding to the customer's requirements to complete the customized system, and the development efficiency of a customized resource package. It is much higher than the development efficiency of a system firmware, which improves the publishing efficiency of the customized system.
  • the customized system implementation method further includes a customized system configuration step, where the customized system configuration step specifically includes:
  • the terminal can obtain general system firmware from the server via a USB interface or a network connection.
  • the terminal can directly burn the acquired general system firmware to the system firmware partition through the burning tool.
  • the terminal can transmit the obtained general system firmware to the internal memory of the terminal through a hardware interface and related software, and then use a U-boot (Universal Boot Loader) command.
  • the generic system firmware is written to the system firmware partition.
  • the terminal may obtain a customized resource package from the server through a communication manner such as a USB interface connection or a network connection.
  • the terminal can parse the configuration information and the customized resource from the customized resource package, so that the configuration information and the customized resource are directly burned to the customized resource partition through the burning tool.
  • the terminal hardware device can be reset and the terminal operating system can be initialized by disconnecting the power of the terminal and re-supplying the power.
  • the configuration of the customized system is completed by acquiring and writing the general system firmware to the system firmware partition, acquiring the customized resource package, and writing the configuration information and the customized resource in the customized resource package to the customized resource partition.
  • the implementation of the system implementation method provides a physical basis.
  • the customized system configuration step further includes:
  • the digital signature is data for information authentication.
  • Information authentication may specifically be the identification of the source and integrity of a customized resource bundle.
  • Digital signatures can be generated by private key encryption, where the private key is a private key.
  • the public key is the public key corresponding to the private key.
  • the server may encrypt the summary information of the customized resource bundle with a private key to obtain a digital signature.
  • the terminal obtains the digital signature and the public key corresponding to the private key from the customized resource package by acquiring the customized resource package.
  • S510 Perform a verification after decrypting the digital signature according to the public key.
  • the verification of the digital signature is to verify the legality of the digital signature.
  • the verification is complete without tampering by indicating that the information of the custom resource bundle is complete.
  • the terminal decrypts the summary information of the encrypted custom resource package by using the public key, and then generates a summary information for the received customized resource package by using a hash function, and passes the summary information of the received customized resource package.
  • the summary information of the public key decryption is compared. If they are the same, the digital signature verification of the customized resource package is verified; if not, the digital signature of the customized resource package is verified. The test will not pass.
  • the information of the customized resource package is completely falsified.
  • the public key in the customized resource package is consistent with the public key in the general system firmware, the custom resource package and the general system firmware source are indicated. Consistent.
  • the information integrity of the customized resource package is not tampered.
  • the public key in the customized resource package is consistent with the public key in the general system firmware, the customized resource package is described.
  • the common system firmware source is consistent, thus ensuring the security of the customized system.
  • the customized system implementation method further includes: obtaining a default code execution path from the general system firmware when there is no configuration information in the custom resource partition; and executing the path according to the default code, from the general Select the system code in the system firmware and execute it.
  • the default code execution path is the path that the system code executes in the general system firmware when the system does not have a custom function. Specifically, when the general system firmware is run, when the configuration information is not read from the file of the custom resource partition by the code instruction in the general system firmware, the selection condition of the default code execution path in the general system firmware is satisfied, then the terminal is The code is selected from the general system firmware and executed by the logic of the default code execution path.
  • the default code path is selected and the system code is loaded, and the common system function can be implemented to complete the implementation of the non-custom system.
  • the customized system implementation method further includes a general system firmware testing step
  • the specific system firmware testing step specifically includes: writing the general system firmware in the system firmware partition, and keeping the custom resource partition empty; When there is no configuration information in the custom resource partition, the default code execution path is obtained from the general system firmware; and the system code is selected and executed from the general system firmware according to the default code execution path.
  • the general system firmware testing step further includes:
  • S612 according to the default code execution path, select the system code from the general system firmware and execute.
  • the test of the general system firmware can be implemented by keeping the custom resource empty, obtaining the default code execution path from the general system firmware when executing the general system firmware, and executing the system code.
  • the customized system implementation method further includes a customized resource package testing step, where the customized resource package testing step specifically includes:
  • S708 Write, in the custom resource partition, configuration information and a corresponding customized resource in one of the plurality of custom resource packages.
  • S710 Read configuration information in the customized resource partition by running the general system firmware.
  • step S720 Determine whether all the customized resource packages are written in the round. If yes, execute step S722. If no, go to step S708.
  • the terminal may acquire a plurality of customized resource packages, and in the customized resource partition, write configuration information and corresponding customized resources in different customized resource packages in a round, and read the customized resource partition by running the general system firmware.
  • the configuration information in the configuration information obtain the customized attribute identifier in the configuration information, determine the code execution path according to the obtained customized attribute identifier, select the system code from the general system firmware according to the code execution path, and execute, through the executed system code, from the customized resource
  • the step of loading a custom resource in a partition tests the custom resource bundle written in the round.
  • the configuration order of the custom resource package and the write order of the custom resource may be the same as the order of obtaining the customized resource package. Therefore, it can also be a random write.
  • the custom resource package is written by round and the custom resource package is tested in turn to complete the test of the customized function of the customized system.
  • the customized system implementation method includes the following steps:
  • S808 Obtain a digital signature and a public key in the customized resource package.
  • step S816 the configuration information in the customized resource partition is read by the running general system firmware.
  • step S818 is performed; when the configuration information in the customized resource partition does not exist, step S826 is performed. .
  • S822 according to the code execution path, select the system code from the general system firmware and execute it.
  • the customized system implementation method ensures the security of the customized system by acquiring and verifying the customized resource package.
  • the general system firmware When running the general system firmware, read the configuration information in the custom resource partition to execute the corresponding system code and load the custom resources to customize the system. When there is no configuration information in the custom resource partition, select the default code path and load the system code to implement common system functions and implement non-custom system release. Because the customization system of different customers is completed by the common system firmware and the customized resource package corresponding to the customer's requirements. Universal system firmware can be used repeatedly after development and testing, so that in the development of customized systems for different customers' different needs, it is only necessary to develop and test custom resource packages corresponding to customer requirements to complete the customized system, and a custom resource package. of Development and testing efficiency is much higher than the development and testing efficiency of a system firmware, which improves the publishing efficiency of custom systems.
  • a computer apparatus comprising a memory and a processor, the memory comprising a system firmware partition and a custom resource partition, the memory storing computer readable instructions; and the computer readable instructions being executed by the processor such that the processor Performing the following steps: running the general system firmware in the system firmware partition; reading the configuration information in the customized resource partition by running the general system firmware; obtaining the customized attribute identifier in the configuration information; determining the code execution path according to the obtained customized attribute identifier; Follow the code execution path, select the system code from the general system firmware and execute it; and load the custom resource from the custom resource partition by executing the system code.
  • the above customized system implements the computer device, and reads the configuration information in the customized resource partition by running the general system firmware to execute the corresponding system code and load the customized resource to realize the customization of the system. Because the customization system of different customers is completed by the common system firmware and the customized resource package corresponding to the customer's requirements. After the development of the general-purpose system firmware, it can be used repeatedly, so that in the development of customized systems for different customers' different needs, it is only necessary to develop a customized resource package corresponding to the customer's requirements to complete the customized system, and the development efficiency of a customized resource package. It is much higher than the development efficiency of a system firmware, which improves the publishing efficiency of the customized system.
  • the computer readable instructions cause the processor to perform the following steps: obtaining general system firmware; writing the acquired general system firmware to the system firmware partition; obtaining customization before executing the general system firmware in the running system firmware partition a resource package; the configuration information in the custom resource package and the corresponding custom resource are written to the custom resource partition; and after the restart, the general system firmware in the running system firmware partition is executed.
  • the computer readable instructions cause the processor to perform the step of obtaining a digital signature in the custom resource bundle and before executing the writing of the configuration information and the corresponding customized resource in the customized resource bundle to the custom resource partition.
  • the public key; the digital signature is decrypted according to the public key and verified; and when the verification passes, and the public key is consistent with the public key of the digital signature generated in the general system firmware, the configuration information and corresponding customization in the customized resource package are executed. Resources are written to the custom resource partition.
  • the computer readable instructions cause the processor to perform the following steps after performing configuration information in the customized resource partition by executing the running general system firmware: when customizing the resource When there is no configuration information in the partition, the default code execution path is obtained from the general system firmware; and the system code is selected and executed from the general system firmware according to the default code execution path.
  • the computer readable instructions are executed by the processor such that the processor further performs the following general system firmware testing steps: writing general system firmware in the system firmware partition and keeping the custom resource partition empty; running system firmware Common system firmware in the partition; read configuration information in the custom resource partition by running the general system firmware; obtain the default code execution path from the general system firmware when there is no configuration information in the custom resource partition; and execute according to the default code Path, select the system code from the general system firmware and execute it.
  • the processor when the computer readable instructions are executed by the processor, the processor further performs the following steps to test the custom resource bundle: in the custom resource partition, the configuration of the round custom writes in the different custom resource bundles Information and corresponding custom resources, read the configuration information in the custom resource partition by running the general system firmware, obtain the customized attribute identifier in the configuration information, determine the code execution path according to the obtained customized attribute identifier, follow the code execution path, from the general system The system code is selected and executed in the firmware. The steps of loading the custom resource from the custom resource partition by executing the system code respectively test the custom resource package written in the round.
  • one or more non-transitory computer readable storage media storing computer readable instructions are provided, the computer readable instructions being executed by one or more processors such that the one Or the plurality of processors perform the following steps: running the general system firmware in the system firmware partition; reading the configuration information in the custom resource partition by running the general system firmware; obtaining the customized attribute identifier in the configuration information; and identifying the customized attribute according to the obtained Determining the code execution path; selecting the system code from the general system firmware and executing it according to the code execution path; and loading the custom resource from the custom resource partition by executing the system code.
  • the computer readable instructions cause the processor to perform the following steps: obtaining general system firmware; writing the acquired general system firmware to the system firmware partition; obtaining customization before executing the general system firmware in the running system firmware partition a resource package; the configuration information in the custom resource package and the corresponding custom resource are written to the custom resource partition; and after the restart, the general system firmware in the running system firmware partition is executed.
  • the computer readable instructions cause the processor to execute in a custom resource bundle Before the configuration information and the corresponding customized resources are written to the custom resource partition, the following steps are performed: obtaining the digital signature and the public key in the customized resource package; performing the verification after decrypting the digital signature according to the public key; and when the verification passes, and When the public key is consistent with the public key for generating the digital signature in the general system firmware, the configuration information and the corresponding customized resource in the customized resource package are written to the custom resource partition.
  • the computer readable instructions cause the processor to perform the following steps after performing configuration information in the customized resource partition by running the running general system firmware: when there is no configuration information in the custom resource partition, Obtain the default code execution path in the system firmware; and select the system code from the general system firmware and execute it according to the default code execution path.
  • the computer readable instructions are executed by the processor such that the processor further performs the following general system firmware testing steps: writing general system firmware in the system firmware partition and keeping the custom resource partition empty; running system firmware Common system firmware in the partition; read configuration information in the custom resource partition by running the general system firmware; obtain the default code execution path from the general system firmware when there is no configuration information in the custom resource partition; and execute according to the default code Path, select the system code from the general system firmware and execute it.
  • the processor when the computer readable instructions are executed by the processor, the processor further performs the following steps to test the custom resource bundle: in the custom resource partition, the configuration of the round custom writes in the different custom resource bundles Information and corresponding custom resources, read the configuration information in the custom resource partition by running the general system firmware, obtain the customized attribute identifier in the configuration information, determine the code execution path according to the obtained customized attribute identifier, follow the code execution path, from the general system The system code is selected and executed in the firmware. The steps of loading the custom resource from the custom resource partition by executing the system code respectively test the custom resource package written in the round.
  • the computer readable storage medium described above reads the configuration information in the custom resource partition by executing the general system firmware to execute the corresponding system code and load the customized resource to implement customization of the system. Because the customization system of different customers is completed by the common system firmware and the customized resource package corresponding to the customer's requirements. After the development of the general-purpose system firmware, it can be used repeatedly, so that in the development of customized systems for different customers' different needs, it is only necessary to develop a customized resource package corresponding to the customer's requirements to complete the customized system, and the development efficiency of a customized resource package. It is much higher than the development efficiency of a system firmware, which improves the publishing efficiency of the customized system.
  • the storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM), or the like.

Abstract

Provided is a method for implementing a custom system, comprising: running a common system firmware in a system firmware partition; by means of the run common system firmware, reading configuration information in a custom resource partition; obtaining a custom attribute identifier in said configuration information; according to the obtained custom attribute identifier, determining a code execution path; according to said code execution path, selecting a system code from the common system firmware and running said code; by means of the executed system code, loading a custom resource from the custom resource partition.

Description

定制系统实现方法、计算机设备和计算机可读存储介质Customized system implementation method, computer device, and computer readable storage medium
本申请要求于2017年06月15日提交中国专利局、申请号为201710453248.7、发明名称为“定制系统实现方法、计算机设备和存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese Patent Application filed on June 15, 2017, the Chinese Patent Office, Application No. 201710453248.7, entitled "Customized System Implementation Method, Computer Equipment, and Storage Media", the entire contents of which are incorporated by reference. In this application.
技术领域Technical field
本申请涉及计算机技术领域,特别是涉及一种定制系统实现方法、计算机设备和计算机可读存储介质。The present application relates to the field of computer technology, and in particular, to a customized system implementation method, a computer device, and a computer readable storage medium.
背景技术Background technique
对于同一个产品,可能有不同的客户,而不同的客户可能有不同需求,为满足不同客户的不同需求,往往需要发布不同客户的定制系统。比如,同一个POS机(Point of Sale,销售终端)产品,可能有来自中国银行、中国建设银行或中国农业银行等不同客户的定制,定制内容比如有开机动画,系统菜单定制,或安装内置app(Application,计算机应用程序)等等。传统的解决方式是当需要根据不同客户的不同需求而定制系统时,需针对不同客户的不同需求发布不同版本系统固件的系统以满足客户需求。For the same product, there may be different customers, and different customers may have different needs. In order to meet the different needs of different customers, it is often necessary to release customized systems for different customers. For example, the same POS (Point of Sale) product may be customized from different customers such as Bank of China, China Construction Bank or Agricultural Bank of China. Customized content such as boot animation, system menu customization, or installation of built-in app. (Application, computer application) and so on. The traditional solution is to release a system with different versions of system firmware to meet customer needs when different systems need to be customized according to the different needs of different customers.
然而基于传统的针对不同客户的不同需求发布不同版本系统固件的系统的方法,使得每个不同版本的系统固件都需要从头到尾的开发,从而导致定制系统发布效率低。However, based on the traditional method of releasing systems of different versions of system firmware for different customers' different needs, each different version of the system firmware needs to be developed from beginning to end, resulting in low efficiency of customized system publishing.
发明内容Summary of the invention
根据本申请的各种实施例,提供一种定制系统实现方法、计算机设备和计算机可读存储介质。In accordance with various embodiments of the present application, a customization system implementation method, computer apparatus, and computer readable storage medium are provided.
一种定制系统实现方法,包括:A customized system implementation method, including:
运行系统固件分区中的通用系统固件; Run the general system firmware in the system firmware partition;
通过运行的通用系统固件读取定制资源分区中的配置信息;Reading configuration information in a custom resource partition by running a generic system firmware;
获取所述配置信息中的定制属性标识;Obtaining a customized attribute identifier in the configuration information;
根据获取的定制属性标识确定代码执行路径;Determining a code execution path according to the obtained custom attribute identifier;
按照所述代码执行路径,从所述通用系统固件中选择系统代码并执行;及Selecting a system code from the general system firmware and executing according to the code execution path; and
通过执行的所述系统代码,从所述定制资源分区中加载定制资源。A custom resource is loaded from the custom resource partition by the system code executed.
一种计算机设备,包括存储器和处理器,所述存储器包括系统固件分区和定制资源分区,所述存储器存储有计算机可读指令,所述计算机可读指令被所述处理器执行时,使得所述处理器执行如下步骤:A computer device comprising a memory and a processor, the memory comprising a system firmware partition and a custom resource partition, the memory storing computer readable instructions, the computer readable instructions being executed by the processor such that The processor performs the following steps:
运行系统固件分区中的通用系统固件;Run the general system firmware in the system firmware partition;
通过运行的通用系统固件读取定制资源分区中的配置信息;Reading configuration information in a custom resource partition by running a generic system firmware;
获取所述配置信息中的定制属性标识;Obtaining a customized attribute identifier in the configuration information;
根据获取的定制属性标识确定代码执行路径;Determining a code execution path according to the obtained custom attribute identifier;
按照所述代码执行路径,从所述通用系统固件中选择系统代码并执行;及Selecting a system code from the general system firmware and executing according to the code execution path; and
通过执行的所述系统代码,从所述定制资源分区中加载定制资源。A custom resource is loaded from the custom resource partition by the system code executed.
一个或多个存储有计算机可读指令的非易失性的计算机可读存储介质,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器执行以下步骤:One or more non-transitory computer readable storage mediums storing computer readable instructions, when executed by one or more processors, cause the one or more processors to perform the following steps :
运行系统固件分区中的通用系统固件;Run the general system firmware in the system firmware partition;
通过运行的通用系统固件读取定制资源分区中的配置信息;Reading configuration information in a custom resource partition by running a generic system firmware;
获取所述配置信息中的定制属性标识;Obtaining a customized attribute identifier in the configuration information;
根据获取的定制属性标识确定代码执行路径;Determining a code execution path according to the obtained custom attribute identifier;
按照所述代码执行路径,从所述通用系统固件中选择系统代码并执行;及Selecting a system code from the general system firmware and executing according to the code execution path; and
通过执行的所述系统代码,从所述定制资源分区中加载定制资源。A custom resource is loaded from the custom resource partition by the system code executed.
本申请的一个或多个实施例的细节在下面的附图和描述中提出。本申请的其它特征、目的和优点将从说明书、附图以及权利要求书变得明显。 Details of one or more embodiments of the present application are set forth in the accompanying drawings and description below. Other features, objects, and advantages of the invention will be apparent from the description and appended claims.
附图说明DRAWINGS
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings used in the description of the embodiments will be briefly described below. It is obvious that the drawings in the following description are only some embodiments of the present application. Other drawings may also be obtained from those of ordinary skill in the art in light of the inventive work.
图1为一个实施例中定制系统实现方法应用环境图;1 is an application environment diagram of a method for implementing a customized system in an embodiment;
图2为一个实施例中终端的内部结构示意图;2 is a schematic diagram showing the internal structure of a terminal in an embodiment;
图3为一个实施例中定制系统实现方法的流程示意图;3 is a schematic flow chart of a method for implementing a customized system in an embodiment;
图4为一个实施例中定制系统配置步骤的流程示意图;4 is a schematic flow chart of a configuration procedure of a customized system in an embodiment;
图5为另一个实施例中定制系统配置步骤的流程示意图;5 is a schematic flow chart of a configuration procedure of a customized system in another embodiment;
图6为一个实施例中通用系统固件测试步骤的流程示意图;6 is a schematic flow chart of a firmware testing procedure of a general system in an embodiment;
图7为一个实施例中定制资源包测试步骤的流程示意图;7 is a schematic flowchart of a custom resource package testing step in an embodiment;
图8为另一个实施例中定制系统实现方法的流程示意图。FIG. 8 is a schematic flow chart of a method for implementing a customized system in another embodiment.
具体实施方式detailed description
为了使本申请的技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处所描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。In order to make the technical solutions and advantages of the present application more clear, the present application will be further described in detail below with reference to the accompanying drawings and embodiments. It is understood that the specific embodiments described herein are merely illustrative of the application and are not intended to be limiting.
图1为一个实施例中定制系统实现方法的应用环境图。如图1所示,该应用环境包括终端110和服务器120。其中,终端可以是POS机、移动手机、平板电脑等;服务器可以是独立的物理服务器,也可以是多个物理服务器构成的服务器集群。终端110可以执行定制系统实现方法,利用系统固件分区中的通用系统固件,结合定制资源分区中的配置信息及相应的定制资源,实现定制系统。终端110可从服务器120获取通用系统固件并写入到系统固件分区中。终端110可从服务器120获取定制资源包,并将定制资源包中的定制资源及相应的配置信息写入到定制资源分区中。本领域技术人员可以理解,图1中示出的应用环境,仅仅是与本申请方案相关的部分场景,并不构成对本申请方案 应用环境的限定。FIG. 1 is an application environment diagram of a method for implementing a customized system in an embodiment. As shown in FIG. 1, the application environment includes a terminal 110 and a server 120. The terminal may be a POS machine, a mobile phone, a tablet computer, or the like; the server may be an independent physical server or a server cluster composed of multiple physical servers. The terminal 110 can execute a customized system implementation method, and utilizes general system firmware in the system firmware partition, combined with configuration information in the customized resource partition and corresponding customized resources to implement the customized system. Terminal 110 can obtain general system firmware from server 120 and write to the system firmware partition. The terminal 110 may acquire a customized resource package from the server 120, and write the customized resource and corresponding configuration information in the customized resource package into the customized resource partition. Those skilled in the art can understand that the application environment shown in FIG. 1 is only a part of the scenario related to the solution of the present application, and does not constitute a solution to the present application. The definition of the application environment.
图2为一个实施例中终端的内部结构示意图。如图2所示,该终端包括通过系统总线连接的处理器、非易失性存储介质、内存储器、摄像头、显示屏、USB接口和网络接口。其中,服务器的非易失性存储介质包括系统固件分区和定制资源分区,可存储有计算机可读指令,该计算机可读指令被处理器执行时,可使得处理器实现定制系统实现方法。该处理器用于提供计算和控制能力,支撑整个终端的运行。该内存储器中也可储存有计算机可读指令,该计算机可读指令被所述处理器执行时,可使得所述处理器执行定制系统实现方法。本领域技术人员可以理解,图2中示出的结构,仅仅是与本申请方案相关的部分结构的框图,并不构成对本申请方案所应用于其上的终端的限定,具体的终端可以包括比图中所示更多或更少的部件,或者组合某些部件,或者具有不同的部件布置。FIG. 2 is a schematic diagram showing the internal structure of a terminal in an embodiment. As shown in FIG. 2, the terminal includes a processor connected through a system bus, a non-volatile storage medium, an internal memory, a camera, a display screen, a USB interface, and a network interface. The non-volatile storage medium of the server includes a system firmware partition and a custom resource partition, and can store computer readable instructions that, when executed by the processor, enable the processor to implement a custom system implementation method. The processor is used to provide computing and control capabilities to support the operation of the entire terminal. Also stored in the internal memory is computer readable instructions that, when executed by the processor, cause the processor to perform a custom system implementation. It will be understood by those skilled in the art that the structure shown in FIG. 2 is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the terminal to which the solution of the present application is applied. The specific terminal may include a ratio. More or fewer components are shown in the figures, or some components are combined, or have different component arrangements.
如图3所示,在一个实施例中,提供了一种定制系统实现方法。本实施例主要以该方法应用于上述图2中的终端来举例说明。参照图3,该定制系统实现方法具体包括如下步骤:As shown in FIG. 3, in one embodiment, a custom system implementation method is provided. This embodiment is mainly illustrated by applying the method to the terminal in FIG. 2 described above. Referring to FIG. 3, the customized system implementation method specifically includes the following steps:
S302,运行系统固件分区中的通用系统固件。S302. Run the general system firmware in the system firmware partition.
其中,系统固件分区是终端的存储器中用于存储通用系统固件的分区。系统固件是实现操作系统功能的固件。通用系统固件是实现不同的定制系统所公用的系统固件。通用系统固件可以是通用的Android(安卓)系统固件。通用系统固件具有操作系统基础功能,如摄像头扫描功能、网络连接功能、触控驱动功能、打印功能和读卡功能等。通用系统固件具备可选择的定制功能,如应用程序安装校验功能或者客户权限判定功能等。终端可在启动过程中自动从系统固件分区加载通用系统固件到内存储器中运行。The system firmware partition is a partition in the terminal's memory for storing general system firmware. System firmware is firmware that implements operating system functions. The general system firmware is the system firmware that is implemented by different custom systems. The general system firmware can be a generic Android (Android) system firmware. The general system firmware has operating system basic functions such as camera scanning, network connection, touch drive, print and card reading. The general system firmware has optional customization features such as application installation verification or customer privilege determination. The terminal can automatically load the general system firmware from the system firmware partition into the internal memory during startup.
S304,通过运行的通用系统固件读取定制资源分区中的配置信息。S304: Read configuration information in the customized resource partition by using the running general system firmware.
其中,定制资源分区是终端的存储器中用于存储配置信息和定制资源的分区。定制资源分区可以与系统固件分区处于相同或者不同的存储介质中。配置信息是基于通用系统固件实现定制系统的功能所需配置的信息。 The custom resource partition is a partition in the memory of the terminal for storing configuration information and custom resources. The custom resource partition can be in the same or a different storage medium than the system firmware partition. Configuration information is information that is required to configure the functionality of a custom system based on common system firmware.
在一个实施例中,当运行通用系统固件时,终端可通过通用系统固件中的代码指令从定制资源分区的文件中读取定制资源分区中的配置信息。In one embodiment, when running the general system firmware, the terminal can read the configuration information in the custom resource partition from the file of the custom resource partition by code instructions in the general system firmware.
S306,获取配置信息中的定制属性标识。S306. Obtain a customized attribute identifier in the configuration information.
其中,定制属性是基于通用系统固件实现定制系统时可定制的属性。基于不同的定制属性,可以从通用系统固件中选择不同的系统代码执行,以实现不同的定制功能。定制属性标识用于唯一标识相应的定制属性。定制属性标识可以是客户名称或客户名称编码。客户名称比如“ccb”,是中国建设银行的英文缩写。配置信息中包含有定制属性标识。Among them, the custom properties are properties that can be customized based on the general system firmware to implement a custom system. Based on different custom properties, different system code executions can be selected from the general system firmware to implement different customization functions. A custom attribute ID is used to uniquely identify the corresponding custom attribute. The custom attribute ID can be a customer name or a customer name code. The customer name such as "ccb" is the English abbreviation of China Construction Bank. The configuration information contains a custom attribute identifier.
举例说明,定制资源分区中的配置信息包括“ro.customer.name=ccb”,其中“ro.customer.name”表示定制属性字段,“ccb”则是定制属性的值,表示定制属性标识。终端可通过读取定制资源分区中定制属性字段“ro.customer.name=ccb”的值“ccb”来获取定制属性标识。For example, the configuration information in the custom resource partition includes "ro.customer.name=ccb", where "ro.customer.name" represents a custom attribute field, and "ccb" is a value of a custom attribute, indicating a custom attribute identifier. The terminal can obtain the customized attribute identifier by reading the value "ccb" of the custom attribute field "ro.customer.name=ccb" in the custom resource partition.
308,根据获取的定制属性标识确定代码执行路径。308. Determine a code execution path according to the obtained customized attribute identifier.
其中,代码执行路径是通用系统固件中实现定制功能的系统代码所执行的路径。不同的代码执行路径可实现不同的定制功能。通用系统固件集成了实现各种定制系统所需的系统代码,通过不同的代码执行路径可以选择不同的系统代码并执行,以实现不同的定制功能。The code execution path is the path executed by the system code that implements the customization function in the general system firmware. Different code execution paths enable different customization functions. The general-purpose system firmware integrates the system code required to implement various custom systems. Different code execution paths allow different system codes to be selected and executed to implement different customization functions.
具体地,终端可在运行通用系统固件时,在运行到路径判断条件时,读取定制资源分区中的配置信息,获取配置信息中的定制属性标识,将获取的定制属性标识输入路径判断条件进行判断,从而确定与获取的定制属性标识对应的代码执行路径。举例说明,比如该终端获取的定制属性标识为“ccb”,则该终端选择判断条件与定制属性标识“ccb”相符的对应的代码执行路径。Specifically, the terminal can read the configuration information in the customized resource partition, obtain the customized attribute identifier in the configuration information, and obtain the customized attribute identifier input path judgment condition when running the path judgment condition when running the general system firmware. Judging, thereby determining a code execution path corresponding to the acquired custom attribute identifier. For example, if the customized attribute identifier acquired by the terminal is “ccb”, the terminal selects a corresponding code execution path that determines that the condition matches the customized attribute identifier “ccb”.
S310,按照代码执行路径,从通用系统固件中选择系统代码并执行。S310. Select a system code from the general system firmware and execute according to the code execution path.
其中,系统代码是能实现具体功能的代码。具体地,终端根据已选择的确定的代码执行路径,从通用系统固件中选择对应的系统代码并按代码执行路径的逻辑执行代码。Among them, the system code is the code that can achieve specific functions. Specifically, the terminal selects the corresponding system code from the general system firmware according to the selected determined code execution path and executes the logic execution code of the code according to the code.
S312,通过执行的系统代码,从定制资源分区中加载定制资源。 S312: Load the customized resource from the customized resource partition by executing the system code.
其中,定制资源是定制系统中能实现定制功能的资源,比如定制的开机动画、定制的背景图片或者定制的应用程序等。定制的应用程序可以配置为默认开机启动。Among them, custom resources are resources that can be customized in a custom system, such as customized boot animations, customized background images, or customized applications. Customized applications can be configured to boot by default.
具体地,终端通过执行通用系统固件中选择的与代码执行路径相对应的系统代码,加载定制资源分区中的定制资源,实现定制系统的定制功能。Specifically, the terminal loads the customized resource in the customized resource partition by executing the system code corresponding to the code execution path selected in the general system firmware, so as to implement the customization function of the customized system.
上述定制系统实现方法,通过运行通用系统固件时读取定制资源分区中的配置信息来执行对应系统代码并加载定制资源,实现系统的定制。由于不同客户的定制系统都是由通用系统固件和对应客户需求的定制资源包共同完成的。通用系统固件开发完成后可反复使用,使得在针对不同客户的不同需求的定制系统开发中,只需再开发出对应客户需求的定制资源包即可完成定制系统,而一个定制资源包的开发效率远高于一个系统固件的开发效率,从而提高了定制系统的发布效率。The above customized system implementation method performs the customization of the system by executing the corresponding system code and loading the customized resource by reading the configuration information in the customized resource partition when running the general system firmware. Because the customization system of different customers is completed by the common system firmware and the customized resource package corresponding to the customer's requirements. After the development of the general-purpose system firmware, it can be used repeatedly, so that in the development of customized systems for different customers' different needs, it is only necessary to develop a customized resource package corresponding to the customer's requirements to complete the customized system, and the development efficiency of a customized resource package. It is much higher than the development efficiency of a system firmware, which improves the publishing efficiency of the customized system.
如图4所示,在一个实施例中,在步骤S302之前,该定制系统实现方法还包括定制系统配置步骤,定制系统配置步骤具体包括:As shown in FIG. 4, in an embodiment, before the step S302, the customized system implementation method further includes a customized system configuration step, where the customized system configuration step specifically includes:
S402,获取通用系统固件。S402. Acquire general system firmware.
在一个实施例中,终端可以通过USB接口连接或网络连接等通信方式从服务器获取通用系统固件。In one embodiment, the terminal can obtain general system firmware from the server via a USB interface or a network connection.
S404,将获取的通用系统固件写入系统固件分区。S404. Write the obtained general system firmware to the system firmware partition.
在一个实施例中,终端可将获取的通用系统固件通过烧录工具直接烧录到系统固件分区上。In one embodiment, the terminal can directly burn the acquired general system firmware to the system firmware partition through the burning tool.
在另一个实施例中,终端可将获取到的通用系统固件通过硬件接口和相关软件传输到终端的内存储器中,再用U-boot(Universal Boot Loader,即系统启动的入口点)的命令将通用系统固件写入到系统固件分区。In another embodiment, the terminal can transmit the obtained general system firmware to the internal memory of the terminal through a hardware interface and related software, and then use a U-boot (Universal Boot Loader) command. The generic system firmware is written to the system firmware partition.
S406,获取定制资源包。S406. Obtain a customized resource package.
在一个实施例中,终端可以通过USB接口连接或网络连接等通信方式从服务器获取定制资源包。In an embodiment, the terminal may obtain a customized resource package from the server through a communication manner such as a USB interface connection or a network connection.
S408,将定制资源包中的配置信息和相应的定制资源写入到定制资源分 区。S408. Write configuration information and corresponding customized resources in the customized resource package to the customized resource. Area.
在一个实施例中,终端可从定制资源包中解析出配置信息和定制资源,从而将配置信息和定制资源通过烧录工具直接烧录到定制资源分区。In one embodiment, the terminal can parse the configuration information and the customized resource from the customized resource package, so that the configuration information and the customized resource are directly burned to the customized resource partition through the burning tool.
S410,重启该终端。S410, restart the terminal.
具体地,可通过断开该终端电源,再重新供给电源后复位该终端硬件设备并初始化该终端操作系统。Specifically, the terminal hardware device can be reset and the terminal operating system can be initialized by disconnecting the power of the terminal and re-supplying the power.
在本实施例中,通过获取和写入通用系统固件到系统固件分区,获取定制资源包并将定制资源包中的配置信息和定制资源写入到定制资源分区,完成定制系统的配置,为定制系统实现方法的实施提供了物理基础。In this embodiment, the configuration of the customized system is completed by acquiring and writing the general system firmware to the system firmware partition, acquiring the customized resource package, and writing the configuration information and the customized resource in the customized resource package to the customized resource partition. The implementation of the system implementation method provides a physical basis.
如图5所示,在一个实施例中,定制系统配置步骤还包括:As shown in FIG. 5, in an embodiment, the customized system configuration step further includes:
S502,获取通用系统固件。S502. Obtain general system firmware.
S504,将获取的通用系统固件写入系统固件分区。S504. Write the obtained general system firmware to the system firmware partition.
S506,获取定制资源包。S506. Obtain a customized resource package.
S508,获取定制资源包中的数字签名和公钥。S508. Obtain a digital signature and a public key in the customized resource package.
其中,数字签名是进行信息鉴别的数据。信息鉴别具体可以是对定制资源包的来源和完整性的鉴别。数字签名可通过私钥加密方式生成,其中私钥是私用密钥。公钥是与私钥相对应的公开的密匙。Among them, the digital signature is data for information authentication. Information authentication may specifically be the identification of the source and integrity of a customized resource bundle. Digital signatures can be generated by private key encryption, where the private key is a private key. The public key is the public key corresponding to the private key.
在一个实施例中,服务器可对定制资源包的摘要信息用私钥加密得到数字签名。终端通过获取定制资源包,从定制资源包中获取数字签名和与私钥对应的公钥。In one embodiment, the server may encrypt the summary information of the customized resource bundle with a private key to obtain a digital signature. The terminal obtains the digital signature and the public key corresponding to the private key from the customized resource package by acquiring the customized resource package.
S510,根据公钥解密数字签名后进行校验。S510: Perform a verification after decrypting the digital signature according to the public key.
其中,对数字签名进行校验,是对数字签名的合法性进行检验。校验通过说明定制资源包的信息完整未被篡改。Among them, the verification of the digital signature is to verify the legality of the digital signature. The verification is complete without tampering by indicating that the information of the custom resource bundle is complete.
在一个实施例中,终端使用公钥解密被加密的定制资源包的摘要信息,然后用哈希函数对收到的定制资源包产生一个摘要信息,将收到的定制资源包的摘要信息与通过公钥解密的摘要信息比对,如果相同,则说明对定制资源包的数字签名校验通过;如果不相同,则说明对定制资源包的数字签名校 验不通过。In one embodiment, the terminal decrypts the summary information of the encrypted custom resource package by using the public key, and then generates a summary information for the received customized resource package by using a hash function, and passes the summary information of the received customized resource package. The summary information of the public key decryption is compared. If they are the same, the digital signature verification of the customized resource package is verified; if not, the digital signature of the customized resource package is verified. The test will not pass.
S512,当校验通过、且公钥与生成通用系统固件中数字签名的公钥一致时,将定制资源包中的配置信息和相应的定制资源写入到定制资源分区。S512. When the verification passes, and the public key is consistent with the public key of the digital signature generated in the general system firmware, the configuration information in the customized resource package and the corresponding customized resource are written to the customized resource partition.
其中,当对定制资源包校验通过后,说明定制资源包的信息完整未被篡改,当定制资源包中的公钥与通用系统固件中的公钥一致时说明定制资源包与通用系统固件来源一致。After the verification of the customized resource package is completed, the information of the customized resource package is completely falsified. When the public key in the customized resource package is consistent with the public key in the general system firmware, the custom resource package and the general system firmware source are indicated. Consistent.
S514,重启该终端。S514, restart the terminal.
在本实施例中,通过校验定制资源包的数字签名保证了定制资源包的信息完整未被篡改,当定制资源包中的公钥与通用系统固件中的公钥一致时说明定制资源包与通用系统固件来源一致,从而保证了定制系统的安全。In this embodiment, by verifying the digital signature of the customized resource package, the information integrity of the customized resource package is not tampered. When the public key in the customized resource package is consistent with the public key in the general system firmware, the customized resource package is described. The common system firmware source is consistent, thus ensuring the security of the customized system.
在一个实施例中,在步骤S304之后,该定制系统实现方法还包括:当定制资源分区中不存在配置信息时,从通用系统固件中获取默认代码执行路径;及按照默认代码执行路径,从通用系统固件中选择系统代码并执行。In an embodiment, after step S304, the customized system implementation method further includes: obtaining a default code execution path from the general system firmware when there is no configuration information in the custom resource partition; and executing the path according to the default code, from the general Select the system code in the system firmware and execute it.
其中,默认代码执行路径是当系统没有定制功能时通用系统固件中系统代码所执行的路径。具体地,当运行通用系统固件时,通过通用系统固件中的代码指令从定制资源分区的文件中未读取到配置信息时,则满足通用系统固件中默认代码执行路径的选择条件,则该终端从通用系统固件中选择系统代码并按默认代码执行路径的逻辑执行该代码。The default code execution path is the path that the system code executes in the general system firmware when the system does not have a custom function. Specifically, when the general system firmware is run, when the configuration information is not read from the file of the custom resource partition by the code instruction in the general system firmware, the selection condition of the default code execution path in the general system firmware is satisfied, then the terminal is The code is selected from the general system firmware and executed by the logic of the default code execution path.
在本实施例中,当定制资源分区中不存在配置信息时,选择默认代码路径并加载系统代码,可实现普通系统功能,完成非定制系统的实现。In this embodiment, when there is no configuration information in the custom resource partition, the default code path is selected and the system code is loaded, and the common system function can be implemented to complete the implementation of the non-custom system.
在一个实施例中,步骤S304之后,该定制系统实现方法还包括通用系统固件测试步骤,通用系统固件测试步骤具体包括:在系统固件分区中写入通用系统固件,并保持定制资源分区为空;当定制资源分区中不存在配置信息时,从通用系统固件中获取默认代码执行路径;及按照默认代码执行路径,从通用系统固件中选择系统代码并执行。In an embodiment, after step S304, the customized system implementation method further includes a general system firmware testing step, the specific system firmware testing step specifically includes: writing the general system firmware in the system firmware partition, and keeping the custom resource partition empty; When there is no configuration information in the custom resource partition, the default code execution path is obtained from the general system firmware; and the system code is selected and executed from the general system firmware according to the default code execution path.
在一个实施例中,通用系统固件测试步骤还具体包括:In an embodiment, the general system firmware testing step further includes:
S602,获取通用系统固件。S602. Acquire general system firmware.
S604,将获取的通用系统固件写入系统固件分区。S604. Write the obtained general system firmware to the system firmware partition.
S606,运行系统固件分区中的通用系统固件。 S606. Run the general system firmware in the system firmware partition.
S608,通过运行的通用系统固件读取定制资源分区中的配置信息。S608. Read configuration information in the customized resource partition by running the general system firmware.
S610,当定制资源分区中不存在配置信息时,从通用系统固件中获取默认代码执行路径。S610: When there is no configuration information in the custom resource partition, obtain a default code execution path from the general system firmware.
S612,按照默认代码执行路径,从通用系统固件中选择系统代码并执行。S612, according to the default code execution path, select the system code from the general system firmware and execute.
在本实施例中,通过保持定制资源为空,运行通用系统固件时从通用系统固件中获取默认代码执行路径并执行系统代码可以实现对通用系统固件的测试。In this embodiment, the test of the general system firmware can be implemented by keeping the custom resource empty, obtaining the default code execution path from the general system firmware when executing the general system firmware, and executing the system code.
如图7所述,在一个实施例中,步骤S304之后,该定制系统实现方法还包括定制资源包测试步骤,定制资源包测试步骤具体包括:As shown in FIG. 7 , in an embodiment, after the step S304, the customized system implementation method further includes a customized resource package testing step, where the customized resource package testing step specifically includes:
S702,获取通用系统固件。S702. Acquire general system firmware.
S704,将获取的通用系统固件写入系统固件分区。S704. Write the obtained general system firmware to the system firmware partition.
S706,获取多个定制资源包。S706. Acquire multiple customized resource bundles.
S708,在定制资源分区中,写入多个定制资源包中其中一个定制资源包中的配置信息和相应的定制资源。S708: Write, in the custom resource partition, configuration information and a corresponding customized resource in one of the plurality of custom resource packages.
S710,通过运行的通用系统固件读取定制资源分区中的配置信息。S710: Read configuration information in the customized resource partition by running the general system firmware.
S712,获取配置信息中的定制属性标识。S712. Obtain a customized attribute identifier in the configuration information.
S714,根据获取的定制属性标识确定代码执行路径。S714. Determine a code execution path according to the obtained customized attribute identifier.
S716,按照代码执行路径,从通用系统固件中选择系统代码并执行。S716. Select a system code from the general system firmware and execute according to the code execution path.
S718,通过执行的系统代码,从定制资源分区中加载定制资源。S718: Load the customized resource from the customized resource partition by executing the system code.
S720,判断所有定制资源包是否均被轮次写入,若是,则执行步骤S722,若否,则跳转步骤S708。S720. Determine whether all the customized resource packages are written in the round. If yes, execute step S722. If no, go to step S708.
S722,结束定制资源包测试。S722, ending the custom resource package test.
在一个实施例中,终端可获取多个定制资源包,在定制资源分区中,轮次写入不同的定制资源包中的配置信息和相应的定制资源,通过运行通用系统固件读取定制资源分区中的配置信息,获取配置信息中的定制属性标识,根据获取的定制属性标识确定代码执行路径,按照代码执行路径,从通用系统固件中选择系统代码并执行,通过执行的系统代码,从定制资源分区中加载定制资源的步骤分别对轮次写入的定制资源包进行测试。其中,不同定制资源包中的配置信息和定制资源的写入顺序可以和获取定制资源包的顺序一 致,也可以是随机写入。In an embodiment, the terminal may acquire a plurality of customized resource packages, and in the customized resource partition, write configuration information and corresponding customized resources in different customized resource packages in a round, and read the customized resource partition by running the general system firmware. The configuration information in the configuration information, obtain the customized attribute identifier in the configuration information, determine the code execution path according to the obtained customized attribute identifier, select the system code from the general system firmware according to the code execution path, and execute, through the executed system code, from the customized resource The step of loading a custom resource in a partition tests the custom resource bundle written in the round. The configuration order of the custom resource package and the write order of the custom resource may be the same as the order of obtaining the customized resource package. Therefore, it can also be a random write.
在本实施例中,通过轮次写入定制资源包并轮次测试定制资源包,以完成对定制系统的定制功能的测试。In this embodiment, the custom resource package is written by round and the custom resource package is tested in turn to complete the test of the customized function of the customized system.
如图8所示,在一个具体实施例中,定制系统实现方法包括以下步骤:As shown in FIG. 8, in a specific embodiment, the customized system implementation method includes the following steps:
S802,获取通用系统固件。S802, obtaining general system firmware.
S804,将获取的通用系统固件写入系统固件分区。S804. Write the obtained general system firmware to the system firmware partition.
S806,获取定制资源包。S806, obtaining a customized resource package.
S808,获取定制资源包中的数字签名和公钥。S808: Obtain a digital signature and a public key in the customized resource package.
S810,根据公钥解密数字签名后进行校验。S810, after verifying the digital signature according to the public key, performing verification.
S812,当校验通过、且公钥与生成通用系统固件中数字签名的公钥一致时,将定制资源包中的配置信息和相应的定制资源写入到定制资源分区。S812: When the verification passes, and the public key is consistent with the public key of the digital signature generated in the general system firmware, the configuration information in the customized resource package and the corresponding customized resource are written to the customized resource partition.
S814,重启后,运行系统固件分区中的通用系统固件。S814, after restarting, running the general system firmware in the system firmware partition.
S816,通过运行的通用系统固件读取定制资源分区中的配置信息,当定制资源分区中的配置信息不为空时,执行步骤S818;当定制资源分区中的配置信息不存在时,执行步骤S826。S816, the configuration information in the customized resource partition is read by the running general system firmware. When the configuration information in the customized resource partition is not empty, step S818 is performed; when the configuration information in the customized resource partition does not exist, step S826 is performed. .
S818,获取配置信息中的定制属性标识。S818. Obtain a customized attribute identifier in the configuration information.
S820,根据获取的定制属性标识确定代码执行路径。S820. Determine a code execution path according to the obtained customized attribute identifier.
S822,按照代码执行路径,从通用系统固件中选择系统代码并执行。S822, according to the code execution path, select the system code from the general system firmware and execute it.
S824,通过执行的系统代码,从定制资源分区中加载定制资源。S824, loading the customized resource from the customized resource partition by executing the system code.
S826,从通用系统固件中获取默认代码执行路径。S826, obtaining a default code execution path from the general system firmware.
S828,按照默认代码执行路径,从通用系统固件中选择系统代码并执行。S828, according to the default code execution path, select the system code from the general system firmware and execute.
在本实施例中,定制系统实现方法,通过获取并校验定制资源包,保障了定制系统的安全性。运行通用系统固件时读取定制资源分区中的配置信息来执行对应系统代码并加载定制资源,实现系统的定制。当定制资源分区中不存在配置信息时,选择默认代码路径并加载系统代码,可实现普通系统功能,实现非定制系统发布。由于不同客户的定制系统都是由通用系统固件和对应客户需求的定制资源包共同完成的。通用系统固件开发和测试完成后可反复使用,使得在针对不同客户的不同需求的定制系统开发中,只需再开发和测试对应客户需求的定制资源包即可完成定制系统,而一个定制资源包的 开发和测试效率远高于一个系统固件的开发和测试效率,从而提高了定制系统的发布效率。In this embodiment, the customized system implementation method ensures the security of the customized system by acquiring and verifying the customized resource package. When running the general system firmware, read the configuration information in the custom resource partition to execute the corresponding system code and load the custom resources to customize the system. When there is no configuration information in the custom resource partition, select the default code path and load the system code to implement common system functions and implement non-custom system release. Because the customization system of different customers is completed by the common system firmware and the customized resource package corresponding to the customer's requirements. Universal system firmware can be used repeatedly after development and testing, so that in the development of customized systems for different customers' different needs, it is only necessary to develop and test custom resource packages corresponding to customer requirements to complete the customized system, and a custom resource package. of Development and testing efficiency is much higher than the development and testing efficiency of a system firmware, which improves the publishing efficiency of custom systems.
在一个实施例中,提供了一种计算机设备,包括存储器和处理器,存储器包括系统固件分区和定制资源分区,存储器存储有计算机可读指令;计算机可读指令被处理器执行时,使得处理器执行如下步骤:运行系统固件分区中的通用系统固件;通过运行的通用系统固件读取定制资源分区中的配置信息;获取配置信息中的定制属性标识;根据获取的定制属性标识确定代码执行路径;按照代码执行路径,从通用系统固件中选择系统代码并执行;及通过执行的系统代码,从定制资源分区中加载定制资源。In one embodiment, a computer apparatus is provided comprising a memory and a processor, the memory comprising a system firmware partition and a custom resource partition, the memory storing computer readable instructions; and the computer readable instructions being executed by the processor such that the processor Performing the following steps: running the general system firmware in the system firmware partition; reading the configuration information in the customized resource partition by running the general system firmware; obtaining the customized attribute identifier in the configuration information; determining the code execution path according to the obtained customized attribute identifier; Follow the code execution path, select the system code from the general system firmware and execute it; and load the custom resource from the custom resource partition by executing the system code.
上述定制系统实现计算机设备,通过运行通用系统固件时读取定制资源分区中的配置信息来执行对应系统代码并加载定制资源,实现系统的定制。由于不同客户的定制系统都是由通用系统固件和对应客户需求的定制资源包共同完成的。通用系统固件开发完成后可反复使用,使得在针对不同客户的不同需求的定制系统开发中,只需再开发出对应客户需求的定制资源包即可完成定制系统,而一个定制资源包的开发效率远高于一个系统固件的开发效率,从而提高了定制系统的发布效率。The above customized system implements the computer device, and reads the configuration information in the customized resource partition by running the general system firmware to execute the corresponding system code and load the customized resource to realize the customization of the system. Because the customization system of different customers is completed by the common system firmware and the customized resource package corresponding to the customer's requirements. After the development of the general-purpose system firmware, it can be used repeatedly, so that in the development of customized systems for different customers' different needs, it is only necessary to develop a customized resource package corresponding to the customer's requirements to complete the customized system, and the development efficiency of a customized resource package. It is much higher than the development efficiency of a system firmware, which improves the publishing efficiency of the customized system.
在一个实施例中,计算机可读指令使得处理器在执行运行系统固件分区中的通用系统固件之前,还执行以下步骤:获取通用系统固件;将获取的通用系统固件写入系统固件分区;获取定制资源包;将定制资源包中的配置信息和相应的定制资源写入到定制资源分区;及重启后,执行所述运行系统固件分区中的通用系统固件。In one embodiment, the computer readable instructions cause the processor to perform the following steps: obtaining general system firmware; writing the acquired general system firmware to the system firmware partition; obtaining customization before executing the general system firmware in the running system firmware partition a resource package; the configuration information in the custom resource package and the corresponding custom resource are written to the custom resource partition; and after the restart, the general system firmware in the running system firmware partition is executed.
在一个实施例中,计算机可读指令使得处理器在执行将定制资源包中的配置信息和相应的定制资源写入到定制资源分区之前,还执行以下步骤:获取定制资源包中的数字签名和公钥;根据公钥解密数字签名后进行校验;及当校验通过、且公钥与生成通用系统固件中数字签名的公钥一致时,执行将定制资源包中的配置信息和相应的定制资源写入到定制资源分区。In one embodiment, the computer readable instructions cause the processor to perform the step of obtaining a digital signature in the custom resource bundle and before executing the writing of the configuration information and the corresponding customized resource in the customized resource bundle to the custom resource partition The public key; the digital signature is decrypted according to the public key and verified; and when the verification passes, and the public key is consistent with the public key of the digital signature generated in the general system firmware, the configuration information and corresponding customization in the customized resource package are executed. Resources are written to the custom resource partition.
在一个实施例中,计算机可读指令使得处理器在执行通过运行的通用系统固件读取定制资源分区中的配置信息之后,还执行以下步骤:当定制资源 分区中不存在配置信息时,从通用系统固件中获取默认代码执行路径;及按照默认代码执行路径,从通用系统固件中选择系统代码并执行。In one embodiment, the computer readable instructions cause the processor to perform the following steps after performing configuration information in the customized resource partition by executing the running general system firmware: when customizing the resource When there is no configuration information in the partition, the default code execution path is obtained from the general system firmware; and the system code is selected and executed from the general system firmware according to the default code execution path.
在一个实施例中,计算机可读指令被处理器执行时,使得处理器还执行如下通用系统固件测试步骤:在系统固件分区中写入通用系统固件,并保持定制资源分区为空;运行系统固件分区中的通用系统固件;通过运行的通用系统固件读取定制资源分区中的配置信息;当定制资源分区中不存在配置信息时,从通用系统固件中获取默认代码执行路径;及按照默认代码执行路径,从通用系统固件中选择系统代码并执行。In one embodiment, the computer readable instructions are executed by the processor such that the processor further performs the following general system firmware testing steps: writing general system firmware in the system firmware partition and keeping the custom resource partition empty; running system firmware Common system firmware in the partition; read configuration information in the custom resource partition by running the general system firmware; obtain the default code execution path from the general system firmware when there is no configuration information in the custom resource partition; and execute according to the default code Path, select the system code from the general system firmware and execute it.
在一个实施例中,计算机可读指令被处理器执行时,使得处理器还执行如下步骤轮次对定制资源包进行测试:在定制资源分区中,轮次写入不同的定制资源包中的配置信息和相应的定制资源,通过运行通用系统固件读取定制资源分区中的配置信息,获取配置信息中的定制属性标识,根据获取的定制属性标识确定代码执行路径,按照代码执行路径,从通用系统固件中选择系统代码并执行,通过执行的系统代码,从定制资源分区中加载定制资源的步骤分别对轮次写入的定制资源包进行测试。In one embodiment, when the computer readable instructions are executed by the processor, the processor further performs the following steps to test the custom resource bundle: in the custom resource partition, the configuration of the round custom writes in the different custom resource bundles Information and corresponding custom resources, read the configuration information in the custom resource partition by running the general system firmware, obtain the customized attribute identifier in the configuration information, determine the code execution path according to the obtained customized attribute identifier, follow the code execution path, from the general system The system code is selected and executed in the firmware. The steps of loading the custom resource from the custom resource partition by executing the system code respectively test the custom resource package written in the round.
在一个实施例中,提供了一个或多个存储有计算机可读指令的非易失性的计算机可读存储介质,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器执行以下步骤:运行系统固件分区中的通用系统固件;通过运行的通用系统固件读取定制资源分区中的配置信息;获取配置信息中的定制属性标识;根据获取的定制属性标识确定代码执行路径;按照代码执行路径,从通用系统固件中选择系统代码并执行;及通过执行的系统代码,从定制资源分区中加载定制资源。In one embodiment, one or more non-transitory computer readable storage media storing computer readable instructions are provided, the computer readable instructions being executed by one or more processors such that the one Or the plurality of processors perform the following steps: running the general system firmware in the system firmware partition; reading the configuration information in the custom resource partition by running the general system firmware; obtaining the customized attribute identifier in the configuration information; and identifying the customized attribute according to the obtained Determining the code execution path; selecting the system code from the general system firmware and executing it according to the code execution path; and loading the custom resource from the custom resource partition by executing the system code.
在一个实施例中,计算机可读指令使得处理器在执行运行系统固件分区中的通用系统固件之前,还执行以下步骤:获取通用系统固件;将获取的通用系统固件写入系统固件分区;获取定制资源包;将定制资源包中的配置信息和相应的定制资源写入到定制资源分区;及重启后,执行所述运行系统固件分区中的通用系统固件。In one embodiment, the computer readable instructions cause the processor to perform the following steps: obtaining general system firmware; writing the acquired general system firmware to the system firmware partition; obtaining customization before executing the general system firmware in the running system firmware partition a resource package; the configuration information in the custom resource package and the corresponding custom resource are written to the custom resource partition; and after the restart, the general system firmware in the running system firmware partition is executed.
在一个实施例中,计算机可读指令使得处理器在执行将定制资源包中的 配置信息和相应的定制资源写入到定制资源分区之前,还执行以下步骤:获取定制资源包中的数字签名和公钥;根据公钥解密数字签名后进行校验;及当校验通过、且公钥与生成通用系统固件中数字签名的公钥一致时,执行将定制资源包中的配置信息和相应的定制资源写入到定制资源分区。In one embodiment, the computer readable instructions cause the processor to execute in a custom resource bundle Before the configuration information and the corresponding customized resources are written to the custom resource partition, the following steps are performed: obtaining the digital signature and the public key in the customized resource package; performing the verification after decrypting the digital signature according to the public key; and when the verification passes, and When the public key is consistent with the public key for generating the digital signature in the general system firmware, the configuration information and the corresponding customized resource in the customized resource package are written to the custom resource partition.
在一个实施例中,计算机可读指令使得处理器在执行通过运行的通用系统固件读取定制资源分区中的配置信息之后,还执行以下步骤:当定制资源分区中不存在配置信息时,从通用系统固件中获取默认代码执行路径;及按照默认代码执行路径,从通用系统固件中选择系统代码并执行。In one embodiment, the computer readable instructions cause the processor to perform the following steps after performing configuration information in the customized resource partition by running the running general system firmware: when there is no configuration information in the custom resource partition, Obtain the default code execution path in the system firmware; and select the system code from the general system firmware and execute it according to the default code execution path.
在一个实施例中,计算机可读指令被处理器执行时,使得处理器还执行如下通用系统固件测试步骤:在系统固件分区中写入通用系统固件,并保持定制资源分区为空;运行系统固件分区中的通用系统固件;通过运行的通用系统固件读取定制资源分区中的配置信息;当定制资源分区中不存在配置信息时,从通用系统固件中获取默认代码执行路径;及按照默认代码执行路径,从通用系统固件中选择系统代码并执行。In one embodiment, the computer readable instructions are executed by the processor such that the processor further performs the following general system firmware testing steps: writing general system firmware in the system firmware partition and keeping the custom resource partition empty; running system firmware Common system firmware in the partition; read configuration information in the custom resource partition by running the general system firmware; obtain the default code execution path from the general system firmware when there is no configuration information in the custom resource partition; and execute according to the default code Path, select the system code from the general system firmware and execute it.
在一个实施例中,计算机可读指令被处理器执行时,使得处理器还执行如下步骤轮次对定制资源包进行测试:在定制资源分区中,轮次写入不同的定制资源包中的配置信息和相应的定制资源,通过运行通用系统固件读取定制资源分区中的配置信息,获取配置信息中的定制属性标识,根据获取的定制属性标识确定代码执行路径,按照代码执行路径,从通用系统固件中选择系统代码并执行,通过执行的系统代码,从定制资源分区中加载定制资源的步骤分别对轮次写入的定制资源包进行测试。In one embodiment, when the computer readable instructions are executed by the processor, the processor further performs the following steps to test the custom resource bundle: in the custom resource partition, the configuration of the round custom writes in the different custom resource bundles Information and corresponding custom resources, read the configuration information in the custom resource partition by running the general system firmware, obtain the customized attribute identifier in the configuration information, determine the code execution path according to the obtained customized attribute identifier, follow the code execution path, from the general system The system code is selected and executed in the firmware. The steps of loading the custom resource from the custom resource partition by executing the system code respectively test the custom resource package written in the round.
上述计算机可读存储介质,通过运行通用系统固件时读取定制资源分区中的配置信息来执行对应系统代码并加载定制资源,实现系统的定制。由于不同客户的定制系统都是由通用系统固件和对应客户需求的定制资源包共同完成的。通用系统固件开发完成后可反复使用,使得在针对不同客户的不同需求的定制系统开发中,只需再开发出对应客户需求的定制资源包即可完成定制系统,而一个定制资源包的开发效率远高于一个系统固件的开发效率,从而提高了定制系统的发布效率。 The computer readable storage medium described above reads the configuration information in the custom resource partition by executing the general system firmware to execute the corresponding system code and load the customized resource to implement customization of the system. Because the customization system of different customers is completed by the common system firmware and the customized resource package corresponding to the customer's requirements. After the development of the general-purpose system firmware, it can be used repeatedly, so that in the development of customized systems for different customers' different needs, it is only necessary to develop a customized resource package corresponding to the customer's requirements to complete the customized system, and the development efficiency of a customized resource package. It is much higher than the development efficiency of a system firmware, which improves the publishing efficiency of the customized system.
本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,所述的程序可存储于一非易失性的计算机可读取存储介质中,该程序在执行时,可包括如上述各方法的实施例的流程。其中,所述的存储介质可为磁碟、光盘、只读存储记忆体(Read-Only Memory,ROM)等。One of ordinary skill in the art can understand that all or part of the process of implementing the above embodiment method can be completed by a computer program to instruct related hardware, and the program can be stored in a non-volatile computer readable storage. In the medium, the program, when executed, may include the flow of an embodiment of the methods as described above. The storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM), or the like.
以上所述实施例的各技术特征可以进行任意的组合,为使描述简洁,未对上述实施例中的各个技术特征所有可能的组合都进行描述,然而,只要这些技术特征的组合不存在矛盾,都应当认为是本说明书记载的范围。The technical features of the above-described embodiments may be arbitrarily combined. For the sake of brevity of description, all possible combinations of the technical features in the above embodiments are not described. However, as long as there is no contradiction between the combinations of these technical features, All should be considered as the scope of this manual.
以上所述实施例仅表达了本申请的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对申请专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本申请构思的前提下,还可以做出若干变形和改进,这些都属于本申请的保护范围。因此,本申请专利的保护范围应以所附权利要求为准。 The above-mentioned embodiments are merely illustrative of several embodiments of the present application, and the description thereof is more specific and detailed, but is not to be construed as limiting the scope of the claims. It should be noted that a number of variations and modifications may be made by those skilled in the art without departing from the spirit and scope of the present application. Therefore, the scope of the invention should be determined by the appended claims.

Claims (15)

  1. 一种定制系统实现方法,包括:A customized system implementation method, including:
    运行系统固件分区中的通用系统固件;Run the general system firmware in the system firmware partition;
    通过运行的通用系统固件读取定制资源分区中的配置信息;Reading configuration information in a custom resource partition by running a generic system firmware;
    获取所述配置信息中的定制属性标识;Obtaining a customized attribute identifier in the configuration information;
    根据获取的定制属性标识确定代码执行路径;Determining a code execution path according to the obtained custom attribute identifier;
    按照所述代码执行路径,从所述通用系统固件中选择系统代码并执行;及Selecting a system code from the general system firmware and executing according to the code execution path; and
    通过执行的所述系统代码,从所述定制资源分区中加载定制资源。A custom resource is loaded from the custom resource partition by the system code executed.
  2. 根据权利要求1所述的方法,其特征在于,所述运行系统固件分区中的通用系统固件之前,所述方法还包括:The method of claim 1, wherein before the running the system firmware in the system firmware partition, the method further comprises:
    获取通用系统固件;Obtain general system firmware;
    将获取的通用系统固件写入系统固件分区;Write the obtained general system firmware to the system firmware partition;
    获取定制资源包;Obtain a custom resource package;
    将所述定制资源包中的配置信息和相应的定制资源写入到定制资源分区;及Writing configuration information and corresponding customized resources in the customized resource package to the customized resource partition; and
    重启后,执行所述运行系统固件分区中的通用系统固件。After rebooting, the general system firmware in the runtime firmware partition is executed.
  3. 根据权利要求2所述的方法,其特征在于,所述将所述定制资源包中的配置信息和相应的定制资源写入到定制资源分区之前,所述方法还包括:The method according to claim 2, wherein the method further comprises: before: writing the configuration information in the customized resource package and the corresponding customized resource to the custom resource partition, the method further comprising:
    获取定制资源包中的数字签名和公钥;Obtain the digital signature and public key in the custom resource bundle;
    根据所述公钥解密所述数字签名后进行校验;及Performing verification after decrypting the digital signature according to the public key; and
    当校验通过、且所述公钥与生成通用系统固件中数字签名的公钥一致时,执行所述将所述定制资源包中的配置信息和相应的定制资源写入到定制资源分区。When the verification passes, and the public key is consistent with the public key of the digital signature generated in the general system firmware, the configuration information and the corresponding customized resource in the customized resource package are executed to be written to the customized resource partition.
  4. 根据权利要求1所述的方法,其特征在于,所述通过运行的通用系统固件读取定制资源分区中的配置信息之后,所述方法还包括:The method according to claim 1, wherein after the reading of the configuration information in the custom resource partition by the running general system firmware, the method further comprises:
    当所述定制资源分区中不存在所述配置信息时,从所述通用系统固件中获取默认代码执行路径;及Obtaining a default code execution path from the general system firmware when the configuration information does not exist in the custom resource partition; and
    按照所述默认代码执行路径,从所述通用系统固件中选择系统代码并执 行。Selecting a system code from the general system firmware and executing the path according to the default code execution path Row.
  5. 根据权利要求4所述的方法,其特征在于,还包括:The method of claim 4, further comprising:
    在系统固件分区中写入通用系统固件,并保持定制资源分区为空,通过权利要求4中所述方法的步骤对所述通用系统固件进行测试;及Writing the general system firmware in the system firmware partition and keeping the custom resource partition empty, testing the general system firmware by the steps of the method described in claim 4;
    在所述定制资源分区中,轮次写入不同的定制资源包中的配置信息和相应的定制资源,通过权利要求1中所述方法的步骤分别对轮次写入的定制资源包进行测试。In the customized resource partition, the configuration information and the corresponding customized resources in different customized resource packages are written in a round, and the customized resource packages written in the round are respectively tested by the steps of the method described in claim 1.
  6. 一种计算机设备,包括存储器和处理器,所述存储器包括系统固件分区和定制资源分区,所述存储器存储有计算机可读指令,所述计算机可读指令被所述处理器执行时,使得所述处理器执行如下步骤:A computer device comprising a memory and a processor, the memory comprising a system firmware partition and a custom resource partition, the memory storing computer readable instructions, the computer readable instructions being executed by the processor such that The processor performs the following steps:
    运行系统固件分区中的通用系统固件;Run the general system firmware in the system firmware partition;
    通过运行的通用系统固件读取定制资源分区中的配置信息;Reading configuration information in a custom resource partition by running a generic system firmware;
    获取所述配置信息中的定制属性标识;Obtaining a customized attribute identifier in the configuration information;
    根据获取的定制属性标识确定代码执行路径;Determining a code execution path according to the obtained custom attribute identifier;
    按照所述代码执行路径,从所述通用系统固件中选择系统代码并执行;及Selecting a system code from the general system firmware and executing according to the code execution path; and
    通过执行的所述系统代码,从所述定制资源分区中加载定制资源。A custom resource is loaded from the custom resource partition by the system code executed.
  7. 根据权利要求6所述的计算机设备,其特征在于,在所述运行系统固件分区中的通用系统固件之前,所述计算机可读指令还使得所述处理器执行:The computer apparatus of claim 6 wherein said computer readable instructions further cause said processor to execute: prior to said operating system firmware partitioning of said general system firmware.
    获取通用系统固件;Obtain general system firmware;
    将获取的通用系统固件写入系统固件分区;Write the obtained general system firmware to the system firmware partition;
    获取定制资源包;Obtain a custom resource package;
    将所述定制资源包中的配置信息和相应的定制资源写入到定制资源分区;及Writing configuration information and corresponding customized resources in the customized resource package to the customized resource partition; and
    重启后,执行所述运行系统固件分区中的通用系统固件。After rebooting, the general system firmware in the runtime firmware partition is executed.
  8. 根据权利要求7所述的计算机设备,其特征在于,所述将所述定制资源包中的配置信息和相应的定制资源写入到定制资源分区之前,所述计算机可读指令还使得所述处理器执行:The computer device according to claim 7, wherein said computer readable instructions further cause said processing before said configuring information in said customized resource bundle and corresponding custom resources are written to said custom resource partition Execution:
    获取定制资源包中的数字签名和公钥; Obtain the digital signature and public key in the custom resource bundle;
    根据所述公钥解密所述数字签名后进行校验;及Performing verification after decrypting the digital signature according to the public key; and
    当校验通过、且所述公钥与生成通用系统固件中数字签名的公钥一致时,执行所述将所述定制资源包中的配置信息和相应的定制资源写入到定制资源分区。When the verification passes, and the public key is consistent with the public key of the digital signature generated in the general system firmware, the configuration information and the corresponding customized resource in the customized resource package are executed to be written to the customized resource partition.
  9. 根据权利要求6所述的计算机设备,其特征在于,在所述通过运行的通用系统固件读取定制资源分区中的配置信息之后,所述计算机可读指令还使得所述处理器执行:The computer apparatus of claim 6, wherein the computer readable instructions further cause the processor to execute after the configuration information in the custom resource partition is read by the running generic system firmware:
    当所述定制资源分区中不存在所述配置信息时,从所述通用系统固件中获取默认代码执行路径;及Obtaining a default code execution path from the general system firmware when the configuration information does not exist in the custom resource partition; and
    按照所述默认代码执行路径,从所述通用系统固件中选择系统代码并执行。The system code is selected from the general system firmware and executed in accordance with the default code execution path.
  10. 根据权利要求9所述的计算机设备,其特征在于,所述计算机可读指令还使得所述处理器执行:The computer apparatus of claim 9 wherein said computer readable instructions further cause said processor to:
    在系统固件分区中写入通用系统固件,并保持定制资源分区为空,通过权利要求9中所述计算机可读指令使得所述处理器执行的步骤对所述通用系统固件进行测试;及Writing the general system firmware in the system firmware partition and keeping the custom resource partition empty, the step of performing the processor to test the general system firmware by the computer readable instructions described in claim 9;
    在所述定制资源分区中,轮次写入不同的定制资源包中的配置信息和相应的定制资源,通过权利要求6中所述计算机可读指令使得所述处理器执行的步骤分别对轮次写入的定制资源包进行测试。In the custom resource partition, the configuration information and the corresponding custom resource in the different custom resource packages are written in a round, and the steps performed by the processor are respectively performed on the round by the computer readable instructions in claim 6. Write a custom resource bundle for testing.
  11. 一个或多个存储有计算机可读指令的非易失性的计算机可读存储介质,所述计算机可读指令被一个或多个处理器执行时,使得所述一个或多个处理器执行以下步骤:One or more non-transitory computer readable storage mediums storing computer readable instructions, when executed by one or more processors, cause the one or more processors to perform the following steps :
    运行系统固件分区中的通用系统固件;Run the general system firmware in the system firmware partition;
    通过运行的通用系统固件读取定制资源分区中的配置信息;Reading configuration information in a custom resource partition by running a generic system firmware;
    获取所述配置信息中的定制属性标识;Obtaining a customized attribute identifier in the configuration information;
    根据获取的定制属性标识确定代码执行路径;Determining a code execution path according to the obtained custom attribute identifier;
    按照所述代码执行路径,从所述通用系统固件中选择系统代码并执行;及Selecting a system code from the general system firmware and executing according to the code execution path; and
    通过执行的所述系统代码,从所述定制资源分区中加载定制资源。 A custom resource is loaded from the custom resource partition by the system code executed.
  12. 根据权利要求11所述的计算机可读存储介质,其特征在于,在所述运行系统固件分区中的通用系统固件之前,所述计算机可读指令还使得所述处理器执行:The computer readable storage medium of claim 11 wherein said computer readable instructions further cause said processor to execute: prior to said general system firmware in said operating system firmware partition:
    获取通用系统固件;Obtain general system firmware;
    将获取的通用系统固件写入系统固件分区;Write the obtained general system firmware to the system firmware partition;
    获取定制资源包;Obtain a custom resource package;
    将所述定制资源包中的配置信息和相应的定制资源写入到定制资源分区;及Writing configuration information and corresponding customized resources in the customized resource package to the customized resource partition; and
    重启后,执行所述运行系统固件分区中的通用系统固件。After rebooting, the general system firmware in the runtime firmware partition is executed.
  13. 根据权利要求12所述的计算机可读存储介质,其特征在于,所述将所述定制资源包中的配置信息和相应的定制资源写入到定制资源分区之前,所述计算机可读指令还使得所述处理器执行:The computer readable storage medium of claim 12, wherein said computer readable instructions further cause said configuration information and said corresponding custom resources in said customized resource bundle to be written to a custom resource partition The processor executes:
    获取定制资源包中的数字签名和公钥;Obtain the digital signature and public key in the custom resource bundle;
    根据所述公钥解密所述数字签名后进行校验;及Performing verification after decrypting the digital signature according to the public key; and
    当校验通过、且所述公钥与生成通用系统固件中数字签名的公钥一致时,执行所述将所述定制资源包中的配置信息和相应的定制资源写入到定制资源分区。When the verification passes, and the public key is consistent with the public key of the digital signature generated in the general system firmware, the configuration information and the corresponding customized resource in the customized resource package are executed to be written to the customized resource partition.
  14. 根据权利要求11所述的计算机可读存储介质,其特征在于,在所述通过运行的通用系统固件读取定制资源分区中的配置信息之后,所述计算机可读指令还使得所述处理器执行:The computer readable storage medium of claim 11, wherein the computer readable instructions further cause the processor to execute after the configuration information in the custom resource partition is read by the running generic system firmware :
    当所述定制资源分区中不存在所述配置信息时,从所述通用系统固件中获取默认代码执行路径;及Obtaining a default code execution path from the general system firmware when the configuration information does not exist in the custom resource partition; and
    按照所述默认代码执行路径,从所述通用系统固件中选择系统代码并执行。The system code is selected from the general system firmware and executed in accordance with the default code execution path.
  15. 根据权利要求14所述的计算机可读存储介质,其特征在于,所述计算机可读指令还使得所述处理器执行:The computer readable storage medium of claim 14 wherein the computer readable instructions further cause the processor to:
    在系统固件分区中写入通用系统固件,并保持定制资源分区为空,通过权利要求14中所述计算机可读指令使得所述处理器执行的步骤对所述通用系统固件进行测试;及 Writing general system firmware in a system firmware partition and keeping the custom resource partition empty, the steps performed by the processor to test the general system firmware by computer readable instructions as recited in claim 14;
    在所述定制资源分区中,轮次写入不同的定制资源包中的配置信息和相应的定制资源,通过权利要求11中所述计算机可读指令使得所述处理器执行的步骤分别对轮次写入的定制资源包进行测试。 In the custom resource partition, the configuration information and corresponding custom resources in different custom resource bundles are written in a round, and the steps performed by the processor are respectively performed on the round by the computer readable instructions in claim 11. Write a custom resource bundle for testing.
PCT/CN2017/101788 2017-06-15 2017-09-14 Custom system implementation method, computer device, and computer-readable storage medium WO2018227798A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201710453248.7 2017-06-15
CN201710453248.7A CN107341003B (en) 2017-06-15 2017-06-15 Customization system implementing method, computer device and storage medium

Publications (1)

Publication Number Publication Date
WO2018227798A1 true WO2018227798A1 (en) 2018-12-20

Family

ID=60220618

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2017/101788 WO2018227798A1 (en) 2017-06-15 2017-09-14 Custom system implementation method, computer device, and computer-readable storage medium

Country Status (2)

Country Link
CN (1) CN107341003B (en)
WO (1) WO2018227798A1 (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108549555A (en) * 2018-04-10 2018-09-18 Tcl通力电子(惠州)有限公司 Processing method, embedded system device and the storage medium of customized software
CN108959116A (en) * 2018-06-15 2018-12-07 深圳市西迪特科技有限公司 The management method of device customizing information
CN109656638A (en) * 2018-12-20 2019-04-19 广东浪潮大数据研究有限公司 A kind of user based on Purley platform customizes the implementation method of function
CN111309338A (en) * 2020-02-12 2020-06-19 杭州涂鸦信息技术有限公司 Method and system for importing difference firmware
CN111679834B (en) * 2020-04-25 2024-01-23 华帝股份有限公司 Automatic burning system and method for internet of things module
CN112306506B (en) * 2020-06-28 2023-08-22 神州融安科技(北京)有限公司 Method and device for burning computer program, electronic equipment and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070168956A1 (en) * 2005-11-03 2007-07-19 International Business Machines Corporation System and method for representing user processes as software packages in a software package management system
CN101847099A (en) * 2010-06-08 2010-09-29 用友软件股份有限公司 Method and device for individually configuring application functions
CN103631587A (en) * 2013-11-15 2014-03-12 北京奇虎科技有限公司 Software installation package customization method and server
CN103984564A (en) * 2013-02-08 2014-08-13 百度国际科技(深圳)有限公司 Method and device for installing and upgrading software

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5963743A (en) * 1997-08-29 1999-10-05 Dell Usa, L.P. Database for facilitating software installation and testing for a build-to-order computer system
FR2876197B1 (en) * 2004-10-01 2006-12-22 Bull Sa Sa METHOD FOR THE FLEXIBLE MANAGEMENT OF MULTIPLE ACTIVITIES EXECUTED ON PARTITIONABLE PLATFORMS OF A MULTI-PROCESSOR SYSTEM
CN103812948B (en) * 2014-03-04 2017-05-31 湘潭大学 Operation system of smart phone high in the clouds interacts custom-built system and method
CN104461533A (en) * 2014-12-03 2015-03-25 重庆蓝岸通讯技术有限公司 System firmware customizing method based on Marvell LTE (Long Term Evolution) platform
CN104778424B (en) * 2015-03-24 2017-10-27 四川长虹电器股份有限公司 The method that ROM brush machines are prevented based on intelligent television

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070168956A1 (en) * 2005-11-03 2007-07-19 International Business Machines Corporation System and method for representing user processes as software packages in a software package management system
CN101847099A (en) * 2010-06-08 2010-09-29 用友软件股份有限公司 Method and device for individually configuring application functions
CN103984564A (en) * 2013-02-08 2014-08-13 百度国际科技(深圳)有限公司 Method and device for installing and upgrading software
CN103631587A (en) * 2013-11-15 2014-03-12 北京奇虎科技有限公司 Software installation package customization method and server

Also Published As

Publication number Publication date
CN107341003A (en) 2017-11-10
CN107341003B (en) 2020-08-07

Similar Documents

Publication Publication Date Title
WO2018227798A1 (en) Custom system implementation method, computer device, and computer-readable storage medium
WO2020042778A1 (en) Firmware upgrade method and device
CN105164644B (en) Hook frame
US8904518B2 (en) Information processing device, information processing method, and program distribution system
JP5891414B2 (en) Information processing apparatus and method for preventing unauthorized application cooperation
US9665465B1 (en) Automated determination of application permissions
CN105631337B (en) Control the system and method for the machine image access operating-system resources of machine code
US9549316B2 (en) Host device coupled to a mobile phone and method of operating the same
US20170131999A1 (en) Detection of software or hardware incompatibilities in software packages
US11023365B2 (en) Systems and methods for automated provisioning of a virtual mainframe test environment
CN113961919B (en) Malicious software detection method and device
US20180357183A1 (en) Device with multiple roots of trust
US20180260433A1 (en) Information processing apparatus and control method for information processing apparatus
US10983903B1 (en) Enhanced automated protocol for secure application testing
US9639345B2 (en) Methods and apparatuses for providing framework for selective execution of application features
KR20160020294A (en) Method and system for providing application security service based on cloud
KR20170089352A (en) Firmware integrity verification for performing the virtualization system
CN112835628A (en) Server operating system booting method, device, equipment and medium
WO2017035819A1 (en) Method for implementing host card emulation, terminal, and data routing method and apparatus
US20210132975A1 (en) Automated host attestation for secure run-time environments
US11494493B1 (en) Software verification for network-accessible applications
JP6018344B2 (en) Dynamic reading code analysis apparatus, dynamic reading code analysis method, and dynamic reading code analysis program
KR20190038609A (en) Order verification
US20220353076A1 (en) Crowd-sourced qa with trusted compute model
CN111177752B (en) Credible file storage method, device and equipment based on static measurement

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 17913739

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 17913739

Country of ref document: EP

Kind code of ref document: A1