In-depth lesson · Missing access control in contracts
Root causes
Every point the Missing access control in contracts reports back under this heading, best-backed first, each with the reports it is seen in.
-
Validation omitted checks that taker and sender addresses are zero, letting a manager set them arbitrarily.
Seen in 1 report
-
The initialisation guard used a caller-settable config value as its sentinel instead of a dedicated boolean flag.
-
Some lend function branches omitted the minting call that the other branches perform.
Seen in 1 report
-
addPlugin lacked validation that the address is a valid plugin bound to this vault and not already registered.
Seen in 1 report
-
The base contract inherited Initializable and the interface but not the upgradeable proxy base, so no upgrade authorisation existed.
Seen in 1 report
-
Delegation functions did not reject the zero address, removing votes without crediting anyone.
Seen in 1 report
-
The fee withdrawal function had no paid-out flag and its modifier checked only the end time, not the caller.
Seen in 1 report
-
The fee change function did not check that a proposal time was non-zero.
Seen in 1 report
-
The approval hash covered only metadata and transition, omitting the proof that controls the bond refund.
Seen in 1 report
-
The signed offer lacked a field distinguishing the two operations, so one signature was valid for both.
Seen in 1 report
-
The signature did not cover the creation config parameters and was not bound to a submitter.
Seen in 1 report
-
The airdrop function had no access control and no cap on the user-supplied array length.
-
The signed hash omitted the verifying contract address, so signatures were valid across collections.
-
The verifier compared swap parameters but omitted a check that the recipient matched the expected recipient.
-
The verifier was deployed with gamma equal to delta, so the pairing equation no longer bound the proof to public inputs.
Seen in 1 report
-
The withdrawal manager decoded the branch mask two ways, so multiple encodings of the same proof produced different exit IDs.
Seen in 1 report
-
The transfer function did not check that the recovered signer was non-zero and did not verify the sender's balance.
Seen in 1 report
-
Precompiled contracts did not check whether an incoming call was a delegatecall or a regular call.
Seen in 1 report
-
The update routine trusted the caller to supply a sensible set and omitted power threshold and size checks.
Seen in 1 report
-
The contract validated the airdrop contract against a whitelist but not the airdrop token address.