ERC-20 Staking Vault
Stake STK, earn more STK at an owner-set per-second rate. ReentrancyGuard + CEI pattern.
Harsha Nandhan Reddy Gajulapalli · read-only overviews · Hardhat local evidence
Stake STK, earn more STK at an owner-set per-second rate. ReentrancyGuard + CEI pattern.
Mintable ERC-20 where holder dividends and staking compete for the same balance. Explicit accounting lab.
Open demo page GitHubOwner mints STK. Users stake into StakingVault, withdraw principal, and claim accrued rewards. Reward rate is owner-controlled.
ReentrancyGuard on stake, withdraw, getRewardsafeTransfer / safeTransferFromonlyOwner on setRewardRate and token mintSend ETH to mint (1 ETH = 1000 DTK). Owner can push ETH via distributeDividends; holders pull with withdrawDividends. Staked tokens stop earning holder dividends until unstaked — that tradeoff is the point of the lab.
ReentrancyGuard on mint, burn, withdraw, stake, unstakeonlyOwner on distributeDividends and fundStakingRewards