Abstract: The ownership of ERC721 tokens when staked in a pool presents challenges, particularly when it involves older, non-lockable NFTs like, for example, Crypto Punks or Bored Ape Yacht Club (BAYC) tokens. This proposal introduces an interface to address these challenges by allowing staked NFTs to be recognized by their original owners, even after they’ve been staked.
Motivation: Recent solutions involve retaining the ownership of the NFT while “locking” it. However, this presupposes that all NFTs are “lockable”. For vintage or previously minted NFTs, like BAYC, this poses an issue. Once staked in a pool, the NFT’s ownership transfers to the staking pool, preventing, for example, original owners from accessing privileges or club memberships associated with those NFTs.
To circumvent this limitation, we propose an interface that exposes a function that allows to know the original owner of the staked NFT.
Specification: The proposed interface introduces a method, holderOfRightsFor
, that enables callers to determine the original owner of a staked NFT.
interface ERC7531 {
function holderOfRightsFor(
address tokenAddress,
uint256 tokenId
) external view returns (address);
}
Flow:
- A user stakes an NFT in a pool.
- As is customary, ownership of the NFT transfers to the staking pool as usual.
- If the staking pool implements this interface, it exposes the
holderOfRightsFor
method. - Apps and other contracts can call this method to determine the original owner of the staked NFT or whoever has ownership rights on it.
Rationale: This approach provides a workaround for the challenges posed by non-lockable NFTs. By exposing the information about the original owner through the holderOfRightsFor
method. This way it would ensure that staking does not hinder the utility or privileges tied to certain NFTs.
Note on Non-Staking Contract Ownership
This interface is intended for staking pool contracts and other similar contracts that take ownership of tokens like NFTs. However, ownership of NFTs by other smart contracts like Gnosis Safe, ERC4337 or ERC6551 wallets would not necessarily implement this interface. In these cases, it is acceptable for the contract to have ownership without exposing original ownership information.
For example, if a smart wallet owns an NFT and receives an airdropped asset, this is fine since the original owner still has control of the smart wallet. The interface proposed here specifically targets staking contracts where obscuring original ownership poses problems.
Backwards Compatibility: This interface can seamlessly integrate with any upgradeable contract that owns NFTs, provided they choose to adopt it. It does not require changes to the ERC721 standard but acts as an enhancement for staking pools and other contracts that receive NFTs for any reason.
Conclusion: The ERC7531
interface proposal offers a streamlined solution for recognizing the ownership of staked NFTs, especially those that are non-lockable. Adopting this proposal will ensure that NFT holders do not lose out on associated benefits when they stake their tokens.