From 9977256cb42b0d85fbdec5c860732fc03fa55366 Mon Sep 17 00:00:00 2001 From: Pablo Maldonado Date: Mon, 17 Jun 2024 14:30:48 +0100 Subject: [PATCH 1/2] fix[oval-audit-n-06]: State Variable Visibility Not Explicitly Declared Signed-off-by: Pablo Maldonado --- src/factories/StandardCoinbaseFactory.sol | 2 +- src/factories/StandardPythFactory.sol | 2 +- src/oracles/CoinbaseOracle.sol | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/factories/StandardCoinbaseFactory.sol b/src/factories/StandardCoinbaseFactory.sol index 9aee47a..179ed87 100644 --- a/src/factories/StandardCoinbaseFactory.sol +++ b/src/factories/StandardCoinbaseFactory.sol @@ -37,7 +37,7 @@ contract OvalCoinbase is MutableUnlockersController, CoinbaseSourceAdapter, Chai * mutability choices are desired. */ contract StandardCoinbaseFactory is Ownable, BaseFactory { - IAggregatorV3SourceCoinbase immutable SOURCE; + IAggregatorV3SourceCoinbase public immutable SOURCE; constructor(IAggregatorV3SourceCoinbase _source, uint256 _maxTraversal, address[] memory _defaultUnlockers) BaseFactory(_maxTraversal, _defaultUnlockers) diff --git a/src/factories/StandardPythFactory.sol b/src/factories/StandardPythFactory.sol index 1529e0a..88aa9ee 100644 --- a/src/factories/StandardPythFactory.sol +++ b/src/factories/StandardPythFactory.sol @@ -38,7 +38,7 @@ contract OvalPyth is MutableUnlockersController, PythSourceAdapter, ChainlinkDes * needed if different mutability or interface choices are desired. */ contract StandardPythFactory is Ownable, BaseFactory { - IPyth immutable pyth; + IPyth public immutable pyth; constructor(IPyth _pyth, uint256 _maxTraversal, address[] memory _defaultUnlockers) BaseFactory(_maxTraversal, _defaultUnlockers) diff --git a/src/oracles/CoinbaseOracle.sol b/src/oracles/CoinbaseOracle.sol index 9517a58..297a0a9 100644 --- a/src/oracles/CoinbaseOracle.sol +++ b/src/oracles/CoinbaseOracle.sol @@ -8,7 +8,7 @@ import {IAggregatorV3SourceCoinbase} from "../interfaces/coinbase/IAggregatorV3S * @notice A smart contract that serves as an oracle for price data reported by a designated reporter. */ contract CoinbaseOracle is IAggregatorV3SourceCoinbase { - address immutable reporter; + address public immutable reporter; uint8 public immutable decimals; From 9a02a41480d9efd38a2cee2a54e095536deda21c Mon Sep 17 00:00:00 2001 From: Pablo Maldonado Date: Tue, 18 Jun 2024 17:49:51 +0100 Subject: [PATCH 2/2] feat: pyth uppercase Signed-off-by: Pablo Maldonado --- src/factories/StandardPythFactory.sol | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/factories/StandardPythFactory.sol b/src/factories/StandardPythFactory.sol index 88aa9ee..6b0aa58 100644 --- a/src/factories/StandardPythFactory.sol +++ b/src/factories/StandardPythFactory.sol @@ -38,12 +38,12 @@ contract OvalPyth is MutableUnlockersController, PythSourceAdapter, ChainlinkDes * needed if different mutability or interface choices are desired. */ contract StandardPythFactory is Ownable, BaseFactory { - IPyth public immutable pyth; + IPyth public immutable PYTH; constructor(IPyth _pyth, uint256 _maxTraversal, address[] memory _defaultUnlockers) BaseFactory(_maxTraversal, _defaultUnlockers) { - pyth = _pyth; + PYTH = _pyth; } /** @@ -56,7 +56,7 @@ contract StandardPythFactory is Ownable, BaseFactory { * @return oval deployed oval address. */ function create(bytes32 pythPriceId, uint256 lockWindow, uint256 maxAge) external returns (address oval) { - oval = address(new OvalPyth(pyth, pythPriceId, defaultUnlockers, lockWindow, MAX_TRAVERSAL, maxAge, owner())); + oval = address(new OvalPyth(PYTH, pythPriceId, defaultUnlockers, lockWindow, MAX_TRAVERSAL, maxAge, owner())); emit OvalDeployed(msg.sender, oval, lockWindow, MAX_TRAVERSAL, owner(), defaultUnlockers); } }