Integer overflow vulnerability in MakeMint

Description

The deposit method of the Purse (from the MakeMint contract) is does not check whether an integer overflow error returns from it's NonNegativeInteger when it adds the amount from the other purse to it's own purse. Therefore, it can happen that an amount of tokens get's decremented from another purse, but will not get added to the own purse.

Included are two files: one file where I wrote down unit tests where the bug is visible, the other file shows a proposed solution.

Reporter: Rinke Hendriksen
E-mail: rinkehendriksen@gmail.com

Environment

None

Attachments

2

Activity

Show:

Isaac DeFrain February 6, 2020 at 1:18 AM

PR 2864

Done

Assignee

Isaac DeFrain

Reporter

Priority

Components

Fix versions

Created November 21, 2018 at 4:14 PM
Updated February 7, 2020 at 7:40 PM
Resolved February 6, 2020 at 1:18 AM
Loading...