Service cluster authorization method, device and equipment

By using node devices to exchange blockchain data in the blockchain, the problem of authorized information in the authorization of software cluster authorizations and high system expenses is solved, and high security and flexible application development deployment and operation and maintenance are realized.

CN119357930AInactive Publication Date: 2025-01-24BEIJING SUWELL TECHNOLOGY CO LTD +2
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202411918663.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-25
Publication Date
2025-01-24
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

During the software cluster authorization process, authorization information is easy to tamper with, and a separate authorization server needs to be purchased and developed, with high system expenditure and low flexibility in application development deployment and operation and maintenance.

Method used

By switching blockchain data between the first node device and the second node equipment in the blockchain, the security storage and update of authorized information is achieved, and the demand for setting up the authorized server separately is avoided.

Benefits of technology

The system complexity and system expenditure have been reduced. The non -tampering of the blockchain -based unable to improve the security of authorization information and enhance the flexibility of application development deployment and operation and maintenance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119357930A_ABST
    Figure CN119357930A_ABST
Patent Text Reader

Abstract

The invention provides a service cluster authorization method, device and equipment, belongs to the technical field of computer information processing, and solves the problems of high service cost, poor security and low deployment and operation and maintenance flexibility in a software cluster authorization process. The method comprises the following steps: acquiring initialization data and first authorization data; obtaining first block chain data according to the initialization data and the first authorization data; sending the first block chain data to a second node device; obtaining second block chain data sent by a second node device, wherein the second block chain data is obtained by processing the first block chain data by the second node device; and updating the first block chain data according to the second block chain data. According to the scheme, the efficiency and safety of software cluster authorization are improved, and the service cost is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of computer information processing, and in particular to a service cluster authorization method, device and equipment. Background Art

[0002] Software authorization is an extension and development of the concept of software protection. The goal of software authorization is to allow software users to use the software according to the purchased license, involving the number of software installations, usage time, application scope, functional modules, etc.; software authorization can be divided into online authorization and offline authorization based on the activation method, and the main types of authorization are local authorization and cluster (or group) authorization.

[0003] Traditional cluster service authorization is implemented through a centralized authorization server. The main function of the authorization server is to verify the user's authorization request and return the authorization result. When the user starts the software, the software will send an authorization request to the authorization server and provide corresponding authentication information, such as product key, user identity, etc. After receiving the request, the authorization server will verify the information provided to determine whether the user has the right to use the software. The authorization server usually uses some encryption algorithms and security mechanisms to ensure the security of the authorization information. It verifies the authentication information provided by the user and checks whether the user has been authorized. If the verification is successful, an authorization license will be generated and returned to the user's computer or device. The license is used to confirm the user's identity and authorization information. The user's software will read the license and decide whether to continue using the software based on the information in the license. Summary of the invention

[0004] The present invention provides a service cluster authorization method, device and equipment, which solve the problems in the software cluster authorization process that authorization information is easy to tamper with, a separate authorization server needs to be purchased and developed, system expenses are high, and the flexibility of application development, deployment and operation and maintenance is low.

[0005] In order to solve the above technical problems, the technical solution of the present invention is as follows:

[0006] An embodiment of the present invention provides a service cluster authorization method, which is applied to a first node device in a blockchain, including:

[0007] Obtaining initialization data and first authorization data;

[0008] Obtaining first blockchain data according to the initialization data and the first authorization data;

[0009] Sending the first blockchain data to a second node device;

[0010] Acquire second blockchain data sent by the second node device, where the second blockchain data is obtained by the second node device processing the first blockchain data;

[0011] The first blockchain data is updated according to the second blockchain data.

[0012] Optionally, the second node device processes the first blockchain data to obtain second blockchain data, including:

[0013] Obtaining first blockchain data sent by the first node device;

[0014] Parsing and verifying the first blockchain data to obtain second authorization data;

[0015] Acquire change data, where the change data includes at least one of authorized user change data and authorized date change data;

[0016] The first blockchain data is processed according to the changed data to obtain the second blockchain data.

[0017] The embodiment of the present invention also provides a service cluster authorization method, which is applied to a second node device in a blockchain, including:

[0018] Obtaining first blockchain data sent by the first node device;

[0019] Parsing and verifying the first blockchain data to obtain second authorization data;

[0020] Acquire change data, where the change data includes at least one of authorized user change data and authorized date change data;

[0021] Processing the first blockchain data according to the changed data to obtain second blockchain data;

[0022] The second blockchain data is sent to the first node device.

[0023] Optionally, parsing and verifying the first blockchain data to obtain second authorization data includes:

[0024] Parsing the first blockchain data to obtain blockchain header data, where the blockchain header data includes at least one of a hash value of the block and first authorization data;

[0025] Verifying the blockchain header data to obtain verification data;

[0026] The first authorization data is processed according to the verification data to obtain second authorization data.

[0027] Optionally, the blockchain header data is verified to obtain verification data, including:

[0028] The validity of the hash value of the block and the first authorization data is verified. When the hash value of the block and the first authorization data are valid, the verification data is a first preset value; when the hash value of the block and the first authorization data are invalid, the verification data is a second preset value.

[0029] Optionally, processing the first authorization data according to the verification data to obtain second authorization data includes:

[0030] When the verification data is a first preset value, user information is obtained from the second node device;

[0031] The first authorization data is queried according to the user information of the second node device to obtain second authorization data.

[0032] Optionally, the first blockchain data is processed according to the change data to obtain the second blockchain data, including:

[0033] Packaging the changed data to obtain changed block data;

[0034] The changed block data is appended to the end of the first blockchain data to obtain the second blockchain data.

[0035] The embodiment of the present invention further provides a service cluster authorization device, which is applied to a first node device in a blockchain, including:

[0036] A first transceiver module, used to obtain initialization data and first authorization data;

[0037] A first processing module, configured to obtain first blockchain data according to the initialization data and the first authorization data;

[0038] The first transceiver module is further used to send the first blockchain data to a second node device;

[0039] The first transceiver module is further used to obtain second blockchain data sent by the second node device, where the second blockchain data is obtained by the second node device processing the first blockchain data;

[0040] The first generating module is used to update the first blockchain data according to the second blockchain data.

[0041] The embodiment of the present invention further provides a service cluster authorization device, which is applied to a second node device in a blockchain, including:

[0042] A second transceiver module is used to obtain the first blockchain data sent by the first node device;

[0043] A second processing module is used to parse and verify the first blockchain data to obtain second authorization data;

[0044] The second transceiver module further acquires change data, wherein the change data includes at least one of authorized user change data and authorized date change data;

[0045] A second generating module, configured to process the first blockchain data according to the change data to obtain second blockchain data;

[0046] The second transceiver module is further used to send the second blockchain data to the first node device.

[0047] An embodiment of the present invention further provides a node device, comprising: a processor and a memory storing a computer program, wherein the computer program executes the above method when executed by the processor.

[0048] The technical solution of the present invention includes at least the following effects:

[0049] The above scheme of the present invention obtains initialization data and first authorization data; obtains first blockchain data according to the initialization data and the first authorization data; sends the first blockchain data to the second node device; obtains the second blockchain data sent by the second node device, and the second blockchain data is obtained by the second node device processing the first blockchain data; updates the first blockchain data according to the second blockchain data. This scheme does not require the separate setting of authorization servers, nor does it require the purchase and development of separate authorization servers, and does not require attention to deployment and operation, which reduces system complexity and system expenses; based on the immutability of blockchain, it makes it more difficult to crack, as long as the initial block is created, the authorization information cannot be tampered with; without binding hardware, it solves the problem of dynamic service authorization of cloud platforms, and greatly enhances the flexibility of application development, deployment and operation. BRIEF DESCRIPTION OF THE DRAWINGS

[0050] Figure 1 is a flow chart of a service cluster authorization method applied to a first node device in a blockchain provided by an embodiment of the present invention;

[0051] Figure 2 is a flow chart of a service cluster authorization method applied to a second node device in a blockchain provided by an embodiment of the present invention;

[0052] Figure 3 It is a schematic diagram of the founding block data of the service cluster authorization method provided by an embodiment of the present invention;

[0053] Figure 4 It is a schematic diagram of the authorization and block synchronization process of the service cluster authorization method provided by an embodiment of the present invention;

[0054] Figure 5 This is a schematic diagram of a blockchain update process of a service cluster authorization method provided by an embodiment of the present invention;

[0055] Figure 6 It is a structural diagram of a service cluster authorization method device applied to a first node device in a blockchain provided by an embodiment of the present invention;

[0056] Figure 7 It is a structural diagram of a service cluster authorization method device applied to a second node device in a blockchain provided by an embodiment of the present invention;

[0057] Figure 8 It is a schematic diagram of the structure of a node device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0058] The exemplary embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. Although the exemplary embodiments of the present invention are shown in the accompanying drawings, it should be understood that the present invention can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided in order to enable a more thorough understanding of the present invention and to enable the scope of the present invention to be fully communicated to those skilled in the art.

[0059] like Figure 1 As shown, an embodiment of the present invention proposes a service cluster authorization method, which is applied to a first node device in a blockchain, including:

[0060] Step 11, obtaining initialization data and first authorization data;

[0061] Step 12, obtaining first blockchain data according to the initialization data and the first authorization data;

[0062] Step 13, sending the first blockchain data to the second node device;

[0063] Step 14: Obtain second blockchain data sent by the second node device, where the second blockchain data is obtained by the second node device processing the first blockchain data;

[0064] Step 15: Update the first blockchain data according to the second blockchain data.

[0065] In this embodiment, in order to implement service cluster authorization, an initialization block is first created, which can be called a genesis authorization block. This block is the first block of the authorized blockchain and has no preceding block. This block mainly contains two parts of information, one part is the basic necessary data information of the blockchain, that is, the initialization data, and the other part is the initialization data information used for authorization, that is, the first authorization data. These data information include but are not limited to the following parts:

[0066] Block Hash: refers to the unique identifier of the genesis block, which is usually calculated by an encryption algorithm. It should be noted that traditional authorization services generally need to be bound to a certain hardware (such as a server machine code) through an authorization certificate generated by a certain cryptographic algorithm, while the important feature of the method of the present invention is that it does not bind to a certain hardware, but only uses this unique identifier to uniquely identify the cluster that needs to be authorized. Once generated, it will not change unless it is reinitialized.

[0067] Timestamp: refers to the time information when the genesis block was created. It is used as the basic comparison value for the validity period of the authorization;

[0068] State: refers to the initial state of the blockchain, and some state information for authorization can also be written;

[0069] Consensus mechanism parameters: Depending on the consensus mechanism used by the blockchain (such as PoW, PoS, DPoS, etc.), it may contain specific parameters;

[0070] Chain ID: an identifier used to distinguish different blockchain networks;

[0071] Authorization information: refers to the data information in the method of the present invention that is different from the traditional blockchain, which is used to store the basic data and initialization data information for authorization, such as some basic data of this cluster, which includes a list of all software service modules that need to be authorized in this cluster, the authorization date for each software and service, the number of concurrent users, the basic information of the authorized user, the product key and the initial license information. The license contains the authorization information, validity period and other control conditions of the software.

[0072] After obtaining the initialization data and the first authorization data, the first blockchain data is generated based on these data, including packaging the data into the transaction format of the blockchain, adding metadata such as timestamps and hash values, and performing necessary encryption processing; using the key or token in the first authorization data to sign the data to prove the legitimacy and integrity of the data, and also verifying whether the format and content of the data meet the requirements of the blockchain system;

[0073] After the first blockchain data is generated, according to the topological structure and consensus mechanism of the blockchain network, a suitable node is selected to send the data. The data can be transmitted through a peer-to-peer (P2P) network or other communication protocols to send the first blockchain data to the second node device. After the second node device receives the first blockchain data, it performs local authorization according to the first authorization data in the first blockchain data.

[0074] After receiving the first blockchain data, the second node device will process it and generate second blockchain data, which will then be sent back to the original device or broadcast to other nodes in the network; since the authorization information often needs to be changed, such as changing the number of authorized users, changing the authorization date, etc.; in this embodiment, changing the authorization information is similar to the transaction process of the blockchain, and each change is equivalent to a transaction in the coin chain. Each change will be packaged into a new block and added to the blockchain for distribution and synchronization, so that all cluster networks can obtain this authorization change data information; it is worth noting that, unlike the coin exchange in the blockchain, there is no need to compete for and reward the new block data packaging, because generally all server clusters in the cluster can be considered trustworthy, and blocks can be packaged through any server node; finally, the first blockchain data is updated according to the received second blockchain data.

[0075] This solution does not require the establishment of a separate authorization server, nor does it require the purchase and development of a separate authorization server, and there is no need to pay attention to deployment and operation and maintenance, which reduces system complexity and system expenses; the immutability of blockchain makes it more difficult to crack, and as long as the initial block is created, the authorization information cannot be tampered with; there is no need to bind hardware, which solves the dynamic service authorization problem of the cloud platform, and greatly enhances the flexibility of application development, deployment and operation and maintenance.

[0076] In an optional embodiment of the present invention, step 14 may include:

[0077] Step 141, obtaining first blockchain data sent by the first node device;

[0078] Step 142, parsing and verifying the first blockchain data to obtain second authorization data;

[0079] Step 143, obtaining change data, wherein the change data includes at least one of authorized user change data and authorized date change data;

[0080] Step 144: Process the first blockchain data according to the changed data to obtain second blockchain data.

[0081] In this embodiment, after the second node device participating in the cluster is started, a node service of a blockchain will be started first. This node will connect to other existing nodes (called peer nodes or peer nodes), namely the first node devices, which already have a complete copy of the blockchain; the second node device will request to obtain the header information of the blockchain from the connected first node device, and obtain the first blockchain data sent by the first node device; this usually includes the latest block header (including the hash value, timestamp, and authorization certificate information of the block, etc.); once the last block of the blockchain is determined, it will start to request to download the block data; this process can be sequential or jumpy, depending on the specific blockchain protocol and implementation; while or after downloading each block, the second node device will parse and verify the first blockchain data to verify the validity of the block, which includes checking the block The second authorization data is obtained by combining the hash value of the header, the information of the authorization certificate, etc.; for each authorization in the block, the second node device verifies the validity of this authorization, including the signature, authorization date and scope consistency, etc.; once the block and authorization information are verified, this information will be stored in the node's local disk or database; of course, some scenarios that cannot be persisted do not need to be stored, because the size of these block information is not large, and they can be downloaded and synchronized in real time after each startup, but in a cluster, at least two or more server nodes with persistence capabilities must be guaranteed, otherwise the block information will be permanently lost; when the second node device downloads and verifies all blocks, it is considered to be synchronized, and can start to participate in transaction verification and creation of new blocks in the network; even after the initial synchronization is completed, the server node needs to continue to synchronize new blocks and transactions to keep the blockchain updated.

[0082] like Figure 2 As shown, an embodiment of the present invention proposes a service cluster authorization method, which is applied to a second node device in a blockchain, including:

[0083] Step 21, obtaining first blockchain data sent by the first node device;

[0084] Step 22, parsing and verifying the first blockchain data to obtain second authorization data;

[0085] Step 23, obtaining change data, wherein the change data includes at least one of authorized user change data and authorized date change data;

[0086] Step 24: Process the first blockchain data according to the change data to obtain second blockchain data;

[0087] Step 25: Send the second blockchain data to the first node device.

[0088] In this embodiment, the second node device first receives the first blockchain data sent from the first node device; the first blockchain data includes metadata such as authorization information, hash value, and timestamp; after receiving the first blockchain data, the second node device parses it, that is, decomposes it into various components for further analysis and processing; at the same time, the parsed data is also verified to ensure the integrity, authenticity and validity of the data. After parsing and verification, the second node device extracts information related to authorization, namely, second authorization data, which includes the identity information of the authorized user, detailed information of the authorized authority, etc.;

[0089] The system processes the first blockchain data accordingly based on the change data obtained previously. This processing may include updating authorization information, adding new transaction records, modifying timestamps, etc. The processed data is reorganized into a new blockchain format, namely the second blockchain data. This process needs to ensure the consistency and security of the data to prevent the data from being tampered with or damaged during the processing. At the same time, the system also needs to maintain the integrity of the blockchain to ensure that the new data block can be correctly linked to the original blockchain; since the authorization information often needs to be changed, such as changing the number of authorized users, changing the authorization date, etc.; the second node device changes the data and processes the first blockchain data accordingly, including updating the authorization information, adding new transaction records, modifying timestamps, etc.; the processed data is reorganized into a new blockchain format, and the change block data is appended to the end of the first blockchain data to obtain the second blockchain data; after generating the second blockchain data, the second node device sends the second blockchain data back to the first node device to ensure that the first node device can update its blockchain data in real time to reflect the latest authorization information and changes.

[0090] In an optional embodiment of the present invention, step 22 may include:

[0091] Step 221, parsing the first blockchain data to obtain blockchain header data, where the blockchain header data includes at least one of a hash value of the block and first authorization data;

[0092] Step 222, verifying the blockchain header data to obtain verification data;

[0093] Step 223: Process the first authorization data according to the verification data to obtain second authorization data.

[0094] In this embodiment, the second node device will parse and verify the first blockchain data to verify the validity of the block, which includes checking the hash value of the block header, information of the authorization certificate, etc.; when the verification data is the same as the preset value, it means that the received first authorization data is valid, that is, the verification is passed, and the second node device will query the first authorization data according to the user information of the second node device, receive the authorization data in the first blockchain data, and obtain the second authorization data; when the verification data is different from the preset value, it means that the received first authorization data is invalid, that is, the verification fails, and the second node device will receive the first blockchain data again.

[0095] In an optional embodiment of the present invention, step 24 may include:

[0096] Step 241, packing the changed data to obtain changed block data;

[0097] Step 242: append the changed block data to the end of the first blockchain data to obtain the second blockchain data.

[0098] In this embodiment, users can obtain authorization certificates through purchase and other channels. This certificate is generally generated by the software manufacturer through a certain encryption algorithm; it contains the initial information for the users of this cluster. As mentioned earlier, each cluster will have an initialization block, which contains the information when the cluster was initialized. When changing the authorization information, this part of the information must be consistent. It needs to be considered valid only after a one-way password comparison, otherwise it will not enter the subsequent block packaging and synchronization process; the changed authorization information will be packaged together with the initial information used for verification to form a new block data; select any service node in the cluster to pass in the new block data, the format can be agreed in advance, and the second node device finds When there is a new block, first verify whether the initial information is consistent. If the certificate is valid after one-way comparison, the block is considered to be confirmed. After confirming that the new block data is valid, the second node device will broadcast the block and broadcast the new block to the network. Other nodes (such as the first node device) will also verify the validity of the block. After other service nodes in the network verify the new block, they will add it to their own blockchain. This process is called confirmation. Usually multiple confirmations (i.e., the addition of subsequent blocks) are required for the transaction to be considered final and irreversible. With the addition of new blocks, all nodes in the blockchain network will update their own ledgers to ensure that all participants have the latest data records. Once all service nodes confirm and add to the blockchain, the authorization information change is considered complete.

[0099] A specific embodiment of the service cluster authorization method provided by an embodiment of the present invention is:

[0100] Step 1: Obtain initialization data and first authorization data.

[0101] When a customer obtains a license for a software system through purchase or other means, the software manufacturer delivers or helps the user initially deploy the license package, which contains initial license data.

[0102] Step 2: Obtain first blockchain data based on the initialization data and the first authorization data.

[0103] The first blockchain data is generated according to the initialization data and the first authorization data; wherein, the initial authorization data corresponds to the genesis block data in the blockchain field, and the genesis block data contains a block header and block body data. The block header records some meta information of this authorized blockchain, such as version information, generation time, random number, and hash value of the block data area, etc. It should be noted that since it is the first block of creation, there is no link data of the previous block, and the block body data stores the basic information of the authorized user and relevant information of the authorized software system, such as the authorization scope and authorization period of the software system. In addition, a server characteristic value for initial deployment can be added according to demand, which is used for authentication of initial deployment to avoid theft. The schematic diagram of the genesis block data is shown as follows: Figure 3 shown.

[0104] Step 3: Send the first blockchain data to the second node device.

[0105] During the initial deployment, the deployment is performed through a designated deployment computer, namely the first node device, and the cluster can be evacuated after the deployment is completed. In addition to the deployment of the software system itself, the deployment process also synchronizes the genesis block data to each cluster server, that is, sends the first blockchain data to the second node device;

[0106] Block data synchronization is completed through a dedicated service, which can be an independent service, and can be started and generated at any time or destroyed. After startup, it will immediately initiate a request to other nodes to obtain block data, thereby obtaining authorization information and determining whether other software services or module containers running on this server are authorized. It is worth noting that each server node will synchronize all blockchain data of the entire cluster. In addition to verifying the authorization status of the node server, it is also necessary to transmit the complete blockchain data to other node servers (this process is similar to the P2P transmission process). After obtaining the complete blockchain data, it can be persisted locally, because this blockchain synchronization verification service may be destroyed at any time, and persistent storage is conducive to fast loading and authorization services after the next startup;

[0107] When a service or module of the entire software system needs to confirm the authorization status, it can initiate an authorization authentication application to the authorization service (if the authorization service is not running, the service can be automatically started). After receiving the authorization authentication application, the authorization service will compare the service type, date and other information of the application with the corresponding information in the blockchain. If it is within the authorization range, it will return permission. If it is not within the authorization range, it will return rejection. The schematic diagram of the authorization and block synchronization process is shown below. Figure 4 shown.

[0108] Step 4: Obtain the second blockchain data sent by the second node device.

[0109] The second node device authorizes according to the first blockchain data, updates the first blockchain data according to the change information, generates the second blockchain data, and then sends it to the first node device; the change of authorization information is similar to the transaction process of blockchain currency. Each change will add a new block data and link it to the previous block. The entire authorization process can be fully described by blockchain data. The following is an explanation of the scenario where a user asks the software developer to renew the software for one year:

[0110] After receiving the one-year renewal order, the software manufacturer will form an authorization data packet with the authorization extension information. The format is basically the same as the authorization information in the Genesis block data, that is, the authorization date will be updated, and then the hash value of this block data will be calculated and saved in the block header;

[0111] Then the block data of the renewal extension is deployed to the customer's target service cluster; similar to the process of initializing and deploying the genesis block, the deployment can be performed by any approved computer (the approved method can be a fixed machine code or a dedicated person). This deployment process actually links the block data of the renewal extension to the blockchain of the target customer cluster. Once the link is completed, the authorization is completed, and all software services will be authorized with the latest authorization information. This authorization process can be completed after the block is linked. This authorization block has been circulated and synchronized in the cluster. This is similar to a transaction of blockchain currency. Whether it is an increase or a decrease, but each transaction is unique and will be recorded in a chain manner, which cannot be cancelled or changed.

[0112] If the authorization period has expired, due to the lack of updated blockchain data for renewal, the authorization status will be invalidated during the authorization process, so the authorization cannot be obtained to achieve software invalidation and achieve the authorization purpose. Figure 5 shown.

[0113] Step 5: Update the first blockchain data according to the second blockchain data.

[0114] After the first node device receives the second blockchain data, it updates the first blockchain data. Among them, all authorization information needs to be transformed into fixed-length output characters through an irreversible algorithm for fast comparison. The commonly used algorithm in blockchain is the hash algorithm. Generally speaking, any irreversible algorithm can be used because only comparison is required and data restoration is not required. Therefore, there is authorization information in the data area of ​​the block, and the block header contains the hash value of the block data. When performing authorization comparison, as long as the block data is calculated using the hash algorithm and then compared with the block header, if they are consistent, the block data can be considered credible and can be used to determine the authorization information;

[0115] Only authorized computers or personnel can perform operations to add new blocks. This can be constrained by traditional machine codes or passwords. For example, only authorized computers or personnel have the right to package blockchain coins. After the authorization operation is completed, this role can be withdrawn, and other servers in the cluster that do not have this role only have the ability to compare, authenticate and transfer blocks, but do not have the right to add or change blockchains (of course, according to scenario requirements, the authorized role can also be placed in the cluster, and then encryption operations can be performed in the block data, but this situation will not be discussed here);

[0116] After the block data is deployed to the cluster, it can be divided into two types: persistence and non-persistence. The difference is that if it is not persisted, it must be ensured that there are always online nodes in the cluster, otherwise the blockchain data will be lost and cannot be authorized. At this time, the initial block data needs to be redeployed. This situation will not occur after persistence.

[0117] The synchronization of block data can be achieved using a variety of technical solutions, such as configuring the server through the application to form a principle similar to the P2P track service, or using broadcast data and other methods.

[0118] The technical solution of the present invention has the following technical advantages:

[0119] (1) The initial block data is the most important part of the entire method design, because it records all the basic information about this software cluster, including the use license generated by the software developer for this customer, authorization information, validity period and other control conditions. The format and content are determined by the software developer, and it is only necessary to ensure that the key is one-way irreversible. All subsequent changes in authorization information will be verified based on the initialization block data before changes;

[0120] (2) Blockchain changes can be made using the block service process of any server node, and the "block packaging rights" can be obtained without proof of work (PoW). This is mainly determined by the user.

[0121] (3) In extreme cases, the entire authorized blockchain network may not require persistent nodes, that is, as long as one node in the cluster is not offline, authorization can be completed. Of course, this is only an extreme case and will not occur in general. In addition, setting up multiple persistent server nodes as a guarantee is conducive to the stable operation of the entire system.

[0122] (4) The synchronization process of block data is very fast. When each server node is scaled, expanded or adjusted, it is necessary to start the blockchain authorization service first, and then start other services, otherwise authorization cannot be obtained.

[0123] like Figure 6 As shown, the embodiment of the present invention further provides a service cluster authorization device 60, which is applied to a first node device in a blockchain, including:

[0124] A first transceiver module 61, used to obtain initialization data and first authorization data;

[0125] A first processing module 62, configured to obtain first blockchain data according to the initialization data and the first authorization data;

[0126] The first transceiver module 61 is further used to send the first blockchain data to the second node device;

[0127] The first transceiver module 61 is further used to obtain second blockchain data sent by the second node device, where the second blockchain data is obtained by the second node device processing the first blockchain data;

[0128] The first generating module 63 is used to update the first blockchain data according to the second blockchain data.

[0129] Optionally, the second node device processes the first blockchain data to obtain second blockchain data, including:

[0130] Obtaining first blockchain data sent by the first node device;

[0131] Parsing and verifying the first blockchain data to obtain second authorization data;

[0132] Acquire change data, where the change data includes at least one of authorized user change data and authorized date change data;

[0133] The first blockchain data is processed according to the changed data to obtain the second blockchain data.

[0134] It should be noted that this device is a device corresponding to the above-mentioned service cluster authorization method applied to the first node device in the blockchain. All implementation methods in the above-mentioned service cluster authorization method embodiment applied to the first node device in the blockchain are applicable to this embodiment and can achieve the same technical effect.

[0135] like Figure 7 As shown, the embodiment of the present invention further provides a service cluster authorization device 70, which is applied to a second node device in a blockchain, including:

[0136] The second transceiver module 71 is used to obtain the first blockchain data sent by the first node device;

[0137] A second processing module 72 is used to parse and verify the first blockchain data to obtain second authorization data;

[0138] The second transceiver module 71 further acquires change data, wherein the change data includes at least one of authorized user change data and authorized date change data;

[0139] A second generation module 73, used to process the first blockchain data according to the change data to obtain second blockchain data;

[0140] The second transceiver module 71 is further used to send the second blockchain data to the first node device.

[0141] Optionally, parsing and verifying the first blockchain data to obtain second authorization data includes:

[0142] Parsing the first blockchain data to obtain blockchain header data, where the blockchain header data includes at least one of a hash value of the block and first authorization data;

[0143] Verifying the blockchain header data to obtain verification data;

[0144] The first authorization data is processed according to the verification data to obtain second authorization data.

[0145] Optionally, the blockchain header data is verified to obtain verification data, including:

[0146] The validity of the hash value of the block and the first authorization data is verified. When the hash value of the block and the first authorization data are valid, the verification data is a first preset value; when the hash value of the block and the first authorization data are invalid, the verification data is a second preset value.

[0147] Optionally, processing the first authorization data according to the verification data to obtain second authorization data includes:

[0148] When the verification data is a first preset value, user information is obtained from the second node device;

[0149] The first authorization data is queried according to the user information of the second node device to obtain second authorization data.

[0150] Optionally, the first blockchain data is processed according to the change data to obtain the second blockchain data, including:

[0151] Packaging the changed data to obtain changed block data;

[0152] The changed block data is appended to the end of the first blockchain data to obtain the second blockchain data.

[0153] It should be noted that this device is a device corresponding to the above-mentioned service cluster authorization method applied to the second node device in the blockchain. All implementation methods in the above-mentioned service cluster authorization method embodiment applied to the second node device in the blockchain are applicable to this embodiment and can achieve the same technical effect.

[0154] like Figure 8 As shown, the embodiment of the present invention further provides a node device 80, including a processor 81, a memory 82, a program or instruction stored in the memory 82 and executable on the processor 81, and the program or instruction is executed by the processor 81 to implement each process of the above-mentioned service cluster authorization method embodiment, and can achieve the same technical effect, to avoid repetition, it is not repeated here. It should be noted that the node device in the embodiment of the present invention includes the node device of any node in the blockchain.

[0155] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.

[0156] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0157] In the embodiments provided by the present invention, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic, for example, the division of units is only a logical function division, and there may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0158] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0159] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.

[0160] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the methods of various embodiments of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as USB flash drives, mobile hard disks, ROM, RAM, magnetic disks, or optical disks.

[0161] In addition, it should be pointed out that in the apparatus and method of the present invention, it is obvious that each component or each step can be decomposed and / or recombined. These decompositions and / or recombinations should be regarded as equivalent schemes of the present invention. Moreover, the steps of performing the above series of processing can naturally be performed in chronological order according to the order of description, but it is not necessary to perform them in chronological order, and some steps can be performed in parallel or independently of each other. For those of ordinary skill in the art, it is understandable that all or any steps or components of the method and apparatus of the present invention can be implemented in hardware, firmware, software or a combination thereof in any computing device (including processors, storage media, etc.) or a network of computing devices, which can be achieved by those of ordinary skill in the art using their basic programming skills after reading the description of the present invention.

[0162] Therefore, the purpose of the present invention can also be achieved by running a program or a group of programs on any computing device. The computing device can be a well-known general-purpose device. Therefore, the purpose of the present invention can also be achieved by simply providing a program product containing a program code for implementing a method or device. That is to say, such a program product also constitutes the present invention, and a storage medium storing such a program product also constitutes the present invention. Obviously, the storage medium can be any well-known storage medium or any storage medium developed in the future. It should also be pointed out that in the device and method of the present invention, it is obvious that each component or each step can be decomposed and / or recombined. These decompositions and / or recombinations should be regarded as equivalent schemes of the present invention. In addition, the steps of performing the above-mentioned series of processing can naturally be performed in chronological order according to the order of description, but it is not necessary to perform them in chronological order. Some steps can be performed in parallel or independently of each other.

[0163] The above are preferred embodiments of the present invention. It should be pointed out that, for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present invention. These improvements and modifications should also be regarded as within the scope of protection of the present invention.

Claims

1. A service cluster authorization method, characterized in that: The first node device used in blockchain includes: Obtaining initialization data and first authorization data; Obtaining first blockchain data according to the initialization data and the first authorization data; Sending the first blockchain data to a second node device; Acquire second blockchain data sent by the second node device, where the second blockchain data is obtained by the second node device processing the first blockchain data; The first blockchain data is updated according to the second blockchain data.

2. The service cluster authorization method according to claim 1, characterized in that: The second node device processes the first blockchain data to obtain second blockchain data, including: Obtaining first blockchain data sent by the first node device; Parsing and verifying the first blockchain data to obtain second authorization data; Acquire change data, where the change data includes at least one of authorized user change data and authorized date change data; The first blockchain data is processed according to the changed data to obtain the second blockchain data.

3. A service cluster authorization method, characterized in that: The second node device used in the blockchain includes: Obtaining first blockchain data sent by the first node device; Parsing and verifying the first blockchain data to obtain second authorization data; Acquire change data, where the change data includes at least one of authorized user change data and authorized date change data; Processing the first blockchain data according to the changed data to obtain second blockchain data; The second blockchain data is sent to the first node device.

4. The service cluster authorization method according to claim 3, characterized in that: The first blockchain data is parsed and verified to obtain second authorization data, including: Parsing the first blockchain data to obtain blockchain header data, where the blockchain header data includes at least one of a hash value of the block and first authorization data; Verifying the blockchain header data to obtain verification data; The first authorization data is processed according to the verification data to obtain second authorization data.

5. The service cluster authorization method according to claim 4, characterized in that: The blockchain header data is verified to obtain verification data, including: The validity of the hash value of the block and the first authorization data is verified. When the hash value of the block and the first authorization data are valid, the verification data is a first preset value; when the hash value of the block and the first authorization data are invalid, the verification data is a second preset value.

6. The service cluster authorization method according to claim 5, characterized in that: Processing the first authorization data according to the verification data to obtain second authorization data includes: When the verification data is a first preset value, user information is obtained from the second node device; The first authorization data is queried according to the user information of the second node device to obtain second authorization data.

7. The service cluster authorization method according to claim 3, characterized in that: According to the change data, the first blockchain data is processed to obtain the second blockchain data, including: Packaging the changed data to obtain changed block data; The changed block data is appended to the end of the first blockchain data to obtain the second blockchain data.

8. A service cluster authorization device, characterized in that: The first node device used in blockchain includes: A first transceiver module, used to obtain initialization data and first authorization data; A first processing module, configured to obtain first blockchain data according to the initialization data and the first authorization data; The first transceiver module is further used to send the first blockchain data to a second node device; The first transceiver module is further used to obtain second blockchain data sent by the second node device, where the second blockchain data is obtained by the second node device processing the first blockchain data; The first generating module is used to update the first blockchain data according to the second blockchain data.

9. A service cluster authorization device, characterized in that: The second node device used in the blockchain includes: A second transceiver module is used to obtain the first blockchain data sent by the first node device; A second processing module is used to parse and verify the first blockchain data to obtain second authorization data; The second transceiver module further acquires change data, wherein the change data includes at least one of authorized user change data and authorized date change data; A second generating module, configured to process the first blockchain data according to the change data to obtain second blockchain data; The second transceiver module is further used to send the second blockchain data to the first node device.

10. A node device, characterized in that: include: A processor and a memory storing a computer program, wherein when the computer program is executed by the processor, the method according to any one of claims 1 to 2 or any one of claims 3 to 7 is performed.

Citation Information

Patent Citations

  • Registration and authorization method, apparatus and system

    CN107079036A

  • A block chain consensus mechanism based on credit proof PoC and an implementation method

    CN109727038A

  • Data processing method and device, node equipment and storage medium

    CN111367923A

  • Block chain-based shared computing method and device, equipment and storage medium

    CN117061132A

  • Block chain-based business information change management method and system

    CN119004528A