Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Overflows Not Set to Panic #56

Closed
MaksymZavershynskyi opened this issue Jun 3, 2020 · 0 comments · Fixed by near/near-sdk-rs#173
Closed

Overflows Not Set to Panic #56

MaksymZavershynskyi opened this issue Jun 3, 2020 · 0 comments · Fixed by near/near-sdk-rs#173

Comments

@MaksymZavershynskyi
Copy link
Contributor

Informational
Reported by a third party.

Description
The Rust release profile does not have overflow checks on by default. As a result, any overflows (e.g. addition, subtraction, etc.) will simply wrap, potentially creating an inconsistent state.

No scenarios could be found to trigger overflows in the fungible-token contract.

Recommendations
The release profile should be updated to panic on overflows, that is, to include overflow-checks = true .

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

Successfully merging a pull request may close this issue.

1 participant