The InheritanceManager.sol
allows a beneficiary address to also carry the role of trustee which contradicts the protocols implementation as the trustee is supposed to be a 3rd party to settle disputes and/or re-evaluate assets.
The InheritanceManager.sol::appointTrustee
is a function that can only be called by beneficiaries when the contract is in an inheritable state. It sets the "address of appointed trustee for asset reevaluation". However, the function is missing a check whereby a beneficiary cannot also hold a position of trustee. As a result, a beneficiary can set themselves as a trust and re-evaluate assets to their benefit in the event of disputes/disagreements. The function is
This goes against the protocols logic and functioning whereby the trustee is a 3rd party appointed for asset re-evaluation. Furthermore, logically, in a re-evaluation case, the final sayer should not be anyone in/on the persons of interest list.
The impact of this is low as the ill-acting beneficiary does not exactly gain extra funds but they do manipulate the payout in a way which may not be agreeable to other beneficiaries.
Manual Review
Foundry for testing
To prove the validity of this issue, I have created a test suite that can be run by: forge test --mt testBenefectoryCanBeTrustee -vvvv
4vs to see the flow of events
The code:
The owner adds 4 beneficiaries and a house worth 2000 ether.
After the 90 day period, the funds are unlocked
A beneficiary tries to call a trustee function but the transaction fails
The beneficiary then sets themselves as a trustee and calls the trustee function again.
The final assertion is to the getTrustee
to show that the trustee address and beneficiary address are the same.
The recommended mitigation is to check to make sure the trustee address is also not a beneficiary address.
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.