Decentralized Mining Pools
Mining pools play a crucial role in decentralizing the mining process on Stacks. However, for mining pools to function effectively in a decentralized manner, specific components need to be integrated:
-
StackerDB – Communication Layer
- StackerDB is a key component for facilitating communication among participants.
- However, its integration lacks proper documentation, making it difficult for developers to understand and utilize its capabilities.
- Questions that need to be addressed:
- How do stacks signers communicate using StackerDB?
- How can a decentralized application interact with and store state using StackerDB?
- Can StackerDB be used beyond mining pools, and what features does it offer?
- In the context of mining pools, StackerDB could serve as a communication layer to:
- Compute the aggregate key using Weighted Schnorr Threshold Signatures (WSTS).
- Establish and update the participants set in the pool.
- Notify participants about pool updates and other events that take place in the pool.
-
WSTS Signature – Enabling Multi-Signature Participation
- Stacks Core has not yet implemented WSTS, but it is planned for a future SIP (cannot add links, check on github stacksgov/sips/blob/main/sips/sip-025/sip-025-iterating-towards-weighted-schnorr-threshold-signatures.md#iteration-2 ).
- There are no existing examples of how WSTS can be used in complex applications that require multi-party communication.
- WSTS is crucial for mining pools because it enables the computation of an aggregate key and allows transaction signing by all participants.
- Once implemented, it will provide a decentralized and secure method for miners to collaborate without relying on a centralized trust.
Change PoX Reward Address Without Penalty
Currently, if a user wants to change their PoX reward address while stacking, they must wait through a one-cycle cooldown, during which their STX remains unstacked, and no rewards are earned. This cooldown is problematic, especially for users managing large amounts of STX.
To improve flexibility, the system could be updated to allow reward address changes mid-cycle:
- The reward address could be updated at any time, provided the change is made at least
X
burn blocks before the associated rewarded Bitcoin block. - This would allow the rewards to be sent to the new address dynamically, without affecting slot allocations.
- The parameter
X
could be chosen to prevent performance issues and race conditions.
Benefits of this update:
- More liquidity in stacking, especially for large accounts that want to adjust their reward distributions.
- Enables new non-custodial stacking solutions, allowing users to receive rewards in
sBTC
bridged from Bitcoin rewards. - Reduces inefficiencies caused by the one-cycle cooldown, allowing participants to optimize their stacking strategy.
This change would require modifications to both the PoX contract and Stacks Node, but it would significantly enhance the flexibility and usability of the PoX mechanism.
Non-Custodial Stacking Pools
A decentralized, non-custodial stacking pool could be implemented using the sBTC bridge and Clarity smart contracts.
How it would work:
-
Users would stack through a smart contract, without relying on an admin or liquidity provider.
-
Rewards can be calculated and distributed by anyone, using on-chain logic, without the need of a centralized entity performing the operations.
-
The system would have safeguards to prevent malicious behavior, such as:
- Cycle extensions limited to one cycle at a time to prevent participants from being locked in longer than intended by others.
-
The pool would allow flexible staking amounts, as long as the total pool stacked amount meets the minimum threshold for stacking.
-
Once sBTC signers are integrated into the Stacks signers, they would be responsible for dynamically updating the reward address.
-
The contract would track the current set of signers by calling the
get-signers
read-only function within the signers contract (SP000000000000000000002Q6VF78.signers
). -
At least 70% of the weighted signers must agree on the new reward address for the update to take effect.
-
This ensures a decentralized and secure mechanism for managing BTC rewards and bridging them into sBTC.
Bridging Capital into the Stacks Network: sBTC on Solana and Ethereum
By making sBTC available on both Solana and Ethereum, users on those chains can hold a Bitcoin-pegged asset and easily move it across different ecosystems. They’ll see that sBTC is powered by Stacks, giving them access to yield opportunities on the Stacks blockchain. As a result, it’s much simpler for someone already using Solana or Ethereum to start using Stacks following these steps directly from their ecosystem.
To achieve this , Chainlink’s decentralized Cross-Chain Interoperability Protocol (CCIP) can be used for secure cross-chain messaging and proofs. The process could be a lock-and-mint approach: sBTC is locked on Stacks, and an equivalent amount is minted on Solana or Ethereum. When returning the tokens, users burn them on the destination chain, and the locked sBTC is released back on Stacks.