License authorization management method and system based on Linux operating system
By detecting and verifying the activation license when the Linux operating system is first installed and started, and generating and verifying the authorization license, the problem of existing technologies that can only control unstarted functions and features is solved, and the rapid activation of functions and features and convenient user experience are achieved, which reduces maintenance costs and reduces the risk of software piracy.
Patent Information
- Application Number
- CN202411826387.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-11
- Publication Date
- 2025-09-19
- Estimated Expiration
- 2044-12-11
AI Technical Summary
Verification of existing Linux operating systems through subscription management services can only control functional features that have not yet been started, and cannot effectively restrict the startup and basic operation of the operating system.
When the Linux operating system is first installed and started, the legitimacy of the activation license is detected and verified. The kernel is verified step by step through efuse/bootrom as the trusted root. A secure connection is established with the server using the user ID/user key. The authorization license is generated and verified, signed, and written to disk. License verification is performed at startup, supporting flexible license management and anomaly detection.
It enables quick activation of features after system startup, reduces system startup time, provides a convenient user experience, reduces maintenance costs, reduces the risk of unauthorized use, supports flexible license management and prevents software piracy.
Smart Images

Figure CN119760670B_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present invention relate to the technical field of operating systems, and in particular to a license authorization management method and system based on a Linux operating system. Background Art
[0002] A license is a legal agreement for software usage, defining how users can use the software. This includes the scope of use (e.g., personal use, business use), method of use (single-user or multi-user), and geographic location (e.g., country-specific or global use). The license also specifies the number of devices on which users can install and activate the software, helping software developers control its distribution and use.
[0003] Software often offers different levels of functionality based on different license tiers. For example, a free version might offer only basic functionality, while a paid Professional or Enterprise version provides advanced features. This tiered system allows software developers to offer different versions of their products based on user needs and willingness to pay.
[0004] The license may specify the duration of the software's use. Some licenses are perpetual, while others are subscription-based, requiring users to renew their subscriptions periodically to continue using the software. This model provides a revenue stream for the software developer and allows users to flexibly choose the duration of use based on their needs. The license reaffirms the intellectual property rights of the software and explicitly prohibits unauthorized copying, distribution, decompilation, tampering, or reverse engineering. This is a key measure to protect the rights of software developers and ensure a reasonable return on their R&D investment.
[0005] Linux operating systems often use a subscription model. After the system boots, users communicate with a verification server through a subscription management service to complete license verification. Only after verification is successful can users access specific features or services. This model is suitable for enterprise-level software that requires regular updates and maintenance. However, after the operating system boots, verification through the subscription management service only controls features that have not yet been enabled; it does not specifically restrict the startup and basic operation of the operating system itself.
[0006] When installing the Windows operating system, you need to enter an activation serial number. This serial number will be sent to Microsoft's service platform for verification. Only after verification is passed can the user unlock the full functionality of Windows. However, the verification method of activation by serial number is relatively inconvenient and not conducive to batch processing. Summary of the Invention
[0007] To this end, an embodiment of the present invention provides a license authorization management method and system based on a Linux operating system to solve the technical problem that the existing Linux operating system can only control functional features that have not yet been started by performing verification through subscription management services.
[0008] In order to achieve the above objectives, the embodiments of the present invention provide the following technical solutions:
[0009] According to a first aspect of an embodiment of the present invention, a method for managing license authorization based on a Linux operating system is provided, the method comprising:
[0010] When the operating system is installed and started for the first time, it detects whether the activation license exists and verifies the legitimacy of the activation license;
[0011] If the activation license does not exist or is illegal, the activation process is executed;
[0012] Perform signature verification on the preset first process, and activate it using the preset first process after the verification passes;
[0013] Obtain a user ID / user key, establish a secure connection with the server using the user ID / user key, and send an activation request to the server;
[0014] The server receives the activation request from the user and executes the corresponding activation process according to the request type, wherein the activation process includes the first activation process and the update activation process;
[0015] After the initial activation process is started, license verification is performed in the first process when the operating system is restarted.
[0016] Furthermore, the signature verification of the preset first process includes:
[0017] Verify the kernel level by level using efuse / bootrom as the trusted root;
[0018] After the kernel verification is passed, the kernel is used to perform signature verification on the preset first process.
[0019] Furthermore, obtaining a user ID / user key, establishing a secure connection with a server using the user ID / user key, and sending an activation request to the server include:
[0020] The activation request includes: hardware information, OS version number information, and current processor architecture information;
[0021] The hardware information includes: cpu, emmc, and mac address information.
[0022] Furthermore, the server receives an activation request from the user and executes a corresponding activation process according to the request type. The activation process includes an initial activation process and an update activation process, including:
[0023] Obtain the license quantity, OS type, and architecture associated with the user ID, and use the license quantity, OS type, and architecture to determine whether the activation can be supported.
[0024] If the activation is supported and the hardware information corresponding to the current device is not recorded in the database, it is considered the first activation;
[0025] The initial activation process includes:
[0026] Record user device information and generate activation codes and authorization licenses based on hardware information;
[0027] Generate an RSA key pair dedicated to the authorization process and generate a public key certificate for the public key through the internal CA process;
[0028] Use the generated private key to sign the license;
[0029] Sending the authorization license, license signature, and public key certificate to the user device;
[0030] Among them, the user device information includes hardware information, version number and architecture; the authorization license information includes activation code, authorization architecture, authorization characteristics and expiration time; and the license signature is a hash signature.
[0031] Furthermore, sending the authorization license, license signature, and public key certificate to the user device also includes:
[0032] After receiving the authorization license, license signature and public key certificate, the user equipment verifies the public key certificate and verifies the license signature using the verified public key certificate;
[0033] Use the license information after signature verification to extract the license activation code, authorized OS version, architecture and time information;
[0034] The user device generates a user activation code and verifies it with the license activation code. If the verification is successful, the license and signature information are written to the specified location on the disk and the software features authorized by the license are configured into the kernel through a specific driver for maintenance.
[0035] Furthermore, after the first activation process is started, the license verification is performed in the first process when the operating system is started again, including:
[0036] Read the license information and signature information from the specified location on the disk and verify the public key certificate;
[0037] Verify the license signature using the verified public key certificate and extract the activation code, authorized OS version, architecture and implementation information from the license information after the signature verification is passed;
[0038] Generate an activation code and verify it with the activation code extracted from the license to verify the OS version, architecture and authorization period;
[0039] After verification, the software features authorized by the license are configured into the kernel through the preset driver for maintenance and the OS is started, completing the first installation and startup of the operating system.
[0040] Furthermore, the method further comprises:
[0041] When encountering a scenario where an authorization update is required, the user purchases the corresponding authorization again, and the management platform configures the user's device in advance to indicate that an authorization update is required;
[0042] Start the user device and determine whether it can enter the OS. If it can enter the OS, clear the local license information through the tools under the OS, and restart the activation process;
[0043] If you cannot enter the OS, reinstall the OS and clear the local license information using the tools under the OS. Then restart the OS and start the activation process again.
[0044] When the hardware information changes, the activation process will be directly started after the user device is started;
[0045] Among them, the scenarios that require authorization updates are: hardware information changes caused by user equipment being returned to the factory for repair, license authorization renewal, license feature additions, and certificate updates.
[0046] Furthermore, the method further comprises:
[0047] License authorization supports individual control of features, and the feature list is loaded into the kernel during the boot phase;
[0048] When a feature is enabled, a separate device driver is used to enter the kernel to query whether the feature is supported. If not, the feature cannot be enabled.
[0049] Furthermore, the method further comprises:
[0050] Detecting abnormal situations:
[0051] The user device encrypts the local hardware information with the device authorization public key and sends it to the server;
[0052] The exceptions include: certificate revocation and discovery of unauthorized illegal licenses;
[0053] When the CA private key / device-specific authorization private key is leaked, the private key is changed and the public key certificate is revoked, and a new public key certificate is generated;
[0054] After decryption, the server compares the information with the hardware information recorded in the database. If they are consistent, the certificate is normal. If they are inconsistent, the certificate is abnormal. The server returns the abnormal result and updates the certificate.
[0055] The client uses the updated certificate to verify the license. If the verification fails, it will re-enter the activation process.
[0056] According to a second aspect of an embodiment of the present invention, a license authorization management system based on a Linux operating system is provided, the system comprising:
[0057] A legitimacy detection module is used to detect the existence of an activation license and verify the legitimacy of the activation license when the operating system is installed and started for the first time;
[0058] An activation process execution module, used to execute the activation process if the activation license does not exist or the activation license is illegal;
[0059] A signature verification module is used to verify the signature of the preset first process and activate it using the preset first process after the verification passes;
[0060] An activation request sending module, configured to obtain a user ID / user key, establish a secure connection with a server using the user ID / user key, and send an activation request to the server;
[0061] An activation process execution module is used for the server to receive an activation request from the user and execute a corresponding activation process according to the request type. The activation process includes an initial activation process and an update activation process.
[0062] The license verification module is used to perform license verification in the first process when the operating system is started again after the first activation process is started.
[0063] The embodiments of the present invention have the following advantages:
[0064] The embodiments of the present invention can enable functional features more quickly by performing verification after the system is started, thereby reducing system startup and preparation time; users do not need to interrupt the installation process to enter serial numbers, providing a smoother and more convenient user experience; since the need for manual serial number entry is reduced, the system maintenance cost and management workload are reduced; the risk of unauthorized use is reduced, and flexible license management: the present invention may provide more flexible license management options, such as a usage-based subscription model, to meet the needs of different users, and reduce software piracy: through an improved verification mechanism, the present invention helps to reduce software piracy and protect intellectual property rights. BRIEF DESCRIPTION OF THE DRAWINGS
[0065] To more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for the embodiments or the description of the prior art. Obviously, the drawings described below are merely exemplary, and those skilled in the art can derive other implementation drawings based on the provided drawings without inventive effort.
[0066] The structures, proportions, sizes, etc. illustrated in this specification are intended only to complement the contents disclosed herein and to facilitate understanding and reading by persons familiar with the art. They are not intended to limit the conditions under which the present invention may be implemented and therefore have no substantive technical significance. Any structural modifications, changes in proportions, or adjustments in sizes, without affecting the efficacy and objectives of the present invention, shall still fall within the scope of the technical contents disclosed herein.
[0067] Figure 1 A schematic diagram of the logical structure of a license authorization management system based on the Linux operating system provided by an embodiment of the present invention;
[0068] Figure 2 A flowchart of a license authorization management method based on a Linux operating system is provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0069] The following describes the implementation of the present invention using specific embodiments. Those skilled in the art will readily understand the other advantages and benefits of the present invention from the disclosure herein. Obviously, the embodiments described are only a portion of the present invention, not all of it. All other embodiments derived by persons of ordinary skill in the art based on the embodiments of the present invention without inventive effort are intended to fall within the scope of protection of the present invention.
[0070] Linux operating systems often use a subscription model. After the system boots, users communicate with a verification server through a subscription management service to complete license verification. Only after verification is successful can users access specific features or services. This model is suitable for enterprise-level software that requires regular updates and maintenance. However, after the operating system boots, verification through the subscription management service only controls features that have not yet been enabled; it does not specifically restrict the startup and basic operation of the operating system itself.
[0071] When installing the Windows operating system, you need to enter an activation serial number. This serial number will be sent to Microsoft's service platform for verification. Only after verification is passed can the user unlock the full functionality of Windows. However, the verification method of activation by serial number is relatively inconvenient and not conducive to batch processing.
[0072] In order to solve the technical problem that the existing Linux operating system can only control functional features that have not been started by performing verification through subscription management services.
[0073] refer to Figure 1 The embodiment of the present invention discloses a license authorization management system based on the Linux operating system, which includes: a legitimacy detection module 1; an activation process execution module 2; a signature verification module 3; an activation request sending module 4; an activation process execution module 5; and a license verification module 6.
[0074] Corresponding to the aforementioned license authorization management system based on the Linux operating system, an embodiment of the present invention further discloses a license authorization management method based on the Linux operating system. The following describes in detail the license authorization management method based on the Linux operating system disclosed in an embodiment of the present invention in conjunction with the aforementioned license authorization management system based on the Linux operating system.
[0075] refer to Figure 2 The present invention discloses a license authorization management method based on a Linux operating system, the method comprising: when the operating system is installed and started for the first time, detecting whether an activation license exists and verifying the legitimacy of the activation license; executing an activation process if the activation license does not exist or the activation license is illegal; performing signature verification on a preset first process, and activating the preset first process after the verification is passed; obtaining a user ID / user key, establishing a secure connection with a server using the user ID / user key, and sending an activation request to the server; the server receives the activation request from the user and executes a corresponding activation process according to the request type, the activation process including an initial activation process and an update activation process; after the initial activation process is started, performing license verification within the first process when the operating system is started again.
[0076] Furthermore, the signature verification is performed on the preset first process, including: verifying the kernel step by step through efuse / bootrom as a trusted root; and using the kernel to perform signature verification on the preset first process after the kernel verification passes.
[0077] Furthermore, a user ID / user key is obtained, a secure connection is established with the server using the user ID / user key, and an activation request is sent to the server, including: the activation request includes: hardware information, OS version number information, and current processor architecture information.
[0078] The hardware information includes: cpu, emmc, and mac address information.
[0079] Furthermore, the server receives an activation request from the user and executes a corresponding activation process according to the request type. The activation process includes an initial activation process and an update activation process, including: obtaining the number of licenses, OS type, and architecture under the user ID, and using the number of licenses, OS type, and architecture to determine whether this activation can be supported; if this activation can be supported and the hardware information corresponding to the current device is not recorded in the database, it is a first activation.
[0080] When the operating system is installed and started for the first time, the system checks whether the activation license exists and verifies the validity of the activation license. If the activation license does not exist or is invalid, the system starts the activation process.
[0081] Use custom process No. 1 or systemd to implement the activation verification function.
[0082] To prevent process 1 from being bypassed, the kernel must verify its signature. This can be achieved by reusing the kernel module signature verification mechanism. It is recommended that the released system version enable security verification, using efuse / bootrom as the root of trust for step-by-step verification to ensure kernel trustworthiness, and thus process 1.
[0083] The first activation process includes: recording the user's device information and generating an activation code and authorization license based on the hardware information; generating an RSA key pair dedicated to the authorization process and generating a public key certificate for the public key through an internal CA process; using the generated private key to sign the license; and sending the authorization license, license signature, and public key certificate to the user's device.
[0084] Among them, the user device information includes hardware information, version number and architecture; the authorization license information includes activation code, authorization architecture, authorization characteristics and expiration time; and the license signature is a hash signature.
[0085] Activation uses the customer name (ID) / customer key method to establish a secure connection with the management backend. The activation request sent needs to carry the following information: hardware information (CPU, eMMC, MAC address, etc.), OS version number, and current processor architecture (aarch64, etc.).
[0086] The server needs to check whether the number of licenses, OS type, architecture, etc. under the customer ID can support this activation. The hardware information corresponding to the current device is not recorded in the database, which means it is the first activation. If it is the first activation, the following process needs to be completed: a) Record the device information, including hardware information, version number, architecture, etc.; b) Generate an activation code: Run a specific algorithm based on the hardware information to generate an activation code; c) Generate an authorization license. The license information includes: activation code + authorization architecture + authorization features + expiration time; d) Generate an RSA key pair dedicated to the authorization process, which is unique for each device; and generate a certificate for the public key through the internal CA process; e) Use the generated private key to hash the license; and send the license, license signature, and public key certificate to the device.
[0087] Furthermore, sending the authorization license, license signature and public key certificate to the user device also includes: after the user device receives the authorization license, license signature and public key certificate, verifying the public key certificate and using the public key certificate after verification to verify the license signature; using the license information after signature verification to extract the license activation code, authorized OS version, architecture and time information; the user device generates a user activation code and verifies it with the license activation code. If the verification passes, the license and signature information are written to a specified location on the disk and the software features authorized by the license are configured into the kernel through a specific driver for maintenance.
[0088] The device verifies the received information through the following process: a) verifying the public key certificate; b) using the verified public key to verify the license signature; c) extracting the activation code, authorized OS version, architecture, and time information from the verified license information; d) using the same method to generate an activation code and verifying it with the activation code extracted from the license; e) if verification passes, writing the license and signature information to a specific location on disk; f) configuring the license-authorized software features in the kernel through a specific driver for maintenance; g) continuing to boot the OS.
[0089] Furthermore, after the first activation process is started, the license verification is performed within the first process when the operating system is started again, including: reading the license information and signature information from the specified location on the disk and verifying the public key certificate; using the verified public key certificate to verify the license signature and extracting the activation code, authorized OS version, architecture and practice information from the license information after the signature verification is passed; generating an activation code and verifying it with the activation code extracted from the license to verify the OS version, architecture and authorization period; after the verification is passed, the software features authorized by the license are configured into the kernel through a preset driver for maintenance and the OS is started, completing the first installation and startup of the operating system.
[0090] After the initial activation, the system will perform license verification in process 1 when it is started again: a) Read the license information and signature from a specific location on the disk; b) Verify the public key certificate; c) Verify the license signature using the verified public key; d) After the signature verification is successful, extract the activation code, authorized OS version, architecture, and time information from the license information; e) Generate an activation code using the same method and verify it with the activation code extracted from the license; f) Verify the OS version and architecture; g) Verify the authorization period; h) If the verification passes, configure the license-authorized software features into the kernel through a specific driver for maintenance; i) Start the OS.
[0091] Furthermore, the method also includes: when encountering a scenario where an authorization update is required, after the user re-purchases the corresponding authorization, the management platform configures the user device in advance to indicate that an authorization update is required; starting the user device and determining whether the OS can be entered, if the OS can be entered, the local license information is cleared through the tools under the OS, and the activation process is re-performed after restart; if the OS cannot be entered, the OS is reinstalled and the local license information is cleared through the tools under the OS, and the activation process is re-performed after restart; when the hardware information changes, the activation process is directly entered after starting the user device.
[0092] Among them, the scenarios that require authorization updates are: hardware information changes caused by user equipment being returned to the factory for repair, license authorization renewal, license feature additions, and certificate updates.
[0093] The following scenarios require license updates: 1) Hardware information changes due to device return for repair; 2) License renewal; 3) License feature additions; 4) Certificate updates.
[0094] After repurchasing the corresponding license, the customer should configure the device in advance on the management platform to indicate that a license update is required. If the system can access the OS after startup, use the OS tools to clear the local license information and restart the activation process. If the hardware information has changed, the activation process will be directly initiated upon startup. The reactivation process is the same as the initial activation process.
[0095] Furthermore, the method also includes: license authorization support for separate control of features, and a feature list is loaded into the kernel during the startup phase; when a feature is started, a separate device driver is used to enter the kernel to query whether the feature is supported, and if not, the feature cannot be started.
[0096] License authorization supports independent control of features. During the boot phase, the feature list is loaded into the kernel. When a feature is enabled, a separate device driver enters the kernel to query feature support. If feature support is not supported, the feature cannot be enabled.
[0097] Furthermore, the method further includes: detecting abnormal situations: the user device encrypts the local hardware information with the device authorization public key and sends it to the server; the abnormal situations include: certificate revocation and discovery of unauthorized illegal licenses.
[0098] When the CA private key / device-specific authorization private key is leaked, the private key is changed and the public key certificate is revoked, and a new public key certificate is updated and generated; the server decrypts and compares it with the hardware information recorded in the database. If they are consistent, the certificate is normal; if they are inconsistent, the certificate is abnormal. The server returns the abnormal result and updates the certificate; the client uses the updated certificate to verify the license. If the verification fails, the activation process is re-entered.
[0099] Exceptions to consider include:
[0100] 1) Certificate revocation:
[0101] If the CA private key / device-specific authorization private key is leaked, the previous public key certificate needs to be revoked and updated after the private key is changed.
[0102] 2) Detect unauthorized and illegal licenses.
[0103] In the event of an anomaly, the certificate only needs to be verified during system startup: the client encrypts the local hardware information using the device authorization public key and sends it to the server. The server decrypts the information and compares it with the hardware information recorded in the database. If there is a discrepancy, it indicates a certificate anomaly. The server returns the anomaly result and the updated certificate. The client uses the updated certificate to verify the license. If verification fails, the reactivation process begins.
[0104] The embodiment of the present invention includes the following key functions: activating the OS product and obtaining the authorized license during the first installation and startup; binding the activation license information with the hardware information and user information and managing and maintaining it; the license authorization includes the OS version, architecture support, and validity period; a list of features authorized by the license; saving the activation license locally and quickly verifying the activation status on subsequent startups; and detecting and disabling illegal licenses.
[0105] In addition, an embodiment of the present invention also provides a license authorization management device based on the Linux operating system, the device comprising: a processor and a memory; the memory is used to store one or more program instructions; the processor is used to run one or more program instructions to execute the steps of a license authorization management method based on the Linux operating system as described in any of the above items.
[0106] In addition, an embodiment of the present invention further provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the steps of the license authorization management method based on the Linux operating system as described in any one of the above items are implemented.
[0107] In the embodiments of the present invention, the processor may be an integrated circuit chip having signal processing capabilities. The processor may be a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.
[0108] The methods, steps, and logic diagrams disclosed in the embodiments of the present invention can be implemented or executed. A general-purpose processor can be a microprocessor or any conventional processor. The steps of the methods disclosed in the embodiments of the present invention can be directly implemented and executed by a hardware decoding processor, or by a combination of hardware and software modules within the decoding processor. The software modules can be located in a storage medium well-established in the art, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, or registers. The processor reads the information from the storage medium and, in conjunction with its hardware, completes the steps of the aforementioned methods.
[0109] The storage medium may be a memory and may be, for example, a volatile memory or a nonvolatile memory, or may include both volatile and nonvolatile memory.
[0110] Among them, the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory.
[0111] Volatile memory may be random access memory (RAM), which is used as an external cache memory. By way of example and not limitation, many forms of RAM are available, such as static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDRSDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM), and direct RAM bus random access memory (DRRAM).
[0112] The storage media described in the embodiments of the present invention are intended to include, but are not limited to, these and any other suitable types of memory.
[0113] Those skilled in the art will appreciate that in one or more of the above examples, the functions described herein can be implemented using a combination of hardware and software. When software is used, the corresponding functions can be stored in a computer-readable medium or transmitted as one or more instructions or codes on a computer-readable medium. Computer-readable media include computer storage media and communication media, wherein communication media includes any medium that facilitates the transmission of computer programs from one place to another. The storage medium can be any available medium that can be accessed by a general-purpose or special-purpose computer.
[0114] Although the present invention has been described in detail above using general descriptions and specific embodiments, it will be apparent to those skilled in the art that modifications and improvements may be made thereto. Therefore, such modifications and improvements, without departing from the spirit of the present invention, are intended to be within the scope of protection claimed herein.
Claims
1. A license authorization management method based on the Linux operating system, characterized in that: The method comprises: When the operating system is installed and started for the first time, it detects whether the activation license exists and verifies the legitimacy of the activation license; If the activation license does not exist or is illegal, the activation process is executed; Perform signature verification on the preset first process, and activate it using the preset first process after the verification passes; Obtain a user ID / user key, establish a secure connection with the server using the user ID / user key, and send an activation request to the server; The server receives the activation request from the user and executes the corresponding activation process according to the request type, wherein the activation process includes the first activation process and the update activation process; After the first activation process is started, the license verification is performed in the first process when the operating system is started again; Perform signature verification on the preset first process, including: Verify the kernel level by level using efuse / bootrom as the trusted root; After the kernel verification is passed, the kernel is used to perform signature verification on the preset first process; The method further comprises: Detecting abnormal situations: The user device encrypts the local hardware information with the device authorization public key and sends it to the server; The exceptions include: certificate revocation and discovery of unauthorized illegal licenses; When the CA private key / device-specific authorization private key is leaked, the private key is changed and the public key certificate is revoked, and a new public key certificate is generated; After decryption, the server compares the information with the hardware information recorded in the database. If they are consistent, the certificate is normal. If they are inconsistent, the certificate is abnormal. The server returns the abnormal result and updates the certificate. The client uses the updated certificate to verify the license. If the verification fails, it will re-enter the activation process.
2. The method for managing license authorization based on a Linux operating system according to claim 1, wherein: Obtain a user ID / user key, establish a secure connection with the server using the user ID / user key, and send an activation request to the server, including: The activation request includes: hardware information, OS version number information, and current processor architecture information; The hardware information includes but is not limited to CPU, eMMC and MAC address information.
3. The method for managing license authorization based on the Linux operating system according to claim 2, wherein: The server receives an activation request from the client and executes the corresponding activation process according to the request type. The activation process includes the initial activation process and the update activation process, including: Obtain the license quantity, OS type, and architecture associated with the user ID, and use the license quantity, OS type, and architecture to determine whether the activation can be supported. If the activation is supported and the hardware information corresponding to the current device is not recorded in the database, it is considered the first activation; The initial activation process includes: Record user device information and generate activation codes and authorization licenses based on hardware information; Generate an RSA key pair dedicated to the authorization process and generate a public key certificate for the public key through the internal CA process; Use the generated private key to sign the license; Sending the authorization license, license signature, and public key certificate to the user device; Among them, the user device information includes hardware information, version number and architecture; the authorization license information includes activation code, authorization architecture, authorization characteristics and expiration time; and the license signature is a hash signature.
4. A method for managing license authorization based on a Linux operating system as claimed in claim 3, characterized in that: Send the authorization license, license signature, and public key certificate to the user's device, including: After receiving the authorization license, license signature and public key certificate, the user equipment verifies the public key certificate and verifies the license signature using the verified public key certificate; Use the license information after signature verification to extract the license activation code, authorized OS version, architecture and time information; The user device generates a user activation code and verifies it with the license activation code. If the verification is successful, the license and signature information are written to the specified location on the disk and the software features authorized by the license are configured into the kernel through a specific driver for maintenance.
5. The method for managing license authorization based on a Linux operating system according to claim 4, wherein: After the initial activation process starts, license verification is performed in the first process when the operating system is restarted, including: Read the license information and signature information from the specified location on the disk and verify the public key certificate; Verify the license signature using the verified public key certificate and extract the activation code, authorized OS version, architecture and implementation information from the license information after the signature verification is passed; Generate an activation code and verify it with the activation code extracted from the license to verify the OS version, architecture and authorization period; After verification, the software features authorized by the license are configured into the kernel through the preset driver for maintenance and the OS is started, completing the first installation and startup of the operating system.
6. The method for managing license authorization based on the Linux operating system according to claim 5, wherein: The method further comprises: When encountering a scenario where an authorization update is required, the user purchases the corresponding authorization again, and the management platform configures the user's device in advance to indicate that an authorization update is required; Start the user device and determine whether it can enter the OS. If it can enter the OS, clear the local license information through the tools under the OS, and restart the activation process; If you cannot enter the OS, reinstall the OS and clear the local license information using the tools under the OS. Then restart the OS and start the activation process again. When the hardware information changes, the activation process will be directly started after the user device is started; Among them, the scenarios that require authorization updates are: hardware information changes caused by user equipment being returned to the factory for repair, license authorization renewal, license feature additions, and certificate updates.
7. A method for managing license authorization based on a Linux operating system as claimed in claim 6, characterized in that: The method further comprises: License authorization supports individual control of features, and the feature list is loaded into the kernel during the boot phase; When a feature is enabled, a separate device driver is used to query the kernel whether the feature is supported. If not, the feature cannot be enabled.
8. A license authorization management system based on Linux operating system, characterized in that: The system comprises: A legitimacy detection module is used to detect the existence of an activation license and verify the legitimacy of the activation license when the operating system is installed and started for the first time; An activation process execution module, used to execute the activation process if the activation license does not exist or the activation license is illegal; A signature verification module is used to verify the signature of the preset first process and activate it using the preset first process after the verification passes; An activation request sending module, configured to obtain a user ID / user key, establish a secure connection with a server using the user ID / user key, and send an activation request to the server; An activation process execution module is used for the server to receive an activation request from the user and execute a corresponding activation process according to the request type. The activation process includes an initial activation process and an update activation process. A license verification module is used to verify the license in the first process when the operating system is restarted after the first activation process is started; Perform signature verification on the preset first process, including: Verify the kernel level by level using efuse / bootrom as the trusted root; After the kernel verification is passed, the kernel is used to perform signature verification on the preset first process; Also includes: Detecting abnormal situations: The user device encrypts the local hardware information with the device authorization public key and sends it to the server; The exceptions include: certificate revocation and discovery of unauthorized illegal licenses; When the CA private key / device-specific authorization private key is leaked, the private key is changed and the public key certificate is revoked, and a new public key certificate is generated; After decryption, the server compares the information with the hardware information recorded in the database. If they are consistent, the certificate is normal. If they are inconsistent, the certificate is abnormal. The server returns the abnormal result and updates the certificate. The client uses the updated certificate to verify the license. If the verification fails, it will re-enter the activation process.
Citation Information
Patent Citations
License authentication method and system
CN115022065A