Litentry Doc

Architecture diagram

A diagram representation of the main architecture
overall architecture
In the diagram, there are three layers of blockchains, each layer has different responsibilities:
  • Layer 0 - The main net of relay chains, for example Kusama or Polkadot. It is responsible for providing the shared security of the whole relayer chain and parachain network, also works as a router for XCM messages.
  • Layer 1 - Litmus or Litentry parachain. In this scenario, it serves as an application-specific blockchain, which connects to the relay chain by fitting itself into the parachain slot. The relay chain will validate its blocks and handle the XCM messages.
  • Layer 2 - The TEE side chain that is supported by Integritee. It provides an environment for the runtime to be executed in the SGX (secure run environment). It deviates from the Layer 1 parachain where every state and extrinsic are public and known.
The most magical part of the architecture is that all three layers of blockchain are all based on the Substrate framework. By adapting to different runtime configurations and execution logics, the customized blockchain can play different roles.
There are 5 major software components, SGX runtime, teerex pallet, application-specific pallets or sgx pallets, worker client and worker server. Their interaction is shown below in the component diagram:
component diagram in TEE