Giter Club home page Giter Club logo

fossil-offchain-processor's Introduction

Offchain Processor Components Requirements

1. Ethereum Data Dispatcher

Goal:

  • Connect to the Ethereum network to send block hashes to a specified Starknet smart contract.

Responsibilities:

  • Establish a connection to the Ethereum blockchain.
  • Call the function to relay the block hashes on Ethereum
  • Ensure that transactions are signed and sent with the correct gas estimation.
  • Monitor transaction status and confirm successful submissions.

2. Starknet Contract Handler

Goal:

  • Interact with Starknet smart contracts to perform various read and write operations and verify proofs.

Responsibilities:

  • Connect to the Starknet blockchain.
  • Execute read operations on specified Starknet smart contracts.
  • Execute write operations on specified Starknet smart contracts.
  • Verify proofs received from the Ethereum Proof Generator and store them on Starknet.
  • Ensure data integrity and confirmation of successful transactions on Starknet.

3. Ethereum Proof Generator

Goal:

  • Generate storage proofs and retrieve block headers from Ethereum, encoding them into RLP format.

Responsibilities:

  • Connect to Ethereum nodes to access blockchain data.
  • Retrieve block headers for specified blocks.
  • Produce storage proofs for given Ethereum accounts and blocks.
  • Encode the retrieved block headers and storage proofs into RLP format.
  • Return the encoded data to the User Request Manager for further processing.

4. User Request Manager

Goal:

  • Manage user requests for specific historical Ethereum account storage values and coordinate interactions with backend components.

Responsibilities:

  • Receive and parse user requests for Ethereum account storage values.
  • Check if the requested storage value is already available.
  • If not available, coordinate with the Ethereum Data Dispatcher to retrieve necessary block hashes.
  • Store the retrieved block hashes on Starknet using the Starknet Contract Handler.
  • Verify if the requested account has already been proved on Starknet.
  • If the account is proved, produce a storage proof using the Ethereum Proof Generator and verify it on Starknet.
  • If the account is not proved, generate the account proof first, verify it on Starknet, then produce and verify the storage proof.
  • Communicate the final result (storage found or storage not found) back to the user.
  • Ensure the storage value is available for use on Starknet once all verifications are complete.

fossil-offchain-processor's People

Contributors

srj31 avatar ametel01 avatar c0np4nn4 avatar tkstanczak avatar

Forkers

ametel01

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.