Skip to content

Instantly share code, notes, and snippets.

@yuriy77k
Forked from MrCrambo/ETH_HuobiToken_report.md
Created June 29, 2019 07:47
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/6e75d4bf6a55db266359de2c77781ce5 to your computer and use it in GitHub Desktop.
Save yuriy77k/6e75d4bf6a55db266359de2c77781ce5 to your computer and use it in GitHub Desktop.

Summary

This is the report from a security audit performed on HuobiToken by MrCrambo.

The audit focused primarily on the security of HuobiToken smart contract.

In scope

  1. https://etherscan.io/address/0x6f259637dcd74c767781e37bc6133cd6a68aa161#contracts

Findings

In total, 3 issue was reported including:

  • 0 high severity issues.

  • 1 medium severity issues.

  • 0 owner privilegies issues.

  • 2 low severity issues.

  • 0 notes.

Security issues

1. Wrong transfer and transferFrom functions

Severity: medium

Description

In functions transfer and transferFrom there are returning false instead of throw when it's not possible to transfer.

Recommendation

Functions transfer and transferFrom should throw in case of not possibility of transfer.

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. More details here

Recommendation

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

require( _to != address(this) );

3. Zero address checking

Severity: low

Description

There is no zero address checking in functions transfer and transferFrom.

Conclusion

Smart contract contains medium severity issues.

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