EthereumCommonwealth / Roadmap

GNU Lesser General Public License v2.1
57 stars 17 forks source link

Auditing Department extension: security guidances #65

Open Dexaran opened 3 years ago

Dexaran commented 3 years ago

1. Preamble

As a result of the analysis of the past contract hacks, and in particular the recent $12,400,000 hack of VultSX, it became obvious that the activity of security auditors does not sufficiently reduce the damage from the security vulnerabilities of smart-contracts.

As security auditors, we must not only check the code of contracts, but also make sure that the developer of the contract adheres to the best known security practices and the developer of the contract is aware of all the known risks associated with the use of the audited contract.

2. Types of contracts

There are two main types of smart-contracts aimed by hackers:

A hacker can simply "withdraw" the funds from a storage contract in order to get profit. A hacker should somehow manipulate the logic of a fund-governing contract in order to get profit (i.e. transfer tokens on behalf of some user or mint new tokens to sell them on exchange).

Special attention needs to be paid to storage contracts as these are at a greater risk category. It would be helpful if the funds in a storage contract were insured.

3. Security practices to follow

Read DAPP security standards for reference.

Platform-specific issues (Ethereum-based)

Platform-specific issues (EOS)

4. Security Audit Report template extension

Conclusion must be moved from paragraph 4 to paragraph 5 ("4. Conclusion" -> "5. Conclusion").

Paragraph 4 must now be "4. Security practices".

Paragraph "4. Security practices" must contain the following checklist relevant for the auditable contract. If one of the points relevant for the contract is checked then it can be left without explanation. Otherwise if one of the points relevant for the audited contract is NOT fulfilled then the explanation of this point from paragraph 3. Security practices to follow (described above) must be included:

See a new ETH_audit_report_example.md.