Skip to content

pBridge Architecture

pBridge, at the very high level, consists of two components – The Middle Layer Logic, which stores the transformed destination transaction messages in a Kafka queue, and the Multiparty Computation (MPC) based Threshold Signature Scheme Account, which ensures every destination transaction is executed collectively by a pool of Bridge Validators, maintaining decentralized, multi-party transaction signing.

Middle Layer Logic (MLL)

The Middle Layer Logic which basically reads the pSTAKE relevant transactions committing at the source chain, and creates raw transaction object to be executed at the destination chain. There are certain event emitters (smart contract-based events/Logs in Ethereum end, EventEmitter at Cosmos end) which keeps track of transactions in cosmos, which are parsed, and transformed using the middle layer logic, into Ethereum transaction which is then executed at the Ethereum chain, thereby executing transfer of value. The same operation happens at the Cosmos chain also, after reading events from Ethereum chain. The middle layer logic consists of set of transformation and optimization routines which are used to automatically create transactions for the destination chain. These routines comprise of transformation logic, batching of transactions, gas and speed optimizations etc. The MLL program is built in GoLang which executes in a secure, provable environment as a binary, ensuring immutable, verified transformations and destination transaction creation. For speed and optimization, these transformed transactions are stored as messages in Apache Kafka Queue.

Multiparty Computation (MPC)

The transaction is executed at the destination chain using a group of bridge validators collectively, so as to maintain decentralization. These bridge validators also happen to be a pool of whitelisted Cosmos PoS validators, who are selected as per several factors of assessment, to ensure only the most reputed and performant validators become part of operating the bridge. These validators collectively use a Multiparty Computation based account to collectively verify each transaction and provide their approval for transaction signing. If the threshold number of approvals are received, then the transaction is automatically signed and dispatched to the chain. The MPC based account also makes sure that validators can be dynamically added or removed as per their performance and legitimacy stats, all the while keeping the account address (and public key) the same. MPC accounts are much more sophisticated than multisig accounts since they can be scaled to any chain based bridging.