When a smart-contract is created following an agreement between two entities, how the state of that contract (data) can be kept secret to only the two contractors?

I heard about Quorum, but how privacy can be ensured while the contract will be executed by the network validators?

Is Quorum the best choice and can handle privacy for any use cases? or is designed for specific cases only?


1 Answer 1


You can read how Quorum achieves privacy in the wiki on this page: https://github.com/jpmorganchase/quorum/wiki/Transaction-Processing.

I'll explain how this works here but not as comprehensively as the link does. Essentially, key to Quorum's privacy features are 2 fold: - Quorum implements 2 states: public and private. Private state is maintained at the node level and reflects changes to private smart contracts that the node was party to during the lifetime of the blockchain. Private smart contracts are smart contracts that are only visible to N number of participants. - Private transactions that a node executes have its payload data stripped and shared only with the intended recipients of the payload. The public chain records a txn which is hash of the encrypted txn shared between the parties (txn is written with special v value) and the actual payload is encrypted and passed over another layer through a private transaction manager (constellation / tessera)

Call me biased, but I do happen to think that Quorum is the best choice for privacy handling that is as close to Ethereum as possible, after all, Quorum is a fork of go-ethereum client. As for use cases: as long as one needs a private blockchain, Quorum will fit and support any use cases applicable to Ethereum. Privacy is only one of the major features, but as most features, op decides what to use in their use case. The other features are several supported consensus algorithms, network level permissioning, and block finality.

  • Thanks, but how a consensus can be achieved especially if the contract is private between small number of participants (eg., two entities only)? or if the contract is private between users that are not full nodes (not participating in the validation) ?
    – Noureddine
    Commented Nov 15, 2018 at 8:53
  • This is answered in more detail on the wiki. Essentially, the consensus is achieved between the N parties participating in the private txn. After the txn is accepted, theres an API to validate that the private contract is the same by comparing its hash via: github.com/jpmorganchase/quorum/blob/master/docs/…. In future versions of Quorum this will be automatic.
    – fixanoid
    Commented Nov 16, 2018 at 22:31
  • Thanks for the clarification, but who will made the comparison of the hash? I guess the validators. I think it does not make sense to not be automatic, or I miss something?
    – Noureddine
    Commented Nov 17, 2018 at 6:55
  • Originally, this wasn't part that validators checked, this a method was added for parties to compare that their state remains in sync outside of the chain. The enhancement being worked on is to make it automatic as part of validation.
    – fixanoid
    Commented Nov 20, 2018 at 5:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.