Skip to content

Instantly share code, notes, and snippets.

@yuriy77k
Forked from danbogd/ETH_HuobiToken_audit_report.md
Created June 29, 2019 07:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yuriy77k/cc9231e2b5ad610bc2bc197971184868 to your computer and use it in GitHub Desktop.
Save yuriy77k/cc9231e2b5ad610bc2bc197971184868 to your computer and use it in GitHub Desktop.

Huobi Token audit report.

1. Summary

This document is a security audit report performed by danbogd, where Huobi Token has been reviewed.

2. In scope

Сommit hash .

3. Findings

In total, 2 issues were reported including:

  • 1 medium severity issues
  • 1 low severity issues
  • 0 owner privileges (ability of owner to manipulate contract, may be risky for investors)..
  • 0 notes.

No critical security issues were found.

3.1 Non-compliance with ERC-20 Token Standard.

Severity: medium

Description

ERC-20 Token Standard specifies for functions transfer and transferFrom:

The function SHOULD throw if the _from account balance does not have enough tokens to spend. But in this implementation it just returns false. This can lead to serious consequences. Because checking the return value of this function is rare.

Code snippet

Lines 46,56, 94.

3.2. Known vulnerabilities of ERC-20 token

Severity: low

Description

  1. It is possible to double withdrawal attack. More details here.

  2. Lack of transaction handling mechanism issue. WARNING! This is a very common issue and it already caused millions of dollars losses for lots of token users! More details here.

Recommendation

Add into a function transfer(address _to, ... ) following code:

require( _to != address(this) );

4. Conclusion

The review did not show any critical issues, some of medium and low severity issues were found.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment