Hyperledger fabric and Ethereum integration - hyperledger-fabric

We were planning to build a blockchain based on below logic, but understand due to the private data(a portion of our data is private while some data is public), it is not possible on Ethereum. Would the same design / implementation be possible using Hyperledger Fabric?
Our current design : Blockchain on ethereum but keeping the data related to blocks in some distributed file storage system like IPFS or Storj and storing the hash of data in blocks. But we need our data to be private / shared, so to achieve that we are thinking of using some Key Management Service like NuCypher KMS. But we will have smart contracts on ethereum which can access the data and perform some operations.
We understand that the above logic is unable due to the private nature of data. Is there anyway to establish communication between Hyperledger fabric data and Ethereum smart contract?

It is quite possible to make a part of the transaction data private and other part of the transaction data private in Ethereum using various smart contract obfuscation techniques. One such technique is known as Zero Knowledge Proof which can be implemented in Ethereum at a Smart Contract level using Aztech Protocol. It is possible to implement Zero Knowledge Proofs in Ethereum in a further extended way using ZoKrates libraries which implements libsnarks. In Hyperledger Fabric, from version 1.2 onwards there is a feature known as 'Side DB' which helps us to have private transaction between two peers.
As you have mentioned, using NuCypher platform with homomorphic encryption and proxy re-encryption is always a good idea. We may need to push data from NuCypher into a Smart Contract through Web3.js or by some other easier approach.
With regard to your third question, yes, it is possible to integrated Ethereum and Hyperledger Fabric from Hyperledger 1.4 easily. It has integrated Hyperledger Burrow which makes compiling and deploying Ethereum Smart Contracts on Hyperledger Fabric easier. However I am not sure how much it will help your purpose.
Thinking again, I believe offline encryption using NuCypher / Decentralised Oracles and then invoking Smart Contracts with Meta Data from encrypted data vault looks like a good design choice. I feel Hyperledger Fabric may be an overkill for implementing an offline encryption vault.

Hyperledger offers etereum support. Please look for Seth, Burrow etc. May be that can be your lead.

Related

Azure Blockchain Service - How to write and read to/from Transaction Node?

We have created the Azure Blockchain Service to store a data securely. But we need a way to write and read the data from Transaction Node.
As of now, we can store the data in Transaction node using HTTP Post method as per this article
https://tsmatz.wordpress.com/2019/11/06/azure-blockchain-service-quorum-tutorial-web3-truffle-develop/
But how to read the same data again from Transaction Node?
After a couple of weeks of study, I realized that we need to write smart contracts to read and write data to blockchain.
Truffle Framework provides a suite of tools for developing Ethereum smart contracts with the Solidity programming language.
Web3.js library, the main JavaScript library for interacting with the Ethereum Blockchain.
Thanks to Gregory McCubbin, a Ethereum Development Expert from Dapp University who explains the Ethereum blockchain in a very effective manner.
https://www.dappuniversity.com/articles/blockchain-app-tutorial
The good news with azure blockchain service is that you can use Azure Blockchain Development Kit for Ethereum VS Code extension to attach to a consortium, create, connect, build, and deploy smart contracts on Ethereum blockchain ledgers.
https://learn.microsoft.com/en-us/azure/blockchain/service/connect-vscode

Smart contract in peer-to-peer network without existence of blockchain

I need to know how can apply smart contract in a peer-to-peer network in which blockchain has not been utilized.
think two entities are interacting together in a peer-to-peer network and they have obligated pay some cost for some service that provide together ,but in this case they don't use blockchain and they should pay inside the network,can they use smart contract in this case? smart contract without blockchain? is any solution or any sample for that?
So far smart contracts have only been implemented in blockchain networks (and other distributed ledgers such as Hashgraph). Without such a platform you need some intermediary to fill the role of a smart contract.
For P2P networks, Bitcoin (and it's successors) were the first to create virtual currency in a decentralized fashion - so no, it is not possible to use digital currency without blockchain or a trusted third party.

Difference between Hyperledger Fabric and Hyperledger Iroha?

Both Hyperledger Fabric and Hyperledger Iroha are platforms for building distributed ledger applications.
What are the main differences between them? When to choose one over the other to implement a blockchain solution?
Hyperledger Iroha and Fabric are just 2 of 5 independent Hyperledger blockchain technologies:
Hyperledger Fabric
Hyperledger Sawtooth
Hyperledger Indy (Identity Management focus)
Hyperledger Iroha (Extensive client API support, including mobile platforms)
Hyperledger Burrow (Ethereum EVM implementation)
How is Iroha different?
Byzantine fault tolerant consensus algorithm (called YAC) is high-performance and allows for finality of transactions with low latency.
Includes built-in commands for common tasks such as create digital assets, register accounts, and transfer assets between accounts.
Has a robust permission system, allowing permissions to be set for all commands, queries, and joining of the network.
I would evaluate each technology to see which one best fits your needs.
Fabric and Iroha are different Hyperledger technologies.
Unlike Fabric where peers polls for validation, Iroha applications interacts with peers in a simple client-server fashion.
Iroha uses YAC consensus algorithm.
The most significant difference is provided by the entity called accounts. Accounts have roles associated with them and only those accounts that holds grantable permission can perform any actions.
I don't know about your use case, so I'll generalise using a small example here. Go for Iroha in use cases similar to KYC. Iroha specialises in accounts and roles(set of permissions) associated with it. You can handle similar scenario with Fabric too, but then you need to take care about access rights, grants etc. Similarly, various use cases can be solved using multiple technologies. Iroha would also be preferable in scenarios involving creation and transfer of assets.
This will be helpful for you. Cheers!

How to deploy a Chain Code with Hyperledger Fabric?

I’m interested into the development of Blockchain Apps using Fabric and Composer.
I’ve got just one question: while Ethereum is a public blockchain so you can deploy your Smart Contract on it and use them freely, can we do the same thing with Fabric? Let me explain: Ethereum has a running Blockchain on which we can work and access, but Fabric has not, right? Should I set up an entire new blockchain network before (setting up all the nodes, giving permissions etc.)?
Thank you
Hyperledger Fabric is different to the blockchain systems you mention in it is private and permissioned. Rather than an open permissionless system that allows unknown identities to participate in the network (requiring protocols like “proof of work” to validate transactions and secure the network), the members of a Hyperledger Fabric network enroll through a trusted Membership Service Provider (MSP). Member organisations would generally set up their own Fabric infrastructure, if they're participating in the blockchain network (context provided earlier). See more on FAQ here -> http://hyperledger-fabric.readthedocs.io/en/release-1.2/Fabric-FAQ.html and understand more on key Fabric Concepts here -> http://hyperledger-fabric.readthedocs.io/en/release-1.2/key_concepts.html . As for Hyperledger Composer, that is a development framework, with tools etc to accelerate development and abstract things to a business level (ie App development using structure/validated, model driven development as a given). See more here -> https://hyperledger.github.io/composer/latest/introduction/introduction (and also see the architectural and key concept links there).
So yes, you will have a running, private blockchain network (including all of the functionality discussed in the docs) with Hyperledger Fabric.
As in Ethereum we can able to create public blockchain and then the user can able to run smart contract on it, same thing we can do in Hyperledger fabric also.
Hyperledger Fabric has the same functionality as smart contracts called as “chaincode”.
A chaincode is a program that is written to read and update the ledger state. All the business logic handled by chaincode.
For example, if a transaction created then chaincode share and update the ledger throughout the network.
About a Fabric based running blockchain we can work on it and can access it but that's only possible when someone from existing network invites you.
It is quite difficult to say you should setup an entire new blockchain network until I know your use case. Based on your use case you can setup an entire new blockchain network using fabric which will be private.

What is the relation between `Fabric`, `Composer`, `Cello` and other Hyperledger applications?

When I was tasting the fabric, I found many other blockchain projects, like Composer, Cello, Explorer. They are all belong to Hyperledger. I'm very confused that there are so many projects. Should I learn all of them? It seems each project plays a role in the blockchain. BUT:
What's the relation between them?
I draw a picture to explain my question. The picture is not correct, I just want to make my question clear.
If I figure it out, when we want to use the blockchain in our project, I can just study few of them, and use them appropriately.
Fabric provides a framework to set up a blockchain network. It is data/application agnostic.
Composer provides a set of tools to define a business network on top of Fabric. This provides a higher level of abstraction than Fabric where the data are essentially just bits. With Composer you can define assets, transactions, etc.
Cello helps with provisioning of the network.
Explorer simply provides a web based interface to explore what's on a blockchain.
Fabric is a permissioned blockchain distributed ledger, it is at the end; an implementation of a permissioned blockchain.
Hyperledger project comprises a suite of tools for building blockchain business networks, what they name it "Hyperledger Composer".
it is used for developing,testing, deploying application on blockchain
also it is used for integrating your blockchain with external systems,
Cello, is a blockchain provision and operation system, which helps manage blockchain networks, and make the blockchain as service BaaS, it is not a blockchain, but it is used to manage the blockchain network.
Check this link for better understanding Cello
Hyperledger Cello
Explorer provide you KPI that show the blockchain
Cello is admin tool that help you to monitor the host and network with and container inside it, actually cello using fabric script if you take around in fabric you will find byfn (build your first network) script that setup container and example peer.
so cello uses this script to create container and show to you status of this and delete it or edit.
composer provide a tools to help you create your business card and your smart contract to write your smart contract you need to write acl(access control language which define rule),your logic , define participant and assets.
then composer will create bna archive file and install it on blockchain.
there is some module in composer like playground and restserver and also there is generator for frontend
fabric is the framework that setup the blockchain network, it's the base that cello and other module uses it
i hope i help you

Resources