SYSTEM AND METHOD FOR PROVIDING AN INTERFACE FOR BLOCKCHAIN CLOUD SERVICES
The Blockchain Cloud Service provides a comprehensive infrastructure for deploying and managing permissioned blockchain networks, addressing inefficiencies in identity and transaction processing, and enhancing scalability and security for enterprise applications.
Patent Information
- Application Number
- JP2023116072
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Priority Date
- 2018-09-25
- Filing Date
- 2023-07-14
- Publication Date
- 2024-11-08
- Estimated Expiration
- 2038-09-28
AI Technical Summary
Existing blockchain systems lack efficient infrastructure for deploying and managing permissioned blockchain networks, particularly in a cloud environment, leading to inefficiencies in identity management, transaction processing, and scalability.
A system and method for implementing a Blockchain Cloud Service (BCS) that provides a complete set of infrastructure services, including compute, containers, storage, and identity management, to configure and execute production-ready blockchains, leveraging Hyperledger Fabric and Oracle PaaS Manager, with a management console and REST proxy service for automation and interface management.
Enables scalable, secure, and efficient deployment and management of permissioned blockchain networks, reducing the need for intermediaries and enhancing transaction processing and identity management, suitable for enterprise applications.
Smart Images

Figure 0007579922000021 
Figure 0007579922000022 
Figure 0007579922000023
Abstract
Description
[Technical Field]
[0001] Copyright Notice A portion of the disclosure of this patent document contains material that is subject to copyright protection. As this patent document or patent disclosure appears in the Patent and Trademark Office patent file or records, the copyright owner has no objection to the facsimile reproduction thereof by anyone, but otherwise reserves all copyright rights whatsoever at all times.
[0002] Priority claims and cross-references to related applications: This application is a continuation of U.S. provisional patent applications entitled "SYSTEM AND METHOD FOR PROVIDING A BLOCKCHAIN CLOUD SERVICE," filed on September 29, 2017, serial number 62 / 565,999, and "SYSTEM AND METHOD FOR PROVIDING AN INTERFACE FOR A BLOCKCHAIN CLOUD SERVICE," filed on September 25, 2018, serial number 16 / 141,329. U.S. patent application Ser. No. 16 / 141,337, filed September 25, 2018, entitled "SYSTEM AND METHOD FOR MANAGING A BLOCKCHAIN CLOUD SERVICE"; and claims the benefit of priority to U.S. patent application Ser. No. 16 / 141,339, entitled "SYSTEM AND METHOD FOR PROVIDING A REPRESENTATIONAL STATE TRANSFER PROXY SERVICE FOR A BLOCKCHAIN CLOUD SERVICE," filed on September 25, 2018, and related to U.S. patent application Ser. No. 15 / 485,532, entitled "MULTI-TENANT IDENTITY AND DATA SECURITY MANAGEMENT CLOUD SERVICE," filed on April 12, 2017 (later issued as U.S. Patent No. 9,781,122 on October 3, 2017), each of which is incorporated herein by reference.
[0003] Field of the invention: This disclosure relates generally to systems and methods for providing a distributed ledger. More particularly, this disclosure describes systems and methods for managing a distributed ledger that is implemented as a blockchain cloud service. [Background technology]
[0004] background: A distributed ledger may be loosely described as a digital record of asset ownership. There is no central administrator of the ledger, and no central data store. Instead, the ledger is replicated across many participating nodes in a computing environment that may be geographically spread across multiple locations, countries, or institutions. A consensus protocol ensures that each node's copy of the ledger is identical to every other node's copy, and the collection of copies may be viewed as a single shared ledger. Distributed ledgers may be used by asset owners, for example, using cryptographic signature techniques to debit their own account and credit another account.
[0005] A blockchain is a data structure that can be used to create a tamper-resistant distributed ledger. Multiple nodes organize transactions from clients into blocks. Following a common packaged protocol, nodes use a consensus protocol to agree on the next block. Blocks carry a cumulative cryptographic hash that makes tampering with the ledger difficult. Each block has a relationship (hash value) to the previous block in time. Additionally, each block may contain its own hash. The blockchain can be traversed backwards (e.g., up the chain).
[0006] A blockchain can be either a permissionless blockchain or a permissioned blockchain. Anyone can join a permissionless blockchain and have a copy of the distributed ledger. Bitcoin and Ethereum are permissionless blockchains. Permissioned blockchains are examples of permissionless blockchains. Permissionless blockchains allow anonymous participants to maintain the ledger while avoiding control by a single entity. However, given the anonymity, identity, accountability, and auditability are difficult. In contrast, permissioned blockchains allow for a level of trust and accountability by accepting members by invitation and allowing explicitly authorized parties to maintain the ledger.
[0007] Hyperledger Fabric is an example of a permissioned blockchain. Hyperledger Fabric, an enterprise-grade open-source distributed ledger framework and codebase, is an example of a distributed ledger platform implementation for running smart contracts. It leverages container technology to host smart contracts, called "chaincode," which contain the system's application logic.
[0008] Platform as a Service (PaaS) is There are many cloud services for application development, data management, integration, mobile, and the Internet of Things (IoT). As demand from cloud services increases, it would be desirable to offer blockchain PaaS cloud services. Blockchain PaaS cloud services can provide a pre-assembled platform for building and executing smart contracts and maintaining tamper-resistant distributed ledgers, while reducing the need for third-party intermediaries. PaaS blockchain cloud services can also enable the development of blockchain solutions that leverage other PaaS services. Summary of the Invention [Means for solving the problem]
[0009] overview: According to one embodiment, a system and method for implementing a distributed ledger as a Blockchain Cloud Service (BCS) is described herein. A BCS may include a complete set of infrastructure services and embedded resources: compute, containers, storage, identity management, and event streaming, to enable the configuration and execution of a production-ready blockchain. In response to an administrator specifying one or more parameters, the BCS configures the underlying infrastructure with the required blockchain network components, interfaces, representational state transfer (REST) proxy service components, and management console components. You can provision components.
[0010] According to one embodiment, the distributed ledger may be Hyperledger Fabric, which is an implementation of blockchain technology intended as a foundation for developing blockchain applications. Hyperledger Fabric is a modular application It can provide a blockchain-based architecture that leverages container technology to host smart contracts called "chaincode" that contain the system's application logic.
[0011] According to one embodiment, the BCS can be based on a PaaS manager (e.g., the Oracle PaaS Service Manager (PSM) platform) and can run in a compute space (e.g., an external compute space) on the PaaS manager. The system utilizes features of the PSM platform, including Oracle Identity Cloud Service (IDCS), Oracle Load Balancer as a Service (LBaaS), Oracle Event Hub Cloud Service, and a container runtime service environment (e.g., Docker or Oracle's Application Container Cloud Service) layered with Oracle Cloud Storage. Each customer blockchain can be provisioned and run as a tenant. The system supports multiple blockchains, each provisioned and run as a separate tenant in a multi-tenant environment.
[0012] According to one embodiment, both the management console component and the REST proxy service component may be network nodes in the BCS.
[0013] According to one embodiment, the management console component facilitates and automates the provisioning, monitoring, and configuration of the BCS. The management console component includes a web application that runs in a scripting runtime environment, such as Node.js. The web application can be built on a graphical user interface framework and a web framework and can include multiple custom functions or APIs for communicating with various nodes or services in the BCS instance. The web application can populate view objects with information from the various nodes or services in the BCS instance for display in the console user interface. The management console component can also provide multiple functions for an administrator to start, stop, and update one or more nodes in the BCS instance. A set of management REST APIs can be provided by or accessed by the scripting runtime environment to support the same functionality provided by the web application.
[0014] According to one embodiment, a REST proxy service component (i.e., a REST proxy service, or REST proxy) within a BCS instance can use a service development kit (SDK) for distributed ledgers in BCS to communicate with the distributed ledger and can query and request data through chaincode. It can provide a REST API for use by client applications to invoke transactions synchronously or asynchronously through chaincode, obtain transaction status, and obtain the BCS proxy version. The REST proxy service component can authenticate and translate REST calls into remote procedure calls, such as Google® Remote Procedure Calls (gRPC), for use in interfacing with the distributed ledger. The REST proxy service component can also provide a REST API that supports the same functionality as provided by the BCS Admin Console component and can provide a user interface for client applications to consume a BCS instance. [Brief explanation of the drawings]
[0015] Brief description of the drawings: [Figure 1A] FIG. 1 illustrates a transaction flow in the fabric of a blockchain cloud service system, according to one embodiment. [Figure 1B] FIG. 1 illustrates a blockchain cloud service system according to one embodiment. [Figure 1C] FIG. 1 illustrates a BCS system according to one embodiment. [Figure 1D] FIG. 1 illustrates a BCS system according to one embodiment. [Figure 1E] 1 is a flowchart of a method for providing an interface for a blockchain cloud service, according to one embodiment. [Figure 2] FIG. 1 illustrates a gateway for a blockchain cloud service system, according to one embodiment. [Figure 3] FIG. 1 illustrates persistence for a blockchain cloud service system, according to one embodiment. [Figure 4] FIG. 1 illustrates an exemplary deployment of a fabric on a BCS. [Figure 5] FIG. 1 illustrates a chaincode architecture according to one embodiment. [Figure 6] FIG. 1 illustrates a system for providing a management console according to one embodiment. [Figure 7A] FIG. 10 illustrates an example of a user interface in the BCS Console UI, according to one embodiment. [Figure 7B] FIG. 10 illustrates an example of a user interface in the BCS Console UI, according to one embodiment. [Figure 7C] FIG. 1 illustrates a method for providing a management console according to one embodiment. [Figure 8A] FIG. 1 illustrates a system for providing REST proxy services in a BCS instance, according to one embodiment. [Figure 8B] FIG. 1 illustrates a system for providing REST proxy services in a BCS instance, according to one embodiment. [Figure 8C] FIG. 1 illustrates a method for providing REST proxy services in a BCS instance, according to one embodiment. [Figure 9A] FIG. 1 illustrates a typical IDCS use case for single sign-on, according to one embodiment. [Figure 9B] FIG. 1 illustrates an IDCS use case for Fabric client authentication, according to one embodiment. DETAILED DESCRIPTION OF THE INVENTION
[0016] Detailed Description: According to one embodiment, a system and method for implementing a distributed ledger as a cloud service is described herein. In one particular embodiment, a permissioned blockchain ledger, such as Hyperledger Fabric, may be offered as a Blockchain Cloud Service (BCS).
[0017] In the following description, the present invention is illustrated by way of example, and not by way of limitation, in the figures of the accompanying drawings. References to various embodiments in this disclosure are not necessarily to the same embodiment, and such references imply at least one. While specific implementations are discussed, it is understood that this is provided by way of example only. Those skilled in the relevant art will recognize that other components and configurations can be used without departing from the scope and spirit of the invention.
[0018] According to one embodiment, in some cases, numerous specific details will be set forth in order to provide a thorough description of the present invention. However, it will be apparent to one skilled in the art that the present invention may be practiced without these specific details. In other cases, it may obscure the invention. To avoid confusion, well-known features have not been described in detail.
[0019] The present invention is described with the help of functional building blocks that illustrate the performance of specified functions and their relationships. For convenience of explanation, the boundaries of these functional building blocks are often arbitrarily defined herein. Thus, functions illustrated to be performed by the same elements may, in alternative embodiments, be performed by different elements. Functions illustrated to be performed by separate elements may instead be combined into a single element. Alternative boundaries can be defined so long as the specified functions and their relationships are appropriately performed. Thus, all such alternative boundaries are within the scope and spirit of the present invention.
[0020] Common reference numbers are used throughout the figures and detailed description to denote the same elements, and thus a reference number used in one figure may or may not be referenced in the detailed description specific to that figure if the element is described elsewhere.
[0021] Blockchain technology has the potential to dramatically increase enterprise business value by enabling near real-time distributed transactions across customer ecosystems and by enabling secure, tamper-resistant data sharing. The Hyperledger Fabric blockchain incorporates a modular architecture and horizontal / cross-industry technology support and support for enterprise needs.
[0022] Introduction According to one embodiment, Hyperledger Fabric is a platform for distributed ledger solutions underpinned by a modular architecture that provides a high degree of confidentiality, resilience, flexibility, and scalability. It is designed to support pluggable implementations of different components and address the complexity that exists across economic ecosystems.
[0023] According to one embodiment, Hyperledger Fabric provides a flexible and scalable architecture that distinguishes it from alternative blockchain solutions.
[0024] Blockchain - Distributed Ledger According to one embodiment, a blockchain network may include a distributed ledger that records all transactions that occur on the network.
[0025] According to one embodiment, a blockchain ledger is often described as decentralized because it is replicated across many network participants, each of whom cooperates in maintaining it. Decentralization and cooperation are attributes that reflect the way businesses exchange goods and services in the real world.
[0026] In addition to being decentralized and collaborative, information recorded on a blockchain is additive only, using cryptographic methods to ensure that transactions cannot be modified once they are added to the ledger. This immutability property makes it easy to determine the provenance of information, because participants can be sure that the information has not been changed after the fact. In this way, a blockchain can be thought of as a system of proof.
[0027] Blockchain - Smart Contracts According to one embodiment, to support consistent updates of information and to enable certain ledger functions (such as transacting and querying), the blockchain network uses smart contracts to provide controlled access to the ledger.
[0028] According to one embodiment, smart contracts are not only the primary mechanism for encapsulating information and keeping it simple across the network, they can also be written to allow participants to automatically execute certain aspects of transactions.
[0029] According to one embodiment, a smart contract can be written to specify, for example, the cost of shipping an item, which varies depending on when the item arrives. Once the item is received, the appropriate cost is automatically exchanged, on terms agreed upon by both parties and written to the ledger.
[0030] Blockchain - Consensus According to one embodiment, the process of keeping ledger transactions synchronized across the network to ensure that the ledger is only updated if the transaction is accepted by the appropriate participants, and that when the ledger makes updates, they are updated with the same transactions in the same order, may be referred to as consensus.
[0031] According to one embodiment, a blockchain can be thought of as a shared, replicated system of transactions that are updated via smart contracts and kept consistently synchronized through a collaborative process called consensus.
[0032] Advantages of Blockchain According to one embodiment, the currently available transaction network is a version of the network that has existed since business records were kept. Members of the business network transact with each other, but each member keeps a separate record of their own transactions. Also, transaction objects have their provenance established each time they are sold, ensuring that a business selling an item has an ownership history that verifies its own ownership of the item.
[0033] According to one embodiment, even though current business networks are modernized by computing systems, there is no unified system for managing the identities of network participants. Establishing provenance is tedious, as security transactions (which amount to trillions of dollars globally) take days to uncover. Contracts must be manually signed and executed. Additionally, every database in the system contains unique information and therefore represents a single point of failure.
[0034] According to one embodiment, blockchain provides an alternative to many of the inefficiencies presented by standard systems of transactions by providing a standard way to establish identities, conduct transactions, and store data on a network.
[0035] According to one embodiment, in a blockchain network, each participant has their own replicated copy of the ledger. In addition to the ledger information being shared, the process for updating the ledger is also shared. Unlike other systems where participants' private programs are used to update their private ledgers, blockchain systems have shared programs for updating the shared ledger.
[0036] According to one embodiment, with the ability to coordinate business networks through a shared ledger, blockchain networks can increase trust and visibility while reducing the time, cost, and risk associated with personal information and transactions.
[0037] Hyperledger Fabric According to one embodiment, Hyperledger Fabric, like other blockchain technologies, has a ledger and uses smart contracts, and is a system in which participants manage their own transactions.
[0038] According to one embodiment, Hyperledger Fabric differs from some other blockchain systems in that it is private and permissioned. Instead of the "proof of work" that some blockchain networks use to verify identity (anyone who meets those criteria can join the network), members of the Hyperledger Fabric network register through a membership service provider.
[0039] According to one embodiment, Hyperledger Fabric also offers several pluggable options: ledger data can be stored in multiple formats, consensus mechanisms can be switched in and out, and different Membership Service Providers (MSPs) are supported.
[0040] According to one embodiment, Hyperledger Fabric also provides the ability to create channels, allowing groups of participants to create separate ledgers of transactions. This allows options for networks where some participants may be competitors and do not want all participants to know about all of the transactions they make (e.g., special pricing only available to a select few). When two participants form a channel, only those participants have a copy of the ledger for that channel.
[0041] shared ledger According to one embodiment, Hyperledger Fabric has a ledger subsystem that includes two components: a world state and a transaction log. Each participant has a copy of the ledger for every Hyperledger Fabric network that it belongs to.
[0042] According to one embodiment, the world state component describes the state of the ledger at a given point in time. It is the ledger's database. The transaction log component records all transactions that resulted in the current value of the world state. It is the update history for the world state. The ledger is then a combination of the world state database and the transaction log history.
[0043] According to one embodiment, the shared ledger has a pluggable data store for the world state. By default, this is the LevelDB key-value store database. The transaction log does not need to be pluggable: it simply records the before and after values of the ledger database used by the blockchain network.
[0044] Smart Contracts According to one embodiment, Hyperledger Fabric smart contracts are written in chaincode and are invoked by applications external to the blockchain when they need to interact with the ledger. In many cases, chaincode only interacts with (e.g., queries) the world state, which is the database component of the ledger, and not with the transaction log.
[0045] consensus According to one embodiment, transactions are written to the ledger in the order that they occurred, even if they occurred between different sets of participants in the network. For this to occur, an order of transactions is established and methods may be put in place to reject bad transactions that have been mistakenly (or maliciously) inserted into the ledger.
[0046] According to one embodiment, Hyperledger Fabric allows network entities (e.g., network users, peers, starters) to choose a consensus mechanism that best represents the relationships that exist between participants. As with privacy, there are varying needs for those relationships, ranging from highly structured networks to networks that are more peer-to-peer.
[0047] Chaincode According to one embodiment, chaincode may include software that defines assets and transaction instructions for modifying assets. It is business logic. Chaincode implements rules for reading or modifying key-value pairs or other state database information. Chaincode functions run against the ledger's current state database and are initiated through transaction proposals. Chaincode execution results in a set of key-value writes (write set) that can be submitted to the network and applied to the ledger on all peers.
[0048] Ledger features According to one embodiment, the ledger is an ordered, tamper-resistant record of all state transactions in the fabric. State transactions are the result of chaincode invocations ("transactions") submitted by participating parties. Each transaction results in a set of asset key-value pairs that are committed to the ledger as a creation, update, or deletion.
[0049] According to one embodiment, the ledger consists of a blockchain for storing ordered, immutable records in blocks and a state database for maintaining the current fabric state. There may be one ledger per channel, with each channel containing a separate ledger of transactions visible to a particular group of participants. Each peer maintains a copy of the ledger for each channel in which they are a member.
[0050] Privacy Through Channels According to one embodiment, Hyperledger Fabric employs a per-channel immutable ledger and chaincode that can manipulate and modify the current state of an asset (i.e., update key-value pairs). The ledger exists within the scope of a channel and can be shared across the entire network (assuming all participants are operating on a common channel), or it can be privately owned to include only a specific set of participants.
[0051] According to one embodiment, in the latter scenario, such participants can create separate channels, thereby isolating / segregating their transactions and ledgers. To enable scenarios that want to bridge the gap between total transparency and privacy, chaincode may be installed only on peers that need access to the asset state to read and write (e.g., if chaincode is not installed on a peer, it will not be able to properly interface with the ledger). To further obfuscate data, values in the chaincode may be encrypted (partially or in whole) using a common cryptographic algorithm, such as AES (Advanced Encryption Standard), before being appended to the ledger. do.
[0052] Security & Membership Services According to one embodiment, Hyperledger Fabric provides a transaction network where all participants know their identities. A public key infrastructure is used to generate cryptographic certificates that are bound to organizations, network components, and end users or client applications. As a result, data access controls can be operated and managed on the broader network and at the channel level. This "permissioned" concept of Hyperledger Fabric, combined with the existence and capabilities of channels, helps address scenarios where privacy and confidentiality are paramount.
[0053] consensus According to one embodiment, in a distributed ledger, consensus can encompass more than simply agreeing on the order of transactions. This distinction is emphasized in Hyperledger Fabric through its fundamental role in the entire transaction flow, from proposal and approval to ordering, validation, and commitment. Consensus can be defined as the full verification of the correctness of a set of transactions that comprise a block.
[0054] According to one embodiment, consensus is achieved when the order and outcome of a block's transactions meet explicit policy criteria checks. These checks and balances occur during the transaction's lifecycle and include the use of approval policies to dictate which specific members must approve certain classes of transactions, and system chaincodes to ensure these policies are enforced and upheld. Prior to commitment, peers can employ these system chaincodes to verify that sufficient approvals exist and that they originate from the appropriate entities. Additionally, before a block containing a transaction is added to the ledger, a versioning check can occur in which the current state of the ledger is agreed upon or accepted. This final check provides protection against double-spending operations and other threats that can compromise data integrity, and allows functions to be performed on non-static variables.
[0055] According to one embodiment, in addition to the authorization, validity, and versioning checks that are performed, ongoing identity validation also occurs in the transaction flow. Access control lists are implemented on the network's layers (ordering services to channels), and payloads are iteratively signed, verified, and authenticated as transaction proposals pass through different architectural components. Consensus is not limited to an agreed-upon ordering of a batch of transactions; rather, it is a process achieved as a by-product of ongoing validation that occurs during the flow of a transaction from proposal to commitment.
[0056] Blockchain Cloud Services - Architecture According to one embodiment, systems such as cloud systems (e.g., Blockchain Cloud Services (BCS)) can utilize the above-described Hyperledger Fabric as a starting point. Such systems provide a highly advanced, differentiated, enterprise-grade distributed ledger cloud platform that enables the building of new blockchain-based applications and / or the extension of existing SaaS, PaaS, IaaS, and on-premise applications.
[0057] According to one embodiment, the system provides scalability, security, robustness, integration, The system supports mission-critical enterprise needs, such as speed and performance, removing barriers to adoption and supporting blockchain applications in production. By offering BCS as a Platform-as-a-Service (PaaS) cloud solution, the system enables users to deploy, configure, manage, and monitor blockchain, lowering the cost of deploying blockchain to their enterprises. The system also accelerates blockchain application development and integration with other platforms. The system enables SaaS cloud customers to enable their enterprise processes, such as procurement, payments, trade finance, accounting, HR, and CX, to securely share data and conduct decentralized transactions with third-party applications and external distributed ledger technologies using the blockchain cloud platform.
[0058] According to one embodiment, the system is a cloud service based on a PaaS manager (e.g., the Oracle PaaS Service Manager (PSM) platform). Generally, such a system is a managed cloud service that runs in a compute space (e.g., an external compute space). In an embodiment, the system utilizes features of the PSM platform, including Oracle Identity Cloud Services (IDCS), Oracle Load Balancer as a Service (LBaaS), Oracle Event Hub Cloud Services, and a container runtime service environment (e.g., Docker or Application Container Cloud Services) layered with Oracle Cloud Storage. Each customer blockchain can be provisioned and run as a tenant. The system supports multiple blockchains, each provisioned and run as a separate tenant in a multi-tenant environment.
[0059] According to one embodiment, the system thus enables applications or customer applications to implement a distributed ledger using smart contracts to the extent necessary or desirable for those applications. Clients and users of such a system may be inside or outside the cloud (blockchain trust), and some blockchain networks may include components outside the cloud environment (or may be constrained to a particular cloud).
[0060] According to one embodiment, such a system may be useful for a variety of application functions, particularly in multi-party transactions where issues of trust and identity must be resolved. Unlike other blockchain systems, the system services provided are not anonymous. In fact, identity and auditability are fundamental and integral elements. Therefore, BCS finds applications in, for example, capital markets, cross-border transactions, financial services, asset transactions, legal reconciliation applications, health care records, publishing, logistics, traceability, and anti-counterfeiting.
[0061] According to one embodiment, as described above, each party on the blockchain has access to the entire database and its complete history (unless the ledger is provisioned / privatized to one party). No single party controls the data or information. All parties can also verify their transaction partners' records directly, without an intermediary. Communication occurs directly between peers, instead of going through a central node. Each node stores and forwards information to all other nodes. Once a transaction is entered into the database and an account is updated, the records cannot be changed because they are linked to all transaction records that occurred before them (hence the term "chain"). If there is an error in a transaction, a new transaction must be used to reverse the error, In that case, both transactions are visible to the provisioned user. To add a new valid transaction, participants can agree on its validity through a consensus mechanism. Participants in a blockchain can prove where assets originated and how ownership of assets has changed over time. Digital signatures can be used to authenticate documents and can be deployed for access control [various levels of authorization] and programmability [executable business rules].
[0062] According to one embodiment, in many multi-party transactions, money changes hands when one party receives an asset or service. Typically, due to transaction times, one party must commit the goods or money before the other. In some environments, trust issues are resolved by using an intermediary that holds funds in escrow until the completion of the terms of the contract. This solves the trust issue between the original parties. However, such an approach adds another central party that must be trusted, increasing the complexity and potentially the cost of the transaction. The use of smart contracts as part of the provided system can eliminate the need for an intermediary, allowing parties to conduct trusted transactions on the blockchain without the intermediary.
[0063] According to one embodiment, advantages of the provided system, such as BCS, include that the information contained therein is decentralized. Access can be controlled and a degree of privacy can be maintained, while auditability is available. Furthermore, a blockchain ledger is inherently immutable and non-repudiable. The ledger consists of a list of blocks. Each transaction block contains a block ID, previous hash, data hash, timestamp, transaction ID list, action (1..n), chaincode ID, chaincode proposal, response (r / w set, event, success or failure), and endorser. Because each block contains the previous hash and its own hash, blocks are inherently ordered and immutable once known / distributed. (Note: The hash of the current block is the hash of the previous block and other data in the current block, thus linking the blocks in the chain.) Consensus can resolve differences. Compared to a centralized database or intermediary, no central authority needs to be given excessive power. The distributed nature of the ledger also adds to the fundamental immutability of blockchain recording technology in that the use of distributed copies and consensus makes modifications difficult (even if algorithmically possible). Thus, given the ordering of transactions, hacking the ledger is nearly impossible if someone has a copy of the most recent block in the chain.
[0064] According to some embodiments, as described below, the provided system can be based on the Oracle PaaS Service Manager (PSM) platform and is augmented with a management console that simplifies, facilitates, and automates provisioning, monitoring, and configuration of a Fabric-based blockchain. In addition, a REST proxy service with a single REST API is provided to simplify application interaction with the blockchain Fabric. Developers can build smart contracts, deploy them using the management console, and then have applications invoke the smart contracts on the blockchain asynchronously (which is the default) or synchronously (if an immediate response is desired). The REST proxy service and API provide both synchronous and asynchronous capabilities, depending on the needs of the platform.
[0065] According to one embodiment, the Fabric CA server manages the membership for the fabric. The Fabric CA server can provide authentication and authorization services. The Fabric CA server can include three parts: authentication for users, authentication for accessing the blockchain (a group of peers and orders), and a CA server that can deliver certificates to application clients, peers, and orders. The Fabric CA can utilize certificates to achieve authentication and authorization. Certificates include two types: enrollment certificates for authentication and transaction certificates for authorization. According to one embodiment, an identity service such as IDCS can also provide authentication and authorization.
[0066] Hyperledger Fabric As mentioned above, in one embodiment, the provided system may implement Hyperledger Fabric, which provides a distributed ledger platform for executing smart contracts. Fabric leverages container technology to host smart contracts, called “chaincode,” which contain the system's application logic. In an alternative embodiment, the blockchain cloud service implements an alternative distributed ledger platform, including, for example, the “Tendermint” ledger system, as described in U.S. Patent Application Serial No. 15 / 169,622, entitled “Accountability And Trust In Distributed Ledger Systems,” filed May 31, 2016 (U.S. Publication No. 2017 / 0236120), which is incorporated herein by reference.
[0067] According to one embodiment, Hyperledger Fabric's distributed ledger protocol is executed by peers. One drawback of previous blockchain technologies is that every peer is required to record every transaction. This creates significant I / O and processor overhead and does not conveniently scale to enterprise-grade systems. Hyperledger Fabric distinguishes between two types of peers: validating peers are nodes on the network that are responsible for performing consensus, validating transactions, and maintaining the ledger. Non-validating peers, on the other hand, are nodes that act as proxies connecting clients (that issue transactions) to validating peers. Non-validating peers do not execute transactions, although they may verify them. This separation of peer types / functions improves the scalability of the system.
[0068] According to one embodiment, Hyperledger features a permissioned blockchain with immediate finality that executes arbitrary smart contracts called chaincode. User-defined chaincode smart contracts are encapsulated within containers, and system chaincode runs in the same process as peers. Chaincode execution is separated from transaction ordering, limiting the required level of trust and validation across node types and reducing network overhead.
[0069] According to one embodiment, channels in Hyperledger Fabric enable multi-sided transactions with the high degree of privacy and confidentiality required by competitive businesses and regulated industries exchanging assets over a common network. An immutable shared ledger encodes the entire transaction history for each channel and includes query capabilities for efficient auditing and dispute resolution. A ledger is provided for the scope of a channel, and it can be shared across the entire network (assuming all participants are operating on a single common channel), or it can be privately owned to include only a set of participants.
[0070] According to one embodiment, Hyperledger Fabric provides a certificate authority (CA) for TLS certificates, registration certificates, and transaction certificates. Security is achieved through support for public key infrastructure. , are used to generate cryptographic certificates that are bound to organizations, network components, and end users or client applications. As a result, data access controls can be operated and managed on the broader network and at the channel level. This "permissioned" nature of Hyperledger Fabric, combined with the existence and capabilities of channels, meets the need for privacy and confidentiality in multi-party enterprise systems.
[0071] According to one embodiment, Hyperledger Fabric provides the ability to modify assets using chaincode transactions. As described above, chaincode is software that defines assets and transaction instructions for modifying the assets.
[0072] According to one embodiment, an overall consensus mechanism plays a fundamental role in the transaction flow in the Hyperledger fabric, from proposal and approval to ordering, validation, and commitment. Consensus, as described above, is the verification of the validity of a set of transactions that comprise a block. Consensus is ultimately achieved when the order and outcome of a block's transactions meet explicit policy criteria checks.
[0073] FIG. 1A illustrates a transaction flow in Fabric, a system for providing blockchain services. More specifically, this diagram illustrates a Blockchain Cloud Services (BCS) system according to one embodiment. At 1, a client 160 accesses a Fabric Certificate Authority 170, 172, or 174 for registration using a Fabric SDK 162. At 1.1, the Fabric CA returns a registration certificate to the client 160. At 2, the client 160 accesses a peer container 180 using the Fabric SDK 162 and requests approval from an endorser 182. At 2.1, the endorser 182 returns a signed RW set (read / write set). At 3, the Fabric SDK 162 of the client 160 submits the approved TX (transaction), including the RW set and the endorser's signature, to the ordering service of the ordering container 190. At 4, the orderer 192 delivers the TX batch to the committer 184 in the peer container 180. An orderer is a defined collection of nodes that orders transactions into blocks. The ordering service exists independently of peer processes and orders transactions on a first-come, first-served basis for all channels on the network. In 5 and 5.1, a committer 184 applies changes to the ledger 186 and world state 188. The fabric certification authority 170 can be used to verify the validity of signatures and authorizations for the peer container 180, smart contract containers 166 and 168 (smart contracts), and orderer 192. Additionally, smart contracts 168 can communicate with endorsers 182.
[0074] In one embodiment, the system utilizes a Kafka cluster as the ordering service. Kafka is a distributed data warehouse that supports publish and subscribe semantics. A Kafka cluster runs on multiple servers and distributes the data. Kafka stores streams in categories called topics. Each record consists of a key value and a timestamp. For this reason, Kafka uses Ordering Service Nodes (OSN-n) and a Kafka cluster. A service client can be connected to multiple OSNs. OSNs do not communicate directly with each other. These Ordering Service Nodes (OSNs) (1) perform client authentication, (2) allow clients to write to or read from chain1 using a simple interface, and (3) they also perform transaction filtering and validation for configuration transactions that reconfigure existing chains or create new chains. Messages (records) in Kafka are organized into topic partitions. A Kafka cluster can have multiple topics, and each topic is written to a separate A chain can have multiple partitions. Each partition is an ordered, immutable array of records that is constantly appended to. Once OSNs perform client authentication and transaction filtering, they can relay incoming client transactions belonging to a chain to the corresponding partition of that chain. They can then consume that partition to again obtain an ordered list of transactions that is common across all ordering service nodes.
[0075] According to one embodiment, each peer has the ability to be an endorser and a committer. There is a configuration item (e.g., CORE_PEER_ENDORSER_ENABLED) that can enable a peer to be an endorser. When a peer joins a channel, this peer becomes a committer for this channel. When a chaincode is installed on a peer, this peer becomes a candidate endorser for this chaincode. When a client proposes a transaction, it is the client's choice to select which peer (from the candidate endorsers) to be the endorser.
[0076] According to one embodiment, the ordering mechanism by which the orderer delivers blocks to peers is as follows: First, a peer (e.g., a leader peer) delivers a request for a new block from the orderer by sending its version (last block number). Next, the orderer checks the peer's version, and if a) it is greater than the orderer's, it returns an error to the peer, indicating that the ledger in the order is lost and cannot be restored from EventHub (in this scenario, the orderer cannot continue working properly). b) If the peer's version is smaller than the orderer's, the orderer retrieves the block from its local ledger, either in RAM or a local file, and sends it back to the peer. Or, c) if they have the same version, the orderer blocks until a new block is available. When the new block data, disconnected from EventHub, is ready, the orderer will put it in its local block file or RAM. Then, a delivery thread reads this block from the ledger and sends it back to the peer. The peer obtains this block, commits it to its local ledger, and can then broadcast its latest version to other peers.
[0077] BCS System Architecture FIG. 1B illustrates transaction flow in the fabric of a system that provides blockchain services. More specifically, this diagram illustrates a Blockchain Cloud Services (BCS) system according to one embodiment. As illustrated, blockchain cloud services components are provisioned in a compute space 120 (e.g., an external compute space) that resides, for example, on the Oracle PaaS Service Manager (PSM) platform. Access to the system is mediated by a PSM API 122 and a blockchain REST API 124. The external compute 120 leverages Load Balancing as a Service (LBaaS) 126 to distribute incoming transactions across appropriate available resources.
[0078] According to one embodiment, the BCS is an application container layering service built using the PSM platform on a container runtime service environment (such as Docker or Application Container Cloud Services) 128. Each BCS entity runs on a separate container. Each BCS entity has a one-to-one correspondence with a container runtime service. The Blockchain Cloud Service implements the Hyperledger Fabric features described above. In addition to the components that build the basic Fabric network, several components have been developed to leverage Hyperledger Fabric for the Blockchain Cloud Service. This These components require separate deployment behaviors and binaries to deploy them. A cloud stack manager can be used to empower users to automate the provisioning of all services defined by a blueprint as a single unit called a stack.
[0079] According to one embodiment, BCS provides an implementation of Hyperledger Fabric, an implementation of a distributed ledger platform for executing smart contracts. BCS leverages container technology to host smart contracts, called "chaincode," which contain the system's application logic.
[0080] According to one embodiment, Fabric's distributed ledger protocol is executed by peers. Fabric distinguishes between two types of peers: validating peers are nodes on the network that are responsible for performing consensus, validating transactions, and maintaining the ledger. Non-validating peers, on the other hand, are nodes that act as proxies connecting clients (which issue transactions) to validating peers. Non-validating peers do not execute transactions, although they may verify them. Some key features of the Fabric release include a permissioned blockchain with immediate finality that executes arbitrary smart contracts called chaincodes. User-defined chaincode smart contracts are encapsulated in containers, and system chaincodes run in the same process as peers. Fabric achieves its consensus protocol and security through support for certificate authorities (CAs) for TLS certificates, registration certificates, and transaction certificates.
[0081] According to one embodiment, BCS entities run in hierarchical container instances with container runtime services 128. Containers are created and / or started by provisioning PSM operations. Fabric CA container 130 is a container where the BCS Fabric CA (Certificate Authority) component is provided. BCS Peer (container) 132 is a container where BCS peer network entities run that maintain the ledger for read / write operations to the ledger component and execute chaincode containers. BCS Ordering container 134 is a container where the BCS Orderer runs, providing the service of ordering transactions into the blockchain for all channels. BCS Chaincode Execution container 139 is a container created and started by a peer entity. In this container, a chaincode execution unit communicates with the parent peer entity to encode asset and transaction instructions to modify assets in the blockchain.
[0082] According to one embodiment, the BCS chaincode builder container 140 is a container created and launched by a peer entity. In this container, the chaincode build environment is installed and deployed, and the chaincode execution unit is built therein. The client-side Fabric SDK 106 provides functionality to access the BCS. The blockchain cloud service also leverages an event hub cloud service 150, a cloud storage service 152, and an identity service 154. The Oracle Storage Cloud Service is used as the storage service for the BCS.
[0083] According to one embodiment, Docker / Weave 141 is a container service. Containers provide a way to package software in an isolated, executable format on a shared operating system. Unlike VMs, containers do not bundle an entire operating system, but instead require the software to use the libraries and configuration necessary to run. This creates an efficient, lightweight, self-contained system. This ensures that the software always runs the same way regardless of where it is deployed.
[0084] According to one embodiment, each BCS instance is composed of different types of nodes: A BCS instance can have a few (e.g., zero or more) to multiple peer nodes. A BCS instance can have a few (e.g., zero) to multiple orderer nodes. A BCS instance has one to multiple Fabric CA nodes, one per VM. Regarding BCS gateways, a BCS instance can have a few (e.g., zero) to multiple BCS gateways. The BCS console is also a component of a BCS instance. A BCS instance has only one BCS console.
[0085] According to one embodiment, the BCS Management Server (Console) 136 is a component of BCS that provides rich monitoring, management, and view functionality for BCS stack instances, as described in more detail below. The BCS Gateway (REST Proxy) 138 is a new component of BCS that provides a REST API interface to customers / clients, which are used to access the fabric to conduct transactions, as described in more detail below.
[0086] According to one embodiment, on the public access client side 100, a PSM console UI 102 enables management of the Platform Services Manager. A BCS console UI 104 enables control of the BCS management server. A variety of different client types can access the BCS service, including a Fabric SDK client 106, a BCS REST client 108, and a Fabric membership client 110.
[0087] According to one embodiment, blueprints can be defined for each container type listed above as an individual service type. Oracle Cloud Stack Manager uses these blueprints to automate the provisioning of all individual service types into a single stack unit. The advantage of defining a service type for each BCS entity is that it is easy to upgrade and maintain different entities while they are running. The container runtime service layering service supports four types of operations: CREATE_SERVICE, DELETE_SERVICE, SCALE_SERVICE, and start / stop / restart. This These actions can be applied on a per-service basis.
[0088] According to one embodiment, in Hyperledger Fabric, the ordering service component uses Apache Kafka to provide ordering services and support for multiple chains in a crash-tolerant manner. Thus, in BCS Cloud Services, the ordering service component delivers the power of Kafka as an OEHCS (Managed Streaming Data Platform) and is a part of Oracle's Cloud. The team will use Oracle Event Hub Cloud Services, which can be integrated with the rest of the team.
[0089] Figure 1C illustrates a BCS system according to one embodiment. More specifically, this diagram illustrates the BCS runtime.
[0090] According to one embodiment, clients such as gateway-based application 103 and / or fabric-based application 105 communicate over a network such as the Internet 107 and via a load balancer, which may include CloudGate (described below). The container runtime service instance 128 can communicate with the container through a front end such as a balancer LBaaS 126. Incoming calls can be made via REST communication ( The diagram may include incoming REST communications (shown as darker dashed lines) or, in some circumstances, incoming gRPC communications (shown as lighter dashed lines in the diagram). Incoming REST communications may be directed to gateway 138 (which may include a REST API / REST proxy), console 136 (as described above), or agent fabric CA 130. Here, the REST communications converted to internal calls (gRPC) can interface with an instance of blockchain fabric / Hyperledger (including agent / peer 132, agent / orderer 134, chaincode 142, and chaincode builder 140). Meanwhile, incoming gRPC communications may be sent directly to agent / peer 132 and agent / orderer 134, for example, to interface with blockchain / Hyperledger.
[0091] According to one embodiment, once a transaction occurs within a container runtime service instance, the container runtime service instance can persist a ledger in cloud storage, for example, via REST communications, or can communicate with an event hub, also via REST communications.
[0092] According to one embodiment, although only one container runtime service instance is shown in the figure, one skilled in the art will readily understand that there may be one or more container runtime service instances with which a client (such as a gateway-based application 103 and / or a fabric-based application 105) can communicate via the described BCS runtime.
[0093] 1D illustrates a BCS system according to one embodiment. More specifically, this diagram illustrates the component concentrations within the BCS system, i.e., the ratio of components to each BCS instance.
[0094] According to one embodiment, for each BCS instance 100a, orderers 101a may be provided in a 1:N ratio, fabric CA memberships 102a may be provided in a 1:N ratio, BCS REST proxies 103a may be provided in a 1:N ratio, BCS consoles 104a may be provided in a 1:1 ratio, and peer containers 105a may exist in a 1:N ratio.
[0095] According to one embodiment, each peer container may include endorsers who can simulate transactions and committers who can also apply changes to the ledger provided by the peer container.
[0096] According to one embodiment, chaincode 109a can be provided in a 1:N ratio to peer containers. Additionally, storage 106a can be provided in an N:1 ratio to peer containers and orderers. Event hub 107a can be provided in an N:1 ratio to peer containers and orderers. IDCS 108a can be provided in an N:1 ratio to Fabric CA membership.
[0097] FIG. 1E is a flowchart of a method for providing an interface for a blockchain cloud service, according to one embodiment.
[0098] According to one embodiment, in step 175, the method may include, on a computer including at least one processor, providing at least one instance of a container runtime service and a distributed ledger component in the at least one instance of the container runtime service, the distributed ledger being provisioned as a blockchain cloud service, the blockchain cloud service providing a peer container and an order book. The container includes a chaining container and a chaincode container.
[0099] According to one embodiment, in step 176, the method may maintain a blockchain ledger by a peer container.
[0100] According to one embodiment, in step 177, the method may order transactions in the blockchain ledger by an ordering container.
[0101] According to one embodiment, in step 178, the method may encode the asset in the ledger by a chaincode execution unit of the chaincode container.
[0102] According to one embodiment, in step 179, the method may configure at least one instance of the container runtime service to receive an incoming call from a client application, the incoming call requesting an entry in the blockchain ledger.
[0103] Blockchain Cloud Service (BCS) Gateway According to one embodiment, a BCS Gateway (BCSGW) includes a network node that uses the Fabric SDK to communicate with the Fabric network. The BCS Gateway provides customers with an HTTPS RESTful API on the client side that allows clients / client applications to interact with the BCS Fabric elements.
[0104] Figure 2 illustrates a gateway for a blockchain cloud services system, according to one embodiment. As shown in Figure 2, an end user 200 interacts with an application adapter 202 for authentication and authorization using HTTPS. The application adapter 202 provides a gateway to an LBaaS, such as CloudGate 212 (i.e., LBaaS). The public cloud 210 is accessed using HTTPS. Load Balancing as a Service (LBaaS) is provided for incoming transactions. CloudGate 212 forwards the transaction to the BCS Gateway 22 using HTTPS. 2. The BCS Gateway provides an interface to the BCS Fabric 220 where communication utilizes the gRPC remote procedure call protocol.
[0105] According to one embodiment, CloudGate 212 supports, for example, OAuth2 and OpenID Connect standards. IDCS is a reverse proxy "access enforcement module" or "policy enforcement point" that uses CloudGate to secure web browser and REST API resources. IDCS uses CloudGate internally to secure its own management UI and REST APIs. (called the "IDCS web tier.") For other applications, Cloud Gate:OTD is deployed as an additional instance in a semi-supported / interim configuration known as non-IDCS or standalone.
[0106] According to one embodiment, OAuth / OpenID based authentication (for UI clients) Supports user browser flow, which is triggered when the HTTP request contains a "User-Agent" header, i.e., the request is from a UI such as a browser or mobile app. CloudGate also provides credentials (username / password) prompts the user for their password, verifies their credentials, and then The OAuth session cookie is then passed to the browser for subsequent HTTP requests. OAuth / OpenID based authentication can also be used by (programmatic) Supports the resource server flow (for clients). This flow is triggered when an HTTP request contains an authentication "bearer" token header. CloudGate uses to check the validity of the token.
[0107] According to one embodiment, for HTTP Basic Authentication, credentials (username / password) must be included in the HTTP Authorization "Basic" header with each HTTP request. Cloud Gate validates the credentials with each HTTP request. This method applies to both UI and programmatic clients.
[0108] According to one embodiment, multi-token flow is a self-adaptive method for covering an HTTP request. If the HTTP request contains an Authorization "Basic" header, CloudGate Performs TP basic behavior. If the HTTP request includes an authorization "Bearer" header, Cloud Gate behaves the same as the resource server flow.
[0109] In one embodiment, the BCS console browser client utilizes the user browser flow. In an embodiment, for the BCS console and gateway programmatic clients, the system can use the CloudGate multi-token authentication method. Programmatic clients can access BCS REST via HTTP Basic Authentication. You can call the API.
[0110] According to one embodiment, the BCS Gateway 222 communicates with peers 224. Peers 224 are network entities that maintain the ledger and run chaincode containers to perform read / write operations on the ledger. Peers are owned and maintained by members. The BCS Gateway 222 and peers 224 communicate with an Orderer 226. The Orderer provides an ordering service. An Orderer is a defined collection of nodes that orders transactions into blocks. The ordering service exists independently of the peer process and orders transactions on a first-come, first-served basis for all channels on the network. The Peers 224 and Orderer 226 communicate with a Fabric Certification Authority 228. The BCS Gateway 222 also provides access to a BCS Management Server / Console 230.
[0111] According to one embodiment, BCS is deployed on a cloud system such as Oracle Cloud. The gateway can run in a container runtime service container. The gateway is stateless. The gateway can be updated by stopping the old gateway and starting a new one. The BCS gateway can enable customer queries or invoke Fabric chaincode through a RESTful protocol. The BCS gateway allows clients to access the Fabric network in Oracle Cloud through HTTPS / RESTful services. The BCS gateway is a network node that uses the Fabric SDK to communicate with the Fabric network. Communication within Fabric uses gRPC as the communication protocol. On the client side, the BCS gateway provides an HTTPS / RESTful API to customers. The REST API allows clients to invoke functions within Fabric using the Fabric SDK.
[0112] According to one embodiment, gateways may be provided in a one-to-one relationship with fabric users. Every gateway user belongs to one organization, and every gateway user is mapped to one fabric user in one gateway. One gateway constitutes one and only one fabric user.
[0113] According to one embodiment, IDCS issues gateway certificates and gateway user (“app adapter”) certificates, which are signed by the Organizational CA. Gateways and gateway users may be deployed by an organizational CA so that they may validate each other using HTTPS.
[0114] According to one embodiment, each end user accesses the BCSGW through an "application adapter." There are three stages of authentication: The end user 200 can be authenticated by the application adapter 202. The application adapter 202 can be authenticated by the BCS gateway 222 using a client certificate. The BCS gateway can be authenticated by peers 224 and orderers 226 in the fabric network 220.
[0115] According to one embodiment, one container runs one Tomcat server, deploys one BCS gateway, and is mapped to one Fabric user. Multiple app adapters may connect to one gateway.
[0116] According to one embodiment, different gateways can be associated with different Fabric users. App adapter end users connecting to one gateway can be mapped to one Fabric user.
[0117] According to one embodiment, BCSGW runs in the Oracle Cloud and the configuration is set through the BCS console using a JSON file. The Admin user can manage peers, teams, and The Admin user can issue a channel and part of the chaincode to the gateway. , start the gateway through the console. The gateway does not refresh its configuration after booting. Admin users can set endorsers for chaincodes. Yes, the policy is opaque to the end user and the gateway does not check the chaincode policy.
[0118] According to one embodiment, BCSGW is launched by the BCS console. The BCS console creates a BCSGW configuration file and uses the BCSGW package to start a new gateway. At startup, a startup script checks the BCSGW configuration file, modifies the configuration file for Tomcat (e.g., the Tomcat configuration file), and then starts Tomcat. Tomcat launches a thread for BCSGW, which reads the configuration file for each channel. It then launches a channel object and can create connections with orderers, peers, and event hubs. Different channels will have different connections with orderers / peers / event hubs. The event hub here is the second port of the peer. The gateway connects to this port to obtain the transaction results. The Tomcat servlet container can listen and wait for client requests. For chaincode querying, BCSGW sends requests to all peers on the channel and uses only the first result. For chaincode invocation, BCSGW sends requests to all endorsers on the channel. If one of them returns success, BCSGW sends the transaction to all orderers on the channel.
[0119] According to one embodiment, an asynchronous API is supported. A peer can open two ports, one port for event exchange. A gateway can connect to the event port of a peer. A gateway only needs to connect to one event port per channel. The normal client API is synchronous. Transactions can take several seconds and the client must wait for a response. Sending asynchronous events to clients is not in the V1 plan. In addition to the synchronous transaction API, the gateway provides an asynchronous transaction API, "asyncinvoke".
[0120] In one embodiment, the asynchronous API can work like this: After checking the parameters of the client request, the gateway returns a transaction ID to the client. The client will know that a transaction has been started but not finished. The gateway will start a background thread to continue processing the transaction. The client can keep track of the unfinished transactions. The gateway can provide a "transaction" API for the client to query the transaction status using the transaction ID.
[0121] According to one embodiment, client login can be supported. The BCSGW can support the HTTPS protocol and cannot allow insecure HTTP access. The BCSGW uses certificates to trust the app adapter or SALT. The app adapter can authenticate the end user. Tomcat must be configured to use HTTPS client certificate authentication. The keystore file contains the BCSGWcert and CAcert to verify the validity of the client provided by the BCS console. The BCS Gateway uses the BCS for client access. Provides a REST interface.
[0122] Persistence - Storage Cloud According to one embodiment, the Hyperledger Fabric is a network of ledgers stored in a local file system and LevelDB, which is also stored in the local file system. The ledger data is stored in the container runtime service container along with other runtime data such as the block index, world state, history, and ledger provider. In the container runtime service, the container file system is ephemeral; that is, if a container is stopped due to some hardware failure and a new container is restarted on a new VM, the file system contents may be lost. Consider the situation where all containers are lost, in that case there is no way to restore the ledger. Therefore, the ledger data must be stored outside of the container runtime service container. For this reason, a persistence solution is provisioned in the form of an object storage service used by the Hyperledger Fabric components mentioned above.
[0123] According to one embodiment, therefore, in BCS, the persistence solution utilizes a storage cloud service, for example, Oracle Storage Cloud Service. The ledger is backed up to an object store. The ledger blocks writes to the container file system as well as backups to object storage. The index and world state are recorded using the container file system, but may be restored from the Storage Cloud Service if the container is restarted. Oracle Storage Cloud is an Infrastructure as a Service (IaaS) product, which provides enterprise global storage for file and unstructured data. It provides a high-end, large-scale object storage solution.
[0124] Figure 3 illustrates persistence for a blockchain cloud service system, according to one embodiment. As shown in Figure 3, a container runtime service instance 300 includes multiple containers. The containers include, for example, ordering containers 302 and 304 having ledgers / blockchains 312 and 314. The ledgers / blockchains 312 and 314 are backed up to object storage 320 through a REST interface. The object storage 320 may be, for example, a cloud storage service.
[0125] According to one embodiment, object storage is used to persist the ledger for each orderer. The current mechanism for an orderer to deliver blocks to peers is as follows: First, a peer sends its version (last block number). The orderer delivers requests for new blocks from the orderer by using the Orderer's dispatch thread. The orderer then checks the peer's version, and if a) it is greater than the orderer's, it returns an error to the peer, indicating that the ledger in the order is lost and cannot be restored from EventHub. In this scenario, the orderer cannot continue working properly. b) If the peer's version is smaller than the orderer's, the orderer retrieves the block from its local ledger, either in RAM or a local file, and sends it back to the peer. c) If they have the same version, the orderer blocks until a new block is available. When the new block data, disconnected from EventHub, is ready, the orderer will put it in its local block file or RAM. Then, a dispatch thread reads this block from the ledger and sends it back to the peer. Finally, the peer obtains this block and commits it to its local ledger. The latest version of the ledger can then be broadcast to other peers.
[0126] According to one embodiment, either the Orderer or EventHub can persist an entire block according to the process described above. As mentioned above, EventHub has time-limited retention. If EventHub can do that, the Orderer can set the ledger type to RAM or file, and once the Orderer is restarted and the ledger is lost, it can replay records from EventHub, chop the batch messages into blocks, and then reconstruct the ledger. If EventHub only supports limited retention, once the Orderer is restarted and the ledger is lost, it cannot accurately reconstruct the ledger because the first record in EventHub is not the true record in the ledger. In this scenario, the Orderer cannot start the old channel because the first block with the channel information is lost and the version number (last block number) is incorrect.
[0127] According to one embodiment, each orderer then persists each block to the oracle storage, while also storing all channel IDs in objects in the storage. On the peers, only the genesis block is persisted because it contains the channel information. For other block data, the peers can retrieve it from the orderer once it is lost.
[0128] According to one embodiment, the container runtime service instance 300 may also include peer containers 306, 308, which contain ledgers 316, 318 and indexes 326, 328. There are five types of runtime data generated by peers: transaction logs (block files), block file indexes (LevelDB), ledger providers (LevelDB), state databases (LevelDB or couchdb), and history (LevelDB). All transaction data is stored in a transaction log as linked blocks in a local file, which must be persisted to the Oracle Storage Cloud service. The Ledger Provider DB stores all ledger IDs and restoration statuses in LevelDB. The ledger ID is a unique identifier used to identify the channel to which a peer belongs. The id of the object must be persisted to the Oracle Storage Cloud service. For others, the peer will automatically restore it at runtime so that it can store them in the local file system.
[0129] According to one embodiment, the Oracle Storage Cloud service provides a REST API for uploading / downloading files to / from objects. When a new block is generated, it will first be written to a local block file as described above, with the difference being one block per file. This block file will then be uploaded to Oracle Storage as an object. If that fails, the changes in the local file are rolled back and an error is returned. will be returned to the caller.
[0130] According to one embodiment, for the block file index, when the orderer updates the latest checkpoint, it can first persist the information to Oracle storage, and then update the local LevelDB. If the operation fails, an error is returned to the caller. This information will be used for recovery of the block file index. In Oracle storage, each peer and orderer has a unique container name which is a combination of msp id and node id. The object name is the name of the block file prefixed with the channel name. For more details, see Naming Conventions in Oracle Storage.
[0131] According to one embodiment, an option may be provided to store the Ledger Provider DB in Oracle storage. For the Ledger Provider DB, the entire LevelDB is stored once it is updated. Once created, it can be replicated to the Oracle Storage Cloud service. This file is very small and updates are infrequent, so the replication overhead is negligible. When a container is restarted, it can download it from the Oracle Storage Cloud service if it exists. When an orderer is restarted from a new container, it will first download the channel ID from the storage object, and then get the latest checkpoint from storage by channel ID. It will then start restoring the block index from the first block to the last block. During this period, block files will be downloaded one by one. After that, the orderer will start restoring the state DB and history DB. When a peer is restarted from a new container, it will first download the ledger provider DB. Then, it can get all ledger IDs. It will then get the relevant genesis block from storage by ledger ID. The peer will start configuring the genesis block and send a query to the orderer to get other block data. After the peer gets these blocks, it will start restoring the block index, state DB, and history DB.
[0132] According to one embodiment, the local block file acts as a read cache. Queries will first read data from local. If it is not present, it will be downloaded from object storage. In addition to the ledger, the chaincode source code needs to be persisted to oracle storage. In the current Fabric, after the chaincode is installed, the encoded source code will be stored on the peer. The peer will check for the chaincode container on each invocation or instantiation. If the container is not present, the peer will rebuild it from the source code. Therefore, it can upload it to oracle storage on each chaincode installation and download it when the peer is restarted from a disk failure.
[0133] BCS: SDK-based configuration file behavior and post-provisioning deployment According to one embodiment, the configuration file and deployment functions deploy, generate, initiate, update, and obtain configuration for applications, including peers, orderers, CA servers, and chaincodes, when deploying or updating an application. These functions are implemented in the BCS console (in Node.js) and in the fabric. These functions will get / update configuration as requested from the UI and call SDK APIs to activate configuration changes when necessary. Components as part of the BCS console backend interact with the BCS console UI, IDCS backend SDK, and all BCS applications to provide the SDK for UI operations and execute requests. The component also helps to provision BCS applications. The BCS Provision component will deploy BCS applications into Docker containers on VMs created using PSM. This feature will implement SDK APIs for the BCS Console UI. And the BCS Provision component will get or update BCS application configuration and deployment in the post-provisioning stage. In the post-provisioning stage, the provisioning system will communicate with CA server, order server, and other applications under Docker / Swarm. It will deploy BCS applications such as admin, peer, etc. When the VM starts, it will call the startup script to do post-provisioning work and initial VM work.
[0134] According to one embodiment, configuration files are provided for Fabric components, including peers, orderers, Fabric CAs, and BCS gateways. BCS application packages, configurations, and chaincodes are stored in the customer's storage cloud service.
[0135] According to one embodiment, the provisioning system should complete all resource allocations, including VMs, networks, and storage.
[0136] According to one embodiment, the provisioning system should store all resource allocation information in the storage service. This information includes VM numbers and their network addresses / account credentials, BCS application numbers and their types in each VM, public IPs and internal IPs. There should also be enough internal IP addresses (accessible between VMs) for containers.
[0137] According to one embodiment, once the BCS provision component has completed its provisioning work, the VM startup script starts, which then invokes swarm to start the container runtime service. It will deploy the service and inside the container the container startup.sh script will be launched and perform the startup actions.
[0138] According to one embodiment, when the BCS console starts up, it will get the configuration from the storage service, save user action input from the UI to the storage service, and then send a restart command to the swarm.
[0139] According to one embodiment, the required security credentials can be stored in the IDCS, or alternatively, the security credentials can be retrieved from the IDCS.
[0140] According to one embodiment, the BCS console backend uses swarm to manage BCS applications. It can communicate with applications.
[0141] According to one embodiment, when the BCS Container Runtime Service starts, the BCS application can gather configuration details to determine its application type (peer or chaincode container or other) and then load the required configuration.
[0142] According to one embodiment, this component updates the configuration and provides the BCS application startup shellcode. The operation of BCS to get / update the configuration file can be divided into several parts. First, the BCS console will get the configuration from storage when it starts up, and if an update is required, it will save the configuration from the BCS console to storage (shell and Node.js). When the BCS container runtime service starts up, it will The startup script (in the na) starts first, then gets the configuration for that application type and gets the app cert from IDCS (shell). When the BCS console UI restarts a BCS application, it sends a message to Docker / Swarm to restart that application in a container.
[0143] According to one embodiment, the BCS Console is stateless and, when launched, can collect all BCS instance configurations and connect to BCS applications to monitor them. The configurations will be retrieved from the storage service via backend APIs. If any configuration changes, the BCS Console will call the backend API to save the configuration to the storage service and restart the associated application. If a customer changes a configuration item through the BCS Console UI, the UI will encode the configuration into key / value data, and the backend code will convert it to a file and save it to the storage service. The BCS Console can monitor, start, and stop BCS applications. The start and stop commands use the Docker / Swarm API to achieve this functionality.
[0144] Fabric Network Deployment According to one embodiment, a Fabric network includes the following entities: peers, clients, an ordering service, and a set of protocols that facilitate communication between these entities. An organization is a logical entity or group that constitutes the stakeholders of the Fabric network. A Fabric network has multiple participating organizations. Members are legally distinct entities that own a unique root certificate for the network. Network components such as peer nodes and application clients will be linked to members. Each organization may have one or more members. An organization may result in both orderers and peers, or only orderers, or only peers.
[0145] According to one embodiment, the first step in deploying a Fabric network is to define the participants. This step is performed out-of-band of the Fabric network. All participating organizations in the Fabric network negotiate and finalize the configuration of the network, including, for example, which organizations will provide orderer nodes and which organizations will provide peer nodes. Every organization that provides orderer nodes issues a root certificate for its orderer server. Every organization that provides peer nodes issues a root certificate for its peer server. Every organization that has clients issues a root certificate for its clients. Clients can be separated from peers to different members in an organization.
[0146] According to one embodiment, as an example, four banks (bank1, bank2, bank3, and bank4) decide to deploy a blockchain network using an ordering service that includes orderer nodes owned by bank1 and bank2, and bank1 is the only one to provide orderers in this network. Banks are organizations in the Fabric network. bank1 has one member: orderer (root_cert_1). bank2 has three members: client (root_cert_21), peer (root_cert22), and orderer (root_cert23). bank3 has two members: client (root_cert31) and peer (root_cert32). bank4 has It has two members: client (root_cert41) and peer (root_cert42).
[0147] According to one embodiment, after defining the participants, certificates are generated for the orderers and peers. Each orderer or peer needs a pair (private key, signing certificate) to identify itself. Each member authenticates its own file using its root certificate. You can configure and start the Brick CA server and use the CLI or SDK to request the CA server to generate (private keys, signing certificates) for each orderer / peer server of this member. BCS provides a Fabric CA server that can provide certificates. However, the Fabric CA server is not the only approach to generate certificates. Users can use other CA systems to do the same thing. Therefore, the Fabric CA server is not a required component in a Fabric network.
[0148] According to one embodiment, after generating certificates for the orderer and peers, the Fabric network is bootstrapped by creating a system channel. There is exactly one system channel for the ordering service (and therefore for a Fabric network), and it is the first channel to be created (or more precisely, bootstrapped). The system channel defines the configuration of the Fabric network: ●One ordering service ○ One or more ordering organizations. Each org MSP ID Cert Ordering service attributes (e.g., type - Solo or Kafka, Orderer address, batch size / timeout) Policies (such as who can create channels) One or more consortia, each of which includes: One or more peer organizations. Any peer organization that wishes to participate in this Fabric network must be defined in one of the consortia here. MSP ID Cert ·Anchor Pier.
[0149] According to one embodiment, after a Fabric network system channel is bootstrapped, a genesis block is created for that system channel (the first block in the chain). The orderer service administrator generates the genesis block for that system channel. The genesis block can be generated by the tool configtxgen (genesismethod=file) or during orderer startup (genesismethod=provisional). Generating a Genesis Block Using the configtxgen Tool In this case, the configuration file configtx.yaml can be configured as input. This file contains the following Contains information: Root certificates of all orderer organizations in the Fabric network; Root certificates of all peer organizations; Ordering Service attributes: orderertype, address policy; channel reader: authentication and validation of channel delivery requests; channel writer: authentication and validation of channel broadcast requests; chain creator: evaluation of chain creation requests; admin: channel reconfiguration requests Authentication and validation of.
[0150] According to one embodiment, the orderer service administrator starts the orderer server with a configuration file and a genesis block. It uses the genesis block to create a system channel. A configuration file orderer.yaml is required to start the orderer server: listen address / port, ledgertype, etc.; LocalMSP (private key, signing certificate). Each organization offering ordering services starts its orderer server (the genesis block should not be specified).
[0151] According to one embodiment, each organization that provides peer nodes must have a LocalMSP to identify peers. (private key, signing certificate); and peer attributes: prepare a configuration file (default location / etc / hyperledger / fabric / core.yaml) for each peer to identify listen address / port, bootstrap peer, gossip attributes, etc. Then, the peer server Start the program.
[0152] According to one embodiment, after the orderer and peers are started, a channel administrator (with privileges to create channels) uses the Fabric CLI or SDK to create a channel on the orderer with inputs of a consortium org (which must have been defined in the system channel) and one or more peer orgs in that consortium. Each participating organization uses the Fabric CLI or SDK to subscribe some of its peers to the newly created channel.
[0153] Example: Deploying a Fabric network on BCS FIG. 4 illustrates an exemplary deployment of a fabric on a BCS.
[0154] More particularly, the diagram and description describe steps for deploying a Fabric network on a BCS, according to one embodiment. In this example, four entities A, B, C, and D wish to create and join a Fabric network. The four entities meet offline to determine the responsibilities of the various entities. Each entity creates one or more BCS instances on the OPC.
[0155] According to one embodiment, Entity A provides both an orderer and a peer. Entity A provides Orderer_Org1 401 for the orderer and Peer_Org1 for the peer. Entity A creates two instances of Orderer_Org1 401 and Orderer_Org2 402, and a Kafka cluster 410. Entity A is also responsible for creating the Fabric network (Note: only an Orderer can create a Fabric network). The ordering service 400 includes Orderer_Org1 401 and Orderer_Org2 402, and a Kafka cluster 410.
[0156] According to one embodiment, Entity B provides both an orderer and a peer. Entity B provides Orderer_Org2 402 for the orderer and Peer_Org2 for the peer. Create two instances of 422.
[0157] According to one embodiment, entity C only provides peers: entity C creates an instance Peer_Org3 423;
[0158] According to one embodiment, entity D provides only peers. Entity D creates an instance, Peer_Org4 424.
[0159] According to one embodiment, the administrator of each BCS instance can access the C Collect the A and admin certificates from the BCS console. For each peer org, the administrator identifies the anchor peers for the current org and collects the anchor peers' IPs / ports. The four entities exchange all collected information with each other offline.
[0160] According to one embodiment, the administrator of Orderer_Org1 uses the information collected in the previous step, the CA certificate and admin certificate of each org and the anchor peer of each peer org, to You create a Fabric network from the BCS console by creating a system channel using the genesis block. The backend work may include invoking Fabric tools to create a genesis block and configuring an orderer to create a system channel using the genesis block.
[0161] According to one embodiment, the administrator of each peer org updates the configuration of all peer nodes to add the collected CA / admin certificates of other orgs, and all peer nodes Join the Fabric network from the BCS console by rebooting the
[0162] According to one embodiment, the system allows a new org to join an existing Fabric network. Additionally, a user-friendly method may be provided to facilitate communication between participants to create / join a Fabric network, e.g., to cover offline actions prior to the formation of the Fabric.
[0163] Chaincode (Smart Contract) Container According to one embodiment, and as described above, chaincode is software that defines assets and transaction instructions for modifying assets. Chaincode implements rules for reading or changing key-value pairs or other state database information. Chaincode functions run against the ledger's current state database and are initiated through transaction proposals. Chaincode execution results in a set of key-value writes (write set) that can be submitted to the network and applied to the ledger on all peers.
[0164] According to one embodiment, to support consistent updates of information and to enable many ledger functions (such as transacting and querying), a blockchain network uses smart contracts to provide controlled access to the ledger. Smart contracts encapsulate information and can be automatically replicated across the fabric; they can also be written to allow participants to automatically execute certain aspects of transactions.
[0165] According to one embodiment, Hyperledger Fabric smart contracts are written in chaincode and are invoked by applications external to the blockchain when they need to interact with the ledger. In many cases, chaincode only interacts with (e.g., queries) the world state, which is the database component of the ledger, and not with the transaction log.
[0166] According to one embodiment, Hyperledger Fabric utilizes the Docker engine to build chaincode, deploy it, and keep it running. This section describes the Fabric architecture and how it integrates into the container runtime service layering model for BCS.
[0167] According to one embodiment, Fabric deploys and manages user chaincode as follows: First, it builds the chaincode into a temporary CCenv container. Second, the chaincode is transferred as source code to a builder container, compiled with the necessary libraries statically linked ("Java build"), and then the binary is sent back to the peer. Static linking allows the actual chaincode container to be as small as possible. Third, it builds the chaincode image and container and starts it. The chaincode container then remains running until the peer is shut down or the channel is terminated. If the chaincode container crashes or is stopped, it will be restarted on the next invocation if the image exists. The design is to have one chaincode Docker container per peer and channel. The chaincode is explicitly installed on the peer; that is, not all peers that join a channel necessarily have the chaincode installed.
[0168] According to one embodiment, users can deploy a Fabric network into a tiered container, the Container Runtime Service, which has the ability to transparently distribute components such as peers, orderers, and chaincodes. Because local block storage is not considered a reliable method of recovery, once the ACLS container chaincode binaries are saved to cloud storage, the chaincode runtime environment container (ccenv) will be dynamically launched. Once built, the chaincode binaries can be dynamically deployed to the cloud storage. The data will be uploaded to cloud storage for restoration purposes in case of a container crash.
[0169] According to one embodiment, each chaincode interaction can correspond to a different function of the chaincode. The only constraint is that the chaincode cannot be invoked or queried until it is instantiated. Additionally, upon invocation, the chaincode container is restarted if it is not found to be running.
[0170] Figure 5 illustrates a chaincode architecture according to one embodiment. More specifically, this diagram illustrates a chaincode architecture that enables a client 530 to install chaincode and execute transactions in a container runtime service environment 500, according to one embodiment. In step 1, the client 530 installs the chaincode source code on peer 1 510. First, the client 530 builds the chaincode into a temporary CCenv container. The client 530 performs the "install" Once the chaincode is created, it will launch a builder container which will automatically launch a builder agent, wait for the builder container to finish initialization, and send the chaincode source code to the builder container via the peer (step 2). The builder agent will build the chaincode (Java build). The chaincode is transferred as source code to the builder container, compiled with the necessary statically linked libraries ("Java build"), and then the binary is sent back to the peer. Static linking allows the actual chaincode container to be as small as possible. Once built, the chaincode package (tgz file) is uploaded to cloud storage 560. The builder agent will send the cloud storage location to the peer for later reference (step 4.2).
[0171] According to one embodiment, the peer 510 would then use the PSM REST API to invoke the CCenv as an ACLS (Access Control List) container 520. The peer 510 will build the chaincode image and container and start it. The chaincode container will then remain running until the peer is shut down or the channel is terminated. The peer 510 will pass the chaincode ID, its own IP (for chaincode registration), and cloud storage location to the ACLS container for startup (step 4.1). The peer will wait for the chaincode to start or time out after a configured time. ccenv will start the chaincode. Upon startup, the chaincode The node will register itself with the peer (step 4.3). The chaincode will be ready for invocation in the transaction (step 5), which will be done using the connection established during registration.
[0172] According to one embodiment, builder container 550 comprises a simple REST-type server. Builder container 550 includes builder agent 553. Builder container 550 starts up and listens for chaincode build requests. When builder container 550 receives a build request, e.g., a POST call with base64 encoded source code as the body, it base64 decodes the source code and saves the chaincode source code to the local file system. Builder agent 553 then runs "Ja If the "Java build" is successful, the builder agent 553 packages the binaries and uploads them to cloud storage 560. The builder agent also returns the chaincode location to the peer. If the "Java build" fails, the agent returns an error and reason to the peer.
[0173] BCS Admin Console According to one embodiment, as described above, each instance of a BCS may include a management console, which may be used to manage and monitor the BCS instance, including BCS gateways, BCS nodes, and BCS channels.
[0174] According to one embodiment, the management console component facilitates and automates the provisioning, monitoring, and configuration of the BCS. The management console component includes a web application that runs in a scripting runtime environment, such as Node.js. The web application can be built on a graphical user interface framework and a web framework and can include multiple custom functions or APIs for communicating with various nodes or services in the BCS instance. The web application can populate view objects with information from the various nodes or services in the BCS instance for display in the console user interface. The management console component can also provide multiple functions for an administrator to start, stop, and update one or more nodes in the BCS instance. A set of management REST APIs can be provided by or accessed by the scripting runtime environment to support the same functionality provided by the web application.
[0175] According to one embodiment, the system can facilitate monitoring and management of associated BCS instances through a web interface provided by a web application or through a custom REST client application written using a collection of administrative REST APIs.
[0176] According to one embodiment, the management console may enable a BCS administrator to manage multiple components of a BCS instance, including one or more peer nodes, one or more orderer nodes, one or more Fabric CA nodes, one or more BCS gateway nodes, channels, and one or more chaincodes.
[0177] According to one embodiment, managing a BCS component may include performing one or more of the following operations: starting a component, stopping a component, adding a component, removing a component, viewing / editing attributes of a component, viewing performance metrics of a component, and viewing logs of a component.
[0178] FIG. 6 illustrates a system for providing a management console according to one embodiment. According to one embodiment, as shown, the BCS Administration Console 136 may be provided as a component of a BCS instance in the Container Runtime Services 128. The BCS Administration Console may represent a runtime environment provided by Node.js. It may be a web application that runs in the crypto runtime environment 605.
[0179] According to one embodiment, the management console may include multiple backend APIs 610, such as a fabric node service development kit (SDK) 611, multiple fabric custom functions / APIs 613, and multiple container runtime service APIs 615. The SDK, custom functions / APIs, and container runtime service APIs are integrated into the Fabric network, which may include distributed streaming services (e.g., Kafka)603. 601. The management console may further include view objects 623. The view objects 623 may contain information that needs to be displayed in the BCS console UI 104 or REST client 604, or may contain information that needs to be passed from the BCS console UI or REST client to the management console. The fabric node SDK 621 may operate to map information from the Fabric network and information from the BCS console UI or REST client.
[0180] According to one embodiment, the BCS Administration Console may include multiple client APIs 622, which may be used by the BCS Console UI or a REST client to provision BCS cloud services and manage provisioned BCS cloud services. Managing provisioned BCS cloud services may include starting and stopping peer nodes, orderer nodes, Fabric CA nodes, and BCS Gateway nodes, and adding and removing peer nodes, orderer nodes, and BCS Gateway nodes.
[0181] According to one embodiment, the BCS Admin Console may further include a GUI framework (eg, JET) 617 and a web framework (eg, Express) 619 . The GUI framework can provide various user interface (UI) components and elements that can be used in the management console web application. For example, the UI components and elements can be used to create forms, collect data, and visualize data. The web framework can be written in JavaScript and can provide a web application framework that includes a robust set of features for developing web and mobile applications.
[0182] 7A-7B show an example of a user interface in the BCS Console UI, according to one embodiment.
[0183] According to one embodiment, a BCS summary 711 may be displayed on the dashboard, as shown in Figure 7A. The summary may include the number of organizations, the number of peers, the number of orderers, the number of channels, and the number of chaincodes.
[0184] According to one embodiment, health information 713 of the BCS instance may be displayed. The health information may be displayed visually and numerically. The sample UI may also display transaction execution 714 and ledger summary 715.
[0185] According to one embodiment, Figure 7B shows information about all nodes in a BCS instance. For example, the sample UI shows five nodes in total, including two peers (in the BCS Gateway node), one ordering node, one Fabric CA, and one REST proxy. For each node, the summary UI 717 displays the node's name 723, the node's route information 725, the node's type 729, and the node's status information 731. The sample UI includes a button 721 for an administrator to add a node and one or more drop-down lists 719 for filtering nodes.
[0186] Node Management According to one embodiment, a management console can be used to manage a BCS instance. There can be two possible entities: a BCS administrator and a BCS user. There can be only one BCS administrator account per BCS instance. A BCS administrator account can be created when a BCS instance is created. A BCS administrator can be bundled with a Fabric CA administrator (i.e., all actions the BCS administrator takes from the BCS console or via the BCS Management REST API use the Fabric CA administrator identity). There can be more than one BCS user account, which can be created by a BCS administrator by registering a Fabric CA identity.
[0187] According to one embodiment, the nodes in a BCS instance can be displayed on a single web page. The management console can support two modes: in the first mode, the name, type, access URL, and status of each node can be presented as a list; in the second mode, the channels in which each peer participates can be presented graphically.
[0188] Additionally, according to one embodiment, the Management Console may allow a BCS administrator to start and stop peer nodes, orderer nodes, Fabric CA nodes, and BCS Gateway nodes, and to add and remove peer nodes, orderer nodes, and BCS Gateway nodes. Fabric CA nodes cannot be added or removed.
[0189] According to one embodiment, when adding a node, a BCS administrator can set the attributes of that node. The newly added node may be automatically started as part of the add operation. When a node is removed, it is stopped and removed from the BCS instance.
[0190] According to one embodiment, the BCS console UI can list all channels that an active peer node participates in and all chaincodes installed on the active peer node.
[0191] According to one embodiment, when managing peer nodes, a BCS administrator can subscribe active peer nodes to existing channels and view and edit the attributes of active orderer nodes, some of which are visible to BCS users.
[0192] According to one embodiment, snapshot performance metrics for active peer nodes, such as memory usage, CPU percentage used, network I / O, and disk I / O, may also be displayed in the BCS console UI.
[0193] According to one embodiment, when managing orderer nodes, BCS administrators can view logs for active orderer nodes and view and edit attributes of active orderer nodes. BCS users can view some of the attributes of active peer nodes. Similar to managing peer nodes, BCS administrators can view snapshot performance metrics for active orderer nodes, such as memory usage, CPU percentage used, network I / O, and disk I / O.
[0194] According to one embodiment, when managing Fabric CA nodes, a BCS administrator can view and edit the attributes of active Fabric CA nodes, and can also view and edit the attributes of active Fabric CA nodes. It is possible to obtain CA certificates from Fabric CA nodes and view logs for active Fabric CA nodes. Additionally, BCS administrators can view performance metrics for active Fabric nodes, such as memory usage, CPU percentage used, network I / O, and disk I / O.
[0195] According to one embodiment, as described above, managing BCS Gateway nodes may include adding or even removing BCS Gateway nodes. Because the maximum number of BCS Gateway nodes allowed is specified when a particular BCS instance is instantiated, the number of BCS Gateway nodes that can be added to a BCS instance is limited by the configured maximum allowed number of BCS Gateways.
[0196] According to one embodiment, each BCS Gateway Node may have a name that is a globally unique identity of the Gateway Node. The name may be referenced when the BCS Gateway Node is configured in the future. A network address may also be determined and displayed when creating a BCS Gateway Node.
[0197] According to one embodiment, when configuring a BCS Gateway node, a BCS administrator can define a BCS Gateway configuration file and bootstrap the BCS Gateway node. When a BCS instance is provisioned, there may be no channels created or chaincodes deployed. Therefore, the BCS Gateway node is not functional until one or more chaincodes are deployed and a valid BCS Gateway configuration is defined through the Administration Console.
[0198] According to one embodiment, there may be a configuration page for each BCS Gateway node. In one embodiment, the following items may be configured on the configuration page: 1) Channel: Select which channel should be exposed through the current gateway node; 2) Chaincode: Select which instantiation chaincode should be exposed from the list of all instantiation chaincodes in each channel; 3) Endorser: Define the endorsing peers for each chaincode; 4) Generate the BCS Gateway configuration according to the settings above. Once a valid configuration file has been generated for the BCS Gateway, the gateway can be started.
[0199] According to one embodiment, the BCS Console allows for a view of BCS Gateway characteristics using a list view feature. The list view provides the following information for each BCS Gateway: 1) Name: A globally unique name specified when creating the gateway; 2) Fabric Identity Name: Each BCS Gateway can be associated with a Fabric Client Identity, which is registered when the BCS Gateway is created. All actions (e.g., calls, queries) performed by the BCS Gateway can be named as this Fabric Client; 3) Network Address: An access point with a public Internet network address; 4) Status: Up or Down.
[0200] According to one embodiment, the Administration Console also allows BCS administrators to view logs for active BCS Gateway nodes and view the following BCS Gateway metrics: 1) Connected clients: client name, address, logon time, etc.; 2) Current Transaction Information: Current transaction information may be made available along with state information, i.e., what state this transaction is in. Current transaction information may be useful for debugging hung transactions; 3) Transaction Statistics: Transaction statistics may be made available through the management console UI. For example, transaction statistics may include the number of completed transactions, the number of event notifications received, and the number of event notifications delivered; 4) Memory usage; 5)CPU percentage; 6) Network I / O; 7) Disk I / O.
[0201] Channel Management According to one embodiment, a BCS user can list all channels in which the current BCS instance participates. A BCS administrator can create a channel using the channel name, consortium name, and one or more organization names as input. Output can also be displayed to indicate the success or failure of the channel creation.
[0202] According to one embodiment, BCS users can view the participating nodes and organizations of a channel. The management console can support two view modes: list mode and topology mode. In list mode, participating local nodes (represented by their anchor peers) and external organizations can be listed as a list. In topology mode, participating local nodes (represented by their anchor peers) and external organizations can be represented in a topology diagram.
[0203] According to one embodiment, a BCS administrator can query the ledger of a peer in a channel. The ledger may consist of a list of transaction blocks. Each such block may include a block ID, previous hash, data hash, timestamp, transaction ID list, action (1..n), chaincode ID, chaincode proposal, response (r / w set, event, success or failure), and one or more endorsers. Statistics on the number of blocks and number of invocations may also be displayed.
[0204] According to one embodiment, a BCS administrator can list all chaincodes instantiated on a channel. The listed items may include the chaincode ID and version. The BCS administrator can also view the instantiated chaincode's information: the Path, which is the path as specified by the instantiation transaction, and the instantiation arguments.
[0205] According to one embodiment, a BCS administrator can upgrade an instantiated chaincode on a channel. The upgrade operation can take as input the target endorsing peer on which the new version of the chaincode is installed, one or more orderers, the chaincode version, and arguments, which can optionally be string array arguments specific to the chaincode. The output of the upgrade operation can be success or failure with an error message.
[0206] Chaincode Management According to one embodiment, a BCS administrator can list all chaincodes installed on any peer in the current BCS instance. The listed items include the chaincode ID and version. In addition, the BCS administrator can also list local peer nodes that have installed chaincodes and those that have not. You can see information about the installed chaincode, the channel on which it was instantiated.
[0207] According to one embodiment, through the management console, a BCS administrator can install chaincode on one or more local peer nodes. Inputs for the install operation may include the target peer; the chaincode type (e.g., golang / Java); the chaincode ID, which may be the name of the chaincode; the chaincode version; the chaincode path, which may be the source code location of the chaincode; and the chaincode package (optional). The output of the install operation may be success or failure with an error message.
[0208] According to one embodiment, a BCS administrator can instantiate an installed chaincode onto a channel in a defined format, or in a default format if no defined format is available, using the following information as input: channel name; target endorsing peer where the chaincode is installed; orderer; arguments, which may be optional and may be string array arguments specific to the chaincode; and endorsing policy.
[0209] Membership Management According to one embodiment, a BCS administrator can list all identities in the current BCS instance, register new users / identities for the current BCS instance, deregister identities, and remove users from the current BCS instance. Additionally, a BCS administrator can view / edit the following attributes of an identity as shown in Table 1:
[0210] [Table 1]
[0211] According to one embodiment, the management console allows a BCS user to register or re-register itself, which can generate a private key and certificate for that user. The management console also allows a BCS administrator to revoke a previously registered identity and allows a BCS user to change their password.
[0212] According to one embodiment, the BCS Administration Console may be started or stopped along with the starting or stopping of the associated BCS instance.
[0213] According to one embodiment, there are two ways to set the log level for the BCS Admin Console: from the BCS Admin Console itself, or by changing the log level at runtime using the Admin REST API.
[0214] FIG. 7C illustrates a method for providing a management console according to one embodiment. According to one embodiment, as shown in FIG. 7C, in step 781, container runtime services are provided.
[0215] According to one embodiment, in step 783, a distributed ledger and management console component is provided in the container runtime service.
[0216] According to one embodiment, in step 785, a plurality of client application programming interfaces (APIs) and a plurality of back-end APIs are provided in the management console component, and a plurality of client applications are provided. The client API is configured to be invoked by a client application, the plurality of backend APIs are configured to communicate with the plurality of nodes of the distributed ledger, and the plurality of client APIs use one or more of the plurality of backend APIs in provisioning the distributed ledger as a blockchain cloud service and in managing the blockchain cloud service.
[0217] REST Proxy Service According to one embodiment, as described above, communication between different components in a Fabric network is based on the gRPC protocol, so a BCS instance based on a Fabric network will require a client application to invoke chaincode in the BCS instance using the Fabric SDK.
[0218] According to one embodiment, requiring client applications to communicate with a blockchain cloud service using the Fabric SDK may partially offset the advantages of providing a distributed ledger as a cloud service, for example, one of the advantages being that the cloud service should be accessible from anywhere with an internet connection.
[0219] According to one embodiment, a REST proxy service component within a BCS instance can use a Service Development Kit (SDK) for Distributed Ledgers in BCS to communicate with the distributed ledger and can provide a REST API for use by client applications to query through chaincode, invoke transactions synchronously or asynchronously through chaincode, obtain transaction status, and obtain the BCS proxy version. The REST proxy service component can authenticate REST calls and translate them into remote procedure calls, such as Google Remote Procedure Calls (gRPC), for use in interfacing with the distributed ledger. The REST proxy service component can also provide a REST API that supports the same functionality as provided by the BCS Administration Console component and can provide a user interface for client applications to consume the BCS instance.
[0220] According to one embodiment, the REST proxy service component may be realized as a BCS and may be a network node in a distributed ledger running in a container runtime service container in a cloud environment (e.g., Oracle Cloud) and managed by a PaaS manager (e.g., the Oracle PaaS Service Manager (PSM) platform).
[0221] According to one embodiment, the REST proxy service component provides The EST APIs may include a REST API that allows client applications to access smart contracts installed on the BCS, and an administrative REST API for the administration console component.
[0222] FIG. 8A illustrates a system for providing REST proxy services in a BCS instance according to one embodiment.
[0223] 8, the REST proxy 138 may include a REST authenticator 827 and a protocol converter 829. When a BCS REST API client 808 sends a REST call 815 to the REST proxy, the LBaaS 126 connected to Cloud Gate 811 may authenticate the call to determine whether the REST call includes a valid username and a valid password that allows the REST to access the BCS instance.
[0224] According to one embodiment, if the REST call is authenticated by the LBaaS, the LBaaS can direct the REST call to a REST proxy, which can forward the REST call 835 to the IDCS 813 to determine if the client application has the appropriate authorization in the BCS.
[0225] According to one embodiment, if the client application is properly authorized, the REST proxy can convert the REST call to a gRPC call 825 and send the gRPC call to the Fabric network 601. Once converted to an internal call (gRPC), the REST call can interface with an instance of Blockchain Fabric / Hyperledger.
[0226] According to one embodiment, the REST calls may be converted by a protocol converter, which may be a Java application based on the Fabric Java SDK 831 with gRPC libraries 833.
[0227] According to one embodiment, as further shown in FIG. 8, the REST proxy can communicate with the management console as described above using REST 821 to expose one or more functions provided by REST API 823 to the management console.
[0228] FIG. 8B illustrates a system for providing REST proxy services in a BCS instance according to one embodiment.
[0229] According to one embodiment, as shown in FIG. 8B, the REST proxy service component 841 runs on a web server 840 (e.g., a tomcat server) in the container runtime service container 838 and can be mapped to a single Fabric user. Furthermore, the REST proxy service component is configurable through a user interface provided by the management console component using JavaScript Object Notation (JSON) files and can be invoked through a user interface provided by the management console component. An administration user can publish peers, channels, and pieces of chaincode to the REST proxy service component. Any updates to the configuration of the REST proxy service component can be automatically reloaded.
[0230] According to one embodiment, a REST proxy service component (node) can be started by a BCS Gateway. The startup script can check the configuration file of the BCS Gateway and the REST proxy service component hosting the BCS Gateway. The web server configuration file can be modified, and then the web server can be started. The web server can start a thread for the BCS Gateway to read the configuration file and create a channel object for each channel. The web server can also create connections with the orderer, peer, and event hub for each channel. Different channels can have different connections with the orderer / peer / event hub. The event hub can be a second port on the peer. The BCS Gateway can connect to this port to get the results of the transaction.
[0231] According to one embodiment, a servlet container in a web server can listen and wait for client requests. For the chaincode query method, the BCS Gateway can randomly send requests to two endorsers of the chaincode and use only the first result. For the chaincode invocation method, the BCS Gateway sends a request to all endorsers of the channel, and if one of them returns success, the BCS Gateway can send the transaction to all orderers of the channel. A peer can open two ports, one for event exchange. The BCS Gateway can connect to the peer's event port for one channel.
[0232] In one embodiment, the REST proxy service component can support both asynchronous and synchronous APIs.
[0233] According to one embodiment, for an asynchronous API, the REST proxy service component can check parameters of a request from a client and return a transaction ID to the client. The client can receive information indicating that a transaction has been started but not completed. The REST proxy service component can start a background thread to continue processing the transaction. The client can keep track of the unfinished transaction. The REST proxy service component provides a transaction API for the client to query the transaction status using the transaction ID.
[0234] FIG. 8C illustrates a method for providing a REST proxy service in a BCS instance according to one embodiment.
[0235] According to one embodiment, as shown in FIG. 8C, in step 881, container runtime services are provided.
[0236] According to one embodiment, in step 883, a distributed ledger is provided in a container runtime service, and the distributed ledger is provisioned as a blockchain cloud service in the container runtime service.
[0237] According to one embodiment, in step 885, a REST proxy service is executed in a container of the container runtime service, the REST proxy service including a plurality of REST APIs for use by client applications in communicating with the distributed ledger, the plurality of REST APIs configured to translate REST calls from the client applications into remote procedure calls.
[0238] Example REST API According to one embodiment, the REST proxy service component uses the BCS and the smart contract (chaincode) installed on the BCS to communicate with the client. A REST API can be provided for interaction between client applications. The following REST API is provided as an example to illustrate the functionality of the REST proxy service component of the blockchain cloud service.
[0239] According to one embodiment, the REST proxy service component must be up and running before invoking the REST API. The status of the REST proxy service component can be checked through the administration console. If the REST proxy service component is not up and running, it can be started from the administration console.
[0240] According to one embodiment, REST APIs can be invoked to interact with smart contracts (chaincodes) deployed to peer nodes in a BCS instance. The deployment process can be accomplished through the Chaincodes page in the Admin Console. Deployment consists of two steps: installation (copying to peers) and instantiation (compiling, binding to a channel, and initializing).
[0241] According to one embodiment, the example REST API provided below assumes that the following example chaincode has been deployed to BCS:
[0242] [Table 2]
[0243] According to one embodiment, as shown above, Table 2 shows exemplary functions of a chaincode, and Table 3 shows an exemplary installation of a chaincode.
[0244] According to one embodiment, the REST proxy service component can provide REST APIs to query through chaincode, invoke transactions through chaincode, invoke transactions through chaincode asynchronously, get transaction status, and get the version of the BCS Gateway.
[0245] According to one embodiment, an API for querying through a chaincode can invoke the chaincode to perform a query action, and the chaincode and arguments for the query are specified through a REST API. An API for getting transaction status can query a channel for transaction status, and the channel and transaction ID are specified through a REST API. An API for getting the version of a BCS gateway can query the version of a BCS gateway. The API for invoking transactions through chaincode can invoke chaincode to perform transactional actions, and the chaincode and arguments for the invocation are specified through the REST API. This REST API can perform transactions in synchronous mode, meaning that a response is sent back in any of three cases: if the transaction execution is successful, if the transaction execution fails, or if the transaction times out.
[0246] According to one embodiment, an API for asynchronously invoking transactions through chaincode can invoke chaincode to perform transactional actions, and the chaincode and arguments for the invocation are specified through a REST API. This REST API performs transactions in an asynchronous mode, i.e., after a transaction is submitted, a response / acknowledgment is sent back immediately without waiting for its completion or timeout, in which case the results may be provided later.
[0247] According to one embodiment, a set of administration REST APIs may be provided on the REST proxy service component for invocation by an administration console to provision and / or manage a BCS.
[0248] Invoking a Query According to one embodiment, the chaincode may contain more functions that are used to query information. These functions are executed using cURL: curl -H Content-type:application / json -X POST http: / / localhost:8080 / bcsgw / rest / v1 / transaction / query The following can be invoked through the REST API by submitting a POST request to the REST resource:
[0249] According to one embodiment, the request body in JSON for a query call may appear as follows:
[0250]
number
[0251] In this example, a function named funcquery has an input parameter of Args[0]:AccountA. This function can query information about account A and return account information. The account information includes the chaincode name, the chaincode version, a method defined in the chaincode to invoke the query, and an array containing the arguments to be passed to the specified method in the chaincode.
[0252] An exemplary response header for a query call may be shown as follows:
[0253]
number
[0254] An example response body for a query invocation may be shown as follows:
[0255]
number
[0256] In the example response body above, "Success" for "returnCode" indicates that the query was successful. "Failure" means the query was unsuccessful. For "result", if the returnCode is "Success", the query result will be For "info", if the returnCode is "Failure" , a string with additional details of the failure may be returned.
[0257] Transaction Invocation (Synchronous) According to one embodiment, the chaincode may include one or more functions for transactions. The REST API is used to invoke these transactions. A response may be sent back if any of the following conditions are met: a timeout for the operation, a successful transaction, or a failed transaction.
[0258] According to one embodiment, the following cURL command can be used to invoke this REST API: "curl -H Content-type:application / json -X POST -d http: / / localhost:8080 / bcsgw / rest / v1 / transaction / invocation."
[0259] An example request body in JSON may be shown as follows:
[0260]
number
[0261] In this example, the function named funcinvoke has the following input parameters: Args[0]: Account A, Args[1]: Account B, and Args[2]: Amount C. You would move 3 from account A to account B.
[0262] An example response header may appear as follows:
[0263]
number
[0264] An exemplary response body may appear as follows:
[0265]
number
[0266] Transaction Invocation (Asynchronous) According to one embodiment, a chaincode may contain one or more functions for transactions. This REST API or operation can be used to invoke those functions in asynchronous mode, where the transaction ID is returned immediately, even if the operation has not yet completed, failed, or timed out. When using this operation, the status of the operation is queried separately.
[0267] The API can be invoked using the command "curl -H Content type:application / json -X POST -d http: / / localhost:8080 / bcsgw / rest / v1 / transaction / asyncInvocation".
[0268] An example request body in JSON may be shown as follows:
[0269]
number
[0270] In this example, the function named funcinvoke has the following input parameters: Args[0]: Account A, Args[1]: Account B, and Args[2]: Amount C. This REST API operation will always return a transaction ID immediately after the transaction is submitted. The status of the transaction can be queried by another REST API operation.
[0271] An example response header may appear as follows:
[0272]
number
[0273] An exemplary response body may appear as follows:
[0274]
number
[0275] In the response body above, "Success" for "returnCode" indicates that the transaction "Failure" means the transaction was not successfully invoked. If the returnCode is "Failure", "info" contains information about the failure. It may contain all the additional information.
[0276] View status of identified transactions According to one embodiment, this REST API allows users to check the current status of a transaction by specified channel information and transaction ID, and can immediately return the current status of the transaction.
[0277] To call the API, you can use the cURL command "curl -H Content-type:application / json -X POST -d http: / / localhost:8080 / bcsgw / rest / v1 / transaction".
[0278] Below is an example request header in JSON for calling the API. In the header, "txid" is the transaction ID:
[0279]
number
[0280] Below are some example response headers:
[0281]
number
[0282] Below is an example response body:
[0283]
number
[0284] View status for transaction list According to one embodiment, this REST API can be used to check the status of a group of identified transactions. It returns if one of two conditions is true: 1) none of the transactions have an InProgress status, i.e., all listed transactions have either succeeded or failed; or 2) the timeout has been reached for this request.
[0285] To call the REST API, use the command "curl -H Content-type:application / json -X POST -d http: / / localhost:8080 / bcsgw / rest / v1 / transaction / waitStatus". It can be used.
[0286] Below is an example request body in JSON:
[0287]
number
[0288] The above request checks the status of the transaction identified by the listed channel and transaction ID. "timeout" is the timeout for this operation. Specifies the timeout in milliseconds, and "array" lists the transactions to be queried. For each transaction, an element can be created with the channel name and transaction ID.
[0289] An example response header may appear as follows:
[0290]
number
[0291] An exemplary response body may appear as follows:
[0292]
number
[0293] View Version According to one embodiment, this REST API can be used to retrieve BCS Gateway version information and can be invoked using the command "curl -H Content-type:application / json -X POST -d http: / / localhost:8080 / bcsgw / rest / version".
[0294] An example request header in JSON for calling a REST API may be shown as follows:
[0295]
number
[0296] An example response header returned from a REST call might look like this:
[0297]
number
[0298] An example response body returned from a REST call may look like this:
[0299]
number
[0300] Fabric Certificate Authority (Fabric CA) integrated with Identity Cloud Services (IDCS) According to one embodiment, the Fabric CA server manages the membership for the fabric. Fabric CA provides authentication and authorization services. It includes three parts: authentication for users, authentication to access the blockchain (a group of peers and orders), and a CA server that can deliver certificates to application clients, peers, and orders. Fabric CA uses certificates to achieve authentication and authorization. Certificates include two types: registration certs for authentication and transaction certs for authorization. IDCS also provides authentication and authorization. However, its authorization is achieved by OAuth. That is, if a peer wants to access an order, it should obtain the user's access token from IDCS and use this token to access the order.
[0301] According to one embodiment, the Fabric CA uses a database or LDAP to store information about registered users of the Fabric CA, such as user name / password, user certificate, and user affiliation. Public cloud (OPC) end users will employ one centralized IDCS instance to manage their employees' access to all applicable public cloud (OPC) instances. The blockchain cloud service BCS is preferably integrated with IDCS used for other cloud services. This allows end users to employ one centralized IDCS instance to manage their employees' access to all applicable public cloud (OPC) instances included in the BCS.
[0302] In one embodiment, Blockchain Cloud Services (BCS) uses Oracle Identity Cloud Services (IDCS) to centrally store user information. BCS stores Fabric CA user information in IDCS, thereby enabling Oracle BCS to use IDCS to manage centralized BCS user information across multiple public cloud service instances. Thus, in one embodiment, BCS Fabric CA user information, certificates, are stored in Oracle IDCS. The Fabric certificate authorization framework is a Fabric Membership Provider (MSP) that contains PKI private keys, signed certificates, and CA certificate chains, which are configured by the Fabric CA client / server.
[0303] According to one embodiment, BCS leverages OPC's user management. Every BCS user must first be an OPC user (and therefore an IDCS identity). When a BCS instance is created, several types of applications are created: BCS Console, CA, and REST Proxy. For the Console, there are two app roles: Console Admin and Console User. For the CA, there are two app roles: Fab Admin and Console User. Rick admin, Fabric client, Fabric peer, Fabric orderer There are four app roles: Gateway admin and Gateway admin. There are two app roles:
[0304] According to one embodiment, to become a BCS user, an OPC user must be granted a BCS app role in the OPC User Management Console.
[0305] According to one embodiment, when creating a BCS instance, the creator must provide an existing OPC user / password, and this user must have the BCS console admin and fabric This user will automatically be given the role of BCS administrator. Become a nistrator.
[0306] Authentication: For BCS console / CA / REST proxy, authentication is done at Cloud Gate. For peer / orderer, authentication is signature based. For BCS console, after authentication, the console will authenticate the current user (by calling IDCS). Get the app role for the user. If the user has the console admin or console user role If the user is not given the connection will be refused. Otherwise the console will enforce access control based on predefined rules. For example, a normal user can generally only read information, while an admin can do anything.
[0307] According to one embodiment, for the CA, after authentication, the CA gets the app roles of the current user. If the user has not been granted any fabric roles, the enrollment request is rejected.
[0308] According to one embodiment, for the REST proxy, after authentication, the REST proxy gets the app roles of the current user. If the user is a gateway admin or gateway user, If the user does not have the appropriate role, the request is rejected. Otherwise, the REST proxy performs access control based on predefined rules. For example, a normal user can make calls / queries, an admin can change configurations or get metrics. This can be done.
[0309] According to one embodiment, the Fabric CA server provides membership services for Fabric, which includes three parts: authentication for users, authentication for accessing the blockchain (a group of peers and orders), and a CA server that can deliver certificates to application clients, peers, and orders.
[0310] According to one embodiment, the Fabric CA uses certificates to achieve authentication and authorization, which include two types: enrollment certs for authentication and transaction certs for authorization.
[0311] According to one embodiment, IDCS also provides authentication and authorization. However, the authorization is achieved through OAuth. That is, when a peer wants to access an order, the peer should get the user's access token from IDCS and use this token to access the order.
[0312] FIG. 9A illustrates a typical IDCS use case for single sign-on, according to one embodiment.
[0313] According to one embodiment, in a first step, a web application 901 can be added to IDCS 902. Then, a client, such as a web browser 900, can request authentication (e.g., username and password) from the web application. Now that the web application has been added to IDCS, the web application can instruct the web browser to make an authentication request to IDCS. After receiving a response from the web application, the web browser can then request authentication (e.g., username and password) from IDCS.
[0314] According to one embodiment, IDCS can then authenticate the request and, upon successful authentication, send a token back to the web browser. Once authenticated and receiving the token, the web browser can then make a request from a web application. The web application can validate the token and signal to the web browser that authentication was successful.
[0315] In the example shown in Figure 9A, IDCS acts as an identity provider (IdP) to provide identity services for applications. All communication between all parties is HTTP-based. This use case is configuration-driven, but only applies to HTTP-based applications.
[0316] FIG. 9B illustrates an IDCS use case for Fabric client authentication, according to one embodiment.
[0317] According to one embodiment, a Fabric client 904 associated with an already registered Fabric user (whose private key and certificate are already stored in the client-side state store) can request to obtain a new client() and the client's user context (username). The Fabric SDK 905 can load the user from the state store and return the user object to the Fabric client. Once the client receives the user object, it can send a transaction proposal to the Fabric SDK, which can sign the proposal using the same private key. The signed proposal can then go to a peer (or peers) 906, which will verify the signature with a membership service 907. The membership service can obtain a certificate for the user from the IDCS 902 and can verify the user's signature using the certificate from the IDCS. The membership service can then return verification to the peer that the signature was verified.
[0318] While various embodiments of the present invention have been described above, it should be understood that they have been presented by way of example, and not by way of limitation. The embodiments have been selected and described in order to explain the features and principles of the invention and its practical application. The embodiments illustrate systems and methods in which various features of the present invention are utilized to provide new and / or improved functionality and / or to enhance the performance of the systems and methods by providing performance advantages, including, but not limited to, reduced resource utilization, increased capacity, increased throughput, improved efficiency, reduced latency, enhanced security, and / or improved ease of use.
[0319] Some embodiments of the present invention are described herein with reference to flowcharts and / or block diagrams of methods, apparatus (systems), and computer program products, illustrating their architecture, functionality, processes, and / or operation. Each block in a flowchart or block diagram represents an element, function, process, module, segment, or portion of an instruction, which comprises one or more executable instructions for implementing the specified function. In some alternative embodiments, the functions depicted in the block diagrams or flowcharts occur in an order other than that depicted in the figures. For example, two blocks shown in succession may be executed substantially simultaneously or in the reverse order, depending on the functionality involved. Each block of the flowcharts and / or block diagrams, and combinations of blocks in the flowcharts and / or block diagrams, may be implemented by computer program instructions and / or dedicated hardware and / or a combination of hardware and computer program instructions that perform the specified function.
[0320] In some embodiments, features of the present invention are implemented in a computer including a processor, a computer-readable storage medium, and a network card / interface for communicating with other computers. In some embodiments, features of the present invention are implemented in a network computing environment including computing systems including various types of computer configurations, including personal computers, handheld devices, multiprocessor systems, microprocessor-based or programmable consumer electronics, network PCs, minicomputers, mainframe computers, etc., interconnected by a network. The network may be a local area network (LAN), a switched fabric network (e.g., Infini Band (InfiniBand), Wide Area Network (WAN) ), and / or the Internet. The network may include copper transmission cables, optical fiber transmissions, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers.
[0321] In some embodiments, features of the present invention are implemented in a computing system that includes back-end components (e.g., data servers), middleware components (e.g., application servers), front-end components (e.g., client computers having a graphical user interface or web browser that allows users to interact with implementations of the subject matter described herein), or any combination of such back-end, middleware, or front-end components interconnected by a network. A computing system may include clients and servers that have a client-server relationship to one another. In some embodiments, features of the present invention are implemented in a computing system that includes a distributed computing environment in which one or more clusters of computers are connected by a network. A distributed computing environment can have all the computers at a single location, or can have clusters of computers in different remote geographic locations connected by a network.
[0322] In some embodiments, features of the present invention are implemented in the cloud as part of, or as a service of, a cloud computing system based on shared, elastic resources provided to users in a self-service, metered manner using web technologies. Cloud characteristics may include, for example, on-demand self-service, wide network access, resource pooling, rapid flexibility, and metered service. Cloud deployment models include public, private, and hybrid. Cloud service models include Software as a Service (SaaS), Platform as a Service (PaaS), Database as a Service (DBA), and others. Database as a Service (DBaaS) and Infrastructure Cloud generally refers to a combination of hardware, software, network, and web technologies that provides shared, flexible resources to users. Cloud as used herein may include public cloud, private cloud, and / or hybrid cloud implementations, and may include cloud SaaS, cloud DBaaS, cloud PaaS, and / or cloud IaaS deployment models.
[0323] In some embodiments, features of the present invention are implemented using or with the aid of hardware, software, firmware, or a combination thereof. In some embodiments, features of the present invention are implemented using a processor configured or programmed to perform one or more functions of the present invention. In some embodiments, the processor is a single or multi-chip processor, a digital signal processor (DSP), a system on a chip (SOC), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic device, a state machine, discrete gate or transistor logic, discrete hardware components, or any combination thereof, designed to perform the functions described herein. In some implementations, features of the present invention are implemented by circuitry specific to a given function. In other implementations, features are implemented by a computer, computing system, or processor configured to perform a particular function using, for example, instructions stored on a computer-readable storage medium. , and / or implemented in a network.
[0324] In some embodiments, features of the present invention are incorporated into software and / or firmware for controlling the hardware of a processing and / or network system and for enabling the processor and / or network to interact with other systems that utilize features of the present invention. Such software or firmware may include, but is not limited to, application code, device drivers, operating systems, virtual machines, hypervisors, application programming interfaces, programming languages, and execution environments / containers. Based on the teachings of the present disclosure, appropriate software coding may be readily prepared by skilled programmers.
[0325] In some embodiments, the present invention includes a computer program product, which is a machine-readable or computer-readable storage medium having stored thereon instructions, including software and / or firmware, that can be used to program or otherwise configure a system, such as a computer, to perform any of the processes or functions of the present invention. The storage medium or computer-readable medium may include any type of medium or device suitable for storing instructions and / or data, including, but not limited to, floppy disks, hard drives, solid-state drives, optical disks, DVDs, CD-ROMs, microdrives, and magneto-optical disks, ROM, RAM, EPROM, EEPROM, DRAM, VRAM, flash memory devices, magnetic or optical cards, molecular memory, nanosystems, or variations and combinations thereof. In certain embodiments, the storage medium or computer-readable medium is a non-transitory machine-readable storage medium or a non-transitory computer-readable storage medium.
[0326] The foregoing description is not intended to be exhaustive or to limit the invention to the precise form disclosed. In addition, while embodiments of the present invention have been described using a particular sequence of transactions and steps, it should be apparent to those skilled in the art that, unless otherwise stated, the embodiments do not exclude the performance of additional transactions and steps. Also, while various embodiments describe particular combinations of features of the present invention, it should be understood that different combinations of features will be apparent to those skilled in the relevant art that fall within the scope of the invention. In particular, features (such as devices or methods) described in a given embodiment, variant, or illustrated in a drawing may be combined with or substituted for other features in other embodiments, variants, or drawings without departing from the scope of the invention. Furthermore, it will be apparent to those skilled in the relevant art that various additions, eliminations, deletions, variations, substitutions with equivalents of elements, and other modifications and changes in form, details, implementations, and applications can be made therein without departing from the spirit and scope of the invention. The broader spirit and scope of the invention is intended to be defined by the claims and their equivalents.
Claims
1. A system for managing a blockchain cloud service, comprising: a computer including at least one processor; a container runtime service executing on the computer, the container runtime service supporting multiple containers, the system further comprising: a distributed ledger and a management console executing in a container of the plurality of containers; the distributed ledger is provisioned as a blockchain cloud service via the management console; the management console includes a graphical user interface (GUI) framework; the GUI framework provides a set of components used by a web component of the administration console to visualize a set of data associated with the distributed ledger; The management console includes a plurality of client application programming interfaces (APIs) and a plurality of back-end APIs; The system, wherein provisioning the distributed ledger as a blockchain cloud service includes launching an ordering node, launching a peer node, and launching a chaincode node.
2. The system of claim 1 , wherein the plurality of client APIs are configured to be called by a client application.
3. 3. The system of claim 2, wherein the backend APIs are configured to communicate with a plurality of nodes of the distributed ledger, including the ordering node, the peer node, and the chaincode node.
4. 4. The system of claim 3, wherein the GUI framework collects the set of data from the distributed ledger.
5. 5. The system of claim 4, further comprising a graphical user interface (GUI) provided at the web component of the management console, the GUI configured to receive instructions from the distributed ledger to provide a visual representation of the set of collected data.
6. 1. A method for managing a blockchain cloud service, comprising: Providing a computer including at least one processor; providing a container runtime service that runs on the computer, the container runtime service supporting multiple containers, the method further comprising: providing a distributed ledger and a management console executing in a container of the plurality of containers, the distributed ledger being provisioned as a blockchain cloud service via the management console, the management console including a graphical user interface (GUI) framework, the method further comprising: the GUI framework providing a set of components used by a web component of the administration console to visualize a set of data associated with the distributed ledger; The management console includes a plurality of client application programming interfaces (APIs) and a plurality of back-end APIs; The method, wherein provisioning the distributed ledger as a blockchain cloud service includes launching an ordering node, launching a peer node, and launching a chaincode node.
7. The method of claim 6 , wherein the plurality of client APIs are configured to be called by a client application.
8. 8. The method of claim 7, wherein the backend APIs are configured to communicate with a number of nodes of the distributed ledger, including the ordering node, the peer node, and the chaincode node.
9. 10. The method of claim 8, wherein the GUI framework collects the set of data from the distributed ledger.
10. 10. The method of claim 9, further comprising providing a graphical user interface (GUI) on the web component of the management console, the GUI configured to receive instructions from the distributed ledger to provide a visual representation of the set of collected data.
11. A computer program comprising instructions which, when executed by a computer, cause the computer to perform the method according to any one of claims 6 to 10.
Citation Information
Patent Citations
Document generation device
JP2011215827A
Sharing of user IDs between operating systems and applications
JP2014512589A
Systems and methods for cloud computing
JP2014524096A
Methods and systems for identity creation, verification and management
US20170177855A1
Network for updating electronic devices
US8555273B1
