Skip to content

Commit f6234c6

Browse files
authored
Merge pull request #126 from VenusProtocol/chore/ven-2225
[VEN-2225] RedStone oracle in the documentation
2 parents ce2ef52 + 0657f01 commit f6234c6

File tree

4 files changed

+11
-12
lines changed

4 files changed

+11
-12
lines changed

deployed-contracts/oracles.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
* Binance Oracle: [`0x594810b741d136f1960141C0d8Fb4a91bE78A820`](https://bscscan.com/address/0x594810b741d136f1960141C0d8Fb4a91bE78A820)
66
* Bound Validator:[`0x6E332fF0bB52475304494E4AE5063c1051c7d735`](https://bscscan.com/address/0x6E332fF0bB52475304494E4AE5063c1051c7d735)
77
* Chainlink Oracle:[`0x1B2103441A0A108daD8848D8F5d790e4D402921F`](https://bscscan.com/address/0x1B2103441A0A108daD8848D8F5d790e4D402921F)
8+
* RedStone Oracle:[`0x8455EFA4D7Ff63b8BFD96AdD889483Ea7d39B70a`](https://bscscan.com/address/0x8455EFA4D7Ff63b8BFD96AdD889483Ea7d39B70a)
89
* Pyth Oracle:[`0xb893E38162f55fb80B18Aa44da76FaDf8E9B2262`](https://bscscan.com/address/0xb893E38162f55fb80B18Aa44da76FaDf8E9B2262)
910
* Resilient Oracle:[`0x6592b5DE802159F3E74B2486b091D11a8256ab8A`](https://bscscan.com/address/0x6592b5DE802159F3E74B2486b091D11a8256ab8A)
1011
* TWAP Oracle:[`0xea2f042e1A4f057EF8A5220e57733AD747ea8867`](https://bscscan.com/address/0xea2f042e1A4f057EF8A5220e57733AD747ea8867)
@@ -15,6 +16,7 @@
1516
* Binance Oracle:[`0xB58BFDCE610042311Dc0e034a80Cc7776c1D68f5`](https://testnet.bscscan.com/address/0xB58BFDCE610042311Dc0e034a80Cc7776c1D68f5)
1617
* Bound Validator:[`0x2842140e4Ad3a92e9af30e27e290300dd785076d`](https://testnet.bscscan.com/address/0x2842140e4Ad3a92e9af30e27e290300dd785076d)
1718
* Chainlink Oracle:[`0xCeA29f1266e880A1482c06eD656cD08C148BaA32`](https://testnet.bscscan.com/address/0xCeA29f1266e880A1482c06eD656cD08C148BaA32)
19+
* RedStone Oracle:[`0x0Af51d1504ac5B711A9EAFe2fAC11A51d32029Ad`](https://testnet.bscscan.com/address/0x0Af51d1504ac5B711A9EAFe2fAC11A51d32029Ad)
1820
* Pyth Oracle:[`0x94E1534c14e0736BB24decA625f2F5364B198E0C`](https://testnet.bscscan.com/address/0x94E1534c14e0736BB24decA625f2F5364B198E0C)
1921
* Resilient Oracle:[`0x3cD69251D04A28d887Ac14cbe2E14c52F3D57823`](https://testnet.bscscan.com/address/0x3cD69251D04A28d887Ac14cbe2E14c52F3D57823)
2022
* TWAP Oracle:[`0x3eeE05d929D1E9816185B1b6d8c470eC192b4432`](https://testnet.bscscan.com/address/0x3eeE05d929D1E9816185B1b6d8c470eC192b4432)

risk/resilient-price-oracle.md

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ Furthermore, the improved oracle infrastructure supports the integration of new
1212

1313
#### Resilient Price Feeds
1414

15-
The Resilient Price Feeds replace the single source price provider used in the Comptroller contract with a more robust and reliable solution. This new component not only fetches asset prices from various on-chain sources but also includes a fallback mechanism to protect the protocol from oracle failures. Presently, this feature incorporates Chainlink, Pyth Network, Binance Oracle, and TWAP oracles, with the possibility of adding more in the future.
15+
The Resilient Price Feeds replace the single source price provider used in the Comptroller contract with a more robust and reliable solution. This new component not only fetches asset prices from various on-chain sources but also includes a fallback mechanism to protect the protocol from oracle failures. Presently, this feature incorporates Chainlink, RedStone, Pyth Network, Binance Oracle, and TWAP oracles, with the possibility of adding more in the future.
1616

1717
#### Governance Configurations
1818

@@ -38,14 +38,6 @@ For more detailed information, refer to the following resources:
3838
* [Certik audit report](https://github.com/VenusProtocol/oracle/blob/develop/audits/024\_oracles\_certik\_20230522.pdf)
3939
* [Hacken audit report](https://github.com/VenusProtocol/oracle/blob/develop/audits/016\_oracles\_hacken\_20230426.pdf)
4040

41-
**Deployed contracts on main net:**
42-
43-
* [ResilientOracle](https://bscscan.com/address/0x6592b5DE802159F3E74B2486b091D11a8256ab8A)
44-
* [ChainlinkOracle](https://bscscan.com/address/0x1B2103441A0A108daD8848D8F5d790e4D402921F)
45-
* [BinanceOracle](https://bscscan.com/address/0x594810b741d136f1960141C0d8Fb4a91bE78A820)
46-
* [PythOracle](https://bscscan.com/address/0xb893E38162f55fb80B18Aa44da76FaDf8E9B2262)
47-
* [TWAPOracle](https://bscscan.com/address/0xea2f042e1A4f057EF8A5220e57733AD747ea8867)
48-
4941
**References**
5042

5143
* [Repository](https://github.com/VenusProtocol/oracle)
@@ -54,3 +46,4 @@ For more detailed information, refer to the following resources:
5446
* [Community post about Venus V4, introducing Resilient Price Feeds](https://community.venus.io/t/proposing-venus-v4/3188#price-feed-redundancy-6)
5547
* [Venus Stars blog post about Binance Oracle](https://venusstars.io/community/index.php/2023/05/09/venus-enhances-resilience-binance-oracle-feeds/)
5648
* [Community discussion about Pyth Oracle](https://community.venus.io/t/vip-xx-integrate-with-pyth-as-an-oracle/2723/6)
49+
* [RedStone’s proposal to be added to the interface](https://community.venus.io/t/adding-redstone-oracles-to-the-venus-oracle-interface/3620)

technical-reference/contracts-overview.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,10 @@ Venus Protocol implements secondary, primary and pivot oracles to create a valid
7878

7979
[ChainLinkOracle](https://github.com/VenusProtocol/oracle/blob/main/contracts/oracles/ChainlinkOracle.sol) is the primary oracle. If a token isn't support by Chainlink then prices will be fetched from a secondary oracle.
8080

81+
[**RedStoneOracle**](https://redstone.finance/)
82+
83+
[RedstoneOracle](https://docs.redstone.finance/docs/smart-contract-devs/get-started/redstone-classic) is used in the Classic model (Chainlink-compatible interface) as a pivot oracle to validate prices returned by main and fallback oracles.
84+
8185
[**BinanceOracle**](./reference-oracle/oracles/binance-oracle.md)
8286

8387
[BinanceOracle](https://github.com/VenusProtocol/oracle/blob/main/contracts/oracles/BinanceOracle.sol) contract is responsible for fetching token prices from the Binance oracle. It is used as a secondary oracle.

technical-reference/reference-oracle/resilient-oracle.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ reported prices. If only one oracle is used, this creates a single point of fail
66
for attacking the protocol.
77

88
The Resilient Oracle uses multiple sources and fallback mechanisms to provide accurate prices and protect
9-
the protocol from oracle attacks. Currently it includes integrations with Chainlink, Pyth, Binance Oracle
9+
the protocol from oracle attacks. Currently it includes integrations with Chainlink, RedStone, Pyth, Binance Oracle
1010
and TWAP (Time-Weighted Average Price) oracles. TWAP uses PancakeSwap as the on-chain price source.
1111

1212
For every market (vToken) we configure the main, pivot and fallback oracles. The oracles are configured per
@@ -25,9 +25,9 @@ anchorRatio = anchorPrice/reporterPrice
2525
isValid = anchorRatio <= upperBoundAnchorRatio && anchorRatio >= lowerBoundAnchorRatio
2626
```
2727

28-
In most cases, Chainlink is used as the main oracle, TWAP or Pyth oracles are used as the pivot oracle depending
28+
In most cases, Chainlink is used as the main oracle, RedStone, TWAP or Pyth oracles are used as the pivot oracle depending
2929
on which supports the given market and Binance oracle is used as the fallback oracle. For some markets we may
30-
use Pyth or TWAP as the main oracle if the token price is not supported by Chainlink or Binance oracles.
30+
use RedStone, Pyth or TWAP as the main oracle if the token price is not supported by Chainlink or Binance oracles.
3131

3232
For a fetched price to be valid it must be positive and not stagnant. If the price is invalid then we consider the
3333
oracle to be stagnant and treat it like it's disabled.

0 commit comments

Comments
 (0)