Algo Ssstablecoinsss

First Flight #30
Beginner FriendlyDeFi
100 EXP
View results
Submission Details
Severity: low
Invalid

The constant variable FEED_PRECISION is defined but not used

Summary

In the protocol, the variable FEED_PRECISION is declared as 10^8, which equates to 1 BTC = 10^8 but is not used in code.

Vulnerability Details

The variable FEED_PRECISIONis declared but not used.

It is my assuption that value should be use in functions _get_usd_value and _get_token_amount_from_usdas a normalizer for BTC and ETH implementation.

Impact

**Low vulnerability in the scope of gas consumption. **

Medium vulnerability because the _get_usd_value and _get_token_amount_from_usd parameters lack proper implementation for BTC and ETH.

Tools Used

manual review

Recommendations

Please rething protocol.

Consider this equation:

(usd_amount_in_wei * PRECISION) // (convert(price, uint256) * ADDITIONAL_FEED_PRECISION)
// @audit usd_amount_in_wei*10^18 / price*10,000,000,000 and if ETH * FEED_PRECISION
Updates

Lead Judging Commences

bube Lead Judge 6 months ago
Submission Judgement Published
Invalidated
Reason: Non-acceptable severity

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.