A method and system for activating a baseboard management controller function
By storing the device's unique identifier in the baseboard management controller and generating an activation code in a non-plaintext format, the problem of unreliable association between the activation code and the device is solved, thus improving the authorization security of the BMC's controlled functions.
Patent Information
- Application Number
- CN202611543491.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-30
- Publication Date
- 2026-11-03
AI Technical Summary
In the prior art, the association between the activation code of the baseboard management controller (BMC) and the device is not reliable enough, resulting in low security of device function authorization.
The device's unique identifier is stored in a one-time programmable storage area, which can only be read when the authorization code verification is successful. An activation code without plaintext is generated, and the controlled functions are enabled through the verification mechanism of the baseboard management controller.
It improves the reliability of binding activation codes to devices, prevents activation codes from being copied to other devices, and enhances the authorization security of controlled functions.
Smart Images

Figure CN123031233A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of server technology, and in particular to a method and system for activating the function of a baseboard management controller. Background Technology
[0002] As servers and other devices offer increasingly rich functionality, manufacturers often configure some functions as controlled features requiring separate authorization. This means that after a user purchases a license, the manufacturer issues an activation code corresponding to the device. Once the device verifies the activation code, the controlled function is activated. For example, the Baseboard Management Controller (BMC) in a server, in addition to providing basic management functions such as component configuration, firmware upgrades, fault diagnosis, log management, and monitoring alarms, also possesses controlled functions that require separate authorization. To ensure authorization reliability, the activation code needs to be associated with a specific device to prevent the same activation code from being used on other devices. However, in related licensing schemes, the association between the activation code and the device is not reliable enough, making the activation code vulnerable to cracking and theft. Summary of the Invention
[0003] This invention provides a method and system for activating the function of a baseboard management controller, which at least solves the problems of unreliable association between activation codes and devices and low security of device function authorization in related technologies.
[0004] This invention provides a method for activating the function of a baseboard management controller, applied to manufacturer customer service equipment, comprising: Receive a function activation request for the baseboard management controller of the target device; wherein the target device includes a baseboard management controller and a first storage area, the first storage area is a one-time programmable storage area and stores the device unique identifier of the target device; An authorization code is sent to the target device, and after the target device verifies the authorization code, the device unique identifier code in the first storage area is obtained; wherein, the device unique identifier code in the first storage area is only allowed to be read out to the outside of the target device when the authorization code verification is successful; An activation code corresponding to the target device is generated using an activation code generation device based on the device's unique identifier. The activation code does not include the device's unique identifier in plaintext. The activation code is sent to the baseboard management controller, so that the baseboard management controller reads the device unique identifier from the first storage area, verifies the activation code using the read device unique identifier, and outputs an activation signal after the verification is successful, so as to enable the controlled functions that are pre-installed in the baseboard management controller and are in an disabled state; wherein, the controlled functions include at least one of memory fault warning and self-repair function, single sign-on function, and system configuration lock function.
[0005] The present invention also provides a baseboard management controller function activation system, including a manufacturer customer service device, an activation code generation device and a target device. The target device includes a baseboard management controller and a first storage area. The first storage area is a one-time programmable storage area and stores the device unique identifier code of the target device. The manufacturer's customer service equipment is used to receive a function activation request for the baseboard management controller of the target device, send an authorization code to the target device, and after the target device verifies the authorization code, obtain the device unique identifier code in the first storage area, generate an activation code corresponding to the target device based on the device unique identifier code through the activation code generation device, wherein the activation code does not include the device unique identifier code in plaintext, and send the activation code to the baseboard management controller. The baseboard management controller is used to read the device unique identifier from the first storage area, use the read device unique identifier to verify the activation code, and output an activation signal after the verification is successful, so as to enable the controlled functions that are preset in the baseboard management controller and are in an disabled state. The device unique identifier in the first storage area is allowed to be read out to the outside of the target device only when the authorization code is verified; the controlled functions include at least one of memory fault warning and self-repair function, single sign-on function and system configuration locking function.
[0006] This invention stores the unique device identifier (UDI) of the target device in a one-time programmable memory area. Once written, it cannot be modified and is only allowed to be read out of the target device when the authorization code verification is successful. Therefore, only the manufacturer's customer service equipment that possesses the authorization code can obtain the UDI; users and other personnel cannot obtain or tamper with it. Based on this, the activation code is generated according to the UDI, but does not include the plaintext version of the UDI. The baseboard management controller verifies the activation code using the UDI in its first memory area. Thus, the UDI is not exposed in plaintext during activation code transmission, and the activation code can only pass verification on its corresponding target device. Even if the activation code is copied to other devices, it will fail verification because the UDI of other devices is different and unrewritable. After successful verification, the baseboard management controller outputs an activation signal, enabling preset controlled functions such as memory fault warning and self-repair, single sign-on, and system configuration locking. This solves the problem of unreliable association between the activation code and the device in related technologies and improves the security of the baseboard management controller's controlled function authorization. Attached Figure Description
[0007] To more clearly illustrate the embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0008] Figure 1 A flowchart illustrating a method for activating the function of a baseboard management controller, as provided in an embodiment of the present invention; Figure 2 This is a schematic diagram illustrating an application scenario of a baseboard management controller function activation system provided in an embodiment of the present invention; Figure 3 This is a schematic diagram of the structure of a target device provided in an embodiment of the present invention; Figure 4 This is a schematic diagram of the structure of a storage area and readout control circuit in a target device provided by an embodiment of the present invention; Figure 5 This is a schematic diagram illustrating a scenario in which a unique device identifier is generated and written in a production environment, as provided by an embodiment of the present invention. Figure 6 A structural block diagram of a device unique identifier generation device provided in an embodiment of the present invention; Figure 7 This is a schematic diagram of the specific structure of a device unique identifier generation device provided in an embodiment of the present invention; Figure 8A schematic diagram of the circuit structure of an identification code generation circuit provided in an embodiment of the present invention; Figure 9 This is a schematic diagram of a writing circuit provided in an embodiment of the present invention; Figure 10 A functional module diagram of a manufacturer's customer service equipment and activation code generation device provided in an embodiment of the present invention; Figure 11 A flowchart of an activation code generation process provided in an embodiment of the present invention; Figure 12 A flowchart of an activation code verification process provided in an embodiment of the present invention; Figure 13 This is a schematic diagram illustrating the distribution of activation code packages to multiple client devices via an out-of-band management interface, as provided in an embodiment of the present invention. Figure 14 This is a schematic diagram of a module structure for identifying a local activation code from an activation code package, provided by an embodiment of the present invention. Figure 15 A flowchart for identifying a local activation code from an activation code package is provided as an embodiment of the present invention; Figure 16 A flowchart of a continuous timing verification method for the authorization period provided in an embodiment of the present invention; Figure 17 This is a schematic diagram of the circuit structure of an authorization period cumulative timing circuit provided in an embodiment of the present invention. Detailed Implementation
[0009] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the protection scope of the present invention.
[0010] It should be noted that, in the description of this invention, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. The terms "first," "second," etc., used in this invention are used to distinguish similar objects and are not used to describe a specific order or sequence.
[0011] To enable those skilled in the art to better understand the present invention, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.
[0012] Here, we will first explain some key terms used in the embodiments of the present invention.
[0013] The Baseboard Management Controller (BMC) is a management and control component in a server used for out-of-band management and monitoring. The BMC can manage server functions such as component configuration, firmware upgrades, fault diagnosis, log management, power management, fan management, and monitoring alarms through a management page and management protocols.
[0014] Intelligent Platform Management Interface (IPMI) refers to a type of management interface specification commonly used in out-of-band server management. It can be used to transmit management commands and status information between the BMC and the management terminal.
[0015] Redfish refers to a standardized management interface protocol used for out-of-band management of servers. The management end can send management requests to BMC and obtain management information through the Redfish interface.
[0016] Out-of-band management refers to a method of device management that does not rely on the operating system of the managed server. The BMC can receive external management commands and return management information through a separate management interface.
[0017] A license document, also known as a license file or activation file, is a document issued by a manufacturer to authorize users to use specific functions in a device. It contains authorization data such as the activation code required to activate that function.
[0018] Single Sign-On (SSO) refers to a login method where a user completes identity authentication once and then accesses multiple related systems or functions within the corresponding authorized scope.
[0019] Customer Relationship Management (CRM) is a system used by manufacturers to manage customer information and customer orders. Enterprise Resource Planning (ERP) is a system used by manufacturers to manage enterprise resources such as orders, production, and materials.
[0020] BMC is a server management and control system that provides management functions through a web page and protocols such as IPMI and Redfish. These functions include basic operations such as configuring hard drives and network cards, firmware upgrades, fault diagnosis, log management, power management, fan management, and monitoring alarms. Administrators and maintenance personnel can manage and monitor servers remotely without needing to be physically present in the data center.
[0021] In addition to the basic functions mentioned above, BMC also features advanced functions such as memory fault warning and self-repair, single sign-on, and system configuration locking. These advanced functions are not available to all customers; customers need to purchase them to use them. In related technologies, the license files for these advanced functions are unique to each device. Once the device verifies the activation code in the license file, the corresponding advanced functions are enabled.
[0022] To ensure the reliability of the authorization, the activation code needs to be associated with a specific device to prevent the same activation code from being used on other devices.
[0023] To address the issues of unreliable association between activation codes and devices and low security of device function authorization in related technologies, this invention provides a method and system for activating the function of a baseboard management controller. The unique device identifier of the target device is stored in a one-time programmable memory area. Once written, it cannot be modified and is only allowed to be read out of the target device when the authorization code verification is successful. Therefore, only the manufacturer's customer service device, possessing the authorization code, can obtain the unique device identifier; users and other personnel cannot obtain or tamper with it. Based on this, the activation code is generated according to the unique device identifier, but does not include the plaintext version of the unique device identifier. The baseboard management controller verifies the activation code using the unique device identifier in its first memory area. Thus, the unique device identifier is not exposed in plaintext during activation code transmission, and the activation code can only pass verification on its corresponding target device. Even if the activation code is copied to other devices, it will fail verification because the unique device identifier of other devices is different and unrewritable. After successful verification, the baseboard management controller outputs an activation signal, enabling preset controlled functions such as memory fault warning and self-repair, single sign-on, and system configuration locking. This solves the problem of unreliable association between activation codes and devices in related technologies, and improves the security of authorized functions of the baseboard management controller.
[0024] Example 1: Overall flow of the method for activating the function of the baseboard management controller.
[0025] Figure 1 This is a flowchart of a method for activating the function of a baseboard management controller, provided in an embodiment of the present invention.
[0026] This invention provides a method for activating the functions of a Baseboard Management Controller (BMC). The method obtains the protected device unique identifier (BUICK) from the manufacturer's side and generates an activation code that can only be verified on the target device, thereby activating the controlled functions in the BMC of the target device.
[0027] like Figure 1 As shown, the baseboard management controller function activation method provided in this embodiment of the invention, applied to manufacturer customer service equipment, may include: S101: Receive a function activation request for the baseboard management controller of the target device; wherein the target device includes a baseboard management controller and a first storage area, the first storage area is a one-time programmable storage area and stores the device unique identifier of the target device; S102: Send an authorization code to the target device, and after the target device verifies the authorization code, obtain the device unique identifier code in the first storage area; wherein, the device unique identifier code in the first storage area is only allowed to be read out to the outside of the target device when the authorization code verification is successful; S103: Using an activation code generation device, an activation code corresponding to the target device is generated based on the device's unique identifier. The activation code does not include the device's unique identifier in plaintext. S104: Send the activation code to the baseboard management controller so that the baseboard management controller reads the device unique identifier from the first storage area, verifies the activation code using the read device unique identifier, and outputs an activation signal after the verification is successful, so as to enable the controlled functions that are pre-installed in the baseboard management controller and are in an disabled state; wherein, the controlled functions include at least one of the following: memory fault warning and self-repair function, single sign-on function, and system configuration lock function.
[0028] In this embodiment of the invention, "vendor customer service equipment" refers to the computer equipment used by the vendor's customer service personnel. The vendor customer service equipment can connect to the target device via a dedicated tool, which may be, for example, a debugging tool connecting the vendor customer service equipment and the target device. The target device refers to the device for which controlled functions need to be activated, such as a server.
[0029] In some alternative implementations, the target device may also be other electronic devices that require activation codes for function authorization.
[0030] The first storage area is a One-Time Programmable (OTP) storage area, meaning it can only be written to once and the data cannot be modified after being written. For example, the first storage area can use an antifuse structure for the OTP. The Hardware Unique Identifier (HUID) is data generated and written to the first storage area before the target device leaves the factory, used to uniquely identify the target device. See Example 3 for one method of generating the HUID.
[0031] In step S101, the board management controller function activation request refers to the request to the manufacturer to activate the controlled functions in the BMC of the target device. For example, it can be an activation application submitted by the customer to the manufacturer's customer service device when purchasing additional controlled functions. It can include purchase information such as customer name, application quantity, product model of the target device and usage type.
[0032] In step S102, the authorization code refers to data held by the manufacturer and used for comparison and verification in the target device. The target device pre-stores a preset authorization code. After the manufacturer's customer service device sends the authorization code to the target device, the target device compares the received authorization code with the preset authorization code. If they match, the authorization code verification passes, and the HUID in the first storage area is allowed to be read out to the outside of the target device for acquisition by the manufacturer's customer service device. If they do not match, the authorization code verification fails, and the HUID cannot be read out to the outside of the target device. See Embodiment Two for a hardware implementation of the authorization code verification.
[0033] Because the HUID is stored in the OTP (Over-The-Air), it cannot be modified after being written, and only manufacturers with the authorization code can read it from external sources. Therefore, users and other personnel cannot obtain or tamper with the HUID. This reduces the risk that the device identity information used to bind the activation code can be obtained or modified.
[0034] In step S103, the activation code refers to data generated by the manufacturer based on the HUID, used to activate the controlled functions of the target device. Generating the activation code based on the HUID means that the HUID participates in the activation code generation calculation. For example, the HUID participates in forming the data to be signed, the HUID is encrypted and written into the activation code, or a verification code is obtained from the HUID and then written into the activation code. The activation code does not include the plaintext form of the HUID, meaning that the activation code does not directly carry the unprocessed HUID, and others cannot directly obtain the HUID by parsing the activation code. See Example 4 for the specific method of generating the activation code.
[0035] An activation code generation device is a device used to generate activation codes based on HUID. Manufacturer customer service equipment obtains the activation code corresponding to the target device through this device.
[0036] In step S104, the BMC reads the HUID from the first storage area of the local machine. This reading is internal to the target device, without authorization code control, and the HUID is not output to the outside of the target device; see Embodiment 2 for details. The BMC uses the read HUID to verify the activation code, meaning the BMC determines whether the activation code was generated based on the local machine's HUID and whether the activation code has been tampered with after generation. See Embodiment 4 for the specific verification method.
[0037] The activation signal refers to the signal output by the BMC after the activation code verification is successful, used to enable the controlled function. In this embodiment of the invention, the activation signal is a software signal, such as the activation signal Active_sig. When Active_sig is 0, the controlled function is in a disabled state. After the activation code verification is successful, Active_sig is set to 1, and the controlled function is enabled. When the activation code verification fails, Active_sig remains 0, and the controlled function is not enabled.
[0038] Controlled functions refer to functions pre-installed in the BMC, disabled by default, and enabled by an activation signal after successful activation code verification. These are advanced BMC functions that require a separate license purchase to use. Controlled functions can be software modules pre-installed in the BMC at the factory. Controlled functions include at least one of the following: memory fault warning and self-repair function, single sign-on function, and system configuration locking function.
[0039] Because the BMC reads the unmodifiable HUID from the first storage area of the local machine, the activation code can only be verified on its corresponding target device. Even if the activation code is copied to other devices, it will fail verification because the HUID of those other devices is different. In this way, the uniqueness and immutability of the HUID translate into a reliable binding between the activation code and the target device.
[0040] Figure 2 This is a schematic diagram illustrating an application scenario of a baseboard management controller function activation system provided in an embodiment of the present invention.
[0041] like Figure 2 As shown, this application scenario includes customers, manufacturer customer service equipment, customer relationship management systems, enterprise resource planning systems, activation code generation devices, and customer devices numbered from the first to the nth. The manufacturer customer service equipment is equipped with dedicated tools. Customer devices numbered from the first to the nth are the target devices, and each customer device is equipped with a Business Controller (BMC). Figure 2 The ellipsis in the text indicates the second customer equipment to the (n-1)th customer equipment. Figure 2In this system, the Customer Relationship Management System (CRM) processes the submission of application forms, the Enterprise Resource Planning (ERP) System generates order numbers, and the activation code generator generates activation codes. Taking the example of a customer purchasing controlled functionality after the equipment is already in use, the activation process in this scenario might include the following:
[0042] ① Submit an activation request. The customer submits an activation request for the controlled functions to the manufacturer's customer service device, providing purchase information such as the customer name, the number of units requested (e.g., 10 units), the product model and usage type of each customer's device (e.g., full version or trial version). The customer service personnel then fill in the application information form shown in Table 1.
[0043] Table 1 Application Information Form
[0044] In Table 1, "Customer Name" refers to the name of the customer applying for activation, and "Application Quantity" refers to the number of customer devices requiring activation of controlled functions, ranging from 1 to N. The application information for each customer device includes the product model, usage type, device serial number, and HUID. Usage types include full version, trial version, and vendor test version, represented by identifier 1, identifier 2, and identifier 3, respectively. Full version activation is permanent, trial version activation is valid for 60 days, and vendor test version is only for vendor testing. "XX" in Table 1 represents a specific customer name or product model.
[0045] like Figure 2 As shown, the manufacturer's customer service equipment connects to each customer's device via a dedicated tool and performs processes such as outputting authorization codes, writing symmetric keys, and obtaining device serial numbers and HUIDs. Specifically, the manufacturer's customer service equipment outputs authorization codes to each customer's device, obtains the HUID of each customer's device after successful authorization code verification, reads the device serial number of each customer's device, and then adds it to the application information table. The manufacturer's customer service equipment can also write the corresponding symmetric key to each customer's device after successful authorization code verification.
[0046] ② Customer service orders are placed. The manufacturer places an order for the customer relationship management system (CRM) equipment, and the CRM system processes the submitted application information form.
[0047] ③ Application Information Form. The Customer Relationship Management System sends the application information form to the Enterprise Resource Planning System.
[0048] ④ Order number and application information form. The Enterprise Resource Planning (ERP) system generates an order number and sends the order number and application information form to the activation code generator.
[0049] ⑤ Send activation code files. The activation code generation device performs the activation code generation process, that is, based on the order number and information such as the device serial number, HUID, and application quantity in the application information table, it generates activation codes for each customer's device and sends the activation code files to the Enterprise Resource Planning (ERP) system. The ERP system then sends the activation code files to the Customer Relationship Management (CRM) system.
[0050] ⑥ Send activation code file. The customer relationship management system sends the activation code file to the manufacturer's customer service equipment, for example, via email.
[0051] ⑦ Activation code package is distributed via out-of-band management interface. The manufacturer's customer service equipment distributes the activation code package via the out-of-band management interface of each customer device's BMC. The BMC of each customer device automatically identifies, verifies, and activates the controlled functions of the local activation code. The symmetric key is used to decrypt the encrypted public key, or the encrypted public key and HUID ciphertext, within the activation code.
[0052] In the above process, the activation code generation device can be a device or system independent of the manufacturer's customer service equipment. For example, the activation code generation device can be deployed on the manufacturer's server. The manufacturer's customer service equipment can interact directly with the activation code generation device, or it can... Figure 2 As shown, the order number and application information form are transmitted to the activation code generation device through the customer relationship management system and enterprise resource planning system, and the device then returns the activation code file.
[0053] In this embodiment of the invention, the activation code generation device can be a software module installed in the manufacturer's customer service equipment, or it can be integrated into the same device as the manufacturer's customer service equipment, with the activation code being generated directly by the manufacturer's customer service equipment. Regardless of the deployment method, the manufacturer's customer service equipment can obtain the activation code corresponding to the target device through the activation code generation device.
[0054] Figure 3 This is a schematic diagram of the structure of a target device provided in an embodiment of the present invention.
[0055] like Figure 3 As shown, the target device includes a BMC, a first storage area, a second storage area, and a readout control module. The BMC includes a receiving module, a verification module, a digest algorithm module, a public key algorithm module, a symmetric algorithm module, an activation module, controlled functions, a log module, a fourth storage area, and an activation code storage. The target device also has an authorization code input terminal and a device unique identifier output terminal.
[0056] like Figure 3As shown, the authorization code input terminal is connected to the readout control module, and the readout control module is connected to the device unique identifier (HUID) output terminal. The first storage area and the second storage area are respectively connected to the readout control module. The second storage area stores preset authorization codes. The readout control module verifies the authorization code input via the authorization code input terminal, and only allows the HUID to be output to the target device via the device unique identifier output terminal when the authorization code verification passes. The readout control module can be implemented using the classifier and the first buffer described in Embodiment 2.
[0057] like Figure 3 As shown, the first storage area is also directly connected to the verification module, forming an internal read path from the first storage area to the verification module. This internal read path does not pass through the read control module, is not controlled by externally input authorization codes, and does not output HUID to the target device.
[0058] like Figure 3 As shown, the receiving module and the verification module interact bidirectionally. The receiving module receives activation codes or activation code packages sent by the manufacturer's customer service equipment, for example, via the BMC's operation interface. The operation interface may include a Web graphical interface and an IPMI command-line interface. The digest algorithm module, public key algorithm module, and symmetric algorithm module interact bidirectionally with the verification module, allowing the verification module to call the corresponding algorithms. The fourth storage area is connected to the verification module, and the symmetric key in the fourth storage area is available for the verification module to read. The verification module reads the local HUID and completes the verification according to Scheme 1, Scheme 2, or Scheme 3 described in Embodiment 4.
[0059] like Figure 3 As shown, the verification module is connected to the activation module, which in turn connects to the controlled function via an activation signal. Upon successful verification, the activation module outputs an activation signal, enabling the corresponding controlled function. If verification fails, the activation module disables the controlled function. The verification module is also connected to a log module and an activation code storage unit. The log module records activation / deactivation status as an audit log. Verified activation codes are encrypted using a symmetric algorithm module and stored in the activation code storage unit. The activation code storage unit is located inside the BMC and can be, for example, an electrically erasable programmable read-only memory (EEPROM). This unit stores received activation codes that need to be parsed or verified by the BMC. It is independent of the third storage area (described later) used to store device serial numbers; the data stored in the two areas differs in purpose.
[0060] In some alternative implementations, before the controlled function is enabled, the baseboard management controller does not display the controlled function in the baseboard management controller's user interface, and returns a prompt message indicating no permission or no function for call requests for the controlled function initiated through the baseboard management controller's function call interface; after the controlled function is enabled, the baseboard management controller displays the controlled function in the user interface and responds to call requests.
[0061] In this embodiment of the invention, the function call interface refers to the interface through which a user invokes functions provided by the BMC in a command-line manner, such as the IPMI interface or the Redfish interface. The user interface can be, for example, the BMC's web interface.
[0062] Before a controlled function is enabled, it is not displayed on the BMC's web interface. When a user invokes the controlled function via command line through the IPMI or Redfish interface, the BMC returns a message indicating "no permission" or "this function does not exist." After the controlled function is enabled, it is displayed on the BMC's web interface, allowing users to access and use it. The BMC also responds to corresponding call requests initiated through the function call interface. This change in the presence of the controlled function before and after activation allows users to intuitively confirm the activation result and prevents unauthorized users from bypassing the interface to invoke the controlled function via command line.
[0063] For example, when memory fault warning and self-repair functions are enabled, the BMC can statistically analyze correctable memory errors, issue a warning when the number of errors reaches a preset threshold, and trigger corresponding memory repair processing. The preset threshold can be set based on the memory model and manufacturer's reliability requirements. When single sign-on is enabled, the BMC opens the configuration entry for single sign-on. After completing authentication once, users can log in to the BMC within the authorized scope without needing to re-enter their account and password. When system configuration locking is enabled, the BMC opens the system configuration lock switch. When this switch is enabled, the BMC refuses unauthorized system configuration modification operations, such as modifying Basic Input Output System (BIOS) settings or upgrading firmware.
[0064] Example 2: Restricted reading method for device unique identifier.
[0065] In this embodiment of the invention, the target device can implement restricted readout of HUID through hardware circuitry. Specifically, the target device can be equipped with a storage area for storing a preset authorization code and a comparison circuit. The comparison circuit controls the path for HUID to be output to the outside of the target device based on the comparison result between the externally input authorization code and the preset authorization code, while reserving the internal read path of the target device for the BMC.
[0066] In some optional implementations, the target device may further include a second storage area, a classifier, and a first buffer. The second storage area is a one-time programmable storage area and stores a preset authorization code. The first input terminal of the classifier receives the preset authorization code, and the second input terminal receives the authorization code. The output terminal of the classifier is connected to the enable terminal of the first buffer. The classifier enables the first buffer when the authorization code matches the preset authorization code and blocks the first buffer when they do not match. The read port of the first storage area is connected to the device unique identifier output terminal of the target device via the first buffer and is connected to the board management controller via the internal bus of the target device. Obtaining the device unique identifier in the first storage area includes: obtaining the device unique identifier via the device unique identifier output terminal; and the board management controller reading the device unique identifier in the first storage area via the internal bus.
[0067] In this embodiment of the invention, the equality detector refers to a circuit used to compare whether the data at two input terminals are the same. When the data at the two input terminals are the same, the equality detector outputs a high level. When the data at the two input terminals are different, the equality detector outputs a low level. The first buffer is a buffer with an enable input, such as a tri-state buffer. When the enable input is active, the buffer outputs the data at the input terminal to the output terminal. When the enable input is inactive, the buffer blocks the data at the input terminal, and the data cannot be output from the output terminal. The device unique identifier output terminal refers to the port on the target device used to output the HUID to the outside. The internal bus refers to the bus inside the target device that connects the first memory area and the BMC; the target device does not provide an access interface to the internal bus to the outside.
[0068] Figure 4 This is a schematic diagram of the structure of the storage area and readout control circuit in a target device provided in an embodiment of the present invention.
[0069] like Figure 4 As shown in the figure, a first client device, a second client device, and an nth client device are illustrated. The ellipsis indicates the third to (n-1)th client devices. Taking the first client device as an example, it includes a first storage area, a second storage area, a third storage area, a fourth storage area, a level divider, a first buffer, a second buffer, and a BMC. The second storage area stores a first preset authorization code, the first storage area stores a first device unique identifier, the third storage area stores a first serial number, and the fourth storage area stores a first symmetric key. The fourth storage area is located within the BMC. The second client device and the nth client device have the same structure, storing a second preset authorization code, a second device unique identifier, a second serial number, and a second symmetric key, respectively, and an nth preset authorization code, an nth device unique identifier, an nth serial number, and an nth symmetric key.
[0070] like Figure 4As shown, the authorization code input is connected to the second input of the grading unit of each client device, and the second storage area is connected to the first input of the grading unit. The output of the grading unit is connected to the enable terminal (en) of the first buffer and also to the enable terminal (en) of the second buffer. The read port of the first storage area is connected to the input of the first buffer, and the output of the first buffer is connected to the device unique identifier output; on the other hand, it is connected to the BMC via the internal bus of the target device. The third storage area is connected to the device serial number output. The key input is connected to the input of the second buffer of each client device, and the output of the second buffer is connected to the fourth storage area.
[0071] The first, second, and fourth storage areas can be OTP regions. The first and second storage areas can be different segments within the same OTP, or they can be set up as independent storage areas. Figure 4 The first and second storage areas are shown in the same frame, indicating that both are located within the target device, but not necessarily that they must use the same physical storage unit. The third storage area can be, for example, a read-enabled non-volatile memory such as an EEPROM. In one example, the fourth storage area is located in the BMC, while the first, second, and third storage areas are located on the motherboard of the target device.
[0072] When the target device leaves the factory, the manufacturer writes the preset authorization code and HUID into the target device's OTP, and writes the device serial number into the third storage area.
[0073] The external authorization code is sent to the equality detector via the authorization code input terminal. The equality detector compares the external authorization code with the preset authorization code in the second storage area. When they match, the equality detector outputs a high level, the enable terminal (en) of the first buffer is active, the first buffer is turned on, and the HUID in the first storage area is output externally via the device unique identifier output terminal for the manufacturer's customer service device to obtain. When they do not match, the equality detector outputs a low level, and the first buffer remains blocked. The device serial number in the third storage area can be directly read from the device serial number output terminal.
[0074] The BMC reads the HUID from the first storage area via its internal bus. This read path bypasses the first buffer, is not controlled by the license code verification result, and does not output the HUID to the target device. Only when the license code verification is successful and the first buffer is enabled will the HUID be output to the outside via the device's unique identifier output terminal. Therefore, the HUID is controlled externally by the license code, but internally it can be read by the BMC, ensuring both the manufacturer's need to obtain the HUID and the BMC's need to verify the activation code.
[0075] In some alternative implementations, the BMC can read the HUID in the first storage area via the internal bus of the target device, and the target device does not provide an access interface to the internal bus to the outside, so that the HUID can only be read to the outside of the target device via the device unique identifier output terminal when the authorization code verification is successful.
[0076] The above method ensures that the HUID's only external exit point on the target device is controlled by the license code. Users cannot bypass the license code to read the HUID via the internal bus, and the BMC's internal reading does not depend on the license code, thus completing the activation code verification without exposing the HUID.
[0077] In some optional implementations, the output of the equality checker can also be connected to the enable terminal of the second buffer. When the authorization codes match, the second buffer is enabled, and the vendor's customer service device can write the corresponding symmetric key to the fourth storage area through the key input terminal. The symmetric key is used by the BMC to decrypt the encrypted public key in the activation code, or the encrypted HUID and public key, as detailed in Embodiment 4.
[0078] In some optional implementations, after the authorization code verification passes, the HUID in the first storage area can be obtained, and the symmetric key corresponding to the target device can be written to the fourth storage area of the target device under the same authorization code verification state; when the authorization code verification fails, both the reading of HUID and the writing of symmetric key are blocked.
[0079] Therefore, the same authorization code verification result simultaneously controls two sensitive data paths. One path controls the reading of the HUID from the first storage area, and the other path controls the writing of the external symmetric key to the fourth storage area. Both HUID reading and symmetric key writing are conditional upon the same authorization verification passing. The vendor's customer service device can complete both operations in a single connection, and both operations remain blocked in the unauthorized state.
[0080] Because users or unauthorized personnel cannot obtain the correct authorization code, they cannot read the HUID or write the symmetric key. For example, if an incorrect authorization code is entered through the authorization code input terminal, the data at the two input terminals of the equality detector will be inconsistent, resulting in a low-level output. The enable terminals (en) of both the first and second buffers will become invalid and blocked. Therefore, the symmetric key cannot be written to the fourth storage area via the second buffer, and the HUID cannot be read from the device unique identifier output terminal via the first buffer.
[0081] Example 3: Method for generating a unique device identifier.
[0082] In this embodiment of the invention, the HUID can be generated by a dedicated hardware device and then written to the target device. Specifically, the delay differences between inverter chains caused by differences in device manufacturing processes can be used to form bit data bit by bit, and multiple bits of data can be accumulated to form the HUID.
[0083] In some optional implementations, the device unique identifier in the first storage area is generated and written by a device unique identifier generation device, which includes a first inverter chain group, a second inverter chain group, a selection circuit, a first counter, a second counter, a comparator, and a shift register. Both the first and second inverter chain groups include multiple inverter chains. The selection circuit is used to select one inverter chain from each of the first and second inverter chain groups according to a selection signal. The first and second counters are used to count the output signals of the two selected inverter chains, respectively. The comparator is used to compare the counting results of the first and second counters and output one bit of data. The shift register is used to shift and store the bit data output sequentially by the comparator under different selection signals to form the device unique identifier.
[0084] In this embodiment of the invention, an inverter chain refers to a circuit formed by connecting multiple inverters sequentially. A selection signal is used to determine which inverter chain participates in the counting process in the first and second inverter chain groups. Due to variations in device manufacturing processes, there are differences in transmission delay between each inverter chain, and the value of each bit data is difficult to determine in advance. Therefore, the resulting HUID has high randomness and uniqueness, and is difficult to deduce based on other information about the device.
[0085] In some optional embodiments, the device unique identifier generation device further includes a random number generator, which sequentially outputs multiple random numbers and provides each random number as a selection signal to a selection circuit. The selection circuit includes a first decoder, a second decoder, a first data selector, and a second data selector. The first decoder and the second decoder enable one inverter chain in the first inverter chain group and the second inverter chain group, respectively, according to the selection signal. The output signal of the disabled inverter chain is a fixed level. The first data selector and the second data selector select the output signal of the enabled inverter chain to the first counter and the second counter, respectively, according to the selection signal.
[0086] A random number generator is used to sequentially output multiple random numbers. Each random number serves as a selection signal, causing the selection circuit to determine the pair of inverter chains participating in the comparison for that round. For a 128-bit HUID, 128 random numbers can be used sequentially to form 128 bits of data. For a 512-bit device serial number, the corresponding number of bit generation operations can be performed sequentially. The 128-bit and 512-bit values in this embodiment are examples and do not limit the identifier code length. The random number determines which pair of inverter chains generates each bit, making the generation path unpredictable. The decoder enable and data selector selector are controlled by the same selection signal, ensuring that only one pair of inverter chains operates at a time, preventing interference from other inverter chains during counting.
[0087] In this embodiment of the invention, the random number generator may use a physical noise source to generate a random sequence by real-time acquisition of environmental noise signals; or, the random number generator may use a pseudo-random number generation module formed by a software algorithm, which uses the system time acquired when the system is powered on as a random seed to form a series of pseudo-random numbers.
[0088] When using physical noise sources, the randomness of HUID can be further improved by utilizing the delay differences between inverter chains to form bit data, building upon the inherent randomness of random numbers. Using a pseudo-random number generation module can save hardware costs and reduce hardware layout and wiring space. Although the randomness of random numbers generated by a pseudo-random number generation module is relatively weak, the randomness of HUID can still be improved through an identifier code generation circuit.
[0089] Figure 5 This is a schematic diagram illustrating a scenario in which a unique device identifier is generated and written in a production environment, as provided in an embodiment of the present invention.
[0090] like Figure 5 As shown, this scenario includes manufacturer customer service equipment, a customer relationship management system, an enterprise resource planning system, a production environment, an activation code generation device, and customer devices numbered from the first to the nth (the ellipsis indicates the second to the (n-1)th customer devices). A diagnostic server is deployed in the production environment, and this server contains a device unique identifier (BMC) generation device. The diagnostic server, deployed in the production environment and running a diagnostic system (Diagnostic, Diag), is used to generate and write device serial numbers and HUIDs, and optionally load activation codes, before the devices leave the factory. Each customer device is equipped with a BMC. Figure 5In this system, the Customer Relationship Management System (CRM) processes the submission of application information forms, the Enterprise Resource Planning (ERP) System generates order numbers, and the activation code generation device generates activation codes. If the customer selects the controlled functionality when purchasing the equipment, the generation and writing of the equipment serial number and HUID, as well as the loading of the activation code, can be completed during the equipment's production process. Specifically, this may include the following:
[0091] ① Customer service places an order. The manufacturer's customer service equipment places an order in the customer relationship management system (CRM) based on the customer's order information. The CRM system then processes the submission of an application information form. The application information form includes the customer's name, the quantity requested (e.g., 10 units), the product model, and the type of use.
[0092] ② Application Information Form. The Customer Relationship Management System sends the application information form to the Enterprise Resource Planning System.
[0093] ③ Order number and application information form. The Enterprise Resource Planning (ERP) system generates the order number and sends the order number and application information form to the diagnostic server in the production environment.
[0094] ④ Generate device serial number and device unique identifier, and supplement the application information table. Based on the number of applications, the diagnostic server calls the device unique identifier generation device to generate device serial numbers and HUIDs for each customer's device awaiting shipment, and supplements them to the application information table.
[0095] ⑤ Order number and application information form. The diagnostic server sends the order number and the completed application information form to the activation code generation device.
[0096] ⑥ Send activation code file. The activation code generation device performs the activation code generation process, generates activation codes corresponding to the number of devices, and sends the activation code file back to the diagnostic server.
[0097] ⑦ Write the device serial number and unique device identifier, and load the activation code. The diagnostic server sequentially writes the device serial number and HUID of each customer device into the corresponding customer device, and sequentially sends the activation code to the BMC of the corresponding customer device. The BMC verifies the activation code and then activates the controlled functions.
[0098] Through the above process, the corresponding controlled functions are activated when the customer's equipment leaves the factory, eliminating the need to provide the customer with an activation code file. The activation code can be encrypted and stored in the customer's BMC. Loading the activation code directly during the production stage is an optional method. This method allows the activation code to be written before the target device leaves the factory, reducing the manual activation steps after the customer receives the device.
[0099] Figure 6 This is a structural block diagram of a device unique identifier generation device provided in an embodiment of the present invention.
[0100] like Figure 6 As shown, the device unique identifier (HUID) generation device includes a selection circuit, a first inverter chain group, a second inverter chain group, a first counter, a second counter, a comparator, a shift register, and a write circuit. A selection signal is input to the selection circuit. The selection circuit is connected to the first inverter chain group and the second inverter chain group respectively, selecting one inverter chain from each. The first inverter chain group is connected to the first counter, and the second inverter chain group is connected to the second counter. The counting results of the first and second counters are sent to the comparator, which outputs bit data. Multiple bits of data corresponding to different selection signals sequentially enter the shift register, ultimately forming the HUID. The shift register is connected to the write circuit, and the formed HUID is written to the first memory area of the target device via the write circuit. Figure 6 In this context, the first storage area is a one-time programmable storage area, and the HUID in the first storage area can be read out when the authorization code verification is successful.
[0101] Figure 7 This is a schematic diagram of the specific structure of a device unique identifier generation device provided in an embodiment of the present invention.
[0102] like Figure 7 As shown, the device unique identifier generation device may include a control unit, a random number generator, random access memory (RAM), an identifier generation circuit, and a writing circuit. Random access memory (RAM) refers to a memory that can be randomly read and written and is used for temporary data storage. The identifier generation circuit includes the aforementioned first inverter chain, second inverter chain, selection circuit, first counter, second counter, comparator, and shift register; its specific structure is described in [reference needed]. Figure 8 .
[0103] like Figure 7 As shown, both the control unit and the identifier code generation circuit receive the clock signal CLK and the reset signal RSTn. The control unit also receives the start signal Start and the mode selection signal SEL[1..0], and outputs the random number Random[4..0], the enable signal Enable, and the gate signal Gate_control to the identifier code generation circuit as selection signals. The identifier code generation circuit returns the generated data to the control unit via the DATA[127..0] port. The random number generator is connected to the control unit, and the control unit reads the random number from the random number generator. The control unit is connected to the RAM and stores the obtained device serial number and HUID in the RAM. The RAM is connected to the write circuit, which reads the above data from the RAM and outputs it through the device unique identifier output terminal, the device serial number output terminal, and the activation code output terminal.
[0104] The operation of the control unit may include the following.
[0105] 1) Receive the start signal Start and mode selection signal SEL[1..0] input by the administrator. When Start is 1, the control unit starts; when Start is 0, the control unit stops running. When SEL[1..0] is 00, the device serial number is generated; when SEL[1..0] is 01, the HUID is generated.
[0106] 2) When Start is 1, the control unit enables the Enable signal and the Gate_control signal, i.e., Enable is 1 and Gate_control is 1. When Start is 0, the control unit disables Enable and Gate_control, i.e., Enable is 0 and Gate_control is 0.
[0107] 3) When Start is 1 and SEL[1..0] is 01, the control unit reads 128 5-bit random numbers from the random number generator and sends them sequentially to the identifier code generation circuit via the Random[4..0] port. The identifier code generation circuit generates 1 bit of data for each random number received, so generating a 16-byte (128-bit) HUID requires sending 128 random numbers. Similarly, when Start is 1 and SEL[1..0] is 00, generating a 64-byte (512-bit) device serial number requires sending 512 5-bit random numbers.
[0108] 4) When both Enable and Gate_control are valid, the identifier generation circuit reads a random number, generates 1 bit of data based on that random number and saves it, and then reads the remaining random numbers in sequence to form the device serial number or HUID.
[0109] 5) The control unit reads the data generated by the identifier generation circuit via the DATA[127..0] port. When SEL[1..0] is 00, the control unit reads data from DATA[127..0] 4 times, i.e., 128×4=512 bits, and concatenates them into the device serial number. When SEL[1..0] is 01, the control unit only needs to read data from DATA[127..0] once to obtain the HUID. Afterwards, the control unit stores the device serial number and HUID in RAM.
[0110] In this embodiment of the invention, the device unique identifier generation device may further include a control unit. The control unit is used to output a selection signal to the selection circuit and, according to the mode selection signal, control the device unique identifier generation device to form a device unique identifier when the mode selection signal is a first value and to form a device serial number when the mode selection signal is a second value. The control unit reads data stored in the shift register multiple times and concatenates it to form the device serial number when the mode selection signal is the second value. The number of bits in the device serial number is greater than the number of bits in the device unique identifier. The target device also includes a third storage area, and the writing circuit is further used to write the device serial number into the third storage area. The device serial number in the third storage area can be directly read.
[0111] In this embodiment of the invention, the device serial number (SN) refers to the product serial number used to identify the target device. The mode selection signal is used to control the device unique identifier generation device to generate either a HUID or a SN. The selection signal is used to determine the inverter chain participating in the counting in the first inverter chain group and the second inverter chain group; the two have different uses. In one specific setting, when the mode selection signal SEL[1..0] is 01, the HUID generation mode is entered. After the control unit completes the generation of 128-bit data, it reads DATA[127..0] once and uses it as the HUID. When the mode selection signal is 00, the SN generation mode is entered. The control unit reads the 128-bit data four times and concatenates them to form a 512-bit SN. The above values and lengths are merely examples.
[0112] HUID and SN employ different storage and access methods. HUID is written to the first storage area and controlled by the authorization code. SN is written to the third storage area, allowing vendor customer service devices, batch deployment tools, or BMCs to read it directly as needed. Thus, SN can be used for device location and activation code package matching, while HUID can be used for device binding in activation code verification. Reusing the same circuitry to generate HUID and SN also reduces hardware overhead.
[0113] Figure 8 This is a schematic diagram of the circuit structure of an identification code generation circuit provided in an embodiment of the present invention.
[0114] like Figure 8As shown, the first inverter chain group and the second inverter chain group each include 32 inverter chains, namely inverter chain 0, inverter chain 1 to inverter chain 31. The ellipsis in the figure indicates omitted inverter chains and omitted input and output terminals. The input terminals D[4..0] of the first decoder and the second decoder, as well as the selection control terminals S[4..0] of the first data selector and the second data selector, all receive the random number Random[4..0]. The enable terminal E of the first decoder and the second decoder receives the enable signal Enable, and its output terminals Q0, Q1 to Q31 are respectively connected to the second input terminals of the AND gates of inverter chains 0 to 31 in the corresponding inverter chain group. The input terminals D_0, D_1 to D_31 of the first data selector and the second data selector are respectively connected to the output terminals of inverter chains 0 to 31 in the corresponding inverter chain group, and their output terminals Q are respectively connected to the clock terminals clk of the first counter and the second counter.
[0115] like Figure 8 As shown, the enable terminals E of the first and second counters receive the gate signal Gate_control, and their output terminals Q[15..0] are connected to the input terminals D[15..0] of the first and second D flip-flops, respectively. The output terminals Q[15..0] of the first and second D flip-flops are connected to the first and second input terminals of the comparator, respectively. The output terminal of the comparator is connected to the input terminal D of the shift register, and the shift register outputs data through the output terminals Q[127..0] and the DATA[127..0] port. The clock terminals clk of the first D flip-flop, the second D flip-flop, and the shift register receive the clock signal CLK. The reset signal RSTn, after being inverted, is connected to the reset terminal R of the first counter, the second counter, the first D flip-flop, the second D flip-flop, and the shift register.
[0116] The decoder, when enabled (E = 1), outputs one of Q0 to Q31 as 1 and the rest as 0, depending on the value of input D[4..0]. For example, when D[4..0] is 00100, only Q4 outputs 1. When enabled (E = 0), all Q0 to Q31 output 0. The data selector outputs one of the data inputs D_0 to D_31 via output Q, depending on the value of selection control S[4..0]. For example, when S[4..0] is 00100, the data from input D_4 is output. The counter, when enabled (E = 1), counts the 1s in the clock input clk and outputs a 16-bit count value Q[15..0]. The counter does not count when enabled (E = 0) and clears its output when reset (R = 0). The shift register stores and shifts the 1-bit data from input D, ultimately forming 128 bits of data.
[0117] In some alternative implementations, the inverter chain includes an odd number of inverters connected in series and an AND gate; the first input of the AND gate is connected to the output of the final stage inverter, the second input of the AND gate is connected to an output of the decoder corresponding to the inverter chain, the output of the AND gate is connected to the input of the first stage inverter, and the output of the AND gate serves as the output of the inverter chain.
[0118] by Figure 8 Taking the five inverters shown as an example, one input of the AND gate is connected to the output of the final stage inverter, and the other input is connected to the output of the corresponding decoder. The output of the AND gate is fed back to the input of the first stage inverter and serves as the output of the inverter chain. When the second input of the AND gate is 1, the signal at the first input is transmitted in phase, the number of inversions in the loop is odd, and the loop has no steady state. Therefore, the output of the inverter chain continuously flips between 1 and 0. When the second input of the AND gate is 0, the output of the AND gate is fixed at 0. Inverter chains not enabled by the decoder maintain a fixed level and do not participate in the current round of counting. In this way, only the selected inverter chain participates in the counting at any given time, reducing the impact of the unselected inverter chain on the current counting process. Due to differences in device integration technology, the delay parameters of each inverter chain are not exactly the same, so the flipping of the output signal of each inverter chain is not exactly the same. The AND gate simultaneously serves as both oscillation enable and signal output.
[0119] The first data selector sends the output of the selected inverter chain in the first inverter chain group to the clock input clk of the first counter, and the second data selector sends the output of the selected inverter chain in the second inverter chain group to the clock input clk of the second counter. When Gate_control is active, the first counter and the second counter respectively count the number of changes of the corresponding output signal within the counting window.
[0120] In some optional embodiments, the device unique identifier generation device further includes a first D flip-flop and a second D flip-flop; the input of the first D flip-flop is connected to the output of the first counter and the output is connected to the first input of the comparator, the input of the second D flip-flop is connected to the output of the second counter and the output is connected to the second input of the comparator; the first D flip-flop and the second D flip-flop sample the counting results of the first counter and the second counter respectively, and output the sampled and stabilized counting results to the comparator.
[0121] This sampling process can reduce the possibility of comparison anomalies caused by directly using count values that have not yet stabilized.
[0122] The comparator compares the two count results. In one example, the comparator outputs 1 when the first count result is not greater than the second count result; and outputs 0 when the first count result is greater than the second count result. This one bit result is written to a shift register. The control unit changes the selection signal and repeats the above process, and the shift register sequentially stores multiple comparison results, ultimately forming the 128-bit data represented by DATA[127..0].
[0123] Taking the generation of a 128-bit HUID as an example, the operation of the identifier generation circuit can include the following:
[0124] 1) The identification code generation circuit reads a random number sent by the control unit through the Random[4..0] port, for example, Random[4..0] is 10111.
[0125] 2) Since Enable is 1, the first and second decoders are enabled. D[4..0] is 10111, corresponding to the decimal number 23. The output terminal Q23 of both the first and second decoders outputs 1. The inverter chains 23 in the first and second inverter chains are enabled respectively, and each outputs a signal that toggles between 1 and 0.
[0126] 3) Since the selection control terminals S[4..0] of both the first and second data selectors are 10111, the output signals of the two inverter chains 23 are selected to the clock terminals clk of the first and second counters via input terminal D_23. Because Gate_control is 1, and the reset terminals R of the first and second counters are invalid after the reset, the first and second counters are in a counting state, counting the 1s in their respective output signals. After the count values are sampled and stabilized by the first and second D flip-flops, they are input to the first and second input terminals of the comparator.
[0127] 4) For example, the count value at the first input of the comparator is 12 and the count value at the second input is 14. Since 12 < 14, the comparator outputs 1.
[0128] 5) The shift register receives the 1 output by the comparator through the input terminal D and saves it to the least significant bit of Q[127..0], that is, Q[0] is 1.
[0129] This completes the generation of 1 bit of data in HUID. Read the remaining 127 random numbers in sequence and repeat steps 1) to 5) above to generate a 128-bit HUID.
[0130] Figure 9 This is a schematic diagram of a writing circuit provided in an embodiment of the present invention.
[0131] like Figure 9 As shown, the writing circuit involves RAM, a device unique identifier output terminal, a device serial number output terminal, a first matching qualifier to an nth matching qualifier, a first output buffer to an nth output buffer, an activation code packet, and an activation code output terminal. The ellipses in the figure indicate omitted data groups, matching qualifiers, and output buffers. The RAM stores multiple sets of SN and HUID, namely the first serial number and the first device unique identifier, the second serial number and the second device unique identifier, up to the nth serial number and the nth device unique identifier. The RAM writes the corresponding data to the target device via the device unique identifier output terminal and the device serial number output terminal. The activation code packet includes the first serial number and the first activation code, the second serial number and the second activation code, up to the nth serial number and the nth activation code.
[0132] like Figure 9 As shown, the line containing the device serial number output is also connected to the first input of each matching qualifier. The second input of each matching qualifier is connected to the first to the nth serial number in the activation code packet. The output of each matching qualifier is connected to the enable terminal (en) of the corresponding output buffer. The input of each output buffer is connected to the first to the nth activation code in the activation code packet, and the output of each output buffer is connected to the activation code output terminal. The matching qualifier outputs a high level when the data at the two inputs are the same, and outputs a low level when they are different. The output buffer outputs the data at the input when the enable terminal (en) is active, and blocks the data when the enable terminal (en) is inactive.
[0133] Taking writing a first serial number and a first device unique identifier to a first customer device and loading a first activation code as an example, the working process of the writing circuit may include the following:
[0134] 1) The writing circuit sequentially reads the generated SN and HUID from the RAM. First, it reads the first serial number, which is simultaneously input to the first input terminal of the first matching qualifier and the nth matching qualifier. The second input terminals of the first matching qualifier to the nth matching qualifier respectively receive the first serial number to the nth serial number from the activation code packet.
[0135] 2) At this time, both inputs of the first matching qualifier are the first sequence number. The first matching qualifier outputs a high level, while the other matching qualifiers output a low level.
[0136] 3) The first output buffer is turned on, while the other output buffers are blocked, so that only the first activation code can be output through the activation code output terminal.
[0137] 4) Write the first serial number to the third storage area of the first customer device via the device serial number output terminal.
[0138] 5) The unique identifier of the first device is written to the first storage area of the first customer device via the device unique identifier output terminal. The first storage area can be an OTP with an anti-fuse structure. Once written, the data cannot be modified, thereby preventing users or malicious personnel from tampering with it.
[0139] 6) The first activation code is sent to the BMC of the first client device via the activation code output terminal, and the BMC verifies it.
[0140] The writing process for other customer devices is similar and will not be described in detail here.
[0141] In some alternative implementations, the writing circuit writes the HUID to a first memory area, which is a one-time programmable memory area with an antifuse structure. Since the HUID cannot be modified after being written, a user cannot change the HUID of a second client device to the HUID of the first client device. This prevents a user from activating the controlled functions of multiple devices by modifying the HUIDs of multiple devices to the same value after purchasing only one activation key.
[0142] In this embodiment of the invention, there can be multiple target devices, each with a device serial number. Each target device's activation code is encapsulated in an activation code package corresponding to its respective device serial number. The activation code package includes n device serial numbers and n corresponding activation codes, where n is an integer greater than 1. The writing circuit includes n matching qualifiers and n output buffers. The first input of the i-th matching qualifier receives the device serial number of the target device currently to be written, and the second input receives the i-th device serial number from the activation code package. The output is connected to the enable terminal of the i-th output buffer. The input of the i-th output buffer receives the i-th activation code from the activation code package, and the output of each output buffer is connected to the activation code output terminal. Here, i takes integer values from 1 to n. The writing circuit is also used to load the activation code corresponding to the device serial number of the target device to be written to the baseboard management controller of the target device via the activation code output terminal before the target device leaves the factory.
[0143] During the production phase, the writing circuit selects the corresponding activation code according to the SN and loads it into the BMC. The controlled functions are already activated when the device leaves the factory, eliminating the need for manual loading for each device individually. It should be noted that... Figure 9 The matching qualifier and output buffer in the circuit belong to the write circuit and are used to select the corresponding activation code based on the SN during the production stage. Figure 4 The classifier, first buffer, and second buffer used to control HUID readout on the target device side are not the same set of devices.
[0144] Example 4: Method for generating and verifying activation codes.
[0145] In this embodiment of the invention, the activation code can be generated based on a digital signature. Specifically, HUID participates in the activation code generation calculation, but is not transmitted with the activation code in plaintext form; the BMC uses its own HUID for verification. Depending on the HUID participation method, Scheme 1, Scheme 2, or Scheme 3 can be adopted.
[0146] Figure 10 This is a schematic diagram of the functional modules of a manufacturer's customer service device and an activation code generation device provided in an embodiment of the present invention.
[0147] like Figure 10 As shown, the manufacturer's customer service equipment and activation code generation device include an acquisition module, an information conversion module, an algorithm identifier, a digest algorithm module, a public key algorithm module, a symmetric encryption module, an activation code generation module, and a sending module. Specifically, the manufacturer's customer service equipment may include an acquisition module and a sending module, and the activation code generation device may include the information conversion module, algorithm identifier, digest algorithm module, public key algorithm module, symmetric encryption module, and activation code generation module.
[0148] like Figure 10 As shown, the acquisition module is connected to the information conversion module, which in turn is connected to the activation code generation module, which in turn is connected to the sending module. The acquisition module is also connected to the algorithm identifier, which in turn is connected to the activation code generation module. The digest algorithm module, public key algorithm module, and symmetric encryption module interact bidirectionally with the activation code generation module.
[0149] The acquisition module receives a function activation request from the baseboard management controller (BMC) of the target device, sends an authorization code to the target device, and, after the target device verifies the authorization code, acquires the HUID from the first storage area and determines the authorization information of the target device based on the BMC function activation request. The acquisition module can obtain the HUID through the authorization reading process described in Embodiment 2, and can also read the SN from the third storage area. The acquisition module acquires information such as the order number and application information table and provides it to the information conversion module, and can also receive the algorithm identifier set by the manufacturer administrator. The information conversion module converts the order number and information from the application information table into standardized structured data for processing by the activation code generation module. The activation code generation module calls the digest algorithm module, public key algorithm module, and symmetric encryption module according to the algorithm identifier to perform calculations and processing on the structured data to generate the activation code. The symmetric encryption module is used to encrypt the public key and other data to ensure their security during transmission. The sending module sends the activation code to the BMC of the target device.
[0150] In this embodiment of the invention, authorization information refers to data describing the authorized content obtained by the target device, such as usage type, validity period, order identifier, and activation code creation time. Usage type may include, for example, a full version, a trial version, and a vendor test version.
[0151] In this embodiment of the invention, the authorization information may include an order identifier, a serial number (SN), a usage type, an expiration time, and a creation time; the order identifier consists of an order number and a system timestamp; the expiration time is determined according to the usage type.
[0152] In one example, the information conversion module can convert the order number and the information corresponding to a target device in the application information table into application information structure data as shown in Table 2. For n target devices, it can be converted into n structure data.
[0153] Table 2 Application Information Structure Data
[0154] In Table 2, Order_ID consists of the order number and system timestamp, serving as a unique identifier for the order and can be used by customer service personnel for querying, after-sales maintenance, and management. device_1_type indicates the type of controlled function used on the target device, with values of 1, 2, and 3 representing the official version, trial version, and vendor test version, respectively. device_1_valid_date indicates the validity period of the activation code. A value of 0xFFFF indicates permanent validity when the usage type is the official version. A value of 0x003C indicates a validity period of 60 days, after which the controlled function will expire. A value from 0x0001 to 0x001E corresponds to 1 to 30 days when the usage type is the vendor test version, set by the vendor's testers for debugging and maintenance. device_1_create_time is filled in by the activation code generator based on the current system time when generating the activation code. Reserve is a reserved field for future upgrades and expansions.
[0155] It should be noted that the HUID field in Table 2 is only used for internal processing by the activation code generation module and is not written into the activation code in plaintext. In Scheme 1, HUID is combined with authorization information to form the data to be signed, and the authorization information in the activation code consists of all fields in Table 2 except for the HUID field. In Scheme 2, HUID is encrypted with a symmetric key and transmitted in ciphertext form along with the activation code. In Scheme 3, HUID is used to calculate the verification code.
[0156] In this embodiment of the invention, the digest algorithm module can provide a Secure Hash Algorithm (SHA), such as SHA256, SHA384, or SHA512. The public key algorithm module can provide an RSA asymmetric cryptographic algorithm (Rivest-Shamir-Adleman, RSA), such as RSA2048, RSA3072, or RSA4096. The symmetric encryption module can employ the Advanced Encryption Standard (AES) or the SM4 block cipher algorithm.
[0157] In this embodiment of the invention, the activation code generation module can call a digest algorithm and a public key algorithm based on an algorithm identifier. The algorithm identifier is set by the vendor administrator, and different encoded values represent different combinations of the digest algorithm and the public key algorithm. The BMC calls the corresponding digest algorithm and public key algorithm based on the algorithm identifier in the activation code. In this way, vendors can choose the algorithm combination according to their security requirements without modifying the activation code generation and verification process.
[0158] The baseboard management controller function activation method provided in this embodiment of the invention may further include: determining the authorization information of the target device according to the baseboard management controller function activation request; generating an activation code corresponding to the target device according to the device unique identifier using an activation code generation device, including: combining the device unique identifier and the authorization information into data to be signed; performing a digest operation on the data to be signed to obtain a digest value, and digitally signing the digest value using a private key to obtain a signature value; generating an activation code according to the authorization information and the signature value, wherein the activation code does not include the device unique identifier; the activation code is used by the baseboard management controller to combine the read device unique identifier and the authorization information in the activation code into data to be verified, perform a digest operation on the data to be verified, and determine that the verification is successful when the operation result is consistent with the digest value obtained by verifying the signature value using the public key corresponding to the private key.
[0159] The above method is referred to as Scheme 1. The public key corresponding to the private key is used for signature verification on the target device side. The digital signature is used to verify whether the data to be signed has changed after its generation and to provide a signature basis for verification based on the local HUID. Since the activation code does not carry the plaintext HUID, the client cannot directly obtain the HUID by parsing the activation code during transmission. When other devices have different HUIDs, the data to be verified they regenerate will be different, and the digest results will also be different. Therefore, the activation code cannot be reused to complete the verification.
[0160] Figure 11 This is a flowchart of an activation code generation process provided in an embodiment of the present invention.
[0161] Figure 11Taking Scheme 1 as an example, and illustrating it using the algorithm identifier Algorithm indicating the use of a combination of SHA256 and RSA2048 algorithms. Figure 11 As shown, the activation code generation process may include the following steps.
[0162] (1) The information conversion module generates authorization information Application_Info based on the order number and application information, and combines the authorization information with HUID to form data to be signed. The composition format of the authorization information can be exemplified as follows: Application_Info { Order_ID: No.123… SN: CN2345AB6789… device_1_type: 1 (Official version) device_1_valid_date: 0xFFFF (Official Version) device_1_create_time:2026.06.08 11:10:30 Reserve: 00… }
[0163] (2) The activation code generation module calls the digest algorithm SHA256 according to the algorithm identifier Algorithm to perform digest operation on the data to be signed and obtain the digest value Hash_value, that is, Hash_value=Hash(Application_Info+HUID); where Hash() represents digest operation and + means concatenating the data before and after in sequence.
[0164] (3) The activation code generation module calls the public key algorithm RSA2048 to generate the public key Pub_Key and the private key Pri_Key.
[0165] (4) The activation code generation module uses the private key Pri_Key to digitally sign the digest value Hash_value to obtain the signature value SignatureValue, that is, SignatureValue=DEC_Pri_Key(Hash_value), where DEC_Pri_Key() indicates that the private key Pri_Key is used to perform the decryption operation of the RSA algorithm. In the RSA algorithm, the operation form of digital signing with the private key is the same as that of decryption operation with the private key.
[0166] (5) Write the authorization information, algorithm identifier, signature value and public key data length into the data offset identifier Data_Offset. The format of the data offset identifier is shown in Table 3 below.
[0167] (6) The activation code generation module obtains the symmetric key AES_Key corresponding to the target device and calls the symmetric encryption module to encrypt the public key Pub_Key using the symmetric key AES_Key to obtain the encrypted public key ENC(Pub_Key). The length of the encrypted public key remains unchanged, for example, it is still 256 bytes.
[0168] (7) Base64 encode the data offset identifier, authorization information, algorithm identifier, signature value and encrypted public key to obtain the activation code. The activation code does not contain HUID, that is, Activation_Code=Base64[Data_Offset+Application_Info+Algorithm+SignatureValue+ENC(Pub_Key)], where Base64 encoding refers to an encoding method that converts binary data into printable characters, Base64[ ] represents Base64 encoding operation, and ENC() represents symmetric encryption operation.
[0169] The symmetric key AES_Key in step (6) is the same as the symmetric key pre-written in the fourth storage area of the target device so that the BMC of the target device can decrypt and obtain the public key.
[0170] The baseboard management controller function activation method provided in this embodiment of the invention may further include: after the authorization code verification is passed, writing the symmetric key corresponding to the target device into the fourth storage area of the target device, wherein the fourth storage area is a one-time programmable storage area and is located in the baseboard management controller; generating an activation code based on the authorization information and signature value may include: encrypting the public key with the symmetric key to obtain the encrypted public key, and generating an activation code based on the authorization information, signature value and encrypted public key; the activation code is also used by the baseboard management controller to decrypt the encrypted public key with the symmetric key in the fourth storage area to obtain a public key for verifying the signature value.
[0171] Different target devices can correspond to different symmetric keys. For example, the first client device to the nth client device can correspond to the first symmetric key to the nth symmetric key, respectively. Once written to the OTP, the symmetric key is not rewritten. The public key is transmitted in ciphertext form along with the activation code. Only target devices that have pre-written the corresponding symmetric key can decrypt the public key, thus ensuring the security of the public key during transmission and preventing tampering.
[0172] In this embodiment of the invention, the symmetric key can be written into the fourth storage area during the manufacturing stage of the target device.
[0173] Specifically, the public key can be pre-stored in the target device, for example, written into the storage area that BMC can read when the device leaves the factory. The activation code does not carry the public key, and BMC uses the pre-stored public key to verify the signature value.
[0174] In this embodiment of the invention, the activation code is obtained by Base64 encoding of the data offset identifier, authorization information, algorithm identifier, signature value and encrypted public key. The data offset identifier records the data length of the authorization information, algorithm identifier, signature value and encrypted public key. After Base64 decoding the activation code, BMC determines the position of each field in the activation code according to the data offset identifier.
[0175] The data offset identifier Data_Offset can be set in the active terminal, and is 8 bytes (64 bits). Bits 63 to 48, 47 to 32, 31 to 16, and 15 to 0 record the data lengths of the authorization information Application_Info, algorithm identifier Algorithm, signature value SignatureValue, and encrypted public key ENC (Pub_Key) in hexadecimal, as shown in Table 3.
[0176] Table 3 Data Offset Identifier
[0177] In one example, if the authorization information includes a 16-byte HUID field, then according to Table 2, the length of the application information structure data is 133 bytes, the algorithm identifier is 1 byte, the signature value is 256 bytes, the public key is 256 bytes, and the data offset identifier is 0085 0001 0100 0100. In Scheme 1, the HUID is not sent with the activation code. With the length of the remaining fields remaining unchanged, the length of the authorization information is 117 bytes, and the corresponding data offset identifier is 0075 0001 0100 0100. Using the data offset identifier allows the length of each field to vary, and BMC can still accurately parse the activation code.
[0178] Figure 12 This is a flowchart of an activation code verification process provided in an embodiment of the present invention.
[0179] Figure 12 Take Option 1 as an example. Figure 12 As shown, the activation code verification process may include the following steps.
[0180] (1) The receiving module receives the activation code Activation_Code, and the verification module performs Base64 decoding on the activation code to obtain the data offset identifier, authorization information, algorithm identifier, signature value and encrypted public key.
[0181] (2) The verification module reads the first 8 bytes of the data offset identifier Data_Offset and calculates the data offset based on the data offset identifier. For example, based on the 0075 0001 0100 0100 recorded therein, it reads 117 bytes, 1 byte, 256 bytes and 256 bytes of data sequentially starting from the 9th byte, respectively obtaining the authorization information Application_Info, the algorithm identifier Algorithm, the signature value SignatureValue and the encrypted public key ENC (Pub_Key).
[0182] (3) The verification module reads the symmetric key AES_Key in the fourth storage area, decrypts the encrypted public key ENC(Pub_Key), and obtains the public key Pub_Key.
[0183] (4) The verification module calls the public key algorithm RSA2048 according to the algorithm identifier Algorithm, and verifies the signature value SignatureValue using the public key Pub_Key to obtain the first digest value Hash_value, that is: Hash_value=ENC_Pub_Key(SignatureValue), where ENC_Pub_Key() indicates that the encryption operation of the RSA algorithm is performed using the public key Pub_Key.
[0184] (5) The verification module reads the local HUID in the first storage area and combines it with the authorization information Application_Info in the same order as the generation side to form the data to be verified.
[0185] (6) The verification module calls the hash algorithm SHA256 to perform hash operation on the data to be verified and obtains the second hash value Hash_value', that is, Hash_value'=Hash(Application_Info+HUID).
[0186] (7) The verification module determines whether the first digest value and the second digest value are consistent. If they are consistent, the activation code verification passes, and the BMC activates the controlled function, that is, the activation module sets the activation signal Active_sig to 1. If they are inconsistent, it means that the activation code has been tampered with, or the activation code was not generated for the local machine. The activation code verification fails, the BMC does not activate the controlled function, the activation signal Active_sig remains at 0, and the log is recorded.
[0187] The baseboard management controller function activation method provided in this embodiment of the invention may further include: determining the authorization information of the target device according to the baseboard management controller function activation request; after the authorization code verification is passed, writing the symmetric key corresponding to the target device into the fourth storage area of the target device, the fourth storage area being a one-time programmable storage area located in the baseboard management controller; generating an activation code corresponding to the target device according to the device unique identifier using an activation code generation device, which may include: performing a digest operation on the data to be signed containing the device unique identifier and authorization information to obtain a digest value, and digitally signing the digest value using a private key to obtain a signature value; encrypting the device unique identifier and the public key corresponding to the private key together using a symmetric key to obtain ciphertext; generating an activation code based on the ciphertext, authorization information, and signature value; the activation code is used by the baseboard management controller to decrypt the ciphertext using the symmetric key in the fourth storage area, and determining that the verification is passed when the device unique identifier obtained after decryption is consistent with the read device unique identifier and the signature value is verified using the decrypted public key.
[0188] The above method is referred to as Scheme Two. In Scheme Two, the manufacturer uses the symmetric key corresponding to the target device to encrypt the HUID and public key together to obtain ciphertext. The activation code carries this ciphertext, authorization information, and signature value. After receiving the activation code, the target device reads the symmetric key from the fourth storage area and decrypts the ciphertext to obtain the HUID and public key. The BMC compares the decrypted HUID with the local HUID in the first storage area. If they match, the decrypted public key is used to verify the signature value. This method ensures that the HUID is not transmitted in plaintext with the activation code, and verifies the device correspondence through comparison with the local HUID. Only target devices with a pre-set corresponding symmetric key can decrypt the HUID and compare it with the local HUID.
[0189] The baseboard management controller function activation method provided in this embodiment of the invention may further include: determining the authorization information of the target device according to the baseboard management controller function activation request; generating an activation code corresponding to the target device according to the device's unique identifier using an activation code generation device, which may include: generating random parameters and performing a one-way operation on the device's unique identifier and random parameters to obtain a verification code; combining the verification code and authorization information into data to be signed, performing a digest operation on the data to be signed to obtain a digest value, and digitally signing the digest value using a private key to obtain a signature value; generating an activation code based on the verification code, random parameters, authorization information, and signature value; the activation code is used by the baseboard management controller to perform a one-way operation on the read device's unique identifier and the random parameters in the activation code, and when the operation result is consistent with the verification code in the activation code, and the signature value is verified using the public key corresponding to the private key, the verification is deemed successful.
[0190] The above method is referred to as Scheme 3. In Scheme 3, the activation code generation module generates random parameters and uses HUID and the random parameters as inputs for a one-way operation to obtain a verification code. The data to be signed includes the verification code and authorization information. The activation code includes the verification code, random parameters, authorization information, and signature value, but does not include HUID. After receiving the activation code, the target device reads its own HUID and performs the same one-way operation with the random parameters from the activation code, obtaining a new local verification code. If the local verification code matches the verification code in the activation code, and the signature verification passes, the verification is successful. The random parameters are sent along with the activation code, enabling the target device to reproduce the verification code calculation process on the generation side. The HUID itself is not sent with the activation code.
[0191] One-way operations can be performed using SHA256, and random parameters can be regenerated each time an activation code is generated, ensuring that the verification code generated for the same target device is different each time.
[0192] In some optional implementations, after the activation code is verified, the BMC encrypts the activation code using a symmetric key and stores the encrypted activation code in the activation code storage in the BMC; the BMC's log module records the operation results such as whether the activation code has been activated or not, as an audit record.
[0193] The activation code is stored in encrypted form, reducing the risk of it being read and copied on the device. Audit logs facilitate traceability of activation operations for both manufacturers and customers. Without causing technical inconsistencies, Solutions 1, 2, and 3 can all be used in conjunction with the methods described in Embodiments 2, 3, 5, and 6.
[0194] Example 5: Batch activation method.
[0195] In some alternative implementations, manufacturers can perform batch activation of multiple target devices. Specifically, activation codes for multiple target devices can be distributed in a single activation code package. Each target device's BMC locates its own activation code based on a publicly readable SN, and then completes the binding verification using a protected HUID.
[0196] In this embodiment of the invention, there are multiple target devices, and each target device further includes a third storage area storing the device serial number of the target device, which can be directly read. The baseboard management controller function activation method provided in this embodiment of the invention may further include: reading the device serial number in the third storage area of each target device, and encapsulating the activation code of each target device with its corresponding device serial number into an activation code package; sending the activation code to the baseboard management controller, which may include: sending the activation code package to the baseboard management controller of each target device respectively, so that each baseboard management controller reads the device serial number in its own third storage area, and identifies the activation code corresponding to the read device serial number from the activation code package as the activation code to be verified.
[0197] In this embodiment of the invention, the third storage area refers to the storage area in the target device used to store the SN and allow the SN to be directly read, such as an EEPROM. The activation code package refers to a data set including multiple SNs and activation codes corresponding to each SN, such as a total activation code file. The SN is used to locate the local activation code, while the HUID is used for subsequent device binding verification; the two have different functions.
[0198] Figure 13 This is a schematic diagram illustrating the distribution of activation code packages to multiple client devices via an out-of-band management interface, as provided in an embodiment of the present invention.
[0199] like Figure 13 As shown, the manufacturer's customer service equipment stores activation code packages and has a sending module, which provides the activation code packages to the sending module. Each of the first, second, and nth customer devices has a Business Controller (BMC), and the ellipsis indicates the third to (n-1)th customer devices. Each BMC includes an out-of-band management interface and a verification module; the out-of-band management interface connects to the verification module. The sending module sends the activation code packages to each customer device via the out-of-band management interface of the BMC. Each BMC's out-of-band management interface provides the activation code packages to the verification module, which identifies and verifies the local activation code. The activation codes for multiple target devices each correspond to their respective serial numbers (SNs).
[0200] In some optional implementations, the activation code package is distributed via the out-of-band management interface of each BMC. The out-of-band management channel where the out-of-band management interface is located adopts the existing encrypted management channel of the target device, and the activation code package does not go through the public cloud server for relay.
[0201] For multiple target devices, the activation code package can be sent in a one-to-many manner, meaning the same activation code package is sent to multiple target devices, and each target device identifies the activation code corresponding to its own serial number (SN). The batch activation tool simply imports the same activation code package into all target devices; the task of matching activation codes is handled by the BMC (Browser Control Center) of each target device.
[0202] In some alternative implementations, the manufacturer's customer service equipment first reads the target device's serial number (SN), then selects the activation code corresponding to the SN from a plurality of activation codes and sends it to the target device individually.
[0203] Figure 14 This is a schematic diagram of a module structure for identifying a local activation code from an activation code package, provided as an embodiment of the present invention.
[0204] like Figure 14 As shown, the activation code packet includes a first serial number and a first activation code, a second serial number and a second activation code, up to the nth serial number and the nth activation code; ellipses indicate omitted data groups. The BMC includes a receiving module, a buffer, activation code matching logic, a verification module, a digest algorithm module, a public key algorithm module, a symmetric algorithm module, controlled functions, a log module, a fourth storage area, and an activation code memory. The buffer can be, for example, RAM. The third storage area is located outside the BMC.
[0205] like Figure 14 As shown, the activation code packet input receiving module is connected to a buffer, which in turn is connected to the activation code matching logic. The third storage area provides the local device serial number to the activation code matching logic, which then provides the local activation code to the verification module. The digest algorithm module, public key algorithm module, and symmetric algorithm module interact bidirectionally with the verification module. The fourth storage area is connected to the verification module. The verification module is connected to the controlled function via an activation signal and is also connected to the log module and the activation code storage.
[0206] The BMC's receiving module receives the activation code packet and caches it in RAM. The activation code matching logic reads the local SN from the third storage area, matches it with each group of SNs in the activation code packet, and outputs the local activation code corresponding to the local SN. Subsequently, the verification module performs the verification described in Example 4 on the activation code based on the local HUID. The activation code matching logic can be used as part of the verification module to identify the local activation code. After successful verification, the verification module outputs an activation signal to activate the controlled function, and the log module records the operation result. The verified activation code can be stored in the activation code memory.
[0207] In some optional implementations, the BMC can cache the activation code package in RAM, read the local SN in the third storage area, initialize the traversal index to 1, sequentially read the SNs in the activation code package corresponding to the traversal index and compare them with the local SN; if they match, output the activation code corresponding to that SN; if they do not match, increment the traversal index by 1, and end the traversal when the traversal index is greater than the total number of SNs in the activation code package.
[0208] Figure 15 This is a flowchart for identifying a local activation code from an activation code package, as provided in an embodiment of the present invention.
[0209] like Figure 15 As shown, the identification process may include the following steps.
[0210] (1) After starting, the BMC reads the local device serial number in the third storage area, which is recorded as sn.
[0211] (2) Initialize the traversal index to 1, i.e., i=1.
[0212] (3) Traverse the activation code package and read the i-th serial number in it, denoted as SN(i).
[0213] (4) Determine whether sn is equal to SN(i). If so, output the i-th activation code in the activation code package corresponding to SN(i), and then end.
[0214] (5) If not, execute i=i+1 and determine whether i>N is satisfied, where N is the total number of SNs in the activation code package. If not, return to step (3) to continue reading. If yes, it means that the traversal is complete and no matching item is found, and the process ends.
[0215] Because BMC automatically selects the activation key based on the device's serial number (SN), customers do not need to distinguish activation key files for each device, improving the efficiency of batch activation across multiple devices and avoiding the accidental loading of activation keys from other devices onto a single device. Furthermore, this method, with matching handled by BMC, does not increase hardware costs.
[0216] In some optional implementations, multiple target devices can be activated in a one-to-one manner; each target device corresponds to an activation code file, and each activation code file contains only one activation code and the corresponding target device's SN; a batch deployment tool is deployed on the management end, which reads the SN of each target device, finds the activation code corresponding to that SN from multiple activation code files, and loads it into the corresponding target device's BMC; the management end includes a cloud management center or a server management and control system.
[0217] For example, the activation code file device_1.lic includes the SN_1 of the first client device and the activation code Activation_Code_1. The cloud management center is suitable for cloud-based deployments, sending activation codes via remote connection. The server management control system (RMC) is suitable for centralized deployments in local data centers, sending activation codes to multiple server nodes via RMC. Activation code parsing and verification are automatically performed by the BMC. This method can be used as... Figure 13 The example shows an alternative implementation besides the full package delivery.
[0218] For the direct activation method during the production stage, the diagnostic server can generate or obtain the activation code before the device leaves the factory, and load the activation code onto the target device via the writing circuit or BMC management interface, as detailed in Example 3. This method is an optional deployment method and does not change the device binding process of this embodiment, which is mainly based on HUID generation, restricted read, and device-side verification.
[0219] Example 6: Management method for authorization period.
[0220] In this embodiment of the invention, the BMC can manage the authorization period after the controlled function is enabled. Specifically, the BMC can use an external reference time to calibrate the local time and determine whether the activation code has expired according to the natural time; alternatively, it can accumulate time only when the controlled function is active and determine whether the activation code has expired according to the actual usage time.
[0221] In some optional implementations, the activation code carries the creation time and validity period of the activation code; the activation code is also used for the baseboard management controller to read the reference time from an external clock source at a preset time every day after the controlled function is enabled, and to read the current time of the baseboard management controller; when the difference between the reference time and the current time is greater than the error threshold, the current time is updated to the reference time; the current time is recorded in the audit log; and when the difference between the current time and the creation time is greater than the validity period, the activation signal is set to invalid, so that the controlled function is restored to the disabled state.
[0222] In this embodiment of the invention, the creation time refers to the system time when the activation code generation device generates the activation code. The effective time refers to the duration for which the controlled functions are allowed to remain enabled from the creation time. A preset time could be, for example, 00:00:00 every day. An external clock source could be, for example, a Real-Time Clock (RTC) or a Network Time Protocol (NTP) server. The error threshold can be set by the administrator at the factory, for example, 1 minute, 1 hour, or 1 day. The error threshold can be determined based on the allowable error of the external clock source and the error of the BMC's local timing.
[0223] Figure 16 A flowchart of a continuous timing verification method for the authorization period provided in an embodiment of the present invention.
[0224] This method addresses the issue of users extending the validity of trial activation codes by reverting the BMC's system time. For example, if the activation code expires on June 15, 2026, the user can change the BMC's system time to March 1, 2026, just before the expiration date, thus continuing to use controlled functions. Taking a customer's trial activation code with a validity period of 60 days as an example... Figure 16As shown, the method may include the following steps.
[0225] (1) After the start, BMC verifies the activation code and obtains the creation time of the activation code, i.e. device_1_create_time in the authorization information.
[0226] (2) BMC reads the base time Base_time from an external clock source at a preset time every day. The external clock source is a real-time clock or a network time server.
[0227] (3) The BMC reads the current time Current_time and determines whether the difference between the base time and the current time is less than or equal to the error threshold error_value, that is, whether |Base_time-Current_time|≤error_value. If yes, the current time is determined to be accurate and has not been tampered with. If no, the current time is determined to be inaccurate or has been tampered with, and the BMC performs time synchronization to update the current time to the base time.
[0228] (4) Record the current time in the audit log.
[0229] (5) Determine whether the difference between the current time and the creation time is greater than the valid time, i.e., whether Current_time - device_1_create_time > device_1_valid_date. If not, set the activation signal to valid and return to step (2) to read the base time again at the next preset time. If yes, set the activation signal to invalid, the controlled function is disabled, and then the process ends. For example, the activation code is valid when the difference between the two is less than 60 days, and the activation code is invalid when it exceeds 60 days.
[0230] The reason for recording the current time in the audit log is that, in some scenarios, an NTP server may not be deployed to save costs; in addition, the RTC requires a separate power supply, and when the power supply is exhausted, it is impossible to obtain an accurate reference time through the RTC.
[0231] In some optional implementations, the audit log can only be written by the BMC; customers can only read the audit log but cannot modify it. The BMC compares the system time daily with the current time recorded in the audit log to determine if the system time has been tampered with. This way, even if an NTP server is not deployed or the RTC's power supply is exhausted and an external reference time cannot be obtained, the BMC can still detect system time rollback based on the audit log, reducing the risk of extending trial authorizations by rolling back system time.
[0232] The continuous timing method described above is based on calendar days. Considering that some customers may not use the controlled function continuously, but only for part of the time, timing during periods when the controlled function is not used would result in underutilization of resources. Therefore, a cumulative timing method can also be used.
[0233] In some optional implementations, the activation code carries a valid time. The substrate management controller includes a cumulative timing circuit, which includes a D flip-flop, a timer, a non-volatile memory, and a timing comparator. The D flip-flop samples the activation signal and outputs the sampling result to the enable terminal of the timer. The timer performs cumulative timing when its enable terminal is active, outputs the timing value to the timing comparator, and synchronously writes it to the non-volatile memory. The timing comparator compares the timing value with the valid time and invalidates the activation signal when the timing value reaches the valid time. The timer also reads the timing value stored before the power failure from the non-volatile memory and continues to accumulate timing based on the read timing value when the substrate management controller is powered on again after a power failure.
[0234] Figure 17 This is a schematic diagram of the circuit structure of an authorization period cumulative timing circuit provided in an embodiment of the present invention.
[0235] like Figure 17 As shown, the cumulative timing circuit includes a D flip-flop, a timer, a non-volatile memory, and a timing comparator. Its input signals include a clock signal CLK, an activation signal, a reset signal RSTn, and a valid time. The D flip-flop's input D receives the activation signal, and its output Q is connected to the timer's enable terminal E. The timer's reference time input T[31..0] is connected to the non-volatile memory's read data port R[31..0]. The timer's output Q[31..0] is connected to the timing comparator's first input and the non-volatile memory's write data port W[31..0]. The timing comparator's second input receives the valid time from the authorization information, and its output is connected to the activation signal. The reset signal RSTn, after inversion, is connected to the D flip-flop and the timer's reset terminal R. The clock input clk of the D flip-flop, timer, and non-volatile memory receives the clock signal CLK.
[0236] When the enable pin E is active, the timer accumulates time based on the time input at pin T[31..0] when the clock signal is active, and outputs the time value at pin Q[31..0]. The timer stops counting when the enable pin E is inactive, and clears its output when the reset pin R is active. The non-volatile memory can be written to via port W[31..0] and read from via port R[31..0] when the clock signal is active; for example, a dual-port memory can be used.
[0237] In this embodiment of the invention, the cumulative timing circuit can be located in the BMC and implemented by a programmable logic device in the BMC, such as a Complex Programmable Logic Device (CPLD) or a Field Programmable Gate Array (FPGA). After the activation code verification is successful, the activation module writes the activation signal Active_sig into the activation signal register in the programmable logic device, and the activation signal register outputs to the input D of the D flip-flop. The output of the timing comparator is connected to the activation signal register via the activation signal. When the timing value has not reached the valid time, the timing comparator outputs a high level, and the activation signal in the activation signal register remains valid. When the timing value reaches the valid time, the timing comparator outputs a low level, invalidating the activation signal in the activation signal register. The BMC software reads the activation signal in the activation signal register to determine whether the controlled function is in an enabled or disabled state.
[0238] Taking a customer's trial activation code for a device that is valid for 60 days as an example, the circuit's operation process may include the following:
[0239] 1) The initial value of the timing stored in the non-volatile memory is set to 0.
[0240] 2) When the BMC is powered on and reset, i.e. when RSTn is 0, the D flip-flop outputs 0, the enable terminal E of the timer is invalid, and the reset terminal R of the timer is valid, so the timer output is 0.
[0241] 3) After the reset is complete (RSTn is 1) and the activation code verification is successful, the valid time of 60 days in the authorization information is input to the second input of the timer comparator. The D flip-flop samples the activation signal, which is 1 at this time. The sampled and stabilized value is input to the enable terminal E of the timer. At this time, the enable terminal E of the timer is valid and the reset terminal R is invalid. The timer reads the initial value 0 from the non-volatile memory through the T[31..0] terminal, starts counting from 0 when the clock signal is valid, and outputs the count value to the first input of the timer comparator. At the same time, it is synchronously written to the non-volatile memory through the W[31..0] port.
[0242] 4) The timing comparator compares the values at the two input terminals. When the timing value has not reached 60 days, the timing comparator outputs a high level, and the activation signal remains active. When the timing value reaches 60 days, the timing comparator outputs a low level, the activation signal becomes inactive, and the controlled function is disabled.
[0243] 5) If the BMC is unexpectedly powered off and then powered on again, the timer will read the timing value saved before the power failure through the non-volatile memory and continue timing based on that timing value.
[0244] Figure 17 The timing comparator in the code compares the accumulated time value with the valid time in the authorization information to determine whether the controlled function should remain active. Figure 8 The comparators used to compare the counting results of the first and second counters and generate a single bit of data have different purposes.
[0245] Before the target device is powered off, the non-volatile memory stores the current timing value; after power is restored, the timer reads the timing value from the non-volatile memory before the power outage and continues to accumulate. In this way, the effective time of the trial authorization can be accumulated according to the actual activation time of the controlled function, without losing used time due to device power failure. Because the timer only counts when the BMC is powered on and the controlled function is active, for example, a 60-day effective time corresponds to the customer's cumulative usage time of the controlled function, rather than 60 calendar days, making resource utilization more rational and customer usage more flexible.
[0246] Furthermore, the validity period of the official version can be set to 0xFFFF, which is 65535 days, approximately 180 years, essentially making it permanently valid. In practical applications, it can also be set to a validity period of 3 years, 5 years, etc., as needed. After the activation code expires, customers can repurchase to continue using the controlled functions. BMC can combine cumulative timing methods or external benchmark time verification methods to determine whether the license is still valid.
[0247] Example 7: System Overall Architecture Example.
[0248] This invention also provides a baseboard management controller function activation system, the application scenarios of which can be found in [reference needed]. Figure 2 .
[0249] The baseboard management controller function activation system provided in this embodiment of the invention may include a manufacturer's customer service device, an activation code generation device, and a target device. The target device includes a baseboard management controller and a first storage area. The first storage area is a one-time programmable storage area and stores the unique device identifier of the target device. The manufacturer's customer service equipment is used to receive the function activation request of the baseboard management controller for the target device, send the authorization code to the target device, and after the target device verifies the authorization code, obtain the device unique identifier code in the first storage area, generate the activation code corresponding to the target device according to the device unique identifier code through the activation code generation device, the activation code does not include the device unique identifier code in plaintext, and send the activation code to the baseboard management controller. The baseboard management controller is used to read the device unique identifier from the first storage area, use the read device unique identifier to verify the activation code, and output an activation signal after the verification is successful, so as to enable the controlled functions that are preset in the baseboard management controller and are in an disabled state. Among them, the device unique identifier in the first storage area is allowed to be read out to the outside of the target device only when the authorization code verification is successful; the controlled functions include at least one of the following: memory fault warning and self-repair function, single sign-on function, and system configuration locking function.
[0250] The processes performed by each component in this system are the same as the corresponding steps in Embodiment 1, and will not be repeated here. The components in this system are described below.
[0251] Manufacturer customer service equipment refers to computer equipment used by the manufacturer's customer service personnel, such as personal computers or servers. This equipment connects to the target device via a dedicated tool. The tool inputs the authorization code into the target device's authorization code input terminal, writes the symmetric key into the key input terminal, reads the serial number (SN) from the device's serial number output terminal, and reads the unique identifier (HUID) from the device's unique identifier output terminal after successful authorization code verification.
[0252] An activation code generation device is used to generate activation codes based on HUID. It can be a device or system deployed on the vendor's server, independent of the vendor's customer service equipment; see Example 1 for details. The functional modules of the activation code generation device are described below. Figure 10 And Example 4.
[0253] The target device, for example, can be a server, the structure of which can be found in [reference needed]. Figure 3 The BMC includes a receiving module, a verification module, an activation module, a log module, an activation code storage area, and a fourth storage area, as well as a digest algorithm module, a public key algorithm module, and a symmetric algorithm module. The receiving module receives the activation code, the verification module reads the HUID from the first storage area and verifies the activation code, and the activation module outputs an activation signal after successful verification.
[0254] The first storage area can be an OTP (Optical Transfer Protocol), such as an antifuse OTP, where the stored HUID cannot be modified after being written. Controlled functions are software modules pre-installed in the BMC (Browser Management Center), which are disabled by default and enabled by an activation signal. The activation signal is a software signal, such as the Active_sig activation signal.
[0255] Example 8: Target device.
[0256] This invention further illustrates the hardware structure of the target device and the function of the BMC in Embodiment 7. The processing procedure is described in Embodiments 1 and 2.
[0257] In some optional implementations, the target device may further include a second storage area, a classifier, and a first buffer. The second storage area is a one-time programmable storage area that stores a preset authorization code. The first input terminal of the classifier receives the preset authorization code, and the second input terminal receives the authorization code. The output terminal of the classifier is connected to the enable terminal of the first buffer. The classifier is used to enable the first buffer when the authorization code matches the preset authorization code and to block the first buffer when they do not match. The read port of the first storage area is connected to the device unique identifier output terminal of the target device via the first buffer and to the board management controller via the internal bus of the target device. The manufacturer's customer service device is used to obtain the device unique identifier via the device unique identifier output terminal, and the board management controller is used to read the device unique identifier in the first storage area via the internal bus.
[0258] In some optional implementations, the target device may further include a second buffer and a fourth storage area, the fourth storage area being a one-time programmable storage area located in the baseboard management controller; the output of the level divider is also connected to the enable terminal of the second buffer, the input terminal of the second buffer is connected to the key input terminal of the target device, and the output terminal is connected to the fourth storage area; the level divider is used to enable the second buffer when the authorization code matches the preset authorization code, and to block the second buffer when they do not match; the manufacturer's customer service device is also used to write the symmetric key corresponding to the target device into the fourth storage area via the key input terminal and the second buffer after the authorization code verification is successful; the activation code includes data encrypted with the symmetric key, and the baseboard management controller is also used to decrypt the encrypted data using the symmetric key in the fourth storage area.
[0259] The structure of the aforementioned target device is shown in the figure. Figure 4 The equality checker can employ a multi-bit digital comparison circuit to compare whether the data at the two input terminals are identical. The first and second buffers can be tri-state buffers with an enable pin (en). The second and fourth memory areas are OTPs; the fourth memory area is located in the BMC, while the first, second, and third memory areas are located on the target device's motherboard. The third memory area can be an EEPROM. The key input terminal is the port on the target device used to write the symmetric key, and the device serial number output terminal is the port on the target device used to read the serial number (SN).
[0260] In some alternative implementations, the target device does not provide an access interface to the internal bus to the outside, and the device unique identifier in the first storage area can only be read out to the outside of the target device through the device unique identifier output terminal when the authorization code verification is successful.
[0261] For the implementation method and effects, please refer to Example 2.
[0262] In some alternative implementations, the baseboard management controller may also be used to: not display the controlled function in the user interface of the baseboard management controller before the controlled function is enabled, and return a prompt message indicating no permission or no function for the call request for the controlled function initiated through the function call interface of the baseboard management controller; and display the controlled function in the user interface and respond to the call request after the controlled function is enabled.
[0263] The aforementioned function call interface can be, for example, an IPMI interface or a Redfish interface, and the user interface can be, for example, a BMC web interface, as detailed in Example 1.
[0264] Example 9: Device Unique Identifier Code Generation Device.
[0265] This invention further describes the device unique identifier generation device in the system described in Embodiment 7. Its operation process is the same as in Embodiment 3, and its structure is as described in Embodiment 7. Figures 6 to 9 The device unique identifier generation device can be installed in the diagnostic server of the production environment. See [link / reference]. Figure 5 .
[0266] In some optional embodiments, the system further includes a device unique identifier generation device, which includes a first inverter chain group, a second inverter chain group, a selection circuit, a first counter, a second counter, a comparator, a shift register, and a write circuit. Both the first and second inverter chain groups include multiple inverter chains. The selection circuit selects one inverter chain from each of the first and second inverter chain groups based on a selection signal. The first and second counters count the output signals of the two selected inverter chains, respectively. The comparator compares the counting results of the first and second counters and outputs one bit of data. The shift register shifts and stores the bit data sequentially output by the comparator under different selection signals to form a device unique identifier. The write circuit writes the device unique identifier into a first storage area.
[0267] In some optional embodiments, the device unique identifier generation device further includes a random number generator, which sequentially outputs multiple random numbers and provides each random number as a selection signal to a selection circuit. The selection circuit includes a first decoder, a second decoder, a first data selector, and a second data selector. The first decoder and the second decoder enable one inverter chain in the first inverter chain group and the second inverter chain group, respectively, according to the selection signal. The output signal of the disabled inverter chain is a fixed level. The first data selector and the second data selector select the output signal of the enabled inverter chain to the first counter and the second counter, respectively, according to the selection signal.
[0268] In some alternative implementations, the inverter chain includes an odd number of inverters connected in series and an AND gate; the first input of the AND gate is connected to the output of the final stage inverter, the second input of the AND gate is connected to an output of the decoder corresponding to the inverter chain, the output of the AND gate is connected to the input of the first stage inverter, and the output of the AND gate serves as the output of the inverter chain.
[0269] In some optional implementations, the device unique identifier generation device further includes a control unit, which is used to output a selection signal to the selection circuit and, according to the mode selection signal, control the device unique identifier generation device to form a device unique identifier when the mode selection signal is a first value and to form a device serial number when the mode selection signal is a second value; wherein, when the mode selection signal is a second value, the control unit reads the data stored in the shift register multiple times and concatenates them to form the device serial number, and the number of bits in the device serial number is greater than the number of bits in the device unique identifier; the target device may also include a third storage area, and the writing circuit is further used to write the device serial number into the third storage area, and the device serial number in the third storage area can be directly read.
[0270] In some optional implementations, there are multiple target devices, each with a device serial number. Each target device's activation code is encapsulated in an activation code package corresponding to its respective device serial number. The activation code package includes n device serial numbers and n corresponding activation codes, where n is an integer greater than 1. The writing circuit includes n matching qualifiers and n output buffers. The first input of the i-th matching qualifier receives the device serial number of the target device currently to be written, the second input receives the i-th device serial number from the activation code package, and the output is connected to the enable terminal of the i-th output buffer. The input of the i-th output buffer receives the i-th activation code from the activation code package, and the output of each output buffer is connected to the activation code output terminal. Here, i takes integer values from 1 to n. The writing circuit is also used to load the activation code corresponding to the device serial number of the target device to be written to the baseboard management controller of the target device via the activation code output terminal before the target device leaves the factory.
[0271] In the aforementioned device unique identifier generation device, the inverters can be NOT gates, and the AND gates can be two-input AND gates. Each inverter chain can, for example, include five NOT gates and one two-input AND gate. The first and second decoders can be 5-line to 32-line decoders with enable inputs. The first and second data selectors can be 32-channel data selectors. The first and second counters can be 16-bit counters with enable and reset inputs. The shift register can be a 128-bit shift register. The random number generator can be a physical noise source or a pseudo-random number generation module. The control unit can be implemented using logic control circuits or a microcontroller.
[0272] In some optional implementations, the device unique identifier generation device further includes a first D flip-flop and a second D flip-flop. The first and second D flip-flops sample the counting results of the first and second counters, respectively, and output the sampled and stabilized counting results to a comparator. For example, the first and second D flip-flops can be 16-bit D flip-flops. See Embodiment 3 for implementation details and effects.
[0273] Example 10: A system implementation example for activation code, batch activation, and license period management.
[0274] This invention further illustrates the generation and verification of activation codes, batch activation, and authorization period management in the system described in Embodiment 7. The processing procedures are described in Embodiments 4, 5, and 6, respectively.
[0275] In some optional implementations, the activation code carries a valid time. The substrate management controller includes a cumulative timing circuit, which includes a D flip-flop, a timer, a non-volatile memory, and a timing comparator. The D flip-flop samples the activation signal and outputs the sampling result to the enable terminal of the timer. The timer performs cumulative timing when its enable terminal is active, outputs the timing value to the timing comparator, and synchronously writes it to the non-volatile memory. The timing comparator compares the timing value with the valid time and invalidates the activation signal when the timing value reaches the valid time. The timer also reads the timing value stored before the power failure from the non-volatile memory and continues to accumulate timing based on the read timing value when the substrate management controller is powered on again after a power failure.
[0276] The structure of the above-mentioned cumulative timing circuit is shown in [reference]. Figure 17 The timer and D flip-flop can be implemented by a CPLD or FPGA in the BMC, the non-volatile memory can be a dual-port memory, and the timer can output a 32-bit timing value.
[0277] In some optional implementations, the manufacturer's customer service device is also used to determine the authorization information of the target device based on the board management controller function activation request; the activation code generation device is used to combine the HUID and authorization information into data to be signed, perform a digest operation on the data to be signed to obtain a digest value, use a private key to digitally sign the digest value to obtain a signature value, and generate an activation code based on the authorization information and the signature value, wherein the activation code does not include the HUID; the BMC is used to combine the HUID read from the first storage area with the authorization information in the activation code into data to be verified, perform a digest operation on the data to be verified, use the public key corresponding to the private key to verify the signature value, and determine that the verification is successful when the result of the digest operation is consistent with the digest value obtained from the verification.
[0278] The above method corresponds to Scheme 1, see Implementation Example 4 for details. Figure 11 , Figure 12 The generation side and the device side use the same HUID source, but the HUID itself is not transmitted between the two with the activation code.
[0279] In some optional implementations, the activation code generation device is used to perform a digest operation on the data to be signed containing HUID and authorization information, and sign it with a private key to obtain a signature value. It then uses a symmetric key corresponding to the target device to encrypt the HUID and the public key corresponding to the private key to obtain ciphertext, and generates an activation code based on the ciphertext, authorization information, and signature value. The BMC is used to decrypt the ciphertext with a symmetric key in the fourth storage area to obtain the HUID and public key. When the decrypted HUID is consistent with the HUID read from the first storage area, and the signature value is verified using the decrypted public key, the verification is deemed successful.
[0280] The above method corresponds to Scheme 2, and see Implementation Example 4 for details.
[0281] In some optional implementations, the activation code generation device is used to generate random parameters, perform a one-way operation on the HUID and random parameters to obtain a verification code, combine the verification code and authorization information into data to be signed and sign it with a private key to obtain a signature value, and generate an activation code based on the verification code, random parameters, authorization information and signature value; the BMC is used to perform a one-way operation on the HUID read from the first storage area and the random parameters in the activation code, and determines that the verification is successful when the operation result is consistent with the verification code in the activation code and the signature value is verified using the public key corresponding to the private key.
[0282] The above method corresponds to Scheme 3, and see Implementation Example 4 for details.
[0283] In some optional implementations, the activation code generation device calls the digest algorithm and public key algorithm according to the algorithm identifier. The activation code is obtained by Base64 encoding of the data offset identifier, authorization information, algorithm identifier, signature value and encrypted public key. The BMC parses the activation code according to the data offset identifier, and after the verification is successful, it encrypts and stores the activation code in the activation code memory. The log module records the operation result.
[0284] For details of the above methods, please refer to Example 4 and Tables 2 and 3.
[0285] In some optional implementations, there are multiple target devices, and each target device also includes a third storage area. The third storage area stores the serial number (SN) of the target device, and the SN can be directly read. The manufacturer's customer service device is also used to read the SN of each target device, encapsulate the activation code of each target device with its corresponding SN into an activation code package, and send the activation code package to the BMC of each target device. Each BMC is used to read the SN in its own third storage area, and identify the activation code corresponding to the read SN from the activation code package as the activation code to be verified.
[0286] For details of the above methods, please refer to Example 5 and... Figures 13 to 15 Activation code packages can be distributed through the out-of-band management interface of each BMC. The BMC can cache the activation code packages in RAM and then perform traversal matching by the activation code matching logic.
[0287] In some optional implementations, the activation code carries the creation time and validity period of the activation code; the BMC is also used to read the reference time from an external clock source at a preset time every day after the controlled function is enabled, and read the current time of the BMC. When the difference between the reference time and the current time is greater than the error threshold, the current time is updated to the reference time, the current time is recorded in the audit log, and the activation signal is set to invalid when the difference between the current time and the creation time is greater than the validity period.
[0288] For details of the above methods, please refer to Example 6 and... Figure 16 .
[0289] It should be noted that embodiments one to six, from a methodological perspective, and embodiments seven to ten, from a system composition perspective, respectively illustrate the technical solutions of the present invention, and the embodiments can be referred to each other. Where there is no technical inconsistency, an optional structure in one embodiment can be used in another embodiment. For example, Figure 4 The authorization code verification and symmetric key writing structure shown can be used in Scheme 2. Figure 14 and Figure 15 The SN matching method shown can be used in conjunction with any of the HUID verification methods in Scheme 1, Scheme 2, or Scheme 3. Figure 16 or Figure 17 The authorization period processing shown can be used for controlled function management after verification. In this embodiment of the invention, the activation code does not contain HUID in plaintext form, and the generation and transmission of the activation code can adopt any of the above-mentioned scheme one, scheme two, or scheme three.
[0290] The algorithms and parameters used in these embodiments can be selected according to product requirements. For example, the hash algorithm can be SHA256, SHA384, or SHA512; the public key algorithm can be RSA2048, RSA3072, or RSA4096; and the symmetric algorithm can be AES or SM4. Each inverter chain can consist of 32 inverter chains, with HUID being 128 bits and SN being 512 bits. The algorithms, number of chains, and bit lengths described above are merely examples.
[0291] Any of the components, modules, units, parts, methods, and operations described herein can be implemented using software, firmware, hardware (e.g., fixed logic circuitry), manual processing, or any combination thereof. Alternatively or additionally, any functionality described herein can be performed at least in part by one or more hardware logic components, such as, but not limited to, a central processing unit (CPU), a field-programmable gate array (FPGA), an application-specific integrated circuit (ASIC), an application-specific standard product (ASSP), a system-on-a-chip (SoC), a complex programmable logic device (CPLD), a microprocessor (MCU), etc. The terms "system," "computing device," or "apparatus" as used herein encompass various means, devices, and machines for processing data, including, for example, one or more programmable processors, computers, SoCs, or combinations thereof. The apparatus may also include code that creates an execution environment for the computer program in question, such as code constituting processor firmware, a protocol stack, a database management system, an operating system, a cross-platform runtime environment, a virtual machine, or a combination thereof. The aforementioned computer program (also known as a program, software, software application, app, script, or code) can be written in any form of programming language, including compiled or interpreted languages, declarative or procedural languages, and can be deployed in any form, including as a standalone program or as a module, component, subroutine, object, or other unit suitable for a computing environment.
[0292] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this invention.
[0293] The above provides a detailed description of the method and system for activating the function of a baseboard management controller provided by the present invention. Specific examples have been used to illustrate the principles and implementation methods of the present invention. The descriptions of the above embodiments are only intended to help understand the method and core ideas of the present invention. It should be noted that those skilled in the art can make various improvements and modifications to the present invention without departing from its principles, and these improvements and modifications also fall within the protection scope of the present invention.
Claims
1. A method for activating the function of a baseboard management controller, characterized in that, Applications in manufacturer customer service equipment, including: Receive a function activation request for the baseboard management controller of the target device; wherein the target device includes a baseboard management controller and a first storage area, the first storage area is a one-time programmable storage area and stores the device unique identifier of the target device; An authorization code is sent to the target device, and after the target device verifies the authorization code, the device unique identifier code in the first storage area is obtained; wherein, the device unique identifier code in the first storage area is only allowed to be read out to the outside of the target device when the authorization code verification is successful; An activation code corresponding to the target device is generated using an activation code generation device based on the device's unique identifier. The activation code does not include the device's unique identifier in plaintext. The activation code is sent to the baseboard management controller, so that the baseboard management controller reads the device unique identifier from the first storage area, verifies the activation code using the read device unique identifier, and outputs an activation signal after the verification is successful, so as to enable the controlled functions that are pre-installed in the baseboard management controller and are in an disabled state; wherein, the controlled functions include at least one of memory fault warning and self-repair function, single sign-on function, and system configuration lock function.
2. The method for activating the function of the baseboard management controller according to claim 1, characterized in that, The target device further includes a second storage area, a classifier, and a first buffer. The second storage area is a one-time programmable storage area and stores a preset authorization code. The first input terminal of the level divider receives the preset authorization code, the second input terminal receives the authorization code, and the output terminal of the level divider is connected to the enable terminal of the first buffer. The level divider enables the first buffer when the authorization code matches the preset authorization code and blocks the first buffer when they do not match. The read port of the first storage area is connected to the device unique identifier output terminal of the target device via the first buffer, and is connected to the baseboard management controller via the internal bus of the target device; The step of obtaining the device unique identifier in the first storage area includes: obtaining the device unique identifier via the device unique identifier output terminal; The baseboard management controller reads the device unique identifier from the first storage area via the internal bus.
3. The method for activating the function of the baseboard management controller according to claim 1, characterized in that, The device unique identifier in the first storage area is generated and written by the device unique identifier generation device. The device unique identifier generation device includes a first inverter chain group, a second inverter chain group, a selection circuit, a first counter, a second counter, a comparator, and a shift register. Both the first inverter chain group and the second inverter chain group include multiple inverter chains. The selection circuit is used to select one inverter chain from the first inverter chain group and the second inverter chain group according to the selection signal; the first counter and the second counter are used to count the output signals of the two selected inverter chains respectively; the comparator is used to compare the counting results of the first counter and the second counter and output one bit of data; the shift register is used to shift and store the bit data output by the comparator under different selection signals to form the unique identifier of the device.
4. The method for activating the function of the baseboard management controller according to claim 3, characterized in that, The device unique identifier generation device further includes a random number generator, which is used to output a plurality of random numbers in sequence and provide each random number as a selection signal to the selection circuit. The selection circuit includes a first decoder, a second decoder, a first data selector, and a second data selector. The first decoder and the second decoder enable one inverter chain in the first inverter chain group and the second inverter chain group, respectively, according to the selection signal. The output signal of the disabled inverter chain is at a fixed level. The first data selector and the second data selector select the output signal of the enabled inverter chain to the first counter and the second counter, respectively, according to the selection signal.
5. The method for activating the function of the baseboard management controller according to claim 1, characterized in that, Also includes: The authorization information of the target device is determined based on the function activation request of the baseboard management controller; The step of generating an activation code corresponding to the target device based on the device's unique identifier using an activation code generation device includes: The device's unique identifier and the authorization information are combined to form data to be signed; Perform a digest operation on the data to be signed to obtain a digest value, and then use a private key to digitally sign the digest value to obtain a signature value; The activation code is generated based on the authorization information and the signature value, and the activation code does not include the device's unique identifier. The activation code is used by the baseboard management controller to combine the unique device identifier read from the activation code with the authorization information in the activation code to form data to be verified, perform the digest operation on the data to be verified, and determine that the verification is successful when the digest value obtained by verifying the signature value using the public key corresponding to the private key is consistent with the digest value obtained by verifying the signature value.
6. The method for activating the function of the baseboard management controller according to claim 5, characterized in that, Also includes: After the authorization code is verified, the symmetric key corresponding to the target device is written into the fourth storage area of the target device. The fourth storage area is a one-time programmable storage area and is located in the baseboard management controller. The step of generating the activation code based on the authorization information and the signature value includes: The public key is encrypted using the symmetric key to obtain the encrypted public key, and the activation code is generated based on the authorization information, the signature value, and the encrypted public key. The activation code is also used by the baseboard management controller to decrypt the encrypted public key using the symmetric key in the fourth storage area, so as to obtain the public key used to verify the signature value.
7. The method for activating the function of the baseboard management controller according to claim 1, characterized in that, Also includes: The authorization information of the target device is determined based on the function activation request of the baseboard management controller; After the authorization code is verified, the symmetric key corresponding to the target device is written into the fourth storage area of the target device. The fourth storage area is a one-time programmable storage area and is located in the baseboard management controller. The step of generating an activation code corresponding to the target device based on the device's unique identifier using an activation code generation device includes: A digest value is obtained by performing a digest operation on the data to be signed, which contains the unique identifier of the device and the authorization information, and a digital signature is obtained by using a private key on the digest value. The symmetric key is used to encrypt the unique identifier of the device and the public key corresponding to the private key together to obtain ciphertext; The activation code is generated based on the ciphertext, the authorization information, and the signature value; The activation code is used by the baseboard management controller to decrypt the ciphertext using the symmetric key in the fourth storage area. When the device unique identifier obtained by decryption is consistent with the read device unique identifier and the signature value is verified by the public key obtained by decryption, the verification is deemed successful.
8. The method for activating the function of the baseboard management controller according to claim 1, characterized in that, Also includes: The authorization information of the target device is determined based on the function activation request of the baseboard management controller; The step of generating an activation code corresponding to the target device based on the device's unique identifier using an activation code generation device includes: Generate random parameters, and perform a one-way operation on the device's unique identifier and the random parameters to obtain a verification code; The verification code and the authorization information are combined into data to be signed. A digest operation is performed on the data to be signed to obtain a digest value. The digest value is then digitally signed using a private key to obtain a signature value. The activation code is generated based on the verification code, the random parameters, the authorization information, and the signature value; The activation code is used by the baseboard management controller to perform the one-way operation on the read device unique identifier code and the random parameters in the activation code. When the operation result is consistent with the verification code in the activation code and the signature value is verified using the public key corresponding to the private key, the verification is deemed successful.
9. The method for activating the function of the baseboard management controller according to claim 1, characterized in that, There are multiple target devices, and each target device further includes a third storage area, which stores the device serial number of the target device, and the device serial number can be directly read. The method for activating the baseboard management controller function also includes: Read the device serial number from the third storage area of each target device, and encapsulate the activation code of each target device and its corresponding device serial number into an activation code package; Sending the activation code to the baseboard management controller includes: The activation code package is sent to the baseboard management controller of each target device, so that each baseboard management controller reads the device serial number in the third storage area of its own machine, and identifies the activation code corresponding to the read device serial number from the activation code package as the activation code to be verified.
10. The method for activating the function of the baseboard management controller according to claim 1, characterized in that, The activation code carries the creation time and validity period of the activation code; The activation code is also used to enable the baseboard management controller to read the reference time from an external clock source at a preset time every day after the controlled function is enabled, and to read the current time of the baseboard management controller. When the difference between the reference time and the current time is greater than an error threshold, the current time is updated to the reference time. The current time is recorded in the audit log; and when the difference between the current time and the creation time is greater than the effective time, the activation signal is set to invalid, so that the controlled function is restored to the disabled state.
11. A baseboard management controller function activation system, characterized in that, The device includes manufacturer customer service equipment, activation code generation device and target device. The target device includes a baseboard management controller and a first storage area. The first storage area is a one-time programmable storage area and stores the device unique identifier of the target device. The manufacturer's customer service equipment is used to receive a function activation request for the baseboard management controller of the target device, send an authorization code to the target device, and after the target device verifies the authorization code, obtain the device unique identifier code in the first storage area, generate an activation code corresponding to the target device based on the device unique identifier code through the activation code generation device, wherein the activation code does not include the device unique identifier code in plaintext, and send the activation code to the baseboard management controller. The baseboard management controller is used to read the device unique identifier from the first storage area, use the read device unique identifier to verify the activation code, and output an activation signal after the verification is successful, so as to enable the controlled functions that are preset in the baseboard management controller and are in an disabled state. The device unique identifier in the first storage area is allowed to be read out to the outside of the target device only when the authorization code is verified; the controlled functions include at least one of memory fault warning and self-repair function, single sign-on function and system configuration locking function.
12. The baseboard management controller function activation system according to claim 11, characterized in that, The target device further includes a second storage area, a classifier, and a first buffer. The second storage area is a one-time programmable storage area and stores a preset authorization code. The first input terminal of the level divider receives the preset authorization code, the second input terminal receives the authorization code, and the output terminal of the level divider is connected to the enable terminal of the first buffer. The level divider is used to enable the first buffer when the authorization code is consistent with the preset authorization code, and to block the first buffer when they are inconsistent. The read port of the first storage area is connected to the device unique identifier output terminal of the target device via the first buffer, and is connected to the baseboard management controller via the internal bus of the target device; The manufacturer's customer service equipment is used to obtain the device's unique identifier code through the device's unique identifier code output terminal, and the baseboard management controller is used to read the device's unique identifier code from the first storage area through the internal bus.
13. The baseboard management controller function activation system according to claim 12, characterized in that, The target device further includes a second buffer and a fourth storage area, wherein the fourth storage area is a one-time programmable storage area and is located in the substrate management controller; The output of the level divider is also connected to the enable terminal of the second buffer. The input terminal of the second buffer is connected to the key input terminal of the target device, and the output terminal is connected to the fourth storage area. The level divider is used to enable the second buffer when the authorization code is consistent with the preset authorization code, and to block the second buffer when they are inconsistent. The manufacturer's customer service device is also used to write the symmetric key corresponding to the target device into the fourth storage area after the authorization code is verified, via the key input terminal and the second buffer; the activation code includes data encrypted with the symmetric key, and the baseboard management controller is also used to decrypt the encrypted data using the symmetric key in the fourth storage area.
14. The baseboard management controller function activation system according to claim 11, characterized in that, It also includes a device unique identifier generation device, which includes a first inverter chain group, a second inverter chain group, a selection circuit, a first counter, a second counter, a comparator, a shift register, and a write circuit. Both the first inverter chain group and the second inverter chain group include multiple inverter chains. The selection circuit is used to select one inverter chain from the first inverter chain group and the second inverter chain group according to the selection signal; the first counter and the second counter are used to count the output signals of the two selected inverter chains respectively; the comparator is used to compare the counting results of the first counter and the second counter and output one bit of data; the shift register is used to shift and store the bit data output by the comparator under different selection signals to form the unique identifier of the device; the writing circuit is used to write the unique identifier of the device into the first storage area.
15. The baseboard management controller function activation system according to claim 14, characterized in that, The device unique identifier generation device further includes a random number generator, which is used to output a plurality of random numbers in sequence and provide each random number as a selection signal to the selection circuit. The selection circuit includes a first decoder, a second decoder, a first data selector, and a second data selector. The first decoder and the second decoder enable one inverter chain in the first inverter chain group and the second inverter chain group, respectively, according to the selection signal. The output signal of the disabled inverter chain is at a fixed level. The first data selector and the second data selector select the output signal of the enabled inverter chain to the first counter and the second counter, respectively, according to the selection signal.
16. The baseboard management controller function activation system according to claim 15, characterized in that, The inverter chain comprises an odd number of inverters connected in series and an AND gate; The first input of the AND gate is connected to the output of the final stage inverter, the second input of the AND gate is connected to the output of the decoder corresponding to the inverter chain, the output of the AND gate is connected to the input of the first stage inverter, and the output of the AND gate serves as the output of the inverter chain.
17. The baseboard management controller function activation system according to any one of claims 14 to 16, characterized in that, The device unique identifier generation device further includes a control unit, which is used to output the selection signal to the selection circuit, and control the device unique identifier generation device to form the device unique identifier when the mode selection signal is a first value and to form a device serial number when the mode selection signal is a second value, according to the mode selection signal; wherein, when the mode selection signal is a second value, the control unit reads the data stored in the shift register multiple times and concatenates them to form the device serial number, and the number of bits in the device serial number is greater than the number of bits in the device unique identifier; The target device further includes a third storage area, and the writing circuit is also used to write the device serial number into the third storage area, wherein the device serial number in the third storage area can be read directly.
18. The baseboard management controller function activation system according to claim 14, characterized in that, There are multiple target devices, each target device has a device serial number, and each target device's activation code is encapsulated in an activation code package corresponding to its respective device serial number. The activation code package includes n device serial numbers and n corresponding activation codes, where n is an integer greater than 1. The writing circuit includes n matching equalizers and n output buffers; The first input of the i-th matching qualifier receives the device serial number of the target device to be written among the target devices, the second input receives the i-th device serial number in the activation code package, and the output is connected to the enable terminal of the i-th output buffer. The input of the i-th output buffer receives the i-th activation code from the activation code packet, and the output of each output buffer is connected to the activation code output; where i takes any integer from 1 to n; The writing circuit is also used to load the activation code corresponding to the device serial number of the target device to be written to the baseboard management controller of the target device via the activation code output terminal before the target device leaves the factory.
19. The baseboard management controller function activation system according to claim 11, characterized in that, The baseboard management controller is further configured to: before the controlled function is enabled, not display the controlled function in the user interface of the baseboard management controller, and return a prompt message indicating no permission or no function for a call request for the controlled function initiated through the function call interface of the baseboard management controller; after the controlled function is enabled, display the controlled function in the user interface and respond to the call request.
20. The baseboard management controller function activation system according to claim 11, characterized in that, The activation code carries a valid time, and the baseboard management controller includes a cumulative timing circuit, which includes a D flip-flop, a timer, a non-volatile memory, and a timing comparator. The D flip-flop is used to sample the activation signal and output the sampling result to the enable terminal of the timer; The timer is used to accumulate time when its enable terminal is active, output the time value to the timer comparator, and synchronously write it to the non-volatile memory; the timer comparator is used to compare the time value with the valid time, and invalidate the activation signal when the time value reaches the valid time; the timer is also used to read the time value stored before the power failure from the non-volatile memory when the baseboard management controller is powered off and then powered on again, and continue to accumulate time based on the read time value.
