The inherit function does not update the InheritanceManager::isInherited
state when the contract is used as a backup (i.e., when there is only one beneficiary). As a result, the new owner (the backup wallet) cannot call InheritanceManager::withdrawInheritedFunds
because InheritanceManager::isInherited
remains false. This breaks the intended functionality of the contract as a backup solution, as the new owner must add another beneficiary to set isInherited to true, which is not intuitive or user-friendly. This can also lead to loss of funds if the new owner doesn't think to add a new wallet as beneficiary.
Place the test below in ./test/InheritanceManagerTest.t.sol
file:
Loss of funds as the new owner (backup wallet) can't withdraw the inherited funds
Contract can't be used as a backup solution as stated in the project README
Manual Review
Foundry
Set the inherited to true when InheritanceManager::inherit
is called. Also, the owner must be set to the backup wallet not msg.sender
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.