Skip to content
master
not-so-smart-contracts/unprotected_function/
not-so-smart-contracts/unprotected_function/

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 

README.md

Unprotected function

Missing (or incorrectly used) modifier on a function allows an attacker to use sensitive functionality in the contract.

Attack Scenario

A contract with a changeOwner function does not label it as private and therefore allows anyone to become the contract owner.

Mitigations

Always specify a modifier for functions.

Examples

You can’t perform that action at this time.