Beginner FriendlyFoundry
100 EXP
View results
Submission Details
Severity: high
Valid

Password is Not Private

Summary

Anyone can retrieve password.

Vulnerability Details

In blockchain, private does not means it is not readable by anyone. Private variables just like every other variable in a contract can easily be accesible via RPC methods, blockchain explorers etc. Hence it is not secure to put a private information like password into a blockchain thinking it will be only reachable by you. In contract getPassword() function is protected via require statement and only the owner of the password can get the password via this method. But as mentioned above, actually there is no need for such function to retrieve data from blockchain.

Impact

PasswordStore is not securely protecting your password, hence the contract is completely failing to promise its mission.

Tools Used

Manual Review

Recommendations

Never put private information into the blockchain :)

Updates

Lead Judging Commences

inallhonesty Lead Judge
almost 2 years ago
inallhonesty Lead Judge almost 2 years ago
Submission Judgement Published
Validated
Assigned finding tags:

finding-anyone-can-read-storage

Private functions and state variables are only visible for the contract they are defined in and not in derived contracts. In this case private doesn't mean secret/confidential

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.