Applications and Architecture for Blockchain-style Messaging

In my previous article, I described third generation blockchain systems that will connect with the real world to do trading and ledger transactions at high volume. The enabling technology is “blockchain-style messaging.”

We can use ideas from blockchain ledgers to make a great messaging system. A blockchain-style messaging system will collect messages about a transaction, share them, and save the whole stream in permanent blockchain-style storage.

With blockchain-style messaging:

  • All bits are publicly shared
  • It’s easy to join and participate
  • You get security and privacy through encryption
  • You have a trustworthy record
  • It’s easy to look at, debug, and audit any transaction
  • It has the force of law in setting up agreements and transactions

Applications

Simple agreements
We can make agreements. If I say that I will do something for you, and you say you will do something for me in return, that is legally a type of contract. We don’t need a smart contract. We just need a record of this exchange.

OTC transactions
One type of agreement is an “over the counter” trade, where two parties agree on a security and a trade by phone or email or some other communication. These message types can be attached to a description of a trade in a blockchain-style messaging system.

Banks settle trades by agreeing on delivery for payment
The core of settling a trade is asking banks to move money, IF the other guy’s bank delivers the securities. The banks can use blockhain-style messaging to negotiate this handoff, and deliver securities and money immediately. For example:

  • “I have Y dollars to trade for X stock in Megacorp.”
  • “I have the stock. I will transfer it to your correspondent account if you confirm your delivery of the money.”
  • “OK. I transferred.”
  • “OK. I transferred. Transaction finished. Send to block builder.”

Straight through processing
The instructions for settlement can come from a process called “Straight through processing”, where a securities buyer or seller takes a trade from an exchange and attaches the settlement instructions — the accounts where money and securities will be transferred. Here is a picture that compares the old messy bilateral way of doing this, with the blockchain way.

Deliver assets to a blockchain ledger
The buyer and the seller might add settlement instructions in the form of signed transactions for a blockchain ledger. Then, the blockchain messaging system would deliver the transactions to the blockchain ledger.

Regulatory monitoring
Regulators often ask for records from banks, online trading, and online gaming. With blockchain-style messaging they have a simple way to get reliable records in real time.

Using the system

  • Join by sharing public keys and routing addresses
  • Receive and send messages with associated transactions
  • Use encrypted message channels
  • Look up past transactions and get the related data

Underneath this simple API, a lot is happening.

Requirements

Distribution
We need to provide a routing system that will send individual messages to recipient addresses. We will also satisfy our mission of providing shared data with a “firehose” of all transactions and messages and publication of the final blocks.

Delivery guarantees
We want to be sure that if we put a transaction in, it goes into our records because it is marked as finished, or because it times out.

Private encrypted data
Participants should be able to exchange private, encrypted messages.

Key management
We will need a way to keep track of the public keys for each participant, so that we can send them private messages and verify instructions. Each participant will need to save secure private keys for reading private messages, signing instructions, and reading historical private information.

Real Names
We want to know what a real person or a real company said. We will want to know the real name associated with each public key.

Immutability
When we retrieve a published block, we should be able to show that it has not been changed. We can do this by looking at block hashes and Merkle hash trees saved in an immutable storage such as the bitcoin blockchain.

Infrastructure

* An endpoint that accepts new transactions and messages

* A router that delivers messages to the next participant

* A firehose that distributes all of the data, for the few participants that want it and can handle it

* A block builder that assembles and signs storage blocks containing transactions with their messages. This centralized block builder can run at a much higher speed than consensus-based systems like bitcoin. If you aren’t sure whether you trust the block-building service, you can audit it by observing the firehose and finished blocks for known messages. We can guarantee that data will not be changed, with the same level of security of bitcoin, by taking hashes from our big block store and putting them into bitcoin transactions.

* A SaaS service for storing blocks and looking up past transactions

Architecture

Public key encryption
We will use elliptical public key encryption for authentication, signing, and for passing encrypted secret keys and addresses.

Open source code
As a trusted, encryption-based system, it will be built on open source code that the user community can examine and improve.

Cloud Infrastructure
A high-volume messaging system is a creature of the current era of big data, not the previous era of P2P networks. It will require cloud infrastructure, and most participants will access it through centralized services.

Scalable number of message pipelines
We will use the on-demand cloud architecture to expand the number of message pipelines as needed.

Microservices
The infrastructure will evolve through continuous improvement of microservices.

A continuous integration testbed
A continuous integration testbed will be available for contributors to test modifications and integrations. We will deliver working code, not standards. This will allow the system to evolve at high speed compared with an older standards process or governance process.

Following up

SaaS entrepreneur/engineer. Founder of MAXOS, Real World DeFi. Previously founded Assembla, PowerSteering Software, on team at SNL Financial.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store