Background
StaFi Hub is transitioning from an app chain to a contract layer model due to prior security challenges. This migration involves moving rATOM to Neutron, which supports CosmWasm smart contracts. The new rATOM is built using StaFi LSaaS’s CosmWasm LSD Stack, exemplifying enhanced security and scalability.
What is CosmWasm
The x/wasm module, the root of CosmWasm, is a Cosmos SDK module enabling smart contracts to execute on the CosmWasm virtual machine. CosmWasm itself refers to the whole ecosystem built around it with a mission to make smart contracts development easy and reliable. The focuses of the CosmWasm platform are security, performance, and interoperability. It is tailored for a tight integration with Cosmos SDK and to build IBC contracts.
The important thing about CosmWasm smart contracts is their transparency. Every smart contract instance has its unique address on the chain, and it can act just like any other account on chain. It is easy to implement communication between two smart contracts on the same chain. CosmWasm standard library provides simple utilities to communicate with non-CosmWasm modules on the chain. That includes common Cosmos modules like bank or staking and any custom module unique for a particular chain. Finally, CosmWasm is built around the IBC(opens in a new tab) and provides a simple API to communicate with other chains and contracts using IBC-based protocols.
What is CosmWasm LSD Stack
Cosmos LSD Stack is devoted to help developers building liquid staking project in Cosmos ecosystem, and designed to provide a comprehensive set of solutions related to Cosmos LSM, CosmWasm, commission fee management, validator set management, and user operations: stake, unstake, withdraw.
Given the complexity of Cosmos ecosystem, StaFi Cosmos LSD Stack supports most chains that either adhere to the ICS-27 Interchain Protocol or CosmWasm. However, it is not compatible with a few chains, such as Irisnet(IRIS), which do not support either.
-
Stack can be directly deploy on the target chains if they support CosmWasm
-
Conversely, for ICS-27 Protocol chains, Our Stack deploys on Neutron, which is a permissionless smart contract platform, and gives programmable operations of ICA and ICQ on the target chain
The Stack current development progress:
-
Ready to use for ICS-27 protocol chains
-
Smart contracts for CosmWasm native chains are under development, stay tuned
Understanding More: https://docs.stafi.io/lsaas/architecture_cosmos_lsd/
How to build a Cosmos LST like rATOM
Deploy Contracts
-
Go to LSaaS App, and select ATOM LST
-
Connect your wallet, configure contract parameters, and wait for the contract deployment.
More Detail:https://docs.stafi.io/lsaas/develop_cosmos_lsd/contract/
Run ICQ Relay Service
ICQ is an abbreviation for Interchain Queries which allow smart contract to make queries to a remote chain. An ICQ Relayer is a required component for making them possible. It acts as a facilitator between the Neutron chain and a querying chain, gathering queries that are needed to be performed from the Neutron, actually performing them, and eventually making the results available for the Neutron’s smart contracts. Read full ICQ relayer documentation here
More Detail:https://docs.stafi.io/lsaas/develop_cosmos_lsd/icq_relay/
Run Relay Service
Given the limitation of smart contracts, they are not self-executing, and require an external force to trigger their functions. Relay is a service to drive LSD to properly process its own internal states, such as dealing with delegating, undelegating, distributing rewards and calculating the rate between LST and the original coin. We introduce era
concept to define how often the smart contract should be called. Most of the time, an era is 24 hours long.
More Detail:https://docs.stafi.io/lsaas/develop_cosmos_lsd/relay/
Deploy own LSD App
Cosmos LSD App is a user interface where users can stake, unstake and get latest information about the project. As a convention in web3 all API users interact with are directly from the RPC configured in wallet, so the app is a pure DApp.
More Detail:https://docs.stafi.io/lsaas/develop_cosmos_lsd/app/
About StaFi
StaFi is a leading Liquid Staking infrastructure provider and protocol for PoS chains. Its Liquid Staking as a Service (LSaaS) framework enables developers to create Liquid Staking Tokens (LSTs) and Liquid Re-staking Tokens (LRTs) across ecosystems like ETH, EVM, BTC, CosmWasm, and SOL. By issuing rTokens (e.g., rETH, rMATIC, rBNB), StaFi unlocks the liquidity of staked assets, allowing users to earn staking rewards while retaining the flexibility to engage in DeFi. With support for major blockchains such as Ethereum, Solana, Polygon, BNB Chain, and Cosmos, StaFi bridges liquidity and security in Proof-of-Stake networks.
Read more about StaFi 2.0.
评论 (0)