The Vault module is intended to store a secret string that should be controlled only by the owner account defined during deployment by @owner
. However, the set_secret
entry function allows any signer to create a Vault resource under their own address without any ownership check.
Likelihood: High
Any user with a valid signer can call set_secret
to publish a new Vault resource with the provided secret under their account.
Impact: High
It breaks the key invariant of the protocol in which only the owner should be able to write/read the secret
In Move for Aptos, the term "owner" refers to a signer, which is a verified account that owns a given resource, has permission to add resources and the ability to grant access or modify digital assets. Following this logic in this contest, the owner is the account that owns `Vault`. This means that anyone has right to call `set_secret` and then to own the `Vault` and to retrieve the secret from the `Vault` in `get_secret` function. Therefore, this group is invalid, because the expected behavior is anyone to call the `set_secret` function.
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.