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

Wrong min amount check in withdrawByStablecoin #97

Open
code423n4 opened this issue Jul 7, 2021 · 2 comments
Open

Wrong min amount check in withdrawByStablecoin #97

code423n4 opened this issue Jul 7, 2021 · 2 comments

Comments

@code423n4
Copy link
Contributor

Handle

cmichel

Vulnerability details

Vulnerability Details

The WithdrawHandler.withdrawByStablecoin incorrectly uses the lpAmount instead of the minAmount in the check.

require(lpAmount > 0, "!minAmount");

Recommended Mitigation Steps

Use minAmount > 0 if trying to check for !minAmount or use a different error message for an invalid LP amount.

@kitty-the-kat
Copy link
Collaborator

non-critical
style/comment issue

@ghoul-sol
Copy link
Collaborator

ghoul-sol commented Jul 26, 2021

Agree with non-critical. This does not influence functionality assuming that lpAmount > 0 is correct check.

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

No branches or pull requests

3 participants