A one-key automatic signing method and system based on a CPE program small file
By using a graphical user interface and a cross-platform file transfer protocol, one-click automatic signing of small CPE program files is achieved, which solves the complicated signing process in existing technologies, improves signing efficiency and security, and supports Windows platform operation.
Patent Information
- Application Number
- CN202510183050.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-19
- Publication Date
- 2026-01-02
- Estimated Expiration
- 2045-02-19
AI Technical Summary
The signing process for small files in CPE programs is complicated, especially since frequent burning of small files requires manual signing, resulting in a large amount of repetitive work. Furthermore, existing technologies cannot automate the signing process on the Windows platform.
It uses a graphical user interface to receive signature parameters, automatically uploads them to a Linux server for signing via a cross-platform file transfer protocol, and completes the signing operation on the Windows platform, including file renaming, parameter conversion, security verification, and result feedback, achieving one-click automatic signing.
It enables fast, secure, and automatic signing of small CPE program files, reducing manual operations, improving signing efficiency, and achieving compatibility with Linux platforms on the Windows platform, enhancing user-friendliness and security.
Smart Images

Figure CN120196595B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of CPE programs, more particularly to a one-key automatic signing method and system based on CPE program small files. BACKGROUND
[0002] Customer Premise Equipment (CPE) refers to equipment located at the user site and owned by the user, used to connect to the network of a service provider. CPE usually includes various types of network equipment, such as routers, switches, modems, gateways, wireless access points, etc. These devices are usually responsible for directing Internet or other communication services from the service provider's network to the internal network of the user's home or office. The function of CPE is to ensure that the user can access the external network and handle data transmission within the local area network.
[0003] With the advent of the era of Internet of Things, CPE has increasing demand due to its portability, easy construction, and high speed. It is important to provide high-quality services to customers in line with the concepts of customer first and service first. In particular, front-line technical support needs to provide various temporary modifications to the current environment for various optimizations in the customer's live network environment with the help of R&D colleagues, and temporary modifications usually require quick response to front-line testing, saving time, and require small files to be burned into CPE. After this important step of signing, front-line personnel can use it normally. The small file is different from the complete firmware burned into CPE. The complete firmware is burned less frequently, so the signing frequency is low. As a "patch", the small file is burned more frequently, and the signing needs to be done before each burn, and the signing may also involve renaming and other processes, which overall makes the signing process of the small file very complex.
[0004] More specifically, the signing of the small file requires uploading to the server. Modify the name, input sequentially, and then perform the signing action. Finally, download the signed small file. With more modifications, the repetitive signing workload is also heavier, so the present application proposes a one-key automatic signing method and system based on CPE program small files. SUMMARY
[0005] The technical problem to be solved by the present application is to provide a one-key automatic signing method and system based on CPE program small files to solve the problems mentioned in the background.
[0006] In order to achieve the above purpose, the present application adopts the following technical scheme:
[0007] A one-key automatic signing method based on CPE program small files, comprising the following steps:
[0008] S1: receiving signature parameters input by a user through a graphical user interface, including signature branch parameters, key list parameters, storage capacity parameters and paths of modules to be signed;
[0009] S2: dynamically displaying corresponding key list parameters according to the signature branch parameters, and converting the key list parameters and the storage capacity parameters into digital identification parameters recognizable by a server side;
[0010] S3: performing standardized renaming processing on original files of modules to be signed to generate target file names conforming to naming rules of a server;
[0011] S4: automatically uploading the renamed files to a Linux server through a cross-platform file transfer protocol, and calling a server signature interface to perform a signature operation, wherein the signature interface selects a corresponding signature algorithm according to the digital identification parameters;
[0012] S5: in response to signature success information returned by the server, appending an extension containing key identification and a timestamp to the signed files, and automatically downloading the signed files to a specified local path through the cross-platform file transfer protocol.
[0013] In an optional embodiment, the parameter conversion in step S2 specifically includes:
[0014] mapping the key list parameters into predefined integer codes, and converting the storage capacity parameters into server-side storage partition configuration identification.
[0015] In an optional embodiment, step S3 further includes:
[0016] performing legality verification and standardized renaming on file names according to a preset module naming rule library matched with a type of the module to be signed.
[0017] In an optional embodiment, the cross-platform file transfer protocol in step S4 is an encapsulation transmission module based on an SCP protocol, and a server IP address, an account and a password are built into the tool in an encrypted form.
[0018] In an optional embodiment, the extension generation rule in step S5 is:
[0019] concatenating a key list parameter name and a current date to the end of an original file name in a format of “key_year-month-day-sign”.
[0020] More specifically, the method is applied to CPE program small files, the CPE program small files are distinguished from CPE overall firmware, are program patches for being burned into the CPE, and the size of the small files is less than 20% of the size of the overall firmware.
[0021] In addition, in order to be more accurate, the CPE program small file can also be defined as a file with a file size less than a preset value T, for example, T can be set to 16MB (the current maximum small file is about 15MB).
[0022] The application further discloses a one-key automatic signing system based on the CPE program small file, which comprises:
[0023] The parameter input module is configured to receive the signing branch parameter, the key list parameter, the storage capacity parameter and the module path through a graphical interface.
[0024] The dynamic display module is configured to dynamically update the selectable parameters of the key list according to the signing branch parameter.
[0025] The file processing module is configured to perform file standardization renaming and cross-platform file transmission based on the SCP protocol.
[0026] The signature execution module is configured to send a signature request carrying a digital identifier parameter to a Linux server and parse a signature result returned by the server.
[0027] The security verification module is configured to check the legality of the signed file and feed back a signature state in the graphical interface.
[0028] In an optional embodiment, the parameter input module comprises:
[0029] The pull-down menu component is configured to select the signing branch parameter and the key list parameter.
[0030] The path selection button is configured to trigger a file browser to select a module path to be signed.
[0031] In an optional embodiment, the security verification module further comprises:
[0032] The regular expression matching unit is configured to detect whether a predefined signature success identifier is contained in the information returned by the server.
[0033] The exception processing unit is configured to automatically retry an uploading operation and record an error log when the signature fails.
[0034] In an optional embodiment, the application further comprises an extensible interface module configured to:
[0035] The newly added signature algorithm parameter and the storage capacity type are dynamically loaded through a configuration file, and the program code does not need to be modified.
[0036] The application has the following advantages over the prior art.
[0037] This invention automates the process, allowing users to quickly sign small files without manual intervention. Furthermore, while traditional signing is performed on Linux platforms, this tool can also sign on Windows, resolving compatibility issues between Windows and Linux environments. The invention can also be configured to support graphical operation and display, optimizing command-line operation for a more user-friendly graphical interface. It can also embed sensitive parameters such as passwords and perform signature validity checks on small files, greatly enhancing security. Attached Figure Description
[0038] Figure 1 This is a flowchart of the method of the present invention;
[0039] Figure 2 This is a structural diagram of the system of the present invention;
[0040] Figure 3 This is a flowchart of one embodiment of the present invention. Detailed Implementation
[0041] The specific embodiments of the present invention will now be described with reference to the accompanying drawings.
[0042] like Figure 1 The diagram shown illustrates the method of the present invention, which includes the following steps:
[0043] S1: Receive signature parameters input by the user through a graphical user interface, including signature branch parameters, key list parameters, storage capacity parameters, and the path of the module to be signed;
[0044] S2: Dynamically display the corresponding key list parameters according to the signature branch parameters, and convert the key list parameters and storage capacity parameters into digital identifier parameters that can be recognized by the server.
[0045] S3: Standardize and rename the original file of the signing module to generate a target file name that conforms to the server's naming rules;
[0046] S4: The renamed file is automatically uploaded to the Linux server via a cross-platform file transfer protocol, and the server signature interface is called to perform a signature operation. The signature interface selects the corresponding signature algorithm according to the digital identifier parameter.
[0047] S5: In response to the signing success information returned by the server, append an extension containing the key identifier and timestamp to the signed file, and automatically download it to the specified local path through the cross-platform file transfer protocol.
[0048] In an optional embodiment, the parameter conversion in step S2 specifically includes:
[0049] Map the key list parameter to a predefined integer code, and convert the storage capacity parameter to a server-side storage partition configuration identifier.
[0050] In an optional embodiment, step S3 further comprises:
[0051] According to the user-selected module type to be signed, the preset module naming rule library is matched to perform legality verification and standardized renaming on the file name.
[0052] In an optional embodiment, the cross-platform file transfer protocol in step S4 is an encapsulation transfer module based on the SCP protocol, and the server IP address, account and password are built-in in the tool in an encrypted form.
[0053] In an optional embodiment, the extension generation rule in step S5 is:
[0054] The key list parameter name and the current date are spliced to the end of the original file name in the format of "key_year-month-day-sign".
[0055] As shown in Figure 2 The structure of the system of the present application, comprising:
[0056] The parameter input module is used to receive the signature branch parameter, the key list parameter, the storage capacity parameter and the module path through the graphical interface;
[0057] The dynamic display module is used to dynamically update the optional parameters of the key list according to the signature branch parameter;
[0058] The file processing module is used to perform file standardized renaming and cross-platform file transfer based on the SCP protocol;
[0059] The signature execution module is used to send a signature request carrying a digital identifier parameter to a Linux server, and parse the signature result returned by the server;
[0060] The security verification module is used to check the legality of the signed file, and feed back the signature state in the graphical interface.
[0061] In an optional embodiment, the parameter input module comprises:
[0062] The drop-down menu component is used to select the signature branch parameter and the key list parameter;
[0063] The path selection button is used to trigger the file browser to select the module path to be signed.
[0064] In an optional embodiment, the security verification module further comprises:
[0065] A regular expression matching unit is configured to detect whether a predefined signature success identifier is included in the server return information.
[0066] An exception handling unit is configured to automatically retry the uploading operation and record error logs when the signature fails.
[0067] In an optional embodiment, an extensible interface module is further included, configured to:
[0068] The newly added signature algorithm parameters and storage capacity types are dynamically loaded through a configuration file, without the need to modify the program code.
[0069] As shown in the following more specific embodiment. In this specific embodiment: Figure 3
[0070] The flow includes:
[0071] Selecting a signature branch parameter:
[0072] The user selects an appropriate signature branch parameter through a graphical interface. Currently, multiple options are provided, such as "un30_wifi6_sign", "un30_sign", and "MX0268_sign". These branch parameters represent different signature environments, meaning that different signature algorithms are used for each branch, but the operation interface of the tool does not differ much for the user. For example, the user currently selects "MX0268_sign" as the signature branch parameter.
[0073] Displaying a key list:
[0074] According to the signature branch selected by the user, the system automatically displays the corresponding key list. For example, if the user selects "MX0268_sign", the system will display the matching key parameters, such as "common", "IN0345", "NG0002", "TN0303", "GH0153", and "SC001". In this example, the user selects the "common" key parameter.
[0075] Selecting a storage capacity (Flash) parameter:
[0076] The user can select the storage capacity type of the CPE device, and common options include "2G FLASH" or "4G FLASH", with the specific selection depending on the hardware configuration of the target device. For example, the user selects "2G FLASH" as the storage capacity.
[0077] Selecting a module path to be signed:
[0078] The system supports signing multiple modules, and currently there are four modules available: "nr", "v3", "ps", and "dsp". Each module represents a different functional component or program module in the CPE. The user selects the "nr" module and selects the path of the module in the file browser, which is the folder path where the module is located.
[0079] Click the Sign button:
[0080] After completing the above settings, the user clicks the "Sign" button to start the signing process. The specific steps of the signing process are as follows:
[0081] Load the signing configuration:
[0082] The system loads the relevant signing configuration according to the user's selected signing branch (such as "MX0268_sign") and key (such as "common").
[0083] File renaming:
[0084] According to the user's selected module type (for example, selecting the "nr" module), the system will perform standardized renaming processing on the file to be signed to ensure that the file name meets the server naming rules. For example, the original file name may be "nr_module.bin", and the system will rename it to "SC9600_Orca_NR_phy_modem.bin".
[0085] File upload to the server:
[0086] The renamed file will be uploaded to the specified Linux server path (such as " / home / work / cp_sign / ") through SCP (Secure Copy Protocol).
[0087] Parameter conversion and signing request:
[0088] The system converts the user's selected "key" and "storage capacity" parameters into numerical identifiers (for example, "common" is mapped to 1, and "2G FLASH" is mapped to 1), and sends these parameters to the server's signing interface along with the file to be signed, starting the signing operation.
[0089] Sign result confirmation:
[0090] After the server completes the signing operation, it returns the signing result information. If the return information contains "Current sign result: Success", it indicates that the signing is successful. Otherwise, the system will prompt that the signing has failed, and the user can adjust the operation according to the prompt.
[0091] File renaming and download:
[0092] If the signature is successful, the system will further rename the signed file according to the user's selected module and the current date (for example, the date is "20250120"). The new file name format is "SC9600_Orca_NR_phy_modem_common_20250120-sign.bin". The renamed file will be automatically downloaded to the user-specified local path (such as the "cp_sign" directory) through the SCP protocol, completing the signature process.
[0093] wherein:
[0094] The signature branch parameter specifies the selection of the signature environment or signature algorithm, and different branch parameters may correspond to different signature strategies or security requirements.
[0095] The key list parameter is used to select the keys related to the signature, and each key represents a specific security identity, ensuring the uniqueness and security of the signature process.
[0096] The storage capacity parameter specifies the storage capacity type of the CPE device, such as 2GB, 4GB, etc., to ensure that the signature process matches the device hardware configuration.
[0097] SCP protocol is a secure copy protocol (Secure Copy Protocol), a protocol for securely transmitting files between computers, commonly used for remote file transfer.
[0098] The module type is a classification of different functional modules in the CPE, and the user can select the module to be signed according to the actual needs, ensuring the accuracy of the firmware update.
[0099] During the signature process, the file name needs to follow specific rules and formats so that the system can correctly identify and perform the corresponding signature operation.
[0100] The above is only the preferred specific implementation of the present application, but the protection scope of the present application is not limited to this. Any person skilled in the art can make equivalent replacements or changes within the technical scope disclosed in the present application according to the technical solution and inventive concept of the present application, which should be covered within the protection scope of the present application.
Claims
1. A one-click automatic signing method for small files based on CPE programs, characterized in that, Includes the following steps: S1: Receive signature parameters input by the user through a graphical user interface, including signature branch parameters, key list parameters, storage capacity parameters, and the path of the module to be signed; S2: Dynamically display the corresponding key list parameters according to the signature branch parameters, and convert the key list parameters and storage capacity parameters into digital identifier parameters that can be recognized by the server; wherein, the signature branch parameters are pre-mapped one by one with the corresponding signature environment and signature algorithm strategy, and an independent key list and storage capacity type set are configured for each signature branch; S3: Standardize and rename the original file of the signing module to generate a target file name that conforms to the server's naming rules; S4: The renamed file is automatically uploaded to the Linux server via a cross-platform file transfer protocol, and the server signature interface is called to perform a signature operation. The signature interface selects the corresponding signature algorithm according to the digital identifier parameter. In step S4, the cross-platform file transfer protocol is an encapsulated transfer module based on the SCP protocol, and the server IP address, account, and password are built into the tool in encrypted form. S5: In response to the signature success message returned by the server, append an extension containing the key identifier and timestamp to the signed file, and automatically download it to the specified local path through the cross-platform file transfer protocol; Specifically, the parameter transformation in step S2 includes: Map the key list parameters to predefined integer codes and convert the storage capacity parameters into server-side storage partition configuration identifiers; Step S3 further includes: Based on the type of module to be signed selected by the user, the system matches the preset module naming rule library and performs legality verification and standardized renaming on the file name; The method is applied to small CPE program files, which are defined as patch files whose file size is less than a preset threshold T.
2. The method according to claim 1, characterized in that, The extension generation rule in step S5 is as follows: Concatenate the key list parameter name and the current date to the end of the original file name in the format "key_year month day-sign".
3. The method according to claim 1 or 2, characterized in that, The method is applied to a small CPE program file, which is different from the overall CPE firmware. It is a program patch used to burn into the CPE and its size is less than 20% of the overall firmware size.
4. A one-click automatic signing system for small CPE program files, characterized in that, To implement the one-click automatic signing method for small CPE program files as described in claim 1, the method includes: The parameter input module is used to receive signature branch parameters, key list parameters, storage capacity parameters, and module paths through a graphical interface; among them, the key list parameters are mapped to predefined integer codes, and the storage capacity parameters are converted into server-side storage partition configuration identifiers; The dynamic display module is used to dynamically update optional parameters of the key list based on the signature branch parameters; The file processing module is used to perform standardized file renaming and cross-platform file transfer based on the SCP protocol. Specifically, based on the type of module to be signed selected by the user, it matches a preset module naming rule library to perform legality verification and standardized renaming of file names. The signature execution module is used to send a signature request carrying a numeric identifier parameter to the Linux server and parse the signature result returned by the server. The security verification module is used to check the legitimacy of signed files and provide feedback on the signing status in a graphical interface.
5. The system according to claim 4, characterized in that, The parameter input module includes: A drop-down menu component for selecting signature branch parameters and key list parameters; The path selection button is used to trigger the file browser to select the path of the module to be signed.
6. The system according to claim 4, characterized in that, The security verification module further includes: Regular expression matching unit is used to detect whether the server-returned information contains a predefined signature success identifier; The exception handling unit is used to automatically retry the upload operation and log errors when the signature fails.
7. The system according to claim 4, characterized in that, It also includes an extensible interface module for: New signature algorithm parameters and storage capacity types can be dynamically loaded through configuration files without modifying the program code.
Citation Information
Patent Citations
Method and system for uniformly signing product firmware
CN118656879A