Normally, a secret vault function should either:
create a new vault if none exists, or
update the existing vault if one already exists.
In the current implementation:
The call to move_to
will abort automatically with a RESOURCE_ALREADY_EXISTS
error if the caller already has a Vault
.
Since no prior check is performed, users cannot update their secret once it’s set — the contract locks them out permanently after the first use.
Likelihood:
Reason 1: This occurs every time a user with an existing vault calls set_secret
.
Reason 2: Since most users will eventually want to update their secret, this bug is guaranteed to surface.
Impact:
Impact 1: Users are unable to update their stored secret after the first transaction (denial of service for legitimate use).
Impact 2: Creates poor UX and may force redeployment or contract migration, undermining trust in the application.
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.