Assessment reports>Benqi Oracle>Threat Model>getPriceAndTimestamp

Function: getPriceAndTimestamp(IAggregatorV2V3Interface feed, IQiToken qiToken)

This function is used to get the price and time stamp of a qiToken.

Inputs

  • feed

    • Control: Fully controlled by the caller.

    • Constraints: None.

    • Impact: A feed to get the price and time stamp of.

  • qiToken

    • Control: Fully controlled by the caller.

    • Constraints: None.

    • Impact: A token to get the price and time stamp of.

Branches and code coverage

Intended branches

  • Check if the given qiToken is the qiAvax token.

  • Get the price of the qiToken from the feed.

Negative behavior

  • Revert if the answer from the lastestRoundData is not greater than zero.

Zellic © 2025Back to top ↑