From ccbfbe74cc3062c27e82d9a5a7a855b89c23bfce Mon Sep 17 00:00:00 2001 From: Brian Chamberlain Date: Mon, 16 Mar 2020 14:43:38 -0400 Subject: [PATCH] Initial import of gitbook docs --- .gitbook.yaml | 2 + docs/README.md | 29 +++ ...ase.md => Radish34_Procurment_Use_case.md} | 0 docs/SUMMARY.md | 49 ++++ docs/baseline-basics/code-docs.md | 2 + docs/baseline-basics/faq.md | 16 ++ docs/baseline-basics/glossary.md | 42 ++++ .../key-github-folder-readmes.md | 2 + docs/baseline-protocol/community/README.md | 61 +++++ .../community/community-governance.md | 2 + .../community/community-tools.md | 2 + .../community/supporting-community-members.md | 16 ++ docs/baseline-protocol/mainnet.md | 41 ++++ docs/baseline-protocol/performance.md | 2 + docs/baseline-protocol/process.md | 30 +++ docs/baseline-protocol/protocol.md | 28 +++ docs/baseline-protocol/roadmap.md | 8 + docs/baseline-protocol/standards.md | 64 +++++ docs/baselining/core-banking.md | 2 + docs/baselining/enterprise-middleware.md | 2 + docs/baselining/erp-crm.md | 2 + docs/baselining/scm.md | 2 + docs/baselining/your-product.md | 12 + docs/components/baseline-server/README.md | 10 + docs/components/baseline-server/apis.md | 8 + docs/components/baseline-server/messenger.md | 18 ++ .../baseline-server/zero-knowledge-service.md | 24 ++ docs/components/on-chain.md | 2 + docs/radish34-demo/README.md | 29 +++ docs/radish34-demo/SUMMARY.md | 49 ++++ .../baseline-basics/code-docs.md | 2 + docs/radish34-demo/baseline-basics/faq.md | 16 ++ .../radish34-demo/baseline-basics/glossary.md | 42 ++++ .../key-github-folder-readmes.md | 2 + .../baseline-protocol/community/README.md | 61 +++++ .../community/community-governance.md | 2 + .../community/community-tools.md | 2 + .../community/supporting-community-members.md | 16 ++ .../baseline-protocol/mainnet.md | 41 ++++ .../baseline-protocol/performance.md | 2 + .../baseline-protocol/process.md | 30 +++ .../baseline-protocol/protocol.md | 28 +++ .../baseline-protocol/roadmap.md | 8 + .../baseline-protocol/standards.md | 64 +++++ docs/radish34-demo/baselining/core-banking.md | 2 + .../baselining/enterprise-middleware.md | 2 + docs/radish34-demo/baselining/erp-crm.md | 2 + docs/radish34-demo/baselining/scm.md | 2 + docs/radish34-demo/baselining/your-product.md | 12 + .../components/baseline-server/README.md | 10 + .../components/baseline-server/apis.md | 8 + .../components/baseline-server/messenger.md | 18 ++ .../baseline-server/zero-knowledge-service.md | 24 ++ docs/radish34-demo/components/on-chain.md | 2 + docs/radish34-demo/demo.md | 13 ++ .../getting-started-with-radish34.md | 8 + docs/radish34-demo/mods.md | 16 ++ docs/radish34-demo/poc-to-protocol.md | 24 ++ docs/radish34-demo/radish34-start.md | 220 ++++++++++++++++++ docs/radish34-demo/radish34-workflow.md | 4 + docs/radish34-demo/radish34.md | 46 ++++ 61 files changed, 1285 insertions(+) create mode 100644 .gitbook.yaml create mode 100644 docs/README.md rename docs/{Radish34 Procurement Use Case.md => Radish34_Procurment_Use_case.md} (100%) create mode 100644 docs/SUMMARY.md create mode 100644 docs/baseline-basics/code-docs.md create mode 100644 docs/baseline-basics/faq.md create mode 100644 docs/baseline-basics/glossary.md create mode 100644 docs/baseline-basics/key-github-folder-readmes.md create mode 100644 docs/baseline-protocol/community/README.md create mode 100644 docs/baseline-protocol/community/community-governance.md create mode 100644 docs/baseline-protocol/community/community-tools.md create mode 100644 docs/baseline-protocol/community/supporting-community-members.md create mode 100644 docs/baseline-protocol/mainnet.md create mode 100644 docs/baseline-protocol/performance.md create mode 100644 docs/baseline-protocol/process.md create mode 100644 docs/baseline-protocol/protocol.md create mode 100644 docs/baseline-protocol/roadmap.md create mode 100644 docs/baseline-protocol/standards.md create mode 100644 docs/baselining/core-banking.md create mode 100644 docs/baselining/enterprise-middleware.md create mode 100644 docs/baselining/erp-crm.md create mode 100644 docs/baselining/scm.md create mode 100644 docs/baselining/your-product.md create mode 100644 docs/components/baseline-server/README.md create mode 100644 docs/components/baseline-server/apis.md create mode 100644 docs/components/baseline-server/messenger.md create mode 100644 docs/components/baseline-server/zero-knowledge-service.md create mode 100644 docs/components/on-chain.md create mode 100644 docs/radish34-demo/README.md create mode 100644 docs/radish34-demo/SUMMARY.md create mode 100644 docs/radish34-demo/baseline-basics/code-docs.md create mode 100644 docs/radish34-demo/baseline-basics/faq.md create mode 100644 docs/radish34-demo/baseline-basics/glossary.md create mode 100644 docs/radish34-demo/baseline-basics/key-github-folder-readmes.md create mode 100644 docs/radish34-demo/baseline-protocol/community/README.md create mode 100644 docs/radish34-demo/baseline-protocol/community/community-governance.md create mode 100644 docs/radish34-demo/baseline-protocol/community/community-tools.md create mode 100644 docs/radish34-demo/baseline-protocol/community/supporting-community-members.md create mode 100644 docs/radish34-demo/baseline-protocol/mainnet.md create mode 100644 docs/radish34-demo/baseline-protocol/performance.md create mode 100644 docs/radish34-demo/baseline-protocol/process.md create mode 100644 docs/radish34-demo/baseline-protocol/protocol.md create mode 100644 docs/radish34-demo/baseline-protocol/roadmap.md create mode 100644 docs/radish34-demo/baseline-protocol/standards.md create mode 100644 docs/radish34-demo/baselining/core-banking.md create mode 100644 docs/radish34-demo/baselining/enterprise-middleware.md create mode 100644 docs/radish34-demo/baselining/erp-crm.md create mode 100644 docs/radish34-demo/baselining/scm.md create mode 100644 docs/radish34-demo/baselining/your-product.md create mode 100644 docs/radish34-demo/components/baseline-server/README.md create mode 100644 docs/radish34-demo/components/baseline-server/apis.md create mode 100644 docs/radish34-demo/components/baseline-server/messenger.md create mode 100644 docs/radish34-demo/components/baseline-server/zero-knowledge-service.md create mode 100644 docs/radish34-demo/components/on-chain.md create mode 100644 docs/radish34-demo/demo.md create mode 100644 docs/radish34-demo/getting-started-with-radish34.md create mode 100644 docs/radish34-demo/mods.md create mode 100644 docs/radish34-demo/poc-to-protocol.md create mode 100644 docs/radish34-demo/radish34-start.md create mode 100644 docs/radish34-demo/radish34-workflow.md create mode 100644 docs/radish34-demo/radish34.md diff --git a/.gitbook.yaml b/.gitbook.yaml new file mode 100644 index 000000000..33814c9d2 --- /dev/null +++ b/.gitbook.yaml @@ -0,0 +1,2 @@ +root: ./docs/ + diff --git a/docs/README.md b/docs/README.md new file mode 100644 index 000000000..802d62834 --- /dev/null +++ b/docs/README.md @@ -0,0 +1,29 @@ +# Welcome + +## Welcome to the Baseline Protocol Community + +The Baseline Protocol initiative was [announced](https://consensys.net/blog/press-release/ey-and-consensys-announce-formation-of-baseline-protocol-initiative-to-make-ethereum-mainnet-safe-and-effective-for-enterprises/) on March 4, 2020 and launched as an [OASIS](https://oasis-open-projects.org/) open source project on \[ March X, 2020 \], supported by fourteen founding companies. More companies joined the effort shortly thereafter and continue to do so. \[Link to full list and roles.\] + +The work of the community is maintained under a public domain license at +[**https://github.com/ethereum-oasis/baseline**](https://github.com/ethereum-oasis/baseline). + +You will find in the Repo the code of a procurement demo called **Radish34**. And separately, there is a folder that will contain the specifications, reference code and other material constituting the **Baseline Protocol**, as the community derives it from the initial Radish34 proof of concept. + +There are lots of opportunities to get informed, get involved, and **get value** out of defining requirements, developing reusable components, and ultimately deploying the Baseline Protocol in your own offerings. + +**Go** [**here**](baseline-protocol/community/) **for details on how to get involved.** + +## The Baseline Protocol + +The Baseline Protocol is an approach to using the public [Mainnet](baseline-basics/glossary.md#mainnet) as a common frame of reference between systems, including traditional corporate systems of record, any kind of database, and even different blockchains or DLTs. It is particularly promising as a way to reduce capital expense and other overheads while increasing operational integrity when automating business processes across multiple companies. + + The approach is designed to appeal to security and performance-minded technology officers. + +You can find all the details on the Baseline Protocol [here](baseline-protocol/protocol.md). + +## The Radish34 Demo + +In 2019, three members of the Baseline Protocol community, EY, ConsenSys and Microsoft, got together to build a proof of concept showing how enterprises could safely and effectively use the public Ethereum network to conduct end-to-end supply chain operations without compromising corporate information security norms and practices. What the team learned from that effort led to the formation of the Baseline Protocol initiative. + +You can find the details on Radish34 [here](radish34-demo/radish34-start.md). + diff --git a/docs/Radish34 Procurement Use Case.md b/docs/Radish34_Procurment_Use_case.md similarity index 100% rename from docs/Radish34 Procurement Use Case.md rename to docs/Radish34_Procurment_Use_case.md diff --git a/docs/SUMMARY.md b/docs/SUMMARY.md new file mode 100644 index 000000000..418e7e878 --- /dev/null +++ b/docs/SUMMARY.md @@ -0,0 +1,49 @@ +# Table of contents + +* [Welcome](README.md) + +## Radish34 Demo + +* [Radish34 Explained](radish34-demo/radish34.md) +* [Radish34 Interactive Demo](radish34-demo/demo.md) +* [Getting Started with Radish34](radish34-demo/radish34-start.md) +* [Radish34 Workflow](radish34-demo/radish34-workflow.md) +* [Modifying Radish34](radish34-demo/mods.md) +* [From POC to Protocol](radish34-demo/poc-to-protocol.md) + +## Baseline Protocol + +* [The Baseline Protocol](baseline-protocol/protocol.md) +* [Open Source Community](baseline-protocol/community/README.md) + * [Supporting Community Members](baseline-protocol/community/supporting-community-members.md) + * [Community Governance](baseline-protocol/community/community-governance.md) + * [Community Tools](baseline-protocol/community/community-tools.md) +* [Baseline Process](baseline-protocol/process.md) +* [Performance Stats and Specs](baseline-protocol/performance.md) +* [Standards](baseline-protocol/standards.md) +* [Driving Mainnet Evolution](baseline-protocol/mainnet.md) +* [Roadmap](baseline-protocol/roadmap.md) + +## Components + +* [Baseline Server](components/baseline-server/README.md) + * [Messenger](components/baseline-server/messenger.md) + * [Zero Knowledge Service](components/baseline-server/zero-knowledge-service.md) + * [APIs](components/baseline-server/apis.md) +* [On-Chain Functions](components/on-chain.md) + +## Baselining Your Product + +* [How to 'Baseline' Your Product](baselining/your-product.md) +* [Supply Chain Management](baselining/scm.md) +* [ERP & CRM](baselining/erp-crm.md) +* [Core Banking](baselining/core-banking.md) +* [Enterprise Middleware](baselining/enterprise-middleware.md) + +## Baseline Basics + +* [Glossary](baseline-basics/glossary.md) +* [FAQ](baseline-basics/faq.md) +* [Key GitHub Folder Readme's](baseline-basics/key-github-folder-readmes.md) +* [Code Docs](baseline-basics/code-docs.md) + diff --git a/docs/baseline-basics/code-docs.md b/docs/baseline-basics/code-docs.md new file mode 100644 index 000000000..fa56defc0 --- /dev/null +++ b/docs/baseline-basics/code-docs.md @@ -0,0 +1,2 @@ +# Code Docs + diff --git a/docs/baseline-basics/faq.md b/docs/baseline-basics/faq.md new file mode 100644 index 000000000..bd78d5394 --- /dev/null +++ b/docs/baseline-basics/faq.md @@ -0,0 +1,16 @@ +# FAQ + +Here is the FAQ + +## General Questions + + + +## The Skeptical Voice + +There is great utility in letting negative thoughts have a voice, so long as we don't leave them there. Here are a few "but that won't work" thoughts that we can address as a community to say, "but it would work if..." + + + + + diff --git a/docs/baseline-basics/glossary.md b/docs/baseline-basics/glossary.md new file mode 100644 index 000000000..9bc37d5ed --- /dev/null +++ b/docs/baseline-basics/glossary.md @@ -0,0 +1,42 @@ +# Glossary + +## Baseline Protocol + +A set of components and procedures that allows separate systems of record to maintain record consistency and workflow integrity by using the public Ethereum Mainnet as a common frame of reference \(CFR\). + +## **Mainnet** + +The Mainnet is an always-on state machine that is maintained as a public good in such a way that it maximizes the resistance to an individual or group to gain control, lock out users from valid functions, or change history. The Mainnet is capitalized to emphasize its relationship to the Internet. + +Used without capitalization to distinguish a public production network from public testnets. For example, the Ethereum mainnet vs. its testnets, such as Ropsten. + +## Middleware + +There are many forms of middleware. We use the term in the context of the Baseline Protocol in a particular way. Systems of record maintained by legally separate entities require a common frame of reference in order to run business process integration across them. Flow control, ensuring that two processes don't run inappropriately against the same shared state, terminating the back and forth of the [two generals problem](https://en.wikipedia.org/wiki/Two_Generals%27_Problem), non-repudiation, etc. In this context, the protocol is primarily about loose-coupling architecture in the transaction-processing middleware \(TPM\) area. It is not necessarily about schema translators, though a typical system would very likely run CRUD access between a baseline server and a system of record through translation services in a traditional Enterprise Service Bus \(ESB\). Unlike some RPC middleware, the Baseline Protocol is asynchronous, though it is certainly about passing parameters between functions running on two or more remote machines...and ensuring consistency between them. + +## Atomic Compartmentalization + +Even counterparties to the same business-to-business Workflow typically must not have access to -- or even awareness of -- processes that they are not directly involved in. + +## Workflow + +lorem ipsum + +## Step + +lorem ipsum + +## Task + +lorem ipsum + +## Workgroup + +lorem ipsum + +## CodeBook => Package + +During the Radish34 project, the notion of a shared "codebook" was often discussed. This is ... + + + diff --git a/docs/baseline-basics/key-github-folder-readmes.md b/docs/baseline-basics/key-github-folder-readmes.md new file mode 100644 index 000000000..27afe1872 --- /dev/null +++ b/docs/baseline-basics/key-github-folder-readmes.md @@ -0,0 +1,2 @@ +# Key GitHub Folder Readme's + diff --git a/docs/baseline-protocol/community/README.md b/docs/baseline-protocol/community/README.md new file mode 100644 index 000000000..62fa4cc5a --- /dev/null +++ b/docs/baseline-protocol/community/README.md @@ -0,0 +1,61 @@ +# Open Source Community + +The Baseline Protocol initiative was [announced](https://consensys.net/blog/press-release/ey-and-consensys-announce-formation-of-baseline-protocol-initiative-to-make-ethereum-mainnet-safe-and-effective-for-enterprises/) on March 4, 2020 and launched as an [OASIS](https://oasis-open-projects.org/) open source project on \[ March X, 2020 \], supported by fourteen founding companies. The initiative is strongly aligned with the Mainnet Working Group, a joint effort of the [Enterprise Ethereum Alliance](https://entethalliance.org) and the [Ethereum Foundation](https://ethereum.org). + +A 2019 project exploring ways to use the public Ethereum network in a procurement use case produced insights that led to the formation of the protocol initiative. The companies that conducted the project -- EY, ConsenSys, and Microsoft -- donated the work as a public domain contribution to the non-profit open standards organization, OASIS under [eCLA](https://www.oasis-open.org/resources/open-repositories/cla/). They were joined on March 4, 2020 by [AMD](https://www.amd.com/en/technologies/blockchain), [ChainLink](https://chain.link/), [Core Convergence](https://www.coreconvergence.us/), [Duke University](https://pratt.duke.edu/), [Envision Blockchain](https://envisionblockchain.com/), [MakerDAO](https://makerdao.com/en/), [Neocova](https://neocova.com/), [Splunk](https://www.splunk.com/), [Unibright](https://unibright.io/), [Provide](https://provide.services/), and [W3BCLOUD](https://www.w3bcloud.com/). + + + +## Contributors Guide + +**Baseline Protocol** is an open-source project that is actively seeking contributions from any willing participants. Here are some guidelines for people that would like to contribute to the project. + +### Submitting an issue + +To help us get a better understanding of the issue you've identified, follow the guidelines in one of our _Issue Templates_. + +### Submitting a pull request + +Follow these steps when submitting a pull request: + +1. Fork the [`github.com/ethereum-oasis/baseline`](https://github.com/ethereu-oasis/baseline) repo into your GitHub account. Read more about forking a repo on Github [here](https://help.github.com/articles/fork-a-repo/). +2. Create a new branch, based on the `master` branch, with a name that concisely describes what you’re working on \(ex. `add-mysql`\). +3. Ensure that your changes do not cause any existing tests to fail. +4. Submit a pull request against the `master` branch. + +## License + +All code in this repo is released under the CC0 1.0 Universal public domain dedication. For the full license text, refer to `license.md`. + + + + + +Contributors Guide + +Communications + +Governance + +OASIS + +eCLA and iCLA + +CC0 + +Patents + +Meetings + +The WORK and how we get it done + +Tools + +How to get involved. Ways to get involved. + +Leadership + +Making community participation pay off for members + + + diff --git a/docs/baseline-protocol/community/community-governance.md b/docs/baseline-protocol/community/community-governance.md new file mode 100644 index 000000000..2159bc36f --- /dev/null +++ b/docs/baseline-protocol/community/community-governance.md @@ -0,0 +1,2 @@ +# Community Governance + diff --git a/docs/baseline-protocol/community/community-tools.md b/docs/baseline-protocol/community/community-tools.md new file mode 100644 index 000000000..54aa4ead6 --- /dev/null +++ b/docs/baseline-protocol/community/community-tools.md @@ -0,0 +1,2 @@ +# Community Tools + diff --git a/docs/baseline-protocol/community/supporting-community-members.md b/docs/baseline-protocol/community/supporting-community-members.md new file mode 100644 index 000000000..b2065888b --- /dev/null +++ b/docs/baseline-protocol/community/supporting-community-members.md @@ -0,0 +1,16 @@ +# Supporting Community Members + +Link to OASIS resources and/or list here + +## Founding Group on March 4, 2020 + +[AMD](https://www.amd.com/en/technologies/blockchain), EY, [ChainLink](https://chain.link/), [Core Convergence](https://www.coreconvergence.us/), ConsenSys, [Duke University](https://pratt.duke.edu/), [Envision Blockchain](https://envisionblockchain.com/), [MakerDAO](https://makerdao.com/en/), Microsoft, [Neocova](https://neocova.com/), [Splunk](https://www.splunk.com/), [Unibright](https://unibright.io/), [Provide](https://provide.services/), and [W3BCLOUD](https://www.w3bcloud.com/). + +## Supporting Group on March 19, 2020 + + + + + + + diff --git a/docs/baseline-protocol/mainnet.md b/docs/baseline-protocol/mainnet.md new file mode 100644 index 000000000..bff1facab --- /dev/null +++ b/docs/baseline-protocol/mainnet.md @@ -0,0 +1,41 @@ +--- +description: >- + Describe the key things the baseline community needs to see improved, + supported, created in order to grow as a protocol, so that enterprises will + use the approach and get used to the Mainnet. +--- + +# Driving Mainnet Evolution + +The Mainnet is a \[ insert copy from the upcoming Medium article \]. + +## Point to Point Messaging + +The Radish34 demo uses Whisper, which comes with standard Geth nodes, to + +## Zokrates Support or Replacement + +While the baseline approach isn't solely about zero knowledge techniques, it uses them to ensure that all parties store the same data in their respective systems of record, execute business rules consistently, and enforce the correctness of Workflow Steps. + +One aspect of this is Zokrates, a domain specific language \(DSL\) for taking logical functions and turning them into the "addition, subtraction, multiplication" math required by zero knowledge proofs. Zokrates is an open source project maintained by \[ \]. From the perspective of the enterprise, it has the disadvantage of being distributed under a \[ \] license, not Apache2 or MIT. + +For enterprises to adopt a DSL like Zokrates as part of their core IT stack, it needs to be GA'd, the problem of the license must be dealt with -- there are a number of ways to handle this -- and the project must be well supported at a level that can give enterprises confidence. + +## Eth2 + +The Baseline Protocol can provide utility for a variety of uses across industries today on the current \[ \] Ethereum. It avoids several of the key issues enterprises have with using "public" Ethereum. + +## Gas Pump Service + + + +## Barriers to Enterprise Adoption of Public Blockchain + +\[List the 10-12 issues and talk about how the baseline protocol was created to avoid most of them and bring the rest within the risk profile of traditional Internet-capable IT systems.\] + +{% file src="../.gitbook/assets/why-i-wont-use-the-mainnet-ten-problems-6.pdf" caption="Why CECIL the CISO Won\'t Use Public Blockchain" %} + + + + + diff --git a/docs/baseline-protocol/performance.md b/docs/baseline-protocol/performance.md new file mode 100644 index 000000000..09bb6554b --- /dev/null +++ b/docs/baseline-protocol/performance.md @@ -0,0 +1,2 @@ +# Performance Stats and Specs + diff --git a/docs/baseline-protocol/process.md b/docs/baseline-protocol/process.md new file mode 100644 index 000000000..b7cc45083 --- /dev/null +++ b/docs/baseline-protocol/process.md @@ -0,0 +1,30 @@ +# Baseline Process + +## Baselining Step-by-Step + + + +#### Local System of Record + +Parties store data in local systems of record \(mongo, oracle, sap,...could even be a private or public blockchain, etc\). A "baseline server" is given CRUD access to this, if the system of record itself is not already "baseline compliant/enabled" \(which we'd hope is typical in future\). + +#### Setting up the Workgroup and Sending Messages to Counterparties + +After setting up a Workgroup on-chain of verified counterparties for a specific Workflow \(which instantiates three on-chain contracts: verifier, orgRegistry, shield\), a Party's baseline server serializes a record to be "baselined" and optionally includes with it a codebook that will govern subsequent workflow steps that either change the state of the record or parameterize part or all of the record into a new function. The codebook could be written in any language, but today, Solidity is convenient. \(And it is important to note that the Radish34 demo does not use a "codebook" in this way, because the workflow it implements is governed by a custom Zokrates circuit labeled "MSA." More on that elsewhere.\) + +The data and codebook are packaged and sent via a point-to-point secret messenger service to one or more selected counterparties, who are also equipped with a baseline-compliant system. They receive the package, deposit the data, store and run the code, digitally sign the output, and send that back to the initiating Party. + +#### Processing for Consistency and Sending the Baseline Proof to the Mainnet + +That initiating Party sends all counterparty-signed messages into a zero knowledge microservice inside the baseline server that uses either a basic "everyone did things the same" zero knowledge circuit or a more advanced, specific one that may, for example, enforce certain "correctness" conditions \(e.g., "I am a volume discount rate table, and I must have no gaps between levels"\). Note: zero knowledge enforcement of "correctness" is more expensive, but techniques being introduced by EY can reduce net expense by 5x or more. Also note that such enforcement is not strictly necessary in cases where counterparties are not worried about the shared code being faulty.\) + +The zk service then sends a commitment \(the "baseline proof" of this workflow step\) in the form of a hash \(plus other material used for verification\) to the shield contract created during Workgroup setup. The shield contract makes a call to the verifier contract, and if the verifier contract returns "true" then the shield contract deposits the hash into the merkel trie contained inside itself. + +#### What's the Use of Putting the Baseline Proof on the Mainnet? + +The key to the utility of the baseline proof being on-chain is that the hash represents shared state \(and of course, tamper resistant shared state\), not just "proof of existence". It is a "state marker" that can, for example, represent the current volume of orders in a procurement agreement. Updates to the state \(e.g., when a new order raises the current volume\) can nullify the previous baseline proof. In this way, it can be used for subsequent calculations to prevent later workflow steps from double-counting, providing deliberately or accidentally erroneous inputs, or changing the business rules. Such actions would result in the subsequent workflow step failing to deposit its baseline proof on-chain, at which point the flow stops, parties are alerted, and corrections can be made. Also the hash can be used as the key in a key-value pair -- or the key in an off-chain value lookup procedure. We put that hash in a shield contract mainly to hide who is doing what to it...and we also get some nice features like merkel root grouping, ordering, etc. + +#### A Word About Tokenization + +Tokenization of assets, and the on-chain transfer of them, can then use the baseline proof as the payload in an ERC721, which can also be done under the shield contract, so that what the world sees is...essentially nothing: "someone sent something to someone...and the something was a nonsense set of characters that only the direct counterparties know is anything at all." Done on a cadence with "chaff" hashes thrown in, and analysis techniques wouldn't be able to get a signal they could use to learn much of anything about the Parties' business activities or relationships. + diff --git a/docs/baseline-protocol/protocol.md b/docs/baseline-protocol/protocol.md new file mode 100644 index 000000000..e39cc48ff --- /dev/null +++ b/docs/baseline-protocol/protocol.md @@ -0,0 +1,28 @@ +# The Baseline Protocol + +The Baseline Protocol is an open source initiative that combines advances in cryptography, messaging, and blockchain to deliver secure and private business processes at low cost via the public Mainnet. The protocol will enable confidential and complex collaboration between enterprises without leaving any sensitive data on-chain. The work is governed by the [Ethereum-Oasis Project](https://github.com/ethereum/oasis-open-project), which is managed by [OASIS](https://oasis-open-projects.org/) and funded by the [Ethereum Foundation](https://ethereum.org/) and the [Enterprise Ethereum Alliance](https://entethalliance.org/). + + + +## Why Baseline Our Systems of Record? + +Businesses spend hundreds of millions of dollars on ERP, CRM and other internal systems of record. Failure to properly synchronize these systems between organizations causes considerable disruption and waste: disputes, lost inventory, inflated capital costs, regulatory actions, and other value leakage. To avoid these problems, systems require a common frame of reference. But only the largest high-volume partnerships can afford the capital expense involved in setting up such integrations. The baseline approach employs the public Ethereum Mainnet as that common frame of reference, because it’s always on, companies can’t be locked out or restricted from using it, and they only need to pay for what they use. + +However, past approaches to blockchain technology have had difficulty meeting the highest standards of privacy, security and performance required by corporate IT departments. Overcoming these issues is the goal of the Baseline Protocol. + +## More Than Privacy + +The protocol will support tokenization and decentralized financial services on the Mainnet in a way that doesn’t reveal corporate assets or activities to unauthorized parties, and it leaves enterprise data safely in traditional systems. Extending the core baseline approach demonstrated in the Radish34 POC to the application of private _and stealthy_ tokens is one of the early items of work for the Baseline Protocol community. + +## Which Mainnet, and Which Version? + +The high level description and specification for a global public Mainnet are \[ here \]. And while it is the point of view of many in the Baseline Protocol community that the Ethereum public network is the likely best candidate to serve the function of being the lowest-level common frame of reference for distributed systems, it should be observed that the requirements, not any particular formulation or named service today, are the essential thing. That said, if there is a platform that better matches these specs today, and is more likely to evolve from a position of critical mass \(achieved by Ethereum at a key historical moment in 2015\) to meet the world's expanding use of it, that platform should really step up now. + +The Baseline Protocol can perform its core tasks on the current public Ethereum network at a rate that is reasonably expected to be sufficient for work in supply chain, B2B contracting, CRM, and other domains that involve coordinating records between legally separate entities. + +Eth2 will further extend the range of applications that baselining can serve at acceptable levels of performance and reliability. The Baseline Protocol community will align closely with Eth2 and work through the EEA Mainnet Working Group to supply the Etherem core developer community with ideas, user stories and requirements to help see Eth2 evolve into a platform well-suited to baselining. + +## Which Systems of Record Can We _Baseline?_ + +It’s hoped that the providers of ERP, CRM and other enterprise systems will optimize their products for the protocol over time, but baselining works without requiring any modification to legacy systems. + diff --git a/docs/baseline-protocol/roadmap.md b/docs/baseline-protocol/roadmap.md new file mode 100644 index 000000000..0ab4d6a19 --- /dev/null +++ b/docs/baseline-protocol/roadmap.md @@ -0,0 +1,8 @@ +--- +description: >- + This page will likely want to become a full Group (or folder within the + Protocol folder) and +--- + +# Roadmap + diff --git a/docs/baseline-protocol/standards.md b/docs/baseline-protocol/standards.md new file mode 100644 index 000000000..eaf54e5fa --- /dev/null +++ b/docs/baseline-protocol/standards.md @@ -0,0 +1,64 @@ +--- +description: >- + The page we use to coordinate, memorialize and publish baseline + specifications. +--- + +# Standards + +Lorem ipsum + +## High Level Context + +### Canonical Use Cases and Patterns + +Requirements, and non-functional requirements in particular, are meaningful only in the context of use. As a protocol designed for wide usage, the baseline pattern begs a set of cases that are well suited it. It's also wise to sketch the boundaries of what constitutes a sensible use of the pattern. That is the intent of this section. + +### Functional Requirements + +## Functional Requirements + + + +## Non-Functional Requirements + + + +## Abstract + +This document, the Baseline Specification, defines the implementation requirements for maintaining data consistency and workflow continuity \(with atomic compartmentalization\) among sets of state machines that are operated by different [Parties](). The Baseline Specification assumes the use of a public Mainnet as the necessary common frame of reference to achieve this, and it uses the public Ethereum [Mainnet ]()as the reference implementation. + +> When two or more machines store data and run business logic in a verified state of consistency, enabled by using the Mainnet as a common frame of reference, then the machines, data and code are said to be _baselined_. + +This specification includes the definition of interfaces to internal and external components, how they are intended to be used, and the minimum standards above which they must perform. + +## **Status of this Document** + +The Baseline Specification is in draft and currently does not have a version number. It is intended for an upcoming proposal to the EEA Mainnet Working Group Specifications Task Force. + +It is expected, at time of writing, that this specification will be released in the second quarter of 2020. + +Send comments to the EEA Mainnet Working Group at https://entethalliance.org/contact/. + +GitHub Issues [https://github.com/ethereum-oasis/baseline](https://github.com/ethereum-oasis/baseline) are preferred for discussion of this specification. + +## Contents + +tbd + +## Introduction + +It is generally understood that state machines, from a simple database to various forms of enterprise systems of record, require a common frame of reference when they need to maintain consistency and continuity with other state machines. The field of distributed systems provides for several patterns that accomplish this, each involving tradeoffs. + +The pattern defined here is predicated on the use of a state machine as a common frame of reference between two or more systems. + +## Conformance + +As well as sections marked as non-normative, all authoring guidelines, diagrams, examples, and notes in this specification are non-normative. Everything else in this specification is normative. + +The key words _MAY_, _MUST_, _MUST NOT_, _SHOULD_, and _SHOULD NOT_ in this document are to be interpreted as described in [BCP 14](https://tools.ietf.org/html/bcp14) \[[RFC2119](https://entethalliance.github.io/client-spec/spec.html#bib-rfc2119)\]\[[RFC8174](https://entethalliance.github.io/client-spec/spec.html#bib-rfc8174)\] when, and only when, they appear in all capitals, as shown here. + +#### 2.1 Experimental Requirements + +This Specification includes requirements and Application Programming Interfaces \(APIs\) that are described as _experimental_. Experimental means that a requirement or API is in early stages of development and might change as feedback is incorporated. Implementors are encouraged to implement these experimental requirements, with the knowledge that requirements in future versions of the Specification are not guaranteed to be compatible with the current version. Please send your comments and feedback on the experimental portions of this Specification to the EEA Technical Steering Committee at [https://entethalliance.org/contact/](https://entethalliance.org/contact/). + diff --git a/docs/baselining/core-banking.md b/docs/baselining/core-banking.md new file mode 100644 index 000000000..f9fed3f20 --- /dev/null +++ b/docs/baselining/core-banking.md @@ -0,0 +1,2 @@ +# Core Banking + diff --git a/docs/baselining/enterprise-middleware.md b/docs/baselining/enterprise-middleware.md new file mode 100644 index 000000000..76b42205c --- /dev/null +++ b/docs/baselining/enterprise-middleware.md @@ -0,0 +1,2 @@ +# Enterprise Middleware + diff --git a/docs/baselining/erp-crm.md b/docs/baselining/erp-crm.md new file mode 100644 index 000000000..b6a806aaa --- /dev/null +++ b/docs/baselining/erp-crm.md @@ -0,0 +1,2 @@ +# ERP & CRM + diff --git a/docs/baselining/scm.md b/docs/baselining/scm.md new file mode 100644 index 000000000..b6d561ba6 --- /dev/null +++ b/docs/baselining/scm.md @@ -0,0 +1,2 @@ +# Supply Chain Management + diff --git a/docs/baselining/your-product.md b/docs/baselining/your-product.md new file mode 100644 index 000000000..83b8b1185 --- /dev/null +++ b/docs/baselining/your-product.md @@ -0,0 +1,12 @@ +# How to 'Baseline' Your Product + +The Baseline Protocol isn't a product or a platform. It's a way for your product, your platform, your service to \[ \]. + +The Baseline Protocol presents significant commercial opportunities for solutions firms, enterprise systems vendors, and Cloud providers. Yorke Rhodes, Principal Program Manager, Blockchain at Microsoft said, “Microsoft Azure has been building production-ready offerings that give our enterprise customers direct access to blockchain technologies up and down the stack. For the Ethereum Mainnet we are imbuing enterprise cloud scale principles in the solution without compromising information security. Baseline is helping to create an opportunity for compelling solutions that can drive new value for enterprises while extending the value of the products our customers and partners have been using for years.” + + + +It’s hoped that the providers of ERP, CRM and other enterprise systems will optimize their products for the protocol over time, but baselining works without requiring any modification to legacy systems. + + + diff --git a/docs/components/baseline-server/README.md b/docs/components/baseline-server/README.md new file mode 100644 index 000000000..5dd82910d --- /dev/null +++ b/docs/components/baseline-server/README.md @@ -0,0 +1,10 @@ +# Baseline Server + +Contains many of the components detailed in this section. + +Installed in the Party's infrastructure on-prem or in Cloud. + + + +Orchestration \(not the same as devops orchestration\) + diff --git a/docs/components/baseline-server/apis.md b/docs/components/baseline-server/apis.md new file mode 100644 index 000000000..38740b96b --- /dev/null +++ b/docs/components/baseline-server/apis.md @@ -0,0 +1,8 @@ +# APIs + +We use GraphQL...so you need to learn that. And then.... + + + + + diff --git a/docs/components/baseline-server/messenger.md b/docs/components/baseline-server/messenger.md new file mode 100644 index 000000000..58a5e0273 --- /dev/null +++ b/docs/components/baseline-server/messenger.md @@ -0,0 +1,18 @@ +# Messenger + +Description of what goes on with the messenger. + +API for messenger?? + +### Radish34 Implementation + +We used Whisper, but bla bla bla. + +Here's where the code is for that. + +### Canonical Implementation + +The Baseline Protocol open source community is helping to build a great bla bla to replace Whisper, and you can help.... + +Here's where you can see the current state of the work on the messenger service. + diff --git a/docs/components/baseline-server/zero-knowledge-service.md b/docs/components/baseline-server/zero-knowledge-service.md new file mode 100644 index 000000000..19a6f52ac --- /dev/null +++ b/docs/components/baseline-server/zero-knowledge-service.md @@ -0,0 +1,24 @@ +# Zero Knowledge Service + +Description of what goes on with the zk service in the Baseline Server + +API for messenger?? + +### Radish34 Implementation + +We used Zokrates, but bla bla bla. + +Here's where the code is for that. + +### Canonical Implementation + +The Baseline Protocol open source community is helping to build ... + +Here's where you can see the current state of the work on the zk service. + + + +## Zero Knowledge Circuits and the Standards Opportunity + +As the Radish34 POC shows, the somewhat more expensive \(if roughly $0.24 per proof is expensive\) process of enforcing the correctness of a code Package + diff --git a/docs/components/on-chain.md b/docs/components/on-chain.md new file mode 100644 index 000000000..848b98a88 --- /dev/null +++ b/docs/components/on-chain.md @@ -0,0 +1,2 @@ +# On-Chain Functions + diff --git a/docs/radish34-demo/README.md b/docs/radish34-demo/README.md new file mode 100644 index 000000000..802d62834 --- /dev/null +++ b/docs/radish34-demo/README.md @@ -0,0 +1,29 @@ +# Welcome + +## Welcome to the Baseline Protocol Community + +The Baseline Protocol initiative was [announced](https://consensys.net/blog/press-release/ey-and-consensys-announce-formation-of-baseline-protocol-initiative-to-make-ethereum-mainnet-safe-and-effective-for-enterprises/) on March 4, 2020 and launched as an [OASIS](https://oasis-open-projects.org/) open source project on \[ March X, 2020 \], supported by fourteen founding companies. More companies joined the effort shortly thereafter and continue to do so. \[Link to full list and roles.\] + +The work of the community is maintained under a public domain license at +[**https://github.com/ethereum-oasis/baseline**](https://github.com/ethereum-oasis/baseline). + +You will find in the Repo the code of a procurement demo called **Radish34**. And separately, there is a folder that will contain the specifications, reference code and other material constituting the **Baseline Protocol**, as the community derives it from the initial Radish34 proof of concept. + +There are lots of opportunities to get informed, get involved, and **get value** out of defining requirements, developing reusable components, and ultimately deploying the Baseline Protocol in your own offerings. + +**Go** [**here**](baseline-protocol/community/) **for details on how to get involved.** + +## The Baseline Protocol + +The Baseline Protocol is an approach to using the public [Mainnet](baseline-basics/glossary.md#mainnet) as a common frame of reference between systems, including traditional corporate systems of record, any kind of database, and even different blockchains or DLTs. It is particularly promising as a way to reduce capital expense and other overheads while increasing operational integrity when automating business processes across multiple companies. + + The approach is designed to appeal to security and performance-minded technology officers. + +You can find all the details on the Baseline Protocol [here](baseline-protocol/protocol.md). + +## The Radish34 Demo + +In 2019, three members of the Baseline Protocol community, EY, ConsenSys and Microsoft, got together to build a proof of concept showing how enterprises could safely and effectively use the public Ethereum network to conduct end-to-end supply chain operations without compromising corporate information security norms and practices. What the team learned from that effort led to the formation of the Baseline Protocol initiative. + +You can find the details on Radish34 [here](radish34-demo/radish34-start.md). + diff --git a/docs/radish34-demo/SUMMARY.md b/docs/radish34-demo/SUMMARY.md new file mode 100644 index 000000000..418e7e878 --- /dev/null +++ b/docs/radish34-demo/SUMMARY.md @@ -0,0 +1,49 @@ +# Table of contents + +* [Welcome](README.md) + +## Radish34 Demo + +* [Radish34 Explained](radish34-demo/radish34.md) +* [Radish34 Interactive Demo](radish34-demo/demo.md) +* [Getting Started with Radish34](radish34-demo/radish34-start.md) +* [Radish34 Workflow](radish34-demo/radish34-workflow.md) +* [Modifying Radish34](radish34-demo/mods.md) +* [From POC to Protocol](radish34-demo/poc-to-protocol.md) + +## Baseline Protocol + +* [The Baseline Protocol](baseline-protocol/protocol.md) +* [Open Source Community](baseline-protocol/community/README.md) + * [Supporting Community Members](baseline-protocol/community/supporting-community-members.md) + * [Community Governance](baseline-protocol/community/community-governance.md) + * [Community Tools](baseline-protocol/community/community-tools.md) +* [Baseline Process](baseline-protocol/process.md) +* [Performance Stats and Specs](baseline-protocol/performance.md) +* [Standards](baseline-protocol/standards.md) +* [Driving Mainnet Evolution](baseline-protocol/mainnet.md) +* [Roadmap](baseline-protocol/roadmap.md) + +## Components + +* [Baseline Server](components/baseline-server/README.md) + * [Messenger](components/baseline-server/messenger.md) + * [Zero Knowledge Service](components/baseline-server/zero-knowledge-service.md) + * [APIs](components/baseline-server/apis.md) +* [On-Chain Functions](components/on-chain.md) + +## Baselining Your Product + +* [How to 'Baseline' Your Product](baselining/your-product.md) +* [Supply Chain Management](baselining/scm.md) +* [ERP & CRM](baselining/erp-crm.md) +* [Core Banking](baselining/core-banking.md) +* [Enterprise Middleware](baselining/enterprise-middleware.md) + +## Baseline Basics + +* [Glossary](baseline-basics/glossary.md) +* [FAQ](baseline-basics/faq.md) +* [Key GitHub Folder Readme's](baseline-basics/key-github-folder-readmes.md) +* [Code Docs](baseline-basics/code-docs.md) + diff --git a/docs/radish34-demo/baseline-basics/code-docs.md b/docs/radish34-demo/baseline-basics/code-docs.md new file mode 100644 index 000000000..fa56defc0 --- /dev/null +++ b/docs/radish34-demo/baseline-basics/code-docs.md @@ -0,0 +1,2 @@ +# Code Docs + diff --git a/docs/radish34-demo/baseline-basics/faq.md b/docs/radish34-demo/baseline-basics/faq.md new file mode 100644 index 000000000..bd78d5394 --- /dev/null +++ b/docs/radish34-demo/baseline-basics/faq.md @@ -0,0 +1,16 @@ +# FAQ + +Here is the FAQ + +## General Questions + + + +## The Skeptical Voice + +There is great utility in letting negative thoughts have a voice, so long as we don't leave them there. Here are a few "but that won't work" thoughts that we can address as a community to say, "but it would work if..." + + + + + diff --git a/docs/radish34-demo/baseline-basics/glossary.md b/docs/radish34-demo/baseline-basics/glossary.md new file mode 100644 index 000000000..9bc37d5ed --- /dev/null +++ b/docs/radish34-demo/baseline-basics/glossary.md @@ -0,0 +1,42 @@ +# Glossary + +## Baseline Protocol + +A set of components and procedures that allows separate systems of record to maintain record consistency and workflow integrity by using the public Ethereum Mainnet as a common frame of reference \(CFR\). + +## **Mainnet** + +The Mainnet is an always-on state machine that is maintained as a public good in such a way that it maximizes the resistance to an individual or group to gain control, lock out users from valid functions, or change history. The Mainnet is capitalized to emphasize its relationship to the Internet. + +Used without capitalization to distinguish a public production network from public testnets. For example, the Ethereum mainnet vs. its testnets, such as Ropsten. + +## Middleware + +There are many forms of middleware. We use the term in the context of the Baseline Protocol in a particular way. Systems of record maintained by legally separate entities require a common frame of reference in order to run business process integration across them. Flow control, ensuring that two processes don't run inappropriately against the same shared state, terminating the back and forth of the [two generals problem](https://en.wikipedia.org/wiki/Two_Generals%27_Problem), non-repudiation, etc. In this context, the protocol is primarily about loose-coupling architecture in the transaction-processing middleware \(TPM\) area. It is not necessarily about schema translators, though a typical system would very likely run CRUD access between a baseline server and a system of record through translation services in a traditional Enterprise Service Bus \(ESB\). Unlike some RPC middleware, the Baseline Protocol is asynchronous, though it is certainly about passing parameters between functions running on two or more remote machines...and ensuring consistency between them. + +## Atomic Compartmentalization + +Even counterparties to the same business-to-business Workflow typically must not have access to -- or even awareness of -- processes that they are not directly involved in. + +## Workflow + +lorem ipsum + +## Step + +lorem ipsum + +## Task + +lorem ipsum + +## Workgroup + +lorem ipsum + +## CodeBook => Package + +During the Radish34 project, the notion of a shared "codebook" was often discussed. This is ... + + + diff --git a/docs/radish34-demo/baseline-basics/key-github-folder-readmes.md b/docs/radish34-demo/baseline-basics/key-github-folder-readmes.md new file mode 100644 index 000000000..27afe1872 --- /dev/null +++ b/docs/radish34-demo/baseline-basics/key-github-folder-readmes.md @@ -0,0 +1,2 @@ +# Key GitHub Folder Readme's + diff --git a/docs/radish34-demo/baseline-protocol/community/README.md b/docs/radish34-demo/baseline-protocol/community/README.md new file mode 100644 index 000000000..62fa4cc5a --- /dev/null +++ b/docs/radish34-demo/baseline-protocol/community/README.md @@ -0,0 +1,61 @@ +# Open Source Community + +The Baseline Protocol initiative was [announced](https://consensys.net/blog/press-release/ey-and-consensys-announce-formation-of-baseline-protocol-initiative-to-make-ethereum-mainnet-safe-and-effective-for-enterprises/) on March 4, 2020 and launched as an [OASIS](https://oasis-open-projects.org/) open source project on \[ March X, 2020 \], supported by fourteen founding companies. The initiative is strongly aligned with the Mainnet Working Group, a joint effort of the [Enterprise Ethereum Alliance](https://entethalliance.org) and the [Ethereum Foundation](https://ethereum.org). + +A 2019 project exploring ways to use the public Ethereum network in a procurement use case produced insights that led to the formation of the protocol initiative. The companies that conducted the project -- EY, ConsenSys, and Microsoft -- donated the work as a public domain contribution to the non-profit open standards organization, OASIS under [eCLA](https://www.oasis-open.org/resources/open-repositories/cla/). They were joined on March 4, 2020 by [AMD](https://www.amd.com/en/technologies/blockchain), [ChainLink](https://chain.link/), [Core Convergence](https://www.coreconvergence.us/), [Duke University](https://pratt.duke.edu/), [Envision Blockchain](https://envisionblockchain.com/), [MakerDAO](https://makerdao.com/en/), [Neocova](https://neocova.com/), [Splunk](https://www.splunk.com/), [Unibright](https://unibright.io/), [Provide](https://provide.services/), and [W3BCLOUD](https://www.w3bcloud.com/). + + + +## Contributors Guide + +**Baseline Protocol** is an open-source project that is actively seeking contributions from any willing participants. Here are some guidelines for people that would like to contribute to the project. + +### Submitting an issue + +To help us get a better understanding of the issue you've identified, follow the guidelines in one of our _Issue Templates_. + +### Submitting a pull request + +Follow these steps when submitting a pull request: + +1. Fork the [`github.com/ethereum-oasis/baseline`](https://github.com/ethereu-oasis/baseline) repo into your GitHub account. Read more about forking a repo on Github [here](https://help.github.com/articles/fork-a-repo/). +2. Create a new branch, based on the `master` branch, with a name that concisely describes what you’re working on \(ex. `add-mysql`\). +3. Ensure that your changes do not cause any existing tests to fail. +4. Submit a pull request against the `master` branch. + +## License + +All code in this repo is released under the CC0 1.0 Universal public domain dedication. For the full license text, refer to `license.md`. + + + + + +Contributors Guide + +Communications + +Governance + +OASIS + +eCLA and iCLA + +CC0 + +Patents + +Meetings + +The WORK and how we get it done + +Tools + +How to get involved. Ways to get involved. + +Leadership + +Making community participation pay off for members + + + diff --git a/docs/radish34-demo/baseline-protocol/community/community-governance.md b/docs/radish34-demo/baseline-protocol/community/community-governance.md new file mode 100644 index 000000000..2159bc36f --- /dev/null +++ b/docs/radish34-demo/baseline-protocol/community/community-governance.md @@ -0,0 +1,2 @@ +# Community Governance + diff --git a/docs/radish34-demo/baseline-protocol/community/community-tools.md b/docs/radish34-demo/baseline-protocol/community/community-tools.md new file mode 100644 index 000000000..54aa4ead6 --- /dev/null +++ b/docs/radish34-demo/baseline-protocol/community/community-tools.md @@ -0,0 +1,2 @@ +# Community Tools + diff --git a/docs/radish34-demo/baseline-protocol/community/supporting-community-members.md b/docs/radish34-demo/baseline-protocol/community/supporting-community-members.md new file mode 100644 index 000000000..b2065888b --- /dev/null +++ b/docs/radish34-demo/baseline-protocol/community/supporting-community-members.md @@ -0,0 +1,16 @@ +# Supporting Community Members + +Link to OASIS resources and/or list here + +## Founding Group on March 4, 2020 + +[AMD](https://www.amd.com/en/technologies/blockchain), EY, [ChainLink](https://chain.link/), [Core Convergence](https://www.coreconvergence.us/), ConsenSys, [Duke University](https://pratt.duke.edu/), [Envision Blockchain](https://envisionblockchain.com/), [MakerDAO](https://makerdao.com/en/), Microsoft, [Neocova](https://neocova.com/), [Splunk](https://www.splunk.com/), [Unibright](https://unibright.io/), [Provide](https://provide.services/), and [W3BCLOUD](https://www.w3bcloud.com/). + +## Supporting Group on March 19, 2020 + + + + + + + diff --git a/docs/radish34-demo/baseline-protocol/mainnet.md b/docs/radish34-demo/baseline-protocol/mainnet.md new file mode 100644 index 000000000..bff1facab --- /dev/null +++ b/docs/radish34-demo/baseline-protocol/mainnet.md @@ -0,0 +1,41 @@ +--- +description: >- + Describe the key things the baseline community needs to see improved, + supported, created in order to grow as a protocol, so that enterprises will + use the approach and get used to the Mainnet. +--- + +# Driving Mainnet Evolution + +The Mainnet is a \[ insert copy from the upcoming Medium article \]. + +## Point to Point Messaging + +The Radish34 demo uses Whisper, which comes with standard Geth nodes, to + +## Zokrates Support or Replacement + +While the baseline approach isn't solely about zero knowledge techniques, it uses them to ensure that all parties store the same data in their respective systems of record, execute business rules consistently, and enforce the correctness of Workflow Steps. + +One aspect of this is Zokrates, a domain specific language \(DSL\) for taking logical functions and turning them into the "addition, subtraction, multiplication" math required by zero knowledge proofs. Zokrates is an open source project maintained by \[ \]. From the perspective of the enterprise, it has the disadvantage of being distributed under a \[ \] license, not Apache2 or MIT. + +For enterprises to adopt a DSL like Zokrates as part of their core IT stack, it needs to be GA'd, the problem of the license must be dealt with -- there are a number of ways to handle this -- and the project must be well supported at a level that can give enterprises confidence. + +## Eth2 + +The Baseline Protocol can provide utility for a variety of uses across industries today on the current \[ \] Ethereum. It avoids several of the key issues enterprises have with using "public" Ethereum. + +## Gas Pump Service + + + +## Barriers to Enterprise Adoption of Public Blockchain + +\[List the 10-12 issues and talk about how the baseline protocol was created to avoid most of them and bring the rest within the risk profile of traditional Internet-capable IT systems.\] + +{% file src="../.gitbook/assets/why-i-wont-use-the-mainnet-ten-problems-6.pdf" caption="Why CECIL the CISO Won\'t Use Public Blockchain" %} + + + + + diff --git a/docs/radish34-demo/baseline-protocol/performance.md b/docs/radish34-demo/baseline-protocol/performance.md new file mode 100644 index 000000000..09bb6554b --- /dev/null +++ b/docs/radish34-demo/baseline-protocol/performance.md @@ -0,0 +1,2 @@ +# Performance Stats and Specs + diff --git a/docs/radish34-demo/baseline-protocol/process.md b/docs/radish34-demo/baseline-protocol/process.md new file mode 100644 index 000000000..b7cc45083 --- /dev/null +++ b/docs/radish34-demo/baseline-protocol/process.md @@ -0,0 +1,30 @@ +# Baseline Process + +## Baselining Step-by-Step + + + +#### Local System of Record + +Parties store data in local systems of record \(mongo, oracle, sap,...could even be a private or public blockchain, etc\). A "baseline server" is given CRUD access to this, if the system of record itself is not already "baseline compliant/enabled" \(which we'd hope is typical in future\). + +#### Setting up the Workgroup and Sending Messages to Counterparties + +After setting up a Workgroup on-chain of verified counterparties for a specific Workflow \(which instantiates three on-chain contracts: verifier, orgRegistry, shield\), a Party's baseline server serializes a record to be "baselined" and optionally includes with it a codebook that will govern subsequent workflow steps that either change the state of the record or parameterize part or all of the record into a new function. The codebook could be written in any language, but today, Solidity is convenient. \(And it is important to note that the Radish34 demo does not use a "codebook" in this way, because the workflow it implements is governed by a custom Zokrates circuit labeled "MSA." More on that elsewhere.\) + +The data and codebook are packaged and sent via a point-to-point secret messenger service to one or more selected counterparties, who are also equipped with a baseline-compliant system. They receive the package, deposit the data, store and run the code, digitally sign the output, and send that back to the initiating Party. + +#### Processing for Consistency and Sending the Baseline Proof to the Mainnet + +That initiating Party sends all counterparty-signed messages into a zero knowledge microservice inside the baseline server that uses either a basic "everyone did things the same" zero knowledge circuit or a more advanced, specific one that may, for example, enforce certain "correctness" conditions \(e.g., "I am a volume discount rate table, and I must have no gaps between levels"\). Note: zero knowledge enforcement of "correctness" is more expensive, but techniques being introduced by EY can reduce net expense by 5x or more. Also note that such enforcement is not strictly necessary in cases where counterparties are not worried about the shared code being faulty.\) + +The zk service then sends a commitment \(the "baseline proof" of this workflow step\) in the form of a hash \(plus other material used for verification\) to the shield contract created during Workgroup setup. The shield contract makes a call to the verifier contract, and if the verifier contract returns "true" then the shield contract deposits the hash into the merkel trie contained inside itself. + +#### What's the Use of Putting the Baseline Proof on the Mainnet? + +The key to the utility of the baseline proof being on-chain is that the hash represents shared state \(and of course, tamper resistant shared state\), not just "proof of existence". It is a "state marker" that can, for example, represent the current volume of orders in a procurement agreement. Updates to the state \(e.g., when a new order raises the current volume\) can nullify the previous baseline proof. In this way, it can be used for subsequent calculations to prevent later workflow steps from double-counting, providing deliberately or accidentally erroneous inputs, or changing the business rules. Such actions would result in the subsequent workflow step failing to deposit its baseline proof on-chain, at which point the flow stops, parties are alerted, and corrections can be made. Also the hash can be used as the key in a key-value pair -- or the key in an off-chain value lookup procedure. We put that hash in a shield contract mainly to hide who is doing what to it...and we also get some nice features like merkel root grouping, ordering, etc. + +#### A Word About Tokenization + +Tokenization of assets, and the on-chain transfer of them, can then use the baseline proof as the payload in an ERC721, which can also be done under the shield contract, so that what the world sees is...essentially nothing: "someone sent something to someone...and the something was a nonsense set of characters that only the direct counterparties know is anything at all." Done on a cadence with "chaff" hashes thrown in, and analysis techniques wouldn't be able to get a signal they could use to learn much of anything about the Parties' business activities or relationships. + diff --git a/docs/radish34-demo/baseline-protocol/protocol.md b/docs/radish34-demo/baseline-protocol/protocol.md new file mode 100644 index 000000000..e39cc48ff --- /dev/null +++ b/docs/radish34-demo/baseline-protocol/protocol.md @@ -0,0 +1,28 @@ +# The Baseline Protocol + +The Baseline Protocol is an open source initiative that combines advances in cryptography, messaging, and blockchain to deliver secure and private business processes at low cost via the public Mainnet. The protocol will enable confidential and complex collaboration between enterprises without leaving any sensitive data on-chain. The work is governed by the [Ethereum-Oasis Project](https://github.com/ethereum/oasis-open-project), which is managed by [OASIS](https://oasis-open-projects.org/) and funded by the [Ethereum Foundation](https://ethereum.org/) and the [Enterprise Ethereum Alliance](https://entethalliance.org/). + + + +## Why Baseline Our Systems of Record? + +Businesses spend hundreds of millions of dollars on ERP, CRM and other internal systems of record. Failure to properly synchronize these systems between organizations causes considerable disruption and waste: disputes, lost inventory, inflated capital costs, regulatory actions, and other value leakage. To avoid these problems, systems require a common frame of reference. But only the largest high-volume partnerships can afford the capital expense involved in setting up such integrations. The baseline approach employs the public Ethereum Mainnet as that common frame of reference, because it’s always on, companies can’t be locked out or restricted from using it, and they only need to pay for what they use. + +However, past approaches to blockchain technology have had difficulty meeting the highest standards of privacy, security and performance required by corporate IT departments. Overcoming these issues is the goal of the Baseline Protocol. + +## More Than Privacy + +The protocol will support tokenization and decentralized financial services on the Mainnet in a way that doesn’t reveal corporate assets or activities to unauthorized parties, and it leaves enterprise data safely in traditional systems. Extending the core baseline approach demonstrated in the Radish34 POC to the application of private _and stealthy_ tokens is one of the early items of work for the Baseline Protocol community. + +## Which Mainnet, and Which Version? + +The high level description and specification for a global public Mainnet are \[ here \]. And while it is the point of view of many in the Baseline Protocol community that the Ethereum public network is the likely best candidate to serve the function of being the lowest-level common frame of reference for distributed systems, it should be observed that the requirements, not any particular formulation or named service today, are the essential thing. That said, if there is a platform that better matches these specs today, and is more likely to evolve from a position of critical mass \(achieved by Ethereum at a key historical moment in 2015\) to meet the world's expanding use of it, that platform should really step up now. + +The Baseline Protocol can perform its core tasks on the current public Ethereum network at a rate that is reasonably expected to be sufficient for work in supply chain, B2B contracting, CRM, and other domains that involve coordinating records between legally separate entities. + +Eth2 will further extend the range of applications that baselining can serve at acceptable levels of performance and reliability. The Baseline Protocol community will align closely with Eth2 and work through the EEA Mainnet Working Group to supply the Etherem core developer community with ideas, user stories and requirements to help see Eth2 evolve into a platform well-suited to baselining. + +## Which Systems of Record Can We _Baseline?_ + +It’s hoped that the providers of ERP, CRM and other enterprise systems will optimize their products for the protocol over time, but baselining works without requiring any modification to legacy systems. + diff --git a/docs/radish34-demo/baseline-protocol/roadmap.md b/docs/radish34-demo/baseline-protocol/roadmap.md new file mode 100644 index 000000000..0ab4d6a19 --- /dev/null +++ b/docs/radish34-demo/baseline-protocol/roadmap.md @@ -0,0 +1,8 @@ +--- +description: >- + This page will likely want to become a full Group (or folder within the + Protocol folder) and +--- + +# Roadmap + diff --git a/docs/radish34-demo/baseline-protocol/standards.md b/docs/radish34-demo/baseline-protocol/standards.md new file mode 100644 index 000000000..eaf54e5fa --- /dev/null +++ b/docs/radish34-demo/baseline-protocol/standards.md @@ -0,0 +1,64 @@ +--- +description: >- + The page we use to coordinate, memorialize and publish baseline + specifications. +--- + +# Standards + +Lorem ipsum + +## High Level Context + +### Canonical Use Cases and Patterns + +Requirements, and non-functional requirements in particular, are meaningful only in the context of use. As a protocol designed for wide usage, the baseline pattern begs a set of cases that are well suited it. It's also wise to sketch the boundaries of what constitutes a sensible use of the pattern. That is the intent of this section. + +### Functional Requirements + +## Functional Requirements + + + +## Non-Functional Requirements + + + +## Abstract + +This document, the Baseline Specification, defines the implementation requirements for maintaining data consistency and workflow continuity \(with atomic compartmentalization\) among sets of state machines that are operated by different [Parties](). The Baseline Specification assumes the use of a public Mainnet as the necessary common frame of reference to achieve this, and it uses the public Ethereum [Mainnet ]()as the reference implementation. + +> When two or more machines store data and run business logic in a verified state of consistency, enabled by using the Mainnet as a common frame of reference, then the machines, data and code are said to be _baselined_. + +This specification includes the definition of interfaces to internal and external components, how they are intended to be used, and the minimum standards above which they must perform. + +## **Status of this Document** + +The Baseline Specification is in draft and currently does not have a version number. It is intended for an upcoming proposal to the EEA Mainnet Working Group Specifications Task Force. + +It is expected, at time of writing, that this specification will be released in the second quarter of 2020. + +Send comments to the EEA Mainnet Working Group at https://entethalliance.org/contact/. + +GitHub Issues [https://github.com/ethereum-oasis/baseline](https://github.com/ethereum-oasis/baseline) are preferred for discussion of this specification. + +## Contents + +tbd + +## Introduction + +It is generally understood that state machines, from a simple database to various forms of enterprise systems of record, require a common frame of reference when they need to maintain consistency and continuity with other state machines. The field of distributed systems provides for several patterns that accomplish this, each involving tradeoffs. + +The pattern defined here is predicated on the use of a state machine as a common frame of reference between two or more systems. + +## Conformance + +As well as sections marked as non-normative, all authoring guidelines, diagrams, examples, and notes in this specification are non-normative. Everything else in this specification is normative. + +The key words _MAY_, _MUST_, _MUST NOT_, _SHOULD_, and _SHOULD NOT_ in this document are to be interpreted as described in [BCP 14](https://tools.ietf.org/html/bcp14) \[[RFC2119](https://entethalliance.github.io/client-spec/spec.html#bib-rfc2119)\]\[[RFC8174](https://entethalliance.github.io/client-spec/spec.html#bib-rfc8174)\] when, and only when, they appear in all capitals, as shown here. + +#### 2.1 Experimental Requirements + +This Specification includes requirements and Application Programming Interfaces \(APIs\) that are described as _experimental_. Experimental means that a requirement or API is in early stages of development and might change as feedback is incorporated. Implementors are encouraged to implement these experimental requirements, with the knowledge that requirements in future versions of the Specification are not guaranteed to be compatible with the current version. Please send your comments and feedback on the experimental portions of this Specification to the EEA Technical Steering Committee at [https://entethalliance.org/contact/](https://entethalliance.org/contact/). + diff --git a/docs/radish34-demo/baselining/core-banking.md b/docs/radish34-demo/baselining/core-banking.md new file mode 100644 index 000000000..f9fed3f20 --- /dev/null +++ b/docs/radish34-demo/baselining/core-banking.md @@ -0,0 +1,2 @@ +# Core Banking + diff --git a/docs/radish34-demo/baselining/enterprise-middleware.md b/docs/radish34-demo/baselining/enterprise-middleware.md new file mode 100644 index 000000000..76b42205c --- /dev/null +++ b/docs/radish34-demo/baselining/enterprise-middleware.md @@ -0,0 +1,2 @@ +# Enterprise Middleware + diff --git a/docs/radish34-demo/baselining/erp-crm.md b/docs/radish34-demo/baselining/erp-crm.md new file mode 100644 index 000000000..b6a806aaa --- /dev/null +++ b/docs/radish34-demo/baselining/erp-crm.md @@ -0,0 +1,2 @@ +# ERP & CRM + diff --git a/docs/radish34-demo/baselining/scm.md b/docs/radish34-demo/baselining/scm.md new file mode 100644 index 000000000..b6d561ba6 --- /dev/null +++ b/docs/radish34-demo/baselining/scm.md @@ -0,0 +1,2 @@ +# Supply Chain Management + diff --git a/docs/radish34-demo/baselining/your-product.md b/docs/radish34-demo/baselining/your-product.md new file mode 100644 index 000000000..83b8b1185 --- /dev/null +++ b/docs/radish34-demo/baselining/your-product.md @@ -0,0 +1,12 @@ +# How to 'Baseline' Your Product + +The Baseline Protocol isn't a product or a platform. It's a way for your product, your platform, your service to \[ \]. + +The Baseline Protocol presents significant commercial opportunities for solutions firms, enterprise systems vendors, and Cloud providers. Yorke Rhodes, Principal Program Manager, Blockchain at Microsoft said, “Microsoft Azure has been building production-ready offerings that give our enterprise customers direct access to blockchain technologies up and down the stack. For the Ethereum Mainnet we are imbuing enterprise cloud scale principles in the solution without compromising information security. Baseline is helping to create an opportunity for compelling solutions that can drive new value for enterprises while extending the value of the products our customers and partners have been using for years.” + + + +It’s hoped that the providers of ERP, CRM and other enterprise systems will optimize their products for the protocol over time, but baselining works without requiring any modification to legacy systems. + + + diff --git a/docs/radish34-demo/components/baseline-server/README.md b/docs/radish34-demo/components/baseline-server/README.md new file mode 100644 index 000000000..5dd82910d --- /dev/null +++ b/docs/radish34-demo/components/baseline-server/README.md @@ -0,0 +1,10 @@ +# Baseline Server + +Contains many of the components detailed in this section. + +Installed in the Party's infrastructure on-prem or in Cloud. + + + +Orchestration \(not the same as devops orchestration\) + diff --git a/docs/radish34-demo/components/baseline-server/apis.md b/docs/radish34-demo/components/baseline-server/apis.md new file mode 100644 index 000000000..38740b96b --- /dev/null +++ b/docs/radish34-demo/components/baseline-server/apis.md @@ -0,0 +1,8 @@ +# APIs + +We use GraphQL...so you need to learn that. And then.... + + + + + diff --git a/docs/radish34-demo/components/baseline-server/messenger.md b/docs/radish34-demo/components/baseline-server/messenger.md new file mode 100644 index 000000000..58a5e0273 --- /dev/null +++ b/docs/radish34-demo/components/baseline-server/messenger.md @@ -0,0 +1,18 @@ +# Messenger + +Description of what goes on with the messenger. + +API for messenger?? + +### Radish34 Implementation + +We used Whisper, but bla bla bla. + +Here's where the code is for that. + +### Canonical Implementation + +The Baseline Protocol open source community is helping to build a great bla bla to replace Whisper, and you can help.... + +Here's where you can see the current state of the work on the messenger service. + diff --git a/docs/radish34-demo/components/baseline-server/zero-knowledge-service.md b/docs/radish34-demo/components/baseline-server/zero-knowledge-service.md new file mode 100644 index 000000000..19a6f52ac --- /dev/null +++ b/docs/radish34-demo/components/baseline-server/zero-knowledge-service.md @@ -0,0 +1,24 @@ +# Zero Knowledge Service + +Description of what goes on with the zk service in the Baseline Server + +API for messenger?? + +### Radish34 Implementation + +We used Zokrates, but bla bla bla. + +Here's where the code is for that. + +### Canonical Implementation + +The Baseline Protocol open source community is helping to build ... + +Here's where you can see the current state of the work on the zk service. + + + +## Zero Knowledge Circuits and the Standards Opportunity + +As the Radish34 POC shows, the somewhat more expensive \(if roughly $0.24 per proof is expensive\) process of enforcing the correctness of a code Package + diff --git a/docs/radish34-demo/components/on-chain.md b/docs/radish34-demo/components/on-chain.md new file mode 100644 index 000000000..848b98a88 --- /dev/null +++ b/docs/radish34-demo/components/on-chain.md @@ -0,0 +1,2 @@ +# On-Chain Functions + diff --git a/docs/radish34-demo/demo.md b/docs/radish34-demo/demo.md new file mode 100644 index 000000000..9725f5172 --- /dev/null +++ b/docs/radish34-demo/demo.md @@ -0,0 +1,13 @@ +--- +description: >- + page to contain the Figma demo and links to setting up the actual demo. note: + hoping to include TJ's more extensive Figma visualization of the complete + flow. +--- + +# Radish34 Interactive Demo + +You can build and run your own functioning instance of the Radish34 proof of concept [here](radish34.md). But if you want to see what it might be like for a group of companies to use the Baseline Protocol in a wider set of supply chain operations, here is an interactive visualization: + +\[embed/link figma\] + diff --git a/docs/radish34-demo/getting-started-with-radish34.md b/docs/radish34-demo/getting-started-with-radish34.md new file mode 100644 index 000000000..e415aa354 --- /dev/null +++ b/docs/radish34-demo/getting-started-with-radish34.md @@ -0,0 +1,8 @@ +--- +description: >- + Description of what this demo does, what it doesn't do, what you can + extrapolate from it...why it's here...how it works. +--- + +# Getting Started with Radish34 + diff --git a/docs/radish34-demo/mods.md b/docs/radish34-demo/mods.md new file mode 100644 index 000000000..b0ff4428a --- /dev/null +++ b/docs/radish34-demo/mods.md @@ -0,0 +1,16 @@ +# Modifying Radish34 + +The Radish34 functional proof-of-concept \(POC\) demonstrates only a few key steps in a procurement process. The UI shows the setup of a [Workgroup](../baseline-basics/glossary.md#workgroup) and a [Workflow](../baseline-basics/glossary.md#workflow) that includes an RFP, Bids, a signed MSA, and POs to be calculated against the terms of the MSA. Each of these is called a Workflow Step, and the current version of Radish34 focuses heavily on the MSA and PO steps to demonstrate the full capability of on-chain and off-chain components of the Baseline Protocol. + +But what if you wanted to add tokenized inventory, shipping & logistics, invoicing, or trade finance functions like invoice factoring? + +As a POC, it is certianly true that the [code](https://github.com/ethereum-oasis/baseline) of Radish34 still needs to add a layer of abstraction to take it to the next level as production-capable code for supply chain applications. This would be a good place for community members to chip in, irrespective of the additional generalization effort of going from [POC to Protocol](poc-to-protocol.md). + +An example of this is the code for the MSA, which you can find in the repo \[ here \]. Strictly speaking, the MSA is an instance of a Workflow [Step](../baseline-basics/glossary.md#step). A Step can implement a number of Tasks. The MSA implements, for example, a specialized zero knowledge circuit specially written to enforce the correctness of the business logic involved in calculating a PO’s correct volume discount. It also implements general Tasks, such as \[ Patrick \], messaging, digital signatures, and the process of generating, validating and storing the proof \(in this case, a state marker representing the rate table and the total number of units ordered\), and nullifying a previous proof when the state has changed. + +So how would you take this code and make it work for something we haven’t written yet into this POC? How would you make an an Invoice Step, for example? + +## Baselining an Invoice + +\[ Brian, Kartheek, Sam, Pat, Lucas — let’s describe in loose terms what parts of the code a skilled developer would use to take what we have and mod it for a different Step, like an Invoice...though we could choose another Step, like the Widget tracker. We can talk about what is here, what can be just used as-is, what would need modification, what would need “heart surgery” and what core concepts or components are yet to be even sketched that would be needed to make that new Step work. \] + diff --git a/docs/radish34-demo/poc-to-protocol.md b/docs/radish34-demo/poc-to-protocol.md new file mode 100644 index 000000000..e67f74b31 --- /dev/null +++ b/docs/radish34-demo/poc-to-protocol.md @@ -0,0 +1,24 @@ +--- +description: Describe how we are going to move from the demo code to the protocol code +--- + +# From POC to Protocol + +## + +### Abstraction + +Even if Radish34 were the only application we wanted to build, the code still requires abstraction. For example, the components that provide the MSA step in the Radish34 Workflow is named MSA and tailored specifically to that Workflow Step. Even without a generalized protocol, this reusable package should be defined one abstraction up as "Step" or "Task" and then instantiated for each instance: RFP, Bid, MSA, PO, Shipment, Invoice, etc. + +### Generalization + + + + + +### Currently observed performance metrics + +MSA Takes x minutes, costs this much..... + + + diff --git a/docs/radish34-demo/radish34-start.md b/docs/radish34-demo/radish34-start.md new file mode 100644 index 000000000..66a1cef71 --- /dev/null +++ b/docs/radish34-demo/radish34-start.md @@ -0,0 +1,220 @@ +--- +description: 'After migration to /baseline, point this file to /radish34 readme.md' +--- + +# Getting Started with Radish34 + +If you’ve read the [Radish34 Explained](radish34.md) section or played with the [user experience demo](demo.md) and now want to build and run the POC yourself, you’re in the right place. + +### Prerequisites + +1. Install [Docker for Mac](https://www.docker.com/docker-mac), or [Docker for Windows](https://www.docker.com/docker-windows) + * It's recommended that you allocate 12GB of RAM in Docker \(see 'Troubleshooting'\). +2. Install and start [dotdocker](https://github.com/aj-may/dotdocker) + + `dotdocker start` + +3. In order to use [Timber](https://github.com/EYBlockchain/timber), you will need to be logged into the Github package registry. To do this, you will need to [generate a Github Personal Access Token](https://help.github.com/en/github/authenticating-to-github/creating-a-personal-access-token-for-the-command-line). Make sure that the token you generate has at minimum `read: packages` and `repo` permissions. + +After you've done that, log in to the Github package registry by running + +`docker login -u -p docker.pkg.github.com` + +### Development/Test Environment + +1. As part of the development environment, we assume a procurement use-case with three users: \(1\) buyer and \(2\) supplier organizations. +2. Run `npm ci && npm run postinstall`. \*\* This takes about 6 minutes to clean install npm packages in root and all sub directories \*\* +3. Run `docker-compose build` to create the latest versions of the docker containers. \*\* Only do this the first time or when service source code is changed \*\*. \*\* This takes about 40 minutes for a fresh build \*\* +4. Run `npm run setup` to perform zk-SNARK trusted setups for the circuits that are contained in the `/zkp/circuits`. \*\* This takes about 5-10 minutes to complete \*\* Example logs: + +\[ Need to fix the code segments below...maybe....at least it scrolls. \] + +```text +*** Starting zokrates container *** +radish-34_radish-zkp-watch_1 is up-to-date +mongo-buyer is up-to-date +radish-34_radish-zkp_1 is up-to-date + +*** Running setup for createMSA *** +{"verificationKey":{"H":[["0x28cbb3929742ba7f874746fb890540017813ef404ae38c7073bf030be3577194","0x0974c59917efe8f2aa0049ded97d3103a300ca864c122b1d4c13197d2548c550"],["0x205078b5f99a3e041d75a8d3eb0cafe24da9649271275861bafbfa074a946f68","0x23c46a91322035df6f503929d00efc95ab970633c0b9cdd521f26831137ce398"]],"Galpha":["0x030cb162dc5bb2112b625de1cff121dc0e867068f496d3862d8d27e144c13c64","0x143e8abb0bcdb24417a01bc581bff336c2539f9b48c39c5b1447a5e4ca8a79c6"],"Hbeta":[["0x2e1a7b77ee31735d5b8dd25a032ea8bfda27c5905bec6d3ee3d0b01169ed7961","0x149b8fb268d495e15e642da2bd172791fd65bf9cdc49da8f1b16c34635ede869"],["0x2ccd66691257c87cdbd98efad37a0f60422a1e4d73dd2c18ebd87fc8522db9be","0x15437cb448e5bf0cf3067e2de941cf4ed73f6f732dac9cf19f0e89555f6d7a36"]],"Ggamma":["0x0c132ee8e18b7dd37a7332f6138d2c30826910652de0df3d188fe3597da2208d","0x2cced0ec0c467fac9b6774739b696d2fd1074cdef99da52c986838cea132bbe8"],"Hgamma":[["0x060ae04d4f50d8f01ca4fad8a29fd6d0d8f6eae762c1345bbebab3d8ca8cd993","0x0bb22b3de71c381a8bbd3b40633f3c2db119b75f5874a28bf4f221bae4fa9d73"],["0x13aa539b007374ee850da69ee1b91869ca4d64337a41e2cf4eaef844a28c251c","0x299c36c9cc3aab3c7df10bff199bb66c6d954dfa4ba30b5b33705a4b5bf0708e"]],"query":[["0x2ea45bf055ff829b0348d5c2b0619371de5835c0e28dd63c3d806aa06e3890f5","0x2aa391d2cb16b76693d1dfbbe0272861e38e7cf457f38d0f93d5a7751f3fa7a0"],["0x18c4fa762ba68bdaabb02658ad113cc22333107d73ebc0f508e4c4f2f5a3aaf2","0x075062f8a367e48fc22c99752a8e0211148462c8dab0c87d4c12c85545594e07"]]}} +*** Running setup for createPO *** +{"verificationKey":{"H":[["0x2d5f6d4b7d13b5cebd8d6cece9dbce5ecb04d3ea80217e0426c2b1d72c2d972d","0x02ff4a4667c3fead0b270277aba0fef1a8f2e94e85b160d19385c089ac7cf501"],["0x25ddb0f3266fc2b2efefa6247f24355a327353f6ccfb5ca9fb5ab1352370a21b","0x1c078f4b5447ef774133731e301b43a9c8657123409333efffa74486a86fb47f"]],"Galpha":["0x0d36fc5d69ce3f50ec40bb9d3540fb1d898a2f91d48932bf55cfcb304af635e3","0x1a555461b3ac218af5fca356d75b9d0eecce6bb8d44aab275141e1a980077a67"],"Hbeta":[["0x29a47d9266d3a915ba517cd2d099ef4872c568d86d69c63ff5fa55aa7a5f6284","0x1125edf840c07eda41a962f71f1e0d8b4c0052587c6b6918ebb3a267c43b6255"],["0x2d15aefb7f2a3374e28671f5b4b5dc1db80660656b16fd81953a6104a95b61ef","0x2e43d6f090a7402b948824568e69a956646a8ddc79eba4bfad65da4863663ce5"]],"Ggamma":["0x11cf0010dc05657a0933a3366efab90a055ef76c926af3c94cd79df0daace624","0x138c005e154787838b851afc869be363e089b2e3786c197c1a7a7f8023e2adcf"],"Hgamma":[["0x267470583b8333a4c8b81331d12d6badfd49c416810fd23006ec393f812c8a56","0x14321eed994c76846d2b8b532e7995d3cb76c022ab05af426a99e98a53076779"],["0x0cfcd3abdf0119481374bf209c71f7afcd8920b85de0e95294933ddd3c16c92a","0x23871104deb8a7c03efaf1ede048dd9f968b4602ea7f824a5c8d4aaa1e6f4143"]],"query":[["0x1a7251f3ac3930802d03eae0f4d8187a62bcf752b33cedd98defe74ddc07cd8f","0x06a13bbc659fae79a8e0ab7fa474d4ae451d42633116e42e17334ee21a847fc5"],["0x26620d77c65980fb18256ee17bc0e80adc30ddb4c54cd61154432d713889ea33","0x237af6ad935a45192f8a279e3543bca9b04aa547d16501c3c164c9ef38ad59c0"]]}} +*** Setups complete *** +``` + +1. Run `npm run build` to compile the smart contracts in `contracts` to JSON files \(containing ABI and Bytecode key value pairs\) in the `artifacts` folder needed for deployment. \*\* This takes less than 15 seconds to run \*\* +2. Make sure you download and have the following files stored in your `/config` directory: `config-buyer.json`, `config-supplier1.json`, `config-supplier2.json`. +3. Run `npm run deploy` to deploy the smart contracts. \*\* This takes about 2 minutes \*\* + + * This docker container first deploys both the Registry contract and the OrgRegistry contract. + * Then it registers \(1\) Buyer and \(2\) Supplier organizations. The corresponding `/config/config-${role}.json` files are updated with the newly deployed contract addresses. + * The goal of deployment is to initialize the Radish34 system by pre-registering a buyer and 2 suppliers with an `OrgRegistry` smart contract, which holds the organization metadata to thus enable any ongoing procurement operations. + * Essentially the deployment is based on deploying an `ERC1820Registry` client called the `Registrar`, followed by registering an interface for `OrgRegistry` with the `ERC1820Registry`, then registering the roles of the buyer and supplier with the `OrgRegistry` + * In addition, the contracts that are necessary for privacy management, `Shield` and `Verifier` contract are deployed to the network + * Any changes to the config files are updated in the individual db instances `mongo-${role}` Example logs: + + ```text + > docker-compose run --rm radish-deploy sh deploy.sh + Patiently waiting 10 seconds for ganache container to init ... + Checking for ganache ... + ✅ ERC1820Registry deployed: 0x448de9B34ac4DD0901DCc3f2fF1a31822B51a397 + ✅ OrgRegistry deployed: 0x31088fd0eede771d5bda1558e06a666Cd9BF110c + ✅ BN256G2 library deployed: 0x8f17969A8dc9cbAe2EB98541F33c7c396f615241 + ✅ Verifier deployed: 0xDf3C747B74CeFe4ffEa5baa2D0eAFE2B0F86A8F3 + ✅ Shield deployed: 0x7370f1C710F3af6f28Be19ed99e0ed8f1B59b1CB + ✅ Assigned the deployer as the manager for OrgRegistry. TxHash: 0x1689ac60fba5c25b5559e0fbca066c4063a433dec552adc9208977e161f05852 + ✅ Set OrgRegistry as Interface Implementer for deployer. TxHash: 0x52660020dad54f7177896e16ba9e6956aa4c046e59c2bf92b53db06d387802a2 + ✅ Retrieved all Whisper Identity for each user + ✅ Registered buyer in the OrgRegistry with tx hash: 0x77e39fc3398e405caaf895a2ea29966423dc8f01f0bffdc335579d0865837415 + ✅ Registered supplier1 in the OrgRegistry with tx hash: 0xefc1142c39f95766d245eab0d7dc4fe0860fded16c4531d529e6636136888123 + ✅ Registered supplier2 in the OrgRegistry with tx hash: 0x354c5a0745690f5c68a33f481e8c89cdbd103b24e549839374f589dc1b15c49c + ✅ getOrg: 3 Organizations have successfully been set up! + { + address: '0xB5630a5a119b0EAb4471F5f2d3632e996bf95d41', + name: 'Org1', + role: 1, + messagingKey: '0x04660083ec950731f412cb96cca49f55d443c370ed8e2d3d938769ce4b200ffc0e9597001574b165b4030235331de26f49b1c4ea1c03d902d2ba75302393fa050e', + zkpPublicKey: '0x21864a8a3f24dad163d716f77823dd849043481c7ae683a592a02080e20c1965' + } + { + address: '0x5ACcdCCE3E60BD98Af2dc48aaf9D1E35E7EC8B5f', + name: 'Supplier 1', + role: 2, + messagingKey: '0x047087e00ac5d68d752caab75c7107329f354a52a9e220d83a0bd14b9a76dbcc359a7e604548a48f0e9a45f5f0d9a31a2b9fa005ec5fd0cce49ccb229a6a28eaff', + zkpPublicKey: '0x1513500b81d1cc3ecb32c0a3af17756b99e23f6edff51fcd5b4b4793ea2d0387' + } + { + address: '0x3f7eB8a7d140366423e9551e9532F4bf1A304C65', + name: 'Supplier 2', + role: 2, + messagingKey: '0x04fa022574ff337d4e5ab9e529a9dc379c8e12fb9fb424c7c400de9ba42d9e24d9d37fb6cd88c182f9908a1451765d98c561006df44a637b9b72551f9f43dc73a7', + zkpPublicKey: '0x03366face983056ea73ff840eee1d8786cf72b0e14a8e44bac13e178ac3cebd5' + } + Updated settings for buyer to include: { + addresses: { + ERC1820Registry: '0x448de9B34ac4DD0901DCc3f2fF1a31822B51a397', + OrgRegistry: '0x31088fd0eede771d5bda1558e06a666Cd9BF110c', + BN256G2: '0x8f17969A8dc9cbAe2EB98541F33c7c396f615241', + Verifier: '0xDf3C747B74CeFe4ffEa5baa2D0eAFE2B0F86A8F3', + Shield: '0x7370f1C710F3af6f28Be19ed99e0ed8f1B59b1CB' + }, + organization: { + messengerKey: '0x04660083ec950731f412cb96cca49f55d443c370ed8e2d3d938769ce4b200ffc0e9597001574b165b4030235331de26f49b1c4ea1c03d902d2ba75302393fa050e', + name: 'Org1', + role: 1, + zkpPublicKey: '0x21864a8a3f24dad163d716f77823dd849043481c7ae683a592a02080e20c1965', + zkpPrivateKey: '0x29ae268c4e58726d63fb5b0dae75e8d70f77519d12063f1a8fa9ebec085e533d' + } + } + Updated settings for supplier1 to include: { + addresses: { + ERC1820Registry: '0x448de9B34ac4DD0901DCc3f2fF1a31822B51a397', + OrgRegistry: '0x31088fd0eede771d5bda1558e06a666Cd9BF110c', + BN256G2: '0x8f17969A8dc9cbAe2EB98541F33c7c396f615241', + Verifier: '0xDf3C747B74CeFe4ffEa5baa2D0eAFE2B0F86A8F3', + Shield: '0x7370f1C710F3af6f28Be19ed99e0ed8f1B59b1CB' + }, + organization: { + messengerKey: '0x047087e00ac5d68d752caab75c7107329f354a52a9e220d83a0bd14b9a76dbcc359a7e604548a48f0e9a45f5f0d9a31a2b9fa005ec5fd0cce49ccb229a6a28eaff', + name: 'Supplier 1', + role: 2, + zkpPublicKey: '0x1513500b81d1cc3ecb32c0a3af17756b99e23f6edff51fcd5b4b4793ea2d0387', + zkpPrivateKey: '0xb084bd09eea9612b5790a73d9f88bdf644d56194a410b08f6d2ae09d5fccbfe' + } + } + Updated settings for supplier2 to include: { + addresses: { + ERC1820Registry: '0x448de9B34ac4DD0901DCc3f2fF1a31822B51a397', + OrgRegistry: '0x31088fd0eede771d5bda1558e06a666Cd9BF110c', + BN256G2: '0x8f17969A8dc9cbAe2EB98541F33c7c396f615241', + Verifier: '0xDf3C747B74CeFe4ffEa5baa2D0eAFE2B0F86A8F3', + Shield: '0x7370f1C710F3af6f28Be19ed99e0ed8f1B59b1CB' + }, + organization: { + messengerKey: '0x04fa022574ff337d4e5ab9e529a9dc379c8e12fb9fb424c7c400de9ba42d9e24d9d37fb6cd88c182f9908a1451765d98c561006df44a637b9b72551f9f43dc73a7', + name: 'Supplier 2', + role: 2, + zkpPublicKey: '0x03366face983056ea73ff840eee1d8786cf72b0e14a8e44bac13e178ac3cebd5', + zkpPrivateKey: '0x111bc1d832ba0ea6804f031c6f0ec9550f4d2b55666c30d7b4cf532b22a45f25' + } + } + + Calling /vk(createMSA) + + Calling /vk(createPO) + Registering vk 18452423262158563026882841675284148407764318157675563070471972217739237880212,4277133668186723831235654096540406807435824845570986335989907942141598418256,14616192035444969003150436321512501628878979352937787850238113590938741010280,16177987224694778648394767874211717524305731735983237888308452790599874831256,1379364984911720626136072585337712693683924249341665513273559476871662484580,9156758973430525230183885922794684348950481245148957809524672239190422485446,20853181206633468719848310853413619676027324855469494224326295594157686487393,9321110026344006065486305790542153704131355025977797475517112642918390032489,20264675796796795709830270740195303883800970394987912963744700332878435563966,9617809250603145165440088584290061628278893233855154595575290228291958307382,5461648036022214211143369568016219712491248347178880605917470283234837405837,20267177760088363139518624979647286695343598308760404799328244803079201012712,2733093637597886369210205749822745181805572745097005975696082802272958732691,5290238555934889435703756934523226089301002621758403523617432452706499992947,8894885147880399898314634619246753739957540450191160311306953007213291775260,18820833068779199149030979951558447374152704724892152325431094507233231270030,21096788491815322535016425843114301240063117688587680689790922945196138729717,19286142148252889888118610521758324658736978834444902653793263786010395781024,11203539013152302732163359604934774718305715328124835655309460996779078298354,3308220779682536962176390239229157209211243587623820368961890312836741680647 against txTypeEnumUint 0 + ✅ Uploaded verification key for createMSA. TxHash: 0x8967d201803467a818c332905d355050bdf7b698917276627d67823bbd2caa02 + Registering vk 20522682982920878954594520278759298871294760675964764796460214555440489273133,1355684326038743620561541607821672442687007980490919311671186212947595425025,17127269861568797267541709762677184095889927147335292037601863383053224682011,12678116670384323664497410100274034092546770156661828399087071137612145079423,5977218531577562924693023811035666278242250033114290451697255598040978699747,11910898444400756692554841800903798844456503196287448234655645015860119566951,18835456375812065002333445288481415807355768040920100504693284277397399495300,7756334174082466369268236005053638756106862232385752031594640362579538174549,20392389658810310087927513615796829306670593413799627867169141543694610686447,20926253247509591845191645741470653974460714522358362695848905641897492888805,8055056222854724947534229729362938900393380623061729822034177100602552411684,8841305248627005490684435068554866336037281409872841166256499053913855667663,17393617880011961063722177156687167597785515650731345358017594453156801841750,9134812782946246477382749501756521033191131648169155399660755523243809924985,5874460545438495447360509618099907294916375005598494526462684352297251031338,16069591515142379111204703045096550819428436131949339386521861704948485407043,11962120239408032609083758269415656400682277263025948496448227609373701557647,2998751751135582910454267866182036306022286179637831158023751086688017088453,17361132210337219581729837662000018081706586352038127359850835578169064024627,16048207551507412141663801408246194149328805387019287537086161573266055846336 against txTypeEnumUint 1 + ✅ Uploaded verification key for createPO. TxHash: 0x1cc5f0e43b810394e655cafc889b1191d5a874d1d3847269182662df13479e9f + ----------------- Completed ----------------- + Please restart the radish-apis for the config to take effect + ``` + +4. run `docker-compose up -d` + + * This will start all `radish` containers + * Wait about 10 seconds to give containers time to complete their initialization routines + * Run `docker-compose logs -f {SERVICE_NAME}` to check the logs of specific containers. Key ones to watch are: `radish-api-{role}` and `radish34-ui` Example Logs: + + ```text + radish-api-buyer | Connected to db + radish-api-buyer | Mongoose connected to db + radish-api-buyer | Loading config file ... + radish-api-buyer | 🚀 Internal REST-Express server listening at http://localhost:8101 + radish-api-buyer | Loading network http://ganache:8545... + radish-api-buyer | Connected to network: { chainId: 333, name: 'unknown' } + radish-api-buyer | Whisper key: 0x0453f6d033725be702e7e00a0056a62caa5c3700796899dbc69d2001a1dae1717b65d30ed3e7e607f8f00bfc69f09c0e22ef69fcee7cd6980434de34863c21491d + radish-api-buyer | Loading wallet with address 0xB5630a5a119b0EAb4471F5f2d3632e996bf95d41 + radish-api-buyer | Wallet balance: 999.89182446 + radish-api-buyer | Your organization has already been registered with the registry + radish-api-buyer | All systems go. + radish-api-buyer | 🏥 Healthcheck Status: ready + radish-api-buyer | 🚀 Server ready at http://localhost:8001/graphql + radish-api-buyer | 🚀 Subscriptions ready at ws://localhost:8001/graphql` + ``` + +5. Run integration tests: `npm run test` +6. Within about 5 minutes, UI is loaded on `http://radish34-ui.docker` on your local browser + +### Troubleshooting + +1. If you get errors during the `npm ci` step, please ensure that you are running node version `11`. The `nvm` \(node version manager\) tool allows you to easily switch between versions: + +```text +nvm install 11 +nvm use 11 +``` + +1. Restart the test environment + * Run `docker-compose down` to stop containers + * Run this command to give the docker command a clean slate: `docker volume prune -f && echo volume pruned && docker system prune -f && echo system pruned && docker network prune -f && echo network pruned` + * In some cases, due to stale images application may have build issues owing to existing images and packages that were a part of those builds. To get around such issues, run `docker-compose build --no-cache` to run a clean re-build of the docker images + * run through the 'steps to start the application' in **Development/Test Environment** +2. Increase RAM allocated to Docker + * Consider these steps if you are running many of the `radish` containers and your PC is bogged down + * Check the memory usage by running `docker stats` + * If the containers are using most of the RAM allocated to Docker, you can increase RAM available to Docker by clicking the Docker Desktop icon in the task bar. Choose `Preferences --> Advanced`, then increase `Memory` to a recommended `12.0GiB` \(default is `2.0GiB`\). + +#### Front-end Environment + +1. When the above setup is run successfully, the UI is ready at `http://radish34-ui.docker` +2. Typically, this process takes about a minute to two. Successful loading of UI at the url can be inspected based on the logs of the `radish34-ui` container. Example Logs: + + ```text + radish34-ui_1 | > @ start /app + radish34-ui_1 | > react-scripts start + radish34-ui_1 | + radish34-ui_1 | + radish34-ui_1 | Starting the development server... + radish34-ui_1 | + radish34-ui_1 | Compiled successfully! + radish34-ui_1 | + radish34-ui_1 | You can now view undefined in the browser. + radish34-ui_1 | + radish34-ui_1 | Local: http://localhost:3000/ + radish34-ui_1 | On Your Network: http://172.27.0.14:3000/ + radish34-ui_1 | + radish34-ui_1 | Note that the development build is not optimized. + radish34-ui_1 | To create a production build, use npm run build. + ``` + diff --git a/docs/radish34-demo/radish34-workflow.md b/docs/radish34-demo/radish34-workflow.md new file mode 100644 index 000000000..c798175d4 --- /dev/null +++ b/docs/radish34-demo/radish34-workflow.md @@ -0,0 +1,4 @@ +# Radish34 Workflow + +Here are a few visualizations of how the Radish34 POC functions. + diff --git a/docs/radish34-demo/radish34.md b/docs/radish34-demo/radish34.md new file mode 100644 index 000000000..d9455bbdb --- /dev/null +++ b/docs/radish34-demo/radish34.md @@ -0,0 +1,46 @@ +# Radish34 Explained + +Radish34 is a proof of concept, a reference implementation, a demo. In 2019, a joint development effort to build it led to the Baseline Protocol, a way for enterprises to use the [Mainnet](../baseline-basics/glossary.md#mainnet) as [middleware](../baseline-basics/glossary.md#middleware) without compromising corporate information security practices. Radish34 remains the best way to show the general baseline approach in a specific example. You can build and run the proof of concept [here](radish34-start.md). And you can see how a set of companies would integrate their supply chain management systems in this [interactive demo](demo.md). + +## The Procurement Use Case + +Supply chain, as a topic, presented an obvious choice for exploring ways to use public blockchain in business. In particular, key steps in the manufacturing procurement process were a good focus for the Radish34 project. + +First, the team from EY that helped start the Radish34 project are experts on the subject and were able to articulate a highly precise and detailed set of workflows with both functional and non-functional requirements. + +Second, supply chain has been a classic starting point for enterprise blockchain explorations, because it involves such a tangle of different entities that must work together. But, one of the key problems with using private or public blockchains in a supply chain context is [_compartmentalization_](../baseline-basics/glossary.md#atomic-compartmentalization). + +Even when different companies are partners in a single supply chain, there are things Party A shouldn't know about the relationship or activities of Parties B and C, even if those activities support the same Workflow for the same set of goods. The Radish34 team had to find a way to coordinate companies without anyone that was maintaining the integrity of the ledger learning anything about the business activities or relationships of the participants. + +It turns out, ironically, that this problem is more insidious for private blockchains than for public networks, given the relative ease of analysis an attacker with access to a node can perform on a small group of known counter-parties. And so the choice was to show how the public Ethereum network could be used in a confidential procurement scenario without anyone being able to analyze the ledger and learn about the cadence, volume or particulars of any Party's business. + +### The Volume Discount Problem + +Even with modern supply chain management \(SCM\) and order management systems, revenue recognition for a Supplier can take time. Take the case of a Buyer and a Supplier that agree to a volume discount arrangement, a tiered pricing table in their master service agreement \(MSA\). To keep it simple, imagine that the Supplier will give a 10% discount on orders over 100 units purchased over the next year. The first purchase order \(PO\) comes in for, say, 100 units. This is easy to calculate. The initial state of the agreement is zero -- no units yet ordered. No disount. After the PO is processed, the new state is 100. The next PO comes in for 100, and if everything goes right, the Buyer will receive 10% on each of those 100 units, because they all fall within the 10% discount tier. So far so good. But what if two POs come in at the same time and both calculate from a base of zero. This happens quite a lot in the real world. And it is one of the reasons why generally accepted accounting principles \(GAAP\) have rules about when a Supplier can recognize revenue from purchase activity. Until someone can go through and make sure that each PO calculated in the right order from the right starting position, there’s no way to be certain that the Buyer doesn’t owe more \(or less\) than what the Supplier thinks. + +The Radish34 POC demonstrates how to ensure that each PO executes faithfully and in correct order \(without double-execution from the same starting state\) by using the Ethereum public network as the common frame of reference needed to be sure of what the Buyer owes more quickly. It does this without putting any of the Supplier or Buyer's data or running the shared code that executes the volume discount agreement of the MSA, and ensures that each PO is calculated faithfully against it, on any blockchain. + +`Instead, Radish34 implements the approach now called the Baseline Protocol. The public Mainnet is used not as a "single source of truth" (where the shared data is stored and the shared business logic is executed) but instead as a common frame of reference that enables the Supplier and Buyer to maintain their own systems of record in a verified state of consistency.` + +Even though this approach does not move the sensitive business data of the Buyer and Supplier's MSAs and POs to any kind of blockchain -- leaving it all right where any conservative security officer wants it, in their own internal high-security systems -- it does use the Mainnet's ability to store state and execute functions to provide this _middleware_ service between the counterparties with great utility. And to be clear, while the approach uses well-known components such as peer-to-peer messaging, digital signatures, hashing, and zero-knowledge proofs, it’s how these elements work together that takes this from a simple "proof of existence" approach to something that can be used as a state marker, flow controller and "stealthy" private token for complex business processes in a widely distributed system environment. + +## Other Relevant Supply Chain Problems + +The techniques used to work on the volume discount problem have other applications across the supply chain. Here are several that can reuse, more-or-less the same components and patterns as Radish34's demo Workflow, _like a box of Legos_, to construct solutions across the supply chain from end to end. + +### The Multilateral-to-Bilateral Compartmentalization Problem + +Say a Buyer wishes to make the same request for proposal \(RFP\) to 10 different suppliers. It may be desirable, or even mandatory, for the suppliers to know about the presence of the others in the RFP process and know that the same RFP was made to all of them. But it would not be appropriate for Supplier A to have access to Supplier B's Bid. In fact, Supplier A shouldn't even be aware that any of the other suppliers actually bid on the RFP, even though an ideal system would link each Bid verifiably to the original multi-party RFP. + +### The Blind Coordination Problem + +The terms that govern the movement of a shipment of product from, say, a Manufacturer to a Wholesaler are usually not only confidential...their existence is confidential. And likewise, the terms between the Wholesaler and a Retailer of that product can't, in some cases, be known to the Manufacturer. But there are cases when some or all of the product must be returned to the Manufacturer from the retail channel. Especially in highly regulated industries, the product's serialization process requires tight coordination. When the product is put back into circulation, the Retailer may need to coordinate with the Manufacturer. However, the Retailer in this scenario has no visibility or connection past the Wholesaler. If this were only a "three party" problem, the Wholesaler in the middle could be used to join the two Parties on each side, but in many real-world scenarios, there are more Steps and more Counterparties involved. + +In this case, what's needed is a way to ensure the overall integrity of a Workflow and run complex business rules that can connect Counterparties only when appropriate, without Parties necessarily having any awareness of the Steps that don't directly involve them. Each Party must be confident that what is coming into their Step is correct, and that what happens downstream from their activity will proceed correctly. + +This is a trivial problem if a common vendor is trusted by everyone to run things. But this historically leads to balkanization as many vendors, smelling profits, convince different sets of companies to use them as the common frame of reference. Another way to handle this is to set up a consortium and jointly invest in a shared ledger solution. But this doesn't solve the problem of the double-blind requirement for any of the firms maintaining a node that validates activities on that ledger. Even if those activities are encrypted and masked, maintainers will inevitably see that some kind of activity is happening, and that itself may give them strategic information that other participants wouldn't knowingly permit. This is particularly acute within a ledger used by a relatively small number of known companies. + +### The Coopetition Problem + +Say a Supplier happens to make a product that competes with a company that not only makes products but also runs a shipping operation. If the Supplier is obliged to use the competitor for shipping to the Buyer, and if they have committed to a late-delivery discount, then it’s important for the Supplier to get the verified delivery date from the Shipper. If the Shipper knows who the Supplier is \(so that it can send them the delivery date\), then they can use that information to know a lot about their product's competition: volumes, peak-and-troughs, and their customer base. But what if the Shipper were only aware of its Step in the Workflow. What if, short of opening up a shipping box and inspecting the item, the Shipper didn’t know who was shipping the package to that address? The trick then is getting the delivery date to the Shipper without knowing where to send it. This is where having a common frame of reference, a message bus, is useful. The Shipper can 'dead-drop' the date and a topic \(a key-value-pair\). The Supplier can watch the topic and grab the date. This is a good use of a public Mainnet, if we can use it without leaving traces that others could use to discover and analyze the Supplier, Buyer or Shipper's activities. +