Withdrawal Address Splitter Contract
There is a demand for parties to stake ETH with Rocket Pool without it necessary to take a position in RPL. There is also a demand from parties uninterested with running a Rocket Pool node to be able to loan unstaked RPL to other parties and earn yield on their loaned RPL.
It might be useful to write a standard escrow smart contract, which will accept all ETH and RPL rewards earned by a node, and then allow the node operator to withdraw only the earned ETH rewards and allow the RPL loaner to withdraw only the earned RPL rewards.
Specification
A new RocketPoolWithdrawalEscrow smart contract should be created that:
-
Must receive and hold RPL and ETH balances.
-
Must distribute ETH balance only to addresses whitelisted under a “Staker” role.
-
Must distribute RPL balance only to addresses whitelisted under a “Loaner” role.
-
New addresses must be added to the Staker role only by other Stakers.
-
New addresses must be added to the Loaner role only by other Loaners.
The proposed workflow of the escrow contracts and staking procedure is as follows:
-
The ETH staker should create and register a new node.
-
The ETH staker should share the wallet private key with the RPL loaner.
-
Either party should deploy a new RocketPoolWithdrawalEscrow contract with agreed upon whitelisted addresses for each party.
-
Ether party should set the node’s withdrawal address to point towards the deployed RocketPoolWithdrawalEscrow contract.
-
The RPL loaner should stake their RPL to the node using the shared private key.
-
The ETH staker should deposit their ETH to the node and create minipools.
-
RPL rewards will be sent to the RocketPoolWithdrawalEscrow contract and will be withdrawable by the RPL loaner during staking.
-
On exit, unstaked ETH will be sent to the RocketPoolWithdrawalEscrow contract and will be withdrawable by the ETH staker.