From b0f4929c716dc163fafbd4cb1e4dbd37dc283d18 Mon Sep 17 00:00:00 2001 From: philbow61 Date: Wed, 9 Aug 2023 16:46:39 +0200 Subject: [PATCH 01/64] feat: MU04 Governance Script --- script/interfaces/ICeloGovernance.sol | 2 + script/interfaces/IFeeCurrencyWhitelist.sol | 7 + script/upgrades/MU04/Config.sol | 165 +++++ script/upgrades/MU04/MU04.sol | 617 ++++++++++++++++++ ...U04-02-Create-Nonupgradeable-Contracts.sol | 72 ++ script/utils/Arrays.sol | 10 + script/utils/Config.sol | 43 ++ 7 files changed, 916 insertions(+) create mode 100644 script/interfaces/IFeeCurrencyWhitelist.sol create mode 100644 script/upgrades/MU04/Config.sol create mode 100644 script/upgrades/MU04/MU04.sol create mode 100644 script/upgrades/MU04/deploy/MU04-02-Create-Nonupgradeable-Contracts.sol diff --git a/script/interfaces/ICeloGovernance.sol b/script/interfaces/ICeloGovernance.sol index aba58b15..f9c1e4f0 100644 --- a/script/interfaces/ICeloGovernance.sol +++ b/script/interfaces/ICeloGovernance.sol @@ -17,4 +17,6 @@ interface ICeloGovernance { uint256[] calldata dataLengths, string calldata descriptionUrl ) external payable returns (uint256); + + function setConstitution(address destination, bytes4 functionId, uint256 threshold) external; } diff --git a/script/interfaces/IFeeCurrencyWhitelist.sol b/script/interfaces/IFeeCurrencyWhitelist.sol new file mode 100644 index 00000000..5c6d1337 --- /dev/null +++ b/script/interfaces/IFeeCurrencyWhitelist.sol @@ -0,0 +1,7 @@ +pragma solidity ^0.5.13; + +interface IFeeCurrencyWhitelist { + function addToken(address) external; + + function getWhitelist() external view returns (address[] memory); +} diff --git a/script/upgrades/MU04/Config.sol b/script/upgrades/MU04/Config.sol new file mode 100644 index 00000000..d1e41e5d --- /dev/null +++ b/script/upgrades/MU04/Config.sol @@ -0,0 +1,165 @@ +// SPDX-License-Identifier: GPL-3.0-or-later +// solhint-disable func-name-mixedcase, contract-name-camelcase, function-max-lines, var-name-mixedcase +pragma solidity ^0.5.13; +pragma experimental ABIEncoderV2; + +import { Chain } from "script/utils/Chain.sol"; +import { Config } from "script/utils/Config.sol"; +import { Contracts } from "script/utils/Contracts.sol"; +import { Arrays } from "script/utils/Arrays.sol"; +import { FixidityLib } from "script/utils/FixidityLib.sol"; + +library MU04Config { + using FixidityLib for FixidityLib.Fraction; + using Contracts for Contracts.Cache; + + struct MU04 { + Config.Pool eXOFCelo; + Config.Pool eXOFEUROC; + Config.Pool[] pools; + Config.RateFeed CELOXOF; + Config.RateFeed EUROCXOF; + Config.RateFeed EUROCEUR; + Config.RateFeed[] rateFeeds; + Config.StableToken stableTokenXOF; + } + + function get(Contracts.Cache storage contracts) internal returns (MU04 memory config) { + config.pools = new Config.Pool[](2); + config.pools[0] = config.eXOFCelo = eXOFCelo_PoolConfig(contracts); + config.pools[1] = config.eXOFEUROC = eXOFEUROC_PoolConfig(contracts); + + config.rateFeeds = new Config.RateFeed[](3); + config.rateFeeds[0] = config.CELOXOF = CELOXOF_RateFeedConfig(contracts); + config.rateFeeds[1] = config.EUROCXOF = EUROCXOF_RateFeedConfig(contracts); + config.rateFeeds[2] = config.EUROCEUR = EUROCEUR_RateFeedConfig(contracts); + + config.stableTokenXOF = stableTokenXOFConfig(); + } + + function stableTokenXOFConfig() internal pure returns (Config.StableToken memory config) { + config = Config.StableToken({ + name: "EcoLabs West African Franc", + symbol: "eXOF", + decimals: 18, + registryAddress: address(0x000000000000000000000000000000000000ce10), + inflationRate: 1000000000000000000000000, + inflationFactorUpdatePeriod: 47304000, + initialBalanceAddresses: new address[](0), + initialBalanceValues: new uint256[](0), + exchangeIdentifier: "Broker" + }); + } + + function eXOFCelo_PoolConfig(Contracts.Cache storage contracts) internal view returns (Config.Pool memory config) { + config = Config.Pool({ + asset0: contracts.celoRegistry("StableTokenXOF"), + asset1: contracts.celoRegistry("GoldToken"), + isConstantSum: false, + spread: FixidityLib.newFixedFraction(50, 10_000), // 0.0050 + referenceRateResetFrequency: 5 minutes, + minimumReports: 5, + stablePoolResetSize: 656 * 250_000 * 1e18, // 164 million + referenceRateFeedID: contracts.celoRegistry("StableTokenXOF"), + asset0limits: Config.TradingLimit({ + enabled0: true, + timeStep0: 5 minutes, + limit0: 656 * 10_000, + enabled1: true, + timeStep1: 1 days, + limit1: 656 * 50_000, + enabledGlobal: true, + limitGlobal: 656 * 300_000 + }), + asset1limits: Config.TradingLimit({ + enabled0: true, + timeStep0: 5 minutes, + limit0: 20_000, // assuming Celo/EUR = 0.5 + enabled1: true, + timeStep1: 1 days, + limit1: 100_000, // assuming Celo/EUR = 0.5 + enabledGlobal: true, + limitGlobal: 600_000 // assuming Celo/EUR = 0.5 + }) + }); + + if (Chain.isBaklava() || Chain.isAlfajores()) { + config.minimumReports = 2; + } + } + + function CELOXOF_RateFeedConfig( + Contracts.Cache storage contracts + ) internal view returns (Config.RateFeed memory config) { + config.rateFeedID = contracts.celoRegistry("StableTokenXOF"); + config.medianDeltaBreaker0 = Config.MedianDeltaBreaker({ + enabled: true, + threshold: FixidityLib.newFixedFraction(3, 100), // 0.03 + cooldown: 30 minutes, + smoothingFactor: 0 + }); + } + + function eXOFEUROC_PoolConfig(Contracts.Cache storage contracts) internal returns (Config.Pool memory config) { + config = Config.Pool({ + asset0: contracts.celoRegistry("StableTokenXOF"), + asset1: contracts.dependency("BridgedEUROC"), + isConstantSum: true, + spread: FixidityLib.newFixedFraction(25, 10000), // 0.0025 + minimumReports: 5, + referenceRateResetFrequency: 5 minutes, + stablePoolResetSize: 656 * 1_000_000 * 1e18, // 656 * 1.0 million + referenceRateFeedID: contracts.dependency("EUROCXOFRateFeedAddr"), + asset0limits: Config.TradingLimit({ + enabled0: true, + timeStep0: 5 minutes, + limit0: 656 * 10_000, + enabled1: true, + timeStep1: 1 days, + limit1: 656 * 50_000, + enabledGlobal: true, + limitGlobal: 656 * 1_000_000 + }), + asset1limits: Config.TradingLimit({ + enabled0: true, + timeStep0: 5 minutes, + limit0: 10_000, + enabled1: true, + timeStep1: 1 days, + limit1: 50_000, + enabledGlobal: true, + limitGlobal: 1_000_000 + }) + }); + if (Chain.isBaklava() || Chain.isAlfajores()) { + config.minimumReports = 2; + } + } + + function EUROCXOF_RateFeedConfig(Contracts.Cache storage contracts) internal returns (Config.RateFeed memory config) { + config.rateFeedID = contracts.dependency("EUROCXOFRateFeedAddr"); + config.valueDeltaBreaker0 = Config.ValueDeltaBreaker({ + enabled: true, + threshold: FixidityLib.newFixedFraction(5, 1000), // 0.005 + referenceValue: 656.55 * 10 ** 24, // TODO: verify + cooldown: 15 minutes + }); + config.valueDeltaBreaker1 = Config.ValueDeltaBreaker({ + enabled: true, + threshold: FixidityLib.newFixedFraction(10, 100), // 0.10 + referenceValue: 656.55 * 10 ** 24, // TODO: verify + cooldown: 0 seconds + }); + config.dependentRateFeeds = Arrays.addresses(contracts.dependency("EUROCEURRateFeedAddr")); + } + + function EUROCEUR_RateFeedConfig(Contracts.Cache storage contracts) internal returns (Config.RateFeed memory config) { + config.rateFeedID = contracts.dependency("EUROCEURRateFeedAddr"); + config.valueDeltaBreaker0 = Config.ValueDeltaBreaker({ + enabled: true, + threshold: FixidityLib.newFixedFraction(5, 1000), // 0.005 + referenceValue: 1e24, // 1€ numerator for 1e24 denominator + cooldown: 1 seconds + }); + } +} diff --git a/script/upgrades/MU04/MU04.sol b/script/upgrades/MU04/MU04.sol new file mode 100644 index 00000000..f1d8dff7 --- /dev/null +++ b/script/upgrades/MU04/MU04.sol @@ -0,0 +1,617 @@ +// SPDX-License-Identifier: GPL-3.0-or-later +// solhint-disable func-name-mixedcase, contract-name-camelcase, function-max-lines, var-name-mixedcase +pragma solidity ^0.5.13; +pragma experimental ABIEncoderV2; + +import { GovernanceScript } from "script/utils/Script.sol"; +import { console2 as console } from "forge-std/Script.sol"; +import { Contracts } from "script/utils/Contracts.sol"; +import { Chain } from "script/utils/Chain.sol"; +import { Arrays } from "script/utils/Arrays.sol"; + +import { FixidityLib } from "mento-core-2.2.0/common/FixidityLib.sol"; +import { IBiPoolManager } from "mento-core-2.2.0/interfaces/IBiPoolManager.sol"; +import { IPricingModule } from "mento-core-2.2.0/interfaces/IPricingModule.sol"; +import { IReserve } from "mento-core-2.2.0/interfaces/IReserve.sol"; +import { IRegistry } from "mento-core-2.2.0/common/interfaces/IRegistry.sol"; +import { IFeeCurrencyWhitelist } from "../../interfaces/IFeeCurrencyWhitelist.sol"; +import { Proxy } from "mento-core-2.2.0/common/Proxy.sol"; +import { IERC20Metadata } from "mento-core-2.2.0/common/interfaces/IERC20Metadata.sol"; + +import { BiPoolManagerProxy } from "mento-core-2.2.0/proxies/BiPoolManagerProxy.sol"; +import { BrokerProxy } from "mento-core-2.2.0/proxies/BrokerProxy.sol"; +import { Broker } from "mento-core-2.2.0/swap/Broker.sol"; +import { BiPoolManager } from "mento-core-2.2.0/swap/BiPoolManager.sol"; +import { Exchange } from "mento-core-2.2.0/legacy/Exchange.sol"; +import { TradingLimits } from "mento-core-2.2.0/libraries/TradingLimits.sol"; +import { BreakerBox } from "mento-core-2.2.0/oracles/BreakerBox.sol"; +import { MedianDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/MedianDeltaBreaker.sol"; +import { ValueDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/ValueDeltaBreaker.sol"; +import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; +import { StableTokenXOF } from "mento-core-2.2.0/legacy/StableTokenXOF.sol"; +import { StableTokenXOFProxy } from "mento-core-2.2.0/legacy/proxies/StableTokenXOFProxy.sol"; + +import { MU04Config, Config } from "./Config.sol"; +import { IMentoUpgrade, ICeloGovernance } from "script/interfaces/IMentoUpgrade.sol"; + +/** + forge script {file} --rpc-url $BAKLAVA_RPC_URL + --broadcast --legacy + * @dev depends on: ../deploy/*.sol + */ +contract MU04 is IMentoUpgrade, GovernanceScript { + using TradingLimits for TradingLimits.Config; + using FixidityLib for FixidityLib.Fraction; + + ICeloGovernance.Transaction[] private transactions; + + address private eXOF; + address payable private eXOFProxy; + address private celo; + address private bridgedEUROC; + address private breakerBox; + address private medianDeltaBreaker; + address private valueDeltaBreaker; + address private nonrecoverableValueDeltaBreaker; + address private brokerProxy; + address private biPoolManagerProxy; + address private sortedOraclesProxy; + + // Helper mapping to store the exchange IDs for the reference rate feeds + mapping(address => bytes32) private referenceRateFeedIDToExchangeId; + + bool public hasChecks = true; + + function prepare() public { + loadDeployedContracts(); + setAddresses(); + setUpConfigs(); + } + + /** + * @dev Loads the deployed contracts from the previous deployment step + */ + function loadDeployedContracts() public { + contracts.load("MU01-00-Create-Proxies", "latest"); + contracts.load("MU01-01-Create-Nonupgradeable-Contracts", "latest"); + contracts.load("MU03-01-Create-Nonupgradeable-Contracts", "latest"); + contracts.load("MU03-02-Create-Implementations", "latest"); + contracts.load("MU04-00-Create-Proxies.sol", "latest"); + contracts.load("MU04-01-Create-Implementations.sol", "latest"); + contracts.load("MU04-02-Create-Nonupgradeable-Contracts.sol", "latest"); + } + + /** + * @dev Sets the addresses of the various contracts needed for the proposal. + */ + function setAddresses() public { + eXOF = contracts.deployed("StableTokenXOF"); + eXOFProxy = contracts.deployed("StableTokenXOFProxy"); + celo = contracts.celoRegistry("GoldToken"); + bridgedEUROC = contracts.dependency("BridgedUSDC"); + breakerBox = contracts.deployed("BreakerBox"); + medianDeltaBreaker = contracts.deployed("MedianDeltaBreaker"); + valueDeltaBreaker = contracts.deployed("ValueDeltaBreaker"); + nonrecoverableValueDeltaBreaker = contracts.deployed("NonrecoverableValueDeltaBreaker"); + brokerProxy = contracts.deployed("BrokerProxy"); + biPoolManagerProxy = contracts.deployed("BiPoolManagerProxy"); + sortedOraclesProxy = contracts.celoRegistry("SortedOracles"); + } + + /** + * @dev Setups up various configuration structs. + * This function is called by the governance script runner. + */ + function setUpConfigs() public { + // Create pool configurations + MU04Config.MU04 memory config = MU04Config.get(contracts); + + // Set the exchange ID for the reference rate feed + for (uint i = 0; i < config.pools.length; i++) { + referenceRateFeedIDToExchangeId[config.pools[i].referenceRateFeedID] = getExchangeId( + config.pools[i].asset0, + config.pools[i].asset1, + config.pools[i].isConstantSum + ); + } + } + + function run() public { + prepare(); + address governance = contracts.celoRegistry("Governance"); + ICeloGovernance.Transaction[] memory _transactions = buildProposal(); + + vm.startBroadcast(Chain.deployerPrivateKey()); + { + createProposal(_transactions, "MU04", governance); + } + vm.stopBroadcast(); + } + + function buildProposal() public returns (ICeloGovernance.Transaction[] memory) { + require(transactions.length == 0, "buildProposal() should only be called once"); + MU04Config.MU04 memory config = MU04Config.get(contracts); + + proposal_initializeEXOFToken(config); + proposal_addEXOFToReserves(); + proposal_addEXOFToRegistry(); + proposal_enableGasPaymentsWithEXOF(); + proposal_configureEXOFConstitutionParameters(); + proposal_createExchanges(config); + proposal_configureTradingLimits(config); + proposal_configureBreakerBox(config); + proposal_configureMedianDeltaBreakers(config); + proposal_configureValueDeltaBreaker(config); + proposal_configureNonrecoverableValueDeltaBreaker(config); + } + + /** + * @notice Configures the eXOF token + */ + function proposal_initializeEXOFToken(MU04Config.MU04 memory config) private { + StableTokenXOFProxy _eXOFProxy = StableTokenXOFProxy(eXOFProxy); + if (_eXOFProxy._getImplementation() == address(0)) { + transactions.push( + ICeloGovernance.Transaction( + 0, + eXOFProxy, + abi.encodeWithSelector( + _eXOFProxy._setAndInitializeImplementation.selector, + eXOF, + abi.encodeWithSelector( + StableTokenXOF(0).initialize.selector, + config.stableTokenXOF.name, + config.stableTokenXOF.symbol, + config.stableTokenXOF.decimals, + config.stableTokenXOF.registryAddress, + config.stableTokenXOF.inflationRate, + config.stableTokenXOF.inflationFactorUpdatePeriod, + config.stableTokenXOF.initialBalanceAddresses, + config.stableTokenXOF.initialBalanceValues, + config.stableTokenXOF.exchangeIdentifier + ) + ) + ) + ); + } else { + console.log("Skipping StableTokenXOFProxy is already initialized"); + } + } + + /** + * @notice adds eXOF token to the partial and main reserve + */ + function proposal_addEXOFToReserves() private { + address payable partialReserveProxy = contracts.deployed("PartialReserveProxy"); + if (IReserve(partialReserveProxy).isStableAsset(eXOFProxy) == false) { + transactions.push( + ICeloGovernance.Transaction( + 0, + partialReserveProxy, + abi.encodeWithSelector(IReserve(0).addToken.selector, eXOFProxy) + ) + ); + } else { + console.log("Token already added to the partial reserve, skipping: %s", eXOFProxy); + } + + address payable mainReserveProxy = contracts.deployed("ReserveProxy"); + if (IReserve(mainReserveProxy).isStableAsset(eXOFProxy) == false) { + transactions.push( + ICeloGovernance.Transaction( + 0, + mainReserveProxy, + abi.encodeWithSelector(IReserve(0).addToken.selector, eXOFProxy) + ) + ); + } else { + console.log("Token already added to the main reserve, skipping: %s", eXOFProxy); + } + } + + /** + * @notice Adds eXOF to the registry + */ + function proposal_addEXOFToRegistry() private { + transactions.push( + ICeloGovernance.Transaction( + 0, + REGISTRY_ADDRESS, + abi.encodeWithSelector(IRegistry(0).setAddressFor.selector, "StableTokenXOF", eXOFProxy) + ) + ); + } + + /** + * @notice enable gas payments with XOF + */ + function proposal_enableGasPaymentsWithEXOF() private { + address feeCurrencyWhitelistProxy = contracts.celoRegistry("FeeCurrencyWhitelist"); + transactions.push( + ICeloGovernance.Transaction( + 0, + feeCurrencyWhitelistProxy, + abi.encodeWithSelector(IFeeCurrencyWhitelist(0).addToken.selector, eXOFProxy) + ) + ); + } + + /** + * @notice configure eXOF constitution parameters see cBRl GCP for reference + */ + function proposal_configureEXOFConstitutionParameters() private { + bytes4[] memory functionSelectors = Arrays.bytes4s( + getSelector("setRegistry(address)"), + getSelector("setInflationParameters(uint256,uint256)"), + getSelector("transfer(address,uint256)"), + getSelector("transferWithComment(address,uint256,string)"), + getSelector("approve(address,uint256)") + ); + uint256[] memory thresholds = Arrays.uints(0.9 * 1e24, 0.6 * 1e24, 0.6 * 1e24, 0.6 * 1e24, 0.6 * 1e24); + address governanceProxy = contracts.celoRegistry("Governance"); + + for (uint256 i = 0; i < functionSelectors.length; i++) { + transactions.push( + ICeloGovernance.Transaction( + 0, + governanceProxy, + abi.encodeWithSelector( + ICeloGovernance(0).setConstitution.selector, + eXOFProxy, + functionSelectors[i], + thresholds[i] + ) + ) + ); + } + } + + /** + * @notice Creates the exchanges for the new pools. + */ + function proposal_createExchanges(MU04Config.MU04 memory config) private { + // Get the address of the pricing modules + IPricingModule constantProduct = IPricingModule(contracts.deployed("ConstantProductPricingModule")); + IPricingModule constantSum = IPricingModule(contracts.deployed("ConstantSumPricingModule")); + + for (uint256 i = 0; i < config.pools.length; i++) { + Config.Pool memory poolConfig = config.pools[i]; + IBiPoolManager.PoolExchange memory pool = IBiPoolManager.PoolExchange({ + asset0: poolConfig.asset0, + asset1: poolConfig.asset1, + pricingModule: poolConfig.isConstantSum ? constantSum : constantProduct, + bucket0: 0, + bucket1: 0, + lastBucketUpdate: 0, + config: IBiPoolManager.PoolConfig({ + spread: FixidityLib.wrap(poolConfig.spread.unwrap()), + referenceRateFeedID: poolConfig.referenceRateFeedID, + referenceRateResetFrequency: poolConfig.referenceRateResetFrequency, + minimumReports: poolConfig.minimumReports, + stablePoolResetSize: poolConfig.stablePoolResetSize + }) + }); + + transactions.push( + ICeloGovernance.Transaction( + 0, + contracts.deployed("BiPoolManagerProxy"), + abi.encodeWithSelector(IBiPoolManager(0).createExchange.selector, pool) + ) + ); + } + } + + /** + * @notice This function creates the transactions to configure the trading limits. + */ + function proposal_configureTradingLimits(MU04Config.MU04 memory config) private { + address brokerProxyAddress = contracts.deployed("BrokerProxy"); + for (uint256 i = 0; i < config.pools.length; i++) { + Config.Pool memory poolConfig = config.pools[i]; + + if (Config.tradingLimitConfigToFlag(poolConfig.asset0limits) > 0) { + // Set the trading limit for asset0 of the pool + transactions.push( + ICeloGovernance.Transaction( + 0, + brokerProxyAddress, + abi.encodeWithSelector( + Broker(0).configureTradingLimit.selector, + referenceRateFeedIDToExchangeId[poolConfig.referenceRateFeedID], + poolConfig.asset0, + TradingLimits.Config({ + timestep0: poolConfig.asset0limits.timeStep0, + timestep1: poolConfig.asset0limits.timeStep1, + limit0: poolConfig.asset0limits.limit0, + limit1: poolConfig.asset0limits.limit1, + limitGlobal: poolConfig.asset0limits.limitGlobal, + flags: Config.tradingLimitConfigToFlag(poolConfig.asset0limits) + }) + ) + ) + ); + } + + if (Config.tradingLimitConfigToFlag(poolConfig.asset1limits) > 0) { + // Set the trading limit for asset1 of the pool + transactions.push( + ICeloGovernance.Transaction( + 0, + brokerProxyAddress, + abi.encodeWithSelector( + Broker(0).configureTradingLimit.selector, + referenceRateFeedIDToExchangeId[poolConfig.referenceRateFeedID], + poolConfig.asset1, + TradingLimits.Config({ + timestep0: poolConfig.asset1limits.timeStep0, + timestep1: poolConfig.asset1limits.timeStep1, + limit0: poolConfig.asset1limits.limit0, + limit1: poolConfig.asset1limits.limit1, + limitGlobal: poolConfig.asset1limits.limitGlobal, + flags: Config.tradingLimitConfigToFlag(poolConfig.asset1limits) + }) + ) + ) + ); + } + } + } + + /** + * @notice This function creates the transactions to configure the Breakerbox. + */ + function proposal_configureBreakerBox(MU04Config.MU04 memory config) private { + // Add the new rate feeds to breaker box + transactions.push( + ICeloGovernance.Transaction( + 0, + breakerBox, + abi.encodeWithSelector( + BreakerBox(0).addRateFeeds.selector, + Arrays.addresses( + contracts.celoRegistry("StableTokenXOF"), + contracts.dependency("EUROCXOFRateFeedAddr"), + contracts.dependency("EUROCEURRateFeedAddr") + ) + ) + ) + ); + + // Add the Nonrecoverable Value Delta Breaker 2 to the breaker box with the trading mode '3' -> trading halted + if (!BreakerBox(breakerBox).isBreaker(nonrecoverableValueDeltaBreaker)) { + transactions.push( + ICeloGovernance.Transaction( + 0, + breakerBox, + abi.encodeWithSelector(BreakerBox(0).addBreaker.selector, nonrecoverableValueDeltaBreaker, 3) + ) + ); + } + + // Set rate feed dependencies + for (uint i = 0; i < config.rateFeeds.length; i++) { + Config.RateFeed memory rateFeed = config.rateFeeds[i]; + if (rateFeed.dependentRateFeeds.length > 0) { + transactions.push( + ICeloGovernance.Transaction( + 0, + breakerBox, + abi.encodeWithSelector( + BreakerBox(0).setRateFeedDependencies.selector, + rateFeed.rateFeedID, + rateFeed.dependentRateFeeds + ) + ) + ); + } + } + + for (uint256 i = 0; i < config.rateFeeds.length; i++) { + Config.RateFeed memory rateFeed = config.rateFeeds[i]; + // Enable Median Delta Breaker for rate feed + if (rateFeed.medianDeltaBreaker0.enabled) { + transactions.push( + ICeloGovernance.Transaction( + 0, + breakerBox, + abi.encodeWithSelector(BreakerBox(0).toggleBreaker.selector, medianDeltaBreaker, rateFeed.rateFeedID, true) + ) + ); + } + + // Enable Value Delta Breaker for rate feeds + if (rateFeed.valueDeltaBreaker0.enabled) { + transactions.push( + ICeloGovernance.Transaction( + 0, + breakerBox, + abi.encodeWithSelector(BreakerBox(0).toggleBreaker.selector, valueDeltaBreaker, rateFeed.rateFeedID, true) + ) + ); + } + + // Enable Nonrecoverable Value Delta Breaker for rate feeds + if (rateFeed.valueDeltaBreaker1.enabled) { + transactions.push( + ICeloGovernance.Transaction( + 0, + breakerBox, + abi.encodeWithSelector( + BreakerBox(0).toggleBreaker.selector, + nonrecoverableValueDeltaBreaker, + rateFeed.rateFeedID, + true + ) + ) + ); + } + } + } + + /** + * @notice This function creates the transactions to configure the Median Delta Breaker. + */ + function proposal_configureMedianDeltaBreakers(MU04Config.MU04 memory config) private { + // Set the cooldown time + transactions.push( + ICeloGovernance.Transaction( + 0, + medianDeltaBreaker, + abi.encodeWithSelector( + MedianDeltaBreaker(0).setCooldownTime.selector, + Arrays.addresses(config.CELOXOF.rateFeedID), + Arrays.uints(config.CELOXOF.medianDeltaBreaker0.cooldown) + ) + ) + ); + // Set the rate change threshold + transactions.push( + ICeloGovernance.Transaction( + 0, + medianDeltaBreaker, + abi.encodeWithSelector( + MedianDeltaBreaker(0).setRateChangeThresholds.selector, + Arrays.addresses(config.CELOXOF.rateFeedID), + Arrays.uints(config.CELOXOF.medianDeltaBreaker0.threshold.unwrap()) + ) + ) + ); + // Set ema smoothing factor + transactions.push( + ICeloGovernance.Transaction( + 0, + medianDeltaBreaker, + abi.encodeWithSelector( + MedianDeltaBreaker(0).setSmoothingFactor.selector, + config.CELOXOF.rateFeedID, + config.CELOXOF.medianDeltaBreaker0.smoothingFactor + ) + ) + ); + } + + /** + * @notice This function creates the transactions to configure the first Value Delta Breaker . + */ + function proposal_configureValueDeltaBreaker(MU04Config.MU04 memory config) private { + address[] memory valueDeltaBreakerRateFeeds = Arrays.addresses( + config.EUROCXOF.rateFeedID, + config.EUROCEUR.rateFeedID + ); + uint[] memory valueDeltaBreakerCooldownTimes = Arrays.uints( + config.EUROCXOF.valueDeltaBreaker0.cooldown, + config.EUROCEUR.valueDeltaBreaker0.cooldown + ); + uint[] memory valueDeltaBreakerThresholds = Arrays.uints( + config.EUROCXOF.valueDeltaBreaker0.threshold.unwrap(), + config.EUROCEUR.valueDeltaBreaker0.threshold.unwrap() + ); + uint[] memory valueDeltaBreakerReferenceValues = Arrays.uints( + config.EUROCXOF.valueDeltaBreaker0.referenceValue, + config.EUROCEUR.valueDeltaBreaker0.referenceValue + ); + + // Set the cooldown times + transactions.push( + ICeloGovernance.Transaction( + 0, + valueDeltaBreaker, + abi.encodeWithSelector( + ValueDeltaBreaker(0).setCooldownTimes.selector, + valueDeltaBreakerRateFeeds, + valueDeltaBreakerCooldownTimes + ) + ) + ); + // Set the rate change thresholds + transactions.push( + ICeloGovernance.Transaction( + 0, + valueDeltaBreaker, + abi.encodeWithSelector( + ValueDeltaBreaker(0).setRateChangeThresholds.selector, + valueDeltaBreakerRateFeeds, + valueDeltaBreakerThresholds + ) + ) + ); + // Set the reference values + transactions.push( + ICeloGovernance.Transaction( + 0, + valueDeltaBreaker, + abi.encodeWithSelector( + ValueDeltaBreaker(0).setReferenceValues.selector, + valueDeltaBreakerRateFeeds, + valueDeltaBreakerReferenceValues + ) + ) + ); + } + + /** + * @notice This function creates the transactions to configure the second Value Delta Breaker . + */ + function proposal_configureNonrecoverableValueDeltaBreaker(MU04Config.MU04 memory config) private { + // Set the cooldown times + transactions.push( + ICeloGovernance.Transaction( + 0, + nonrecoverableValueDeltaBreaker, + abi.encodeWithSelector( + ValueDeltaBreaker(0).setCooldownTimes.selector, + Arrays.addresses(config.EUROCXOF.rateFeedID), + Arrays.uints(config.EUROCXOF.valueDeltaBreaker1.cooldown) + ) + ) + ); + + // Set the rate change thresholds + transactions.push( + ICeloGovernance.Transaction( + 0, + nonrecoverableValueDeltaBreaker, + abi.encodeWithSelector( + ValueDeltaBreaker(0).setRateChangeThresholds.selector, + Arrays.addresses(config.EUROCXOF.rateFeedID), + Arrays.uints(config.EUROCXOF.valueDeltaBreaker1.threshold.unwrap()) + ) + ) + ); + + // Set the reference values + transactions.push( + ICeloGovernance.Transaction( + 0, + nonrecoverableValueDeltaBreaker, + abi.encodeWithSelector( + ValueDeltaBreaker(0).setReferenceValues.selector, + Arrays.addresses(config.EUROCXOF.rateFeedID), + Arrays.uints(config.EUROCXOF.valueDeltaBreaker1.referenceValue) + ) + ) + ); + } + + /** + * @notice Helper function to get the exchange ID for a pool. + */ + function getExchangeId(address asset0, address asset1, bool isConstantSum) internal view returns (bytes32) { + return + keccak256( + abi.encodePacked( + IERC20Metadata(asset0).symbol(), + IERC20Metadata(asset1).symbol(), + isConstantSum ? "ConstantSum" : "ConstantProduct" + ) + ); + } + + /** + * @notice Helper function to get the function selector for a function. + */ + function getSelector(string memory _func) internal pure returns (bytes4) { + return bytes4(keccak256(bytes(_func))); + } +} diff --git a/script/upgrades/MU04/deploy/MU04-02-Create-Nonupgradeable-Contracts.sol b/script/upgrades/MU04/deploy/MU04-02-Create-Nonupgradeable-Contracts.sol new file mode 100644 index 00000000..4fe186f4 --- /dev/null +++ b/script/upgrades/MU04/deploy/MU04-02-Create-Nonupgradeable-Contracts.sol @@ -0,0 +1,72 @@ +// SPDX-License-Identifier: GPL-3.0-or-later +pragma solidity ^0.5.13; + +import { Script } from "script/utils/Script.sol"; +import { Chain } from "script/utils/Chain.sol"; +import { console2 } from "forge-std/Script.sol"; + +import { ISortedOracles } from "mento-core-2.2.0/interfaces/ISortedOracles.sol"; +import { ValueDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/ValueDeltaBreaker.sol"; + +contract NonrecoverableValueDeltaBreaker is ValueDeltaBreaker { + constructor( + uint256 _defaultCooldownTime, + uint256 _defaultRateChangeThreshold, + ISortedOracles _sortedOracles, + address[] memory rateFeedIDs, + uint256[] memory rateChangeThresholds, + uint256[] memory cooldownTimes + ) + public + ValueDeltaBreaker( + _defaultCooldownTime, + _defaultRateChangeThreshold, + _sortedOracles, + rateFeedIDs, + rateChangeThresholds, + cooldownTimes + ) + {} +} + +/* + yarn deploy -n -u MU04 -s MU04-02-Create-Nonupgradeable-Contracts.sol +*/ +contract MU04_CreateNonupgradeableContracts is Script { + NonrecoverableValueDeltaBreaker private nonrecoverableValueDeltaBreaker; + + function run() public { + address governance = contracts.celoRegistry("Governance"); + address sortedOracles = contracts.celoRegistry("SortedOracles"); + + uint256 _defaultCooldown = 0; + uint256 _defaultThreshold = 0; + + address[] memory __rateFeedIDs = new address[](0); + uint256[] memory __rateChangeThresholds = new uint256[](0); + uint256[] memory __cooldowns = new uint256[](0); + + vm.startBroadcast(Chain.deployerPrivateKey()); + { + nonrecoverableValueDeltaBreaker = new NonrecoverableValueDeltaBreaker( + _defaultCooldown, + _defaultThreshold, + ISortedOracles(sortedOracles), + __rateFeedIDs, + __rateChangeThresholds, + __cooldowns + ); + nonrecoverableValueDeltaBreaker.transferOwnership(governance); + } + vm.stopBroadcast(); + + console2.log("----------"); + console2.log("ValueDeltaBreaker2 deployed at: ", address(nonrecoverableValueDeltaBreaker)); + console2.log( + "ValueDeltaBreaker2(%s) ownership transferred to %s", + address(nonrecoverableValueDeltaBreaker), + governance + ); + console2.log("----------"); + } +} diff --git a/script/utils/Arrays.sol b/script/utils/Arrays.sol index f5fdd915..d2cf1887 100644 --- a/script/utils/Arrays.sol +++ b/script/utils/Arrays.sol @@ -130,6 +130,16 @@ library Arrays { return arr; } + function bytes4s(bytes4 e0, bytes4 e1, bytes4 e2, bytes4 e3, bytes4 e4) internal pure returns (bytes4[] memory arr) { + arr = new bytes4[](5); + arr[0] = bytes4(e0); + arr[1] = bytes4(e1); + arr[2] = bytes4(e2); + arr[3] = bytes4(e3); + arr[4] = bytes4(e4); + return arr; + } + function bytes32s(bytes32 e0) internal pure returns (bytes32[] memory arr) { arr = new bytes32[](1); arr[0] = e0; diff --git a/script/utils/Config.sol b/script/utils/Config.sol index 15611498..bf69460f 100644 --- a/script/utils/Config.sol +++ b/script/utils/Config.sol @@ -87,6 +87,10 @@ library Config { * @dev List of Value Delta RateFeed Configurations for the rate feed. */ ValueDeltaBreaker valueDeltaBreaker0; + /** + * @dev List of Value Delta RateFeed Configurations for the rate feed. + */ + ValueDeltaBreaker valueDeltaBreaker1; /** * @dev List of dependent rate feeds. */ @@ -227,6 +231,45 @@ library Config { uint256[] collateralAssetDailySpendingRatios; } + struct StableToken { + /** + * @dev The name of the stable token. + */ + string name; + /** + * @dev The symbol of the stable token. + */ + string symbol; + /** + * @dev The number of decimal places for the stable token. + */ + uint8 decimals; + /** + * @dev The address of the celo registry + */ + address registryAddress; + /** + * @dev the inflation rate ... TODO. + */ + uint256 inflationRate; + /** + * @dev TODO + */ + uint256 inflationFactorUpdatePeriod; + /** + * @dev + */ + address[] initialBalanceAddresses; + /** + * @dev + */ + uint256[] initialBalanceValues; + /** + * @dev + */ + string exchangeIdentifier; + } + /** * @dev Helper to create an empty trading limit config. */ From e3e2b864ec9e01163460f0aadcde9149a7923a64 Mon Sep 17 00:00:00 2001 From: philbow61 Date: Mon, 14 Aug 2023 15:35:12 +0200 Subject: [PATCH 02/64] test: started with MU04 deployment checks --- lib/mento-core-2.2.0 | 2 +- script/upgrades/MU04/MU04Checks.sol | 616 ++++++++++++++++++++++++++++ 2 files changed, 617 insertions(+), 1 deletion(-) create mode 100644 script/upgrades/MU04/MU04Checks.sol diff --git a/lib/mento-core-2.2.0 b/lib/mento-core-2.2.0 index 619461d2..c2e344eb 160000 --- a/lib/mento-core-2.2.0 +++ b/lib/mento-core-2.2.0 @@ -1 +1 @@ -Subproject commit 619461d22513f16c55a9d51c858f4bd6def0e2f2 +Subproject commit c2e344ebd5f3018253cf26cb39a50f81d8db7c21 diff --git a/script/upgrades/MU04/MU04Checks.sol b/script/upgrades/MU04/MU04Checks.sol new file mode 100644 index 00000000..fbbff749 --- /dev/null +++ b/script/upgrades/MU04/MU04Checks.sol @@ -0,0 +1,616 @@ +// SPDX-License-Identifier: GPL-3.0-or-later +pragma solidity ^0.5.13; +pragma experimental ABIEncoderV2; + +import { console2 as console } from "forge-std/Script.sol"; +import { Test } from "forge-std/Test.sol"; +import { PrecompileHandler } from "celo-foundry/PrecompileHandler.sol"; +import { IERC20 } from "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol"; + +import { Script } from "script/utils/Script.sol"; +import { Chain } from "script/utils/Chain.sol"; +import { Arrays } from "script/utils/Arrays.sol"; + +import { FixidityLib } from "mento-core-2.2.0/common/FixidityLib.sol"; +import { IBiPoolManager } from "mento-core-2.2.0/interfaces/IBiPoolManager.sol"; +import { IBroker } from "mento-core-2.2.0/interfaces/IBroker.sol"; +import { IERC20Metadata } from "mento-core-2.2.0/common/interfaces/IERC20Metadata.sol"; + +import { BiPoolManagerProxy } from "mento-core-2.2.0/proxies/BiPoolManagerProxy.sol"; +import { StableTokenXOFProxy } from "mento-core-2.2.0/legacy/proxies/StableTokenXOFProxy.sol"; +import { StableTokenXOF } from "mento-core-2.2.0/legacy/StableTokenXOF.sol"; +import { Broker } from "mento-core-2.2.0/swap/Broker.sol"; +import { BiPoolManager } from "mento-core-2.2.0/swap/BiPoolManager.sol"; +import { Exchange } from "mento-core-2.2.0/legacy/Exchange.sol"; +import { TradingLimits } from "mento-core-2.2.0/libraries/TradingLimits.sol"; +import { BreakerBox } from "mento-core-2.2.0/oracles/BreakerBox.sol"; +import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; +import { Reserve } from "mento-core-2.2.0/swap/Reserve.sol"; +import { MedianDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/MedianDeltaBreaker.sol"; +import { ValueDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/ValueDeltaBreaker.sol"; +import { ConstantSumPricingModule } from "mento-core-2.2.0/swap/ConstantSumPricingModule.sol"; +import { SafeMath } from "celo-foundry/test/SafeMath.sol"; +import { Proxy } from "mento-core-2.2.0/common/Proxy.sol"; + +import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; + +import { MU04Config, Config } from "./Config.sol"; + +/** + * @title IBrokerWithCasts + * @notice Interface for Broker with tuple -> struct casting + * @dev This is used to access the internal trading limits + * config as a struct as opposed to a tuple. + */ +interface IBrokerWithCasts { + function tradingLimitsConfig(bytes32 id) external view returns (TradingLimits.Config memory); +} + +contract MU04Checks is Script, Test { + using TradingLimits for TradingLimits.Config; + using FixidityLib for FixidityLib.Fraction; + using SafeMath for uint256; + + address public celoToken; + address public cUSD; + address public cEUR; + address public cBRL; + address payable public eXOF; + address public bridgedUSDC; + address public bridgedEUROC; + address public governance; + address public medianDeltaBreaker; + address public valueDeltaBreaker; + address public nonrecoverableValueDeltaBreaker; + address public biPoolManager; + address payable sortedOraclesProxy; + address public sortedOracles; + address public constantSum; + address public constantProduct; + address payable biPoolManagerProxy; + address public reserve; + address public broker; + address public breakerBox; + + function setUp() public { + new PrecompileHandler(); // needed for reserve CELO transfer checks + + // Load addresses from deployments + contracts.load("MU01-00-Create-Proxies", "latest"); + contracts.load("MU01-01-Create-Nonupgradeable-Contracts", "latest"); + contracts.load("MU03-01-Create-Nonupgradeable-Contracts", "latest"); + contracts.load("MU03-02-Create-Implementations", "latest"); + contracts.load("MU04-00-Create-Proxies", "latest"); + contracts.load("MU04-01-Create-Implementations", "latest"); + contracts.load("MU04-02-Create-Nonupgradeable-Contracts", "latest"); + + // Get proxy addresses + eXOF = contracts.celoRegistry("StableTokenXOF"); + cUSD = contracts.celoRegistry("StableToken"); + cEUR = contracts.celoRegistry("StableTokenEUR"); + cBRL = contracts.celoRegistry("StableTokenBRL"); + reserve = contracts.deployed("PartialReserveProxy"); + celoToken = contracts.celoRegistry("GoldToken"); + broker = contracts.celoRegistry("Broker"); + governance = contracts.celoRegistry("Governance"); + sortedOraclesProxy = address(uint160(contracts.celoRegistry("SortedOracles"))); + + // Get Deployment addresses + bridgedUSDC = contracts.dependency("BridgedUSDC"); + bridgedEUROC = contracts.dependency("BridgedEUROC"); + breakerBox = contracts.deployed("BreakerBox"); + medianDeltaBreaker = contracts.deployed("MedianDeltaBreaker"); + valueDeltaBreaker = contracts.deployed("ValueDeltaBreaker"); + nonrecoverableValueDeltaBreaker = contracts.deployed("NonrecoverableValueDeltaBreaker"); + biPoolManager = contracts.deployed("BiPoolManager"); + constantSum = contracts.deployed("ConstantSumPricingModule"); + constantProduct = contracts.deployed("ConstantProductPricingModule"); + biPoolManagerProxy = contracts.deployed("BiPoolManagerProxy"); + sortedOracles = contracts.deployed("SortedOracles"); + } + + function run() public { + setUp(); + verifyExchanges(); + verifyCircuitBreaker(); + } + + function verifyEXOFStableToken() internal view { + StableTokenXOFProxy stableTokenXOFProxy = StableTokenXOFProxy(eXOF); + address eXOFDeployedImplementation = contracts.deployed("StableTokenXOF"); + + address eXOFImplementation = stableTokenXOFProxy._getImplementation(); + if (eXOFImplementation != eXOFDeployedImplementation) { + console.log( + "The implementation from StableTokenXOFProxy: %s does not match the deployed address: %s.", + eXOFImplementation, + eXOFDeployedImplementation + ); + revert("Deployed StableTokenXOF does not match what proxy points to. See logs."); + } + console.log("\tStableTokenXOFProxy has the correct implementation address 🫡"); + } + + /* ================================================================ */ + /* =========================== Exchanges ========================== */ + /* ================================================================ */ + + function verifyExchanges() internal { + MU04Config.MU04 memory config = MU04Config.get(contracts); + + console.log("== Verifying exchanges... =="); + + verifyPoolExchange(config); + verifyPoolConfig(config); + verifyTradingLimits(config); + } + + function verifyPoolExchange(MU04Config.MU04 memory config) internal view { + bytes32[] memory exchanges = BiPoolManager(biPoolManagerProxy).getExchangeIds(); + + // check configured pools against the config + require( + exchanges.length == config.pools.length + 7, + "Number of expected pools does not match the number of deployed pools." + ); + + for (uint256 i = 0; i < config.pools.length; i++) { + bytes32 exchangeId = getExchangeId(config.pools[i].asset0, config.pools[i].asset1, config.pools[i].isConstantSum); + + IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeId); + Config.Pool memory poolConfig = config.pools[i]; + + // verify asset0 of the deployed pool against the config + if (pool.asset0 != poolConfig.asset0) { + console.log( + "The asset0 of deployed pool: %s does not match the expected asset0: %s.", + pool.asset0, + poolConfig.asset0 + ); + revert("asset0 of pool does not match the expected asset0. See logs."); + } + + // verify asset1 of the deployed pool against the config + if (pool.asset1 != poolConfig.asset1) { + console.log( + "The asset1 of deployed pool: %s does not match the expected asset1: %s.", + pool.asset1, + poolConfig.asset1 + ); + revert("asset1 of pool does not match the expected asset1. See logs."); + } + + if (poolConfig.isConstantSum) { + if (address(pool.pricingModule) != constantSum) { + console.log( + "The pricing module of deployed pool: %s does not match the expected pricing module: %s.", + address(pool.pricingModule), + constantSum + ); + revert("pricing module of pool does not match the expected pricing module. See logs."); + } + } else { + if (address(pool.pricingModule) != constantProduct) { + console.log( + "The pricing module of deployed pool: %s does not match the expected pricing module: %s.", + address(pool.pricingModule), + constantProduct + ); + revert("pricing module of pool does not match the expected pricing module. See logs."); + } + } + // verify asset0 is always a stable asset + require( + pool.asset0 == cUSD || pool.asset0 == cEUR || pool.asset0 == cBRL || pool.asset0 == eXOF, + "asset0 is not a stable asset in the exchange" + ); + // verify asset1 is always a collateral asset + require( + pool.asset1 == celoToken || pool.asset1 == bridgedUSDC || pool.asset1 == bridgedEUROC, + "asset1 is not CELO or bridgedUSDC in the exchange" + ); + } + console.log("\tPoolExchange correctly configured 🤘🏼"); + } + + function verifyPoolConfig(MU04Config.MU04 memory config) internal view { + for (uint256 i = 0; i < config.pools.length; i++) { + bytes32 exchangeId = getExchangeId(config.pools[i].asset0, config.pools[i].asset1, config.pools[i].isConstantSum); + IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeId); + Config.Pool memory poolConfig = config.pools[i]; + + if (pool.config.spread.unwrap() != poolConfig.spread.unwrap()) { + console.log( + "The spread of deployed pool: %s does not match the expected spread: %s.", + pool.config.spread.unwrap(), + poolConfig.spread.unwrap() + ); + revert("spread of pool does not match the expected spread. See logs."); + } + + if (pool.config.referenceRateFeedID != poolConfig.referenceRateFeedID) { + console.log( + "The referenceRateFeedID of deployed pool: %s does not match the expected referenceRateFeedID: %s.", + pool.config.referenceRateFeedID, + poolConfig.referenceRateFeedID + ); + revert("referenceRateFeedID of pool does not match the expected referenceRateFeedID. See logs."); + } + + if (pool.config.minimumReports != poolConfig.minimumReports) { + console.log( + "The minimumReports of deployed pool: %s does not match the expected minimumReports: %s.", + pool.config.minimumReports, + poolConfig.minimumReports + ); + revert("minimumReports of pool does not match the expected minimumReports. See logs."); + } + + if (pool.config.referenceRateResetFrequency != poolConfig.referenceRateResetFrequency) { + console.log( + "The referenceRateResetFrequency of deployed pool: %s does not match the expected: %s.", + pool.config.referenceRateResetFrequency, + poolConfig.referenceRateResetFrequency + ); + revert( + "referenceRateResetFrequency of pool does not match the expected referenceRateResetFrequency. See logs." + ); + } + + if (pool.config.stablePoolResetSize != poolConfig.stablePoolResetSize) { + console.log( + "The stablePoolResetSize of deployed pool: %s does not match the expected stablePoolResetSize: %s.", + pool.config.stablePoolResetSize, + poolConfig.stablePoolResetSize + ); + revert("stablePoolResetSize of pool does not match the expected stablePoolResetSize. See logs."); + } + } + console.log("\tPool config is correctly configured 🤘🏼"); + } + + function verifyTradingLimits(MU04Config.MU04 memory config) internal view { + IBrokerWithCasts _broker = IBrokerWithCasts(address(broker)); + + for (uint256 i = 0; i < config.pools.length; i++) { + bytes32 exchangeId = getExchangeId(config.pools[i].asset0, config.pools[i].asset1, config.pools[i].isConstantSum); + IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeId); + Config.Pool memory poolConfig = config.pools[i]; + + bytes32 limitId = exchangeId ^ bytes32(uint256(uint160(pool.asset0))); + TradingLimits.Config memory limits = _broker.tradingLimitsConfig(limitId); + + // verify configured trading limits for all pools + if (poolConfig.asset0limits.limit0 != limits.limit0) { + console.log("limit0 for %s, %s was not set ❌", pool.asset0, pool.asset1); + revert("Not all trading limits were configured correctly."); + } + if (poolConfig.asset0limits.limit1 != limits.limit1) { + console.log("limit1 for %s, %s was not set ❌", pool.asset0, pool.asset1); + revert("Not all trading limits were configured correctly."); + } + if (poolConfig.asset0limits.limitGlobal != limits.limitGlobal) { + console.log("limitGlobal for %s, %s was not set ❌", pool.asset0, pool.asset1); + revert("Not all trading limits were configured correctly."); + } + if (poolConfig.asset0limits.timeStep0 != limits.timestep0) { + console.log("timestep0 for %s, %s was not set ❌", pool.asset0, pool.asset1); + revert("Not all trading limits were configured correctly."); + } + if (poolConfig.asset0limits.timeStep1 != limits.timestep1) { + console.log("timestep1 for %s, %s was not set ❌", pool.asset0, pool.asset1); + revert("Not all trading limits were configured correctly."); + } + if (Config.tradingLimitConfigToFlag(poolConfig.asset0limits) != limits.flags) { + console.log("flags for %s, %s was not set ❌", pool.asset0, pool.asset1); + revert("Not all trading limits were configured correctly."); + } + } + console.log("\tTrading limits set for all exchanges 🔒"); + } + + /* ================================================================ */ + /* ======================== Circuit Breaker ======================= */ + /* ================================================================ */ + + function verifyCircuitBreaker() internal { + MU04Config.MU04 memory config = MU04Config.get(contracts); + + console.log("\n== Checking circuit breaker... =="); + + verifyBreakerBox(config); + verifyMedianDeltaBreaker(config); + verifyValueDeltaBreaker(config); + } + + function verifyBreakerBox(MU04Config.MU04 memory config) internal view { + // verify that breakers were set with trading mode 3 + /* if (BreakerBox(breakerBox).breakerTradingMode(nonrecoverableValueDeltaBreaker) != 3) { + console.log("The Nonrecoverable ValueDeltaBreaker was not set with trading halted ❌"); + revert("Nonrecoverable ValueDeltaBreaker was not set with trading halted"); + } + console.log("\t Nonrecoverable ValueDeltaBreaker set with trading mode 3"); + + // verify that rate feed dependencies were configured correctly + address EUROCXOFDependency = BreakerBox(breakerBox).rateFeedDependencies(config.EUROCXOF.rateFeedID, 0); + require( + EUROCXOFDependency == contracts.dependency("EUROCEURRateFeedAddr"), + "EUROC/XOF rate feed dependency not set correctly" + ); + console.log("\tRate feed dependencies configured correctly 🗳️"); + + // verify that MedianDeltaBreaker && ValueDeltaBreakers were enabled for rateFeeds + for (uint256 i = 0; i < config.rateFeeds.length; i++) { + Config.RateFeed memory rateFeed = config.rateFeeds[i]; + + if (rateFeed.medianDeltaBreaker0.enabled) { + bool medianDeltaEnabled = BreakerBox(breakerBox).isBreakerEnabled(medianDeltaBreaker, rateFeed.rateFeedID); + if (!medianDeltaEnabled) { + console.log("MedianDeltaBreaker not enabled for rate feed %s", rateFeed.rateFeedID); + revert("MedianDeltaBreaker not enabled for all rate feeds"); + } + + if (rateFeed.valueDeltaBreaker0.enabled) { + bool valueDeltaEnabled = BreakerBox(breakerBox).isBreakerEnabled(valueDeltaBreaker, rateFeed.rateFeedID); + if (!valueDeltaEnabled) { + console.log("ValueDeltaBreaker not enabled for rate feed %s", rateFeed.rateFeedID); + revert("ValueDeltaBreaker not enabled for all rate feeds"); + } + } + + if (rateFeed.valueDeltaBreaker1.enabled) { + bool nonrecoverableValueDeltaEnabled = BreakerBox(breakerBox).isBreakerEnabled( + nonrecoverableValueDeltaBreaker, + rateFeed.rateFeedID + ); + if (!nonrecoverableValueDeltaEnabled) { + console.log("Nonrecoverable ValueDeltaBreaker not enabled for rate feed %s", rateFeed.rateFeedID); + revert("Nonrecoverable ValueDeltaBreaker not enabled for all rate feeds"); + } + } + } + } + console.log("\tBreakers enabled for all rate feeds 🗳️");*/ + } + + function verifyMedianDeltaBreaker(MU04Config.MU04 memory config) internal view { + // verify that cooldown period, rate change threshold and smoothing factor were set correctly + for (uint256 i = 0; i < config.rateFeeds.length; i++) { + Config.RateFeed memory rateFeed = config.rateFeeds[i]; + + if (rateFeed.medianDeltaBreaker0.enabled) { + uint256 cooldown = MedianDeltaBreaker(medianDeltaBreaker).rateFeedCooldownTime(rateFeed.rateFeedID); + uint256 rateChangeThreshold = MedianDeltaBreaker(medianDeltaBreaker).rateChangeThreshold(rateFeed.rateFeedID); + uint256 smoothingFactor = MedianDeltaBreaker(medianDeltaBreaker).smoothingFactors(rateFeed.rateFeedID); + + // verify cooldown period + verifyCooldownTime(cooldown, rateFeed.medianDeltaBreaker0.cooldown, rateFeed.rateFeedID, false); + + // verify rate change threshold + verifyRateChangeTheshold( + rateChangeThreshold, + rateFeed.medianDeltaBreaker0.threshold.unwrap(), + rateFeed.rateFeedID, + false + ); + + // verify smoothing factor + if (smoothingFactor != rateFeed.medianDeltaBreaker0.smoothingFactor) { + console.log( + "MedianDeltaBreaker smoothing factor not set correctly for the rate feed: %s", + rateFeed.rateFeedID + ); + revert("MedianDeltaBreaker smoothing factor not set correctly for all rate feeds"); + } + } + } + console.log("\tMedianDeltaBreaker cooldown, rate change threshold and smoothing factor set correctly 🔒"); + } + + function verifyValueDeltaBreaker(MU04Config.MU04 memory config) internal view { + // verify that cooldown period, rate change threshold and reference value were set correctly + for (uint256 i = 0; i < config.rateFeeds.length; i++) { + Config.RateFeed memory rateFeed = config.rateFeeds[i]; + + if (rateFeed.valueDeltaBreaker0.enabled) { + uint256 cooldown = ValueDeltaBreaker(valueDeltaBreaker).rateFeedCooldownTime(rateFeed.rateFeedID); + uint256 rateChangeThreshold = ValueDeltaBreaker(valueDeltaBreaker).rateChangeThreshold(rateFeed.rateFeedID); + uint256 referenceValue = ValueDeltaBreaker(valueDeltaBreaker).referenceValues(rateFeed.rateFeedID); + + // verify cooldown period + verifyCooldownTime(cooldown, rateFeed.valueDeltaBreaker0.cooldown, rateFeed.rateFeedID, true); + + // verify rate change threshold + verifyRateChangeTheshold( + rateChangeThreshold, + rateFeed.valueDeltaBreaker0.threshold.unwrap(), + rateFeed.rateFeedID, + true + ); + + // verify refernece value + if (referenceValue != rateFeed.valueDeltaBreaker0.referenceValue) { + console.log("ValueDeltaBreaker reference value not set correctly for the rate feed: %s", rateFeed.rateFeedID); + revert("ValueDeltaBreaker reference values not set correctly for all rate feeds"); + } + } + } + console.log("\tValueDeltaBreaker cooldown, rate change threshold and reference value set correctly 🔒"); + } + + function verifyNonrecoverableValueDeltaBreaker(MU04Config.MU04 memory config) internal view { + // verify that cooldown period, rate change threshold and reference value were set correctly + for (uint256 i = 0; i < config.rateFeeds.length; i++) { + Config.RateFeed memory rateFeed = config.rateFeeds[i]; + + if (rateFeed.valueDeltaBreaker1.enabled) { + uint256 cooldown = ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).rateFeedCooldownTime(rateFeed.rateFeedID); + uint256 rateChangeThreshold = ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).rateChangeThreshold( + rateFeed.rateFeedID + ); + uint256 referenceValue = ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).referenceValues( + rateFeed.rateFeedID + ); + + // verify cooldown period + verifyCooldownTime(cooldown, rateFeed.valueDeltaBreaker0.cooldown, rateFeed.rateFeedID, true); + + // verify rate change threshold + verifyRateChangeTheshold( + rateChangeThreshold, + rateFeed.valueDeltaBreaker0.threshold.unwrap(), + rateFeed.rateFeedID, + true + ); + + // verify refernece value + if (referenceValue != rateFeed.valueDeltaBreaker0.referenceValue) { + console.log( + "Nonrecoverable ValueDeltaBreaker reference value not set correctly for the rate feed: %s", + rateFeed.rateFeedID + ); + revert("Nonrecoverable ValueDeltaBreaker reference values not set correctly for all rate feeds"); + } + } + } + console.log( + "\tNonrecoverable ValueDeltaBreaker cooldown, rate change threshold and reference value set correctly 🔒" + ); + } + + // /* ================================================================ */ + // /* ============================= Swaps ============================ */ + // /* ================================================================ */ + + // /* ================================================================ */ + // /* ============================ Helpers =========================== */ + // /* ================================================================ */ + + function verifyRateChangeTheshold( + uint256 currentThreshold, + uint256 expectedThreshold, + address rateFeedID, + bool isValueDeltaBreaker + ) internal view { + if (currentThreshold != expectedThreshold) { + if (isValueDeltaBreaker) { + console.log("ValueDeltaBreaker rate change threshold not set correctly for USDC/USD rate feed %s", rateFeedID); + revert("ValueDeltaBreaker rate change threshold not set correctly for USDC/USD rate feed"); + } + console.log("MedianDeltaBreaker rate change threshold not set correctly for rate feed %s", rateFeedID); + revert("MedianDeltaBreaker rate change threshold not set correctly for all rate feeds"); + } + } + + function verifyCooldownTime( + uint256 currentCoolDown, + uint256 expectedCoolDown, + address rateFeedID, + bool isValueDeltaBreaker + ) internal view { + if (currentCoolDown != expectedCoolDown) { + if (isValueDeltaBreaker) { + console.log("ValueDeltaBreaker cooldown not set correctly for USDC/USD rate feed %s", rateFeedID); + revert("ValueDeltaBreaker cooldown not set correctly for USDC/USD rate feed"); + } + console.log("MedianDeltaBreaker cooldown not set correctly for rate feed %s", rateFeedID); + revert("MedianDeltaBreaker cooldown not set correctly for all rate feeds"); + } + } + + function testAndPerformConstantProductSwap( + bytes32 exchangeID, + address trader, + address tokenIn, + address tokenOut, + uint256 amountIn + ) internal { + uint256 amountOut = Broker(broker).getAmountOut(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn); + IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeID); + + FixidityLib.Fraction memory numerator; + FixidityLib.Fraction memory denominator; + + if (tokenIn == pool.asset0) { + numerator = FixidityLib.newFixed(amountIn).multiply(FixidityLib.newFixed(pool.bucket1)); + denominator = FixidityLib.newFixed(pool.bucket0).add(FixidityLib.newFixed(amountIn)); + } else { + numerator = FixidityLib.newFixed(amountIn).multiply(FixidityLib.newFixed(pool.bucket0)); + denominator = FixidityLib.newFixed(pool.bucket1).add(FixidityLib.newFixed(amountIn)); + } + + uint256 estimatedAmountOut = numerator.unwrap().div(denominator.unwrap()); + + FixidityLib.Fraction memory maxTolerance = FixidityLib.newFixedFraction(25, 10000); + uint256 threshold = FixidityLib.newFixed(estimatedAmountOut).multiply(maxTolerance).fromFixed(); + assertApproxEqAbs(amountOut, estimatedAmountOut, threshold); + + doSwapIn(exchangeID, trader, tokenIn, tokenOut, amountIn, amountOut); + } + + function testAndPerformConstantSumSwap( + bytes32 exchangeID, + address trader, + address tokenIn, + address tokenOut, + uint256 amountIn, + address rateFeedID, + bool isBridgedUsdcToStable + ) internal { + uint256 amountOut = Broker(broker).getAmountOut(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn); + (uint256 numerator, uint256 denominator) = SortedOracles(sortedOraclesProxy).medianRate(rateFeedID); + uint256 estimatedAmountOut; + + if (isBridgedUsdcToStable) { + estimatedAmountOut = FixidityLib + .newFixed(amountIn.mul(1e12)) + .multiply(FixidityLib.wrap(numerator).divide(FixidityLib.wrap(denominator))) + .fromFixed(); + } else { + estimatedAmountOut = FixidityLib + .newFixed(amountIn) + .multiply(FixidityLib.wrap(denominator).divide(FixidityLib.wrap(numerator))) + .fromFixed(); + estimatedAmountOut = estimatedAmountOut.div(1e12); + } + + FixidityLib.Fraction memory maxTolerance = FixidityLib.newFixedFraction(25, 1000); + uint256 threshold = FixidityLib.newFixed(estimatedAmountOut).multiply(maxTolerance).fromFixed(); + assertApproxEqAbs(amountOut, estimatedAmountOut, threshold); + + doSwapIn(exchangeID, trader, tokenIn, tokenOut, amountIn, amountOut); + } + + function doSwapIn( + bytes32 exchangeID, + address trader, + address tokenIn, + address tokenOut, + uint256 amountIn, + uint256 amountOut + ) internal { + uint256 beforeBuyingTokenOut = IERC20(tokenOut).balanceOf(trader); + uint256 beforeSellingTokenIn = IERC20(tokenIn).balanceOf(trader); + + vm.startPrank(trader); + IERC20(tokenIn).approve(address(broker), amountIn); + Broker(broker).swapIn(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn, amountOut); + assertEq(IERC20(tokenOut).balanceOf(trader), beforeBuyingTokenOut + amountOut); + assertEq(IERC20(tokenIn).balanceOf(trader), beforeSellingTokenIn - amountIn); + vm.stopPrank(); + } + + /** + * @notice Helper function to get the exchange ID for a pool. + */ + function getExchangeId(address asset0, address asset1, bool isConstantSum) internal view returns (bytes32) { + return + keccak256( + abi.encodePacked( + IERC20Metadata(asset0).symbol(), + IERC20Metadata(asset1).symbol(), + isConstantSum ? "ConstantSum" : "ConstantProduct" + ) + ); + } +} From 5ce3b5546d6bd8b63158714338a792d670bce9fd Mon Sep 17 00:00:00 2001 From: philbow61 Date: Wed, 16 Aug 2023 11:21:34 +0200 Subject: [PATCH 03/64] test: more MU04 deployment checks --- ...U03-01-Create-Nonupgradeable-Contracts.sol | 1 + script/upgrades/MU04/Config.sol | 14 +- script/upgrades/MU04/MU04.sol | 32 ++--- script/upgrades/MU04/MU04Checks.sol | 125 ++++++++++++++++-- 4 files changed, 127 insertions(+), 45 deletions(-) diff --git a/script/upgrades/MU03/deploy/MU03-01-Create-Nonupgradeable-Contracts.sol b/script/upgrades/MU03/deploy/MU03-01-Create-Nonupgradeable-Contracts.sol index 0349e431..5893ddfe 100644 --- a/script/upgrades/MU03/deploy/MU03-01-Create-Nonupgradeable-Contracts.sol +++ b/script/upgrades/MU03/deploy/MU03-01-Create-Nonupgradeable-Contracts.sol @@ -38,6 +38,7 @@ contract MU03_CreateNonupgradeableContracts is Script { medianDeltaBreakerCooldown, medianDeltaBreakerThreshold, ISortedOracles(sortedOracles), + address(breakerBox), __rateFeedIDs, __rateChangeThresholds, __cooldowns diff --git a/script/upgrades/MU04/Config.sol b/script/upgrades/MU04/Config.sol index d1e41e5d..532a76f7 100644 --- a/script/upgrades/MU04/Config.sol +++ b/script/upgrades/MU04/Config.sol @@ -19,7 +19,6 @@ library MU04Config { Config.Pool[] pools; Config.RateFeed CELOXOF; Config.RateFeed EUROCXOF; - Config.RateFeed EUROCEUR; Config.RateFeed[] rateFeeds; Config.StableToken stableTokenXOF; } @@ -32,14 +31,13 @@ library MU04Config { config.rateFeeds = new Config.RateFeed[](3); config.rateFeeds[0] = config.CELOXOF = CELOXOF_RateFeedConfig(contracts); config.rateFeeds[1] = config.EUROCXOF = EUROCXOF_RateFeedConfig(contracts); - config.rateFeeds[2] = config.EUROCEUR = EUROCEUR_RateFeedConfig(contracts); config.stableTokenXOF = stableTokenXOFConfig(); } function stableTokenXOFConfig() internal pure returns (Config.StableToken memory config) { config = Config.StableToken({ - name: "EcoLabs West African Franc", + name: "ECO CFA", symbol: "eXOF", decimals: 18, registryAddress: address(0x000000000000000000000000000000000000ce10), @@ -152,14 +150,4 @@ library MU04Config { }); config.dependentRateFeeds = Arrays.addresses(contracts.dependency("EUROCEURRateFeedAddr")); } - - function EUROCEUR_RateFeedConfig(Contracts.Cache storage contracts) internal returns (Config.RateFeed memory config) { - config.rateFeedID = contracts.dependency("EUROCEURRateFeedAddr"); - config.valueDeltaBreaker0 = Config.ValueDeltaBreaker({ - enabled: true, - threshold: FixidityLib.newFixedFraction(5, 1000), // 0.005 - referenceValue: 1e24, // 1€ numerator for 1e24 denominator - cooldown: 1 seconds - }); - } } diff --git a/script/upgrades/MU04/MU04.sol b/script/upgrades/MU04/MU04.sol index f1d8dff7..081fd2f4 100644 --- a/script/upgrades/MU04/MU04.sol +++ b/script/upgrades/MU04/MU04.sol @@ -76,9 +76,9 @@ contract MU04 is IMentoUpgrade, GovernanceScript { contracts.load("MU01-01-Create-Nonupgradeable-Contracts", "latest"); contracts.load("MU03-01-Create-Nonupgradeable-Contracts", "latest"); contracts.load("MU03-02-Create-Implementations", "latest"); - contracts.load("MU04-00-Create-Proxies.sol", "latest"); - contracts.load("MU04-01-Create-Implementations.sol", "latest"); - contracts.load("MU04-02-Create-Nonupgradeable-Contracts.sol", "latest"); + contracts.load("MU04-00-Create-Proxies", "latest"); + contracts.load("MU04-01-Create-Implementations", "latest"); + contracts.load("MU04-02-Create-Nonupgradeable-Contracts", "latest"); } /** @@ -369,11 +369,7 @@ contract MU04 is IMentoUpgrade, GovernanceScript { breakerBox, abi.encodeWithSelector( BreakerBox(0).addRateFeeds.selector, - Arrays.addresses( - contracts.celoRegistry("StableTokenXOF"), - contracts.dependency("EUROCXOFRateFeedAddr"), - contracts.dependency("EUROCEURRateFeedAddr") - ) + Arrays.addresses(contracts.celoRegistry("StableTokenXOF"), contracts.dependency("EUROCXOFRateFeedAddr")) ) ) ); @@ -495,22 +491,10 @@ contract MU04 is IMentoUpgrade, GovernanceScript { * @notice This function creates the transactions to configure the first Value Delta Breaker . */ function proposal_configureValueDeltaBreaker(MU04Config.MU04 memory config) private { - address[] memory valueDeltaBreakerRateFeeds = Arrays.addresses( - config.EUROCXOF.rateFeedID, - config.EUROCEUR.rateFeedID - ); - uint[] memory valueDeltaBreakerCooldownTimes = Arrays.uints( - config.EUROCXOF.valueDeltaBreaker0.cooldown, - config.EUROCEUR.valueDeltaBreaker0.cooldown - ); - uint[] memory valueDeltaBreakerThresholds = Arrays.uints( - config.EUROCXOF.valueDeltaBreaker0.threshold.unwrap(), - config.EUROCEUR.valueDeltaBreaker0.threshold.unwrap() - ); - uint[] memory valueDeltaBreakerReferenceValues = Arrays.uints( - config.EUROCXOF.valueDeltaBreaker0.referenceValue, - config.EUROCEUR.valueDeltaBreaker0.referenceValue - ); + address[] memory valueDeltaBreakerRateFeeds = Arrays.addresses(config.EUROCXOF.rateFeedID); + uint[] memory valueDeltaBreakerCooldownTimes = Arrays.uints(config.EUROCXOF.valueDeltaBreaker0.cooldown); + uint[] memory valueDeltaBreakerThresholds = Arrays.uints(config.EUROCXOF.valueDeltaBreaker0.threshold.unwrap()); + uint[] memory valueDeltaBreakerReferenceValues = Arrays.uints(config.EUROCXOF.valueDeltaBreaker0.referenceValue); // Set the cooldown times transactions.push( diff --git a/script/upgrades/MU04/MU04Checks.sol b/script/upgrades/MU04/MU04Checks.sol index fbbff749..6db9c27d 100644 --- a/script/upgrades/MU04/MU04Checks.sol +++ b/script/upgrades/MU04/MU04Checks.sol @@ -74,7 +74,6 @@ contract MU04Checks is Script, Test { function setUp() public { new PrecompileHandler(); // needed for reserve CELO transfer checks - // Load addresses from deployments contracts.load("MU01-00-Create-Proxies", "latest"); contracts.load("MU01-01-Create-Nonupgradeable-Contracts", "latest"); @@ -85,7 +84,7 @@ contract MU04Checks is Script, Test { contracts.load("MU04-02-Create-Nonupgradeable-Contracts", "latest"); // Get proxy addresses - eXOF = contracts.celoRegistry("StableTokenXOF"); + eXOF = address(uint160(contracts.celoRegistry("StableTokenXOF"))); cUSD = contracts.celoRegistry("StableToken"); cEUR = contracts.celoRegistry("StableTokenEUR"); cBRL = contracts.celoRegistry("StableTokenBRL"); @@ -111,10 +110,25 @@ contract MU04Checks is Script, Test { function run() public { setUp(); + verifyOwner(); + verifyEXOFStableToken(); verifyExchanges(); verifyCircuitBreaker(); } + function verifyOwner() internal view { + address eXOFImplementation = contracts.deployed("StableTokenXOF"); + require( + StableTokenXOF(eXOFImplementation).owner() == governance, + "StableTokenXOF ownership not transferred to governance" + ); + require( + ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).owner() == governance, + "Nonrecoverable Value Delta Breaker ownership not transferred to governance" + ); + console.log("Contract ownerships transferred to governance 🤝"); + } + function verifyEXOFStableToken() internal view { StableTokenXOFProxy stableTokenXOFProxy = StableTokenXOFProxy(eXOF); address eXOFDeployedImplementation = contracts.deployed("StableTokenXOF"); @@ -319,13 +333,14 @@ contract MU04Checks is Script, Test { console.log("\n== Checking circuit breaker... =="); verifyBreakerBox(config); + verifyBreakersAreEnabled(config); verifyMedianDeltaBreaker(config); verifyValueDeltaBreaker(config); } function verifyBreakerBox(MU04Config.MU04 memory config) internal view { // verify that breakers were set with trading mode 3 - /* if (BreakerBox(breakerBox).breakerTradingMode(nonrecoverableValueDeltaBreaker) != 3) { + if (BreakerBox(breakerBox).breakerTradingMode(nonrecoverableValueDeltaBreaker) != 3) { console.log("The Nonrecoverable ValueDeltaBreaker was not set with trading halted ❌"); revert("Nonrecoverable ValueDeltaBreaker was not set with trading halted"); } @@ -334,11 +349,13 @@ contract MU04Checks is Script, Test { // verify that rate feed dependencies were configured correctly address EUROCXOFDependency = BreakerBox(breakerBox).rateFeedDependencies(config.EUROCXOF.rateFeedID, 0); require( - EUROCXOFDependency == contracts.dependency("EUROCEURRateFeedAddr"), + EUROCXOFDependency == config.EUROCXOF.dependentRateFeeds[0], "EUROC/XOF rate feed dependency not set correctly" ); console.log("\tRate feed dependencies configured correctly 🗳️"); + } + function verifyBreakersAreEnabled(MU04Config.MU04 memory config) internal view { // verify that MedianDeltaBreaker && ValueDeltaBreakers were enabled for rateFeeds for (uint256 i = 0; i < config.rateFeeds.length; i++) { Config.RateFeed memory rateFeed = config.rateFeeds[i]; @@ -370,7 +387,7 @@ contract MU04Checks is Script, Test { } } } - console.log("\tBreakers enabled for all rate feeds 🗳️");*/ + console.log("\tBreakers enabled for all rate feeds 🗳️"); } function verifyMedianDeltaBreaker(MU04Config.MU04 memory config) internal view { @@ -453,18 +470,18 @@ contract MU04Checks is Script, Test { ); // verify cooldown period - verifyCooldownTime(cooldown, rateFeed.valueDeltaBreaker0.cooldown, rateFeed.rateFeedID, true); + verifyCooldownTime(cooldown, rateFeed.valueDeltaBreaker1.cooldown, rateFeed.rateFeedID, true); // verify rate change threshold verifyRateChangeTheshold( rateChangeThreshold, - rateFeed.valueDeltaBreaker0.threshold.unwrap(), + rateFeed.valueDeltaBreaker1.threshold.unwrap(), rateFeed.rateFeedID, true ); // verify refernece value - if (referenceValue != rateFeed.valueDeltaBreaker0.referenceValue) { + if (referenceValue != rateFeed.valueDeltaBreaker1.referenceValue) { console.log( "Nonrecoverable ValueDeltaBreaker reference value not set correctly for the rate feed: %s", rateFeed.rateFeedID @@ -481,6 +498,98 @@ contract MU04Checks is Script, Test { // /* ================================================================ */ // /* ============================= Swaps ============================ */ // /* ================================================================ */ + function doSwaps() internal { + MU04Config.MU04 memory config = MU04Config.get(contracts); + + console.log("\n== Doing some test swaps... =="); + + swapCeloToEXOF(config); + swapEXOFtoCelo(config); + swapBridgedEUROCtoEXOF(config); + swapEXOFtoBridgedEUROC(config); + } + + function swapCeloToEXOF(MU04Config.MU04 memory config) internal { + bytes32 exchangeID = getExchangeId(config.eXOFCelo.asset0, config.eXOFCelo.asset1, config.eXOFCelo.isConstantSum); + + address trader = vm.addr(5); + address tokenIn = celoToken; + address tokenOut = eXOF; + uint256 amountIn = 100e18; + + // Give trader some celo + vm.deal(trader, amountIn); + + testAndPerformConstantProductSwap(exchangeID, trader, tokenIn, tokenOut, amountIn); + + console.log("\tCELO -> eXOF swap successful 🚀"); + } + + function swapEXOFtoCelo(MU04Config.MU04 memory config) internal { + bytes32 exchangeID = getExchangeId(config.eXOFCelo.asset0, config.eXOFCelo.asset1, config.eXOFCelo.isConstantSum); + + address trader = vm.addr(5); + address tokenIn = eXOF; + address tokenOut = celoToken; + uint256 amountIn = 100e18; + + testAndPerformConstantProductSwap(exchangeID, trader, tokenIn, tokenOut, amountIn); + + console.log("\teXOF -> CELO swap successful 🚀"); + } + + function swapBridgedEUROCtoEXOF(MU04Config.MU04 memory config) internal { + bytes32 exchangeID = getExchangeId( + config.eXOFEUROC.asset0, + config.eXOFEUROC.asset1, + config.eXOFEUROC.isConstantSum + ); + + address trader = vm.addr(4); + address tokenIn = bridgedEUROC; + address tokenOut = eXOF; + uint256 amountIn = 10e6; + + // Mint some EUROC to trader + deal(bridgedUSDC, trader, amountIn, true); + + testAndPerformConstantSumSwap( + exchangeID, + trader, + tokenIn, + tokenOut, + amountIn, + config.eXOFEUROC.referenceRateFeedID, + true + ); + + console.log("\tbridgedEUROC -> eXOF swap successful 🚀"); + } + + function swapEXOFtoBridgedEUROC(MU04Config.MU04 memory config) internal { + bytes32 exchangeID = getExchangeId( + config.eXOFEUROC.asset0, + config.eXOFEUROC.asset1, + config.eXOFEUROC.isConstantSum + ); + + address trader = vm.addr(4); + address tokenIn = eXOF; + address tokenOut = bridgedEUROC; + uint256 amountIn = 100e18; + + testAndPerformConstantSumSwap( + exchangeID, + trader, + tokenIn, + tokenOut, + amountIn, + config.eXOFEUROC.referenceRateFeedID, + false + ); + + console.log("\teXOF -> bridgedEUROC swap successful 🚀"); + } // /* ================================================================ */ // /* ============================ Helpers =========================== */ From 1071d7524e68af053c54579c8b4e7b2a3f413e2f Mon Sep 17 00:00:00 2001 From: philbow61 Date: Thu, 17 Aug 2023 14:08:41 +0200 Subject: [PATCH 04/64] chore: deploy XOF to mainnet --- .../42220/run-latest.json | 117 +++++++++++++++++ .../42220/run-latest.json | 121 ++++++++++++++++++ contracts/NonrecoverableValueDeltaBreaker.sol | 25 ++++ script/upgrades/MU04/MU04.sol | 37 ++---- ...U04-02-Create-Nonupgradeable-Contracts.sol | 23 +--- 5 files changed, 273 insertions(+), 50 deletions(-) create mode 100644 broadcast/MU04-00-Create-Proxies.sol/42220/run-latest.json create mode 100644 broadcast/MU04-01-Create-Implementations.sol/42220/run-latest.json create mode 100644 contracts/NonrecoverableValueDeltaBreaker.sol diff --git a/broadcast/MU04-00-Create-Proxies.sol/42220/run-latest.json b/broadcast/MU04-00-Create-Proxies.sol/42220/run-latest.json new file mode 100644 index 00000000..78f7fbe7 --- /dev/null +++ b/broadcast/MU04-00-Create-Proxies.sol/42220/run-latest.json @@ -0,0 +1,117 @@ +{ + "transactions": [ + { + "hash": "0xda37556aef0efb712cece2a2c9d00cf2d6b95ed831722f994280d2786e69218d", + "transactionType": "CREATE", + "contractName": "StableTokenXOFProxy", + "contractAddress": "0x73F93dcc49cB8A239e2032663e9475dd5ef29A08", + "function": null, + "arguments": null, + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "gas": "0xbd5cc", + "value": "0x0", + "data": "0x6080604052610016336001600160e01b0361001b16565b6100d9565b6001600160a01b03811661006a576040805162461bcd60e51b815260206004820152601160248201527006f776e65722063616e6e6f74206265203607c1b604482015290519081900360640190fd5b604080517f656970313936372e70726f78792e61646d696e000000000000000000000000008152905190819003601301812060001901828155906001600160a01b038316907f50146d0e3c60aa1d17a70635b05494f864e86144a2201275021014fbf08bafe290600090a25050565b61096b806100e86000396000f3fe60806040526004361061005a5760003560e01c8063bb913f4111610043578063bb913f41146102a7578063d29d44ee146102e7578063f7e6af80146103275761005a565b806303386ba3146101da57806342404e0714610269575b604080517f656970313936372e70726f78792e696d706c656d656e746174696f6e000000008152905190819003601c0190207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff01805473ffffffffffffffffffffffffffffffffffffffff811661013257604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f4e6f20496d706c656d656e746174696f6e207365740000000000000000000000604482015290519081900360640190fd5b61013b8161033c565b6101a657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f496e76616c696420636f6e747261637420616464726573730000000000000000604482015290519081900360640190fd5b60405136810160405236600082376000803683855af43d604051818101604052816000823e8280156101d6578282f35b8282fd5b610267600480360360408110156101f057600080fd5b73ffffffffffffffffffffffffffffffffffffffff823516919081019060408101602082013564010000000081111561022857600080fd5b82018360208201111561023a57600080fd5b8035906020019184600183028401116401000000008311171561025c57600080fd5b509092509050610378565b005b34801561027557600080fd5b5061027e61050c565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b3480156102b357600080fd5b50610267600480360360208110156102ca57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610564565b3480156102f357600080fd5b506102676004803603602081101561030a57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610715565b34801561033357600080fd5b5061027e6107c2565b6000813f7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47081811480159061037057508115155b949350505050565b6103806107c2565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461041957604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f73656e64657220776173206e6f74206f776e6572000000000000000000000000604482015290519081900360640190fd5b61042283610564565b600060608473ffffffffffffffffffffffffffffffffffffffff1684846040518083838082843760405192019450600093509091505080830381855af49150503d806000811461048e576040519150601f19603f3d011682016040523d82523d6000602084013e610493565b606091505b5090925090508161050557604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f696e697469616c697a6174696f6e2063616c6c6261636b206661696c65640000604482015290519081900360640190fd5b5050505050565b604080517f656970313936372e70726f78792e696d706c656d656e746174696f6e000000008152905190819003601c0190207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff015490565b61056c6107c2565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461060557604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f73656e64657220776173206e6f74206f776e6572000000000000000000000000604482015290519081900360640190fd5b604080517f656970313936372e70726f78792e696d706c656d656e746174696f6e000000008152905190819003601c0190207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff016106628261033c565b6106cd57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f496e76616c696420636f6e747261637420616464726573730000000000000000604482015290519081900360640190fd5b81815560405173ffffffffffffffffffffffffffffffffffffffff8316907fab64f92ab780ecbf4f3866f57cee465ff36c89450dcce20237ca7a8d81fb7d1390600090a25050565b61071d6107c2565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146107b657604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f73656e64657220776173206e6f74206f776e6572000000000000000000000000604482015290519081900360640190fd5b6107bf8161081a565b50565b604080517f656970313936372e70726f78792e61646d696e00000000000000000000000000815290519081900360130190207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff015490565b73ffffffffffffffffffffffffffffffffffffffff811661089c57604080517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601160248201527f6f776e65722063616e6e6f742062652030000000000000000000000000000000604482015290519081900360640190fd5b604080517f656970313936372e70726f78792e61646d696e00000000000000000000000000815290519081900360130181207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff018281559073ffffffffffffffffffffffffffffffffffffffff8316907f50146d0e3c60aa1d17a70635b05494f864e86144a2201275021014fbf08bafe290600090a2505056fea265627a7a72315820fb186e42146669f7df853077eb65750c7576b3fca10559c92f45a0ae6a83f99d64736f6c63430005110032", + "nonce": "0x7b" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0xe1af2ae5c50cd3f4fbd4253adf0a361d56acb1355a1f6741d6be0f4ac95262f6", + "transactionType": "CALL", + "contractName": "StableTokenXOFProxy", + "contractAddress": "0x73F93dcc49cB8A239e2032663e9475dd5ef29A08", + "function": "_transferOwnership(address)", + "arguments": [ + "0xD533Ca259b330c7A88f74E000a3FaEa2d63B7972" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "to": "0x73f93dcc49cb8a239e2032663e9475dd5ef29a08", + "gas": "0x9789", + "value": "0x0", + "data": "0xd29d44ee000000000000000000000000d533ca259b330c7a88f74e000a3faea2d63b7972", + "nonce": "0x7c" + }, + "additionalContracts": [], + "isFixedGasLimit": false + } + ], + "receipts": [ + { + "transactionHash": "0xda37556aef0efb712cece2a2c9d00cf2d6b95ed831722f994280d2786e69218d", + "transactionIndex": "0x5", + "blockHash": "0xc6cb77460436f1de22482966eff238c5bd89f5193a5aac94dc72be5eac08a479", + "blockNumber": "0x13f3adb", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": null, + "cumulativeGasUsed": "0xf9600", + "gasUsed": "0x91589", + "contractAddress": "0x73F93dcc49cB8A239e2032663e9475dd5ef29A08", + "logs": [ + { + "address": "0x73F93dcc49cB8A239e2032663e9475dd5ef29A08", + "topics": [ + "0x50146d0e3c60aa1d17a70635b05494f864e86144a2201275021014fbf08bafe2", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0xc6cb77460436f1de22482966eff238c5bd89f5193a5aac94dc72be5eac08a479", + "blockNumber": "0x13f3adb", + "transactionHash": "0xda37556aef0efb712cece2a2c9d00cf2d6b95ed831722f994280d2786e69218d", + "transactionIndex": "0x5", + "logIndex": "0x9", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000020000000000000000000000000000080000000000000410000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000000100000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0x5d21dba00" + }, + { + "transactionHash": "0xe1af2ae5c50cd3f4fbd4253adf0a361d56acb1355a1f6741d6be0f4ac95262f6", + "transactionIndex": "0x6", + "blockHash": "0xc6cb77460436f1de22482966eff238c5bd89f5193a5aac94dc72be5eac08a479", + "blockNumber": "0x13f3adb", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": "0x73F93dcc49cB8A239e2032663e9475dd5ef29A08", + "cumulativeGasUsed": "0x1003b6", + "gasUsed": "0x6db6", + "contractAddress": null, + "logs": [ + { + "address": "0x73F93dcc49cB8A239e2032663e9475dd5ef29A08", + "topics": [ + "0x50146d0e3c60aa1d17a70635b05494f864e86144a2201275021014fbf08bafe2", + "0x000000000000000000000000d533ca259b330c7a88f74e000a3faea2d63b7972" + ], + "data": "0x", + "blockHash": "0xc6cb77460436f1de22482966eff238c5bd89f5193a5aac94dc72be5eac08a479", + "blockNumber": "0x13f3adb", + "transactionHash": "0xe1af2ae5c50cd3f4fbd4253adf0a361d56acb1355a1f6741d6be0f4ac95262f6", + "transactionIndex": "0x6", + "logIndex": "0xa", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000080000000000000400000000000000000000000000000000000000000100000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000080000000100000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0x5d21dba00" + } + ], + "libraries": [ + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x6200F54D73491d56b8d7A975C9ee18EFb4D518Df", + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0xED477A99035d0c1e11369F1D7A4e587893cc002B" + ], + "pending": [], + "returns": {}, + "timestamp": 1692273757, + "chain": 42220, + "multi": false, + "commit": "5ce3b55" +} \ No newline at end of file diff --git a/broadcast/MU04-01-Create-Implementations.sol/42220/run-latest.json b/broadcast/MU04-01-Create-Implementations.sol/42220/run-latest.json new file mode 100644 index 00000000..360ceac0 --- /dev/null +++ b/broadcast/MU04-01-Create-Implementations.sol/42220/run-latest.json @@ -0,0 +1,121 @@ +{ + "transactions": [ + { + "hash": "0x213fa5f650df2731f778088560d15a553aaed4ddfe249c1600cf77f054fa7b97", + "transactionType": "CREATE", + "contractName": "StableTokenXOF", + "contractAddress": "0xb5ECB577604169C2dC80621a31A938BEaF06aDa6", + "function": null, + "arguments": [ + "false" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "gas": "0x588934", + "value": "0x0", + "data": "0x60806040523480156200001157600080fd5b506040516200503c3803806200503c833981810160405260208110156200003757600080fd5b505180806000620000506001600160e01b03620000bd16565b600080546001600160a01b0319166001600160a01b0383169081178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a35080620000b4576000805460ff60a01b1916600160a01b1790555b505050620000c1565b3390565b614f6b80620000d16000396000f3fe608060405234801561001057600080fd5b50600436106102ff5760003560e01c806370a082311161019c578063a457c2d7116100ee578063df4da46111610097578063ec68307211610071578063ec68307214610d2a578063f2fde38b14610d7e578063fae8db0a14610da4576102ff565b8063df4da46114610c80578063e1d6aceb14610c88578063e50e652d14610d0d576102ff565b8063a91ee0dc116100c8578063a91ee0dc14610c0f578063af31f58714610c35578063dd62ed3e14610c52576102ff565b8063a457c2d714610baf578063a67f874714610bdb578063a9059cbb14610be3576102ff565b80638a8836261161015057806395d89b411161012a57806395d89b4114610b825780639a7b3be714610b8a5780639b2b592f14610b92576102ff565b80638a88362614610acc5780638da5cb5b14610b725780638f32d59b14610b7a576102ff565b80637385e5da116101815780637385e5da14610ab45780637b10399914610abc57806387ee8a0f14610ac4576102ff565b806370a0823114610a86578063715018a614610aac576102ff565b806339509351116102555780634b2c2f44116102095780635d180adb116101e35780635d180adb1461096457806367960e91146109875780636a30b25314610a2d576102ff565b80634b2c2f441461086457806354255be01461090a57806358cf967214610938576102ff565b806340a12f641161023a57806340a12f641461081357806340c10f191461081b57806342966c6814610847576102ff565b806339509351146107ca5780633b1eb4bf146107f6576102ff565b806318160ddd116102b757806323b872dd1161029157806323b872dd1461063957806323f0ab651461066f578063313ce567146107ac576102ff565b806318160ddd146104315780631e4f0e0314610439578063222836ad14610616576102ff565b8063123633ea116102e8578063123633ea146103c157806312c6c099146103fa578063158ef93e14610429576102ff565b806306fdde0314610304578063095ea7b314610381575b600080fd5b61030c610dc1565b6040805160208082528351818301528351919283929083019185019080838360005b8381101561034657818101518382015260200161032e565b50505050905090810190601f1680156103735780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103ad6004803603604081101561039757600080fd5b506001600160a01b038135169060200135610e73565b604080519115158252519081900360200190f35b6103de600480360360208110156103d757600080fd5b5035610fa4565b604080516001600160a01b039092168252519081900360200190f35b6104176004803603602081101561041057600080fd5b50356110b3565b60408051918252519081900360200190f35b6103ad6110d9565b6104176110fa565b610614600480360361012081101561045057600080fd5b81019060208101813564010000000081111561046b57600080fd5b82018360208201111561047d57600080fd5b8035906020019184600183028401116401000000008311171561049f57600080fd5b9193909290916020810190356401000000008111156104bd57600080fd5b8201836020820111156104cf57600080fd5b803590602001918460018302840111640100000000831117156104f157600080fd5b9193909260ff833516926001600160a01b036020820135169260408201359260608301359260a08101906080013564010000000081111561053157600080fd5b82018360208201111561054357600080fd5b8035906020019184602083028401116401000000008311171561056557600080fd5b91939092909160208101903564010000000081111561058357600080fd5b82018360208201111561059557600080fd5b803590602001918460208302840111640100000000831117156105b757600080fd5b9193909290916020810190356401000000008111156105d557600080fd5b8201836020820111156105e757600080fd5b8035906020019184600183028401116401000000008311171561060957600080fd5b50909250905061110c565b005b6106146004803603604081101561062c57600080fd5b50803590602001356113ac565b6103ad6004803603606081101561064f57600080fd5b506001600160a01b0381358116916020810135909116906040013561156e565b6103ad6004803603606081101561068557600080fd5b6001600160a01b0382351691908101906040810160208201356401000000008111156106b057600080fd5b8201836020820111156106c257600080fd5b803590602001918460018302840111640100000000831117156106e457600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929594936020810193503591505064010000000081111561073757600080fd5b82018360208201111561074957600080fd5b8035906020019184600183028401116401000000008311171561076b57600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295506118dc945050505050565b6107b4611a76565b6040805160ff9092168252519081900360200190f35b6103ad600480360360408110156107e057600080fd5b506001600160a01b038135169060200135611a7f565b6104176004803603602081101561080c57600080fd5b5035611be8565b610417611c01565b6103ad6004803603604081101561083157600080fd5b506001600160a01b038135169060200135611c62565b6103ad6004803603602081101561085d57600080fd5b5035612076565b6104176004803603602081101561087a57600080fd5b81019060208101813564010000000081111561089557600080fd5b8201836020820111156108a757600080fd5b803590602001918460018302840111640100000000831117156108c957600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295506124a3945050505050565b6109126125fb565b604080519485526020850193909352838301919091526060830152519081900360800190f35b6106146004803603604081101561094e57600080fd5b506001600160a01b038135169060200135612608565b6103de6004803603604081101561097a57600080fd5b5080359060200135612820565b6104176004803603602081101561099d57600080fd5b8101906020810181356401000000008111156109b857600080fd5b8201836020820111156109ca57600080fd5b803590602001918460018302840111640100000000831117156109ec57600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550612928945050505050565b6106146004803603610100811015610a4457600080fd5b506001600160a01b0381358116916020810135821691604082013581169160608101359091169060808101359060a08101359060c08101359060e00135612a75565b61041760048036036020811015610a9c57600080fd5b50356001600160a01b0316612c4e565b610614612c70565b610417612d2b565b6103de612d36565b610417612d45565b61041760048036036020811015610ae257600080fd5b810190602081018135640100000000811115610afd57600080fd5b820183602082011115610b0f57600080fd5b80359060200191846001830284011164010000000083111715610b3157600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550612e5d945050505050565b6103de612faa565b6103ad612fb9565b61030c612fdd565b61041761305c565b61041760048036036020811015610ba857600080fd5b5035613067565b6103ad60048036036040811015610bc557600080fd5b506001600160a01b03813516906020013561316d565b610912613225565b6103ad60048036036040811015610bf957600080fd5b506001600160a01b038135169060200135613274565b61061460048036036020811015610c2557600080fd5b50356001600160a01b03166133c6565b61041760048036036020811015610c4b57600080fd5b50356134dc565b61041760048036036040811015610c6857600080fd5b506001600160a01b0381358116916020013516613512565b61041761353d565b6103ad60048036036060811015610c9e57600080fd5b6001600160a01b0382351691602081013591810190606081016040820135640100000000811115610cce57600080fd5b820183602082011115610ce057600080fd5b80359060200191846001830284011164010000000083111715610d0257600080fd5b509092509050613628565b61041760048036036020811015610d2357600080fd5b50356137e9565b610d65600480360360c0811015610d4057600080fd5b5080359060208101359060408101359060608101359060808101359060a00135613827565b6040805192835260208301919091528051918290030190f35b61061460048036036020811015610d9457600080fd5b50356001600160a01b03166139e4565b61041760048036036020811015610dba57600080fd5b5035613a49565b60028054604080516020601f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6101006001871615020190941685900493840181900481028201810190925282815260609390929091830182828015610e685780601f10610e3d57610100808354040283529160200191610e68565b820191906000526020600020905b815481529060010190602001808311610e4b57829003601f168201915b505050505090505b90565b6000610e7d614acb565b6000610e87613b4f565b600b5491935091508114610ef65781516009819055600b82905560408051602081019091529081527f08f3ed03ec9e579d1f6ab2f9e0d3dc661704696deabe37a6b6df7014f1b30a9790610eda90613cbf565b600b546040805192835260208301919091528051918290030190a15b6001600160a01b038516610f3b5760405162461bcd60e51b815260040180806020018281038252602a815260200180614d95602a913960400191505060405180910390fd5b3360008181526007602090815260408083206001600160a01b038a1680855290835292819020889055805188815290519293927f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925929181900390910190a3506001949350505050565b60408051602080820184905243828401528251808303840181526060928301938490528051600094859360fa939282918401908083835b60208310610ffa5780518252601f199092019160209182019101610fdb565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d806000811461105a576040519150601f19603f3d011682016040523d82523d6000602084013e61105f565b606091505b5092509050806110a05760405162461bcd60e51b815260040180806020018281038252603d815260200180614ced603d913960400191505060405180910390fd5b6110ab826000613cc3565b949350505050565b60006110bd614acb565b6110c5613b4f565b5090506110d28184613ccf565b9392505050565b60005474010000000000000000000000000000000000000000900460ff1681565b60006111076006546134dc565b905090565b60005474010000000000000000000000000000000000000000900460ff161561117c576040805162461bcd60e51b815260206004820152601c60248201527f636f6e747261637420616c726561647920696e697469616c697a656400000000604482015290519081900360640190fd5b600080547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff1674010000000000000000000000000000000000000000179055876111f75760405162461bcd60e51b8152600401808060200182810382526026815260200180614c106026913960400191505060405180910390fd5b600087116112365760405162461bcd60e51b8152600401808060200182810382526027815260200180614bc36027913960400191505060405180910390fd5b61123f33613ced565b600060065561125060028f8f614ade565b5061125d60038d8d614ade565b50600480547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff8c1617905561129488613da5565b516008556112a0613dbf565b51600955600a87905542600b55848314611301576040805162461bcd60e51b815260206004820152601560248201527f4172726179206c656e677468206d69736d617463680000000000000000000000604482015290519081900360640190fd5b60005b8581101561135c5761134387878381811061131b57fe5b905060200201356001600160a01b031686868481811061133757fe5b90506020020135613de3565b5061135581600163ffffffff613f0a16565b9050611304565b50611366896133c6565b818160405160200180838380828437808301925050509250505060405160208183030381529060405280519060200120600c819055505050505050505050505050505050565b6113b4612fb9565b611405576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61140d614acb565b6000611417613b4f565b600b54919350915081146114865781516009819055600b82905560408051602081019091529081527f08f3ed03ec9e579d1f6ab2f9e0d3dc661704696deabe37a6b6df7014f1b30a979061146a90613cbf565b600b546040805192835260208301919091528051918290030190a15b836114c25760405162461bcd60e51b8152600401808060200182810382526027815260200180614c366027913960400191505060405180910390fd5b60008311611517576040805162461bcd60e51b815260206004820152601860248201527f757064617465506572696f64206d757374206265203e20300000000000000000604482015290519081900360640190fd5b61152084613da5565b51600855600a8390556040805185815260208101859052428183015290517fa0035d6667ffb7d387c86c7228141c4a877e8ed831b267ac928a2f5b651c155d9181900360600190a150505050565b6000611578614acb565b6000611582613b4f565b600b54919350915081146115f15781516009819055600b82905560408051602081019091529081527f08f3ed03ec9e579d1f6ab2f9e0d3dc661704696deabe37a6b6df7014f1b30a97906115d590613cbf565b600b546040805192835260208301919091528051918290030190a15b6115f9613f64565b6001600160a01b031663e5839836306040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561164e57600080fd5b505afa158015611662573d6000803e3d6000fd5b505050506040513d602081101561167857600080fd5b5051156116b65760405162461bcd60e51b8152600401808060200182810382526022815260200180614c956022913960400191505060405180910390fd5b604080516020810190915260095481526000906116d39086613ccf565b90506001600160a01b03861661171a5760405162461bcd60e51b815260040180806020018281038252602a815260200180614eea602a913960400191505060405180910390fd5b6001600160a01b0387166000908152600560205260409020548111156117715760405162461bcd60e51b8152600401808060200182810382526029815260200180614de06029913960400191505060405180910390fd5b6001600160a01b03871660009081526007602090815260408083203384529091529020548511156117d35760405162461bcd60e51b8152600401808060200182810382526038815260200180614e096038913960400191505060405180910390fd5b6001600160a01b0386166000908152600560205260409020546117fc908263ffffffff613f0a16565b6001600160a01b038088166000908152600560205260408082209390935590891681522054611831908263ffffffff61403916565b6001600160a01b038816600090815260056020908152604080832093909355600781528282203383529052205461186e908663ffffffff61403916565b6001600160a01b0380891660008181526007602090815260408083203384528252918290209490945580518981529051928a169391927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef929181900390910190a35060019695505050505050565b60008060fb6001600160a01b031685858560405160200180846001600160a01b03166001600160a01b031660601b815260140183805190602001908083835b6020831061193a5780518252601f19909201916020918201910161191b565b51815160209384036101000a7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff018019909216911617905285519190930192850191508083835b602083106119a05780518252601f199092019160209182019101611981565b6001836020036101000a03801982511681845116808217855250505050505090500193505050506040516020818303038152906040526040518082805190602001908083835b60208310611a055780518252601f1990920191602091820191016119e6565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d8060008114611a65576040519150601f19603f3d011682016040523d82523d6000602084013e611a6a565b606091505b50909695505050505050565b60045460ff1690565b6000611a89614acb565b6000611a93613b4f565b600b5491935091508114611b025781516009819055600b82905560408051602081019091529081527f08f3ed03ec9e579d1f6ab2f9e0d3dc661704696deabe37a6b6df7014f1b30a9790611ae690613cbf565b600b546040805192835260208301919091528051918290030190a15b6001600160a01b038516611b475760405162461bcd60e51b815260040180806020018281038252602a815260200180614d95602a913960400191505060405180910390fd5b3360009081526007602090815260408083206001600160a01b038916845290915281205490611b7c828763ffffffff613f0a16565b3360008181526007602090815260408083206001600160a01b038d16808552908352928190208590558051858152905194955091937f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259281900390910190a35060019695505050505050565b6000611bfb82611bf661353d565b61407b565b92915050565b600c54600090611c595760405160200180807f45786368616e67650000000000000000000000000000000000000000000000008152506008019050604051602081830303815290604052805190602001209050610e70565b50600c54610e70565b6000611c6c614acb565b6000611c76613b4f565b600b5491935091508114611ce55781516009819055600b82905560408051602081019091529081527f08f3ed03ec9e579d1f6ab2f9e0d3dc661704696deabe37a6b6df7014f1b30a9790611cc990613cbf565b600b546040805192835260208301919091528051918290030190a15b600154604080517f42726f6b6572000000000000000000000000000000000000000000000000000060208083019190915282518083036006018152602683018085528151918301919091207fdd92723300000000000000000000000000000000000000000000000000000000909152602a83015291516001600160a01b039093169263dd92723392604a80840193919291829003018186803b158015611d8a57600080fd5b505afa158015611d9e573d6000803e3d6000fd5b505050506040513d6020811015611db457600080fd5b50516001600160a01b0316331480611e4c57506001546001600160a01b031663dd927233611de0611c01565b6040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b158015611e1457600080fd5b505afa158015611e28573d6000803e3d6000fd5b505050506040513d6020811015611e3e57600080fd5b50516001600160a01b031633145b80611f2f5750600154604080517f56616c696461746f7273000000000000000000000000000000000000000000006020808301919091528251808303600a018152602a83018085528151918301919091207fdd92723300000000000000000000000000000000000000000000000000000000909152602e83015291516001600160a01b039093169263dd92723392604e80840193919291829003018186803b158015611ef757600080fd5b505afa158015611f0b573d6000803e3d6000fd5b505050506040513d6020811015611f2157600080fd5b50516001600160a01b031633145b806120125750600154604080517f4772616e64614d656e746f0000000000000000000000000000000000000000006020808301919091528251808303600b018152602b83018085528151918301919091207fdd92723300000000000000000000000000000000000000000000000000000000909152602f83015291516001600160a01b039093169263dd92723392604f80840193919291829003018186803b158015611fda57600080fd5b505afa158015611fee573d6000803e3d6000fd5b505050506040513d602081101561200457600080fd5b50516001600160a01b031633145b612063576040805162461bcd60e51b815260206004820152601d60248201527f53656e646572206e6f7420617574686f72697a656420746f206d696e74000000604482015290519081900360640190fd5b61206d8585613de3565b95945050505050565b6000612080614acb565b600061208a613b4f565b600b54919350915081146120f95781516009819055600b82905560408051602081019091529081527f08f3ed03ec9e579d1f6ab2f9e0d3dc661704696deabe37a6b6df7014f1b30a97906120dd90613cbf565b600b546040805192835260208301919091528051918290030190a15b600154604080517f42726f6b6572000000000000000000000000000000000000000000000000000060208083019190915282518083036006018152602683018085528151918301919091207fdd92723300000000000000000000000000000000000000000000000000000000909152602a83015291516001600160a01b039093169263dd92723392604a80840193919291829003018186803b15801561219e57600080fd5b505afa1580156121b2573d6000803e3d6000fd5b505050506040513d60208110156121c857600080fd5b50516001600160a01b031633148061226057506001546001600160a01b031663dd9272336121f4611c01565b6040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b15801561222857600080fd5b505afa15801561223c573d6000803e3d6000fd5b505050506040513d602081101561225257600080fd5b50516001600160a01b031633145b806123435750600154604080517f4772616e64614d656e746f0000000000000000000000000000000000000000006020808301919091528251808303600b018152602b83018085528151918301919091207fdd92723300000000000000000000000000000000000000000000000000000000909152602f83015291516001600160a01b039093169263dd92723392604f80840193919291829003018186803b15801561230b57600080fd5b505afa15801561231f573d6000803e3d6000fd5b505050506040513d602081101561233557600080fd5b50516001600160a01b031633145b612394576040805162461bcd60e51b815260206004820152601d60248201527f53656e646572206e6f7420617574686f72697a656420746f206275726e000000604482015290519081900360640190fd5b604080516020810190915260095481526000906123b19086613ccf565b33600090815260056020526040902054909150811115612418576040805162461bcd60e51b815260206004820181905260248201527f76616c75652065786365656465642062616c616e6365206f662073656e646572604482015290519081900360640190fd5b60065461242b908263ffffffff61403916565b6006553360009081526005602052604090205461244e908263ffffffff61403916565b336000818152600560209081526040808320949094558351858152935191937fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef929081900390910190a3506001949350505050565b60006060600060f46001600160a01b0316846040516020018082805190602001908083835b602083106124e75780518252601f1990920191602091820191016124c8565b6001836020036101000a0380198251168184511680821785525050505050509050019150506040516020818303038152906040526040518082805190602001908083835b6020831061254a5780518252601f19909201916020918201910161252b565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d80600081146125aa576040519150601f19603f3d011682016040523d82523d6000602084013e6125af565b606091505b5092509050806125f05760405162461bcd60e51b8152600401808060200182810382526038815260200180614c5d6038913960400191505060405180910390fd5b6110ab8260006140b8565b6001600281600090919293565b331561265b576040805162461bcd60e51b815260206004820152601060248201527f4f6e6c7920564d2063616e2063616c6c00000000000000000000000000000000604482015290519081900360640190fd5b612663613f64565b6001600160a01b031663e5839836306040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b1580156126b857600080fd5b505afa1580156126cc573d6000803e3d6000fd5b505050506040513d60208110156126e257600080fd5b5051156127205760405162461bcd60e51b8152600401808060200182810382526022815260200180614c956022913960400191505060405180910390fd5b612728614acb565b6000612732613b4f565b600b54919350915081146127a15781516009819055600b82905560408051602081019091529081527f08f3ed03ec9e579d1f6ab2f9e0d3dc661704696deabe37a6b6df7014f1b30a979061278590613cbf565b600b546040805192835260208301919091528051918290030190a15b604080516020810190915260095481526000906127be9085613ccf565b6001600160a01b0386166000908152600560205260409020549091506127ea908263ffffffff61403916565b6001600160a01b038616600090815260056020526040902055600654612816908263ffffffff61403916565b6006555050505050565b6040805160208082018590528183018490528251808303840181526060928301938490528051600094859360fa939282918401908083835b602083106128775780518252601f199092019160209182019101612858565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d80600081146128d7576040519150601f19603f3d011682016040523d82523d6000602084013e6128dc565b606091505b50925090508061291d5760405162461bcd60e51b8152600401808060200182810382526036815260200180614d5f6036913960400191505060405180910390fd5b61206d826000613cc3565b60006060600060f66001600160a01b0316846040516020018082805190602001908083835b6020831061296c5780518252601f19909201916020918201910161294d565b6001836020036101000a0380198251168184511680821785525050505050509050019150506040516020818303038152906040526040518082805190602001908083835b602083106129cf5780518252601f1990920191602091820191016129b0565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d8060008114612a2f576040519150601f19603f3d011682016040523d82523d6000602084013e612a34565b606091505b5092509050806125f05760405162461bcd60e51b8152600401808060200182810382526023815260200180614f146023913960400191505060405180910390fd5b3315612ac8576040805162461bcd60e51b815260206004820152601060248201527f4f6e6c7920564d2063616e2063616c6c00000000000000000000000000000000604482015290519081900360640190fd5b612ad0613f64565b6001600160a01b031663e5839836306040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b158015612b2557600080fd5b505afa158015612b39573d6000803e3d6000fd5b505050506040513d6020811015612b4f57600080fd5b505115612b8d5760405162461bcd60e51b8152600401808060200182810382526022815260200180614c956022913960400191505060405180910390fd5b60408051602081019091526009548152600090612baa9086613ccf565b6001600160a01b038a16600090815260056020526040902054909150612bd6908263ffffffff613f0a16565b6001600160a01b038a16600090815260056020526040902055612c0a612bfd8a8885614129565b829063ffffffff613f0a16565b9050612c1a612bfd8a8a87614129565b9050612c2a612bfd8a8986614129565b600654909150612c40908263ffffffff613f0a16565b600655505050505050505050565b6001600160a01b038116600090815260056020526040812054611bfb906134dc565b612c78612fb9565b612cc9576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b6000611107436137e9565b6001546001600160a01b031681565b60006060600060f96001600160a01b031643604051602001808281526020019150506040516020818303038152906040526040518082805190602001908083835b60208310612da55780518252601f199092019160209182019101612d86565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d8060008114612e05576040519150601f19603f3d011682016040523d82523d6000602084013e612e0a565b606091505b509250905080612e4b5760405162461bcd60e51b8152600401808060200182810382526035815260200180614d2a6035913960400191505060405180910390fd5b612e56826000613cc3565b9250505090565b60006060600060f76001600160a01b0316846040516020018082805190602001908083835b60208310612ea15780518252601f199092019160209182019101612e82565b6001836020036101000a0380198251168184511680821785525050505050509050019150506040516020818303038152906040526040518082805190602001908083835b60208310612f045780518252601f199092019160209182019101612ee5565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d8060008114612f64576040519150601f19603f3d011682016040523d82523d6000602084013e612f69565b606091505b5092509050806110a05760405162461bcd60e51b8152600401808060200182810382526031815260200180614eb96031913960400191505060405180910390fd5b6000546001600160a01b031690565b600080546001600160a01b0316612fce6141e9565b6001600160a01b031614905090565b60038054604080516020601f60027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff610100600188161502019095169490940493840181900481028201810190925282815260609390929091830182828015610e685780601f10610e3d57610100808354040283529160200191610e68565b600061110743611be8565b60006060600060f96001600160a01b031684604051602001808281526020019150506040516020818303038152906040526040518082805190602001908083835b602083106130c75780518252601f1990920191602091820191016130a8565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d8060008114613127576040519150601f19603f3d011682016040523d82523d6000602084013e61312c565b606091505b5092509050806110a05760405162461bcd60e51b815260040180806020018281038252602e815260200180614b95602e913960400191505060405180910390fd5b6000613177614acb565b6000613181613b4f565b600b54919350915081146131f05781516009819055600b82905560408051602081019091529081527f08f3ed03ec9e579d1f6ab2f9e0d3dc661704696deabe37a6b6df7014f1b30a97906131d490613cbf565b600b546040805192835260208301919091528051918290030190a15b3360009081526007602090815260408083206001600160a01b038916845290915281205490611b7c828763ffffffff61403916565b6040805160208101909152600854815260009081908190819061324790613cbf565b6040805160208101909152600954815261326090613cbf565b600a54600b54929791965094509092509050565b600061327e614acb565b6000613288613b4f565b600b54919350915081146132f75781516009819055600b82905560408051602081019091529081527f08f3ed03ec9e579d1f6ab2f9e0d3dc661704696deabe37a6b6df7014f1b30a97906132db90613cbf565b600b546040805192835260208301919091528051918290030190a15b6132ff613f64565b6001600160a01b031663e5839836306040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561335457600080fd5b505afa158015613368573d6000803e3d6000fd5b505050506040513d602081101561337e57600080fd5b5051156133bc5760405162461bcd60e51b8152600401808060200182810382526022815260200180614c956022913960400191505060405180910390fd5b61206d85856141ed565b6133ce612fb9565b61341f576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03811661347a576040805162461bcd60e51b815260206004820181905260248201527f43616e6e6f7420726567697374657220746865206e756c6c2061646472657373604482015290519081900360640190fd5b600180547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383169081179091556040517f27fe5f0c1c3b1ed427cc63d0f05759ffdecf9aec9e18d31ef366fc8a6cb5dc3b90600090a250565b60006134e6614acb565b6134ee613b4f565b5090506110d261350d8261350186614353565b9063ffffffff6143c116565b6144a5565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205490565b604080516000808252602082019283905281519092606092849260f89290819081908082805b602083106135825780518252601f199092019160209182019101613563565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d80600081146135e2576040519150601f19603f3d011682016040523d82523d6000602084013e6135e7565b606091505b509250905080612e4b5760405162461bcd60e51b8152600401808060200182810382526025815260200180614e686025913960400191505060405180910390fd5b6000613632614acb565b600061363c613b4f565b600b54919350915081146136ab5781516009819055600b82905560408051602081019091529081527f08f3ed03ec9e579d1f6ab2f9e0d3dc661704696deabe37a6b6df7014f1b30a979061368f90613cbf565b600b546040805192835260208301919091528051918290030190a15b6136b3613f64565b6001600160a01b031663e5839836306040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b0316815260200191505060206040518083038186803b15801561370857600080fd5b505afa15801561371c573d6000803e3d6000fd5b505050506040513d602081101561373257600080fd5b5051156137705760405162461bcd60e51b8152600401808060200182810382526022815260200180614c956022913960400191505060405180910390fd5b600061377c8888613274565b90507fe5d4e30fb8364e57bc4d662a07d0cf36f4c34552004c4c3624620a2c1d1c03dc868660405180806020018281038252848482818152602001925080828437600083820152604051601f909101601f19169092018290039550909350505050a1979650505050505050565b6000611bfb600361381b600261380f600261380388613067565b9063ffffffff6144b616565b9063ffffffff613f0a16565b9063ffffffff61450f16565b600080861580159061383857508415155b613889576040805162461bcd60e51b815260206004820152601560248201527f612064656e6f6d696e61746f72206973207a65726f0000000000000000000000604482015290519081900360640190fd5b6000806000606060fc6001600160a01b03168c8c8c8c8c8c6040516020018087815260200186815260200185815260200184815260200183815260200182815260200196505050505050506040516020818303038152906040526040518082805190602001908083835b602083106139125780518252601f1990920191602091820191016138f3565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d8060008114613972576040519150601f19603f3d011682016040523d82523d6000602084013e613977565b606091505b509092509050816139b95760405162461bcd60e51b8152600401808060200182810382526027815260200180614e416027913960400191505060405180910390fd5b6139c4816000613cc3565b93506139d1816020613cc3565b939c939b50929950505050505050505050565b6139ec612fb9565b613a3d576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b613a4681613ced565b50565b60006060600060f56001600160a01b031684604051602001808281526020019150506040516020818303038152906040526040518082805190602001908083835b60208310613aa95780518252601f199092019160209182019101613a8a565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855afa9150503d8060008114613b09576040519150601f19603f3d011682016040523d82523d6000602084013e613b0e565b606091505b5092509050806125f05760405162461bcd60e51b815260040180806020018281038252602c815260200180614e8d602c913960400191505060405180910390fd5b613b57614acb565b600a54600b54600091613b70919063ffffffff613f0a16565b421015613b92575050600b546040805160208101909152600954815290613cbb565b600a54600b5460009182918291613bb49161381b90429063ffffffff61403916565b60408051602081019091526009548152909150613c1590613bd490613cbf565b613be4613bdf613dbf565b613cbf565b60408051602081019091526008548152613bfd90613cbf565b613c08613bdf613dbf565b600454869060ff16613827565b9093509150821580613c25575081155b15613c4a575050600b546040805160208101909152600954815293509150613cbb9050565b613c52614acb565b613c67613c5e84613da5565b61350186613da5565b90506000613cb0613ca160086002015461381b613c926008600301544261403990919063ffffffff16565b600a549063ffffffff6144b616565b600b549063ffffffff613f0a16565b919650909450505050505b9091565b5190565b60006110d283836140b8565b60006110d261350d613ce084614353565b859063ffffffff61455116565b6001600160a01b038116613d325760405162461bcd60e51b8152600401808060200182810382526026815260200180614bea6026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b613dad614acb565b50604080516020810190915290815290565b613dc7614acb565b50604080516020810190915269d3c21bcecceda1000000815290565b60006001600160a01b038316613e40576040805162461bcd60e51b815260206004820152601760248201527f3020697320612072657365727665642061646472657373000000000000000000604482015290519081900360640190fd5b81613e4d57506001611bfb565b60408051602081019091526009548152600090613e6a9084613ccf565b600654909150613e80908263ffffffff613f0a16565b6006556001600160a01b038416600090815260056020526040902054613eac908263ffffffff613f0a16565b6001600160a01b03851660008181526005602090815260408083209490945583518781529351929391927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9281900390910190a35060019392505050565b6000828201838110156110d2576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b600154604080517f467265657a65720000000000000000000000000000000000000000000000000060208083019190915282518083036007018152602783018085528151918301919091207fdcf0aaed00000000000000000000000000000000000000000000000000000000909152602b83015291516000936001600160a01b03169263dcf0aaed92604b8082019391829003018186803b15801561400857600080fd5b505afa15801561401c573d6000803e3d6000fd5b505050506040513d602081101561403257600080fd5b5051905090565b60006110d283836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506148c3565b60008082848161408757fe5b04905082848161409357fe5b0661409f579050611bfb565b6140b081600163ffffffff613f0a16565b915050611bfb565b60006140cb82602063ffffffff613f0a16565b83511015614120576040805162461bcd60e51b815260206004820152601460248201527f736c6963696e67206f7574206f662072616e6765000000000000000000000000604482015290519081900360640190fd5b50016020015190565b60006001600160a01b038316614141575060006110d2565b6040805160208101909152600954815260009061415e9084613ccf565b6001600160a01b03851660009081526005602052604090205490915061418a908263ffffffff613f0a16565b6001600160a01b0380861660008181526005602090815260409182902094909455805187815290519193928916927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef92918290030190a3949350505050565b3390565b60006001600160a01b0383166142345760405162461bcd60e51b815260040180806020018281038252602a815260200180614eea602a913960400191505060405180910390fd5b604080516020810190915260095481526000906142519084613ccf565b336000908152600560205260409020549091508111156142a25760405162461bcd60e51b8152600401808060200182810382526029815260200180614de06029913960400191505060405180910390fd5b336000908152600560205260409020546142c2908263ffffffff61403916565b33600090815260056020526040808220929092556001600160a01b038616815220546142f4908263ffffffff613f0a16565b6001600160a01b0385166000818152600560209081526040918290209390935580518681529051919233927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9281900390910190a35060019392505050565b61435b614acb565b61436361495a565b8211156143a15760405162461bcd60e51b8152600401808060200182810382526036815260200180614cb76036913960400191505060405180910390fd5b50604080516020810190915269d3c21bcecceda100000082028152919050565b6143c9614acb565b815161441c576040805162461bcd60e51b815260206004820152601160248201527f63616e2774206469766964652062792030000000000000000000000000000000604482015290519081900360640190fd5b825169d3c21bcecceda10000008181029190820414614482576040805162461bcd60e51b815260206004820152601260248201527f6f766572666c6f77206174206469766964650000000000000000000000000000604482015290519081900360640190fd5b60405180602001604052808460000151838161449a57fe5b049052949350505050565b5169d3c21bcecceda1000000900490565b6000826144c557506000611bfb565b828202828482816144d257fe5b04146110d25760405162461bcd60e51b8152600401808060200182810382526021815260200180614dbf6021913960400191505060405180910390fd5b60006110d283836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250614975565b614559614acb565b8251158061456657508151155b156145805750604080516020810190915260008152611bfb565b815169d3c21bcecceda1000000141561459a575081611bfb565b825169d3c21bcecceda100000014156145b4575080611bfb565b600069d3c21bcecceda10000006145ca856149da565b51816145d257fe5b04905060006145e085614a0f565b519050600069d3c21bcecceda10000006145f9866149da565b518161460157fe5b049050600061460f86614a0f565b5190508382028415614678578285828161462557fe5b0414614678576040805162461bcd60e51b815260206004820152601660248201527f6f766572666c6f77207831793120646574656374656400000000000000000000604482015290519081900360640190fd5b69d3c21bcecceda1000000810281156146f25769d3c21bcecceda100000082828161469f57fe5b04146146f2576040805162461bcd60e51b815260206004820152601f60248201527f6f766572666c6f772078317931202a2066697865643120646574656374656400604482015290519081900360640190fd5b905080848402851561475b578486828161470857fe5b041461475b576040805162461bcd60e51b815260206004820152601660248201527f6f766572666c6f77207832793120646574656374656400000000000000000000604482015290519081900360640190fd5b86840287156147c1578488828161476e57fe5b04146147c1576040805162461bcd60e51b815260206004820152601660248201527f6f766572666c6f77207831793220646574656374656400000000000000000000604482015290519081900360640190fd5b6147c9614a49565b87816147d157fe5b0496506147dc614a49565b85816147e457fe5b049450868502871561484d57858882816147fa57fe5b041461484d576040805162461bcd60e51b815260206004820152601660248201527f6f766572666c6f77207832793220646574656374656400000000000000000000604482015290519081900360640190fd5b614855614acb565b604051806020016040528087815250905061487e81604051806020016040528087815250614a52565b905061489881604051806020016040528086815250614a52565b90506148b281604051806020016040528085815250614a52565b9d9c50505050505050505050505050565b600081848411156149525760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156149175781810151838201526020016148ff565b50505050905090810190601f1680156149445780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b7601357c299a88ea76a58924d52ce4f26a85af186c2b9e7490565b600081836149c45760405162461bcd60e51b81526020600482018181528351602484015283519092839260449091019190850190808383600083156149175781810151838201526020016148ff565b5060008385816149d057fe5b0495945050505050565b6149e2614acb565b604051806020016040528069d3c21bcecceda100000080856000015181614a0557fe5b0402905292915050565b614a17614acb565b604051806020016040528069d3c21bcecceda100000080856000015181614a3a57fe5b95519504029093039092525090565b64e8d4a5100090565b614a5a614acb565b8151835190810190811015614ab6576040805162461bcd60e51b815260206004820152601560248201527f616464206f766572666c6f772064657465637465640000000000000000000000604482015290519081900360640190fd5b60408051602081019091529081529392505050565b6040518060200160405280600081525090565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10614b3d578280017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00823516178555614b6a565b82800160010185558215614b6a579182015b82811115614b6a578235825591602001919060010190614b4f565b50614b76929150614b7a565b5090565b610e7091905b80821115614b765760008155600101614b8056fe6572726f722063616c6c696e67206e756d62657256616c696461746f7273496e53657420707265636f6d70696c65696e666c6174696f6e466163746f72557064617465506572696f64206d757374206265203e20304f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573734d7573742070726f766964652061206e6f6e2d7a65726f20696e666c6174696f6e20726174654d7573742070726f766964652061206e6f6e2d7a65726f20696e666c6174696f6e20726174652e6572726f722063616c6c696e672067657456657269666965645365616c4269746d617046726f6d48656164657220707265636f6d70696c6563616e27742063616c6c207768656e20636f6e74726163742069732066726f7a656e63616e277420637265617465206669786964697479206e756d626572206c6172676572207468616e206d61784e6577466978656428296572726f722063616c6c696e672076616c696461746f725369676e65724164647265737346726f6d43757272656e7453657420707265636f6d70696c656572726f722063616c6c696e67206e756d62657256616c696461746f7273496e43757272656e7453657420707265636f6d70696c656572726f722063616c6c696e672076616c696461746f725369676e65724164647265737346726f6d53657420707265636f6d70696c6572657365727665642061646472657373203078302063616e6e6f74206861766520616c6c6f77616e6365536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f777472616e736665722076616c75652065786365656465642062616c616e6365206f662073656e6465727472616e736665722076616c75652065786365656465642073656e646572277320616c6c6f77616e636520666f7220726563697069656e746572726f722063616c6c696e67206672616374696f6e4d756c45787020707265636f6d70696c656572726f722063616c6c696e672067657445706f636853697a6520707265636f6d70696c656572726f722063616c6c696e6720676574506172656e745365616c4269746d617020707265636f6d70696c656572726f722063616c6c696e6720676574426c6f636b4e756d62657246726f6d48656164657220707265636f6d70696c657472616e7366657220617474656d7074656420746f2072657365727665642061646472657373203078306572726f722063616c6c696e67206861736848656164657220707265636f6d70696c65a265627a7a7231582023304dc3d3d86adc84723c7862e6ae0d092f4d528cdd4f75f0f1433e99d106e664736f6c634300051100320000000000000000000000000000000000000000000000000000000000000000", + "nonce": "0x7d" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0xbc89736d925776e3d13b916fd62f05484527406006238b4eefdc9e217f9192f9", + "transactionType": "CALL", + "contractName": "StableTokenXOF", + "contractAddress": "0xb5ECB577604169C2dC80621a31A938BEaF06aDa6", + "function": "transferOwnership(address)", + "arguments": [ + "0xD533Ca259b330c7A88f74E000a3FaEa2d63B7972" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "to": "0xb5ecb577604169c2dc80621a31a938beaf06ada6", + "gas": "0x9adf", + "value": "0x0", + "data": "0xf2fde38b000000000000000000000000d533ca259b330c7a88f74e000a3faea2d63b7972", + "nonce": "0x7e" + }, + "additionalContracts": [], + "isFixedGasLimit": false + } + ], + "receipts": [ + { + "transactionHash": "0x213fa5f650df2731f778088560d15a553aaed4ddfe249c1600cf77f054fa7b97", + "transactionIndex": "0x4", + "blockHash": "0x53b609c4c25f01688d941d9a33d93e514e247b1d9bc69e3f75fa4216250bd99b", + "blockNumber": "0x13f3ae6", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": null, + "cumulativeGasUsed": "0x4a51aa", + "gasUsed": "0x4415b2", + "contractAddress": "0xb5ECB577604169C2dC80621a31A938BEaF06aDa6", + "logs": [ + { + "address": "0xb5ECB577604169C2dC80621a31A938BEaF06aDa6", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0x53b609c4c25f01688d941d9a33d93e514e247b1d9bc69e3f75fa4216250bd99b", + "blockNumber": "0x13f3ae6", + "transactionHash": "0x213fa5f650df2731f778088560d15a553aaed4ddfe249c1600cf77f054fa7b97", + "transactionIndex": "0x4", + "logIndex": "0xd", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000020800000000000000000000000000000000000000000010000000400000000000000000000000000000000000000000000000000000000000001000000000000020000000000000000000000020000000000000000000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000000000020000004000000000000000000000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0x5d21dba00" + }, + { + "transactionHash": "0xbc89736d925776e3d13b916fd62f05484527406006238b4eefdc9e217f9192f9", + "transactionIndex": "0x5", + "blockHash": "0x53b609c4c25f01688d941d9a33d93e514e247b1d9bc69e3f75fa4216250bd99b", + "blockNumber": "0x13f3ae6", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": "0xb5ECB577604169C2dC80621a31A938BEaF06aDa6", + "cumulativeGasUsed": "0x4ac1ca", + "gasUsed": "0x7020", + "contractAddress": null, + "logs": [ + { + "address": "0xb5ECB577604169C2dC80621a31A938BEaF06aDa6", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", + "0x000000000000000000000000d533ca259b330c7a88f74e000a3faea2d63b7972" + ], + "data": "0x", + "blockHash": "0x53b609c4c25f01688d941d9a33d93e514e247b1d9bc69e3f75fa4216250bd99b", + "blockNumber": "0x13f3ae6", + "transactionHash": "0xbc89736d925776e3d13b916fd62f05484527406006238b4eefdc9e217f9192f9", + "transactionIndex": "0x5", + "logIndex": "0xe", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000020800000000000000000000000000000000000000000010000000400000000000000000000000000000000100000000000000000000000000001000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080400000000000000000000000000000000000000000000000000000000000000000000000004000000000000000004000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0x5d21dba00" + } + ], + "libraries": [ + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x6200F54D73491d56b8d7A975C9ee18EFb4D518Df", + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0xED477A99035d0c1e11369F1D7A4e587893cc002B" + ], + "pending": [], + "returns": {}, + "timestamp": 1692273815, + "chain": 42220, + "multi": false, + "commit": "5ce3b55" +} \ No newline at end of file diff --git a/contracts/NonrecoverableValueDeltaBreaker.sol b/contracts/NonrecoverableValueDeltaBreaker.sol new file mode 100644 index 00000000..bcfcd180 --- /dev/null +++ b/contracts/NonrecoverableValueDeltaBreaker.sol @@ -0,0 +1,25 @@ +// SPDX-License-Identifier: GPL-3.0-or-later +pragma solidity ^0.5.13; +import { ISortedOracles } from "mento-core-2.2.0/interfaces/ISortedOracles.sol"; +import { ValueDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/ValueDeltaBreaker.sol"; + +contract NonrecoverableValueDeltaBreaker is ValueDeltaBreaker { + constructor( + uint256 _defaultCooldownTime, + uint256 _defaultRateChangeThreshold, + ISortedOracles _sortedOracles, + address[] memory rateFeedIDs, + uint256[] memory rateChangeThresholds, + uint256[] memory cooldownTimes + ) + public + ValueDeltaBreaker( + _defaultCooldownTime, + _defaultRateChangeThreshold, + _sortedOracles, + rateFeedIDs, + rateChangeThresholds, + cooldownTimes + ) + {} +} diff --git a/script/upgrades/MU04/MU04.sol b/script/upgrades/MU04/MU04.sol index 081fd2f4..b26efd40 100644 --- a/script/upgrades/MU04/MU04.sol +++ b/script/upgrades/MU04/MU04.sol @@ -134,7 +134,6 @@ contract MU04 is IMentoUpgrade, GovernanceScript { proposal_initializeEXOFToken(config); proposal_addEXOFToReserves(); - proposal_addEXOFToRegistry(); proposal_enableGasPaymentsWithEXOF(); proposal_configureEXOFConstitutionParameters(); proposal_createExchanges(config); @@ -209,19 +208,6 @@ contract MU04 is IMentoUpgrade, GovernanceScript { } } - /** - * @notice Adds eXOF to the registry - */ - function proposal_addEXOFToRegistry() private { - transactions.push( - ICeloGovernance.Transaction( - 0, - REGISTRY_ADDRESS, - abi.encodeWithSelector(IRegistry(0).setAddressFor.selector, "StableTokenXOF", eXOFProxy) - ) - ); - } - /** * @notice enable gas payments with XOF */ @@ -369,7 +355,7 @@ contract MU04 is IMentoUpgrade, GovernanceScript { breakerBox, abi.encodeWithSelector( BreakerBox(0).addRateFeeds.selector, - Arrays.addresses(contracts.celoRegistry("StableTokenXOF"), contracts.dependency("EUROCXOFRateFeedAddr")) + Arrays.addresses(eXOFProxy, contracts.dependency("EUROCXOFRateFeedAddr")) ) ) ); @@ -403,7 +389,7 @@ contract MU04 is IMentoUpgrade, GovernanceScript { } } - for (uint256 i = 0; i < config.rateFeeds.length; i++) { + for (uint i = 0; i < config.rateFeeds.length; i++) { Config.RateFeed memory rateFeed = config.rateFeeds[i]; // Enable Median Delta Breaker for rate feed if (rateFeed.medianDeltaBreaker0.enabled) { @@ -488,14 +474,9 @@ contract MU04 is IMentoUpgrade, GovernanceScript { } /** - * @notice This function creates the transactions to configure the first Value Delta Breaker . + * @notice This function creates the transactions to configure the recoverable Value Delta Breaker . */ function proposal_configureValueDeltaBreaker(MU04Config.MU04 memory config) private { - address[] memory valueDeltaBreakerRateFeeds = Arrays.addresses(config.EUROCXOF.rateFeedID); - uint[] memory valueDeltaBreakerCooldownTimes = Arrays.uints(config.EUROCXOF.valueDeltaBreaker0.cooldown); - uint[] memory valueDeltaBreakerThresholds = Arrays.uints(config.EUROCXOF.valueDeltaBreaker0.threshold.unwrap()); - uint[] memory valueDeltaBreakerReferenceValues = Arrays.uints(config.EUROCXOF.valueDeltaBreaker0.referenceValue); - // Set the cooldown times transactions.push( ICeloGovernance.Transaction( @@ -503,8 +484,8 @@ contract MU04 is IMentoUpgrade, GovernanceScript { valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setCooldownTimes.selector, - valueDeltaBreakerRateFeeds, - valueDeltaBreakerCooldownTimes + Arrays.addresses(config.EUROCXOF.rateFeedID), + Arrays.uints(config.EUROCXOF.valueDeltaBreaker0.cooldown) ) ) ); @@ -515,8 +496,8 @@ contract MU04 is IMentoUpgrade, GovernanceScript { valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setRateChangeThresholds.selector, - valueDeltaBreakerRateFeeds, - valueDeltaBreakerThresholds + Arrays.addresses(config.EUROCXOF.rateFeedID), + Arrays.uints(config.EUROCXOF.valueDeltaBreaker0.threshold.unwrap()) ) ) ); @@ -527,8 +508,8 @@ contract MU04 is IMentoUpgrade, GovernanceScript { valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setReferenceValues.selector, - valueDeltaBreakerRateFeeds, - valueDeltaBreakerReferenceValues + Arrays.addresses(config.EUROCXOF.rateFeedID), + Arrays.uints(config.EUROCXOF.valueDeltaBreaker0.referenceValue) ) ) ); diff --git a/script/upgrades/MU04/deploy/MU04-02-Create-Nonupgradeable-Contracts.sol b/script/upgrades/MU04/deploy/MU04-02-Create-Nonupgradeable-Contracts.sol index 4fe186f4..a40c13e9 100644 --- a/script/upgrades/MU04/deploy/MU04-02-Create-Nonupgradeable-Contracts.sol +++ b/script/upgrades/MU04/deploy/MU04-02-Create-Nonupgradeable-Contracts.sol @@ -6,28 +6,7 @@ import { Chain } from "script/utils/Chain.sol"; import { console2 } from "forge-std/Script.sol"; import { ISortedOracles } from "mento-core-2.2.0/interfaces/ISortedOracles.sol"; -import { ValueDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/ValueDeltaBreaker.sol"; - -contract NonrecoverableValueDeltaBreaker is ValueDeltaBreaker { - constructor( - uint256 _defaultCooldownTime, - uint256 _defaultRateChangeThreshold, - ISortedOracles _sortedOracles, - address[] memory rateFeedIDs, - uint256[] memory rateChangeThresholds, - uint256[] memory cooldownTimes - ) - public - ValueDeltaBreaker( - _defaultCooldownTime, - _defaultRateChangeThreshold, - _sortedOracles, - rateFeedIDs, - rateChangeThresholds, - cooldownTimes - ) - {} -} +import { NonrecoverableValueDeltaBreaker } from "contracts/NonrecoverableValueDeltaBreaker.sol"; /* yarn deploy -n -u MU04 -s MU04-02-Create-Nonupgradeable-Contracts.sol From ac52f848c35b29ac8994ce4f73f934a135fdb010 Mon Sep 17 00:00:00 2001 From: boqdan Date: Wed, 23 Aug 2023 10:48:54 +0100 Subject: [PATCH 05/64] feat: turn MU04 into eXOF --- bin/deploy.sh | 2 +- bin/setup.sh | 5 +- .../42220/run-latest.json | 0 .../44787/run-latest.json | 0 .../62320/run-latest.json | 0 .../42220/run-latest.json | 0 .../44787/run-latest.json | 0 .../62320/run-latest.json | 0 .../44787/run-1692783898.json | 64 +++++++ .../44787/run-1692783905.json | 180 ++++++++++++++++++ .../44787/run-1692783955.json | 180 ++++++++++++++++++ .../44787/run-latest.json | 180 ++++++++++++++++++ script/upgrades/dependencies.json | 2 + script/upgrades/{MU04 => eXOF}/Config.sol | 6 +- .../deploy/eXOF-00-Create-Proxies.sol} | 4 +- .../eXOF-01-Create-Implementations.sol} | 4 +- ...OF-02-Create-Nonupgradeable-Contracts.sol} | 4 +- .../upgrades/{MU04/MU04.sol => eXOF/eXOF.sol} | 30 +-- .../MU04Checks.sol => eXOF/eXOFChecks.sol} | 40 ++-- 19 files changed, 654 insertions(+), 47 deletions(-) rename broadcast/{MU04-00-Create-Proxies.sol => eXOF-00-Create-Proxies.sol}/42220/run-latest.json (100%) rename broadcast/{MU04-00-Create-Proxies.sol => eXOF-00-Create-Proxies.sol}/44787/run-latest.json (100%) rename broadcast/{MU04-00-Create-Proxies.sol => eXOF-00-Create-Proxies.sol}/62320/run-latest.json (100%) rename broadcast/{MU04-01-Create-Implementations.sol => eXOF-01-Create-Implementations.sol}/42220/run-latest.json (100%) rename broadcast/{MU04-01-Create-Implementations.sol => eXOF-01-Create-Implementations.sol}/44787/run-latest.json (100%) rename broadcast/{MU04-01-Create-Implementations.sol => eXOF-01-Create-Implementations.sol}/62320/run-latest.json (100%) create mode 100644 broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783898.json create mode 100644 broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783905.json create mode 100644 broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783955.json create mode 100644 broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-latest.json rename script/upgrades/{MU04 => eXOF}/Config.sol (98%) rename script/upgrades/{MU04/deploy/MU04-00-Create-Proxies.sol => eXOF/deploy/eXOF-00-Create-Proxies.sol} (89%) rename script/upgrades/{MU04/deploy/MU04-01-Create-Implementations.sol => eXOF/deploy/eXOF-01-Create-Implementations.sol} (88%) rename script/upgrades/{MU04/deploy/MU04-02-Create-Nonupgradeable-Contracts.sol => eXOF/deploy/eXOF-02-Create-Nonupgradeable-Contracts.sol} (93%) rename script/upgrades/{MU04/MU04.sol => eXOF/eXOF.sol} (95%) rename script/upgrades/{MU04/MU04Checks.sol => eXOF/eXOFChecks.sol} (95%) diff --git a/bin/deploy.sh b/bin/deploy.sh index 6f8c0e5d..1fd8d1a7 100755 --- a/bin/deploy.sh +++ b/bin/deploy.sh @@ -29,7 +29,7 @@ parse_upgrade "$UPGRADE" if ! [ -z "$SCRIPT" ]; then # Pick the script by name SCRIPT_FILE="script/upgrades/$UPGRADE/deploy/$SCRIPT" if test -f "$SCRIPT_FILE"; then - echo "🔎 $SCRIPT_FILE found" + echo "🔎 $SCRIPT_FILE found" forge_script "$SCRIPT" "$SCRIPT_FILE" "$(forge_skip $UPGRADE)" exit 0 else diff --git a/bin/setup.sh b/bin/setup.sh index 58ca7554..d992209c 100644 --- a/bin/setup.sh +++ b/bin/setup.sh @@ -54,10 +54,11 @@ parse_upgrade () { # $1: upgrade forge_skip () { # $1: target if [ "dev" = $1 ]; then # If target is dev script, skip all upgrades - echo "--skip MU" + upgrades=$(ls script/upgrades | tr '\n' ' ') + echo "--skip $upgrades" else # if target is a un upgrade, skip dev and other upgrades - other_upgrades=$(ls script/upgrades | grep MU | grep -v $1 | tr '\n' ' ') + other_upgrades=$(ls script/upgrades | grep -v $1 | tr '\n' ' ') echo "--skip dev- $other_upgrades" fi } diff --git a/broadcast/MU04-00-Create-Proxies.sol/42220/run-latest.json b/broadcast/eXOF-00-Create-Proxies.sol/42220/run-latest.json similarity index 100% rename from broadcast/MU04-00-Create-Proxies.sol/42220/run-latest.json rename to broadcast/eXOF-00-Create-Proxies.sol/42220/run-latest.json diff --git a/broadcast/MU04-00-Create-Proxies.sol/44787/run-latest.json b/broadcast/eXOF-00-Create-Proxies.sol/44787/run-latest.json similarity index 100% rename from broadcast/MU04-00-Create-Proxies.sol/44787/run-latest.json rename to broadcast/eXOF-00-Create-Proxies.sol/44787/run-latest.json diff --git a/broadcast/MU04-00-Create-Proxies.sol/62320/run-latest.json b/broadcast/eXOF-00-Create-Proxies.sol/62320/run-latest.json similarity index 100% rename from broadcast/MU04-00-Create-Proxies.sol/62320/run-latest.json rename to broadcast/eXOF-00-Create-Proxies.sol/62320/run-latest.json diff --git a/broadcast/MU04-01-Create-Implementations.sol/42220/run-latest.json b/broadcast/eXOF-01-Create-Implementations.sol/42220/run-latest.json similarity index 100% rename from broadcast/MU04-01-Create-Implementations.sol/42220/run-latest.json rename to broadcast/eXOF-01-Create-Implementations.sol/42220/run-latest.json diff --git a/broadcast/MU04-01-Create-Implementations.sol/44787/run-latest.json b/broadcast/eXOF-01-Create-Implementations.sol/44787/run-latest.json similarity index 100% rename from broadcast/MU04-01-Create-Implementations.sol/44787/run-latest.json rename to broadcast/eXOF-01-Create-Implementations.sol/44787/run-latest.json diff --git a/broadcast/MU04-01-Create-Implementations.sol/62320/run-latest.json b/broadcast/eXOF-01-Create-Implementations.sol/62320/run-latest.json similarity index 100% rename from broadcast/MU04-01-Create-Implementations.sol/62320/run-latest.json rename to broadcast/eXOF-01-Create-Implementations.sol/62320/run-latest.json diff --git a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783898.json b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783898.json new file mode 100644 index 00000000..937973c6 --- /dev/null +++ b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783898.json @@ -0,0 +1,64 @@ +{ + "transactions": [ + { + "hash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionType": "CREATE", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "function": null, + "arguments": [ + "0", + "0", + "0xFdd8bD58115FfBf04e47411c1d228eCC45E93075", + "[]", + "[]", + "[]" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "gas": "0x1f2d9a", + "value": "0x0", + "data": "0x60806040523480156200001157600080fd5b506040516200242b3803806200242b833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b5050505090500160405250505085858585858560006200020d620002d660201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620023ea833981519152908290a3506200025e336001600160e01b03620002da16565b62000272846001600160e01b036200036c16565b62000286866001600160e01b036200046c16565b6200029a856001600160e01b03620004a716565b620002af83836001600160e01b036200058516565b620002c483826001600160e01b03620007d316565b505050505050505050505050620009fd565b3390565b6001600160a01b038116620003215760405162461bcd60e51b8152600401808060200182810382526026815260200180620023c46026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620023ea83398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b6200037f6001600160e01b036200097016565b620003d1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b81526004018080602001828103825260218152602001806200240a6021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004bd81620009a160201b620017ea1760201c565b51600255620004fd620004db620009bd602090811b620015a217901c565b6040805160208082019092526002548152919062001804620009e3821b17901c565b6200054f576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005dc576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200060157fe5b60200260200101516001600160a01b031614156200065a576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000664620009ea565b6200068e8383815181106200067557fe5b6020026020010151620009a160201b620017ea1760201c565b9050620006be620006a9620009bd60201b620015a21760201c565b82620009e360201b620018041790919060201c565b62000710576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200072257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200078557fe5b60200260200101518484815181106200079a57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005df565b505050565b80518251146200082a576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200084f57fe5b60200260200101516001600160a01b03161415620008a8576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008b557fe5b602002602001015160016000858481518110620008ce57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200092857fe5b60200260200101518383815181106200093d57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a16001016200082d565b6004546000906001600160a01b0316620009926001600160e01b03620002d616565b6001600160a01b031614905090565b620009ab620009ea565b50604080516020810190915290815290565b620009c7620009ea565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b6119b78062000a0d6000396000f3fe608060405234801561001057600080fd5b506004361061016c5760003560e01c806368b89d58116100cd5780638f32d59b11610081578063e829902e11610066578063e829902e14610521578063f2fde38b146105e3578063fd165f53146106165761016c565b80638f32d59b14610511578063a44235cb146105195761016c565b8063715018a6116100b2578063715018a6146104c2578063753d8c2f146104ca5780638da5cb5b146105095761016c565b806368b89d58146103b95780636cac543a146104005761016c565b80633932bcc3116101245780634afb215e116101095780634afb215e1461033657806353f5d6f1146103695780635ac3ff701461039c5761016c565b80633932bcc3146102d057806339b84ecf146103035761016c565b8063132e8aa711610155578063132e8aa7146102525780631893304f146102835780632e37ff73146102c85761016c565b8063020323dd1461017157806305e0478514610235575b600080fd5b6102336004803603604081101561018757600080fd5b8101906020810181356401000000008111156101a257600080fd5b8201836020820111156101b457600080fd5b803590602001918460208302840111640100000000831117156101d657600080fd5b9193909290916020810190356401000000008111156101f457600080fd5b82018360208201111561020657600080fd5b8035906020019184602083028401116401000000008311171561022857600080fd5b509092509050610649565b005b6102336004803603602081101561024b57600080fd5b5035610715565b61025a61077a565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6102b66004803603602081101561029957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610796565b60408051918252519081900360200190f35b6102b66107a8565b6102b6600480360360208110156102e657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107ae565b6102b66004803603602081101561031957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107c0565b6102336004803603602081101561034c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107fd565b6102b66004803603602081101561037f57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610921565b610233600480360360208110156103b257600080fd5b5035610933565b6103ec600480360360208110156103cf57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610995565b604080519115158252519081900360200190f35b6102336004803603604081101561041657600080fd5b81019060208101813564010000000081111561043157600080fd5b82018360208201111561044357600080fd5b8035906020019184602083028401116401000000008311171561046557600080fd5b91939092909160208101903564010000000081111561048357600080fd5b82018360208201111561049557600080fd5b803590602001918460208302840111640100000000831117156104b757600080fd5b5090925090506109a7565b610233610a6d565b6103ec600480360360608110156104e057600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610b35565b61025a610c47565b6103ec610c63565b6102b6610ca3565b6102336004803603604081101561053757600080fd5b81019060208101813564010000000081111561055257600080fd5b82018360208201111561056457600080fd5b8035906020019184602083028401116401000000008311171561058657600080fd5b9193909290916020810190356401000000008111156105a457600080fd5b8201836020820111156105b657600080fd5b803590602001918460208302840111640100000000831117156105d857600080fd5b509092509050610ca9565b610233600480360360208110156105f957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f0e565b6103ec6004803603602081101561062c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f70565b610651610c63565b6106a2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f8484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061105b92505050565b50505050565b61071d610c63565b61076e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610777816112c7565b50565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b60036020526000908152604090205481565b60005481565b60066020526000908152604090205481565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260016020526040812054806107f55750506000546107f8565b90505b919050565b610805610c63565b610856576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166108a85760405162461bcd60e51b81526004018080602001828103825260218152602001806119626021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60016020526000908152604090205481565b61093b610c63565b61098c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077781611382565b60006109a082610f70565b1592915050565b6109af610c63565b610a00576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113bd92505050565b610a75610c63565b610ac6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610b539061159e565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610b939061159e565b90508015610b9f578091505b6000610bb1610bac6115a2565b61159e565b90506000610bc5828563ffffffff6115c616565b90506000610bf369d3c21bcecceda1000000610be78b8563ffffffff61162916565b9063ffffffff61168216565b90506000610c07848763ffffffff6116c416565b90506000610c2969d3c21bcecceda1000000610be78d8563ffffffff61162916565b9050808a1080610c385750828a115b9b9a5050505050505050505050565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610c87611706565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610cb1610c63565b610d02576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b828114610d56576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b83811015610f07576000858583818110610d6f57fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610df5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b828282818110610e0157fe5b9050602002013560066000878785818110610e1857fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fa62a59cb391b90466127d5c2ae9c7cfb59877763680d974867d6abe0c4fd52cb858583818110610ea057fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff16848484818110610ec957fe5b6040805173ffffffffffffffffffffffffffffffffffffffff90951685526020918202939093013590840152508051918290030190a1600101610d59565b5050505050565b610f16610c63565b610f67576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107778161170a565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610fe357600080fd5b505afa158015610ff7573d6000803e3d6000fd5b505050506040513d604081101561100d57600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526006602052604090205490915080611048576000925050506107f8565b611053818386610b35565b949350505050565b80518251146110b1576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff168382815181106110e157fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415611152576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b61115a611907565b61117683838151811061116957fe5b60200260200101516117ea565b90506111906111836115a2565b829063ffffffff61180416565b6111e1576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111f257fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061126e57fe5b602002602001015184848151811061128257fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110b4565b505050565b6112d0816117ea565b516002556112fb6112df6115a2565b604080516020810190915260025481529063ffffffff61180416565b61134c576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b8051825114611413576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff1683828151811061144357fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114b4576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114c057fe5b6020026020010151600160008584815181106114d857fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061154b57fe5b602002602001015183838151811061155f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611416565b5190565b6115aa611907565b50604080516020810190915269d3c21bcecceda1000000815290565b600082820183811015611620576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b60008261163857506000611623565b8282028284828161164557fe5b04146116205760405162461bcd60e51b81526004018080602001828103825260218152602001806119416021913960400191505060405180910390fd5b600061162083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061180b565b600061162083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506118ad565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661175c5760405162461bcd60e51b815260040180806020018281038252602681526020018061191b6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6117f2611907565b50604080516020810190915290815290565b5190511090565b600081836118975760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561185c578181015183820152602001611844565b50505050905090810190601f1680156118895780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816118a357fe5b0495945050505050565b600081848411156118ff5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561185c578181015183820152602001611844565b505050900390565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a7231582011765acba939a6b32e46cb228259748701b284c59dfd4ac49f1e8f56ca5fb53864736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d7573742062652073657400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000fdd8bd58115ffbf04e47411c1d228ecc45e9307500000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "nonce": "0xde" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", + "transactionType": "CALL", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "function": "transferOwnership(address)", + "arguments": [ + "0xAA963FC97281d9632d96700aB62A4D1340F9a28a" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "to": "0x69d7a21025d45d301a396cceffd2d3a80b7c3a5b", + "gas": "0xa387", + "value": "0x0", + "data": "0xf2fde38b000000000000000000000000aa963fc97281d9632d96700ab62a4d1340f9a28a", + "nonce": "0xdf" + }, + "additionalContracts": [], + "isFixedGasLimit": false + } + ], + "receipts": [], + "libraries": [ + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x2F0F7686fFFEfc3C266403Ad600035581deaedff", + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0x29B1B5e05217c751038861aF2C77494EAB10A257" + ], + "pending": [ + "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6" + ], + "returns": {}, + "timestamp": 1692783898, + "chain": 44787, + "multi": false, + "commit": "1071d75" +} \ No newline at end of file diff --git a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783905.json b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783905.json new file mode 100644 index 00000000..f4a44398 --- /dev/null +++ b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783905.json @@ -0,0 +1,180 @@ +{ + "transactions": [ + { + "hash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionType": "CREATE", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "function": null, + "arguments": [ + "0", + "0", + "0xFdd8bD58115FfBf04e47411c1d228eCC45E93075", + "[]", + "[]", + "[]" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "gas": "0x1f2d9a", + "value": "0x0", + "data": "0x60806040523480156200001157600080fd5b506040516200242b3803806200242b833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b5050505090500160405250505085858585858560006200020d620002d660201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620023ea833981519152908290a3506200025e336001600160e01b03620002da16565b62000272846001600160e01b036200036c16565b62000286866001600160e01b036200046c16565b6200029a856001600160e01b03620004a716565b620002af83836001600160e01b036200058516565b620002c483826001600160e01b03620007d316565b505050505050505050505050620009fd565b3390565b6001600160a01b038116620003215760405162461bcd60e51b8152600401808060200182810382526026815260200180620023c46026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620023ea83398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b6200037f6001600160e01b036200097016565b620003d1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b81526004018080602001828103825260218152602001806200240a6021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004bd81620009a160201b620017ea1760201c565b51600255620004fd620004db620009bd602090811b620015a217901c565b6040805160208082019092526002548152919062001804620009e3821b17901c565b6200054f576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005dc576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200060157fe5b60200260200101516001600160a01b031614156200065a576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000664620009ea565b6200068e8383815181106200067557fe5b6020026020010151620009a160201b620017ea1760201c565b9050620006be620006a9620009bd60201b620015a21760201c565b82620009e360201b620018041790919060201c565b62000710576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200072257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200078557fe5b60200260200101518484815181106200079a57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005df565b505050565b80518251146200082a576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200084f57fe5b60200260200101516001600160a01b03161415620008a8576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008b557fe5b602002602001015160016000858481518110620008ce57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200092857fe5b60200260200101518383815181106200093d57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a16001016200082d565b6004546000906001600160a01b0316620009926001600160e01b03620002d616565b6001600160a01b031614905090565b620009ab620009ea565b50604080516020810190915290815290565b620009c7620009ea565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b6119b78062000a0d6000396000f3fe608060405234801561001057600080fd5b506004361061016c5760003560e01c806368b89d58116100cd5780638f32d59b11610081578063e829902e11610066578063e829902e14610521578063f2fde38b146105e3578063fd165f53146106165761016c565b80638f32d59b14610511578063a44235cb146105195761016c565b8063715018a6116100b2578063715018a6146104c2578063753d8c2f146104ca5780638da5cb5b146105095761016c565b806368b89d58146103b95780636cac543a146104005761016c565b80633932bcc3116101245780634afb215e116101095780634afb215e1461033657806353f5d6f1146103695780635ac3ff701461039c5761016c565b80633932bcc3146102d057806339b84ecf146103035761016c565b8063132e8aa711610155578063132e8aa7146102525780631893304f146102835780632e37ff73146102c85761016c565b8063020323dd1461017157806305e0478514610235575b600080fd5b6102336004803603604081101561018757600080fd5b8101906020810181356401000000008111156101a257600080fd5b8201836020820111156101b457600080fd5b803590602001918460208302840111640100000000831117156101d657600080fd5b9193909290916020810190356401000000008111156101f457600080fd5b82018360208201111561020657600080fd5b8035906020019184602083028401116401000000008311171561022857600080fd5b509092509050610649565b005b6102336004803603602081101561024b57600080fd5b5035610715565b61025a61077a565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6102b66004803603602081101561029957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610796565b60408051918252519081900360200190f35b6102b66107a8565b6102b6600480360360208110156102e657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107ae565b6102b66004803603602081101561031957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107c0565b6102336004803603602081101561034c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107fd565b6102b66004803603602081101561037f57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610921565b610233600480360360208110156103b257600080fd5b5035610933565b6103ec600480360360208110156103cf57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610995565b604080519115158252519081900360200190f35b6102336004803603604081101561041657600080fd5b81019060208101813564010000000081111561043157600080fd5b82018360208201111561044357600080fd5b8035906020019184602083028401116401000000008311171561046557600080fd5b91939092909160208101903564010000000081111561048357600080fd5b82018360208201111561049557600080fd5b803590602001918460208302840111640100000000831117156104b757600080fd5b5090925090506109a7565b610233610a6d565b6103ec600480360360608110156104e057600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610b35565b61025a610c47565b6103ec610c63565b6102b6610ca3565b6102336004803603604081101561053757600080fd5b81019060208101813564010000000081111561055257600080fd5b82018360208201111561056457600080fd5b8035906020019184602083028401116401000000008311171561058657600080fd5b9193909290916020810190356401000000008111156105a457600080fd5b8201836020820111156105b657600080fd5b803590602001918460208302840111640100000000831117156105d857600080fd5b509092509050610ca9565b610233600480360360208110156105f957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f0e565b6103ec6004803603602081101561062c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f70565b610651610c63565b6106a2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f8484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061105b92505050565b50505050565b61071d610c63565b61076e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610777816112c7565b50565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b60036020526000908152604090205481565b60005481565b60066020526000908152604090205481565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260016020526040812054806107f55750506000546107f8565b90505b919050565b610805610c63565b610856576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166108a85760405162461bcd60e51b81526004018080602001828103825260218152602001806119626021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60016020526000908152604090205481565b61093b610c63565b61098c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077781611382565b60006109a082610f70565b1592915050565b6109af610c63565b610a00576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113bd92505050565b610a75610c63565b610ac6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610b539061159e565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610b939061159e565b90508015610b9f578091505b6000610bb1610bac6115a2565b61159e565b90506000610bc5828563ffffffff6115c616565b90506000610bf369d3c21bcecceda1000000610be78b8563ffffffff61162916565b9063ffffffff61168216565b90506000610c07848763ffffffff6116c416565b90506000610c2969d3c21bcecceda1000000610be78d8563ffffffff61162916565b9050808a1080610c385750828a115b9b9a5050505050505050505050565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610c87611706565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610cb1610c63565b610d02576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b828114610d56576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b83811015610f07576000858583818110610d6f57fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610df5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b828282818110610e0157fe5b9050602002013560066000878785818110610e1857fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fa62a59cb391b90466127d5c2ae9c7cfb59877763680d974867d6abe0c4fd52cb858583818110610ea057fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff16848484818110610ec957fe5b6040805173ffffffffffffffffffffffffffffffffffffffff90951685526020918202939093013590840152508051918290030190a1600101610d59565b5050505050565b610f16610c63565b610f67576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107778161170a565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610fe357600080fd5b505afa158015610ff7573d6000803e3d6000fd5b505050506040513d604081101561100d57600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526006602052604090205490915080611048576000925050506107f8565b611053818386610b35565b949350505050565b80518251146110b1576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff168382815181106110e157fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415611152576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b61115a611907565b61117683838151811061116957fe5b60200260200101516117ea565b90506111906111836115a2565b829063ffffffff61180416565b6111e1576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111f257fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061126e57fe5b602002602001015184848151811061128257fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110b4565b505050565b6112d0816117ea565b516002556112fb6112df6115a2565b604080516020810190915260025481529063ffffffff61180416565b61134c576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b8051825114611413576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff1683828151811061144357fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114b4576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114c057fe5b6020026020010151600160008584815181106114d857fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061154b57fe5b602002602001015183838151811061155f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611416565b5190565b6115aa611907565b50604080516020810190915269d3c21bcecceda1000000815290565b600082820183811015611620576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b60008261163857506000611623565b8282028284828161164557fe5b04146116205760405162461bcd60e51b81526004018080602001828103825260218152602001806119416021913960400191505060405180910390fd5b600061162083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061180b565b600061162083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506118ad565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661175c5760405162461bcd60e51b815260040180806020018281038252602681526020018061191b6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6117f2611907565b50604080516020810190915290815290565b5190511090565b600081836118975760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561185c578181015183820152602001611844565b50505050905090810190601f1680156118895780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816118a357fe5b0495945050505050565b600081848411156118ff5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561185c578181015183820152602001611844565b505050900390565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a7231582011765acba939a6b32e46cb228259748701b284c59dfd4ac49f1e8f56ca5fb53864736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d7573742062652073657400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000fdd8bd58115ffbf04e47411c1d228ecc45e9307500000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "nonce": "0xde" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", + "transactionType": "CALL", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "function": "transferOwnership(address)", + "arguments": [ + "0xAA963FC97281d9632d96700aB62A4D1340F9a28a" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "to": "0x69d7a21025d45d301a396cceffd2d3a80b7c3a5b", + "gas": "0xa387", + "value": "0x0", + "data": "0xf2fde38b000000000000000000000000aa963fc97281d9632d96700ab62a4d1340f9a28a", + "nonce": "0xdf" + }, + "additionalContracts": [], + "isFixedGasLimit": false + } + ], + "receipts": [ + { + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": null, + "cumulativeGasUsed": "0x17e762", + "gasUsed": "0x17e762", + "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "logs": [ + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x0", + "removed": false + }, + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x1", + "removed": false + }, + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f7353" + ], + "data": "0x000000000000000000000000fdd8bd58115ffbf04e47411c1d228ecc45e93075", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x2", + "removed": false + }, + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a2" + ], + "data": "0x0000000000000000000000000000000000000000000000000000000000000000", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x3", + "removed": false + }, + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0xd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d" + ], + "data": "0x0000000000000000000000000000000000000000000000000000000000000000", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x4", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000022800000000000000000080000000000000000000000010000000000001000000000000000000000000000008000000000000000000000000001000000000000000000000000000000800000020000000000000200000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000800000000000000000000008000000000000000000000000000000000000000000000000000000000000000000080000000000000000004000000000000020000004000000000001000000000000000000000000000000000000000020000000", + "type": "0x0", + "effectiveGasPrice": "0x5d21dba00" + }, + { + "transactionHash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", + "transactionIndex": "0x1", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "cumulativeGasUsed": "0x185733", + "gasUsed": "0x6fd1", + "contractAddress": null, + "logs": [ + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", + "0x000000000000000000000000aa963fc97281d9632d96700ab62a4d1340f9a28a" + ], + "data": "0x", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", + "transactionIndex": "0x1", + "logIndex": "0x5", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000020000000000000000000000000000000000020800000000000000000080000004000000000000000010000000000000000000000000000000000000000008000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0x5d21dba00" + } + ], + "libraries": [ + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x2F0F7686fFFEfc3C266403Ad600035581deaedff", + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0x29B1B5e05217c751038861aF2C77494EAB10A257" + ], + "pending": [], + "returns": {}, + "timestamp": 1692783905, + "chain": 44787, + "multi": false, + "commit": "1071d75" +} \ No newline at end of file diff --git a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783955.json b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783955.json new file mode 100644 index 00000000..ed40e2ac --- /dev/null +++ b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783955.json @@ -0,0 +1,180 @@ +{ + "transactions": [ + { + "hash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionType": "CREATE", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "function": null, + "arguments": [ + "0", + "0", + "0xFdd8bD58115FfBf04e47411c1d228eCC45E93075", + "[]", + "[]", + "[]" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "gas": "0x1f2d9a", + "value": "0x0", + "data": "0x60806040523480156200001157600080fd5b506040516200242b3803806200242b833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b5050505090500160405250505085858585858560006200020d620002d660201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620023ea833981519152908290a3506200025e336001600160e01b03620002da16565b62000272846001600160e01b036200036c16565b62000286866001600160e01b036200046c16565b6200029a856001600160e01b03620004a716565b620002af83836001600160e01b036200058516565b620002c483826001600160e01b03620007d316565b505050505050505050505050620009fd565b3390565b6001600160a01b038116620003215760405162461bcd60e51b8152600401808060200182810382526026815260200180620023c46026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620023ea83398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b6200037f6001600160e01b036200097016565b620003d1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b81526004018080602001828103825260218152602001806200240a6021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004bd81620009a160201b620017ea1760201c565b51600255620004fd620004db620009bd602090811b620015a217901c565b6040805160208082019092526002548152919062001804620009e3821b17901c565b6200054f576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005dc576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200060157fe5b60200260200101516001600160a01b031614156200065a576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000664620009ea565b6200068e8383815181106200067557fe5b6020026020010151620009a160201b620017ea1760201c565b9050620006be620006a9620009bd60201b620015a21760201c565b82620009e360201b620018041790919060201c565b62000710576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200072257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200078557fe5b60200260200101518484815181106200079a57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005df565b505050565b80518251146200082a576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200084f57fe5b60200260200101516001600160a01b03161415620008a8576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008b557fe5b602002602001015160016000858481518110620008ce57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200092857fe5b60200260200101518383815181106200093d57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a16001016200082d565b6004546000906001600160a01b0316620009926001600160e01b03620002d616565b6001600160a01b031614905090565b620009ab620009ea565b50604080516020810190915290815290565b620009c7620009ea565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b6119b78062000a0d6000396000f3fe608060405234801561001057600080fd5b506004361061016c5760003560e01c806368b89d58116100cd5780638f32d59b11610081578063e829902e11610066578063e829902e14610521578063f2fde38b146105e3578063fd165f53146106165761016c565b80638f32d59b14610511578063a44235cb146105195761016c565b8063715018a6116100b2578063715018a6146104c2578063753d8c2f146104ca5780638da5cb5b146105095761016c565b806368b89d58146103b95780636cac543a146104005761016c565b80633932bcc3116101245780634afb215e116101095780634afb215e1461033657806353f5d6f1146103695780635ac3ff701461039c5761016c565b80633932bcc3146102d057806339b84ecf146103035761016c565b8063132e8aa711610155578063132e8aa7146102525780631893304f146102835780632e37ff73146102c85761016c565b8063020323dd1461017157806305e0478514610235575b600080fd5b6102336004803603604081101561018757600080fd5b8101906020810181356401000000008111156101a257600080fd5b8201836020820111156101b457600080fd5b803590602001918460208302840111640100000000831117156101d657600080fd5b9193909290916020810190356401000000008111156101f457600080fd5b82018360208201111561020657600080fd5b8035906020019184602083028401116401000000008311171561022857600080fd5b509092509050610649565b005b6102336004803603602081101561024b57600080fd5b5035610715565b61025a61077a565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6102b66004803603602081101561029957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610796565b60408051918252519081900360200190f35b6102b66107a8565b6102b6600480360360208110156102e657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107ae565b6102b66004803603602081101561031957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107c0565b6102336004803603602081101561034c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107fd565b6102b66004803603602081101561037f57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610921565b610233600480360360208110156103b257600080fd5b5035610933565b6103ec600480360360208110156103cf57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610995565b604080519115158252519081900360200190f35b6102336004803603604081101561041657600080fd5b81019060208101813564010000000081111561043157600080fd5b82018360208201111561044357600080fd5b8035906020019184602083028401116401000000008311171561046557600080fd5b91939092909160208101903564010000000081111561048357600080fd5b82018360208201111561049557600080fd5b803590602001918460208302840111640100000000831117156104b757600080fd5b5090925090506109a7565b610233610a6d565b6103ec600480360360608110156104e057600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610b35565b61025a610c47565b6103ec610c63565b6102b6610ca3565b6102336004803603604081101561053757600080fd5b81019060208101813564010000000081111561055257600080fd5b82018360208201111561056457600080fd5b8035906020019184602083028401116401000000008311171561058657600080fd5b9193909290916020810190356401000000008111156105a457600080fd5b8201836020820111156105b657600080fd5b803590602001918460208302840111640100000000831117156105d857600080fd5b509092509050610ca9565b610233600480360360208110156105f957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f0e565b6103ec6004803603602081101561062c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f70565b610651610c63565b6106a2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f8484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061105b92505050565b50505050565b61071d610c63565b61076e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610777816112c7565b50565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b60036020526000908152604090205481565b60005481565b60066020526000908152604090205481565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260016020526040812054806107f55750506000546107f8565b90505b919050565b610805610c63565b610856576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166108a85760405162461bcd60e51b81526004018080602001828103825260218152602001806119626021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60016020526000908152604090205481565b61093b610c63565b61098c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077781611382565b60006109a082610f70565b1592915050565b6109af610c63565b610a00576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113bd92505050565b610a75610c63565b610ac6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610b539061159e565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610b939061159e565b90508015610b9f578091505b6000610bb1610bac6115a2565b61159e565b90506000610bc5828563ffffffff6115c616565b90506000610bf369d3c21bcecceda1000000610be78b8563ffffffff61162916565b9063ffffffff61168216565b90506000610c07848763ffffffff6116c416565b90506000610c2969d3c21bcecceda1000000610be78d8563ffffffff61162916565b9050808a1080610c385750828a115b9b9a5050505050505050505050565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610c87611706565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610cb1610c63565b610d02576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b828114610d56576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b83811015610f07576000858583818110610d6f57fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610df5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b828282818110610e0157fe5b9050602002013560066000878785818110610e1857fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fa62a59cb391b90466127d5c2ae9c7cfb59877763680d974867d6abe0c4fd52cb858583818110610ea057fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff16848484818110610ec957fe5b6040805173ffffffffffffffffffffffffffffffffffffffff90951685526020918202939093013590840152508051918290030190a1600101610d59565b5050505050565b610f16610c63565b610f67576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107778161170a565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610fe357600080fd5b505afa158015610ff7573d6000803e3d6000fd5b505050506040513d604081101561100d57600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526006602052604090205490915080611048576000925050506107f8565b611053818386610b35565b949350505050565b80518251146110b1576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff168382815181106110e157fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415611152576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b61115a611907565b61117683838151811061116957fe5b60200260200101516117ea565b90506111906111836115a2565b829063ffffffff61180416565b6111e1576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111f257fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061126e57fe5b602002602001015184848151811061128257fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110b4565b505050565b6112d0816117ea565b516002556112fb6112df6115a2565b604080516020810190915260025481529063ffffffff61180416565b61134c576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b8051825114611413576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff1683828151811061144357fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114b4576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114c057fe5b6020026020010151600160008584815181106114d857fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061154b57fe5b602002602001015183838151811061155f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611416565b5190565b6115aa611907565b50604080516020810190915269d3c21bcecceda1000000815290565b600082820183811015611620576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b60008261163857506000611623565b8282028284828161164557fe5b04146116205760405162461bcd60e51b81526004018080602001828103825260218152602001806119416021913960400191505060405180910390fd5b600061162083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061180b565b600061162083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506118ad565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661175c5760405162461bcd60e51b815260040180806020018281038252602681526020018061191b6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6117f2611907565b50604080516020810190915290815290565b5190511090565b600081836118975760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561185c578181015183820152602001611844565b50505050905090810190601f1680156118895780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816118a357fe5b0495945050505050565b600081848411156118ff5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561185c578181015183820152602001611844565b505050900390565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a7231582011765acba939a6b32e46cb228259748701b284c59dfd4ac49f1e8f56ca5fb53864736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d7573742062652073657400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000fdd8bd58115ffbf04e47411c1d228ecc45e9307500000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "nonce": "0xde" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", + "transactionType": "CALL", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "function": "transferOwnership(address)", + "arguments": [ + "0xAA963FC97281d9632d96700aB62A4D1340F9a28a" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "to": "0x69d7a21025d45d301a396cceffd2d3a80b7c3a5b", + "gas": "0xa387", + "value": "0x0", + "data": "0xf2fde38b000000000000000000000000aa963fc97281d9632d96700ab62a4d1340f9a28a", + "nonce": "0xdf" + }, + "additionalContracts": [], + "isFixedGasLimit": false + } + ], + "receipts": [ + { + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": null, + "cumulativeGasUsed": "0x17e762", + "gasUsed": "0x17e762", + "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "logs": [ + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x0", + "removed": false + }, + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x1", + "removed": false + }, + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f7353" + ], + "data": "0x000000000000000000000000fdd8bd58115ffbf04e47411c1d228ecc45e93075", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x2", + "removed": false + }, + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a2" + ], + "data": "0x0000000000000000000000000000000000000000000000000000000000000000", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x3", + "removed": false + }, + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0xd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d" + ], + "data": "0x0000000000000000000000000000000000000000000000000000000000000000", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x4", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000022800000000000000000080000000000000000000000010000000000001000000000000000000000000000008000000000000000000000000001000000000000000000000000000000800000020000000000000200000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000800000000000000000000008000000000000000000000000000000000000000000000000000000000000000000080000000000000000004000000000000020000004000000000001000000000000000000000000000000000000000020000000", + "type": "0x0", + "effectiveGasPrice": "0x5d21dba00" + }, + { + "transactionHash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", + "transactionIndex": "0x1", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "cumulativeGasUsed": "0x185733", + "gasUsed": "0x6fd1", + "contractAddress": null, + "logs": [ + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", + "0x000000000000000000000000aa963fc97281d9632d96700ab62a4d1340f9a28a" + ], + "data": "0x", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", + "transactionIndex": "0x1", + "logIndex": "0x5", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000020000000000000000000000000000000000020800000000000000000080000004000000000000000010000000000000000000000000000000000000000008000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0x5d21dba00" + } + ], + "libraries": [ + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x2F0F7686fFFEfc3C266403Ad600035581deaedff", + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0x29B1B5e05217c751038861aF2C77494EAB10A257" + ], + "pending": [], + "returns": {}, + "timestamp": 1692783955, + "chain": 44787, + "multi": false, + "commit": "1071d75" +} \ No newline at end of file diff --git a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-latest.json b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-latest.json new file mode 100644 index 00000000..ed40e2ac --- /dev/null +++ b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-latest.json @@ -0,0 +1,180 @@ +{ + "transactions": [ + { + "hash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionType": "CREATE", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "function": null, + "arguments": [ + "0", + "0", + "0xFdd8bD58115FfBf04e47411c1d228eCC45E93075", + "[]", + "[]", + "[]" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "gas": "0x1f2d9a", + "value": "0x0", + "data": "0x60806040523480156200001157600080fd5b506040516200242b3803806200242b833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b5050505090500160405250505085858585858560006200020d620002d660201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620023ea833981519152908290a3506200025e336001600160e01b03620002da16565b62000272846001600160e01b036200036c16565b62000286866001600160e01b036200046c16565b6200029a856001600160e01b03620004a716565b620002af83836001600160e01b036200058516565b620002c483826001600160e01b03620007d316565b505050505050505050505050620009fd565b3390565b6001600160a01b038116620003215760405162461bcd60e51b8152600401808060200182810382526026815260200180620023c46026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620023ea83398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b6200037f6001600160e01b036200097016565b620003d1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b81526004018080602001828103825260218152602001806200240a6021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004bd81620009a160201b620017ea1760201c565b51600255620004fd620004db620009bd602090811b620015a217901c565b6040805160208082019092526002548152919062001804620009e3821b17901c565b6200054f576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005dc576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200060157fe5b60200260200101516001600160a01b031614156200065a576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000664620009ea565b6200068e8383815181106200067557fe5b6020026020010151620009a160201b620017ea1760201c565b9050620006be620006a9620009bd60201b620015a21760201c565b82620009e360201b620018041790919060201c565b62000710576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200072257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200078557fe5b60200260200101518484815181106200079a57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005df565b505050565b80518251146200082a576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200084f57fe5b60200260200101516001600160a01b03161415620008a8576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008b557fe5b602002602001015160016000858481518110620008ce57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200092857fe5b60200260200101518383815181106200093d57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a16001016200082d565b6004546000906001600160a01b0316620009926001600160e01b03620002d616565b6001600160a01b031614905090565b620009ab620009ea565b50604080516020810190915290815290565b620009c7620009ea565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b6119b78062000a0d6000396000f3fe608060405234801561001057600080fd5b506004361061016c5760003560e01c806368b89d58116100cd5780638f32d59b11610081578063e829902e11610066578063e829902e14610521578063f2fde38b146105e3578063fd165f53146106165761016c565b80638f32d59b14610511578063a44235cb146105195761016c565b8063715018a6116100b2578063715018a6146104c2578063753d8c2f146104ca5780638da5cb5b146105095761016c565b806368b89d58146103b95780636cac543a146104005761016c565b80633932bcc3116101245780634afb215e116101095780634afb215e1461033657806353f5d6f1146103695780635ac3ff701461039c5761016c565b80633932bcc3146102d057806339b84ecf146103035761016c565b8063132e8aa711610155578063132e8aa7146102525780631893304f146102835780632e37ff73146102c85761016c565b8063020323dd1461017157806305e0478514610235575b600080fd5b6102336004803603604081101561018757600080fd5b8101906020810181356401000000008111156101a257600080fd5b8201836020820111156101b457600080fd5b803590602001918460208302840111640100000000831117156101d657600080fd5b9193909290916020810190356401000000008111156101f457600080fd5b82018360208201111561020657600080fd5b8035906020019184602083028401116401000000008311171561022857600080fd5b509092509050610649565b005b6102336004803603602081101561024b57600080fd5b5035610715565b61025a61077a565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6102b66004803603602081101561029957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610796565b60408051918252519081900360200190f35b6102b66107a8565b6102b6600480360360208110156102e657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107ae565b6102b66004803603602081101561031957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107c0565b6102336004803603602081101561034c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107fd565b6102b66004803603602081101561037f57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610921565b610233600480360360208110156103b257600080fd5b5035610933565b6103ec600480360360208110156103cf57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610995565b604080519115158252519081900360200190f35b6102336004803603604081101561041657600080fd5b81019060208101813564010000000081111561043157600080fd5b82018360208201111561044357600080fd5b8035906020019184602083028401116401000000008311171561046557600080fd5b91939092909160208101903564010000000081111561048357600080fd5b82018360208201111561049557600080fd5b803590602001918460208302840111640100000000831117156104b757600080fd5b5090925090506109a7565b610233610a6d565b6103ec600480360360608110156104e057600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610b35565b61025a610c47565b6103ec610c63565b6102b6610ca3565b6102336004803603604081101561053757600080fd5b81019060208101813564010000000081111561055257600080fd5b82018360208201111561056457600080fd5b8035906020019184602083028401116401000000008311171561058657600080fd5b9193909290916020810190356401000000008111156105a457600080fd5b8201836020820111156105b657600080fd5b803590602001918460208302840111640100000000831117156105d857600080fd5b509092509050610ca9565b610233600480360360208110156105f957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f0e565b6103ec6004803603602081101561062c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f70565b610651610c63565b6106a2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f8484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061105b92505050565b50505050565b61071d610c63565b61076e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610777816112c7565b50565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b60036020526000908152604090205481565b60005481565b60066020526000908152604090205481565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260016020526040812054806107f55750506000546107f8565b90505b919050565b610805610c63565b610856576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166108a85760405162461bcd60e51b81526004018080602001828103825260218152602001806119626021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60016020526000908152604090205481565b61093b610c63565b61098c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077781611382565b60006109a082610f70565b1592915050565b6109af610c63565b610a00576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113bd92505050565b610a75610c63565b610ac6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610b539061159e565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610b939061159e565b90508015610b9f578091505b6000610bb1610bac6115a2565b61159e565b90506000610bc5828563ffffffff6115c616565b90506000610bf369d3c21bcecceda1000000610be78b8563ffffffff61162916565b9063ffffffff61168216565b90506000610c07848763ffffffff6116c416565b90506000610c2969d3c21bcecceda1000000610be78d8563ffffffff61162916565b9050808a1080610c385750828a115b9b9a5050505050505050505050565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610c87611706565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610cb1610c63565b610d02576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b828114610d56576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b83811015610f07576000858583818110610d6f57fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610df5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b828282818110610e0157fe5b9050602002013560066000878785818110610e1857fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fa62a59cb391b90466127d5c2ae9c7cfb59877763680d974867d6abe0c4fd52cb858583818110610ea057fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff16848484818110610ec957fe5b6040805173ffffffffffffffffffffffffffffffffffffffff90951685526020918202939093013590840152508051918290030190a1600101610d59565b5050505050565b610f16610c63565b610f67576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107778161170a565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610fe357600080fd5b505afa158015610ff7573d6000803e3d6000fd5b505050506040513d604081101561100d57600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526006602052604090205490915080611048576000925050506107f8565b611053818386610b35565b949350505050565b80518251146110b1576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff168382815181106110e157fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415611152576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b61115a611907565b61117683838151811061116957fe5b60200260200101516117ea565b90506111906111836115a2565b829063ffffffff61180416565b6111e1576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111f257fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061126e57fe5b602002602001015184848151811061128257fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110b4565b505050565b6112d0816117ea565b516002556112fb6112df6115a2565b604080516020810190915260025481529063ffffffff61180416565b61134c576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b8051825114611413576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff1683828151811061144357fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114b4576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114c057fe5b6020026020010151600160008584815181106114d857fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061154b57fe5b602002602001015183838151811061155f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611416565b5190565b6115aa611907565b50604080516020810190915269d3c21bcecceda1000000815290565b600082820183811015611620576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b60008261163857506000611623565b8282028284828161164557fe5b04146116205760405162461bcd60e51b81526004018080602001828103825260218152602001806119416021913960400191505060405180910390fd5b600061162083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061180b565b600061162083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506118ad565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661175c5760405162461bcd60e51b815260040180806020018281038252602681526020018061191b6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6117f2611907565b50604080516020810190915290815290565b5190511090565b600081836118975760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561185c578181015183820152602001611844565b50505050905090810190601f1680156118895780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816118a357fe5b0495945050505050565b600081848411156118ff5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561185c578181015183820152602001611844565b505050900390565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a7231582011765acba939a6b32e46cb228259748701b284c59dfd4ac49f1e8f56ca5fb53864736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d7573742062652073657400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000fdd8bd58115ffbf04e47411c1d228ecc45e9307500000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "nonce": "0xde" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", + "transactionType": "CALL", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "function": "transferOwnership(address)", + "arguments": [ + "0xAA963FC97281d9632d96700aB62A4D1340F9a28a" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "to": "0x69d7a21025d45d301a396cceffd2d3a80b7c3a5b", + "gas": "0xa387", + "value": "0x0", + "data": "0xf2fde38b000000000000000000000000aa963fc97281d9632d96700ab62a4d1340f9a28a", + "nonce": "0xdf" + }, + "additionalContracts": [], + "isFixedGasLimit": false + } + ], + "receipts": [ + { + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": null, + "cumulativeGasUsed": "0x17e762", + "gasUsed": "0x17e762", + "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "logs": [ + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x0", + "removed": false + }, + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x1", + "removed": false + }, + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f7353" + ], + "data": "0x000000000000000000000000fdd8bd58115ffbf04e47411c1d228ecc45e93075", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x2", + "removed": false + }, + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a2" + ], + "data": "0x0000000000000000000000000000000000000000000000000000000000000000", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x3", + "removed": false + }, + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0xd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d" + ], + "data": "0x0000000000000000000000000000000000000000000000000000000000000000", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", + "transactionIndex": "0x0", + "logIndex": "0x4", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000022800000000000000000080000000000000000000000010000000000001000000000000000000000000000008000000000000000000000000001000000000000000000000000000000800000020000000000000200000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000800000000000000000000008000000000000000000000000000000000000000000000000000000000000000000080000000000000000004000000000000020000004000000000001000000000000000000000000000000000000000020000000", + "type": "0x0", + "effectiveGasPrice": "0x5d21dba00" + }, + { + "transactionHash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", + "transactionIndex": "0x1", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "cumulativeGasUsed": "0x185733", + "gasUsed": "0x6fd1", + "contractAddress": null, + "logs": [ + { + "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", + "0x000000000000000000000000aa963fc97281d9632d96700ab62a4d1340f9a28a" + ], + "data": "0x", + "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", + "blockNumber": "0x1293e7b", + "transactionHash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", + "transactionIndex": "0x1", + "logIndex": "0x5", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000020000000000000000000000000000000000020800000000000000000080000004000000000000000010000000000000000000000000000000000000000008000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0x5d21dba00" + } + ], + "libraries": [ + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x2F0F7686fFFEfc3C266403Ad600035581deaedff", + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0x29B1B5e05217c751038861aF2C77494EAB10A257" + ], + "pending": [], + "returns": {}, + "timestamp": 1692783955, + "chain": 44787, + "multi": false, + "commit": "1071d75" +} \ No newline at end of file diff --git a/script/upgrades/dependencies.json b/script/upgrades/dependencies.json index e385e357..0b9582dd 100644 --- a/script/upgrades/dependencies.json +++ b/script/upgrades/dependencies.json @@ -8,6 +8,7 @@ }, "62320": { "BridgedUSDC": "0xD4079B322c392D6b196f90AA4c439fC2C16d6770", + "BridgedEUROC": "0xD4079B322c392D6b196f90AA4c439fC2C16d6770", "USDCUSDRateFeedAddr": "0xA1A8003936862E7a15092A91898D69fa8bCE290c", "USDCEURRateFeedAddr": "0x206B25Ea01E188Ee243131aFdE526bA6E131a016", "USDCBRLRateFeedAddr": "0x25F21A1f97607Edf6852339fad709728cffb9a9d", @@ -15,6 +16,7 @@ }, "44787": { "BridgedUSDC": "0x87D61dA3d668797786D73BC674F053f87111570d", + "BridgedEUROC": "0x87D61dA3d668797786D73BC674F053f87111570d", "USDCUSDRateFeedAddr": "0xA1A8003936862E7a15092A91898D69fa8bCE290c", "USDCEURRateFeedAddr": "0x206B25Ea01E188Ee243131aFdE526bA6E131a016", "USDCBRLRateFeedAddr": "0x25F21A1f97607Edf6852339fad709728cffb9a9d", diff --git a/script/upgrades/MU04/Config.sol b/script/upgrades/eXOF/Config.sol similarity index 98% rename from script/upgrades/MU04/Config.sol rename to script/upgrades/eXOF/Config.sol index 532a76f7..2be98f6f 100644 --- a/script/upgrades/MU04/Config.sol +++ b/script/upgrades/eXOF/Config.sol @@ -9,11 +9,11 @@ import { Contracts } from "script/utils/Contracts.sol"; import { Arrays } from "script/utils/Arrays.sol"; import { FixidityLib } from "script/utils/FixidityLib.sol"; -library MU04Config { +library eXOFConfig { using FixidityLib for FixidityLib.Fraction; using Contracts for Contracts.Cache; - struct MU04 { + struct eXOF { Config.Pool eXOFCelo; Config.Pool eXOFEUROC; Config.Pool[] pools; @@ -23,7 +23,7 @@ library MU04Config { Config.StableToken stableTokenXOF; } - function get(Contracts.Cache storage contracts) internal returns (MU04 memory config) { + function get(Contracts.Cache storage contracts) internal returns (eXOF memory config) { config.pools = new Config.Pool[](2); config.pools[0] = config.eXOFCelo = eXOFCelo_PoolConfig(contracts); config.pools[1] = config.eXOFEUROC = eXOFEUROC_PoolConfig(contracts); diff --git a/script/upgrades/MU04/deploy/MU04-00-Create-Proxies.sol b/script/upgrades/eXOF/deploy/eXOF-00-Create-Proxies.sol similarity index 89% rename from script/upgrades/MU04/deploy/MU04-00-Create-Proxies.sol rename to script/upgrades/eXOF/deploy/eXOF-00-Create-Proxies.sol index 580b28a3..a0b0edcb 100644 --- a/script/upgrades/MU04/deploy/MU04-00-Create-Proxies.sol +++ b/script/upgrades/eXOF/deploy/eXOF-00-Create-Proxies.sol @@ -8,9 +8,9 @@ import { console2 } from "forge-std/Script.sol"; import { StableTokenXOFProxy } from "mento-core-2.2.0/legacy/proxies/StableTokenXOFProxy.sol"; /* - yarn deploy -n -u MU04 -s MU04-00-Create-Proxies.sol + yarn deploy -n -u eXOF -s eXOF-00-Create-Proxies.sol */ -contract MU04_CreateProxies is Script { +contract eXOF_CreateProxies is Script { function run() public { address payable stableTokenXOFProxy; address governance = contracts.celoRegistry("Governance"); diff --git a/script/upgrades/MU04/deploy/MU04-01-Create-Implementations.sol b/script/upgrades/eXOF/deploy/eXOF-01-Create-Implementations.sol similarity index 88% rename from script/upgrades/MU04/deploy/MU04-01-Create-Implementations.sol rename to script/upgrades/eXOF/deploy/eXOF-01-Create-Implementations.sol index abd3b6b5..f37d7c60 100644 --- a/script/upgrades/MU04/deploy/MU04-01-Create-Implementations.sol +++ b/script/upgrades/eXOF/deploy/eXOF-01-Create-Implementations.sol @@ -8,9 +8,9 @@ import { console2 } from "forge-std/Script.sol"; import { StableTokenXOF } from "mento-core-2.2.0/legacy/StableTokenXOF.sol"; /* - yarn deploy -n -u MU04 -s MU04-01-Create-Implementations.sol + yarn deploy -n -u eXOF -s eXOF-01-Create-Implementations.sol */ -contract MU01_CreateImplementations is Script { +contract eXOF_CreateImplementations is Script { function run() public { address stableTokenXOF; address governance = contracts.celoRegistry("Governance"); diff --git a/script/upgrades/MU04/deploy/MU04-02-Create-Nonupgradeable-Contracts.sol b/script/upgrades/eXOF/deploy/eXOF-02-Create-Nonupgradeable-Contracts.sol similarity index 93% rename from script/upgrades/MU04/deploy/MU04-02-Create-Nonupgradeable-Contracts.sol rename to script/upgrades/eXOF/deploy/eXOF-02-Create-Nonupgradeable-Contracts.sol index a40c13e9..8e8eeaa6 100644 --- a/script/upgrades/MU04/deploy/MU04-02-Create-Nonupgradeable-Contracts.sol +++ b/script/upgrades/eXOF/deploy/eXOF-02-Create-Nonupgradeable-Contracts.sol @@ -9,9 +9,9 @@ import { ISortedOracles } from "mento-core-2.2.0/interfaces/ISortedOracles.sol"; import { NonrecoverableValueDeltaBreaker } from "contracts/NonrecoverableValueDeltaBreaker.sol"; /* - yarn deploy -n -u MU04 -s MU04-02-Create-Nonupgradeable-Contracts.sol + yarn deploy -n -u eXOF -s eXOF-02-Create-Nonupgradeable-Contracts.sol */ -contract MU04_CreateNonupgradeableContracts is Script { +contract eXOF_CreateNonupgradeableContracts is Script { NonrecoverableValueDeltaBreaker private nonrecoverableValueDeltaBreaker; function run() public { diff --git a/script/upgrades/MU04/MU04.sol b/script/upgrades/eXOF/eXOF.sol similarity index 95% rename from script/upgrades/MU04/MU04.sol rename to script/upgrades/eXOF/eXOF.sol index b26efd40..3b8104c3 100644 --- a/script/upgrades/MU04/MU04.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -31,7 +31,7 @@ import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; import { StableTokenXOF } from "mento-core-2.2.0/legacy/StableTokenXOF.sol"; import { StableTokenXOFProxy } from "mento-core-2.2.0/legacy/proxies/StableTokenXOFProxy.sol"; -import { MU04Config, Config } from "./Config.sol"; +import { eXOFConfig, Config } from "./Config.sol"; import { IMentoUpgrade, ICeloGovernance } from "script/interfaces/IMentoUpgrade.sol"; /** @@ -39,7 +39,7 @@ import { IMentoUpgrade, ICeloGovernance } from "script/interfaces/IMentoUpgrade. --broadcast --legacy * @dev depends on: ../deploy/*.sol */ -contract MU04 is IMentoUpgrade, GovernanceScript { +contract eXOF is IMentoUpgrade, GovernanceScript { using TradingLimits for TradingLimits.Config; using FixidityLib for FixidityLib.Fraction; @@ -76,9 +76,9 @@ contract MU04 is IMentoUpgrade, GovernanceScript { contracts.load("MU01-01-Create-Nonupgradeable-Contracts", "latest"); contracts.load("MU03-01-Create-Nonupgradeable-Contracts", "latest"); contracts.load("MU03-02-Create-Implementations", "latest"); - contracts.load("MU04-00-Create-Proxies", "latest"); - contracts.load("MU04-01-Create-Implementations", "latest"); - contracts.load("MU04-02-Create-Nonupgradeable-Contracts", "latest"); + contracts.load("eXOF-00-Create-Proxies", "latest"); + contracts.load("eXOF-01-Create-Implementations", "latest"); + contracts.load("eXOF-02-Create-Nonupgradeable-Contracts", "latest"); } /** @@ -104,7 +104,7 @@ contract MU04 is IMentoUpgrade, GovernanceScript { */ function setUpConfigs() public { // Create pool configurations - MU04Config.MU04 memory config = MU04Config.get(contracts); + eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); // Set the exchange ID for the reference rate feed for (uint i = 0; i < config.pools.length; i++) { @@ -123,14 +123,14 @@ contract MU04 is IMentoUpgrade, GovernanceScript { vm.startBroadcast(Chain.deployerPrivateKey()); { - createProposal(_transactions, "MU04", governance); + createProposal(_transactions, "eXOF", governance); } vm.stopBroadcast(); } function buildProposal() public returns (ICeloGovernance.Transaction[] memory) { require(transactions.length == 0, "buildProposal() should only be called once"); - MU04Config.MU04 memory config = MU04Config.get(contracts); + eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); proposal_initializeEXOFToken(config); proposal_addEXOFToReserves(); @@ -147,7 +147,7 @@ contract MU04 is IMentoUpgrade, GovernanceScript { /** * @notice Configures the eXOF token */ - function proposal_initializeEXOFToken(MU04Config.MU04 memory config) private { + function proposal_initializeEXOFToken(eXOFConfig.eXOF memory config) private { StableTokenXOFProxy _eXOFProxy = StableTokenXOFProxy(eXOFProxy); if (_eXOFProxy._getImplementation() == address(0)) { transactions.push( @@ -255,7 +255,7 @@ contract MU04 is IMentoUpgrade, GovernanceScript { /** * @notice Creates the exchanges for the new pools. */ - function proposal_createExchanges(MU04Config.MU04 memory config) private { + function proposal_createExchanges(eXOFConfig.eXOF memory config) private { // Get the address of the pricing modules IPricingModule constantProduct = IPricingModule(contracts.deployed("ConstantProductPricingModule")); IPricingModule constantSum = IPricingModule(contracts.deployed("ConstantSumPricingModule")); @@ -291,7 +291,7 @@ contract MU04 is IMentoUpgrade, GovernanceScript { /** * @notice This function creates the transactions to configure the trading limits. */ - function proposal_configureTradingLimits(MU04Config.MU04 memory config) private { + function proposal_configureTradingLimits(eXOFConfig.eXOF memory config) private { address brokerProxyAddress = contracts.deployed("BrokerProxy"); for (uint256 i = 0; i < config.pools.length; i++) { Config.Pool memory poolConfig = config.pools[i]; @@ -347,7 +347,7 @@ contract MU04 is IMentoUpgrade, GovernanceScript { /** * @notice This function creates the transactions to configure the Breakerbox. */ - function proposal_configureBreakerBox(MU04Config.MU04 memory config) private { + function proposal_configureBreakerBox(eXOFConfig.eXOF memory config) private { // Add the new rate feeds to breaker box transactions.push( ICeloGovernance.Transaction( @@ -434,7 +434,7 @@ contract MU04 is IMentoUpgrade, GovernanceScript { /** * @notice This function creates the transactions to configure the Median Delta Breaker. */ - function proposal_configureMedianDeltaBreakers(MU04Config.MU04 memory config) private { + function proposal_configureMedianDeltaBreakers(eXOFConfig.eXOF memory config) private { // Set the cooldown time transactions.push( ICeloGovernance.Transaction( @@ -476,7 +476,7 @@ contract MU04 is IMentoUpgrade, GovernanceScript { /** * @notice This function creates the transactions to configure the recoverable Value Delta Breaker . */ - function proposal_configureValueDeltaBreaker(MU04Config.MU04 memory config) private { + function proposal_configureValueDeltaBreaker(eXOFConfig.eXOF memory config) private { // Set the cooldown times transactions.push( ICeloGovernance.Transaction( @@ -518,7 +518,7 @@ contract MU04 is IMentoUpgrade, GovernanceScript { /** * @notice This function creates the transactions to configure the second Value Delta Breaker . */ - function proposal_configureNonrecoverableValueDeltaBreaker(MU04Config.MU04 memory config) private { + function proposal_configureNonrecoverableValueDeltaBreaker(eXOFConfig.eXOF memory config) private { // Set the cooldown times transactions.push( ICeloGovernance.Transaction( diff --git a/script/upgrades/MU04/MU04Checks.sol b/script/upgrades/eXOF/eXOFChecks.sol similarity index 95% rename from script/upgrades/MU04/MU04Checks.sol rename to script/upgrades/eXOF/eXOFChecks.sol index 6db9c27d..f88f2f4b 100644 --- a/script/upgrades/MU04/MU04Checks.sol +++ b/script/upgrades/eXOF/eXOFChecks.sol @@ -34,7 +34,7 @@ import { Proxy } from "mento-core-2.2.0/common/Proxy.sol"; import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; -import { MU04Config, Config } from "./Config.sol"; +import { eXOFConfig, Config } from "./Config.sol"; /** * @title IBrokerWithCasts @@ -46,7 +46,7 @@ interface IBrokerWithCasts { function tradingLimitsConfig(bytes32 id) external view returns (TradingLimits.Config memory); } -contract MU04Checks is Script, Test { +contract eXOFChecks is Script, Test { using TradingLimits for TradingLimits.Config; using FixidityLib for FixidityLib.Fraction; using SafeMath for uint256; @@ -79,9 +79,9 @@ contract MU04Checks is Script, Test { contracts.load("MU01-01-Create-Nonupgradeable-Contracts", "latest"); contracts.load("MU03-01-Create-Nonupgradeable-Contracts", "latest"); contracts.load("MU03-02-Create-Implementations", "latest"); - contracts.load("MU04-00-Create-Proxies", "latest"); - contracts.load("MU04-01-Create-Implementations", "latest"); - contracts.load("MU04-02-Create-Nonupgradeable-Contracts", "latest"); + contracts.load("eXOF-00-Create-Proxies", "latest"); + contracts.load("eXOF-01-Create-Implementations", "latest"); + contracts.load("eXOF-02-Create-Nonupgradeable-Contracts", "latest"); // Get proxy addresses eXOF = address(uint160(contracts.celoRegistry("StableTokenXOF"))); @@ -150,7 +150,7 @@ contract MU04Checks is Script, Test { /* ================================================================ */ function verifyExchanges() internal { - MU04Config.MU04 memory config = MU04Config.get(contracts); + eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); console.log("== Verifying exchanges... =="); @@ -159,7 +159,7 @@ contract MU04Checks is Script, Test { verifyTradingLimits(config); } - function verifyPoolExchange(MU04Config.MU04 memory config) internal view { + function verifyPoolExchange(eXOFConfig.eXOF memory config) internal view { bytes32[] memory exchanges = BiPoolManager(biPoolManagerProxy).getExchangeIds(); // check configured pools against the config @@ -227,7 +227,7 @@ contract MU04Checks is Script, Test { console.log("\tPoolExchange correctly configured 🤘🏼"); } - function verifyPoolConfig(MU04Config.MU04 memory config) internal view { + function verifyPoolConfig(eXOFConfig.eXOF memory config) internal view { for (uint256 i = 0; i < config.pools.length; i++) { bytes32 exchangeId = getExchangeId(config.pools[i].asset0, config.pools[i].asset1, config.pools[i].isConstantSum); IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeId); @@ -283,7 +283,7 @@ contract MU04Checks is Script, Test { console.log("\tPool config is correctly configured 🤘🏼"); } - function verifyTradingLimits(MU04Config.MU04 memory config) internal view { + function verifyTradingLimits(eXOFConfig.eXOF memory config) internal view { IBrokerWithCasts _broker = IBrokerWithCasts(address(broker)); for (uint256 i = 0; i < config.pools.length; i++) { @@ -328,7 +328,7 @@ contract MU04Checks is Script, Test { /* ================================================================ */ function verifyCircuitBreaker() internal { - MU04Config.MU04 memory config = MU04Config.get(contracts); + eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); console.log("\n== Checking circuit breaker... =="); @@ -338,7 +338,7 @@ contract MU04Checks is Script, Test { verifyValueDeltaBreaker(config); } - function verifyBreakerBox(MU04Config.MU04 memory config) internal view { + function verifyBreakerBox(eXOFConfig.eXOF memory config) internal view { // verify that breakers were set with trading mode 3 if (BreakerBox(breakerBox).breakerTradingMode(nonrecoverableValueDeltaBreaker) != 3) { console.log("The Nonrecoverable ValueDeltaBreaker was not set with trading halted ❌"); @@ -355,7 +355,7 @@ contract MU04Checks is Script, Test { console.log("\tRate feed dependencies configured correctly 🗳️"); } - function verifyBreakersAreEnabled(MU04Config.MU04 memory config) internal view { + function verifyBreakersAreEnabled(eXOFConfig.eXOF memory config) internal view { // verify that MedianDeltaBreaker && ValueDeltaBreakers were enabled for rateFeeds for (uint256 i = 0; i < config.rateFeeds.length; i++) { Config.RateFeed memory rateFeed = config.rateFeeds[i]; @@ -390,7 +390,7 @@ contract MU04Checks is Script, Test { console.log("\tBreakers enabled for all rate feeds 🗳️"); } - function verifyMedianDeltaBreaker(MU04Config.MU04 memory config) internal view { + function verifyMedianDeltaBreaker(eXOFConfig.eXOF memory config) internal view { // verify that cooldown period, rate change threshold and smoothing factor were set correctly for (uint256 i = 0; i < config.rateFeeds.length; i++) { Config.RateFeed memory rateFeed = config.rateFeeds[i]; @@ -424,7 +424,7 @@ contract MU04Checks is Script, Test { console.log("\tMedianDeltaBreaker cooldown, rate change threshold and smoothing factor set correctly 🔒"); } - function verifyValueDeltaBreaker(MU04Config.MU04 memory config) internal view { + function verifyValueDeltaBreaker(eXOFConfig.eXOF memory config) internal view { // verify that cooldown period, rate change threshold and reference value were set correctly for (uint256 i = 0; i < config.rateFeeds.length; i++) { Config.RateFeed memory rateFeed = config.rateFeeds[i]; @@ -455,7 +455,7 @@ contract MU04Checks is Script, Test { console.log("\tValueDeltaBreaker cooldown, rate change threshold and reference value set correctly 🔒"); } - function verifyNonrecoverableValueDeltaBreaker(MU04Config.MU04 memory config) internal view { + function verifyNonrecoverableValueDeltaBreaker(eXOFConfig.eXOF memory config) internal view { // verify that cooldown period, rate change threshold and reference value were set correctly for (uint256 i = 0; i < config.rateFeeds.length; i++) { Config.RateFeed memory rateFeed = config.rateFeeds[i]; @@ -499,7 +499,7 @@ contract MU04Checks is Script, Test { // /* ============================= Swaps ============================ */ // /* ================================================================ */ function doSwaps() internal { - MU04Config.MU04 memory config = MU04Config.get(contracts); + eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); console.log("\n== Doing some test swaps... =="); @@ -509,7 +509,7 @@ contract MU04Checks is Script, Test { swapEXOFtoBridgedEUROC(config); } - function swapCeloToEXOF(MU04Config.MU04 memory config) internal { + function swapCeloToEXOF(eXOFConfig.eXOF memory config) internal { bytes32 exchangeID = getExchangeId(config.eXOFCelo.asset0, config.eXOFCelo.asset1, config.eXOFCelo.isConstantSum); address trader = vm.addr(5); @@ -525,7 +525,7 @@ contract MU04Checks is Script, Test { console.log("\tCELO -> eXOF swap successful 🚀"); } - function swapEXOFtoCelo(MU04Config.MU04 memory config) internal { + function swapEXOFtoCelo(eXOFConfig.eXOF memory config) internal { bytes32 exchangeID = getExchangeId(config.eXOFCelo.asset0, config.eXOFCelo.asset1, config.eXOFCelo.isConstantSum); address trader = vm.addr(5); @@ -538,7 +538,7 @@ contract MU04Checks is Script, Test { console.log("\teXOF -> CELO swap successful 🚀"); } - function swapBridgedEUROCtoEXOF(MU04Config.MU04 memory config) internal { + function swapBridgedEUROCtoEXOF(eXOFConfig.eXOF memory config) internal { bytes32 exchangeID = getExchangeId( config.eXOFEUROC.asset0, config.eXOFEUROC.asset1, @@ -566,7 +566,7 @@ contract MU04Checks is Script, Test { console.log("\tbridgedEUROC -> eXOF swap successful 🚀"); } - function swapEXOFtoBridgedEUROC(MU04Config.MU04 memory config) internal { + function swapEXOFtoBridgedEUROC(eXOFConfig.eXOF memory config) internal { bytes32 exchangeID = getExchangeId( config.eXOFEUROC.asset0, config.eXOFEUROC.asset1, From 6a28e304b6a116e3220f406630882415b038a079 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Wed, 23 Aug 2023 15:56:27 -0500 Subject: [PATCH 06/64] chore: deploy non upgradeables to baklava --- .../62320/run-1692821205.json | 64 +++++++ .../62320/run-1692821211.json | 180 ++++++++++++++++++ .../62320/run-1692821216.json | 180 ++++++++++++++++++ .../62320/run-latest.json | 180 ++++++++++++++++++ 4 files changed, 604 insertions(+) create mode 100644 broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821205.json create mode 100644 broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821211.json create mode 100644 broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821216.json create mode 100644 broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-latest.json diff --git a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821205.json b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821205.json new file mode 100644 index 00000000..5b177f77 --- /dev/null +++ b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821205.json @@ -0,0 +1,64 @@ +{ + "transactions": [ + { + "hash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionType": "CREATE", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "function": null, + "arguments": [ + "0", + "0", + "0x88A187a876290E9843175027902B9f7f1B092c88", + "[]", + "[]", + "[]" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "gas": "0x1f2d9a", + "value": "0x0", + "data": "0x60806040523480156200001157600080fd5b506040516200242b3803806200242b833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b5050505090500160405250505085858585858560006200020d620002d660201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620023ea833981519152908290a3506200025e336001600160e01b03620002da16565b62000272846001600160e01b036200036c16565b62000286866001600160e01b036200046c16565b6200029a856001600160e01b03620004a716565b620002af83836001600160e01b036200058516565b620002c483826001600160e01b03620007d316565b505050505050505050505050620009fd565b3390565b6001600160a01b038116620003215760405162461bcd60e51b8152600401808060200182810382526026815260200180620023c46026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620023ea83398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b6200037f6001600160e01b036200097016565b620003d1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b81526004018080602001828103825260218152602001806200240a6021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004bd81620009a160201b620017ea1760201c565b51600255620004fd620004db620009bd602090811b620015a217901c565b6040805160208082019092526002548152919062001804620009e3821b17901c565b6200054f576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005dc576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200060157fe5b60200260200101516001600160a01b031614156200065a576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000664620009ea565b6200068e8383815181106200067557fe5b6020026020010151620009a160201b620017ea1760201c565b9050620006be620006a9620009bd60201b620015a21760201c565b82620009e360201b620018041790919060201c565b62000710576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200072257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200078557fe5b60200260200101518484815181106200079a57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005df565b505050565b80518251146200082a576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200084f57fe5b60200260200101516001600160a01b03161415620008a8576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008b557fe5b602002602001015160016000858481518110620008ce57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200092857fe5b60200260200101518383815181106200093d57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a16001016200082d565b6004546000906001600160a01b0316620009926001600160e01b03620002d616565b6001600160a01b031614905090565b620009ab620009ea565b50604080516020810190915290815290565b620009c7620009ea565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b6119b78062000a0d6000396000f3fe608060405234801561001057600080fd5b506004361061016c5760003560e01c806368b89d58116100cd5780638f32d59b11610081578063e829902e11610066578063e829902e14610521578063f2fde38b146105e3578063fd165f53146106165761016c565b80638f32d59b14610511578063a44235cb146105195761016c565b8063715018a6116100b2578063715018a6146104c2578063753d8c2f146104ca5780638da5cb5b146105095761016c565b806368b89d58146103b95780636cac543a146104005761016c565b80633932bcc3116101245780634afb215e116101095780634afb215e1461033657806353f5d6f1146103695780635ac3ff701461039c5761016c565b80633932bcc3146102d057806339b84ecf146103035761016c565b8063132e8aa711610155578063132e8aa7146102525780631893304f146102835780632e37ff73146102c85761016c565b8063020323dd1461017157806305e0478514610235575b600080fd5b6102336004803603604081101561018757600080fd5b8101906020810181356401000000008111156101a257600080fd5b8201836020820111156101b457600080fd5b803590602001918460208302840111640100000000831117156101d657600080fd5b9193909290916020810190356401000000008111156101f457600080fd5b82018360208201111561020657600080fd5b8035906020019184602083028401116401000000008311171561022857600080fd5b509092509050610649565b005b6102336004803603602081101561024b57600080fd5b5035610715565b61025a61077a565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6102b66004803603602081101561029957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610796565b60408051918252519081900360200190f35b6102b66107a8565b6102b6600480360360208110156102e657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107ae565b6102b66004803603602081101561031957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107c0565b6102336004803603602081101561034c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107fd565b6102b66004803603602081101561037f57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610921565b610233600480360360208110156103b257600080fd5b5035610933565b6103ec600480360360208110156103cf57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610995565b604080519115158252519081900360200190f35b6102336004803603604081101561041657600080fd5b81019060208101813564010000000081111561043157600080fd5b82018360208201111561044357600080fd5b8035906020019184602083028401116401000000008311171561046557600080fd5b91939092909160208101903564010000000081111561048357600080fd5b82018360208201111561049557600080fd5b803590602001918460208302840111640100000000831117156104b757600080fd5b5090925090506109a7565b610233610a6d565b6103ec600480360360608110156104e057600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610b35565b61025a610c47565b6103ec610c63565b6102b6610ca3565b6102336004803603604081101561053757600080fd5b81019060208101813564010000000081111561055257600080fd5b82018360208201111561056457600080fd5b8035906020019184602083028401116401000000008311171561058657600080fd5b9193909290916020810190356401000000008111156105a457600080fd5b8201836020820111156105b657600080fd5b803590602001918460208302840111640100000000831117156105d857600080fd5b509092509050610ca9565b610233600480360360208110156105f957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f0e565b6103ec6004803603602081101561062c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f70565b610651610c63565b6106a2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f8484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061105b92505050565b50505050565b61071d610c63565b61076e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610777816112c7565b50565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b60036020526000908152604090205481565b60005481565b60066020526000908152604090205481565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260016020526040812054806107f55750506000546107f8565b90505b919050565b610805610c63565b610856576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166108a85760405162461bcd60e51b81526004018080602001828103825260218152602001806119626021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60016020526000908152604090205481565b61093b610c63565b61098c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077781611382565b60006109a082610f70565b1592915050565b6109af610c63565b610a00576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113bd92505050565b610a75610c63565b610ac6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610b539061159e565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610b939061159e565b90508015610b9f578091505b6000610bb1610bac6115a2565b61159e565b90506000610bc5828563ffffffff6115c616565b90506000610bf369d3c21bcecceda1000000610be78b8563ffffffff61162916565b9063ffffffff61168216565b90506000610c07848763ffffffff6116c416565b90506000610c2969d3c21bcecceda1000000610be78d8563ffffffff61162916565b9050808a1080610c385750828a115b9b9a5050505050505050505050565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610c87611706565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610cb1610c63565b610d02576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b828114610d56576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b83811015610f07576000858583818110610d6f57fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610df5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b828282818110610e0157fe5b9050602002013560066000878785818110610e1857fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fa62a59cb391b90466127d5c2ae9c7cfb59877763680d974867d6abe0c4fd52cb858583818110610ea057fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff16848484818110610ec957fe5b6040805173ffffffffffffffffffffffffffffffffffffffff90951685526020918202939093013590840152508051918290030190a1600101610d59565b5050505050565b610f16610c63565b610f67576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107778161170a565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610fe357600080fd5b505afa158015610ff7573d6000803e3d6000fd5b505050506040513d604081101561100d57600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526006602052604090205490915080611048576000925050506107f8565b611053818386610b35565b949350505050565b80518251146110b1576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff168382815181106110e157fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415611152576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b61115a611907565b61117683838151811061116957fe5b60200260200101516117ea565b90506111906111836115a2565b829063ffffffff61180416565b6111e1576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111f257fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061126e57fe5b602002602001015184848151811061128257fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110b4565b505050565b6112d0816117ea565b516002556112fb6112df6115a2565b604080516020810190915260025481529063ffffffff61180416565b61134c576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b8051825114611413576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff1683828151811061144357fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114b4576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114c057fe5b6020026020010151600160008584815181106114d857fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061154b57fe5b602002602001015183838151811061155f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611416565b5190565b6115aa611907565b50604080516020810190915269d3c21bcecceda1000000815290565b600082820183811015611620576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b60008261163857506000611623565b8282028284828161164557fe5b04146116205760405162461bcd60e51b81526004018080602001828103825260218152602001806119416021913960400191505060405180910390fd5b600061162083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061180b565b600061162083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506118ad565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661175c5760405162461bcd60e51b815260040180806020018281038252602681526020018061191b6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6117f2611907565b50604080516020810190915290815290565b5190511090565b600081836118975760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561185c578181015183820152602001611844565b50505050905090810190601f1680156118895780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816118a357fe5b0495945050505050565b600081848411156118ff5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561185c578181015183820152602001611844565b505050900390565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a723158202de52c133daa5165b485b36d57f3f0ee8f32fe21677670bf73fc60225c1d889a64736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d757374206265207365740000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000088a187a876290e9843175027902b9f7f1b092c8800000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "nonce": "0x289" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", + "transactionType": "CALL", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "function": "transferOwnership(address)", + "arguments": [ + "0x28443b1d87db521320a6517A4F1B6Ead77F8C811" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "to": "0xcf49ddc026a66cbd5312a46eada3176d40b245e5", + "gas": "0xa387", + "value": "0x0", + "data": "0xf2fde38b00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811", + "nonce": "0x28a" + }, + "additionalContracts": [], + "isFixedGasLimit": false + } + ], + "receipts": [], + "libraries": [ + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x3e2cc57f83093Ce1Ee03482c1590E3B5f4225bd7", + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0x99EDce8143FF8AeFA1fBB6C2103B349Add2B9519" + ], + "pending": [ + "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168" + ], + "returns": {}, + "timestamp": 1692821205, + "chain": 62320, + "multi": false, + "commit": "ac52f84" +} \ No newline at end of file diff --git a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821211.json b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821211.json new file mode 100644 index 00000000..f598a850 --- /dev/null +++ b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821211.json @@ -0,0 +1,180 @@ +{ + "transactions": [ + { + "hash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionType": "CREATE", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "function": null, + "arguments": [ + "0", + "0", + "0x88A187a876290E9843175027902B9f7f1B092c88", + "[]", + "[]", + "[]" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "gas": "0x1f2d9a", + "value": "0x0", + "data": "0x60806040523480156200001157600080fd5b506040516200242b3803806200242b833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b5050505090500160405250505085858585858560006200020d620002d660201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620023ea833981519152908290a3506200025e336001600160e01b03620002da16565b62000272846001600160e01b036200036c16565b62000286866001600160e01b036200046c16565b6200029a856001600160e01b03620004a716565b620002af83836001600160e01b036200058516565b620002c483826001600160e01b03620007d316565b505050505050505050505050620009fd565b3390565b6001600160a01b038116620003215760405162461bcd60e51b8152600401808060200182810382526026815260200180620023c46026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620023ea83398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b6200037f6001600160e01b036200097016565b620003d1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b81526004018080602001828103825260218152602001806200240a6021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004bd81620009a160201b620017ea1760201c565b51600255620004fd620004db620009bd602090811b620015a217901c565b6040805160208082019092526002548152919062001804620009e3821b17901c565b6200054f576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005dc576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200060157fe5b60200260200101516001600160a01b031614156200065a576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000664620009ea565b6200068e8383815181106200067557fe5b6020026020010151620009a160201b620017ea1760201c565b9050620006be620006a9620009bd60201b620015a21760201c565b82620009e360201b620018041790919060201c565b62000710576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200072257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200078557fe5b60200260200101518484815181106200079a57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005df565b505050565b80518251146200082a576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200084f57fe5b60200260200101516001600160a01b03161415620008a8576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008b557fe5b602002602001015160016000858481518110620008ce57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200092857fe5b60200260200101518383815181106200093d57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a16001016200082d565b6004546000906001600160a01b0316620009926001600160e01b03620002d616565b6001600160a01b031614905090565b620009ab620009ea565b50604080516020810190915290815290565b620009c7620009ea565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b6119b78062000a0d6000396000f3fe608060405234801561001057600080fd5b506004361061016c5760003560e01c806368b89d58116100cd5780638f32d59b11610081578063e829902e11610066578063e829902e14610521578063f2fde38b146105e3578063fd165f53146106165761016c565b80638f32d59b14610511578063a44235cb146105195761016c565b8063715018a6116100b2578063715018a6146104c2578063753d8c2f146104ca5780638da5cb5b146105095761016c565b806368b89d58146103b95780636cac543a146104005761016c565b80633932bcc3116101245780634afb215e116101095780634afb215e1461033657806353f5d6f1146103695780635ac3ff701461039c5761016c565b80633932bcc3146102d057806339b84ecf146103035761016c565b8063132e8aa711610155578063132e8aa7146102525780631893304f146102835780632e37ff73146102c85761016c565b8063020323dd1461017157806305e0478514610235575b600080fd5b6102336004803603604081101561018757600080fd5b8101906020810181356401000000008111156101a257600080fd5b8201836020820111156101b457600080fd5b803590602001918460208302840111640100000000831117156101d657600080fd5b9193909290916020810190356401000000008111156101f457600080fd5b82018360208201111561020657600080fd5b8035906020019184602083028401116401000000008311171561022857600080fd5b509092509050610649565b005b6102336004803603602081101561024b57600080fd5b5035610715565b61025a61077a565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6102b66004803603602081101561029957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610796565b60408051918252519081900360200190f35b6102b66107a8565b6102b6600480360360208110156102e657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107ae565b6102b66004803603602081101561031957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107c0565b6102336004803603602081101561034c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107fd565b6102b66004803603602081101561037f57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610921565b610233600480360360208110156103b257600080fd5b5035610933565b6103ec600480360360208110156103cf57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610995565b604080519115158252519081900360200190f35b6102336004803603604081101561041657600080fd5b81019060208101813564010000000081111561043157600080fd5b82018360208201111561044357600080fd5b8035906020019184602083028401116401000000008311171561046557600080fd5b91939092909160208101903564010000000081111561048357600080fd5b82018360208201111561049557600080fd5b803590602001918460208302840111640100000000831117156104b757600080fd5b5090925090506109a7565b610233610a6d565b6103ec600480360360608110156104e057600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610b35565b61025a610c47565b6103ec610c63565b6102b6610ca3565b6102336004803603604081101561053757600080fd5b81019060208101813564010000000081111561055257600080fd5b82018360208201111561056457600080fd5b8035906020019184602083028401116401000000008311171561058657600080fd5b9193909290916020810190356401000000008111156105a457600080fd5b8201836020820111156105b657600080fd5b803590602001918460208302840111640100000000831117156105d857600080fd5b509092509050610ca9565b610233600480360360208110156105f957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f0e565b6103ec6004803603602081101561062c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f70565b610651610c63565b6106a2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f8484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061105b92505050565b50505050565b61071d610c63565b61076e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610777816112c7565b50565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b60036020526000908152604090205481565b60005481565b60066020526000908152604090205481565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260016020526040812054806107f55750506000546107f8565b90505b919050565b610805610c63565b610856576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166108a85760405162461bcd60e51b81526004018080602001828103825260218152602001806119626021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60016020526000908152604090205481565b61093b610c63565b61098c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077781611382565b60006109a082610f70565b1592915050565b6109af610c63565b610a00576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113bd92505050565b610a75610c63565b610ac6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610b539061159e565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610b939061159e565b90508015610b9f578091505b6000610bb1610bac6115a2565b61159e565b90506000610bc5828563ffffffff6115c616565b90506000610bf369d3c21bcecceda1000000610be78b8563ffffffff61162916565b9063ffffffff61168216565b90506000610c07848763ffffffff6116c416565b90506000610c2969d3c21bcecceda1000000610be78d8563ffffffff61162916565b9050808a1080610c385750828a115b9b9a5050505050505050505050565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610c87611706565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610cb1610c63565b610d02576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b828114610d56576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b83811015610f07576000858583818110610d6f57fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610df5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b828282818110610e0157fe5b9050602002013560066000878785818110610e1857fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fa62a59cb391b90466127d5c2ae9c7cfb59877763680d974867d6abe0c4fd52cb858583818110610ea057fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff16848484818110610ec957fe5b6040805173ffffffffffffffffffffffffffffffffffffffff90951685526020918202939093013590840152508051918290030190a1600101610d59565b5050505050565b610f16610c63565b610f67576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107778161170a565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610fe357600080fd5b505afa158015610ff7573d6000803e3d6000fd5b505050506040513d604081101561100d57600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526006602052604090205490915080611048576000925050506107f8565b611053818386610b35565b949350505050565b80518251146110b1576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff168382815181106110e157fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415611152576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b61115a611907565b61117683838151811061116957fe5b60200260200101516117ea565b90506111906111836115a2565b829063ffffffff61180416565b6111e1576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111f257fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061126e57fe5b602002602001015184848151811061128257fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110b4565b505050565b6112d0816117ea565b516002556112fb6112df6115a2565b604080516020810190915260025481529063ffffffff61180416565b61134c576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b8051825114611413576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff1683828151811061144357fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114b4576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114c057fe5b6020026020010151600160008584815181106114d857fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061154b57fe5b602002602001015183838151811061155f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611416565b5190565b6115aa611907565b50604080516020810190915269d3c21bcecceda1000000815290565b600082820183811015611620576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b60008261163857506000611623565b8282028284828161164557fe5b04146116205760405162461bcd60e51b81526004018080602001828103825260218152602001806119416021913960400191505060405180910390fd5b600061162083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061180b565b600061162083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506118ad565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661175c5760405162461bcd60e51b815260040180806020018281038252602681526020018061191b6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6117f2611907565b50604080516020810190915290815290565b5190511090565b600081836118975760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561185c578181015183820152602001611844565b50505050905090810190601f1680156118895780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816118a357fe5b0495945050505050565b600081848411156118ff5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561185c578181015183820152602001611844565b505050900390565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a723158202de52c133daa5165b485b36d57f3f0ee8f32fe21677670bf73fc60225c1d889a64736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d757374206265207365740000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000088a187a876290e9843175027902b9f7f1b092c8800000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "nonce": "0x289" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", + "transactionType": "CALL", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "function": "transferOwnership(address)", + "arguments": [ + "0x28443b1d87db521320a6517A4F1B6Ead77F8C811" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "to": "0xcf49ddc026a66cbd5312a46eada3176d40b245e5", + "gas": "0xa387", + "value": "0x0", + "data": "0xf2fde38b00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811", + "nonce": "0x28a" + }, + "additionalContracts": [], + "isFixedGasLimit": false + } + ], + "receipts": [ + { + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": null, + "cumulativeGasUsed": "0x17fbb2", + "gasUsed": "0x17fbb2", + "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "logs": [ + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x0", + "removed": false + }, + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x1", + "removed": false + }, + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f7353" + ], + "data": "0x00000000000000000000000088a187a876290e9843175027902b9f7f1b092c88", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x2", + "removed": false + }, + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a2" + ], + "data": "0x0000000000000000000000000000000000000000000000000000000000000000", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x3", + "removed": false + }, + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0xd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d" + ], + "data": "0x0000000000000000000000000000000000000000000000000000000000000000", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x4", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000022800000000000000000000000000000000000000000010000000000001040000000000000000000000000000000000000000000000000000001000000000000000000000000000000800000020000000000000200000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000004000000800000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000020000004000000000041000000000000000000000000000000000000000020000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" + }, + { + "transactionHash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", + "transactionIndex": "0x1", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "cumulativeGasUsed": "0x186b83", + "gasUsed": "0x6fd1", + "contractAddress": null, + "logs": [ + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", + "0x00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811" + ], + "data": "0x", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", + "transactionIndex": "0x1", + "logIndex": "0x5", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000020801000000000000000000000000000000000000000010000000000000040000000000000000000000000000000000000000000000000000001000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000004000000000040000000000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" + } + ], + "libraries": [ + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x3e2cc57f83093Ce1Ee03482c1590E3B5f4225bd7", + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0x99EDce8143FF8AeFA1fBB6C2103B349Add2B9519" + ], + "pending": [], + "returns": {}, + "timestamp": 1692821211, + "chain": 62320, + "multi": false, + "commit": "ac52f84" +} \ No newline at end of file diff --git a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821216.json b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821216.json new file mode 100644 index 00000000..fbfe4e2f --- /dev/null +++ b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821216.json @@ -0,0 +1,180 @@ +{ + "transactions": [ + { + "hash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionType": "CREATE", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "function": null, + "arguments": [ + "0", + "0", + "0x88A187a876290E9843175027902B9f7f1B092c88", + "[]", + "[]", + "[]" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "gas": "0x1f2d9a", + "value": "0x0", + "data": "0x60806040523480156200001157600080fd5b506040516200242b3803806200242b833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b5050505090500160405250505085858585858560006200020d620002d660201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620023ea833981519152908290a3506200025e336001600160e01b03620002da16565b62000272846001600160e01b036200036c16565b62000286866001600160e01b036200046c16565b6200029a856001600160e01b03620004a716565b620002af83836001600160e01b036200058516565b620002c483826001600160e01b03620007d316565b505050505050505050505050620009fd565b3390565b6001600160a01b038116620003215760405162461bcd60e51b8152600401808060200182810382526026815260200180620023c46026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620023ea83398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b6200037f6001600160e01b036200097016565b620003d1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b81526004018080602001828103825260218152602001806200240a6021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004bd81620009a160201b620017ea1760201c565b51600255620004fd620004db620009bd602090811b620015a217901c565b6040805160208082019092526002548152919062001804620009e3821b17901c565b6200054f576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005dc576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200060157fe5b60200260200101516001600160a01b031614156200065a576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000664620009ea565b6200068e8383815181106200067557fe5b6020026020010151620009a160201b620017ea1760201c565b9050620006be620006a9620009bd60201b620015a21760201c565b82620009e360201b620018041790919060201c565b62000710576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200072257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200078557fe5b60200260200101518484815181106200079a57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005df565b505050565b80518251146200082a576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200084f57fe5b60200260200101516001600160a01b03161415620008a8576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008b557fe5b602002602001015160016000858481518110620008ce57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200092857fe5b60200260200101518383815181106200093d57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a16001016200082d565b6004546000906001600160a01b0316620009926001600160e01b03620002d616565b6001600160a01b031614905090565b620009ab620009ea565b50604080516020810190915290815290565b620009c7620009ea565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b6119b78062000a0d6000396000f3fe608060405234801561001057600080fd5b506004361061016c5760003560e01c806368b89d58116100cd5780638f32d59b11610081578063e829902e11610066578063e829902e14610521578063f2fde38b146105e3578063fd165f53146106165761016c565b80638f32d59b14610511578063a44235cb146105195761016c565b8063715018a6116100b2578063715018a6146104c2578063753d8c2f146104ca5780638da5cb5b146105095761016c565b806368b89d58146103b95780636cac543a146104005761016c565b80633932bcc3116101245780634afb215e116101095780634afb215e1461033657806353f5d6f1146103695780635ac3ff701461039c5761016c565b80633932bcc3146102d057806339b84ecf146103035761016c565b8063132e8aa711610155578063132e8aa7146102525780631893304f146102835780632e37ff73146102c85761016c565b8063020323dd1461017157806305e0478514610235575b600080fd5b6102336004803603604081101561018757600080fd5b8101906020810181356401000000008111156101a257600080fd5b8201836020820111156101b457600080fd5b803590602001918460208302840111640100000000831117156101d657600080fd5b9193909290916020810190356401000000008111156101f457600080fd5b82018360208201111561020657600080fd5b8035906020019184602083028401116401000000008311171561022857600080fd5b509092509050610649565b005b6102336004803603602081101561024b57600080fd5b5035610715565b61025a61077a565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6102b66004803603602081101561029957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610796565b60408051918252519081900360200190f35b6102b66107a8565b6102b6600480360360208110156102e657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107ae565b6102b66004803603602081101561031957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107c0565b6102336004803603602081101561034c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107fd565b6102b66004803603602081101561037f57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610921565b610233600480360360208110156103b257600080fd5b5035610933565b6103ec600480360360208110156103cf57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610995565b604080519115158252519081900360200190f35b6102336004803603604081101561041657600080fd5b81019060208101813564010000000081111561043157600080fd5b82018360208201111561044357600080fd5b8035906020019184602083028401116401000000008311171561046557600080fd5b91939092909160208101903564010000000081111561048357600080fd5b82018360208201111561049557600080fd5b803590602001918460208302840111640100000000831117156104b757600080fd5b5090925090506109a7565b610233610a6d565b6103ec600480360360608110156104e057600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610b35565b61025a610c47565b6103ec610c63565b6102b6610ca3565b6102336004803603604081101561053757600080fd5b81019060208101813564010000000081111561055257600080fd5b82018360208201111561056457600080fd5b8035906020019184602083028401116401000000008311171561058657600080fd5b9193909290916020810190356401000000008111156105a457600080fd5b8201836020820111156105b657600080fd5b803590602001918460208302840111640100000000831117156105d857600080fd5b509092509050610ca9565b610233600480360360208110156105f957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f0e565b6103ec6004803603602081101561062c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f70565b610651610c63565b6106a2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f8484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061105b92505050565b50505050565b61071d610c63565b61076e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610777816112c7565b50565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b60036020526000908152604090205481565b60005481565b60066020526000908152604090205481565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260016020526040812054806107f55750506000546107f8565b90505b919050565b610805610c63565b610856576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166108a85760405162461bcd60e51b81526004018080602001828103825260218152602001806119626021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60016020526000908152604090205481565b61093b610c63565b61098c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077781611382565b60006109a082610f70565b1592915050565b6109af610c63565b610a00576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113bd92505050565b610a75610c63565b610ac6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610b539061159e565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610b939061159e565b90508015610b9f578091505b6000610bb1610bac6115a2565b61159e565b90506000610bc5828563ffffffff6115c616565b90506000610bf369d3c21bcecceda1000000610be78b8563ffffffff61162916565b9063ffffffff61168216565b90506000610c07848763ffffffff6116c416565b90506000610c2969d3c21bcecceda1000000610be78d8563ffffffff61162916565b9050808a1080610c385750828a115b9b9a5050505050505050505050565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610c87611706565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610cb1610c63565b610d02576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b828114610d56576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b83811015610f07576000858583818110610d6f57fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610df5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b828282818110610e0157fe5b9050602002013560066000878785818110610e1857fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fa62a59cb391b90466127d5c2ae9c7cfb59877763680d974867d6abe0c4fd52cb858583818110610ea057fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff16848484818110610ec957fe5b6040805173ffffffffffffffffffffffffffffffffffffffff90951685526020918202939093013590840152508051918290030190a1600101610d59565b5050505050565b610f16610c63565b610f67576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107778161170a565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610fe357600080fd5b505afa158015610ff7573d6000803e3d6000fd5b505050506040513d604081101561100d57600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526006602052604090205490915080611048576000925050506107f8565b611053818386610b35565b949350505050565b80518251146110b1576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff168382815181106110e157fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415611152576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b61115a611907565b61117683838151811061116957fe5b60200260200101516117ea565b90506111906111836115a2565b829063ffffffff61180416565b6111e1576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111f257fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061126e57fe5b602002602001015184848151811061128257fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110b4565b505050565b6112d0816117ea565b516002556112fb6112df6115a2565b604080516020810190915260025481529063ffffffff61180416565b61134c576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b8051825114611413576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff1683828151811061144357fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114b4576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114c057fe5b6020026020010151600160008584815181106114d857fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061154b57fe5b602002602001015183838151811061155f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611416565b5190565b6115aa611907565b50604080516020810190915269d3c21bcecceda1000000815290565b600082820183811015611620576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b60008261163857506000611623565b8282028284828161164557fe5b04146116205760405162461bcd60e51b81526004018080602001828103825260218152602001806119416021913960400191505060405180910390fd5b600061162083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061180b565b600061162083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506118ad565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661175c5760405162461bcd60e51b815260040180806020018281038252602681526020018061191b6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6117f2611907565b50604080516020810190915290815290565b5190511090565b600081836118975760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561185c578181015183820152602001611844565b50505050905090810190601f1680156118895780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816118a357fe5b0495945050505050565b600081848411156118ff5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561185c578181015183820152602001611844565b505050900390565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a723158202de52c133daa5165b485b36d57f3f0ee8f32fe21677670bf73fc60225c1d889a64736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d757374206265207365740000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000088a187a876290e9843175027902b9f7f1b092c8800000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "nonce": "0x289" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", + "transactionType": "CALL", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "function": "transferOwnership(address)", + "arguments": [ + "0x28443b1d87db521320a6517A4F1B6Ead77F8C811" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "to": "0xcf49ddc026a66cbd5312a46eada3176d40b245e5", + "gas": "0xa387", + "value": "0x0", + "data": "0xf2fde38b00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811", + "nonce": "0x28a" + }, + "additionalContracts": [], + "isFixedGasLimit": false + } + ], + "receipts": [ + { + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": null, + "cumulativeGasUsed": "0x17fbb2", + "gasUsed": "0x17fbb2", + "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "logs": [ + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x0", + "removed": false + }, + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x1", + "removed": false + }, + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f7353" + ], + "data": "0x00000000000000000000000088a187a876290e9843175027902b9f7f1b092c88", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x2", + "removed": false + }, + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a2" + ], + "data": "0x0000000000000000000000000000000000000000000000000000000000000000", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x3", + "removed": false + }, + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0xd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d" + ], + "data": "0x0000000000000000000000000000000000000000000000000000000000000000", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x4", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000022800000000000000000000000000000000000000000010000000000001040000000000000000000000000000000000000000000000000000001000000000000000000000000000000800000020000000000000200000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000004000000800000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000020000004000000000041000000000000000000000000000000000000000020000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" + }, + { + "transactionHash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", + "transactionIndex": "0x1", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "cumulativeGasUsed": "0x186b83", + "gasUsed": "0x6fd1", + "contractAddress": null, + "logs": [ + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", + "0x00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811" + ], + "data": "0x", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", + "transactionIndex": "0x1", + "logIndex": "0x5", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000020801000000000000000000000000000000000000000010000000000000040000000000000000000000000000000000000000000000000000001000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000004000000000040000000000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" + } + ], + "libraries": [ + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x3e2cc57f83093Ce1Ee03482c1590E3B5f4225bd7", + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0x99EDce8143FF8AeFA1fBB6C2103B349Add2B9519" + ], + "pending": [], + "returns": {}, + "timestamp": 1692821216, + "chain": 62320, + "multi": false, + "commit": "ac52f84" +} \ No newline at end of file diff --git a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-latest.json b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-latest.json new file mode 100644 index 00000000..fbfe4e2f --- /dev/null +++ b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-latest.json @@ -0,0 +1,180 @@ +{ + "transactions": [ + { + "hash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionType": "CREATE", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "function": null, + "arguments": [ + "0", + "0", + "0x88A187a876290E9843175027902B9f7f1B092c88", + "[]", + "[]", + "[]" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "gas": "0x1f2d9a", + "value": "0x0", + "data": "0x60806040523480156200001157600080fd5b506040516200242b3803806200242b833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b5050505090500160405250505085858585858560006200020d620002d660201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620023ea833981519152908290a3506200025e336001600160e01b03620002da16565b62000272846001600160e01b036200036c16565b62000286866001600160e01b036200046c16565b6200029a856001600160e01b03620004a716565b620002af83836001600160e01b036200058516565b620002c483826001600160e01b03620007d316565b505050505050505050505050620009fd565b3390565b6001600160a01b038116620003215760405162461bcd60e51b8152600401808060200182810382526026815260200180620023c46026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620023ea83398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b6200037f6001600160e01b036200097016565b620003d1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b81526004018080602001828103825260218152602001806200240a6021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004bd81620009a160201b620017ea1760201c565b51600255620004fd620004db620009bd602090811b620015a217901c565b6040805160208082019092526002548152919062001804620009e3821b17901c565b6200054f576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005dc576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200060157fe5b60200260200101516001600160a01b031614156200065a576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000664620009ea565b6200068e8383815181106200067557fe5b6020026020010151620009a160201b620017ea1760201c565b9050620006be620006a9620009bd60201b620015a21760201c565b82620009e360201b620018041790919060201c565b62000710576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200072257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200078557fe5b60200260200101518484815181106200079a57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005df565b505050565b80518251146200082a576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200084f57fe5b60200260200101516001600160a01b03161415620008a8576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008b557fe5b602002602001015160016000858481518110620008ce57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200092857fe5b60200260200101518383815181106200093d57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a16001016200082d565b6004546000906001600160a01b0316620009926001600160e01b03620002d616565b6001600160a01b031614905090565b620009ab620009ea565b50604080516020810190915290815290565b620009c7620009ea565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b6119b78062000a0d6000396000f3fe608060405234801561001057600080fd5b506004361061016c5760003560e01c806368b89d58116100cd5780638f32d59b11610081578063e829902e11610066578063e829902e14610521578063f2fde38b146105e3578063fd165f53146106165761016c565b80638f32d59b14610511578063a44235cb146105195761016c565b8063715018a6116100b2578063715018a6146104c2578063753d8c2f146104ca5780638da5cb5b146105095761016c565b806368b89d58146103b95780636cac543a146104005761016c565b80633932bcc3116101245780634afb215e116101095780634afb215e1461033657806353f5d6f1146103695780635ac3ff701461039c5761016c565b80633932bcc3146102d057806339b84ecf146103035761016c565b8063132e8aa711610155578063132e8aa7146102525780631893304f146102835780632e37ff73146102c85761016c565b8063020323dd1461017157806305e0478514610235575b600080fd5b6102336004803603604081101561018757600080fd5b8101906020810181356401000000008111156101a257600080fd5b8201836020820111156101b457600080fd5b803590602001918460208302840111640100000000831117156101d657600080fd5b9193909290916020810190356401000000008111156101f457600080fd5b82018360208201111561020657600080fd5b8035906020019184602083028401116401000000008311171561022857600080fd5b509092509050610649565b005b6102336004803603602081101561024b57600080fd5b5035610715565b61025a61077a565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6102b66004803603602081101561029957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610796565b60408051918252519081900360200190f35b6102b66107a8565b6102b6600480360360208110156102e657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107ae565b6102b66004803603602081101561031957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107c0565b6102336004803603602081101561034c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107fd565b6102b66004803603602081101561037f57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610921565b610233600480360360208110156103b257600080fd5b5035610933565b6103ec600480360360208110156103cf57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610995565b604080519115158252519081900360200190f35b6102336004803603604081101561041657600080fd5b81019060208101813564010000000081111561043157600080fd5b82018360208201111561044357600080fd5b8035906020019184602083028401116401000000008311171561046557600080fd5b91939092909160208101903564010000000081111561048357600080fd5b82018360208201111561049557600080fd5b803590602001918460208302840111640100000000831117156104b757600080fd5b5090925090506109a7565b610233610a6d565b6103ec600480360360608110156104e057600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610b35565b61025a610c47565b6103ec610c63565b6102b6610ca3565b6102336004803603604081101561053757600080fd5b81019060208101813564010000000081111561055257600080fd5b82018360208201111561056457600080fd5b8035906020019184602083028401116401000000008311171561058657600080fd5b9193909290916020810190356401000000008111156105a457600080fd5b8201836020820111156105b657600080fd5b803590602001918460208302840111640100000000831117156105d857600080fd5b509092509050610ca9565b610233600480360360208110156105f957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f0e565b6103ec6004803603602081101561062c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f70565b610651610c63565b6106a2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f8484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061105b92505050565b50505050565b61071d610c63565b61076e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610777816112c7565b50565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b60036020526000908152604090205481565b60005481565b60066020526000908152604090205481565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260016020526040812054806107f55750506000546107f8565b90505b919050565b610805610c63565b610856576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166108a85760405162461bcd60e51b81526004018080602001828103825260218152602001806119626021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60016020526000908152604090205481565b61093b610c63565b61098c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077781611382565b60006109a082610f70565b1592915050565b6109af610c63565b610a00576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113bd92505050565b610a75610c63565b610ac6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610b539061159e565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610b939061159e565b90508015610b9f578091505b6000610bb1610bac6115a2565b61159e565b90506000610bc5828563ffffffff6115c616565b90506000610bf369d3c21bcecceda1000000610be78b8563ffffffff61162916565b9063ffffffff61168216565b90506000610c07848763ffffffff6116c416565b90506000610c2969d3c21bcecceda1000000610be78d8563ffffffff61162916565b9050808a1080610c385750828a115b9b9a5050505050505050505050565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610c87611706565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610cb1610c63565b610d02576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b828114610d56576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b83811015610f07576000858583818110610d6f57fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610df5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b828282818110610e0157fe5b9050602002013560066000878785818110610e1857fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fa62a59cb391b90466127d5c2ae9c7cfb59877763680d974867d6abe0c4fd52cb858583818110610ea057fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff16848484818110610ec957fe5b6040805173ffffffffffffffffffffffffffffffffffffffff90951685526020918202939093013590840152508051918290030190a1600101610d59565b5050505050565b610f16610c63565b610f67576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107778161170a565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610fe357600080fd5b505afa158015610ff7573d6000803e3d6000fd5b505050506040513d604081101561100d57600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526006602052604090205490915080611048576000925050506107f8565b611053818386610b35565b949350505050565b80518251146110b1576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff168382815181106110e157fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415611152576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b61115a611907565b61117683838151811061116957fe5b60200260200101516117ea565b90506111906111836115a2565b829063ffffffff61180416565b6111e1576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111f257fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061126e57fe5b602002602001015184848151811061128257fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110b4565b505050565b6112d0816117ea565b516002556112fb6112df6115a2565b604080516020810190915260025481529063ffffffff61180416565b61134c576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b8051825114611413576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff1683828151811061144357fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114b4576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114c057fe5b6020026020010151600160008584815181106114d857fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061154b57fe5b602002602001015183838151811061155f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611416565b5190565b6115aa611907565b50604080516020810190915269d3c21bcecceda1000000815290565b600082820183811015611620576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b60008261163857506000611623565b8282028284828161164557fe5b04146116205760405162461bcd60e51b81526004018080602001828103825260218152602001806119416021913960400191505060405180910390fd5b600061162083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061180b565b600061162083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506118ad565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661175c5760405162461bcd60e51b815260040180806020018281038252602681526020018061191b6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6117f2611907565b50604080516020810190915290815290565b5190511090565b600081836118975760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561185c578181015183820152602001611844565b50505050905090810190601f1680156118895780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816118a357fe5b0495945050505050565b600081848411156118ff5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561185c578181015183820152602001611844565b505050900390565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a723158202de52c133daa5165b485b36d57f3f0ee8f32fe21677670bf73fc60225c1d889a64736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d757374206265207365740000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000088a187a876290e9843175027902b9f7f1b092c8800000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "nonce": "0x289" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", + "transactionType": "CALL", + "contractName": "NonrecoverableValueDeltaBreaker", + "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "function": "transferOwnership(address)", + "arguments": [ + "0x28443b1d87db521320a6517A4F1B6Ead77F8C811" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "to": "0xcf49ddc026a66cbd5312a46eada3176d40b245e5", + "gas": "0xa387", + "value": "0x0", + "data": "0xf2fde38b00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811", + "nonce": "0x28a" + }, + "additionalContracts": [], + "isFixedGasLimit": false + } + ], + "receipts": [ + { + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": null, + "cumulativeGasUsed": "0x17fbb2", + "gasUsed": "0x17fbb2", + "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "logs": [ + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x0", + "removed": false + }, + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x1", + "removed": false + }, + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f7353" + ], + "data": "0x00000000000000000000000088a187a876290e9843175027902b9f7f1b092c88", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x2", + "removed": false + }, + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a2" + ], + "data": "0x0000000000000000000000000000000000000000000000000000000000000000", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x3", + "removed": false + }, + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0xd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d" + ], + "data": "0x0000000000000000000000000000000000000000000000000000000000000000", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", + "transactionIndex": "0x0", + "logIndex": "0x4", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000022800000000000000000000000000000000000000000010000000000001040000000000000000000000000000000000000000000000000000001000000000000000000000000000000800000020000000000000200000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000004000000800000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000020000004000000000041000000000000000000000000000000000000000020000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" + }, + { + "transactionHash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", + "transactionIndex": "0x1", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "cumulativeGasUsed": "0x186b83", + "gasUsed": "0x6fd1", + "contractAddress": null, + "logs": [ + { + "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", + "0x00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811" + ], + "data": "0x", + "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", + "blockNumber": "0x122015c", + "transactionHash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", + "transactionIndex": "0x1", + "logIndex": "0x5", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000020801000000000000000000000000000000000000000010000000000000040000000000000000000000000000000000000000000000000000001000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000004000000000040000000000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" + } + ], + "libraries": [ + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x3e2cc57f83093Ce1Ee03482c1590E3B5f4225bd7", + "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0x99EDce8143FF8AeFA1fBB6C2103B349Add2B9519" + ], + "pending": [], + "returns": {}, + "timestamp": 1692821216, + "chain": 62320, + "multi": false, + "commit": "ac52f84" +} \ No newline at end of file From 19cfb10760fd48369267c77dc5c49731fc22246a Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Wed, 23 Aug 2023 15:58:34 -0500 Subject: [PATCH 07/64] chore: add new eur rate feed identifiers --- script/upgrades/dependencies.json | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/script/upgrades/dependencies.json b/script/upgrades/dependencies.json index 0b9582dd..b739e355 100644 --- a/script/upgrades/dependencies.json +++ b/script/upgrades/dependencies.json @@ -4,6 +4,8 @@ "USDCUSDRateFeedAddr": "0xA1A8003936862E7a15092A91898D69fa8bCE290c", "USDCEURRateFeedAddr": "0x206B25Ea01E188Ee243131aFdE526bA6E131a016", "USDCBRLRateFeedAddr": "0x25F21A1f97607Edf6852339fad709728cffb9a9d", + "EURXOFRateFeedAddr": "0x40dc8528167557353fdcd98548ab2139a670dd0b", + "EUROCEURRateFeedAddr": "0x26076b9702885d475ac8c3db3bd9f250dc5a318b", "PartialReserveMultisig": "0x87647780180B8f55980C7D3fFeFe08a9B29e9aE1" }, "62320": { @@ -12,6 +14,8 @@ "USDCUSDRateFeedAddr": "0xA1A8003936862E7a15092A91898D69fa8bCE290c", "USDCEURRateFeedAddr": "0x206B25Ea01E188Ee243131aFdE526bA6E131a016", "USDCBRLRateFeedAddr": "0x25F21A1f97607Edf6852339fad709728cffb9a9d", + "EURXOFRateFeedAddr": "0x40dc8528167557353fdcd98548ab2139a670dd0b", + "EUROCEURRateFeedAddr": "0x26076b9702885d475ac8c3db3bd9f250dc5a318b", "PartialReserveMultisig": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81" }, "44787": { @@ -20,6 +24,8 @@ "USDCUSDRateFeedAddr": "0xA1A8003936862E7a15092A91898D69fa8bCE290c", "USDCEURRateFeedAddr": "0x206B25Ea01E188Ee243131aFdE526bA6E131a016", "USDCBRLRateFeedAddr": "0x25F21A1f97607Edf6852339fad709728cffb9a9d", + "EURXOFRateFeedAddr": "0x40dc8528167557353fdcd98548ab2139a670dd0b", + "EUROCEURRateFeedAddr": "0x26076b9702885d475ac8c3db3bd9f250dc5a318b", "PartialReserveMultisig": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81" } } From 259ced128d65d15a6e1d964e042849efa2ecf596 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Wed, 23 Aug 2023 16:14:47 -0500 Subject: [PATCH 08/64] chore: update rate feed references --- lib/mento-core | 1 + script/upgrades/eXOF/Config.sol | 2 +- script/upgrades/eXOF/eXOF.sol | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) create mode 160000 lib/mento-core diff --git a/lib/mento-core b/lib/mento-core new file mode 160000 index 00000000..aee81629 --- /dev/null +++ b/lib/mento-core @@ -0,0 +1 @@ +Subproject commit aee816290ac9395b528094455360e8e130eedb5f diff --git a/script/upgrades/eXOF/Config.sol b/script/upgrades/eXOF/Config.sol index 2be98f6f..f7365ab1 100644 --- a/script/upgrades/eXOF/Config.sol +++ b/script/upgrades/eXOF/Config.sol @@ -107,7 +107,7 @@ library eXOFConfig { minimumReports: 5, referenceRateResetFrequency: 5 minutes, stablePoolResetSize: 656 * 1_000_000 * 1e18, // 656 * 1.0 million - referenceRateFeedID: contracts.dependency("EUROCXOFRateFeedAddr"), + referenceRateFeedID: contracts.dependency("EURXOFRateFeedAddr"), asset0limits: Config.TradingLimit({ enabled0: true, timeStep0: 5 minutes, diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index 3b8104c3..4381867d 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -355,7 +355,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { breakerBox, abi.encodeWithSelector( BreakerBox(0).addRateFeeds.selector, - Arrays.addresses(eXOFProxy, contracts.dependency("EUROCXOFRateFeedAddr")) + Arrays.addresses(eXOFProxy, contracts.dependency("EURXOFRateFeedAddr")) ) ) ); From f7f0681e2e6872d959ab2732bb9cfd1308bca387 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 24 Aug 2023 13:51:06 -0500 Subject: [PATCH 09/64] chore: reafactor for better readability --- script/upgrades/dependencies.json | 6 +- script/upgrades/eXOF/Config.sol | 127 +++++++++++++++++++----------- 2 files changed, 85 insertions(+), 48 deletions(-) diff --git a/script/upgrades/dependencies.json b/script/upgrades/dependencies.json index b739e355..9ed62424 100644 --- a/script/upgrades/dependencies.json +++ b/script/upgrades/dependencies.json @@ -5,7 +5,7 @@ "USDCEURRateFeedAddr": "0x206B25Ea01E188Ee243131aFdE526bA6E131a016", "USDCBRLRateFeedAddr": "0x25F21A1f97607Edf6852339fad709728cffb9a9d", "EURXOFRateFeedAddr": "0x40dc8528167557353fdcd98548ab2139a670dd0b", - "EUROCEURRateFeedAddr": "0x26076b9702885d475ac8c3db3bd9f250dc5a318b", + "EUROCEURRateFeedAddr": "0x26076B9702885d475ac8c3dB3Bd9F250Dc5A318B", "PartialReserveMultisig": "0x87647780180B8f55980C7D3fFeFe08a9B29e9aE1" }, "62320": { @@ -15,7 +15,7 @@ "USDCEURRateFeedAddr": "0x206B25Ea01E188Ee243131aFdE526bA6E131a016", "USDCBRLRateFeedAddr": "0x25F21A1f97607Edf6852339fad709728cffb9a9d", "EURXOFRateFeedAddr": "0x40dc8528167557353fdcd98548ab2139a670dd0b", - "EUROCEURRateFeedAddr": "0x26076b9702885d475ac8c3db3bd9f250dc5a318b", + "EUROCEURRateFeedAddr": "0x26076B9702885d475ac8c3dB3Bd9F250Dc5A318B", "PartialReserveMultisig": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81" }, "44787": { @@ -25,7 +25,7 @@ "USDCEURRateFeedAddr": "0x206B25Ea01E188Ee243131aFdE526bA6E131a016", "USDCBRLRateFeedAddr": "0x25F21A1f97607Edf6852339fad709728cffb9a9d", "EURXOFRateFeedAddr": "0x40dc8528167557353fdcd98548ab2139a670dd0b", - "EUROCEURRateFeedAddr": "0x26076b9702885d475ac8c3db3bd9f250dc5a318b", + "EUROCEURRateFeedAddr": "0x26076B9702885d475ac8c3dB3Bd9F250Dc5A318B", "PartialReserveMultisig": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81" } } diff --git a/script/upgrades/eXOF/Config.sol b/script/upgrades/eXOF/Config.sol index f7365ab1..2db7a28a 100644 --- a/script/upgrades/eXOF/Config.sol +++ b/script/upgrades/eXOF/Config.sol @@ -9,20 +9,31 @@ import { Contracts } from "script/utils/Contracts.sol"; import { Arrays } from "script/utils/Arrays.sol"; import { FixidityLib } from "script/utils/FixidityLib.sol"; +/** + * @dev This library contains the configuration required for the eXOF governance proposal. + * The following configuration is used: + * - 2 pools: eXOFCelo and eXOFEUROC + * - 2 rate feeds: CELOXOF and EUROXOF + */ library eXOFConfig { using FixidityLib for FixidityLib.Fraction; using Contracts for Contracts.Cache; struct eXOF { + // Pools Config.Pool eXOFCelo; Config.Pool eXOFEUROC; Config.Pool[] pools; + // Rate Feeds Config.RateFeed CELOXOF; - Config.RateFeed EUROCXOF; + Config.RateFeed EUROXOF; Config.RateFeed[] rateFeeds; Config.StableToken stableTokenXOF; } + /** + * @dev Returns the populated configuration object for the eXOF governance proposal. + */ function get(Contracts.Cache storage contracts) internal returns (eXOF memory config) { config.pools = new Config.Pool[](2); config.pools[0] = config.eXOFCelo = eXOFCelo_PoolConfig(contracts); @@ -30,27 +41,60 @@ library eXOFConfig { config.rateFeeds = new Config.RateFeed[](3); config.rateFeeds[0] = config.CELOXOF = CELOXOF_RateFeedConfig(contracts); - config.rateFeeds[1] = config.EUROCXOF = EUROCXOF_RateFeedConfig(contracts); + config.rateFeeds[1] = config.EUROXOF = EUROXOF_RateFeedConfig(contracts); config.stableTokenXOF = stableTokenXOFConfig(); } - function stableTokenXOFConfig() internal pure returns (Config.StableToken memory config) { - config = Config.StableToken({ - name: "ECO CFA", - symbol: "eXOF", - decimals: 18, - registryAddress: address(0x000000000000000000000000000000000000ce10), - inflationRate: 1000000000000000000000000, - inflationFactorUpdatePeriod: 47304000, - initialBalanceAddresses: new address[](0), - initialBalanceValues: new uint256[](0), - exchangeIdentifier: "Broker" + /* ==================== Rate Feed Configurations ==================== */ + + /** + * @dev Returns the configuration for the CELOXOF rate feed. + */ + function CELOXOF_RateFeedConfig( + Contracts.Cache storage contracts + ) internal view returns (Config.RateFeed memory rateFeedConfig) { + rateFeedConfig.rateFeedID = contracts.celoRegistry("StableTokenXOF"); + rateFeedConfig.medianDeltaBreaker0 = Config.MedianDeltaBreaker({ + enabled: true, + threshold: FixidityLib.newFixedFraction(3, 100), // 0.03 + cooldown: 30 minutes, + smoothingFactor: 0 + }); + } + + /** + * @dev Returns the configuration for the EUROXOF rate feed. + */ + function EUROXOF_RateFeedConfig( + Contracts.Cache storage contracts + ) internal returns (Config.RateFeed memory rateFeedConfig) { + rateFeedConfig.rateFeedID = contracts.dependency("EURXOFRateFeedAddr"); + rateFeedConfig.valueDeltaBreaker0 = Config.ValueDeltaBreaker({ + enabled: true, + threshold: FixidityLib.newFixedFraction(5, 1000), // 0.005 + referenceValue: 656.55 * 10 ** 24, // TODO: verify + cooldown: 15 minutes + }); + + rateFeedConfig.valueDeltaBreaker1 = Config.ValueDeltaBreaker({ + enabled: true, + threshold: FixidityLib.newFixedFraction(10, 100), // 0.10 + referenceValue: 656.55 * 10 ** 24, // TODO: verify + cooldown: 0 seconds }); + rateFeedConfig.dependentRateFeeds = Arrays.addresses(contracts.dependency("EUROCEURRateFeedAddr")); } - function eXOFCelo_PoolConfig(Contracts.Cache storage contracts) internal view returns (Config.Pool memory config) { - config = Config.Pool({ + /* ==================== Pool Configurations ==================== */ + + /** + * @dev Returns the configuration for the eXOFCelo pool. + */ + function eXOFCelo_PoolConfig( + Contracts.Cache storage contracts + ) internal view returns (Config.Pool memory poolConfig) { + poolConfig = Config.Pool({ asset0: contracts.celoRegistry("StableTokenXOF"), asset1: contracts.celoRegistry("GoldToken"), isConstantSum: false, @@ -82,24 +126,15 @@ library eXOFConfig { }); if (Chain.isBaklava() || Chain.isAlfajores()) { - config.minimumReports = 2; + poolConfig.minimumReports = 2; } } - function CELOXOF_RateFeedConfig( - Contracts.Cache storage contracts - ) internal view returns (Config.RateFeed memory config) { - config.rateFeedID = contracts.celoRegistry("StableTokenXOF"); - config.medianDeltaBreaker0 = Config.MedianDeltaBreaker({ - enabled: true, - threshold: FixidityLib.newFixedFraction(3, 100), // 0.03 - cooldown: 30 minutes, - smoothingFactor: 0 - }); - } - - function eXOFEUROC_PoolConfig(Contracts.Cache storage contracts) internal returns (Config.Pool memory config) { - config = Config.Pool({ + /** + * @dev Returns the configuration for the eXOFEUROC pool. + */ + function eXOFEUROC_PoolConfig(Contracts.Cache storage contracts) internal returns (Config.Pool memory poolConfig) { + poolConfig = Config.Pool({ asset0: contracts.celoRegistry("StableTokenXOF"), asset1: contracts.dependency("BridgedEUROC"), isConstantSum: true, @@ -130,24 +165,26 @@ library eXOFConfig { }) }); if (Chain.isBaklava() || Chain.isAlfajores()) { - config.minimumReports = 2; + poolConfig.minimumReports = 2; } } - function EUROCXOF_RateFeedConfig(Contracts.Cache storage contracts) internal returns (Config.RateFeed memory config) { - config.rateFeedID = contracts.dependency("EUROCXOFRateFeedAddr"); - config.valueDeltaBreaker0 = Config.ValueDeltaBreaker({ - enabled: true, - threshold: FixidityLib.newFixedFraction(5, 1000), // 0.005 - referenceValue: 656.55 * 10 ** 24, // TODO: verify - cooldown: 15 minutes - }); - config.valueDeltaBreaker1 = Config.ValueDeltaBreaker({ - enabled: true, - threshold: FixidityLib.newFixedFraction(10, 100), // 0.10 - referenceValue: 656.55 * 10 ** 24, // TODO: verify - cooldown: 0 seconds + /* ==================== Stable Token Configuration ==================== */ + + /** + * @dev Returns the configuration for the eXOF stable token. + */ + function stableTokenXOFConfig() internal pure returns (Config.StableToken memory config) { + config = Config.StableToken({ + name: "ECO CFA", + symbol: "eXOF", + decimals: 18, + registryAddress: address(0x000000000000000000000000000000000000ce10), + inflationRate: 1000000000000000000000000, + inflationFactorUpdatePeriod: 47304000, + initialBalanceAddresses: new address[](0), + initialBalanceValues: new uint256[](0), + exchangeIdentifier: "Broker" }); - config.dependentRateFeeds = Arrays.addresses(contracts.dependency("EUROCEURRateFeedAddr")); } } From 5fc616eeb74c3b0a3e47b1e4025d894f000c8c3d Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 24 Aug 2023 13:53:58 -0500 Subject: [PATCH 10/64] chore: rename rate feed ref --- script/upgrades/eXOF/eXOF.sol | 26 +++++++++++++------------- script/upgrades/eXOF/eXOFChecks.sol | 4 ++-- 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index 4381867d..eb8d7095 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -133,9 +133,9 @@ contract eXOF is IMentoUpgrade, GovernanceScript { eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); proposal_initializeEXOFToken(config); + proposal_configureEXOFConstitutionParameters(); proposal_addEXOFToReserves(); proposal_enableGasPaymentsWithEXOF(); - proposal_configureEXOFConstitutionParameters(); proposal_createExchanges(config); proposal_configureTradingLimits(config); proposal_configureBreakerBox(config); @@ -484,8 +484,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setCooldownTimes.selector, - Arrays.addresses(config.EUROCXOF.rateFeedID), - Arrays.uints(config.EUROCXOF.valueDeltaBreaker0.cooldown) + Arrays.addresses(config.EUROXOF.rateFeedID), + Arrays.uints(config.EUROXOF.valueDeltaBreaker0.cooldown) ) ) ); @@ -496,8 +496,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setRateChangeThresholds.selector, - Arrays.addresses(config.EUROCXOF.rateFeedID), - Arrays.uints(config.EUROCXOF.valueDeltaBreaker0.threshold.unwrap()) + Arrays.addresses(config.EUROXOF.rateFeedID), + Arrays.uints(config.EUROXOF.valueDeltaBreaker0.threshold.unwrap()) ) ) ); @@ -508,8 +508,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setReferenceValues.selector, - Arrays.addresses(config.EUROCXOF.rateFeedID), - Arrays.uints(config.EUROCXOF.valueDeltaBreaker0.referenceValue) + Arrays.addresses(config.EUROXOF.rateFeedID), + Arrays.uints(config.EUROXOF.valueDeltaBreaker0.referenceValue) ) ) ); @@ -526,8 +526,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { nonrecoverableValueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setCooldownTimes.selector, - Arrays.addresses(config.EUROCXOF.rateFeedID), - Arrays.uints(config.EUROCXOF.valueDeltaBreaker1.cooldown) + Arrays.addresses(config.EUROXOF.rateFeedID), + Arrays.uints(config.EUROXOF.valueDeltaBreaker1.cooldown) ) ) ); @@ -539,8 +539,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { nonrecoverableValueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setRateChangeThresholds.selector, - Arrays.addresses(config.EUROCXOF.rateFeedID), - Arrays.uints(config.EUROCXOF.valueDeltaBreaker1.threshold.unwrap()) + Arrays.addresses(config.EUROXOF.rateFeedID), + Arrays.uints(config.EUROXOF.valueDeltaBreaker1.threshold.unwrap()) ) ) ); @@ -552,8 +552,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { nonrecoverableValueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setReferenceValues.selector, - Arrays.addresses(config.EUROCXOF.rateFeedID), - Arrays.uints(config.EUROCXOF.valueDeltaBreaker1.referenceValue) + Arrays.addresses(config.EUROXOF.rateFeedID), + Arrays.uints(config.EUROXOF.valueDeltaBreaker1.referenceValue) ) ) ); diff --git a/script/upgrades/eXOF/eXOFChecks.sol b/script/upgrades/eXOF/eXOFChecks.sol index f88f2f4b..5aee1128 100644 --- a/script/upgrades/eXOF/eXOFChecks.sol +++ b/script/upgrades/eXOF/eXOFChecks.sol @@ -347,9 +347,9 @@ contract eXOFChecks is Script, Test { console.log("\t Nonrecoverable ValueDeltaBreaker set with trading mode 3"); // verify that rate feed dependencies were configured correctly - address EUROCXOFDependency = BreakerBox(breakerBox).rateFeedDependencies(config.EUROCXOF.rateFeedID, 0); + address EUROCXOFDependency = BreakerBox(breakerBox).rateFeedDependencies(config.EUROXOF.rateFeedID, 0); require( - EUROCXOFDependency == config.EUROCXOF.dependentRateFeeds[0], + EUROCXOFDependency == config.EUROXOF.dependentRateFeeds[0], "EUROC/XOF rate feed dependency not set correctly" ); console.log("\tRate feed dependencies configured correctly 🗳️"); From 94e5b2c232b9b198d968a9db571a2aed81e12513 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 24 Aug 2023 13:58:35 -0500 Subject: [PATCH 11/64] chore: add xof to celo registry --- script/upgrades/eXOF/eXOF.sol | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index eb8d7095..99394c7f 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -133,6 +133,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); proposal_initializeEXOFToken(config); + proposal_addEXOFToCeloRegistry(config); proposal_configureEXOFConstitutionParameters(); proposal_addEXOFToReserves(); proposal_enableGasPaymentsWithEXOF(); @@ -177,6 +178,19 @@ contract eXOF is IMentoUpgrade, GovernanceScript { } } + /** + * @notice Add the transaction to create a new entry for StableTokenXOF in the CeloRegistry + */ + function proposal_addEXOFToCeloRegistry(eXOFConfig.eXOF memory config) private { + transactions.push( + ICeloGovernance.Transaction( + 0, + config.stableTokenXOF.registryAddress, + abi.encodeWithSelector(IRegistry(0).setAddressFor.selector, "StableTokenXOF", eXOFProxy) + ) + ); + } + /** * @notice adds eXOF token to the partial and main reserve */ From 3712057a0997504b6e0d36c8b5a3640f28cb509b Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 24 Aug 2023 18:13:15 -0500 Subject: [PATCH 12/64] feat: update daily spend for collateral assets --- script/upgrades/dependencies.json | 1 + script/upgrades/eXOF/eXOF.sol | 48 ++++++++++++++++++++++++++----- 2 files changed, 42 insertions(+), 7 deletions(-) diff --git a/script/upgrades/dependencies.json b/script/upgrades/dependencies.json index 9ed62424..48b82d52 100644 --- a/script/upgrades/dependencies.json +++ b/script/upgrades/dependencies.json @@ -1,6 +1,7 @@ { "42220": { "BridgedUSDC": "0xEB466342C4d449BC9f53A865D5Cb90586f405215", + "BridgedEUROC": "", "USDCUSDRateFeedAddr": "0xA1A8003936862E7a15092A91898D69fa8bCE290c", "USDCEURRateFeedAddr": "0x206B25Ea01E188Ee243131aFdE526bA6E131a016", "USDCBRLRateFeedAddr": "0x25F21A1f97607Edf6852339fad709728cffb9a9d", diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index 99394c7f..afa7a9b4 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -30,6 +30,7 @@ import { ValueDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/ValueDeltaB import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; import { StableTokenXOF } from "mento-core-2.2.0/legacy/StableTokenXOF.sol"; import { StableTokenXOFProxy } from "mento-core-2.2.0/legacy/proxies/StableTokenXOFProxy.sol"; +import { Reserve } from "mento-core-2.2.0/swap/Reserve.sol"; import { eXOFConfig, Config } from "./Config.sol"; import { IMentoUpgrade, ICeloGovernance } from "script/interfaces/IMentoUpgrade.sol"; @@ -56,6 +57,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { address private brokerProxy; address private biPoolManagerProxy; address private sortedOraclesProxy; + address private partialReserveProxy; // Helper mapping to store the exchange IDs for the reference rate feeds mapping(address => bytes32) private referenceRateFeedIDToExchangeId; @@ -85,17 +87,23 @@ contract eXOF is IMentoUpgrade, GovernanceScript { * @dev Sets the addresses of the various contracts needed for the proposal. */ function setAddresses() public { + // Tokens eXOF = contracts.deployed("StableTokenXOF"); eXOFProxy = contracts.deployed("StableTokenXOFProxy"); celo = contracts.celoRegistry("GoldToken"); - bridgedEUROC = contracts.dependency("BridgedUSDC"); + bridgedEUROC = contracts.dependency("BridgedEUROC"); + + // Oracles breakerBox = contracts.deployed("BreakerBox"); medianDeltaBreaker = contracts.deployed("MedianDeltaBreaker"); valueDeltaBreaker = contracts.deployed("ValueDeltaBreaker"); nonrecoverableValueDeltaBreaker = contracts.deployed("NonrecoverableValueDeltaBreaker"); + sortedOraclesProxy = contracts.celoRegistry("SortedOracles"); + + // Swaps brokerProxy = contracts.deployed("BrokerProxy"); biPoolManagerProxy = contracts.deployed("BiPoolManagerProxy"); - sortedOraclesProxy = contracts.celoRegistry("SortedOracles"); + partialReserveProxy = contracts.deployed("PartialReserveProxy"); } /** @@ -133,10 +141,12 @@ contract eXOF is IMentoUpgrade, GovernanceScript { eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); proposal_initializeEXOFToken(config); - proposal_addEXOFToCeloRegistry(config); + proposal_addEXOFToCeloRegistry(); proposal_configureEXOFConstitutionParameters(); proposal_addEXOFToReserves(); proposal_enableGasPaymentsWithEXOF(); + proposal_setDailySpendingRatioForCollateralAssets(); + proposal_createExchanges(config); proposal_configureTradingLimits(config); proposal_configureBreakerBox(config); @@ -181,11 +191,11 @@ contract eXOF is IMentoUpgrade, GovernanceScript { /** * @notice Add the transaction to create a new entry for StableTokenXOF in the CeloRegistry */ - function proposal_addEXOFToCeloRegistry(eXOFConfig.eXOF memory config) private { + function proposal_addEXOFToCeloRegistry() private { transactions.push( ICeloGovernance.Transaction( 0, - config.stableTokenXOF.registryAddress, + REGISTRY_ADDRESS, abi.encodeWithSelector(IRegistry(0).setAddressFor.selector, "StableTokenXOF", eXOFProxy) ) ); @@ -195,7 +205,6 @@ contract eXOF is IMentoUpgrade, GovernanceScript { * @notice adds eXOF token to the partial and main reserve */ function proposal_addEXOFToReserves() private { - address payable partialReserveProxy = contracts.deployed("PartialReserveProxy"); if (IReserve(partialReserveProxy).isStableAsset(eXOFProxy) == false) { transactions.push( ICeloGovernance.Transaction( @@ -237,7 +246,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { } /** - * @notice configure eXOF constitution parameters see cBRl GCP for reference + * @notice configure eXOF constitution parameters + * @dev see cBRl GCP(https://celo.stake.id/#/proposal/49) for reference */ function proposal_configureEXOFConstitutionParameters() private { bytes4[] memory functionSelectors = Arrays.bytes4s( @@ -248,6 +258,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { getSelector("approve(address,uint256)") ); uint256[] memory thresholds = Arrays.uints(0.9 * 1e24, 0.6 * 1e24, 0.6 * 1e24, 0.6 * 1e24, 0.6 * 1e24); + address governanceProxy = contracts.celoRegistry("Governance"); for (uint256 i = 0; i < functionSelectors.length; i++) { @@ -266,6 +277,29 @@ contract eXOF is IMentoUpgrade, GovernanceScript { } } + /** + * @notice This function creates the transaction to set the daily spending ratio for all collateral assets + * including the newly added EuroC. + */ + function proposal_setDailySpendingRatioForCollateralAssets() private { + uint256 dailySpendingRatio = 1e24; + + address[] memory collateralAssets = Arrays.addresses(celo, contracts.dependency("BridgedUSDC"), bridgedEUROC); + uint256[] memory dailySpendingRatios = Arrays.uints(dailySpendingRatio, dailySpendingRatio, dailySpendingRatio); + + transactions.push( + ICeloGovernance.Transaction( + 0, + partialReserveProxy, + abi.encodeWithSelector( + Reserve(0).setDailySpendingRatioForCollateralAssets.selector, + collateralAssets, + dailySpendingRatios + ) + ) + ); + } + /** * @notice Creates the exchanges for the new pools. */ From 42fad5bf459dc9b501e9e7c8004c70bc13ad04f8 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 24 Aug 2023 19:54:34 -0500 Subject: [PATCH 13/64] refactor: update get x change id function --- script/upgrades/eXOF/Config.sol | 10 +++++----- script/upgrades/eXOF/eXOF.sol | 17 ++++++----------- script/upgrades/eXOF/eXOFChecks.sol | 5 +++-- 3 files changed, 14 insertions(+), 18 deletions(-) diff --git a/script/upgrades/eXOF/Config.sol b/script/upgrades/eXOF/Config.sol index 2db7a28a..05e7e0e7 100644 --- a/script/upgrades/eXOF/Config.sol +++ b/script/upgrades/eXOF/Config.sol @@ -39,7 +39,7 @@ library eXOFConfig { config.pools[0] = config.eXOFCelo = eXOFCelo_PoolConfig(contracts); config.pools[1] = config.eXOFEUROC = eXOFEUROC_PoolConfig(contracts); - config.rateFeeds = new Config.RateFeed[](3); + config.rateFeeds = new Config.RateFeed[](2); config.rateFeeds[0] = config.CELOXOF = CELOXOF_RateFeedConfig(contracts); config.rateFeeds[1] = config.EUROXOF = EUROXOF_RateFeedConfig(contracts); @@ -54,7 +54,7 @@ library eXOFConfig { function CELOXOF_RateFeedConfig( Contracts.Cache storage contracts ) internal view returns (Config.RateFeed memory rateFeedConfig) { - rateFeedConfig.rateFeedID = contracts.celoRegistry("StableTokenXOF"); + rateFeedConfig.rateFeedID = contracts.deployed("StableTokenXOFProxy"); rateFeedConfig.medianDeltaBreaker0 = Config.MedianDeltaBreaker({ enabled: true, threshold: FixidityLib.newFixedFraction(3, 100), // 0.03 @@ -95,14 +95,14 @@ library eXOFConfig { Contracts.Cache storage contracts ) internal view returns (Config.Pool memory poolConfig) { poolConfig = Config.Pool({ - asset0: contracts.celoRegistry("StableTokenXOF"), + asset0: contracts.deployed("StableTokenXOFProxy"), asset1: contracts.celoRegistry("GoldToken"), isConstantSum: false, spread: FixidityLib.newFixedFraction(50, 10_000), // 0.0050 referenceRateResetFrequency: 5 minutes, minimumReports: 5, stablePoolResetSize: 656 * 250_000 * 1e18, // 164 million - referenceRateFeedID: contracts.celoRegistry("StableTokenXOF"), + referenceRateFeedID: contracts.deployed("StableTokenXOFProxy"), asset0limits: Config.TradingLimit({ enabled0: true, timeStep0: 5 minutes, @@ -135,7 +135,7 @@ library eXOFConfig { */ function eXOFEUROC_PoolConfig(Contracts.Cache storage contracts) internal returns (Config.Pool memory poolConfig) { poolConfig = Config.Pool({ - asset0: contracts.celoRegistry("StableTokenXOF"), + asset0: contracts.deployed("StableTokenXOFProxy"), asset1: contracts.dependency("BridgedEUROC"), isConstantSum: true, spread: FixidityLib.newFixedFraction(25, 10000), // 0.0025 diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index afa7a9b4..9da8b1bb 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -46,7 +46,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { ICeloGovernance.Transaction[] private transactions; - address private eXOF; + address private eXOFToken; address payable private eXOFProxy; address private celo; address private bridgedEUROC; @@ -88,7 +88,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { */ function setAddresses() public { // Tokens - eXOF = contracts.deployed("StableTokenXOF"); + eXOFToken = contracts.deployed("StableTokenXOF"); eXOFProxy = contracts.deployed("StableTokenXOFProxy"); celo = contracts.celoRegistry("GoldToken"); bridgedEUROC = contracts.dependency("BridgedEUROC"); @@ -117,7 +117,6 @@ contract eXOF is IMentoUpgrade, GovernanceScript { // Set the exchange ID for the reference rate feed for (uint i = 0; i < config.pools.length; i++) { referenceRateFeedIDToExchangeId[config.pools[i].referenceRateFeedID] = getExchangeId( - config.pools[i].asset0, config.pools[i].asset1, config.pools[i].isConstantSum ); @@ -141,7 +140,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); proposal_initializeEXOFToken(config); - proposal_addEXOFToCeloRegistry(); + proposal_addEXOFToCeloRegistry(); //TODO(Bayo): registry was already updated on testnet before this was added. How? proposal_configureEXOFConstitutionParameters(); proposal_addEXOFToReserves(); proposal_enableGasPaymentsWithEXOF(); @@ -167,7 +166,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { eXOFProxy, abi.encodeWithSelector( _eXOFProxy._setAndInitializeImplementation.selector, - eXOF, + eXOFToken, abi.encodeWithSelector( StableTokenXOF(0).initialize.selector, config.stableTokenXOF.name, @@ -610,14 +609,10 @@ contract eXOF is IMentoUpgrade, GovernanceScript { /** * @notice Helper function to get the exchange ID for a pool. */ - function getExchangeId(address asset0, address asset1, bool isConstantSum) internal view returns (bytes32) { + function getExchangeId(address asset1, bool isConstantSum) internal view returns (bytes32) { return keccak256( - abi.encodePacked( - IERC20Metadata(asset0).symbol(), - IERC20Metadata(asset1).symbol(), - isConstantSum ? "ConstantSum" : "ConstantProduct" - ) + abi.encodePacked("eXOF", IERC20Metadata(asset1).symbol(), isConstantSum ? "ConstantSum" : "ConstantProduct") ); } diff --git a/script/upgrades/eXOF/eXOFChecks.sol b/script/upgrades/eXOF/eXOFChecks.sol index 5aee1128..45213160 100644 --- a/script/upgrades/eXOF/eXOFChecks.sol +++ b/script/upgrades/eXOF/eXOFChecks.sol @@ -110,6 +110,7 @@ contract eXOFChecks is Script, Test { function run() public { setUp(); + console.log("\nStarting eXOF checks: \n"); verifyOwner(); verifyEXOFStableToken(); verifyExchanges(); @@ -126,7 +127,7 @@ contract eXOFChecks is Script, Test { ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).owner() == governance, "Nonrecoverable Value Delta Breaker ownership not transferred to governance" ); - console.log("Contract ownerships transferred to governance 🤝"); + console.log("🟢 Contract ownerships transferred to governance \n"); } function verifyEXOFStableToken() internal view { @@ -142,7 +143,7 @@ contract eXOFChecks is Script, Test { ); revert("Deployed StableTokenXOF does not match what proxy points to. See logs."); } - console.log("\tStableTokenXOFProxy has the correct implementation address 🫡"); + console.log("🟢 StableTokenXOFProxy has the correct implementation address \n"); } /* ================================================================ */ From b7f79d3d9150401bcc9038c2bd8ea663a5a95a53 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 24 Aug 2023 20:00:57 -0500 Subject: [PATCH 14/64] merge from main --- README.md | 5 +- .../62320/run-latest.json | 233 ++++++------ .../62320/run-latest.json | 241 ++++++++---- script/dev/dev-CreateMockBridgedEUROC.sol | 24 ++ script/dev/dev-FundPartialReserve.sol | 4 +- script/upgrades/MU03/Config.sol | 46 ++- script/upgrades/MU03/MU03.sol | 238 +++++++----- script/upgrades/MU03/MU03Checks.sol | 354 +++++++++++------- .../deploy/MU03-02-Create-Implementations.sol | 8 + script/upgrades/dependencies.json | 6 +- script/utils/Arrays.sol | 24 +- 11 files changed, 775 insertions(+), 408 deletions(-) create mode 100644 script/dev/dev-CreateMockBridgedEUROC.sol diff --git a/README.md b/README.md index 332e17f4..9797be11 100644 --- a/README.md +++ b/README.md @@ -67,8 +67,9 @@ Check the script file for more details on usage but here's a quick overview: ================================================================== 👇 Pick a script to run ------------------------------------------------------------------ -1) AddOtherReserveAddress 3) DrainPartialReserve -2) CreateMockBridgedUSDC 4) FundPartialReserve +1) AddOtherReserveAddress 4) CreateMockBridgedUSDC +2) ChangeTestnetMockBridgedUSDC 5) DrainPartialReserve +3) CreateMockBridgedEUROC 6) FundPartialReserve #? # Run a development script by index diff --git a/broadcast/MU03-01-Create-Nonupgradeable-Contracts.sol/62320/run-latest.json b/broadcast/MU03-01-Create-Nonupgradeable-Contracts.sol/62320/run-latest.json index e090bd21..89622dcc 100644 --- a/broadcast/MU03-01-Create-Nonupgradeable-Contracts.sol/62320/run-latest.json +++ b/broadcast/MU03-01-Create-Nonupgradeable-Contracts.sol/62320/run-latest.json @@ -1,10 +1,10 @@ { "transactions": [ { - "hash": "0x583c8e509298606257155561ac7cd5fd35233da0c10ddd268245db2dd977cd86", + "hash": "0xc6bee716532a994d5e64ea8fed2056aa0af3c18e5c2ac9002936b0ec8d185e87", "transactionType": "CREATE", "contractName": "BreakerBox", - "contractAddress": "0x34292A3dECAD80258733070CD074e34E70477a1e", + "contractAddress": "0x5Ea5A5F694F10de979BEeC7b8041E9f931F54bc7", "function": null, "arguments": [ "[]", @@ -13,19 +13,19 @@ "transaction": { "type": "0x00", "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "gas": "0x2da9c8", + "gas": "0x2e9bf6", "value": "0x0", - "data": "0x60806040523480156200001157600080fd5b5060405162002e7738038062002e77833981810160405260408110156200003757600080fd5b81019080805160405193929190846401000000008211156200005857600080fd5b9083019060208201858111156200006e57600080fd5b82518660208202830111640100000000821117156200008c57600080fd5b82525081516020918201928201910280838360005b83811015620000bb578181015183820152602001620000a1565b50505050919091016040525060200151915060009050620000e46001600160e01b036200016116565b600080546001600160a01b0319166001600160a01b03831690811782556040519293509160008051602062002de4833981519152908290a35062000131336001600160e01b036200016516565b62000145816001600160e01b03620001f616565b62000159826001600160e01b03620002db16565b505062000637565b3390565b6001600160a01b038116620001ac5760405162461bcd60e51b815260040180806020018281038252602681526020018062002d9e6026913960400191505060405180910390fd5b600080546040516001600160a01b038085169392169160008051602062002de483398151915291a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b620002096001600160e01b036200036e16565b6200024a576040805162461bcd60e51b8152602060048201819052602482015260008051602062002dc4833981519152604482015290519081900360640190fd5b6001600160a01b038116620002915760405162461bcd60e51b815260040180806020018281038252602181526020018062002e276021913960400191505060405180910390fd5b600880546001600160a01b0319166001600160a01b0383169081179091556040517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f735390600090a250565b620002ee6001600160e01b036200036e16565b6200032f576040805162461bcd60e51b8152602060048201819052602482015260008051602062002dc4833981519152604482015290519081900360640190fd5b60005b81518110156200036a57620003618282815181106200034d57fe5b60200260200101516200039d60201b60201c565b60010162000332565b5050565b600080546001600160a01b03166200038e6001600160e01b036200016116565b6001600160a01b031614905090565b620003b06001600160e01b036200036e16565b620003f1576040805162461bcd60e51b8152602060048201819052602482015260008051602062002dc4833981519152604482015290519081900360640190fd5b6001600160a01b03811660009081526002602052604090205460ff16156200044b5760405162461bcd60e51b815260040180806020018281038252602381526020018062002e046023913960400191505060405180910390fd5b60085460408051638e74928160e01b81526001600160a01b03848116600483015291516000939290921691638e749281916024808201928692909190829003018186803b1580156200049c57600080fd5b505afa158015620004b1573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526020811015620004db57600080fd5b8101908080516040519392919084640100000000821115620004fc57600080fd5b9083019060208201858111156200051257600080fd5b82518660208202830111640100000000821117156200053057600080fd5b82525081516020918201928201910280838360005b838110156200055f57818101518382015260200162000545565b505050509050016040525050505111620005ab5760405162461bcd60e51b815260040180806020018281038252602f81526020018062002e48602f913960400191505060405180910390fd5b6001805480820182557fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf60180546001600160a01b0319166001600160a01b038416908117909155600081815260026020526040808220805460ff1916909417909355915190917fa1bccd87833fab06528ad8412cd349ff6ec2f1b851f48592a05ff995e4e7347d91a250565b61275780620006476000396000f3fe608060405234801561001057600080fd5b50600436106101b95760003560e01c8063607e4569116100f95780638f32d59b11610097578063c0b05da011610071578063c0b05da014610630578063c4bb759b14610656578063f2fde38b1461067c578063ff7bffa1146106a2576101b9565b80638f32d59b146105a7578063ab02e6c0146105af578063b5b01283146105d5576101b9565b806385c89866116100d357806385c89866146104d657806387efb0b5146104f35780638c892d3d146105735780638da5cb5b1461059f576101b9565b8063607e456914610405578063715018a61461042b578063793cef5114610433576101b9565b806327fd631111610166578063360e10ae11610140578063360e10ae146103595780633ed739c31461037f5780634afb215e146103a55780635727caef146103cb576101b9565b806327fd6311146102e65780632e730a8e146103225780632eeae9961461032a576101b9565b8063132e8aa711610197578063132e8aa71461024d5780631d82c3a31461027157806321a2d9d01461028e576101b9565b80630308422e146101be57806309833c3e146101ef5780630c60714614610215575b600080fd5b6101ed600480360360408110156101d457600080fd5b5080356001600160a01b0316906020013560ff166106d0565b005b6101ed6004803603602081101561020557600080fd5b50356001600160a01b03166107f7565b6101ed6004803603606081101561022b57600080fd5b506001600160a01b038135811691602081013590911690604001351515610ad9565b610255610d8c565b604080516001600160a01b039092168252519081900360200190f35b6102556004803603602081101561028757600080fd5b5035610d9b565b610296610dc2565b60408051602080825283518183015283519192839290830191858101910280838360005b838110156102d25781810151838201526020016102ba565b505050509050019250505060405180910390f35b61030c600480360360208110156102fc57600080fd5b50356001600160a01b0316610e25565b6040805160ff9092168252519081900360200190f35b610296610e3a565b6101ed6004803603604081101561034057600080fd5b5080356001600160a01b0316906020013560ff16610e9a565b6101ed6004803603602081101561036f57600080fd5b50356001600160a01b031661102b565b61030c6004803603602081101561039557600080fd5b50356001600160a01b03166112ac565b6101ed600480360360208110156103bb57600080fd5b50356001600160a01b03166112c1565b6103f1600480360360208110156103e157600080fd5b50356001600160a01b03166113c1565b604080519115158252519081900360200190f35b6103f16004803603602081101561041b57600080fd5b50356001600160a01b03166113d6565b6101ed611433565b6101ed6004803603602081101561044957600080fd5b81019060208101813564010000000081111561046457600080fd5b82018360208201111561047657600080fd5b8035906020019184602083028401116401000000008311171561049857600080fd5b9190808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152509295506114ee945050505050565b610255600480360360208110156104ec57600080fd5b503561157b565b6101ed6004803603604081101561050957600080fd5b6001600160a01b03823516919081019060408101602082013564010000000081111561053457600080fd5b82018360208201111561054657600080fd5b8035906020019184602083028401116401000000008311171561056857600080fd5b509092509050611588565b6102556004803603604081101561058957600080fd5b506001600160a01b0381351690602001356116c6565b6102556116fb565b6103f161170a565b6101ed600480360360208110156105c557600080fd5b50356001600160a01b031661172e565b610603600480360360408110156105eb57600080fd5b506001600160a01b038135811691602001351661180a565b6040805160ff909416845267ffffffffffffffff9092166020840152151582820152519081900360600190f35b61030c6004803603602081101561064657600080fd5b50356001600160a01b031661184c565b6101ed6004803603602081101561066c57600080fd5b50356001600160a01b031661195c565b6101ed6004803603602081101561069257600080fd5b50356001600160a01b0316611c5c565b6103f1600480360360408110156106b857600080fd5b506001600160a01b0381358116916020013516611cc1565b6106d861170a565b610729576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03821660009081526002602052604090205460ff16610796576040805162461bcd60e51b815260206004820152601f60248201527f52617465206665656420494420686173206e6f74206265656e20616464656400604482015290519081900360640190fd5b6001600160a01b038216600081815260046020908152604091829020805460ff191660ff8616908117909155825190815291517fb64ea6f0b71eb82019a4e1cb18612c962bf400a2333377020f4a9ab71eeeeb529281900390910190a25050565b6107ff61170a565b610850576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03811660009081526002602052604090205460ff16156108a85760405162461bcd60e51b81526004018080602001828103825260238152602001806126b06023913960400191505060405180910390fd5b600854604080517f8e7492810000000000000000000000000000000000000000000000000000000081526001600160a01b03848116600483015291516000939290921691638e749281916024808201928692909190829003018186803b15801561091157600080fd5b505afa158015610925573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052602081101561096c57600080fd5b810190808051604051939291908464010000000082111561098c57600080fd5b9083019060208201858111156109a157600080fd5b82518660208202830111640100000000821117156109be57600080fd5b82525081516020918201928201910280838360005b838110156109eb5781810151838201526020016109d3565b505050509050016040525050505111610a355760405162461bcd60e51b815260040180806020018281038252602f8152602001806126f4602f913960400191505060405180910390fd5b6001805480820182557fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf60180547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b038416908117909155600081815260026020526040808220805460ff1916909417909355915190917fa1bccd87833fab06528ad8412cd349ff6ec2f1b851f48592a05ff995e4e7347d91a250565b610ae161170a565b610b32576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03821660009081526002602052604090205460ff16610b9f576040805162461bcd60e51b815260206004820152601f60248201527f52617465206665656420494420686173206e6f74206265656e20616464656400604482015290519081900360640190fd5b610ba8836113d6565b610be35760405162461bcd60e51b815260040180806020018281038252603181526020018061265c6031913960400191505060405180910390fd5b6001600160a01b0380831660009081526003602090815260408083209387168352929052205460ff69010000000000000000009091041615158115151415610c72576040805162461bcd60e51b815260206004820181905260248201527f427265616b657220697320616c726561647920696e2074686973207374617465604482015290519081900360640190fd5b8015610cd8576001600160a01b03828116600090815260036020908152604080832093871683529290522080547fffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff16690100000000000000000083151502179055610d3c565b6001600160a01b038083166000908152600360209081526040808320938716835292905290812080547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055610d2e83611cfe565b9050610d3a83826106d0565b505b604080516001600160a01b038086168252841660208201528215158183015290517f292d7648986a4abc017bc2a39852a675c1e325e24afd18fad659810792d5e4059181900360600190a1505050565b6008546001600160a01b031681565b60018181548110610da857fe5b6000918252602090912001546001600160a01b0316905081565b60606007805480602002602001604051908101604052809291908181526020018280548015610e1a57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311610dfc575b505050505090505b90565b60046020526000908152604090205460ff1681565b60606001805480602002602001604051908101604052809291908181526020018280548015610e1a576020028201919060005260206000209081546001600160a01b03168152600190910190602001808311610dfc575050505050905090565b610ea261170a565b610ef3576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b818160ff16610f01826113d6565b15610f3d5760405162461bcd60e51b815260040180806020018281038252602381526020018061268d6023913960400191505060405180910390fd5b67ffffffffffffffff8116610f835760405162461bcd60e51b815260040180806020018281038252602f815260200180612607602f913960400191505060405180910390fd5b6001600160a01b038416600081815260066020526040808220805460ff191660ff8816179055600780546001810182559083527fa66cc928b5edb82af9bd49922954155ab7b0942694bea4ce44661d9a8736c6880180547fffffffffffffffffffffffff00000000000000000000000000000000000000001684179055517fb41d9a8e03d4798a0a905017e377ecae53ebc5ca694c8fccaeabb5a08c0d333f9190a250505050565b61103361170a565b611084576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6000805b6001548110156110d457826001600160a01b0316600182815481106110a957fe5b6000918252602090912001546001600160a01b031614156110cc578091506110d4565b600101611088565b50816001600160a01b0316600182815481106110ec57fe5b6000918252602090912001546001600160a01b031614611153576040805162461bcd60e51b815260206004820152601f60248201527f52617465206665656420494420686173206e6f74206265656e20616464656400604482015290519081900360640190fd5b6001805460009161116a919063ffffffff611dd016565b90508082146111d5576001818154811061118057fe5b600091825260209091200154600180546001600160a01b0390921691849081106111a657fe5b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055505b60018054806111e057fe5b6000828152602080822083017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690559092019092556001600160a01b03851682526004905260409020805460ff1916905561126183611e19565b6001600160a01b038316600081815260026020526040808220805460ff19169055517f2646cbfbc7a17246cd5998517025a987bbdc416a91f2482601aeb30045d388199190a2505050565b60066020526000908152604090205460ff1681565b6112c961170a565b61131a576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03811661135f5760405162461bcd60e51b81526004018080602001828103825260218152602001806126d36021913960400191505060405180910390fd5b600880547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383169081179091556040517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f735390600090a250565b60026020526000908152604090205460ff1681565b6000805b60075481101561142857826001600160a01b0316600782815481106113fb57fe5b6000918252602090912001546001600160a01b0316141561142057600191505061142e565b6001016113da565b50600090505b919050565b61143b61170a565b61148c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b6114f661170a565b611547576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60005b81518110156115775761156f82828151811061156257fe5b60200260200101516107f7565b60010161154a565b5050565b60078181548110610da857fe5b61159061170a565b6115e1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03831660009081526002602052604090205460ff1661164e576040805162461bcd60e51b815260206004820152601f60248201527f52617465206665656420494420686173206e6f74206265656e20616464656400604482015290519081900360640190fd5b6001600160a01b038316600090815260056020526040902061167190838361252f565b50818160405180838360200280828437604051920182900382209450506001600160a01b03871692507f01ebc358c2c8d23692013d9ef4f803f9e0f60486a319faa591e1f84fd08fcd529150600090a3505050565b600560205281600052604060002081815481106116df57fe5b6000918252602090912001546001600160a01b03169150829050565b6000546001600160a01b031690565b600080546001600160a01b031661171f611f06565b6001600160a01b031614905090565b6000805b6007548110156117dc576001600160a01b0383166000908152600360205260408120600780549192918490811061176557fe5b60009182526020808320909101546001600160a01b0316835282019290925260400190205460ff690100000000000000000090910416156117d45760006117cd84600784815481106117b357fe5b6000918252602090912001546001600160a01b0316611f0a565b9290921791505b600101611732565b506001600160a01b03919091166000908152600460205260409020805460ff191660ff909216919091179055565b600360209081526000928352604080842090915290825290205460ff8082169167ffffffffffffffff6101008204169169010000000000000000009091041683565b6001600160a01b03811660009081526002602052604081205460ff166118b9576040805162461bcd60e51b815260206004820152601f60248201527f52617465206665656420494420686173206e6f74206265656e20616464656400604482015290519081900360640190fd5b6001600160a01b03821660009081526004602052604081205460ff16905b6001600160a01b038416600090815260056020526040902054811015611955576001600160a01b0384166000908152600560205260408120805460049291908490811061192057fe5b60009182526020808320909101546001600160a01b0316835282019290925260400190205460ff1691909117906001016118d7565b5092915050565b61196461170a565b6119b5576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6000805b600754811015611a0557826001600160a01b0316600782815481106119da57fe5b6000918252602090912001546001600160a01b031614156119fd57809150611a05565b6001016119b9565b50816001600160a01b031660078281548110611a1d57fe5b6000918252602090912001546001600160a01b031614611a84576040805162461bcd60e51b815260206004820152601a60248201527f427265616b657220686173206e6f74206265656e206164646564000000000000604482015290519081900360640190fd5b60005b600154811015611b20576003600060018381548110611aa257fe5b60009182526020808320909101546001600160a01b039081168452838201949094526040928301822093871682529290925290205460ff69010000000000000000009091041615611b1857611b188360018381548110611afe57fe5b60009182526020822001546001600160a01b031690610ad9565b600101611a87565b506001600160a01b0382166000908152600660205260408120805460ff19169055600754611b5590600163ffffffff611dd016565b9050808214611bc05760078181548110611b6b57fe5b600091825260209091200154600780546001600160a01b039092169184908110611b9157fe5b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055505b6007805480611bcb57fe5b60008281526020812082017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690559091019091556040516001600160a01b038516917f25d0fcab10ffc3ea7a197ec99e51df0362a1485e3a020caa618dbf72f92bb9f391a2505050565b611c6461170a565b611cb5576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b611cbe81611f55565b50565b6001600160a01b038181166000908152600360209081526040808320938616835292905220546901000000000000000000900460ff165b92915050565b600080805b600754811015611955576001600160a01b03841660009081526003602052604081206007805491929184908110611d3657fe5b60009182526020808320909101546001600160a01b0316835282019290925260400190205460ff69010000000000000000009091041615611dc8576001600160a01b03841660009081526003602052604081206007805491929184908110611d9a57fe5b60009182526020808320909101546001600160a01b0316835282019290925260400190205460ff1691909117905b600101611d03565b6000611e1283836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525061200d565b9392505050565b60005b600754811015611577576001600160a01b03821660009081526003602052604081206007805491929184908110611e4f57fe5b60009182526020808320909101546001600160a01b0316835282019290925260400190205460ff69010000000000000000009091041615611efe576001600160a01b03821660009081526003602052604081206007805491929184908110611eb357fe5b60009182526020808320909101546001600160a01b03168352820192909252604001902080547fffffffffffffffffffffffffffffffffffffffffffff000000000000000000001690555b600101611e1c565b3390565b6001600160a01b03808316600090815260036020908152604080832093851683529290529081205460ff1615611f4b57611f4483836120a4565b9050611cf8565b611e128383612391565b6001600160a01b038116611f9a5760405162461bcd60e51b81526004018080602001828103825260268152602001806126366026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b6000818484111561209c5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b83811015612061578181015183820152602001612049565b50505050905090810190601f16801561208e5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b60006120ae6125aa565b506001600160a01b0380841660008181526003602090815260408083209487168084529482528083208151606081018352905460ff808216835267ffffffffffffffff6101008304168386015269010000000000000000009091041615158183015281517f39b84ecf000000000000000000000000000000000000000000000000000000008152600481019590955290519094879490926339b84ecf92602480840193829003018186803b15801561216557600080fd5b505afa158015612179573d6000803e3d6000fd5b505050506040513d602081101561218f57600080fd5b5051905080158015906121c1575060208301516121bd90829067ffffffffffffffff1663ffffffff6124d516565b4210155b1561231e57816001600160a01b03166368b89d58876040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b03168152602001915050602060405180830381600087803b15801561221e57600080fd5b505af1158015612232573d6000803e3d6000fd5b505050506040513d602081101561224857600080fd5b5051156122d8576001600160a01b038681166000818152600360209081526040808320948a168084529490915280822080547fffffffffffffffffffffffffffffffffffffffffffffff000000000000000000166101004267ffffffffffffffff1602179055517fd45bd915ab99a070b980cdf13e671da6b79cc32e66eff6dc12c83a92071e6ab39190a3612319565b846001600160a01b0316866001600160a01b03167f90ca142474a3987fe4ec5cb24a254e13086fb998251070b5c9fc8ab70d78b8af60405160405180910390a35b61235f565b846001600160a01b0316866001600160a01b03167f636207d0069f1a3500c8d1676c804bc9d9a9d27e9add85139022a1757edf552260405160405180910390a35b505050506001600160a01b03918216600090815260036020908152604080832093909416825291909152205460ff1690565b604080517ffd165f530000000000000000000000000000000000000000000000000000000081526001600160a01b0384811660048301529151600092839285929183169163fd165f539160248082019260209290919082900301818887803b1580156123fc57600080fd5b505af1158015612410573d6000803e3d6000fd5b505050506040513d602081101561242657600080fd5b5051156124cd576001600160a01b03848116600081815260066020908152604080832054948a1680845260038352818420858552909252808320805460ff90961660ff1990961686177fffffffffffffffffffffffffffffffffffffffffffffff0000000000000000ff166101004267ffffffffffffffff160217905551939550927fe59f00019fc03badf2caa7d5de220ccfa5a411564a41f3b15906c02fd20150d59190a35b509392505050565b600082820183811015611e12576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b82805482825590600052602060002090810192821561259a579160200282015b8281111561259a5781547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0384351617825560209092019160019091019061254f565b506125a69291506125ca565b5090565b604080516060810182526000808252602082018190529181019190915290565b610e2291905b808211156125a65780547fffffffffffffffffffffffff00000000000000000000000000000000000000001681556001016125d056fe5468652064656661756c742074726164696e67206d6f64652063616e206e6f742068617665206120627265616b65724f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573735468697320627265616b657220686173206e6f74206265656e20616464656420746f2074686520427265616b6572426f785468697320627265616b65722068617320616c7265616479206265656e2061646465645261746520666565642049442068617320616c7265616479206265656e206164646564536f727465644f7261636c65732061646472657373206d7573742062652073657452617465206665656420494420646f6573206e6f74206578697374206173206974206861732030206f7261636c6573a265627a7a723158206eacd5475a180b4511b11492b29756fb1f20b9c05e02ebfdd7a3c7853849067a64736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573734f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65728be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e05261746520666565642049442068617320616c7265616479206265656e206164646564536f727465644f7261636c65732061646472657373206d7573742062652073657452617465206665656420494420646f6573206e6f74206578697374206173206974206861732030206f7261636c6573000000000000000000000000000000000000000000000000000000000000004000000000000000000000000088a187a876290e9843175027902b9f7f1b092c880000000000000000000000000000000000000000000000000000000000000000", - "nonce": "0x233" + "data": "0x60806040523480156200001157600080fd5b5060405162002f5438038062002f54833981810160405260408110156200003757600080fd5b81019080805160405193929190846401000000008211156200005857600080fd5b9083019060208201858111156200006e57600080fd5b82518660208202830111640100000000821117156200008c57600080fd5b82525081516020918201928201910280838360005b83811015620000bb578181015183820152602001620000a1565b50505050919091016040525060200151915060009050620000e46001600160e01b036200016116565b600080546001600160a01b0319166001600160a01b03831690811782556040519293509160008051602062002ec1833981519152908290a35062000131336001600160e01b036200016516565b62000145816001600160e01b03620001f616565b62000159826001600160e01b03620002db16565b505062000637565b3390565b6001600160a01b038116620001ac5760405162461bcd60e51b815260040180806020018281038252602681526020018062002e7b6026913960400191505060405180910390fd5b600080546040516001600160a01b038085169392169160008051602062002ec183398151915291a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b620002096001600160e01b036200036e16565b6200024a576040805162461bcd60e51b8152602060048201819052602482015260008051602062002ea1833981519152604482015290519081900360640190fd5b6001600160a01b038116620002915760405162461bcd60e51b815260040180806020018281038252602181526020018062002f046021913960400191505060405180910390fd5b600880546001600160a01b0319166001600160a01b0383169081179091556040517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f735390600090a250565b620002ee6001600160e01b036200036e16565b6200032f576040805162461bcd60e51b8152602060048201819052602482015260008051602062002ea1833981519152604482015290519081900360640190fd5b60005b81518110156200036a57620003618282815181106200034d57fe5b60200260200101516200039d60201b60201c565b60010162000332565b5050565b600080546001600160a01b03166200038e6001600160e01b036200016116565b6001600160a01b031614905090565b620003b06001600160e01b036200036e16565b620003f1576040805162461bcd60e51b8152602060048201819052602482015260008051602062002ea1833981519152604482015290519081900360640190fd5b6001600160a01b03811660009081526002602052604090205460ff16156200044b5760405162461bcd60e51b815260040180806020018281038252602381526020018062002ee16023913960400191505060405180910390fd5b60085460408051638e74928160e01b81526001600160a01b03848116600483015291516000939290921691638e749281916024808201928692909190829003018186803b1580156200049c57600080fd5b505afa158015620004b1573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526020811015620004db57600080fd5b8101908080516040519392919084640100000000821115620004fc57600080fd5b9083019060208201858111156200051257600080fd5b82518660208202830111640100000000821117156200053057600080fd5b82525081516020918201928201910280838360005b838110156200055f57818101518382015260200162000545565b505050509050016040525050505111620005ab5760405162461bcd60e51b815260040180806020018281038252602f81526020018062002f25602f913960400191505060405180910390fd5b6001805480820182557fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf60180546001600160a01b0319166001600160a01b038416908117909155600081815260026020526040808220805460ff1916909417909355915190917fa1bccd87833fab06528ad8412cd349ff6ec2f1b851f48592a05ff995e4e7347d91a250565b61283480620006476000396000f3fe608060405234801561001057600080fd5b50600436106101b95760003560e01c8063607e4569116100f95780638f32d59b11610097578063c0b05da011610071578063c0b05da014610630578063c4bb759b14610656578063f2fde38b1461067c578063ff7bffa1146106a2576101b9565b80638f32d59b146105a7578063ab02e6c0146105af578063b5b01283146105d5576101b9565b806385c89866116100d357806385c89866146104d657806387efb0b5146104f35780638c892d3d146105735780638da5cb5b1461059f576101b9565b8063607e456914610405578063715018a61461042b578063793cef5114610433576101b9565b806327fd631111610166578063360e10ae11610140578063360e10ae146103595780633ed739c31461037f5780634afb215e146103a55780635727caef146103cb576101b9565b806327fd6311146102e65780632e730a8e146103225780632eeae9961461032a576101b9565b8063132e8aa711610197578063132e8aa71461024d5780631d82c3a31461027157806321a2d9d01461028e576101b9565b80630308422e146101be57806309833c3e146101ef5780630c60714614610215575b600080fd5b6101ed600480360360408110156101d457600080fd5b5080356001600160a01b0316906020013560ff166106d0565b005b6101ed6004803603602081101561020557600080fd5b50356001600160a01b03166107f7565b6101ed6004803603606081101561022b57600080fd5b506001600160a01b038135811691602081013590911690604001351515610ad9565b610255610d95565b604080516001600160a01b039092168252519081900360200190f35b6102556004803603602081101561028757600080fd5b5035610da4565b610296610dcb565b60408051602080825283518183015283519192839290830191858101910280838360005b838110156102d25781810151838201526020016102ba565b505050509050019250505060405180910390f35b61030c600480360360208110156102fc57600080fd5b50356001600160a01b0316610e2e565b6040805160ff9092168252519081900360200190f35b610296610e43565b6101ed6004803603604081101561034057600080fd5b5080356001600160a01b0316906020013560ff16610ea3565b6101ed6004803603602081101561036f57600080fd5b50356001600160a01b0316611034565b61030c6004803603602081101561039557600080fd5b50356001600160a01b03166112d6565b6101ed600480360360208110156103bb57600080fd5b50356001600160a01b03166112eb565b6103f1600480360360208110156103e157600080fd5b50356001600160a01b03166113eb565b604080519115158252519081900360200190f35b6103f16004803603602081101561041b57600080fd5b50356001600160a01b0316611400565b6101ed61145d565b6101ed6004803603602081101561044957600080fd5b81019060208101813564010000000081111561046457600080fd5b82018360208201111561047657600080fd5b8035906020019184602083028401116401000000008311171561049857600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550611518945050505050565b610255600480360360208110156104ec57600080fd5b50356115a5565b6101ed6004803603604081101561050957600080fd5b6001600160a01b03823516919081019060408101602082013564010000000081111561053457600080fd5b82018360208201111561054657600080fd5b8035906020019184602083028401116401000000008311171561056857600080fd5b5090925090506115b2565b6102556004803603604081101561058957600080fd5b506001600160a01b0381351690602001356116f0565b610255611725565b6103f1611734565b6101ed600480360360208110156105c557600080fd5b50356001600160a01b0316611758565b610603600480360360408110156105eb57600080fd5b506001600160a01b03813581169160200135166117ad565b6040805160ff909416845267ffffffffffffffff9092166020840152151582820152519081900360600190f35b61030c6004803603602081101561064657600080fd5b50356001600160a01b03166117ef565b6101ed6004803603602081101561066c57600080fd5b50356001600160a01b03166118ff565b6101ed6004803603602081101561069257600080fd5b50356001600160a01b0316611bff565b6103f1600480360360408110156106b857600080fd5b506001600160a01b0381358116916020013516611c61565b6106d8611734565b610729576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03821660009081526002602052604090205460ff16610796576040805162461bcd60e51b815260206004820152601f60248201527f52617465206665656420494420686173206e6f74206265656e20616464656400604482015290519081900360640190fd5b6001600160a01b038216600081815260046020908152604091829020805460ff191660ff8616908117909155825190815291517fb64ea6f0b71eb82019a4e1cb18612c962bf400a2333377020f4a9ab71eeeeb529281900390910190a25050565b6107ff611734565b610850576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03811660009081526002602052604090205460ff16156108a85760405162461bcd60e51b815260040180806020018281038252602381526020018061278d6023913960400191505060405180910390fd5b600854604080517f8e7492810000000000000000000000000000000000000000000000000000000081526001600160a01b03848116600483015291516000939290921691638e749281916024808201928692909190829003018186803b15801561091157600080fd5b505afa158015610925573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052602081101561096c57600080fd5b810190808051604051939291908464010000000082111561098c57600080fd5b9083019060208201858111156109a157600080fd5b82518660208202830111640100000000821117156109be57600080fd5b82525081516020918201928201910280838360005b838110156109eb5781810151838201526020016109d3565b505050509050016040525050505111610a355760405162461bcd60e51b815260040180806020018281038252602f8152602001806127d1602f913960400191505060405180910390fd5b6001805480820182557fb10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf60180547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b038416908117909155600081815260026020526040808220805460ff1916909417909355915190917fa1bccd87833fab06528ad8412cd349ff6ec2f1b851f48592a05ff995e4e7347d91a250565b610ae1611734565b610b32576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03821660009081526002602052604090205460ff16610b9f576040805162461bcd60e51b815260206004820152601f60248201527f52617465206665656420494420686173206e6f74206265656e20616464656400604482015290519081900360640190fd5b610ba883611400565b610be35760405162461bcd60e51b81526004018080602001828103825260318152602001806127396031913960400191505060405180910390fd5b6001600160a01b0380831660009081526003602090815260408083209387168352929052205460ff69010000000000000000009091041615158115151415610c72576040805162461bcd60e51b815260206004820181905260248201527f427265616b657220697320616c726561647920696e2074686973207374617465604482015290519081900360640190fd5b8015610ce1576001600160a01b03828116600090815260036020908152604080832093871683529290522080547fffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff16690100000000000000000083151502179055610cdc82611c9e565b610d45565b6001600160a01b038083166000908152600360209081526040808320938716835292905290812080547fffffffffffffffffffffffffffffffffffffffffffff00000000000000000000169055610d3783611d7a565b9050610d4383826106d0565b505b604080516001600160a01b038086168252841660208201528215158183015290517f292d7648986a4abc017bc2a39852a675c1e325e24afd18fad659810792d5e4059181900360600190a1505050565b6008546001600160a01b031681565b60018181548110610db157fe5b6000918252602090912001546001600160a01b0316905081565b60606007805480602002602001604051908101604052809291908181526020018280548015610e2357602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311610e05575b505050505090505b90565b60046020526000908152604090205460ff1681565b60606001805480602002602001604051908101604052809291908181526020018280548015610e23576020028201919060005260206000209081546001600160a01b03168152600190910190602001808311610e05575050505050905090565b610eab611734565b610efc576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b818160ff16610f0a82611400565b15610f465760405162461bcd60e51b815260040180806020018281038252602381526020018061276a6023913960400191505060405180910390fd5b67ffffffffffffffff8116610f8c5760405162461bcd60e51b815260040180806020018281038252602f8152602001806126bb602f913960400191505060405180910390fd5b6001600160a01b038416600081815260066020526040808220805460ff191660ff8816179055600780546001810182559083527fa66cc928b5edb82af9bd49922954155ab7b0942694bea4ce44661d9a8736c6880180547fffffffffffffffffffffffff00000000000000000000000000000000000000001684179055517fb41d9a8e03d4798a0a905017e377ecae53ebc5ca694c8fccaeabb5a08c0d333f9190a250505050565b61103c611734565b61108d576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6000805b6001548110156110dd57826001600160a01b0316600182815481106110b257fe5b6000918252602090912001546001600160a01b031614156110d5578091506110dd565b600101611091565b50816001600160a01b0316600182815481106110f557fe5b6000918252602090912001546001600160a01b03161461115c576040805162461bcd60e51b815260206004820152601f60248201527f52617465206665656420494420686173206e6f74206265656e20616464656400604482015290519081900360640190fd5b60018054600091611173919063ffffffff611e4c16565b90508082146111de576001818154811061118957fe5b600091825260209091200154600180546001600160a01b0390921691849081106111af57fe5b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055505b60018054806111e957fe5b6000828152602080822083017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690559092019092556001600160a01b03851682526005905260408120611262916125ab565b6001600160a01b0383166000908152600460205260409020805460ff1916905561128b83611e95565b6001600160a01b038316600081815260026020526040808220805460ff19169055517f2646cbfbc7a17246cd5998517025a987bbdc416a91f2482601aeb30045d388199190a2505050565b60066020526000908152604090205460ff1681565b6112f3611734565b611344576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b0381166113895760405162461bcd60e51b81526004018080602001828103825260218152602001806127b06021913960400191505060405180910390fd5b600880547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383169081179091556040517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f735390600090a250565b60026020526000908152604090205460ff1681565b6000805b60075481101561145257826001600160a01b03166007828154811061142557fe5b6000918252602090912001546001600160a01b0316141561144a576001915050611458565b600101611404565b50600090505b919050565b611465611734565b6114b6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b611520611734565b611571576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60005b81518110156115a15761159982828151811061158c57fe5b60200260200101516107f7565b600101611574565b5050565b60078181548110610db157fe5b6115ba611734565b61160b576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03831660009081526002602052604090205460ff16611678576040805162461bcd60e51b815260206004820152601f60248201527f52617465206665656420494420686173206e6f74206265656e20616464656400604482015290519081900360640190fd5b6001600160a01b038316600090815260056020526040902061169b9083836125c9565b50818160405180838360200280828437604051920182900382209450506001600160a01b03871692507f01ebc358c2c8d23692013d9ef4f803f9e0f60486a319faa591e1f84fd08fcd529150600090a3505050565b6005602052816000526040600020818154811061170957fe5b6000918252602090912001546001600160a01b03169150829050565b6000546001600160a01b031690565b600080546001600160a01b0316611749611f82565b6001600160a01b031614905090565b6008546001600160a01b031633146117a15760405162461bcd60e51b81526004018080602001828103825260298152602001806127106029913960400191505060405180910390fd5b6117aa81611c9e565b50565b600360209081526000928352604080842090915290825290205460ff8082169167ffffffffffffffff6101008204169169010000000000000000009091041683565b6001600160a01b03811660009081526002602052604081205460ff1661185c576040805162461bcd60e51b815260206004820152601f60248201527f52617465206665656420494420686173206e6f74206265656e20616464656400604482015290519081900360640190fd5b6001600160a01b03821660009081526004602052604081205460ff16905b6001600160a01b0384166000908152600560205260409020548110156118f8576001600160a01b038416600090815260056020526040812080546004929190849081106118c357fe5b60009182526020808320909101546001600160a01b0316835282019290925260400190205460ff16919091179060010161187a565b5092915050565b611907611734565b611958576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6000805b6007548110156119a857826001600160a01b03166007828154811061197d57fe5b6000918252602090912001546001600160a01b031614156119a0578091506119a8565b60010161195c565b50816001600160a01b0316600782815481106119c057fe5b6000918252602090912001546001600160a01b031614611a27576040805162461bcd60e51b815260206004820152601a60248201527f427265616b657220686173206e6f74206265656e206164646564000000000000604482015290519081900360640190fd5b60005b600154811015611ac3576003600060018381548110611a4557fe5b60009182526020808320909101546001600160a01b039081168452838201949094526040928301822093871682529290925290205460ff69010000000000000000009091041615611abb57611abb8360018381548110611aa157fe5b60009182526020822001546001600160a01b031690610ad9565b600101611a2a565b506001600160a01b0382166000908152600660205260408120805460ff19169055600754611af890600163ffffffff611e4c16565b9050808214611b635760078181548110611b0e57fe5b600091825260209091200154600780546001600160a01b039092169184908110611b3457fe5b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055505b6007805480611b6e57fe5b60008281526020812082017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690559091019091556040516001600160a01b038516917f25d0fcab10ffc3ea7a197ec99e51df0362a1485e3a020caa618dbf72f92bb9f391a2505050565b611c07611734565b611c58576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6117aa81611f86565b6001600160a01b038181166000908152600360209081526040808320938616835292905220546901000000000000000000900460ff165b92915050565b6000805b600754811015611d4c576001600160a01b03831660009081526003602052604081206007805491929184908110611cd557fe5b60009182526020808320909101546001600160a01b0316835282019290925260400190205460ff69010000000000000000009091041615611d44576000611d3d8460078481548110611d2357fe5b6000918252602090912001546001600160a01b031661203e565b9290921791505b600101611ca2565b506001600160a01b03919091166000908152600460205260409020805460ff191660ff909216919091179055565b600080805b6007548110156118f8576001600160a01b03841660009081526003602052604081206007805491929184908110611db257fe5b60009182526020808320909101546001600160a01b0316835282019290925260400190205460ff69010000000000000000009091041615611e44576001600160a01b03841660009081526003602052604081206007805491929184908110611e1657fe5b60009182526020808320909101546001600160a01b0316835282019290925260400190205460ff1691909117905b600101611d7f565b6000611e8e83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250612089565b9392505050565b60005b6007548110156115a1576001600160a01b03821660009081526003602052604081206007805491929184908110611ecb57fe5b60009182526020808320909101546001600160a01b0316835282019290925260400190205460ff69010000000000000000009091041615611f7a576001600160a01b03821660009081526003602052604081206007805491929184908110611f2f57fe5b60009182526020808320909101546001600160a01b03168352820192909252604001902080547fffffffffffffffffffffffffffffffffffffffffffff000000000000000000001690555b600101611e98565b3390565b6001600160a01b038116611fcb5760405162461bcd60e51b81526004018080602001828103825260268152602001806126ea6026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b6001600160a01b03808316600090815260036020908152604080832093851683529290529081205460ff161561207f576120788383612120565b9050611c98565b611e8e838361240d565b600081848411156121185760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156120dd5781810151838201526020016120c5565b50505050905090810190601f16801561210a5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b600061212a612644565b506001600160a01b0380841660008181526003602090815260408083209487168084529482528083208151606081018352905460ff808216835267ffffffffffffffff6101008304168386015269010000000000000000009091041615158183015281517f39b84ecf000000000000000000000000000000000000000000000000000000008152600481019590955290519094879490926339b84ecf92602480840193829003018186803b1580156121e157600080fd5b505afa1580156121f5573d6000803e3d6000fd5b505050506040513d602081101561220b57600080fd5b50519050801580159061223d5750602083015161223990829067ffffffffffffffff1663ffffffff61255116565b4210155b1561239a57816001600160a01b03166368b89d58876040518263ffffffff1660e01b815260040180826001600160a01b03166001600160a01b03168152602001915050602060405180830381600087803b15801561229a57600080fd5b505af11580156122ae573d6000803e3d6000fd5b505050506040513d60208110156122c457600080fd5b505115612354576001600160a01b038681166000818152600360209081526040808320948a168084529490915280822080547fffffffffffffffffffffffffffffffffffffffffffffff000000000000000000166101004267ffffffffffffffff1602179055517fd45bd915ab99a070b980cdf13e671da6b79cc32e66eff6dc12c83a92071e6ab39190a3612395565b846001600160a01b0316866001600160a01b03167f90ca142474a3987fe4ec5cb24a254e13086fb998251070b5c9fc8ab70d78b8af60405160405180910390a35b6123db565b846001600160a01b0316866001600160a01b03167f636207d0069f1a3500c8d1676c804bc9d9a9d27e9add85139022a1757edf552260405160405180910390a35b505050506001600160a01b03918216600090815260036020908152604080832093909416825291909152205460ff1690565b604080517ffd165f530000000000000000000000000000000000000000000000000000000081526001600160a01b0384811660048301529151600092839285929183169163fd165f539160248082019260209290919082900301818887803b15801561247857600080fd5b505af115801561248c573d6000803e3d6000fd5b505050506040513d60208110156124a257600080fd5b505115612549576001600160a01b03848116600081815260066020908152604080832054948a1680845260038352818420858552909252808320805460ff90961660ff1990961686177fffffffffffffffffffffffffffffffffffffffffffffff0000000000000000ff166101004267ffffffffffffffff160217905551939550927fe59f00019fc03badf2caa7d5de220ccfa5a411564a41f3b15906c02fd20150d59190a35b509392505050565b600082820183811015611e8e576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b50805460008255906000526020600020908101906117aa9190612664565b828054828255906000526020600020908101928215612634579160200282015b828111156126345781547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b038435161782556020909201916001909101906125e9565b5061264092915061267e565b5090565b604080516060810182526000808252602082018190529181019190915290565b610e2b91905b80821115612640576000815560010161266a565b610e2b91905b808211156126405780547fffffffffffffffffffffffff000000000000000000000000000000000000000016815560010161268456fe5468652064656661756c742074726164696e67206d6f64652063616e206e6f742068617665206120627265616b65724f776e61626c653a206e6577206f776e657220697320746865207a65726f206164647265737343616c6c6572206d7573742062652074686520536f727465644f7261636c657320636f6e74726163745468697320627265616b657220686173206e6f74206265656e20616464656420746f2074686520427265616b6572426f785468697320627265616b65722068617320616c7265616479206265656e2061646465645261746520666565642049442068617320616c7265616479206265656e206164646564536f727465644f7261636c65732061646472657373206d7573742062652073657452617465206665656420494420646f6573206e6f74206578697374206173206974206861732030206f7261636c6573a265627a7a723158207e8d4fe74ce1df28dcf6a785e6ee0f4a5055279ad0c1d681a72a63da71bcd0cf64736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573734f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65728be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e05261746520666565642049442068617320616c7265616479206265656e206164646564536f727465644f7261636c65732061646472657373206d7573742062652073657452617465206665656420494420646f6573206e6f74206578697374206173206974206861732030206f7261636c6573000000000000000000000000000000000000000000000000000000000000004000000000000000000000000088a187a876290e9843175027902b9f7f1b092c880000000000000000000000000000000000000000000000000000000000000000", + "nonce": "0x276" }, "additionalContracts": [], "isFixedGasLimit": false }, { - "hash": "0x86247baafc339f3b4d1b3a56367cd6254ee2d595ac166a0824912ea8e510f811", + "hash": "0x9dd8dd06ed0e023dd0ec389a99e01aa4515991fecc76728843c8ff60ebfe450d", "transactionType": "CALL", "contractName": "BreakerBox", - "contractAddress": "0x34292A3dECAD80258733070CD074e34E70477a1e", + "contractAddress": "0x5Ea5A5F694F10de979BEeC7b8041E9f931F54bc7", "function": "transferOwnership(address)", "arguments": [ "0x28443b1d87db521320a6517A4F1B6Ead77F8C811" @@ -33,25 +33,26 @@ "transaction": { "type": "0x00", "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "to": "0x34292a3decad80258733070cd074e34e70477a1e", + "to": "0x5ea5a5f694f10de979beec7b8041e9f931f54bc7", "gas": "0x9aef", "value": "0x0", "data": "0xf2fde38b00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811", - "nonce": "0x234" + "nonce": "0x277" }, "additionalContracts": [], "isFixedGasLimit": false }, { - "hash": "0xde534fd0d6cb4392130408effcb451cea051111cf891381cfe032d2c2779ced5", + "hash": "0xfb88c90066e7685c3c9d796e5c3d0d191ad6fee9044a2d35c7ce633a6df77f6d", "transactionType": "CREATE", "contractName": "MedianDeltaBreaker", - "contractAddress": "0x1a10C5E4d366E2F10E4447E30b738eB4a0FD7843", + "contractAddress": "0x286a8137EE9EE6dE8B5e5be334706fA812400994", "function": null, "arguments": [ "0", "0", "0x88A187a876290E9843175027902B9f7f1B092c88", + "0x5Ea5A5F694F10de979BEeC7b8041E9f931F54bc7", "[]", "[]", "[]" @@ -59,19 +60,19 @@ "transaction": { "type": "0x00", "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "gas": "0x2498b1", + "gas": "0x2648fc", "value": "0x0", - "data": "0x60806040523480156200001157600080fd5b506040516200291238038062002912833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b50505050905001604052505050600062000207620002ca60201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620028d1833981519152908290a35062000258336001600160e01b03620002ce16565b6200026c846001600160e01b036200036016565b62000280866001600160e01b036200046016565b62000294856001600160e01b036200049b16565b620002a983836001600160e01b036200057916565b620002be83826001600160e01b03620007c716565b505050505050620009f1565b3390565b6001600160a01b038116620003155760405162461bcd60e51b8152600401808060200182810382526026815260200180620028ab6026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620028d183398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b620003736001600160e01b036200096416565b620003c5576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b0381166200040c5760405162461bcd60e51b8152600401808060200182810382526021815260200180620028f16021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004b1816200099560201b620013931760201c565b51600255620004f1620004cf620009b1602090811b620013ad17901c565b6040805160208082019092526002548152919062001c7f620009d7821b17901c565b62000543576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005d0576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007c25760006001600160a01b0316838281518110620005f557fe5b60200260200101516001600160a01b031614156200064e576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000658620009de565b620006828383815181106200066957fe5b60200260200101516200099560201b620013931760201c565b9050620006b26200069d620009b160201b620013ad1760201c565b82620009d760201b62001c7f1790919060201c565b62000704576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200071657fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200077957fe5b60200260200101518484815181106200078e57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005d3565b505050565b80518251146200081e576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007c25760006001600160a01b03168382815181106200084357fe5b60200260200101516001600160a01b031614156200089c576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008a957fe5b602002602001015160016000858481518110620008c257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200091c57fe5b60200260200101518383815181106200093157fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a160010162000821565b6004546000906001600160a01b0316620009866001600160e01b03620002ca16565b6001600160a01b031614905090565b6200099f620009de565b50604080516020810190915290815290565b620009bb620009de565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b611eaa8062000a016000396000f3fe608060405234801561001057600080fd5b506004361061018d5760003560e01c80634e510e88116100e35780638c54acdc1161008c578063a44235cb11610066578063a44235cb146105e1578063f2fde38b146105e9578063fd165f531461061c5761018d565b80638c54acdc1461059e5780638da5cb5b146105d15780638f32d59b146105d95761018d565b806368b89d58116100bd57806368b89d5814610510578063715018a614610557578063753d8c2f1461055f5761018d565b80634e510e88146103fe57806353f5d6f1146104c05780635ac3ff70146104f35761018d565b806313df95c9116101455780633151e2201161011f5780633151e2201461035f57806339b84ecf146103985780634afb215e146103cb5761018d565b806313df95c9146102f15780631893304f146103245780632e37ff73146103575761018d565b80630c62541e116101765780630c62541e146102735780630f42151f1461028d578063132e8aa7146102c05761018d565b8063020323dd1461019257806305e0478514610256575b600080fd5b610254600480360360408110156101a857600080fd5b8101906020810181356401000000008111156101c357600080fd5b8201836020820111156101d557600080fd5b803590602001918460208302840111640100000000831117156101f757600080fd5b91939092909160208101903564010000000081111561021557600080fd5b82018360208201111561022757600080fd5b8035906020019184602083028401116401000000008311171561024957600080fd5b50909250905061064f565b005b6102546004803603602081101561026c57600080fd5b503561071b565b61027b610780565b60408051918252519081900360200190f35b61027b600480360360208110156102a357600080fd5b503573ffffffffffffffffffffffffffffffffffffffff1661078e565b6102c86107a0565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b61027b6004803603602081101561030757600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107bc565b61027b6004803603602081101561033a57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff1661081c565b61027b61082e565b6102546004803603604081101561037557600080fd5b5073ffffffffffffffffffffffffffffffffffffffff8135169060200135610834565b61027b600480360360208110156103ae57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610971565b610254600480360360208110156103e157600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166109a6565b6102546004803603604081101561041457600080fd5b81019060208101813564010000000081111561042f57600080fd5b82018360208201111561044157600080fd5b8035906020019184602083028401116401000000008311171561046357600080fd5b91939092909160208101903564010000000081111561048157600080fd5b82018360208201111561049357600080fd5b803590602001918460208302840111640100000000831117156104b557600080fd5b509092509050610aca565b61027b600480360360208110156104d657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610b90565b6102546004803603602081101561050957600080fd5b5035610ba2565b6105436004803603602081101561052657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610c04565b604080519115158252519081900360200190f35b610254610c16565b6105436004803603606081101561057557600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610cde565b61027b600480360360208110156105b457600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610df0565b6102c8610e02565b610543610e1e565b61027b610e5e565b610254600480360360208110156105ff57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610e64565b6105436004803603602081101561063257600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610ec6565b610657610e1e565b6106a8576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107158484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061106892505050565b50505050565b610723610e1e565b610774576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077d816112d4565b50565b69d3c21bcecceda100000081565b60076020526000908152604090205481565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600660209081526040808320815192830190915254815281906107fa9061138f565b9050806108145769d3c21bcecceda1000000915050610817565b90505b919050565b60036020526000908152604090205481565b60005481565b61083c610e1e565b61088d576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610895611dfa565b61089e82611393565b90506108b86108ab6113ad565b829063ffffffff6113d116565b610909576040805162461bcd60e51b815260206004820152601d60248201527f536d6f6f7468696e6720666163746f72206d757374206265203c3d2031000000604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff8316600081815260066020908152604091829020845190558151928352820184905280517f6024a1181d4b6670f0122b1101b175bd17051e91a5b57e85972a9187c3f9721c9281900390910190a1505050565b73ffffffffffffffffffffffffffffffffffffffff811660009081526001602052604081205480610814575050600054610817565b6109ae610e1e565b6109ff576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff8116610a515760405162461bcd60e51b8152600401808060200182810382526021815260200180611e556021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b610ad2610e1e565b610b23576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610715848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113de92505050565b60016020526000908152604090205481565b610baa610e1e565b610bfb576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077d816115bf565b6000610c0f82610ec6565b1592915050565b610c1e610e1e565b610c6f576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610cfc9061138f565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610d3c9061138f565b90508015610d48578091505b6000610d5a610d556113ad565b61138f565b90506000610d6e828563ffffffff6115fa16565b90506000610d9c69d3c21bcecceda1000000610d908b8563ffffffff61165b16565b9063ffffffff6116b416565b90506000610db0848763ffffffff6116f616565b90506000610dd269d3c21bcecceda1000000610d908d8563ffffffff61165b16565b9050808a1080610de15750828a115b9b9a5050505050505050505050565b60066020526000908152604090205481565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610e42611738565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610e6c610e1e565b610ebd576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077d8161173c565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610f3957600080fd5b505afa158015610f4d573d6000803e3d6000fd5b505050506040513d6040811015610f6357600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526007602052604090205490915080610fc4575073ffffffffffffffffffffffffffffffffffffffff83166000908152600760205260408120919091559050610817565b610fcc611dfa565b610fdd610fd8866107bc565b611393565b905061102e610d5561101561100084610ff46113ad565b9063ffffffff61181c16565b61100986611393565b9063ffffffff61189416565b6110228461100988611393565b9063ffffffff611c0616565b73ffffffffffffffffffffffffffffffffffffffff861660009081526007602052604090205561105f828487610cde565b95945050505050565b80518251146110be576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112cf57600073ffffffffffffffffffffffffffffffffffffffff168382815181106110ee57fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff16141561115f576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b611167611dfa565b61118383838151811061117657fe5b6020026020010151611393565b905061119d6111906113ad565b829063ffffffff611c7f16565b6111ee576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111ff57fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061127b57fe5b602002602001015184848151811061128f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110c1565b505050565b6112dd81611393565b516002556113086112ec6113ad565b604080516020810190915260025481529063ffffffff611c7f16565b611359576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b5190565b61139b611dfa565b50604080516020810190915290815290565b6113b5611dfa565b50604080516020810190915269d3c21bcecceda1000000815290565b8051825111155b92915050565b8051825114611434576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112cf57600073ffffffffffffffffffffffffffffffffffffffff1683828151811061146457fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114d5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114e157fe5b6020026020010151600160008584815181106114f957fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061156c57fe5b602002602001015183838151811061158057fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611437565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b600082820183811015611654576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b9392505050565b60008261166a575060006113d8565b8282028284828161167757fe5b04146116545760405162461bcd60e51b8152600401808060200182810382526021815260200180611e346021913960400191505060405180910390fd5b600061165483836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250611c86565b600061165483836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250611d28565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661178e5760405162461bcd60e51b8152600401808060200182810382526026815260200180611e0e6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b611824611dfa565b81518351101561187b576040805162461bcd60e51b815260206004820152601f60248201527f737562737472616374696f6e20756e646572666c6f7720646574656374656400604482015290519081900360640190fd5b5060408051602081019091528151835103815292915050565b61189c611dfa565b825115806118a957508151155b156118c357506040805160208101909152600081526113d8565b815169d3c21bcecceda100000014156118dd5750816113d8565b825169d3c21bcecceda100000014156118f75750806113d8565b600069d3c21bcecceda100000061190d85611d82565b518161191557fe5b049050600061192385611db7565b519050600069d3c21bcecceda100000061193c86611d82565b518161194457fe5b049050600061195286611db7565b51905083820284156119bb578285828161196857fe5b04146119bb576040805162461bcd60e51b815260206004820152601660248201527f6f766572666c6f77207831793120646574656374656400000000000000000000604482015290519081900360640190fd5b69d3c21bcecceda100000081028115611a355769d3c21bcecceda10000008282816119e257fe5b0414611a35576040805162461bcd60e51b815260206004820152601f60248201527f6f766572666c6f772078317931202a2066697865643120646574656374656400604482015290519081900360640190fd5b9050808484028515611a9e5784868281611a4b57fe5b0414611a9e576040805162461bcd60e51b815260206004820152601660248201527f6f766572666c6f77207832793120646574656374656400000000000000000000604482015290519081900360640190fd5b8684028715611b045784888281611ab157fe5b0414611b04576040805162461bcd60e51b815260206004820152601660248201527f6f766572666c6f77207831793220646574656374656400000000000000000000604482015290519081900360640190fd5b611b0c611df1565b8781611b1457fe5b049650611b1f611df1565b8581611b2757fe5b0494508685028715611b905785888281611b3d57fe5b0414611b90576040805162461bcd60e51b815260206004820152601660248201527f6f766572666c6f77207832793220646574656374656400000000000000000000604482015290519081900360640190fd5b611b98611dfa565b6040518060200160405280878152509050611bc181604051806020016040528087815250611c06565b9050611bdb81604051806020016040528086815250611c06565b9050611bf581604051806020016040528085815250611c06565b9d9c50505050505050505050505050565b611c0e611dfa565b8151835190810190811015611c6a576040805162461bcd60e51b815260206004820152601560248201527f616464206f766572666c6f772064657465637465640000000000000000000000604482015290519081900360640190fd5b60408051602081019091529081529392505050565b5190511090565b60008183611d125760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b83811015611cd7578181015183820152602001611cbf565b50505050905090810190601f168015611d045780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b506000838581611d1e57fe5b0495945050505050565b60008184841115611d7a5760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315611cd7578181015183820152602001611cbf565b505050900390565b611d8a611dfa565b604051806020016040528069d3c21bcecceda100000080856000015181611dad57fe5b0402905292915050565b611dbf611dfa565b604051806020016040528069d3c21bcecceda100000080856000015181611de257fe5b95519504029093039092525090565b64e8d4a5100090565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a7231582072bb51b4e3ea1b45d020753be3bd7ef6c48df79cae8a6c8ce54e7e7bb6652c1f64736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d757374206265207365740000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000088a187a876290e9843175027902b9f7f1b092c8800000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "nonce": "0x235" + "data": "0x60806040523480156200001157600080fd5b5060405162002b4938038062002b49833981810160405260e08110156200003757600080fd5b81516020830151604080850151606086015160808701805193519597949692959194919392820192846401000000008211156200007357600080fd5b9083019060208201858111156200008957600080fd5b8251866020820283011164010000000082111715620000a757600080fd5b82525081516020918201928201910280838360005b83811015620000d6578181015183820152602001620000bc565b50505050905001604052602001805160405193929190846401000000008211156200010057600080fd5b9083019060208201858111156200011657600080fd5b82518660208202830111640100000000821117156200013457600080fd5b82525081516020918201928201910280838360005b838110156200016357818101518382015260200162000149565b50505050905001604052602001805160405193929190846401000000008211156200018d57600080fd5b908301906020820185811115620001a357600080fd5b8251866020820283011164010000000082111715620001c157600080fd5b82525081516020918201928201910280838360005b83811015620001f0578181015183820152602001620001d6565b5050505090500160405250505060006200020f620002e760201b60201c565b600480546001600160a01b0319166001600160a01b0383169081179091556040519192509060009060008051602062002b08833981519152908290a35062000260336001600160e01b03620002eb16565b62000274856001600160e01b036200037d16565b62000288846001600160e01b036200046c16565b6200029c876001600160e01b036200057016565b620002b0866001600160e01b03620005ab16565b620002c583836001600160e01b036200068916565b620002da83826001600160e01b03620008d716565b5050505050505062000b01565b3390565b6001600160a01b038116620003325760405162461bcd60e51b815260040180806020018281038252602681526020018062002ac26026913960400191505060405180910390fd5b6004546040516001600160a01b0380841692169060008051602062002b0883398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b620003906001600160e01b0362000a7416565b620003d1576040805162461bcd60e51b8152602060048201819052602482015260008051602062002ae8833981519152604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b815260040180806020018281038252602181526020018062002b286021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b6200047f6001600160e01b0362000a7416565b620004c0576040805162461bcd60e51b8152602060048201819052602482015260008051602062002ae8833981519152604482015290519081900360640190fd5b6001600160a01b0381166200051c576040805162461bcd60e51b815260206004820152601e60248201527f427265616b6572426f782061646472657373206d757374206265207365740000604482015290519081900360640190fd5b600680546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f21921b3b46ef2c939e85d6a14410c6e3b9ce132b66e944357ff4f789f68e00e29181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620005c18162000aa560201b620014dc1760201c565b5160025562000601620005df62000ac1602090811b620014f617901c565b6040805160208082019092526002548152919062001d6062000ae7821b17901c565b62000653576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620006e0576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620008d25760006001600160a01b03168382815181106200070557fe5b60200260200101516001600160a01b031614156200075e576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b6200076862000aee565b620007928383815181106200077957fe5b602002602001015162000aa560201b620014dc1760201c565b9050620007c2620007ad62000ac160201b620014f61760201c565b8262000ae760201b62001d601790919060201c565b62000814576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200082657fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200088957fe5b60200260200101518484815181106200089e57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620006e3565b505050565b80518251146200092e576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620008d25760006001600160a01b03168382815181106200095357fe5b60200260200101516001600160a01b03161415620009ac576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620009b957fe5b602002602001015160016000858481518110620009d257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811062000a2c57fe5b602002602001015183838151811062000a4157fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a160010162000931565b6004546000906001600160a01b031662000a966001600160e01b03620002e716565b6001600160a01b031614905090565b62000aaf62000aee565b50604080516020810190915290815290565b62000acb62000aee565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b611fb18062000b116000396000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806353f5d6f1116100ee5780638da5cb5b11610097578063bfc7c45011610071578063bfc7c450146105a1578063f2fde38b146105c7578063f414c5e4146105ed578063fd165f53146105f5576101ae565b80638da5cb5b146105895780638f32d59b14610591578063a44235cb14610599576101ae565b8063715018a6116100c8578063715018a614610529578063753d8c2f146105315780638c54acdc14610563576101ae565b806353f5d6f1146104ac5780635ac3ff70146104d257806368b89d58146104ef576101ae565b806313df95c91161015b5780633151e220116101355780633151e2201461037257806339b84ecf1461039e5780634afb215e146103c45780634e510e88146103ea576101ae565b806313df95c91461031e5780631893304f146103445780632e37ff731461036a576101ae565b80630c62541e1161018c5780630c62541e146102ba5780630f42151f146102d4578063132e8aa7146102fa576101ae565b8063020323dd146101b3578063040bbd351461027757806305e047851461029d575b600080fd5b610275600480360360408110156101c957600080fd5b8101906020810181356401000000008111156101e457600080fd5b8201836020820111156101f657600080fd5b8035906020019184602083028401116401000000008311171561021857600080fd5b91939092909160208101903564010000000081111561023657600080fd5b82018360208201111561024857600080fd5b8035906020019184602083028401116401000000008311171561026a57600080fd5b50909250905061061b565b005b6102756004803603602081101561028d57600080fd5b50356001600160a01b03166106e7565b610275600480360360208110156102b357600080fd5b5035610807565b6102c261086c565b60408051918252519081900360200190f35b6102c2600480360360208110156102ea57600080fd5b50356001600160a01b031661087a565b61030261088c565b604080516001600160a01b039092168252519081900360200190f35b6102c26004803603602081101561033457600080fd5b50356001600160a01b031661089b565b6102c26004803603602081101561035a57600080fd5b50356001600160a01b03166108ee565b6102c2610900565b6102756004803603604081101561038857600080fd5b506001600160a01b038135169060200135610906565b6102c2600480360360208110156103b457600080fd5b50356001600160a01b0316610a36565b610275600480360360208110156103da57600080fd5b50356001600160a01b0316610a5e565b6102756004803603604081101561040057600080fd5b81019060208101813564010000000081111561041b57600080fd5b82018360208201111561042d57600080fd5b8035906020019184602083028401116401000000008311171561044f57600080fd5b91939092909160208101903564010000000081111561046d57600080fd5b82018360208201111561047f57600080fd5b803590602001918460208302840111640100000000831117156104a157600080fd5b509092509050610b68565b6102c2600480360360208110156104c257600080fd5b50356001600160a01b0316610c2e565b610275600480360360208110156104e857600080fd5b5035610c40565b6105156004803603602081101561050557600080fd5b50356001600160a01b0316610ca2565b604080519115158252519081900360200190f35b610275610cb4565b6105156004803603606081101561054757600080fd5b50803590602081013590604001356001600160a01b0316610d6f565b6102c26004803603602081101561057957600080fd5b50356001600160a01b0316610e74565b610302610e86565b610515610e95565b6102c2610ebb565b610275600480360360208110156105b757600080fd5b50356001600160a01b0316610ec1565b610275600480360360208110156105dd57600080fd5b50356001600160a01b0316610fc8565b61030261102a565b6105156004803603602081101561060b57600080fd5b50356001600160a01b0316611039565b610623610e95565b610674576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6106e1848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506111f292505050565b50505050565b6106ef610e95565b610740576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03811661079b576040805162461bcd60e51b815260206004820152601e60248201527f427265616b6572426f782061646472657373206d757374206265207365740000604482015290519081900360640190fd5b600680546001600160a01b0383167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f21921b3b46ef2c939e85d6a14410c6e3b9ce132b66e944357ff4f789f68e00e29181900360200190a150565b61080f610e95565b610860576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6108698161141d565b50565b69d3c21bcecceda100000081565b60086020526000908152604090205481565b6005546001600160a01b031681565b6001600160a01b0381166000908152600760209081526040808320815192830190915254815281906108cc906114d8565b9050806108e65769d3c21bcecceda10000009150506108e9565b90505b919050565b60036020526000908152604090205481565b60005481565b61090e610e95565b61095f576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610967611edb565b610970826114dc565b905061098a61097d6114f6565b829063ffffffff61151a16565b6109db576040805162461bcd60e51b815260206004820152601d60248201527f536d6f6f7468696e6720666163746f72206d757374206265203c3d2031000000604482015290519081900360640190fd5b6001600160a01b038316600081815260076020908152604091829020845190558151928352820184905280517f6024a1181d4b6670f0122b1101b175bd17051e91a5b57e85972a9187c3f9721c9281900390910190a1505050565b6001600160a01b038116600090815260016020526040812054806108e65750506000546108e9565b610a66610e95565b610ab7576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116610afc5760405162461bcd60e51b8152600401808060200182810382526021815260200180611f5c6021913960400191505060405180910390fd5b600580546001600160a01b0383167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b610b70610e95565b610bc1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6106e18484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061152792505050565b60016020526000908152604090205481565b610c48610e95565b610c99576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610869816116c7565b6000610cad82611039565b1592915050565b610cbc610e95565b610d0d576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6004546040516000916001600160a01b0316907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610d8d906114d8565b6001600160a01b0384166000908152600360209081526040808320815192830190915254815291925090610dc0906114d8565b90508015610dcc578091505b6000610dde610dd96114f6565b6114d8565b90506000610df2828563ffffffff61170216565b90506000610e2069d3c21bcecceda1000000610e148b8563ffffffff61176316565b9063ffffffff6117bc16565b90506000610e34848763ffffffff6117fe16565b90506000610e5669d3c21bcecceda1000000610e148d8563ffffffff61176316565b9050808a1080610e655750828a115b9b9a5050505050505050505050565b60076020526000908152604090205481565b6004546001600160a01b031690565b6004546000906001600160a01b0316610eac611840565b6001600160a01b031614905090565b60025481565b610ec9610e95565b610f1a576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116610f75576040805162461bcd60e51b815260206004820152601c60248201527f52617465466565642061646472657373206d7573742062652073657400000000604482015290519081900360640190fd5b6001600160a01b038116600081815260086020908152604080832092909255815192835290517f76d186fb6f7faabecd3480fe1bc33d485f376eaed587ac952f4f2e9aca4c29319281900390910190a150565b610fd0610e95565b611021576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61086981611844565b6006546001600160a01b031681565b6006546000906001600160a01b031633146110855760405162461bcd60e51b8152600401808060200182810382526026815260200180611f366026913960400191505060405180910390fd5b600554604080517fef90e1b00000000000000000000000000000000000000000000000000000000081526001600160a01b0385811660048301528251600094919091169263ef90e1b09260248082019391829003018186803b1580156110ea57600080fd5b505afa1580156110fe573d6000803e3d6000fd5b505050506040513d604081101561111457600080fd5b50516001600160a01b0384166000908152600860205260409020549091508061115b57506001600160a01b03831660009081526008602052604081209190915590506108e9565b611163611edb565b61117461116f8661089b565b6114dc565b90506111c5610dd96111ac6111978461118b6114f6565b9063ffffffff6118fd16565b6111a0866114dc565b9063ffffffff61197516565b6111b9846111a0886114dc565b9063ffffffff611ce716565b6001600160a01b0386166000908152600860205260409020556111e9828487610d6f565b95945050505050565b8051825114611248576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156114185760006001600160a01b031683828151811061126b57fe5b60200260200101516001600160a01b031614156112cf576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b6112d7611edb565b6112f38383815181106112e657fe5b60200260200101516114dc565b905061130d6113006114f6565b829063ffffffff611d6016565b61135e576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b806003600086858151811061136f57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106113d157fe5b60200260200101518484815181106113e557fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a15060010161124b565b505050565b611426816114dc565b516002556114516114356114f6565b604080516020810190915260025481529063ffffffff611d6016565b6114a2576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b5190565b6114e4611edb565b50604080516020810190915290815290565b6114fe611edb565b50604080516020810190915269d3c21bcecceda1000000815290565b8051825111155b92915050565b805182511461157d576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156114185760006001600160a01b03168382815181106115a057fe5b60200260200101516001600160a01b03161415611604576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b81818151811061161057fe5b60200260200101516001600085848151811061162857fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061168157fe5b602002602001015183838151811061169557fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a1600101611580565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b60008282018381101561175c576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b9392505050565b60008261177257506000611521565b8282028284828161177f57fe5b041461175c5760405162461bcd60e51b8152600401808060200182810382526021815260200180611f156021913960400191505060405180910390fd5b600061175c83836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250611d67565b600061175c83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250611e09565b3390565b6001600160a01b0381166118895760405162461bcd60e51b8152600401808060200182810382526026815260200180611eef6026913960400191505060405180910390fd5b6004546040516001600160a01b038084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b611905611edb565b81518351101561195c576040805162461bcd60e51b815260206004820152601f60248201527f737562737472616374696f6e20756e646572666c6f7720646574656374656400604482015290519081900360640190fd5b5060408051602081019091528151835103815292915050565b61197d611edb565b8251158061198a57508151155b156119a45750604080516020810190915260008152611521565b815169d3c21bcecceda100000014156119be575081611521565b825169d3c21bcecceda100000014156119d8575080611521565b600069d3c21bcecceda10000006119ee85611e63565b51816119f657fe5b0490506000611a0485611e98565b519050600069d3c21bcecceda1000000611a1d86611e63565b5181611a2557fe5b0490506000611a3386611e98565b5190508382028415611a9c5782858281611a4957fe5b0414611a9c576040805162461bcd60e51b815260206004820152601660248201527f6f766572666c6f77207831793120646574656374656400000000000000000000604482015290519081900360640190fd5b69d3c21bcecceda100000081028115611b165769d3c21bcecceda1000000828281611ac357fe5b0414611b16576040805162461bcd60e51b815260206004820152601f60248201527f6f766572666c6f772078317931202a2066697865643120646574656374656400604482015290519081900360640190fd5b9050808484028515611b7f5784868281611b2c57fe5b0414611b7f576040805162461bcd60e51b815260206004820152601660248201527f6f766572666c6f77207832793120646574656374656400000000000000000000604482015290519081900360640190fd5b8684028715611be55784888281611b9257fe5b0414611be5576040805162461bcd60e51b815260206004820152601660248201527f6f766572666c6f77207831793220646574656374656400000000000000000000604482015290519081900360640190fd5b611bed611ed2565b8781611bf557fe5b049650611c00611ed2565b8581611c0857fe5b0494508685028715611c715785888281611c1e57fe5b0414611c71576040805162461bcd60e51b815260206004820152601660248201527f6f766572666c6f77207832793220646574656374656400000000000000000000604482015290519081900360640190fd5b611c79611edb565b6040518060200160405280878152509050611ca281604051806020016040528087815250611ce7565b9050611cbc81604051806020016040528086815250611ce7565b9050611cd681604051806020016040528085815250611ce7565b9d9c50505050505050505050505050565b611cef611edb565b8151835190810190811015611d4b576040805162461bcd60e51b815260206004820152601560248201527f616464206f766572666c6f772064657465637465640000000000000000000000604482015290519081900360640190fd5b60408051602081019091529081529392505050565b5190511090565b60008183611df35760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b83811015611db8578181015183820152602001611da0565b50505050905090810190601f168015611de55780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b506000838581611dff57fe5b0495945050505050565b60008184841115611e5b5760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315611db8578181015183820152602001611da0565b505050900390565b611e6b611edb565b604051806020016040528069d3c21bcecceda100000080856000015181611e8e57fe5b0402905292915050565b611ea0611edb565b604051806020016040528069d3c21bcecceda100000080856000015181611ec357fe5b95519504029093039092525090565b64e8d4a5100090565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f7743616c6c6572206d7573742062652074686520427265616b6572426f7820636f6e7472616374536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a723158208d8bda0ec44c8fbae3d9e3c5d825a62d658469e57c253df5912e72312c3485a364736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573734f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65728be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d757374206265207365740000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000088a187a876290e9843175027902b9f7f1b092c880000000000000000000000005ea5a5f694f10de979beec7b8041e9f931f54bc700000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "nonce": "0x278" }, "additionalContracts": [], "isFixedGasLimit": false }, { - "hash": "0x922150ddb6c4701d37d39e194f02160dd48c062fdadb8feacff6d67d9a893db9", + "hash": "0xe8ac0792fb3991a485aee537255ce0e715851561b15c8ca47d9a97099cf8850a", "transactionType": "CALL", "contractName": "MedianDeltaBreaker", - "contractAddress": "0x1a10C5E4d366E2F10E4447E30b738eB4a0FD7843", + "contractAddress": "0x286a8137EE9EE6dE8B5e5be334706fA812400994", "function": "transferOwnership(address)", "arguments": [ "0x28443b1d87db521320a6517A4F1B6Ead77F8C811" @@ -79,29 +80,29 @@ "transaction": { "type": "0x00", "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "to": "0x1a10c5e4d366e2f10e4447e30b738eb4a0fd7843", - "gas": "0xa387", + "to": "0x286a8137ee9ee6de8b5e5be334706fa812400994", + "gas": "0xa3f1", "value": "0x0", "data": "0xf2fde38b00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811", - "nonce": "0x236" + "nonce": "0x279" }, "additionalContracts": [], "isFixedGasLimit": false }, { - "hash": "0x07719513533e2791e6898d942f29290a9f019f1f73d2b0b63a3770b3c983977c", + "hash": "0x40cbc3cd80bb734f1e61d8d5712be5f4d893f89dc493bf3ff1b8418b8fbb4e15", "transactionType": "CREATE", "contractName": "ConstantSumPricingModule", - "contractAddress": "0xA29E5C58E209bF65e8fb1F78eD543F605741b43A", + "contractAddress": "0x2901da88dd444a3c41AF51696548DEe3524Cf8Dc", "function": null, "arguments": null, "transaction": { "type": "0x00", "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "gas": "0xdb358", + "gas": "0xdb348", "value": "0x0", - "data": "0x608060405234801561001057600080fd5b50610b9b806100206000396000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c806306fdde031461004657806352707d8c14610064578063571fd01214610084575b600080fd5b61004e610097565b60405161005b9190610a3e565b60405180910390f35b6100776100723660046107a8565b6100ce565b60405161005b9190610acf565b6100776100923660046107a8565b610183565b60408051808201909152600b81527f436f6e7374616e7453756d000000000000000000000000000000000000000000602082015290565b6000816100dd5750600061017b565b6100e561078a565b6101056100f185610202565b6100f961021c565b9063ffffffff61024016565b905061010f61078a565b61012861011b856102a7565b839063ffffffff61031016565b905061013261078a565b61013e61011b886102a7565b905061014861078a565b610151896102a7565b905061017461015f826105fb565b610168846105fb565b9063ffffffff6105ff16565b9450505050505b949350505050565b6000816101925750600061017b565b61019a61078a565b6101a66100f185610202565b90506101b061078a565b6101d16101bc886102a7565b6101c5866102a7565b9063ffffffff61031016565b90506101db61078a565b6101e8836101c5896102a7565b90506101f661015f826105fb565b98975050505050505050565b61020a61078a565b50604080516020810190915290815290565b61022461078a565b50604080516020810190915269d3c21bcecceda1000000815290565b61024861078a565b81518351101561028d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610a5f565b60405180910390fd5b506040805160208101909152815183510381525b92915050565b6102af61078a565b6102b7610648565b8211156102f0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610a7f565b50604080516020810190915269d3c21bcecceda100000082028152919050565b61031861078a565b8251158061032557508151155b1561033f57506040805160208101909152600081526102a1565b815169d3c21bcecceda100000014156103595750816102a1565b825169d3c21bcecceda100000014156103735750806102a1565b600069d3c21bcecceda100000061038985610663565b518161039157fe5b049050600061039f85610698565b519050600069d3c21bcecceda10000006103b886610663565b51816103c057fe5b04905060006103ce86610698565b519050838202841561041c57828582816103e457fe5b041461041c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610a4f565b69d3c21bcecceda10000008102811561047b5769d3c21bcecceda100000082828161044357fe5b041461047b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610aaf565b90508084840285156104c9578486828161049157fe5b04146104c9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610abf565b868402871561051457848882816104dc57fe5b0414610514576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610a8f565b61051c6106d2565b878161052457fe5b04965061052f6106d2565b858161053757fe5b0494508685028715610585578588828161054d57fe5b0414610585576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610a6f565b61058d61078a565b60405180602001604052808781525090506105b6816040518060200160405280878152506106db565b90506105d0816040518060200160405280868152506106db565b90506105ea816040518060200160405280858152506106db565b9d9c50505050505050505050505050565b5190565b600061064183836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250610739565b9392505050565b7601357c299a88ea76a58924d52ce4f26a85af186c2b9e7490565b61066b61078a565b604051806020016040528069d3c21bcecceda10000008085600001518161068e57fe5b0402905292915050565b6106a061078a565b604051806020016040528069d3c21bcecceda1000000808560000151816106c357fe5b95519504029093039092525090565b64e8d4a5100090565b6106e361078a565b8151835190810190811015610724576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610a9f565b60408051602081019091529081529392505050565b60008183610774576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016102849190610a3e565b50600083858161078057fe5b0495945050505050565b6040518060200160405280600081525090565b80356102a181610b41565b600080600080608085870312156107be57600080fd5b60006107ca878761079d565b94505060206107db8782880161079d565b93505060406107ec8782880161079d565b92505060606107fd8782880161079d565b91505092959194509250565b6000610814826105fb565b61081e8185610add565b935061082e818560208601610ae9565b61083781610b19565b9093019392505050565b600061084e601683610add565b7f6f766572666c6f77207831793120646574656374656400000000000000000000815260200192915050565b6000610887601f83610add565b7f737562737472616374696f6e20756e646572666c6f7720646574656374656400815260200192915050565b60006108c0601683610add565b7f6f766572666c6f77207832793220646574656374656400000000000000000000815260200192915050565b60006108f9603683610add565b7f63616e277420637265617465206669786964697479206e756d626572206c617281527f676572207468616e206d61784e65774669786564282900000000000000000000602082015260400192915050565b6000610958601683610add565b7f6f766572666c6f77207831793220646574656374656400000000000000000000815260200192915050565b6000610991601583610add565b7f616464206f766572666c6f772064657465637465640000000000000000000000815260200192915050565b60006109ca601f83610add565b7f6f766572666c6f772078317931202a2066697865643120646574656374656400815260200192915050565b6000610a03601683610add565b7f6f766572666c6f77207832793120646574656374656400000000000000000000815260200192915050565b610a3881610ae6565b82525050565b602080825281016106418184610809565b602080825281016102a181610841565b602080825281016102a18161087a565b602080825281016102a1816108b3565b602080825281016102a1816108ec565b602080825281016102a18161094b565b602080825281016102a181610984565b602080825281016102a1816109bd565b602080825281016102a1816109f6565b602081016102a18284610a2f565b90815260200190565b90565b60005b83811015610b04578181015183820152602001610aec565b83811115610b13576000848401525b50505050565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690565b610b4a81610ae6565b8114610b5557600080fd5b5056fea365627a7a723158208788bdc5a8f5e3d0f45ed7ab33ad66f7fd6815a1657e616de9129c1b2ffc6f6f6c6578706572696d656e74616cf564736f6c63430005110040", - "nonce": "0x237" + "data": "0x608060405234801561001057600080fd5b50610b9b806100206000396000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c806306fdde031461004657806352707d8c14610064578063571fd01214610084575b600080fd5b61004e610097565b60405161005b9190610a3e565b60405180910390f35b6100776100723660046107a8565b6100ce565b60405161005b9190610acf565b6100776100923660046107a8565b610183565b60408051808201909152600b81527f436f6e7374616e7453756d000000000000000000000000000000000000000000602082015290565b6000816100dd5750600061017b565b6100e561078a565b6101056100f185610202565b6100f961021c565b9063ffffffff61024016565b905061010f61078a565b61012861011b856102a7565b839063ffffffff61031016565b905061013261078a565b61013e61011b886102a7565b905061014861078a565b610151896102a7565b905061017461015f826105fb565b610168846105fb565b9063ffffffff6105ff16565b9450505050505b949350505050565b6000816101925750600061017b565b61019a61078a565b6101a66100f185610202565b90506101b061078a565b6101d16101bc886102a7565b6101c5866102a7565b9063ffffffff61031016565b90506101db61078a565b6101e8836101c5896102a7565b90506101f661015f826105fb565b98975050505050505050565b61020a61078a565b50604080516020810190915290815290565b61022461078a565b50604080516020810190915269d3c21bcecceda1000000815290565b61024861078a565b81518351101561028d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610a5f565b60405180910390fd5b506040805160208101909152815183510381525b92915050565b6102af61078a565b6102b7610648565b8211156102f0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610a7f565b50604080516020810190915269d3c21bcecceda100000082028152919050565b61031861078a565b8251158061032557508151155b1561033f57506040805160208101909152600081526102a1565b815169d3c21bcecceda100000014156103595750816102a1565b825169d3c21bcecceda100000014156103735750806102a1565b600069d3c21bcecceda100000061038985610663565b518161039157fe5b049050600061039f85610698565b519050600069d3c21bcecceda10000006103b886610663565b51816103c057fe5b04905060006103ce86610698565b519050838202841561041c57828582816103e457fe5b041461041c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610a4f565b69d3c21bcecceda10000008102811561047b5769d3c21bcecceda100000082828161044357fe5b041461047b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610aaf565b90508084840285156104c9578486828161049157fe5b04146104c9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610abf565b868402871561051457848882816104dc57fe5b0414610514576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610a8f565b61051c6106d2565b878161052457fe5b04965061052f6106d2565b858161053757fe5b0494508685028715610585578588828161054d57fe5b0414610585576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610a6f565b61058d61078a565b60405180602001604052808781525090506105b6816040518060200160405280878152506106db565b90506105d0816040518060200160405280868152506106db565b90506105ea816040518060200160405280858152506106db565b9d9c50505050505050505050505050565b5190565b600061064183836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250610739565b9392505050565b7601357c299a88ea76a58924d52ce4f26a85af186c2b9e7490565b61066b61078a565b604051806020016040528069d3c21bcecceda10000008085600001518161068e57fe5b0402905292915050565b6106a061078a565b604051806020016040528069d3c21bcecceda1000000808560000151816106c357fe5b95519504029093039092525090565b64e8d4a5100090565b6106e361078a565b8151835190810190811015610724576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161028490610a9f565b60408051602081019091529081529392505050565b60008183610774576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016102849190610a3e565b50600083858161078057fe5b0495945050505050565b6040518060200160405280600081525090565b80356102a181610b41565b600080600080608085870312156107be57600080fd5b60006107ca878761079d565b94505060206107db8782880161079d565b93505060406107ec8782880161079d565b92505060606107fd8782880161079d565b91505092959194509250565b6000610814826105fb565b61081e8185610add565b935061082e818560208601610ae9565b61083781610b19565b9093019392505050565b600061084e601683610add565b7f6f766572666c6f77207831793120646574656374656400000000000000000000815260200192915050565b6000610887601f83610add565b7f737562737472616374696f6e20756e646572666c6f7720646574656374656400815260200192915050565b60006108c0601683610add565b7f6f766572666c6f77207832793220646574656374656400000000000000000000815260200192915050565b60006108f9603683610add565b7f63616e277420637265617465206669786964697479206e756d626572206c617281527f676572207468616e206d61784e65774669786564282900000000000000000000602082015260400192915050565b6000610958601683610add565b7f6f766572666c6f77207831793220646574656374656400000000000000000000815260200192915050565b6000610991601583610add565b7f616464206f766572666c6f772064657465637465640000000000000000000000815260200192915050565b60006109ca601f83610add565b7f6f766572666c6f772078317931202a2066697865643120646574656374656400815260200192915050565b6000610a03601683610add565b7f6f766572666c6f77207832793120646574656374656400000000000000000000815260200192915050565b610a3881610ae6565b82525050565b602080825281016106418184610809565b602080825281016102a181610841565b602080825281016102a18161087a565b602080825281016102a1816108b3565b602080825281016102a1816108ec565b602080825281016102a18161094b565b602080825281016102a181610984565b602080825281016102a1816109bd565b602080825281016102a1816109f6565b602081016102a18284610a2f565b90815260200190565b90565b60005b83811015610b04578181015183820152602001610aec565b83811115610b13576000848401525b50505050565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690565b610b4a81610ae6565b8114610b5557600080fd5b5056fea365627a7a7231582088e1d43bb0bbae670f2682884354b0cfe585b946cf1f0a78cd0c5c0085e2dd206c6578706572696d656e74616cf564736f6c63430005110040", + "nonce": "0x27a" }, "additionalContracts": [], "isFixedGasLimit": false @@ -109,226 +110,244 @@ ], "receipts": [ { - "transactionHash": "0x583c8e509298606257155561ac7cd5fd35233da0c10ddd268245db2dd977cd86", + "transactionHash": "0xc6bee716532a994d5e64ea8fed2056aa0af3c18e5c2ac9002936b0ec8d185e87", "transactionIndex": "0x0", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", "to": null, - "cumulativeGasUsed": "0x2315fc", - "gasUsed": "0x2315fc", - "contractAddress": "0x34292A3dECAD80258733070CD074e34E70477a1e", + "cumulativeGasUsed": "0x23da6f", + "gasUsed": "0x23da6f", + "contractAddress": "0x5Ea5A5F694F10de979BEeC7b8041E9f931F54bc7", "logs": [ { - "address": "0x34292A3dECAD80258733070CD074e34E70477a1e", + "address": "0x5Ea5A5F694F10de979BEeC7b8041E9f931F54bc7", "topics": [ "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", "0x0000000000000000000000000000000000000000000000000000000000000000", "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" ], "data": "0x", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", - "transactionHash": "0x583c8e509298606257155561ac7cd5fd35233da0c10ddd268245db2dd977cd86", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", + "transactionHash": "0xc6bee716532a994d5e64ea8fed2056aa0af3c18e5c2ac9002936b0ec8d185e87", "transactionIndex": "0x0", "logIndex": "0x0", "removed": false }, { - "address": "0x34292A3dECAD80258733070CD074e34E70477a1e", + "address": "0x5Ea5A5F694F10de979BEeC7b8041E9f931F54bc7", "topics": [ "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" ], "data": "0x", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", - "transactionHash": "0x583c8e509298606257155561ac7cd5fd35233da0c10ddd268245db2dd977cd86", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", + "transactionHash": "0xc6bee716532a994d5e64ea8fed2056aa0af3c18e5c2ac9002936b0ec8d185e87", "transactionIndex": "0x0", "logIndex": "0x1", "removed": false }, { - "address": "0x34292A3dECAD80258733070CD074e34E70477a1e", + "address": "0x5Ea5A5F694F10de979BEeC7b8041E9f931F54bc7", "topics": [ "0x590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f7353", "0x00000000000000000000000088a187a876290e9843175027902b9f7f1b092c88" ], "data": "0x", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", - "transactionHash": "0x583c8e509298606257155561ac7cd5fd35233da0c10ddd268245db2dd977cd86", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", + "transactionHash": "0xc6bee716532a994d5e64ea8fed2056aa0af3c18e5c2ac9002936b0ec8d185e87", "transactionIndex": "0x0", "logIndex": "0x2", "removed": false } ], "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000080000000000000020800000000000000000000000000000000000000002010000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000020000000000000200000800000400000000000000000000000000400000010000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000004000000000001000000000002000000000000000000000000000020000000", - "effectiveGasPrice": "0x1dcd6500" + "logsBloom": "0x00000000000000000000000000000000000000000000000020800000000000000000000000000000000000000002010000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000080020000000000000200000800000000000000000000000000000000400000010000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000020000004000000000001000000000002000000000000000000000000000020000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" }, { - "transactionHash": "0x86247baafc339f3b4d1b3a56367cd6254ee2d595ac166a0824912ea8e510f811", + "transactionHash": "0x9dd8dd06ed0e023dd0ec389a99e01aa4515991fecc76728843c8ff60ebfe450d", "transactionIndex": "0x1", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", - "to": "0x34292A3dECAD80258733070CD074e34E70477a1e", - "cumulativeGasUsed": "0x238628", + "to": "0x5Ea5A5F694F10de979BEeC7b8041E9f931F54bc7", + "cumulativeGasUsed": "0x244a9b", "gasUsed": "0x702c", "contractAddress": null, "logs": [ { - "address": "0x34292A3dECAD80258733070CD074e34E70477a1e", + "address": "0x5Ea5A5F694F10de979BEeC7b8041E9f931F54bc7", "topics": [ "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", "0x00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811" ], "data": "0x", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", - "transactionHash": "0x86247baafc339f3b4d1b3a56367cd6254ee2d595ac166a0824912ea8e510f811", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", + "transactionHash": "0x9dd8dd06ed0e023dd0ec389a99e01aa4515991fecc76728843c8ff60ebfe450d", "transactionIndex": "0x1", "logIndex": "0x3", "removed": false } ], "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000080000000000000020801000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000001000000000000020000000000000000000000000000000000000000000000000400000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000004000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0x1dcd6500" + "logsBloom": "0x00000000000000000000000000000000000000000000000020801000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000001000000000000020000000000000000000080000000000000000000000000000000000000000000000000000000400000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000080000004000000000000000000000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" }, { - "transactionHash": "0xde534fd0d6cb4392130408effcb451cea051111cf891381cfe032d2c2779ced5", + "transactionHash": "0xfb88c90066e7685c3c9d796e5c3d0d191ad6fee9044a2d35c7ce633a6df77f6d", "transactionIndex": "0x2", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", "to": null, - "cumulativeGasUsed": "0x3f9888", - "gasUsed": "0x1c1260", - "contractAddress": "0x1a10C5E4d366E2F10E4447E30b738eB4a0FD7843", + "cumulativeGasUsed": "0x41bdd3", + "gasUsed": "0x1d7338", + "contractAddress": "0x286a8137EE9EE6dE8B5e5be334706fA812400994", "logs": [ { - "address": "0x1a10C5E4d366E2F10E4447E30b738eB4a0FD7843", + "address": "0x286a8137EE9EE6dE8B5e5be334706fA812400994", "topics": [ "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", "0x0000000000000000000000000000000000000000000000000000000000000000", "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" ], "data": "0x", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", - "transactionHash": "0xde534fd0d6cb4392130408effcb451cea051111cf891381cfe032d2c2779ced5", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", + "transactionHash": "0xfb88c90066e7685c3c9d796e5c3d0d191ad6fee9044a2d35c7ce633a6df77f6d", "transactionIndex": "0x2", "logIndex": "0x4", "removed": false }, { - "address": "0x1a10C5E4d366E2F10E4447E30b738eB4a0FD7843", + "address": "0x286a8137EE9EE6dE8B5e5be334706fA812400994", "topics": [ "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" ], "data": "0x", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", - "transactionHash": "0xde534fd0d6cb4392130408effcb451cea051111cf891381cfe032d2c2779ced5", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", + "transactionHash": "0xfb88c90066e7685c3c9d796e5c3d0d191ad6fee9044a2d35c7ce633a6df77f6d", "transactionIndex": "0x2", "logIndex": "0x5", "removed": false }, { - "address": "0x1a10C5E4d366E2F10E4447E30b738eB4a0FD7843", + "address": "0x286a8137EE9EE6dE8B5e5be334706fA812400994", "topics": [ "0x590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f7353" ], "data": "0x00000000000000000000000088a187a876290e9843175027902b9f7f1b092c88", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", - "transactionHash": "0xde534fd0d6cb4392130408effcb451cea051111cf891381cfe032d2c2779ced5", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", + "transactionHash": "0xfb88c90066e7685c3c9d796e5c3d0d191ad6fee9044a2d35c7ce633a6df77f6d", "transactionIndex": "0x2", "logIndex": "0x6", "removed": false }, { - "address": "0x1a10C5E4d366E2F10E4447E30b738eB4a0FD7843", + "address": "0x286a8137EE9EE6dE8B5e5be334706fA812400994", + "topics": [ + "0x21921b3b46ef2c939e85d6a14410c6e3b9ce132b66e944357ff4f789f68e00e2" + ], + "data": "0x0000000000000000000000005ea5a5f694f10de979beec7b8041e9f931f54bc7", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", + "transactionHash": "0xfb88c90066e7685c3c9d796e5c3d0d191ad6fee9044a2d35c7ce633a6df77f6d", + "transactionIndex": "0x2", + "logIndex": "0x7", + "removed": false + }, + { + "address": "0x286a8137EE9EE6dE8B5e5be334706fA812400994", "topics": [ "0x9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a2" ], "data": "0x0000000000000000000000000000000000000000000000000000000000000000", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", - "transactionHash": "0xde534fd0d6cb4392130408effcb451cea051111cf891381cfe032d2c2779ced5", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", + "transactionHash": "0xfb88c90066e7685c3c9d796e5c3d0d191ad6fee9044a2d35c7ce633a6df77f6d", "transactionIndex": "0x2", - "logIndex": "0x7", + "logIndex": "0x8", "removed": false }, { - "address": "0x1a10C5E4d366E2F10E4447E30b738eB4a0FD7843", + "address": "0x286a8137EE9EE6dE8B5e5be334706fA812400994", "topics": [ "0xd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d" ], "data": "0x0000000000000000000000000000000000000000000000000000000000000000", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", - "transactionHash": "0xde534fd0d6cb4392130408effcb451cea051111cf891381cfe032d2c2779ced5", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", + "transactionHash": "0xfb88c90066e7685c3c9d796e5c3d0d191ad6fee9044a2d35c7ce633a6df77f6d", "transactionIndex": "0x2", - "logIndex": "0x8", + "logIndex": "0x9", "removed": false } ], "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000022800000000001004000000000000000000000000000010000000000001000000000000000000000000000000000000000000000000000000001000000000000000000000000000000800000020000000000000200000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000800000000000000000000008000000000000000000000000000000000000000000000000000000000000200000000000000000000000004000000000000020000004000000000001000000000000000000000000000000000000000020000000", - "effectiveGasPrice": "0x1dcd6500" + "logsBloom": "0x00000000000002000000000000000000000000000000000062800000000000000000000000000000000000000000010000000000001000000000000000000000000400000000000000000000000000000001000000000000000000000000000000800000020000000000400200000800000000000000000000000000000000400000000000000000001000000000000000000000000000000000000000000000800000000000000000000008000000000000000000000000000000000000000400000000000000000000000000000000000000000000004000000000000020000004000000000001000000000000000000000000000000000000000020000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" }, { - "transactionHash": "0x922150ddb6c4701d37d39e194f02160dd48c062fdadb8feacff6d67d9a893db9", + "transactionHash": "0xe8ac0792fb3991a485aee537255ce0e715851561b15c8ca47d9a97099cf8850a", "transactionIndex": "0x3", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", - "to": "0x1a10C5E4d366E2F10E4447E30b738eB4a0FD7843", - "cumulativeGasUsed": "0x400859", - "gasUsed": "0x6fd1", + "to": "0x286a8137EE9EE6dE8B5e5be334706fA812400994", + "cumulativeGasUsed": "0x422dec", + "gasUsed": "0x7019", "contractAddress": null, "logs": [ { - "address": "0x1a10C5E4d366E2F10E4447E30b738eB4a0FD7843", + "address": "0x286a8137EE9EE6dE8B5e5be334706fA812400994", "topics": [ "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", "0x00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811" ], "data": "0x", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", - "transactionHash": "0x922150ddb6c4701d37d39e194f02160dd48c062fdadb8feacff6d67d9a893db9", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", + "transactionHash": "0xe8ac0792fb3991a485aee537255ce0e715851561b15c8ca47d9a97099cf8850a", "transactionIndex": "0x3", - "logIndex": "0x9", + "logIndex": "0xa", "removed": false } ], "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000020801000000001004000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000001000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000080000004000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0x1dcd6500" + "logsBloom": "0x00000000000000000000000000000000000000000000000020801000000000000000000000000000000000000000010000000000000000000000000000000000000400000000000000000000000000000001000000000000020000000000000000000000000000000000400000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000080000004000000000000000000000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" }, { - "transactionHash": "0x07719513533e2791e6898d942f29290a9f019f1f73d2b0b63a3770b3c983977c", + "transactionHash": "0x40cbc3cd80bb734f1e61d8d5712be5f4d893f89dc493bf3ff1b8418b8fbb4e15", "transactionIndex": "0x4", - "blockHash": "0x34cc18b4d478f9cdfa41522edfd54117aa585ed24c8d3c0f5496e98107f1e9c0", - "blockNumber": "0x1156369", + "blockHash": "0x963a6e156f0e4fb75b89da7b120b7e15c0615d0e3786024f7e7448192134a386", + "blockNumber": "0x1216d24", "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", "to": null, - "cumulativeGasUsed": "0x4a924e", - "gasUsed": "0xa89f5", - "contractAddress": "0xA29E5C58E209bF65e8fb1F78eD543F605741b43A", + "cumulativeGasUsed": "0x4cb7d5", + "gasUsed": "0xa89e9", + "contractAddress": "0x2901da88dd444a3c41AF51696548DEe3524Cf8Dc", "logs": [], "status": "0x1", "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0x1dcd6500" + "type": "0x0", + "effectiveGasPrice": "0xbebc200" } ], "libraries": [ @@ -337,8 +356,8 @@ ], "pending": [], "returns": {}, - "timestamp": 1688646296, + "timestamp": 1692627889, "chain": 62320, "multi": false, - "commit": "df51287" + "commit": "b396ea6" } \ No newline at end of file diff --git a/broadcast/MU03-02-Create-Implementations.sol/62320/run-latest.json b/broadcast/MU03-02-Create-Implementations.sol/62320/run-latest.json index 18e146f7..9f85bafe 100644 --- a/broadcast/MU03-02-Create-Implementations.sol/62320/run-latest.json +++ b/broadcast/MU03-02-Create-Implementations.sol/62320/run-latest.json @@ -1,10 +1,10 @@ { "transactions": [ { - "hash": "0xbe304071d7b24f6a9480ad68a32ef1521f8987daea1acb162a208d41017be192", + "hash": "0xfb2a45b97150c1a180d6df81f4f00e94dc58cd936b1ddd88fddcdec4c52061ae", "transactionType": "CREATE", "contractName": "BiPoolManager", - "contractAddress": "0x7B0C742c350d68986027e36bd337328Cb390c3d4", + "contractAddress": "0xf0e764Da1E61Bd5421692e5d02bdad9f3B09f825", "function": null, "arguments": [ "false" @@ -12,19 +12,19 @@ "transaction": { "type": "0x00", "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "gas": "0x47692d", + "gas": "0x48cdc3", "value": "0x0", - "data": "0x60806040523480156200001157600080fd5b50604051620040fa380380620040fa8339810160408190526200003491620000cf565b808062000049576000805460ff191660011790555b5060006200005f6001600160e01b03620000b816565b60008054610100600160a81b0319166101006001600160a01b038416908102919091178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a3505062000117565b3390565b8051620000c981620000fd565b92915050565b600060208284031215620000e257600080fd5b6000620000f08484620000bc565b949350505050565b151590565b6200010881620000f8565b81146200011457600080fd5b50565b613fd380620001276000396000f3fe608060405234801561001057600080fd5b50600436106101cf5760003560e01c8063abff011011610104578063d482dda6116100a2578063f2fde38b11610071578063f2fde38b146103af578063f414c5e4146103c2578063f670dde1146103ca578063f8c8765e146103dd576101cf565b8063d482dda61461034e578063dc162e3614610374578063decc1c8614610389578063e46eb5b61461039c576101cf565b8063c0ad52d5116100de578063c0ad52d514610323578063cd3293de1461032b578063cd8513ba14610333578063d3385d051461033b576101cf565b8063abff0110146102f5578063b0898691146102fd578063bf0d021314610310576101cf565b806345b2b467116101715780638da5cb5b1161014b5780638da5cb5b146102b25780638f32d59b146102c757806393c7e3bc146102cf5780639cecc80a146102e2576101cf565b806345b2b467146102845780634afb215e14610297578063715018a6146102aa576101cf565b80631e2e3a6b116101ad5780631e2e3a6b1461021c578063278488a41461023157806338b1e9f71461025157806342bfc99c14610271576101cf565b8063040bbd35146101d4578063132e8aa7146101e9578063158ef93e14610207575b600080fd5b6101e76101e2366004612e6f565b6103f0565b005b6101f16104b1565b6040516101fe9190613c46565b60405180910390f35b61020f6104c0565b6040516101fe9190613c2a565b6102246104c9565b6040516101fe9190613c19565b61024461023f366004612dcc565b610691565b6040516101fe9190613e35565b61026461025f366004612dcc565b610774565b6040516101fe9190613c38565b61026461027f366004612dea565b610792565b610264610292366004612c85565b61091a565b6101e76102a5366004612e6f565b61092c565b6101e76109d8565b6102ba610a62565b6040516101fe9190613b9d565b61020f610a76565b6102646102dd366004612dea565b610a9f565b6101e76102f0366004612e6f565b610b2a565b6102ba610bd6565b61026461030b366004612ec2565b610be5565b6101e761031e366004612c85565b61130b565b6102646113b7565b6101f16113df565b6102646113ee565b610264610349366004612dea565b6113fd565b61036161035c366004612dcc565b611578565b6040516101fe9796959493929190613bab565b61037c611604565b6040516101fe9190613c08565b6101e7610397366004612d04565b61165c565b61020f6103aa366004612e3f565b61170b565b6101e76103bd366004612c85565b611a6b565b6101f1611a9b565b6102646103d8366004612dea565b611aaa565b6101e76103eb366004612ca3565b611b29565b6103f8610a76565b61041d5760405162461bcd60e51b815260040161041490613d85565b60405180910390fd5b6001600160a01b0381166104435760405162461bcd60e51b815260040161041490613e05565b600580547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383161790556040517f21921b3b46ef2c939e85d6a14410c6e3b9ce132b66e944357ff4f789f68e00e2906104a6908390613b9d565b60405180910390a150565b6006546001600160a01b031681565b60005460ff1681565b600354604080518281526020808402820101909152606091801561050757816020015b6104f461295a565b8152602001906001900390816104ec5790505b50905060005b60035481101561068d576003818154811061052457fe5b906000526020600020015482828151811061053b57fe5b60209081029190910101515260408051600280825260608201909252908160200160208202803883390190505082828151811061057457fe5b602002602001015160200181905250600260006003838154811061059457fe5b9060005260206000200154815260200190815260200160002060000160009054906101000a90046001600160a01b03168282815181106105d057fe5b6020026020010151602001516000815181106105e857fe5b60200260200101906001600160a01b031690816001600160a01b031681525050600260006003838154811061061957fe5b9060005260206000200154815260200190815260200160002060010160009054906101000a90046001600160a01b031682828151811061065557fe5b60200260200101516020015160018151811061066d57fe5b6001600160a01b039092166020928302919091019091015260010161050d565b5090565b610699612972565b50600081815260026020818152604092839020835160e08101855281546001600160a01b03908116825260018301548116828501529382015484168186015260038201546060808301919091526004830154608080840191909152600584015460a080850191909152875160c08181018a5260068701549282019283529181526007860154881696810196909652600885015497860197909752600984015491850191909152600a90920154918301919091529283015281511661076f5760405162461bcd60e51b815260040161041490613dd5565b919050565b6003818154811061078157fe5b600091825260209091200154905081565b6001546000906001600160a01b031633146107bf5760405162461bcd60e51b815260040161041490613d15565b6107c7612972565b6107d086610691565b60055460c0820151602001516040517fc0b05da00000000000000000000000000000000000000000000000000000000081529293506000926001600160a01b039092169163c0b05da09161082691600401613b9d565b60206040518083038186803b15801561083e57600080fd5b505afa158015610852573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506108769190810190612f4e565b60ff16146108965760405162461bcd60e51b815260040161041490613c65565b6001600160a01b0385166000908152600760205260408120546108c090859063ffffffff611baa16565b90506000806108d184898986611bed565b915091506108e389858a868686611def565b6001600160a01b03871660009081526007602052604090205461090d90839063ffffffff611f1016565b9998505050505050505050565b60076020526000908152604090205481565b610934610a76565b6109505760405162461bcd60e51b815260040161041490613d85565b6001600160a01b0381166109765760405162461bcd60e51b815260040161041490613de5565b600680547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383169081179091556040517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f735390600090a250565b6109e0610a76565b6109fc5760405162461bcd60e51b815260040161041490613d85565b600080546040516101009091046001600160a01b0316907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080547fffffffffffffffffffffff0000000000000000000000000000000000000000ff169055565b60005461010090046001600160a01b031690565b6000805461010090046001600160a01b0316610a90611f52565b6001600160a01b031614905090565b6000610aa9612972565b610ab286610691565b6001600160a01b03861660009081526007602052604081205491925090610ae090859063ffffffff611baa16565b90506000610af083888885611bed565b506001600160a01b038716600090815260076020526040902054909150610b1e90829063ffffffff611f1016565b98975050505050505050565b610b32610a76565b610b4e5760405162461bcd60e51b815260040161041490613d85565b6001600160a01b038116610b745760405162461bcd60e51b815260040161041490613df5565b600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383169081179091556040517f0b248ab246a87e452fbedee8dc12dfc53e3f3bfdc6920999062c56dea4ab522a90600090a250565b6001546001600160a01b031681565b6000610bef610a76565b610c0b5760405162461bcd60e51b815260040161041490613d85565b610c13612972565b610c2236849003840184612ee1565b60408101519091506001600160a01b0316610c4f5760405162461bcd60e51b815260040161041490613d55565b80516001600160a01b0316610c765760405162461bcd60e51b815260040161041490613cb5565b60208101516001600160a01b0316610ca05760405162461bcd60e51b815260040161041490613da5565b80602001516001600160a01b031681600001516001600160a01b03161415610cda5760405162461bcd60e51b815260040161041490613d95565b80600001516001600160a01b03166395d89b416040518163ffffffff1660e01b815260040160006040518083038186803b158015610d1757600080fd5b505afa158015610d2b573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610d539190810190612e8d565b81602001516001600160a01b03166395d89b416040518163ffffffff1660e01b815260040160006040518083038186803b158015610d9057600080fd5b505afa158015610da4573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610dcc9190810190612e8d565b82604001516001600160a01b03166306fdde036040518163ffffffff1660e01b815260040160006040518083038186803b158015610e0957600080fd5b505afa158015610e1d573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610e459190810190612e8d565b604051602001610e5793929190613b63565b60408051601f198184030181529181528151602092830120600081815260029093529120549092506001600160a01b031615610ea55760405162461bcd60e51b815260040161041490613ce5565b610eae81611f56565b600080610eba836121c6565b915091508183606001818152505080836080018181525050601283600001516001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b158015610f1157600080fd5b505afa158015610f25573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250610f499190810190612f4e565b60ff161115610f6a5760405162461bcd60e51b815260040161041490613cf5565b601283602001516001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b158015610fa957600080fd5b505afa158015610fbd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250610fe19190810190612f4e565b60ff1611156110025760405162461bcd60e51b815260040161041490613d35565b82600001516001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b15801561103f57600080fd5b505afa158015611053573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506110779190810190612f4e565b60ff16601203600a0a6007600085600001516001600160a01b03166001600160a01b031681526020019081526020016000208190555082602001516001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b1580156110ea57600080fd5b505afa1580156110fe573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506111229190810190612f4e565b60ff16601203600a0a6007600085602001516001600160a01b03166001600160a01b0316815260200190815260200160002081905550826002600086815260200190815260200160002060008201518160000160006101000a8154816001600160a01b0302191690836001600160a01b0316021790555060208201518160010160006101000a8154816001600160a01b0302191690836001600160a01b0316021790555060408201518160020160006101000a8154816001600160a01b0302191690836001600160a01b03160217905550606082015181600301556080820151816004015560a0820151816005015560c08201518160060160008201518160000160008201518160000155505060208201518160010160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506040820151816002015560608201518160030155608082015181600401555050905050600384908060018154018082558091505090600182039060005260206000200160009091929091909150555082602001516001600160a01b031683600001516001600160a01b0316857fb374789237d43aed0f75b4c50a45793fd70e354bb96eecd573f35f5d509d78a186604001516040516112fb9190613b9d565b60405180910390a4505050919050565b611313610a76565b61132f5760405162461bcd60e51b815260040161041490613d85565b6001600160a01b0381166113555760405162461bcd60e51b815260040161041490613e25565b600180547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383169081179091556040517f865dab7821134b6eb27cba259b40e33bbc1b898e970a535a18a83147f380a51f90600090a250565b6040516020016113c690613b92565b6040516020818303038152906040528051906020012081565b6004546001600160a01b031681565b6040516020016113c690613b87565b6001546000906001600160a01b0316331461142a5760405162461bcd60e51b815260040161041490613d15565b611432612972565b61143b86610691565b60055460c0820151602001516040517fc0b05da00000000000000000000000000000000000000000000000000000000081529293506000926001600160a01b039092169163c0b05da09161149191600401613b9d565b60206040518083038186803b1580156114a957600080fd5b505afa1580156114bd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506114e19190810190612f4e565b60ff16146115015760405162461bcd60e51b815260040161041490613c65565b6001600160a01b03841660009081526007602052604081205461152b90859063ffffffff611baa16565b905060008061153c84898986612216565b9150915061154e89858a858786611def565b6001600160a01b03881660009081526007602052604090205461090d90839063ffffffff611f1016565b6002602081815260009283526040928390208054600182015493820154600383015460048401546005850154885160c081018a52600687015460a08201908152815260078701546001600160a01b0390811698820198909852600887015499810199909952600986015460608a0152600a90950154608089015292851696958516959190941693929087565b6060600380548060200260200160405190810160405280929190818152602001828054801561165257602002820191906000526020600020905b81548152602001906001019080831161163e575b5050505050905090565b611664610a76565b6116805760405162461bcd60e51b815260040161041490613d85565b82811461169f5760405162461bcd60e51b815260040161041490613d65565b60005b83811015611704578282828181106116b657fe5b90506020020135600760008787858181106116cd57fe5b90506020020160206116e29190810190612c85565b6001600160a01b031681526020810191909152604001600020556001016116a2565b5050505050565b6000611715610a76565b6117315760405162461bcd60e51b815260040161041490613d85565b60035482106117525760405162461bcd60e51b815260040161041490613cc5565b826003838154811061176057fe5b9060005260206000200154146117885760405162461bcd60e51b815260040161041490613db5565b611790612972565b600260008581526020019081526020016000206040518060e00160405290816000820160009054906101000a90046001600160a01b03166001600160a01b03166001600160a01b031681526020016001820160009054906101000a90046001600160a01b03166001600160a01b03166001600160a01b031681526020016002820160009054906101000a90046001600160a01b03166001600160a01b03166001600160a01b03168152602001600382015481526020016004820154815260200160058201548152602001600682016040518060a00160405290816000820160405180602001604052908160008201548152505081526020016001820160009054906101000a90046001600160a01b03166001600160a01b03166001600160a01b03168152602001600282015481526020016003820154815260200160048201548152505081525050905060026000858152602001908152602001600020600080820160006101000a8154906001600160a01b0302191690556001820160006101000a8154906001600160a01b0302191690556002820160006101000a8154906001600160a01b03021916905560038201600090556004820160009055600582016000905560068201600080820160008082016000905550506001820160006101000a8154906001600160a01b0302191690556002820160009055600382016000905560048201600090555050505060036119b9600160038054905061232590919063ffffffff16565b815481106119c357fe5b9060005260206000200154600384815481106119db57fe5b60009182526020909120015560038054806119f257fe5b600190038181906000526020600020016000905590556001915080602001516001600160a01b031681600001516001600160a01b0316857fadbbec6c203cb0248e89fe6d15ad651061a9d5203a1ab0273256e2b7decffa898460400151604051611a5c9190613b9d565b60405180910390a45092915050565b611a73610a76565b611a8f5760405162461bcd60e51b815260040161041490613d85565b611a9881612367565b50565b6005546001600160a01b031681565b6000611ab4612972565b611abd86610691565b6001600160a01b03851660009081526007602052604081205491925090611aeb90859063ffffffff611baa16565b90506000611afb83888885612216565b506001600160a01b038816600090815260076020526040902054909150610b1e90829063ffffffff611f1016565b60005460ff1615611b4c5760405162461bcd60e51b815260040161041490613c85565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055611b8033612367565b611b898461130b565b611b9283610b2a565b611b9b8261092c565b611ba4816103f0565b50505050565b600082611bb957506000611be7565b82820282848281611bc657fe5b0414611be45760405162461bcd60e51b815260040161041490613d75565b90505b92915050565b60008085600001516001600160a01b0316856001600160a01b0316148015611c2a575085602001516001600160a01b0316846001600160a01b0316145b80611c61575085602001516001600160a01b0316856001600160a01b0316148015611c61575085516001600160a01b038581169116145b611c7d5760405162461bcd60e51b815260040161041490613e15565b611c868661240a565b815191975091506001600160a01b0386811691161415611d455785604001516001600160a01b03166352707d8c87606001518860800151611cce8a60c001516000015161243f565b876040518563ffffffff1660e01b8152600401611cee9493929190613e5f565b60206040518083038186803b158015611d0657600080fd5b505afa158015611d1a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611d3e9190810190612f00565b9150611de6565b85604001516001600160a01b03166352707d8c87608001518860600151611d738a60c001516000015161243f565b876040518563ffffffff1660e01b8152600401611d939493929190613e5f565b60206040518083038186803b158015611dab57600080fd5b505afa158015611dbf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611de39190810190612f00565b91505b94509492505050565b8015611e5357426002600088815260200190815260200160002060050181905550857f949f5db193cbfa01f2d443b1c656bfede15497de0d86838cea089bd60c43834286606001518760800151604051611e4a929190613e44565b60405180910390a25b611e5c85612443565b15611ee45784516001600160a01b0385811691161415611eaf576060850151611e8b908463ffffffff61247a16565b60608601526080850151611ea5908363ffffffff61232516565b6080860152611ee4565b6060850151611ec4908363ffffffff61232516565b60608601526080850151611ede908463ffffffff61247a16565b60808601525b505050606082015160009384526002602052604090932060038101939093555060800151600490910155565b6000611be483836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061249f565b3390565b6004805482516040517f4f8e6e230000000000000000000000000000000000000000000000000000000081526001600160a01b0390921692634f8e6e2392611f9f929101613b9d565b60206040518083038186803b158015611fb757600080fd5b505afa158015611fcb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611fef9190810190612d74565b61200b5760405162461bcd60e51b815260040161041490613c75565b6004805460208301516040517f4f8e6e230000000000000000000000000000000000000000000000000000000081526001600160a01b0390921692634f8e6e2392612057929101613b9d565b60206040518083038186803b15801561206f57600080fd5b505afa158015612083573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506120a79190810190612d74565b8061214957506004805460208301516040517fcae182fe0000000000000000000000000000000000000000000000000000000081526001600160a01b039092169263cae182fe926120f9929101613b9d565b60206040518083038186803b15801561211157600080fd5b505afa158015612125573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506121499190810190612d74565b6121655760405162461bcd60e51b815260040161041490613d05565b60c08101515161217c906121776124d8565b6124fc565b6121985760405162461bcd60e51b815260040161041490613d45565b60c0810151602001516001600160a01b0316611a985760405162461bcd60e51b815260040161041490613dc5565b6000808260c001516080015191506000806121e88560c0015160200151612504565b909250905061220d82612201838763ffffffff611baa16565b9063ffffffff611f1016565b92505050915091565b60008085600001516001600160a01b0316856001600160a01b0316148015612253575085602001516001600160a01b0316846001600160a01b0316145b8061228a575085602001516001600160a01b0316856001600160a01b031614801561228a575085516001600160a01b038581169116145b6122a65760405162461bcd60e51b815260040161041490613e15565b6122af8661240a565b815191975091506001600160a01b03868116911614156122f75785604001516001600160a01b031663571fd01287606001518860800151611cce8a60c001516000015161243f565b85604001516001600160a01b031663571fd01287608001518860600151611d738a60c001516000015161243f565b6000611be483836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506125d1565b6001600160a01b03811661238d5760405162461bcd60e51b815260040161041490613c95565b600080546040516001600160a01b038085169361010090930416917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b03909216610100027fffffffffffffffffffffff0000000000000000000000000000000000000000ff909216919091179055565b612412612972565b600061241d836125fd565b156124395761242b836121c6565b608085015260608401525060015b91929050565b5190565b600060405160200161245490613b87565b604051602081830303815290604052805190602001206124738361266e565b1492915050565b600082820183811015611be45760405162461bcd60e51b815260040161041490613cd5565b600081836124c05760405162461bcd60e51b81526004016104149190613c54565b5060008385816124cc57fe5b049150505b9392505050565b6124e06129cf565b50604080516020810190915269d3c21bcecceda1000000815290565b519051111590565b6006546040517fef90e1b00000000000000000000000000000000000000000000000000000000081526000918291829182916001600160a01b039091169063ef90e1b090612556908890600401613b9d565b604080518083038186803b15801561256d57600080fd5b505afa158015612581573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506125a59190810190612f1e565b9092509050806125c75760405162461bcd60e51b815260040161041490613d25565b9092509050915091565b600081848411156125f55760405162461bcd60e51b81526004016104149190613c54565b505050900390565b60008061260983612716565b905061261483612949565b1561263657806126365760405162461bcd60e51b815260040161041490613ca5565b60006126578460c00151604001518560a0015161247a90919063ffffffff16565b42101590508080156126665750815b949350505050565b600081604001516001600160a01b03166306fdde036040518163ffffffff1660e01b815260040160006040518083038186803b1580156126ad57600080fd5b505afa1580156126c1573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526126e99190810190612e8d565b6040516020016126f99190613b57565b604051602081830303815290604052805190602001209050919050565b60065460c0820151602001516040517fffe736bf00000000000000000000000000000000000000000000000000000000815260009283926001600160a01b039091169163ffe736bf9161276b91600401613b9d565b604080518083038186803b15801561278257600080fd5b505afa158015612796573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506127ba9190810190612d92565b5060c084015160608101516006546020909201516040517fbbc66a9400000000000000000000000000000000000000000000000000000000815293945060009391926001600160a01b03169163bbc66a949161281891600401613b9d565b60206040518083038186803b15801561283057600080fd5b505afa158015612844573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506128689190810190612f00565b1015905060006128898560c00151604001514261232590919063ffffffff16565b60065460c0870151602001516040517f071b48fc0000000000000000000000000000000000000000000000000000000081526001600160a01b039092169163071b48fc916128d991600401613b9d565b60206040518083038186803b1580156128f157600080fd5b505afa158015612905573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506129299190810190612f00565b119050821580156129375750815b80156129405750805b95945050505050565b600060405160200161245490613b92565b60408051808201909152600081526060602082015290565b6040518060e0016040528060006001600160a01b0316815260200160006001600160a01b0316815260200160006001600160a01b031681526020016000815260200160008152602001600081526020016129ca6129e2565b905290565b6040518060200160405280600081525090565b6040518060a001604052806129f56129cf565b815260200160006001600160a01b031681526020016000815260200160008152602001600081525090565b8035611be781613f58565b8051611be781613f58565b60008083601f840112612a4857600080fd5b50813567ffffffffffffffff811115612a6057600080fd5b602083019150836020820283011115612a7857600080fd5b9250929050565b8051611be781613f6c565b8035611be781613f75565b8035611be781613f7e565b600082601f830112612ab157600080fd5b8151612ac4612abf82613ebb565b613e94565b91508082526020830160208301858383011115612ae057600080fd5b612aeb838284613f22565b50505092915050565b600060208284031215612b0657600080fd5b612b106020613e94565b90506000612b1e8484612a8a565b82525092915050565b600060a08284031215612b3957600080fd5b612b4360a0613e94565b90506000612b518484612af4565b8252506020612b6284848301612a20565b6020830152506040612b7684828501612a8a565b6040830152506060612b8a84828501612a8a565b6060830152506080612b9e84828501612a8a565b60808301525092915050565b60006101608284031215612bbd57600080fd5b50919050565b60006101608284031215612bd657600080fd5b612be060e0613e94565b90506000612bee8484612a20565b8252506020612bff84848301612a20565b6020830152506040612c1384828501612a95565b6040830152506060612c2784828501612a8a565b6060830152506080612c3b84828501612a8a565b60808301525060a0612c4f84828501612a8a565b60a08301525060c0612c6384828501612b27565b60c08301525092915050565b8051611be781613f75565b8051611be781613f87565b600060208284031215612c9757600080fd5b60006126668484612a20565b60008060008060808587031215612cb957600080fd5b6000612cc58787612a20565b9450506020612cd687828801612a95565b9350506040612ce787828801612a95565b9250506060612cf887828801612a95565b91505092959194509250565b60008060008060408587031215612d1a57600080fd5b843567ffffffffffffffff811115612d3157600080fd5b612d3d87828801612a36565b9450945050602085013567ffffffffffffffff811115612d5c57600080fd5b612d6887828801612a36565b95989497509550505050565b600060208284031215612d8657600080fd5b60006126668484612a7f565b60008060408385031215612da557600080fd5b6000612db18585612a7f565b9250506020612dc285828601612a2b565b9150509250929050565b600060208284031215612dde57600080fd5b60006126668484612a8a565b60008060008060808587031215612e0057600080fd5b6000612e0c8787612a8a565b9450506020612e1d87828801612a20565b9350506040612e2e87828801612a20565b9250506060612cf887828801612a8a565b60008060408385031215612e5257600080fd5b6000612e5e8585612a8a565b9250506020612dc285828601612a8a565b600060208284031215612e8157600080fd5b60006126668484612a95565b600060208284031215612e9f57600080fd5b815167ffffffffffffffff811115612eb657600080fd5b61266684828501612aa0565b60006101608284031215612ed557600080fd5b60006126668484612baa565b60006101608284031215612ef457600080fd5b60006126668484612bc3565b600060208284031215612f1257600080fd5b60006126668484612c6f565b60008060408385031215612f3157600080fd5b6000612f3d8585612c6f565b9250506020612dc285828601612c6f565b600060208284031215612f6057600080fd5b60006126668484612c7a565b6000612f788383612f98565b505060200190565b6000612f7883836130c5565b6000611be48383613a39565b612fa181613ef2565b82525050565b6000612fb28261243f565b612fbc8185613ee9565b9350612fc783613ee3565b8060005b83811015612ff5578151612fdf8882612f6c565b9750612fea83613ee3565b925050600101612fcb565b509495945050505050565b600061300b8261243f565b6130158185613ee9565b935061302083613ee3565b8060005b83811015612ff55781516130388882612f80565b975061304383613ee3565b925050600101613024565b60006130598261243f565b6130638185613ee9565b93508360208202850161307585613ee3565b8060005b858110156130af57848403895281516130928582612f8c565b945061309d83613ee3565b60209a909a0199925050600101613079565b5091979650505050505050565b612fa181613efd565b612fa181613f02565b612fa181613f05565b60006130e28261243f565b6130ec8185613ee9565b93506130fc818560208601613f22565b61310581613f4e565b9093019392505050565b600061311a8261243f565b613124818561076f565b9350613134818560208601613f22565b9290920192915050565b600061314b602c83613ee9565b7f54726164696e672069732073757370656e64656420666f72207468697320726581527f666572656e636520726174650000000000000000000000000000000000000000602082015260400192915050565b60006131aa603383613ee9565b7f617373657430206d757374206265206120737461626c6520726567697374657281527f6564207769746820746865207265736572766500000000000000000000000000602082015260400192915050565b6000613209601c83613ee9565b7f636f6e747261637420616c726561647920696e697469616c697a656400000000815260200192915050565b6000613242602683613ee9565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206181527f6464726573730000000000000000000000000000000000000000000000000000602082015260400192915050565b60006132a1600f83613ee9565b7f6e6f2076616c6964206d656469616e0000000000000000000000000000000000815260200192915050565b60006132da601283613ee9565b7f617373657430206d757374206265207365740000000000000000000000000000815260200192915050565b6000613313601c83613ee9565b7f65786368616e67654964496e646578206e6f7420696e2072616e676500000000815260200192915050565b600061334c601b83613ee9565b7f536166654d6174683a206164646974696f6e206f766572666c6f770000000000815260200192915050565b6000613385600f8361076f565b7f436f6e7374616e7450726f6475637400000000000000000000000000000000008152600f0192915050565b60006133be603983613ee9565b7f416e2065786368616e676520776974682074686520737065636966696564206181527f737365747320616e642065786368616e67652065786973747300000000000000602082015260400192915050565b600061341d601d83613ee9565b7f61737365743020646563696d616c73206d757374206265203c3d203138000000815260200192915050565b6000613456602583613ee9565b7f617373657431206d757374206265206120737461626c65206f7220636f6c6c6181527f746572616c000000000000000000000000000000000000000000000000000000602082015260400192915050565b60006134b5601883613ee9565b7f43616c6c6572206973206e6f74207468652042726f6b65720000000000000000815260200192915050565b60006134ee603083613ee9565b7f65786368616e676520726174652064656e6f6d696e61746f72206d757374206281527f652067726561746572207468616e203000000000000000000000000000000000602082015260400192915050565b600061354d601d83613ee9565b7f61737365743120646563696d616c73206d757374206265203c3d203138000000815260200192915050565b6000613586602683613ee9565b7f737072656164206d757374206265206c657373207468616e206f72206571756181527f6c20746f20310000000000000000000000000000000000000000000000000000602082015260400192915050565b60006135e5601983613ee9565b7f70726963696e674d6f64756c65206d7573742062652073657400000000000000815260200192915050565b600061361e603783613ee9565b7f746f6b656e7320616e6420707265636973696f6e4d756c7469706c696572732081527f6d757374206265207468652073616d65206c656e677468000000000000000000602082015260400192915050565b600061367d602183613ee9565b7f536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f81527f7700000000000000000000000000000000000000000000000000000000000000602082015260400192915050565b60006136dc602083613ee9565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572815260200192915050565b6000613715602283613ee9565b7f65786368616e6765206173736574732063616e2774206265206964656e74696381527f616c000000000000000000000000000000000000000000000000000000000000602082015260400192915050565b6000613774601283613ee9565b7f617373657431206d757374206265207365740000000000000000000000000000815260200192915050565b60006137ad600b8361076f565b7f436f6e7374616e7453756d0000000000000000000000000000000000000000008152600b0192915050565b60006137e6602183613ee9565b7f65786368616e6765496420617420696e64657820646f65736e2774206d61746381527f6800000000000000000000000000000000000000000000000000000000000000602082015260400192915050565b6000613845601f83613ee9565b7f7265666572656e636552617465466565644944206d7573742062652073657400815260200192915050565b600061387e603083613ee9565b7f416e2065786368616e676520776974682074686520737065636966696564206981527f6420646f6573206e6f7420657869737400000000000000000000000000000000602082015260400192915050565b60006138dd602183613ee9565b7f536f727465644f7261636c65732061646472657373206d75737420626520736581527f7400000000000000000000000000000000000000000000000000000000000000602082015260400192915050565b600061393c601b83613ee9565b7f526573657276652061646472657373206d757374206265207365740000000000815260200192915050565b6000613975601e83613ee9565b7f427265616b6572426f782061646472657373206d757374206265207365740000815260200192915050565b60006139ae602883613ee9565b7f746f6b656e496e20616e6420746f6b656e4f7574206d757374206d617463682081527f65786368616e6765000000000000000000000000000000000000000000000000602082015260400192915050565b6000613a0d601a83613ee9565b7f42726f6b65722061646472657373206d75737420626520736574000000000000815260200192915050565b80516000906040840190613a4d85826130c5565b50602083015184820360208601526129408282612fa7565b80516020830190611ba484826130c5565b805160a0830190613a878482613a65565b506020820151613a9a6020850182612f98565b506040820151613aad60408501826130c5565b506060820151613ac060608501826130c5565b506080820151611ba460808501826130c5565b8051610160830190613ae58482612f98565b506020820151613af86020850182612f98565b506040820151613b0b60408501826130ce565b506060820151613b1e60608501826130c5565b506080820151613b3160808501826130c5565b5060a0820151613b4460a08501826130c5565b5060c0820151611ba460c0850182613a76565b60006124d1828461310f565b6000613b6f828661310f565b9150613b7b828561310f565b9150612940828461310f565b6000611be782613378565b6000611be7826137a0565b60208101611be78284612f98565b6101608101613bba828a612f98565b613bc76020830189612f98565b613bd460408301886130ce565b613be160608301876130c5565b613bee60808301866130c5565b613bfb60a08301856130c5565b610b1e60c0830184613a76565b60208082528101611be48184613000565b60208082528101611be4818461304e565b60208101611be782846130bc565b60208101611be782846130c5565b60208101611be782846130ce565b60208082528101611be481846130d7565b60208082528101611be78161313e565b60208082528101611be78161319d565b60208082528101611be7816131fc565b60208082528101611be781613235565b60208082528101611be781613294565b60208082528101611be7816132cd565b60208082528101611be781613306565b60208082528101611be78161333f565b60208082528101611be7816133b1565b60208082528101611be781613410565b60208082528101611be781613449565b60208082528101611be7816134a8565b60208082528101611be7816134e1565b60208082528101611be781613540565b60208082528101611be781613579565b60208082528101611be7816135d8565b60208082528101611be781613611565b60208082528101611be781613670565b60208082528101611be7816136cf565b60208082528101611be781613708565b60208082528101611be781613767565b60208082528101611be7816137d9565b60208082528101611be781613838565b60208082528101611be781613871565b60208082528101611be7816138d0565b60208082528101611be78161392f565b60208082528101611be781613968565b60208082528101611be7816139a1565b60208082528101611be781613a00565b6101608101611be78284613ad3565b60408101613e5282856130c5565b6124d160208301846130c5565b60808101613e6d82876130c5565b613e7a60208301866130c5565b613e8760408301856130c5565b61294060608301846130c5565b60405181810167ffffffffffffffff81118282101715613eb357600080fd5b604052919050565b600067ffffffffffffffff821115613ed257600080fd5b506020601f91909101601f19160190565b60200190565b90815260200190565b6000611be782613f10565b151590565b90565b6000611be782613ef2565b6001600160a01b031690565b60ff1690565b60005b83811015613f3d578181015183820152602001613f25565b83811115611ba45750506000910152565b601f01601f191690565b613f6181613ef2565b8114611a9857600080fd5b613f6181613efd565b613f6181613f02565b613f6181613f05565b613f6181613f1c56fea365627a7a723158202c0ac2d7a1e2588b47ef3bea98db20e5ec400e70b4e365b612e77e69248cb79c6c6578706572696d656e74616cf564736f6c634300051100400000000000000000000000000000000000000000000000000000000000000000", - "nonce": "0x23d" + "data": "0x60806040523480156200001157600080fd5b5060405162004241380380620042418339810160408190526200003491620000cf565b808062000049576000805460ff191660011790555b5060006200005f6001600160e01b03620000b816565b60008054610100600160a81b0319166101006001600160a01b038416908102919091178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a3505062000117565b3390565b8051620000c981620000fd565b92915050565b600060208284031215620000e257600080fd5b6000620000f08484620000bc565b949350505050565b151590565b6200010881620000f8565b81146200011457600080fd5b50565b61411a80620001276000396000f3fe608060405234801561001057600080fd5b50600436106101da5760003560e01c8063abff011011610104578063d482dda6116100a2578063f2fde38b11610071578063f2fde38b146103cd578063f414c5e4146103e0578063f670dde1146103e8578063f8c8765e146103fb576101da565b8063d482dda61461036c578063dc162e3614610392578063e46eb5b6146103a7578063eaaba701146103ba576101da565b8063c0ad52d5116100de578063c0ad52d514610341578063cd3293de14610349578063cd8513ba14610351578063d3385d0514610359576101da565b8063abff011014610313578063b08986911461031b578063bf0d02131461032e576101da565b8063450154211161017c5780638da5cb5b1161014b5780638da5cb5b146102d05780638f32d59b146102e557806393c7e3bc146102ed5780639cecc80a14610300576101da565b8063450154211461028f57806345b2b467146102a25780634afb215e146102b5578063715018a6146102c8576101da565b80631e2e3a6b116101b85780631e2e3a6b14610227578063278488a41461023c57806338b1e9f71461025c57806342bfc99c1461027c576101da565b8063040bbd35146101df578063132e8aa7146101f4578063158ef93e14610212575b600080fd5b6101f26101ed366004612e82565b61040e565b005b6101fc6104cf565b6040516102099190613d62565b60405180910390f35b61021a6104de565b6040516102099190613d46565b61022f6104e7565b6040516102099190613d35565b61024f61024a366004612ddf565b6106b0565b6040516102099190613f61565b61026f61026a366004612ddf565b610793565b6040516102099190613d54565b61026f61028a366004612dfd565b6107b1565b6101f261029d366004612d17565b610939565b61026f6102b0366004612c98565b610a53565b6101f26102c3366004612e82565b610a65565b6101f2610b11565b6102d8610b9b565b6040516102099190613c88565b61021a610baf565b61026f6102fb366004612dfd565b610bd8565b6101f261030e366004612e82565b610c63565b6102d8610d0f565b61026f610329366004612ed5565b610d1e565b6101f261033c366004612c98565b6113b4565b61026f611460565b6101fc611488565b61026f611497565b61026f610367366004612dfd565b6114a6565b61037f61037a366004612ddf565b611621565b6040516102099796959493929190613c96565b61039a6116ad565b6040516102099190613d24565b61021a6103b5366004612e52565b611705565b6102d86103c8366004612ddf565b611a65565b6101f26103db366004612c98565b611a80565b6101fc611ab0565b61026f6103f6366004612dfd565b611abf565b6101f2610409366004612cb6565b611b3e565b610416610baf565b61043b5760405162461bcd60e51b815260040161043290613ea1565b60405180910390fd5b6001600160a01b0381166104615760405162461bcd60e51b815260040161043290613f21565b600580547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383161790556040517f21921b3b46ef2c939e85d6a14410c6e3b9ce132b66e944357ff4f789f68e00e2906104c4908390613c88565b60405180910390a150565b6006546001600160a01b031681565b60005460ff1681565b6003546040805182815260208084028201019091526060919081801561052757816020015b61051461296d565b81526020019060019003908161050c5790505b50915060005b818110156106ab576003818154811061054257fe5b906000526020600020015483828151811061055957fe5b60209081029190910101515260408051600280825260608201909252908160200160208202803883390190505083828151811061059257fe5b60200260200101516020018190525060026000600383815481106105b257fe5b9060005260206000200154815260200190815260200160002060000160009054906101000a90046001600160a01b03168382815181106105ee57fe5b60200260200101516020015160008151811061060657fe5b60200260200101906001600160a01b031690816001600160a01b031681525050600260006003838154811061063757fe5b9060005260206000200154815260200190815260200160002060010160009054906101000a90046001600160a01b031683828151811061067357fe5b60200260200101516020015160018151811061068b57fe5b6001600160a01b039092166020928302919091019091015260010161052d565b505090565b6106b8612985565b50600081815260026020818152604092839020835160e08101855281546001600160a01b03908116825260018301548116828501529382015484168186015260038201546060808301919091526004830154608080840191909152600584015460a080850191909152875160c08181018a5260068701549282019283529181526007860154881696810196909652600885015497860197909752600984015491850191909152600a90920154918301919091529283015281511661078e5760405162461bcd60e51b815260040161043290613ef1565b919050565b600381815481106107a057fe5b600091825260209091200154905081565b6001546000906001600160a01b031633146107de5760405162461bcd60e51b815260040161043290613e31565b6107e6612985565b6107ef866106b0565b60055460c0820151602001516040517fc0b05da00000000000000000000000000000000000000000000000000000000081529293506000926001600160a01b039092169163c0b05da09161084591600401613c88565b60206040518083038186803b15801561085d57600080fd5b505afa158015610871573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506108959190810190612f61565b60ff16146108b55760405162461bcd60e51b815260040161043290613d81565b6001600160a01b0385166000908152600760205260408120546108df90859063ffffffff611bbf16565b90506000806108f084898986611c02565b9150915061090289858a868686611e0a565b6001600160a01b03871660009081526007602052604090205461092c90839063ffffffff611f2b16565b9998505050505050505050565b610941610baf565b61095d5760405162461bcd60e51b815260040161043290613ea1565b82811461097c5760405162461bcd60e51b815260040161043290613f51565b60005b83811015610a0f5782828281811061099357fe5b90506020020160206109a89190810190612c98565b600860008787858181106109b857fe5b6020908102929092013583525081019190915260400160002080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b039290921691909117905560010161097f565b507f84557d458d60fcb29d9a10a8f28861c76847f7ef6450a9266a228a6f3a590baa84848484604051610a459493929190613cf3565b60405180910390a150505050565b60076020526000908152604090205481565b610a6d610baf565b610a895760405162461bcd60e51b815260040161043290613ea1565b6001600160a01b038116610aaf5760405162461bcd60e51b815260040161043290613f01565b600680547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383169081179091556040517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f735390600090a250565b610b19610baf565b610b355760405162461bcd60e51b815260040161043290613ea1565b600080546040516101009091046001600160a01b0316907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080547fffffffffffffffffffffff0000000000000000000000000000000000000000ff169055565b60005461010090046001600160a01b031690565b6000805461010090046001600160a01b0316610bc9611f6d565b6001600160a01b031614905090565b6000610be2612985565b610beb866106b0565b6001600160a01b03861660009081526007602052604081205491925090610c1990859063ffffffff611bbf16565b90506000610c2983888885611c02565b506001600160a01b038716600090815260076020526040902054909150610c5790829063ffffffff611f2b16565b98975050505050505050565b610c6b610baf565b610c875760405162461bcd60e51b815260040161043290613ea1565b6001600160a01b038116610cad5760405162461bcd60e51b815260040161043290613f11565b600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383169081179091556040517f0b248ab246a87e452fbedee8dc12dfc53e3f3bfdc6920999062c56dea4ab522a90600090a250565b6001546001600160a01b031681565b6000610d28610baf565b610d445760405162461bcd60e51b815260040161043290613ea1565b610d4c612985565b610d5b36849003840184612ef4565b60408101519091506001600160a01b0316610d885760405162461bcd60e51b815260040161043290613e71565b80516001600160a01b0316610daf5760405162461bcd60e51b815260040161043290613dd1565b60208101516001600160a01b0316610dd95760405162461bcd60e51b815260040161043290613ec1565b80602001516001600160a01b031681600001516001600160a01b03161415610e135760405162461bcd60e51b815260040161043290613eb1565b80604001516001600160a01b031660086000610e2e84611f71565b81526020810191909152604001600020546001600160a01b031614610e655760405162461bcd60e51b815260040161043290613e91565b80600001516001600160a01b03166395d89b416040518163ffffffff1660e01b815260040160006040518083038186803b158015610ea257600080fd5b505afa158015610eb6573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610ede9190810190612ea0565b81602001516001600160a01b03166395d89b416040518163ffffffff1660e01b815260040160006040518083038186803b158015610f1b57600080fd5b505afa158015610f2f573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610f579190810190612ea0565b82604001516001600160a01b03166306fdde036040518163ffffffff1660e01b815260040160006040518083038186803b158015610f9457600080fd5b505afa158015610fa8573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052610fd09190810190612ea0565b604051602001610fe293929190613c4e565b60408051601f198184030181529181528151602092830120600081815260029093529120549092506001600160a01b0316156110305760405162461bcd60e51b815260040161043290613e01565b61103981612019565b60008061104583612289565b915091508183606001818152505080836080018181525050600083600001516001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b15801561109c57600080fd5b505afa1580156110b0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506110d49190810190612f61565b60ff169050600084602001516001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b15801561111857600080fd5b505afa15801561112c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506111509190810190612f61565b60ff16905060128211156111765760405162461bcd60e51b815260040161043290613e11565b60128111156111975760405162461bcd60e51b815260040161043290613e51565b81601203600a0a6007600087600001516001600160a01b03166001600160a01b031681526020019081526020016000208190555080601203600a0a6007600087602001516001600160a01b03166001600160a01b0316815260200190815260200160002081905550846002600088815260200190815260200160002060008201518160000160006101000a8154816001600160a01b0302191690836001600160a01b0316021790555060208201518160010160006101000a8154816001600160a01b0302191690836001600160a01b0316021790555060408201518160020160006101000a8154816001600160a01b0302191690836001600160a01b03160217905550606082015181600301556080820151816004015560a0820151816005015560c08201518160060160008201518160000160008201518160000155505060208201518160010160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506040820151816002015560608201518160030155608082015181600401555050905050600386908060018154018082558091505090600182039060005260206000200160009091929091909150555084602001516001600160a01b031685600001516001600160a01b0316877fb374789237d43aed0f75b4c50a45793fd70e354bb96eecd573f35f5d509d78a188604001516040516113a29190613c88565b60405180910390a45050505050919050565b6113bc610baf565b6113d85760405162461bcd60e51b815260040161043290613ea1565b6001600160a01b0381166113fe5760405162461bcd60e51b815260040161043290613f41565b600180547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383169081179091556040517f865dab7821134b6eb27cba259b40e33bbc1b898e970a535a18a83147f380a51f90600090a250565b60405160200161146f90613c7d565b6040516020818303038152906040528051906020012081565b6004546001600160a01b031681565b60405160200161146f90613c72565b6001546000906001600160a01b031633146114d35760405162461bcd60e51b815260040161043290613e31565b6114db612985565b6114e4866106b0565b60055460c0820151602001516040517fc0b05da00000000000000000000000000000000000000000000000000000000081529293506000926001600160a01b039092169163c0b05da09161153a91600401613c88565b60206040518083038186803b15801561155257600080fd5b505afa158015611566573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061158a9190810190612f61565b60ff16146115aa5760405162461bcd60e51b815260040161043290613d81565b6001600160a01b0384166000908152600760205260408120546115d490859063ffffffff611bbf16565b90506000806115e5848989866122d9565b915091506115f789858a858786611e0a565b6001600160a01b03881660009081526007602052604090205461092c90839063ffffffff611f2b16565b6002602081815260009283526040928390208054600182015493820154600383015460048401546005850154885160c081018a52600687015460a08201908152815260078701546001600160a01b0390811698820198909852600887015499810199909952600986015460608a0152600a90950154608089015292851696958516959190941693929087565b606060038054806020026020016040519081016040528092919081815260200182805480156116fb57602002820191906000526020600020905b8154815260200190600101908083116116e7575b5050505050905090565b600061170f610baf565b61172b5760405162461bcd60e51b815260040161043290613ea1565b600354821061174c5760405162461bcd60e51b815260040161043290613de1565b826003838154811061175a57fe5b9060005260206000200154146117825760405162461bcd60e51b815260040161043290613ed1565b61178a612985565b600260008581526020019081526020016000206040518060e00160405290816000820160009054906101000a90046001600160a01b03166001600160a01b03166001600160a01b031681526020016001820160009054906101000a90046001600160a01b03166001600160a01b03166001600160a01b031681526020016002820160009054906101000a90046001600160a01b03166001600160a01b03166001600160a01b03168152602001600382015481526020016004820154815260200160058201548152602001600682016040518060a00160405290816000820160405180602001604052908160008201548152505081526020016001820160009054906101000a90046001600160a01b03166001600160a01b03166001600160a01b03168152602001600282015481526020016003820154815260200160048201548152505081525050905060026000858152602001908152602001600020600080820160006101000a8154906001600160a01b0302191690556001820160006101000a8154906001600160a01b0302191690556002820160006101000a8154906001600160a01b03021916905560038201600090556004820160009055600582016000905560068201600080820160008082016000905550506001820160006101000a8154906001600160a01b0302191690556002820160009055600382016000905560048201600090555050505060036119b360016003805490506123eb90919063ffffffff16565b815481106119bd57fe5b9060005260206000200154600384815481106119d557fe5b60009182526020909120015560038054806119ec57fe5b600190038181906000526020600020016000905590556001915080602001516001600160a01b031681600001516001600160a01b0316857fadbbec6c203cb0248e89fe6d15ad651061a9d5203a1ab0273256e2b7decffa898460400151604051611a569190613c88565b60405180910390a45092915050565b6008602052600090815260409020546001600160a01b031681565b611a88610baf565b611aa45760405162461bcd60e51b815260040161043290613ea1565b611aad8161242d565b50565b6005546001600160a01b031681565b6000611ac9612985565b611ad2866106b0565b6001600160a01b03851660009081526007602052604081205491925090611b0090859063ffffffff611bbf16565b90506000611b10838888856122d9565b506001600160a01b038816600090815260076020526040902054909150610c5790829063ffffffff611f2b16565b60005460ff1615611b615760405162461bcd60e51b815260040161043290613da1565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055611b953361242d565b611b9e846113b4565b611ba783610c63565b611bb082610a65565b611bb98161040e565b50505050565b600082611bce57506000611bfc565b82820282848281611bdb57fe5b0414611bf95760405162461bcd60e51b815260040161043290613e81565b90505b92915050565b60008084848780600001516001600160a01b0316836001600160a01b0316148015611c42575080602001516001600160a01b0316826001600160a01b0316145b80611c79575080602001516001600160a01b0316836001600160a01b0316148015611c79575080516001600160a01b038381169116145b611c955760405162461bcd60e51b815260040161043290613f31565b611c9e896124d0565b8151919a5094506001600160a01b0389811691161415611d5d5788604001516001600160a01b03166352707d8c8a606001518b60800151611ce68d60c0015160000151612508565b8a6040518563ffffffff1660e01b8152600401611d069493929190613f8b565b60206040518083038186803b158015611d1e57600080fd5b505afa158015611d32573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611d569190810190612f13565b9450611dfe565b88604001516001600160a01b03166352707d8c8a608001518b60600151611d8b8d60c0015160000151612508565b8a6040518563ffffffff1660e01b8152600401611dab9493929190613f8b565b60206040518083038186803b158015611dc357600080fd5b505afa158015611dd7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611dfb9190810190612f13565b94505b50505094509492505050565b8015611e6e57426002600088815260200190815260200160002060050181905550857f949f5db193cbfa01f2d443b1c656bfede15497de0d86838cea089bd60c43834286606001518760800151604051611e65929190613f70565b60405180910390a25b611e778561250c565b15611eff5784516001600160a01b0385811691161415611eca576060850151611ea6908463ffffffff61254316565b60608601526080850151611ec0908363ffffffff6123eb16565b6080860152611eff565b6060850151611edf908363ffffffff6123eb16565b60608601526080850151611ef9908463ffffffff61254316565b60808601525b505050606082015160009384526002602052604090932060038101939093555060800151600490910155565b6000611bf983836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612568565b3390565b600081604001516001600160a01b03166306fdde036040518163ffffffff1660e01b815260040160006040518083038186803b158015611fb057600080fd5b505afa158015611fc4573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052611fec9190810190612ea0565b604051602001611ffc9190613c42565b604051602081830303815290604052805190602001209050919050565b6004805482516040517f4f8e6e230000000000000000000000000000000000000000000000000000000081526001600160a01b0390921692634f8e6e2392612062929101613c88565b60206040518083038186803b15801561207a57600080fd5b505afa15801561208e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506120b29190810190612d87565b6120ce5760405162461bcd60e51b815260040161043290613d91565b6004805460208301516040517f4f8e6e230000000000000000000000000000000000000000000000000000000081526001600160a01b0390921692634f8e6e239261211a929101613c88565b60206040518083038186803b15801561213257600080fd5b505afa158015612146573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061216a9190810190612d87565b8061220c57506004805460208301516040517fcae182fe0000000000000000000000000000000000000000000000000000000081526001600160a01b039092169263cae182fe926121bc929101613c88565b60206040518083038186803b1580156121d457600080fd5b505afa1580156121e8573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061220c9190810190612d87565b6122285760405162461bcd60e51b815260040161043290613e21565b60c08101515161223f9061223a6125a1565b6125c5565b61225b5760405162461bcd60e51b815260040161043290613e61565b60c0810151602001516001600160a01b0316611aad5760405162461bcd60e51b815260040161043290613ee1565b6000808260c001516080015191506000806122ab8560c00151602001516125cd565b90925090506122d0826122c4838763ffffffff611bbf16565b9063ffffffff611f2b16565b92505050915091565b60008084848780600001516001600160a01b0316836001600160a01b0316148015612319575080602001516001600160a01b0316826001600160a01b0316145b80612350575080602001516001600160a01b0316836001600160a01b0316148015612350575080516001600160a01b038381169116145b61236c5760405162461bcd60e51b815260040161043290613f31565b612375896124d0565b8151919a5094506001600160a01b03898116911614156123bd5788604001516001600160a01b031663571fd0128a606001518b60800151611ce68d60c0015160000151612508565b88604001516001600160a01b031663571fd0128a608001518b60600151611d8b8d60c0015160000151612508565b6000611bf983836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525061268c565b6001600160a01b0381166124535760405162461bcd60e51b815260040161043290613db1565b600080546040516001600160a01b038085169361010090930416917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b03909216610100027fffffffffffffffffffffff0000000000000000000000000000000000000000ff909216919091179055565b6124d8612985565b60006124e3836126b8565b156124ff576124f183612289565b608085015260608401525060015b8291505b915091565b5190565b600060405160200161251d90613c72565b6040516020818303038152906040528051906020012061253c83611f71565b1492915050565b600082820183811015611bf95760405162461bcd60e51b815260040161043290613df1565b600081836125895760405162461bcd60e51b81526004016104329190613d70565b50600083858161259557fe5b049150505b9392505050565b6125a96129e2565b50604080516020810190915269d3c21bcecceda1000000815290565b519051111590565b6006546040517fef90e1b000000000000000000000000000000000000000000000000000000000815260009182916001600160a01b039091169063ef90e1b09061261b908690600401613c88565b604080518083038186803b15801561263257600080fd5b505afa158015612646573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061266a9190810190612f31565b9092509050806125035760405162461bcd60e51b815260040161043290613e41565b600081848411156126b05760405162461bcd60e51b81526004016104329190613d70565b505050900390565b6000806126c483612729565b90506126cf8361295c565b156126f157806126f15760405162461bcd60e51b815260040161043290613dc1565b60006127128460c00151604001518560a0015161254390919063ffffffff16565b42101590508080156127215750815b949350505050565b60065460c0820151602001516040517fffe736bf00000000000000000000000000000000000000000000000000000000815260009283926001600160a01b039091169163ffe736bf9161277e91600401613c88565b604080518083038186803b15801561279557600080fd5b505afa1580156127a9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506127cd9190810190612da5565b5060c084015160608101516006546020909201516040517fbbc66a9400000000000000000000000000000000000000000000000000000000815293945060009391926001600160a01b03169163bbc66a949161282b91600401613c88565b60206040518083038186803b15801561284357600080fd5b505afa158015612857573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061287b9190810190612f13565b10159050600061289c8560c0015160400151426123eb90919063ffffffff16565b60065460c0870151602001516040517f071b48fc0000000000000000000000000000000000000000000000000000000081526001600160a01b039092169163071b48fc916128ec91600401613c88565b60206040518083038186803b15801561290457600080fd5b505afa158015612918573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061293c9190810190612f13565b1190508215801561294a5750815b80156129535750805b95945050505050565b600060405160200161251d90613c7d565b60408051808201909152600081526060602082015290565b6040518060e0016040528060006001600160a01b0316815260200160006001600160a01b0316815260200160006001600160a01b031681526020016000815260200160008152602001600081526020016129dd6129f5565b905290565b6040518060200160405280600081525090565b6040518060a00160405280612a086129e2565b815260200160006001600160a01b031681526020016000815260200160008152602001600081525090565b8035611bfc8161409f565b8051611bfc8161409f565b60008083601f840112612a5b57600080fd5b50813567ffffffffffffffff811115612a7357600080fd5b602083019150836020820283011115612a8b57600080fd5b9250929050565b8051611bfc816140b3565b8035611bfc816140bc565b8035611bfc816140c5565b600082601f830112612ac457600080fd5b8151612ad7612ad282613fe7565b613fc0565b91508082526020830160208301858383011115612af357600080fd5b612afe838284614069565b50505092915050565b600060208284031215612b1957600080fd5b612b236020613fc0565b90506000612b318484612a9d565b82525092915050565b600060a08284031215612b4c57600080fd5b612b5660a0613fc0565b90506000612b648484612b07565b8252506020612b7584848301612a33565b6020830152506040612b8984828501612a9d565b6040830152506060612b9d84828501612a9d565b6060830152506080612bb184828501612a9d565b60808301525092915050565b60006101608284031215612bd057600080fd5b50919050565b60006101608284031215612be957600080fd5b612bf360e0613fc0565b90506000612c018484612a33565b8252506020612c1284848301612a33565b6020830152506040612c2684828501612aa8565b6040830152506060612c3a84828501612a9d565b6060830152506080612c4e84828501612a9d565b60808301525060a0612c6284828501612a9d565b60a08301525060c0612c7684828501612b3a565b60c08301525092915050565b8051611bfc816140bc565b8051611bfc816140ce565b600060208284031215612caa57600080fd5b60006127218484612a33565b60008060008060808587031215612ccc57600080fd5b6000612cd88787612a33565b9450506020612ce987828801612aa8565b9350506040612cfa87828801612aa8565b9250506060612d0b87828801612aa8565b91505092959194509250565b60008060008060408587031215612d2d57600080fd5b843567ffffffffffffffff811115612d4457600080fd5b612d5087828801612a49565b9450945050602085013567ffffffffffffffff811115612d6f57600080fd5b612d7b87828801612a49565b95989497509550505050565b600060208284031215612d9957600080fd5b60006127218484612a92565b60008060408385031215612db857600080fd5b6000612dc48585612a92565b9250506020612dd585828601612a3e565b9150509250929050565b600060208284031215612df157600080fd5b60006127218484612a9d565b60008060008060808587031215612e1357600080fd5b6000612e1f8787612a9d565b9450506020612e3087828801612a33565b9350506040612e4187828801612a33565b9250506060612d0b87828801612a9d565b60008060408385031215612e6557600080fd5b6000612e718585612a9d565b9250506020612dd585828601612a9d565b600060208284031215612e9457600080fd5b60006127218484612aa8565b600060208284031215612eb257600080fd5b815167ffffffffffffffff811115612ec957600080fd5b61272184828501612ab3565b60006101608284031215612ee857600080fd5b60006127218484612bbd565b60006101608284031215612f0757600080fd5b60006127218484612bd6565b600060208284031215612f2557600080fd5b60006127218484612c82565b60008060408385031215612f4457600080fd5b6000612f508585612c82565b9250506020612dd585828601612c82565b600060208284031215612f7357600080fd5b60006127218484612c8d565b6000612f8b8383612fab565b505060200190565b6000612f8b8383613177565b6000611bf98383613b24565b612fb481614030565b82525050565b6000612fc68385614018565b9350612fd18261400f565b8060005b8581101561300757612fe78284614021565b612ff18882612f7f565b9750612ffc83614012565b925050600101612fd5565b509495945050505050565b600061301d82612508565b6130278185614018565b935061303283614012565b8060005b8381101561300757815161304a8882612f7f565b975061305583614012565b925050600101613036565b600061306c8385614018565b93507f07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83111561309b57600080fd5b6020830292506130ac83858461405d565b50500190565b60006130bd82612508565b6130c78185614018565b93506130d283614012565b8060005b838110156130075781516130ea8882612f93565b97506130f583614012565b9250506001016130d6565b600061310b82612508565b6131158185614018565b93508360208202850161312785614012565b8060005b8581101561316157848403895281516131448582612f9f565b945061314f83614012565b60209a909a019992505060010161312b565b5091979650505050505050565b612fb48161403b565b612fb48161400f565b612fb481614040565b600061319482612508565b61319e8185614018565b93506131ae818560208601614069565b6131b781614095565b9093019392505050565b60006131cc82612508565b6131d6818561078e565b93506131e6818560208601614069565b9290920192915050565b60006131fd602c83614018565b7f54726164696e672069732073757370656e64656420666f72207468697320726581527f666572656e636520726174650000000000000000000000000000000000000000602082015260400192915050565b600061325c603383614018565b7f617373657430206d757374206265206120737461626c6520726567697374657281527f6564207769746820746865207265736572766500000000000000000000000000602082015260400192915050565b60006132bb601c83614018565b7f636f6e747261637420616c726561647920696e697469616c697a656400000000815260200192915050565b60006132f4602683614018565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206181527f6464726573730000000000000000000000000000000000000000000000000000602082015260400192915050565b6000613353600f83614018565b7f6e6f2076616c6964206d656469616e0000000000000000000000000000000000815260200192915050565b600061338c601283614018565b7f617373657430206d757374206265207365740000000000000000000000000000815260200192915050565b60006133c5601c83614018565b7f65786368616e67654964496e646578206e6f7420696e2072616e676500000000815260200192915050565b60006133fe601b83614018565b7f536166654d6174683a206164646974696f6e206f766572666c6f770000000000815260200192915050565b6000613437600f8361078e565b7f436f6e7374616e7450726f6475637400000000000000000000000000000000008152600f0192915050565b6000613470603983614018565b7f416e2065786368616e676520776974682074686520737065636966696564206181527f737365747320616e642065786368616e67652065786973747300000000000000602082015260400192915050565b60006134cf601d83614018565b7f61737365743020646563696d616c73206d757374206265203c3d203138000000815260200192915050565b6000613508602583614018565b7f617373657431206d757374206265206120737461626c65206f7220636f6c6c6181527f746572616c000000000000000000000000000000000000000000000000000000602082015260400192915050565b6000613567601883614018565b7f43616c6c6572206973206e6f74207468652042726f6b65720000000000000000815260200192915050565b60006135a0603083614018565b7f65786368616e676520726174652064656e6f6d696e61746f72206d757374206281527f652067726561746572207468616e203000000000000000000000000000000000602082015260400192915050565b60006135ff601d83614018565b7f61737365743120646563696d616c73206d757374206265203c3d203138000000815260200192915050565b6000613638602683614018565b7f737072656164206d757374206265206c657373207468616e206f72206571756181527f6c20746f20310000000000000000000000000000000000000000000000000000602082015260400192915050565b6000613697601983614018565b7f70726963696e674d6f64756c65206d7573742062652073657400000000000000815260200192915050565b60006136d0602183614018565b7f536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f81527f7700000000000000000000000000000000000000000000000000000000000000602082015260400192915050565b600061372f601583614018565b7f696e76616c69642070726963696e674d6f64756c650000000000000000000000815260200192915050565b6000613768602083614018565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572815260200192915050565b60006137a1602283614018565b7f65786368616e6765206173736574732063616e2774206265206964656e74696381527f616c000000000000000000000000000000000000000000000000000000000000602082015260400192915050565b6000613800601283614018565b7f617373657431206d757374206265207365740000000000000000000000000000815260200192915050565b6000613839600b8361078e565b7f436f6e7374616e7453756d0000000000000000000000000000000000000000008152600b0192915050565b6000613872602183614018565b7f65786368616e6765496420617420696e64657820646f65736e2774206d61746381527f6800000000000000000000000000000000000000000000000000000000000000602082015260400192915050565b60006138d1601f83614018565b7f7265666572656e636552617465466565644944206d7573742062652073657400815260200192915050565b600061390a603083614018565b7f416e2065786368616e676520776974682074686520737065636966696564206981527f6420646f6573206e6f7420657869737400000000000000000000000000000000602082015260400192915050565b6000613969602183614018565b7f536f727465644f7261636c65732061646472657373206d75737420626520736581527f7400000000000000000000000000000000000000000000000000000000000000602082015260400192915050565b60006139c8601b83614018565b7f526573657276652061646472657373206d757374206265207365740000000000815260200192915050565b6000613a01601e83614018565b7f427265616b6572426f782061646472657373206d757374206265207365740000815260200192915050565b6000613a3a602883614018565b7f746f6b656e496e20616e6420746f6b656e4f7574206d757374206d617463682081527f65786368616e6765000000000000000000000000000000000000000000000000602082015260400192915050565b6000613a99601a83614018565b7f42726f6b65722061646472657373206d75737420626520736574000000000000815260200192915050565b6000613ad2602f83614018565b7f6964656e7469666965727320616e64206d6f64756c6573206d7573742062652081527f7468652073616d65206c656e6774680000000000000000000000000000000000602082015260400192915050565b80516000906040840190613b388582613177565b50602083015184820360208601526129538282613012565b80516020830190611bb98482613177565b805160a0830190613b728482613b50565b506020820151613b856020850182612fab565b506040820151613b986040850182613177565b506060820151613bab6060850182613177565b506080820151611bb96080850182613177565b8051610160830190613bd08482612fab565b506020820151613be36020850182612fab565b506040820151613bf66040850182613180565b506060820151613c096060850182613177565b506080820151613c1c6080850182613177565b5060a0820151613c2f60a0850182613177565b5060c0820151611bb960c0850182613b61565b600061259a82846131c1565b6000613c5a82866131c1565b9150613c6682856131c1565b915061295382846131c1565b6000611bfc8261342a565b6000611bfc8261382c565b60208101611bfc8284612fab565b6101608101613ca5828a612fab565b613cb26020830189612fab565b613cbf6040830188613180565b613ccc6060830187613177565b613cd96080830186613177565b613ce660a0830185613177565b610c5760c0830184613b61565b60408082528101613d05818688613060565b90508181036020830152613d1a818486612fba565b9695505050505050565b60208082528101611bf981846130b2565b60208082528101611bf98184613100565b60208101611bfc828461316e565b60208101611bfc8284613177565b60208101611bfc8284613180565b60208082528101611bf98184613189565b60208082528101611bfc816131f0565b60208082528101611bfc8161324f565b60208082528101611bfc816132ae565b60208082528101611bfc816132e7565b60208082528101611bfc81613346565b60208082528101611bfc8161337f565b60208082528101611bfc816133b8565b60208082528101611bfc816133f1565b60208082528101611bfc81613463565b60208082528101611bfc816134c2565b60208082528101611bfc816134fb565b60208082528101611bfc8161355a565b60208082528101611bfc81613593565b60208082528101611bfc816135f2565b60208082528101611bfc8161362b565b60208082528101611bfc8161368a565b60208082528101611bfc816136c3565b60208082528101611bfc81613722565b60208082528101611bfc8161375b565b60208082528101611bfc81613794565b60208082528101611bfc816137f3565b60208082528101611bfc81613865565b60208082528101611bfc816138c4565b60208082528101611bfc816138fd565b60208082528101611bfc8161395c565b60208082528101611bfc816139bb565b60208082528101611bfc816139f4565b60208082528101611bfc81613a2d565b60208082528101611bfc81613a8c565b60208082528101611bfc81613ac5565b6101608101611bfc8284613bbe565b60408101613f7e8285613177565b61259a6020830184613177565b60808101613f998287613177565b613fa66020830186613177565b613fb36040830185613177565b6129536060830184613177565b60405181810167ffffffffffffffff81118282101715613fdf57600080fd5b604052919050565b600067ffffffffffffffff821115613ffe57600080fd5b506020601f91909101601f19160190565b90565b60200190565b90815260200190565b6000611bf96020840184612a33565b6000611bfc8261404b565b151590565b6000611bfc82614030565b6001600160a01b031690565b60ff1690565b82818337506000910152565b60005b8381101561408457818101518382015260200161406c565b83811115611bb95750506000910152565b601f01601f191690565b6140a881614030565b8114611aad57600080fd5b6140a88161403b565b6140a88161400f565b6140a881614040565b6140a88161405756fea365627a7a72315820cdf63629dbfa428892096c567b160d266a74d256ec25fe8464e6f60fbc748f356c6578706572696d656e74616cf564736f6c634300051100400000000000000000000000000000000000000000000000000000000000000000", + "nonce": "0x27b" }, "additionalContracts": [], "isFixedGasLimit": false }, { - "hash": "0x04fbd963610daa728e6534a19f0829f507b04b745bbd6881cf2ba7d89f8d66bb", + "hash": "0x57a9d0fd0f801d5213e73fec37c8a6fe96c728bc577233a5608eadde1acf78bc", "transactionType": "CALL", "contractName": "BiPoolManager", - "contractAddress": "0x7B0C742c350d68986027e36bd337328Cb390c3d4", + "contractAddress": "0xf0e764Da1E61Bd5421692e5d02bdad9f3B09f825", "function": "transferOwnership(address)", "arguments": [ "0x28443b1d87db521320a6517A4F1B6Ead77F8C811" @@ -32,20 +32,61 @@ "transaction": { "type": "0x00", "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "to": "0x7b0c742c350d68986027e36bd337328cb390c3d4", + "to": "0xf0e764da1e61bd5421692e5d02bdad9f3b09f825", "gas": "0x9bf9", "value": "0x0", "data": "0xf2fde38b00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811", - "nonce": "0x23e" + "nonce": "0x27c" }, "additionalContracts": [], "isFixedGasLimit": false }, { - "hash": "0xdb44985e8a120a4e8f50698d4dd541f00856dcf43f932cf420c241eb8b2d0b28", + "hash": "0xa50ae40e0950b44791ec8283a4b1155697a168fb1f700eb7e72e40b82697374b", + "transactionType": "CREATE", + "contractName": "Broker", + "contractAddress": "0xb474472410F72c292280Ad6778978b49B8F7e68c", + "function": null, + "arguments": [ + "false" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "gas": "0x41d4af", + "value": "0x0", + "data": "0x60806040523480156200001157600080fd5b5060405162003ba238038062003ba28339810160408190526200003491620000d3565b808062000049576000805460ff191660011790555b5060006200005f6001600160e01b03620000bc16565b60008054610100600160a81b0319166101006001600160a01b038416908102919091178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a35050600180556200011b565b3390565b8051620000cd8162000101565b92915050565b600060208284031215620000e657600080fd5b6000620000f48484620000c0565b949350505050565b151590565b6200010c81620000fc565b81146200011857600080fd5b50565b613a77806200012b6000396000f3fe608060405234801561001057600080fd5b50600436106101775760003560e01c80638f32d59b116100d8578063cd3293de1161008c578063ddbbe85011610066578063ddbbe850146102ee578063f01ecd1714610301578063f2fde38b1461032557610177565b8063cd3293de146102b3578063d163b135146102c8578063d1d786b1146102db57610177565b8063a20f2305116100bd578063a20f23051461027a578063a9b5aab31461028d578063c4454fdc146102a057610177565b80638f32d59b1461025f5780639cecc80a1461026757610177565b8063462d0b2e1161012f57806373ec4cf41161011457806373ec4cf414610212578063821a816c146102255780638da5cb5b1461024a57610177565b8063462d0b2e146101f7578063715018a61461020a57610177565b8063131cab2a11610160578063131cab2a146101ba578063158ef93e146101da5780632cac2568146101e257610177565b806304710d531461017c57806304e4564014610191575b600080fd5b61018f61018a36600461283f565b610338565b005b6101a461019f366004612743565b6104ef565b6040516101b19190613870565b60405180910390f35b6101cd6101c836600461283f565b6105cc565b6040516101b191906135c2565b6101cd61075a565b6101ea610763565b6040516101b191906135b1565b61018f610205366004612879565b6107c5565b61018f610863565b6101a4610220366004612725565b6108ed565b6102386102333660046128ec565b610a48565b6040516101b1969594939291906138c0565b610252610ad3565b6040516101b19190613522565b6101cd610ae7565b61018f610275366004612725565b610b10565b6101a4610288366004612743565b610bcf565b61018f61029b36600461290a565b610c52565b6102526102ae3660046128ec565b611008565b6102bb61102f565b6040516101b19190613621565b6101a46102d63660046127b8565b61103e565b6101cd6102e9366004612725565b6111e3565b6101a46102fc3660046127b8565b6111f8565b61031461030f3660046128ec565b611369565b6040516101b195949392919061387e565b61018f610333366004612725565b6113d2565b610340610ae7565b6103655760405162461bcd60e51b815260040161035c90613750565b60405180910390fd5b816001600160a01b03166002828154811061037c57fe5b6000918252602090912001546001600160a01b0316146103ae5760405162461bcd60e51b815260040161035c906136c0565b600280546103c390600163ffffffff61140216565b815481106103cd57fe5b600091825260209091200154600280546001600160a01b0390921691839081106103f357fe5b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b03160217905550600280548061042c57fe5b6000828152602080822083017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690559092019092556001600160a01b0384168083526003909152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690555190917f29e92ab2e30f4f74283034c28c451b6faac986b554f1808101eb6418bdba19d491a25050565b6001600160a01b03851660009081526003602052604081205460ff166105275760405162461bcd60e51b815260040161035c90613720565b6040517ff670dde10000000000000000000000000000000000000000000000000000000081526001600160a01b0387169063f670dde1906105729088908890889088906004016135d0565b60206040518083038186803b15801561058a57600080fd5b505afa15801561059e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506105c2919081019061294e565b9695505050505050565b6006546040517f4f8e6e230000000000000000000000000000000000000000000000000000000081526000916001600160a01b031690634f8e6e2390610616908690600401613522565b60206040518083038186803b15801561062e57600080fd5b505afa158015610642573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061066691908101906128ce565b6106825760405162461bcd60e51b815260040161035c906136f0565b61069d6001600160a01b03841633308563ffffffff61144b16565b6040517f42966c680000000000000000000000000000000000000000000000000000000081526001600160a01b038416906342966c68906106e2908590600401613870565b602060405180830381600087803b1580156106fc57600080fd5b505af1158015610710573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061073491908101906128ce565b6107505760405162461bcd60e51b815260040161035c90613790565b5060015b92915050565b60005460ff1681565b606060028054806020026020016040519081016040528092919081815260200182805480156107bb57602002820191906000526020600020905b81546001600160a01b0316815260019091019060200180831161079d575b5050505050905090565b60005460ff16156107e85760405162461bcd60e51b815260040161035c90613650565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905561081c33611510565b60005b828110156108545761084b84848381811061083657fe5b90506020020160206102209190810190612725565b5060010161081f565b5061085e81610b10565b505050565b61086b610ae7565b6108875760405162461bcd60e51b815260040161035c90613750565b600080546040516101009091046001600160a01b0316907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080547fffffffffffffffffffffff0000000000000000000000000000000000000000ff169055565b60006108f7610ae7565b6109135760405162461bcd60e51b815260040161035c90613750565b6001600160a01b03821660009081526003602052604090205460ff161561094c5760405162461bcd60e51b815260040161035c90613640565b6001600160a01b0382166109725760405162461bcd60e51b815260040161035c90613740565b6002805460018082019092557f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace0180547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b03851690811790915560008181526003602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016909417909355915190917f2ee2cb0721ec60b86190cae5c48e25064b69b35abad32452a4ec99d232033de291a260025461075490600163ffffffff61140216565b60056020819052600091825260409091205463ffffffff80821692640100000000830490911691680100000000000000008104820b916e0100000000000000000000000000008204810b9174010000000000000000000000000000000000000000810490910b907a010000000000000000000000000000000000000000000000000000900460ff1686565b60005461010090046001600160a01b031690565b6000805461010090046001600160a01b0316610b016115b3565b6001600160a01b031614905090565b610b18610ae7565b610b345760405162461bcd60e51b815260040161035c90613750565b6001600160a01b038116610b5a5760405162461bcd60e51b815260040161035c90613820565b6006546040516001600160a01b03918216918316907fb69e1c416d8be92ac92c8e97e77c4626fba5e6ab50161099f659ea3303479e5090600090a3600680547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b6001600160a01b03851660009081526003602052604081205460ff16610c075760405162461bcd60e51b815260040161035c90613720565b6040517f93c7e3bc0000000000000000000000000000000000000000000000000000000081526001600160a01b038716906393c7e3bc906105729088908890889088906004016135d0565b610c5a610ae7565b610c765760405162461bcd60e51b815260040161035c90613750565b610c7f816115b7565b6000826001600160a01b031660001b84189050816005600083815260200190815260200160002060008201518160000160006101000a81548163ffffffff021916908363ffffffff16021790555060208201518160000160046101000a81548163ffffffff021916908363ffffffff16021790555060408201518160000160086101000a81548165ffffffffffff021916908360050b65ffffffffffff160217905550606082015181600001600e6101000a81548165ffffffffffff021916908360050b65ffffffffffff16021790555060808201518160000160146101000a81548165ffffffffffff021916908360050b65ffffffffffff16021790555060a082015181600001601a6101000a81548160ff021916908360ff160217905550905050610e7582600460008481526020019081526020016000206040518060a00160405290816000820160009054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160049054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160089054906101000a900460050b60050b60050b815260200160008201600e9054906101000a900460050b60050b60050b81526020016000820160149054906101000a900460050b60050b60050b815250506117c290919063ffffffff16565b6000828152600460209081526040918290208351815492850151858501516060870151608090970151600590810b65ffffffffffff90811674010000000000000000000000000000000000000000027fffffffffffff000000000000ffffffffffffffffffffffffffffffffffffffff99830b82166e010000000000000000000000000000027fffffffffffffffffffffffff000000000000ffffffffffffffffffffffffffff9490930b90911668010000000000000000027fffffffffffffffffffffffffffffffffffff000000000000ffffffffffffffff63ffffffff958616640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff969097167fffffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000909916989098179490941694909417959095169190911716929092179390931617909155517f1a082a1efaf1549c18917ddcb1f759680c29371609e24f4b946e93acf4ce5ad290610ffa908690869086906135f8565b60405180910390a150505050565b6002818154811061101557fe5b6000918252602090912001546001600160a01b0316905081565b6006546001600160a01b031681565b600180548101908190556001600160a01b03871660009081526003602052604081205490919060ff166110835760405162461bcd60e51b815260040161035c90613720565b6040517fd3385d050000000000000000000000000000000000000000000000000000000081526001600160a01b0389169063d3385d05906110ce908a908a908a908a906004016135d0565b602060405180830381600087803b1580156110e857600080fd5b505af11580156110fc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611120919081019061294e565b9150828211156111425760405162461bcd60e51b815260040161035c906136a0565b61114f8787848888611817565b61115a3387846118ea565b611165338686611b33565b856001600160a01b0316336001600160a01b0316887fe7b046415cac9de47940c3087e06db13a0e058ccf53ac5f0edd49ebb4c2c3a6f8b89878a6040516111af9493929190613573565b60405180910390a460015481146111d85760405162461bcd60e51b815260040161035c90613710565b509695505050505050565b60036020526000908152604090205460ff1681565b600180548101908190556001600160a01b03871660009081526003602052604081205490919060ff1661123d5760405162461bcd60e51b815260040161035c90613720565b6040517f42bfc99c0000000000000000000000000000000000000000000000000000000081526001600160a01b038916906342bfc99c90611288908a908a908a908a906004016135d0565b602060405180830381600087803b1580156112a257600080fd5b505af11580156112b6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506112da919081019061294e565b9150828210156112fc5760405162461bcd60e51b815260040161035c906137d0565b6113098787868886611817565b6113143387866118ea565b61131f338684611b33565b856001600160a01b0316336001600160a01b0316887fe7b046415cac9de47940c3087e06db13a0e058ccf53ac5f0edd49ebb4c2c3a6f8b8989886040516111af9493929190613573565b60046020526000908152604090205463ffffffff80821691640100000000810490911690680100000000000000008104600590810b916e0100000000000000000000000000008104820b9174010000000000000000000000000000000000000000909104900b85565b6113da610ae7565b6113f65760405162461bcd60e51b815260040161035c90613750565b6113ff81611510565b50565b600061144483836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250611ddf565b9392505050565b60405161150a9085907f23b872dd00000000000000000000000000000000000000000000000000000000906114889087908790879060240161354b565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611e0b565b50505050565b6001600160a01b0381166115365760405162461bcd60e51b815260040161035c90613670565b600080546040516001600160a01b038085169361010090930416917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b03909216610100027fffffffffffffffffffffff0000000000000000000000000000000000000000ff909216919091179055565b3390565b60a081015160021615806115d1575060a081015160011615155b6115ed5760405162461bcd60e51b815260040161035c906136b0565b60a081015160011615806116075750805163ffffffff1615155b6116235760405162461bcd60e51b815260040161035c90613730565b60a0810151600216158061164157506000816020015163ffffffff16115b61165d5760405162461bcd60e51b815260040161035c906136e0565b60a0810151600116158061167857506000816040015160050b135b6116945760405162461bcd60e51b815260040161035c90613770565b60a081015160021615806116af57506000816060015160050b135b6116cb5760405162461bcd60e51b815260040161035c90613660565b60a081015160041615806116e657506000816080015160050b135b6117025760405162461bcd60e51b815260040161035c90613800565b60a081015160039081161415806117265750806060015160050b816040015160050b125b6117425760405162461bcd60e51b815260040161035c90613760565b60a081015160069081161415806117665750806080015160050b816060015160050b125b6117825760405162461bcd60e51b815260040161035c906137a0565b60a081015160059081161415806117a65750806080015160050b816040015160050b125b6113ff5760405162461bcd60e51b815260040161035c90613680565b6117ca61258a565b6000808452602084015260a08201516001166117e857600060408401525b60a08201516002166117fc57600060608401525b60a082015160041661181057600060808401525b5090919050565b6001600160a01b038481169083167f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8511156118655760405162461bcd60e51b815260040161035c90613780565b7f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8311156118a55760405162461bcd60e51b815260040161035c906137b0565b6118b28288188688611ef0565b6118e1818818847fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0286611ef0565b50505050505050565b6006546040517f4f8e6e230000000000000000000000000000000000000000000000000000000081526001600160a01b0390911690634f8e6e2390611933908590600401613522565b60206040518083038186803b15801561194b57600080fd5b505afa15801561195f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061198391908101906128ce565b15611a5b576119a36001600160a01b03831684308463ffffffff61144b16565b6040517f42966c680000000000000000000000000000000000000000000000000000000081526001600160a01b038316906342966c68906119e8908490600401613870565b602060405180830381600087803b158015611a0257600080fd5b505af1158015611a16573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611a3a91908101906128ce565b611a565760405162461bcd60e51b815260040161035c90613790565b61085e565b6006546040517fcae182fe0000000000000000000000000000000000000000000000000000000081526001600160a01b039091169063cae182fe90611aa4908590600401613522565b60206040518083038186803b158015611abc57600080fd5b505afa158015611ad0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611af491908101906128ce565b15611b1b57600654611a56906001600160a01b03848116918691168463ffffffff61144b16565b60405162461bcd60e51b815260040161035c90613840565b6006546040517f4f8e6e230000000000000000000000000000000000000000000000000000000081526001600160a01b0390911690634f8e6e2390611b7c908590600401613522565b60206040518083038186803b158015611b9457600080fd5b505afa158015611ba8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611bcc91908101906128ce565b15611c86576040517f40c10f190000000000000000000000000000000000000000000000000000000081526001600160a01b038316906340c10f1990611c189086908590600401613530565b602060405180830381600087803b158015611c3257600080fd5b505af1158015611c46573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611c6a91908101906128ce565b611a565760405162461bcd60e51b815260040161035c90613810565b6006546040517fcae182fe0000000000000000000000000000000000000000000000000000000081526001600160a01b039091169063cae182fe90611ccf908590600401613522565b60206040518083038186803b158015611ce757600080fd5b505afa158015611cfb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611d1f91908101906128ce565b15611b1b576006546040517f6be383fc0000000000000000000000000000000000000000000000000000000081526001600160a01b0390911690636be383fc90611d719085908790869060040161354b565b602060405180830381600087803b158015611d8b57600080fd5b505af1158015611d9f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250611dc391908101906128ce565b611a565760405162461bcd60e51b815260040161035c90613850565b60008184841115611e035760405162461bcd60e51b815260040161035c919061362f565b505050900390565b611e1d826001600160a01b031661225a565b611e395760405162461bcd60e51b815260040161035c90613860565b60006060836001600160a01b031683604051611e559190613516565b6000604051808303816000865af19150503d8060008114611e92576040519150601f19603f3d011682016040523d82523d6000602084013e611e97565b606091505b509150915081611eb95760405162461bcd60e51b815260040161035c906136d0565b80511561150a5780806020019051611ed491908101906128ce565b61150a5760405162461bcd60e51b815260040161035c90613830565b611ef86125b8565b50600083815260056020818152604092839020835160c081018552905463ffffffff808216835264010000000082041692820192909252680100000000000000008204830b830b830b938101939093526e0100000000000000000000000000008104820b820b820b6060840152740100000000000000000000000000000000000000008104820b820b90910b60808301527a010000000000000000000000000000000000000000000000000000900460ff1660a082018190521561150a57611fbe61258a565b50600084815260046020818152604092839020835160a081018552905463ffffffff808216835264010000000082041682840152680100000000000000008104600590810b810b810b838701526e0100000000000000000000000000008204810b810b810b606084015274010000000000000000000000000000000000000000909104810b810b900b608082015283517f313ce567000000000000000000000000000000000000000000000000000000008152935190936120ef93869389936001600160a01b038a169363313ce56793818101939291829003018186803b1580156120a857600080fd5b505afa1580156120bc573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052506120e0919081019061296c565b8492919063ffffffff61229616565b9050612101818363ffffffff6123bd16565b60009485526004602090815260409586902082518154928401519784015160608501516080909501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000000090941663ffffffff928316177fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff166401000000009290991691909102979097177fffffffffffffffffffffffffffffffffffff000000000000ffffffffffffffff1668010000000000000000600598890b65ffffffffffff90811691909102919091177fffffffffffffffffffffffff000000000000ffffffffffffffffffffffffffff166e01000000000000000000000000000094890b821694909402939093177fffffffffffff000000000000ffffffffffffffffffffffffffffffffffffffff16740100000000000000000000000000000000000000009290970b929092160294909417909355505050565b6000813f7fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47081811480159061228e57508115155b949350505050565b61229e61258a565b60008260ff16600a0a84816122af57fe5b059050657fffffffffff8113156122d85760405162461bcd60e51b815260040161035c906137e0565b600081156122e657816122e9565b60015b60a08701519091506001161561238a57855187510163ffffffff1642111561231c576000604088015263ffffffff421687525b61232a87604001518261252c565b600590810b900b604088015260a08601516002161561238a57856020015187602001510163ffffffff1642111561236f576000606088015263ffffffff421660208801525b61237d87606001518261252c565b600590810b900b60608801525b60a0860151600416156123b2576123a587608001518261252c565b600590810b900b60808801525b509495945050505050565b60a0810151600116158015906124195750816040015160050b81604001517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0260050b13806124195750806040015160050b826040015160050b135b156124365760405162461bcd60e51b815260040161035c906137c0565b60a0810151600216158015906124925750816060015160050b81606001517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0260050b13806124925750806060015160050b826060015160050b135b156124af5760405162461bcd60e51b815260040161035c90613700565b60a08101516004161580159061250b5750816080015160050b81608001517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0260050b138061250b5750806080015160050b826080015160050b135b156125285760405162461bcd60e51b815260040161035c906137f0565b5050565b6000600582810b9084900b017fffffffffffffffffffffffffffffffffffffffffffffffffffff800000000001811280159061256e5750657fffffffffff8113155b6114445760405162461bcd60e51b815260040161035c90613690565b6040805160a08101825260008082526020820181905291810182905260608101829052608081019190915290565b6040805160c081018252600080825260208201819052918101829052606081018290526080810182905260a081019190915290565b8035610754816139f3565b60008083601f84011261260a57600080fd5b50813567ffffffffffffffff81111561262257600080fd5b60208301915083602082028301111561263a57600080fd5b9250929050565b805161075481613a07565b803561075481613a10565b803561075481613a19565b600060c0828403121561267457600080fd5b61267e60c061391a565b9050600061268c8484612704565b825250602061269d84848301612704565b60208301525060406126b184828501612657565b60408301525060606126c584828501612657565b60608301525060806126d984828501612657565b60808301525060a06126ed8482850161270f565b60a08301525092915050565b805161075481613a10565b803561075481613a22565b803561075481613a2b565b805161075481613a2b565b60006020828403121561273757600080fd5b600061228e84846125ed565b600080600080600060a0868803121561275b57600080fd5b600061276788886125ed565b95505060206127788882890161264c565b9450506040612789888289016125ed565b935050606061279a888289016125ed565b92505060806127ab8882890161264c565b9150509295509295909350565b60008060008060008060c087890312156127d157600080fd5b60006127dd89896125ed565b96505060206127ee89828a0161264c565b95505060406127ff89828a016125ed565b945050606061281089828a016125ed565b935050608061282189828a0161264c565b92505060a061283289828a0161264c565b9150509295509295509295565b6000806040838503121561285257600080fd5b600061285e85856125ed565b925050602061286f8582860161264c565b9150509250929050565b60008060006040848603121561288e57600080fd5b833567ffffffffffffffff8111156128a557600080fd5b6128b1868287016125f8565b935093505060206128c4868287016125ed565b9150509250925092565b6000602082840312156128e057600080fd5b600061228e8484612641565b6000602082840312156128fe57600080fd5b600061228e848461264c565b6000806000610100848603121561292057600080fd5b600061292c868661264c565b935050602061293d868287016125ed565b92505060406128c486828701612662565b60006020828403121561296057600080fd5b600061228e84846126f9565b60006020828403121561297e57600080fd5b600061228e848461271a565b600061299683836129ad565b505060200190565b6129a78161398d565b82525050565b6129a781613959565b60006129c182613947565b6129cb818561394b565b93506129d683613941565b8060005b838110156123b25781516129ee888261298a565b97506129f983613941565b9250506001016129da565b6129a781613964565b6129a781613969565b6000612a2182613947565b612a2b8185613954565b9350612a3b81856020860161399f565b9290920192915050565b6129a781613994565b6129a78161396c565b6000612a6282613947565b612a6c818561394b565b9350612a7c81856020860161399f565b612a85816139cb565b9093019392505050565b6000612a9c602b8361394b565b7f45786368616e676550726f766964657220616c7265616479206578697374732081527f696e20746865206c697374000000000000000000000000000000000000000000602082015260400192915050565b6000612afb601c8361394b565b7f636f6e747261637420616c726561647920696e697469616c697a656400000000815260200192915050565b6000612b34601e8361394b565b7f6c696d6974312063616e2774206265207a65726f206966206163746976650000815260200192915050565b6000612b6d60268361394b565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206181527f6464726573730000000000000000000000000000000000000000000000000000602082015260400192915050565b6000612bcc60278361394b565b7f6c696d6974476c6f62616c206d7573742062652067726561746572207468616e81527f206c696d69743000000000000000000000000000000000000000000000000000602082015260400192915050565b6000612c2b60178361394b565b7f696e743438206164646974696f6e206f766572666c6f77000000000000000000815260200192915050565b6000612c6460148361394b565b7f616d6f756e74496e4d6178206578636565646564000000000000000000000000815260200192915050565b6000612c9d60198361394b565b7f4c3120776974686f7574204c30206e6f7420616c6c6f77656400000000000000815260200192915050565b6000612cd6601c8361394b565b7f696e64657820646f65736e2774206d617463682070726f766964657200000000815260200192915050565b6000612d0f60208361394b565b7f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815260200192915050565b6000612d4860218361394b565b7f74696d6573746570312063616e2774206265207a65726f20696620616374697681527f6500000000000000000000000000000000000000000000000000000000000000602082015260400192915050565b6000612da760248361394b565b7f546f6b656e206d7573742062652061207265736572766520737461626c65206181527f7373657400000000000000000000000000000000000000000000000000000000602082015260400192915050565b6000612e06600b8361394b565b7f4c31204578636565646564000000000000000000000000000000000000000000815260200192915050565b6000612e3f600e8361394b565b7f7265656e7472616e742063616c6c000000000000000000000000000000000000815260200192915050565b6000612e78601f8361394b565b7f45786368616e676550726f766964657220646f6573206e6f7420657869737400815260200192915050565b6000612eb160218361394b565b7f74696d6573746570302063616e2774206265207a65726f20696620616374697681527f6500000000000000000000000000000000000000000000000000000000000000602082015260400192915050565b6000612f1060238361394b565b7f45786368616e676550726f766964657220616464726573732063616e2774206281527f6520300000000000000000000000000000000000000000000000000000000000602082015260400192915050565b6000612f6f60208361394b565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572815260200192915050565b6000612fa860228361394b565b7f6c696d697431206d7573742062652067726561746572207468616e206c696d6981527f7430000000000000000000000000000000000000000000000000000000000000602082015260400192915050565b6000613007601e8361394b565b7f6c696d6974302063616e2774206265207a65726f206966206163746976650000815260200192915050565b600061304060128361394b565b7f616d6f756e74496e20746f6f206c617267650000000000000000000000000000815260200192915050565b600061307960228361394b565b7f4275726e696e67206f662074686520737461626c65206173736574206661696c81527f6564000000000000000000000000000000000000000000000000000000000000602082015260400192915050565b60006130d860278361394b565b7f6c696d6974476c6f62616c206d7573742062652067726561746572207468616e81527f206c696d69743100000000000000000000000000000000000000000000000000602082015260400192915050565b600061313760138361394b565b7f616d6f756e744f757420746f6f206c6172676500000000000000000000000000815260200192915050565b6000613170600b8361394b565b7f4c30204578636565646564000000000000000000000000000000000000000000815260200192915050565b60006131a960148361394b565b7f616d6f756e744f75744d696e206e6f74206d6574000000000000000000000000815260200192915050565b60006131e2600f8361394b565b7f64466c6f7720746f6f206c617267650000000000000000000000000000000000815260200192915050565b600061321b600b8361394b565b7f4c47204578636565646564000000000000000000000000000000000000000000815260200192915050565b600061325460238361394b565b7f6c696d6974476c6f62616c2063616e2774206265207a65726f2069662061637481527f6976650000000000000000000000000000000000000000000000000000000000602082015260400192915050565b60006132b360228361394b565b7f4d696e74696e67206f662074686520737461626c65206173736574206661696c81527f6564000000000000000000000000000000000000000000000000000000000000602082015260400192915050565b6000613312601b8361394b565b7f526573657276652061646472657373206d757374206265207365740000000000815260200192915050565b600061334b602a8361394b565b7f5361666545524332303a204552433230206f7065726174696f6e20646964206e81527f6f74207375636365656400000000000000000000000000000000000000000000602082015260400192915050565b60006133aa60298361394b565b7f546f6b656e206d75737420626520737461626c65206f7220636f6c6c6174657281527f616c206173736572740000000000000000000000000000000000000000000000602082015260400192915050565b600061340960278361394b565b7f5472616e73666572206f662074686520636f6c6c61746572616c20617373657481527f206661696c656400000000000000000000000000000000000000000000000000602082015260400192915050565b6000613468601f8361394b565b7f5361666545524332303a2063616c6c20746f206e6f6e2d636f6e747261637400815260200192915050565b805160c08301906134a58482613504565b5060208201516134b86020850182613504565b5060408201516134cb6040850182612a4e565b5060608201516134de6060850182612a4e565b5060808201516134f16080850182612a4e565b5060a082015161150a60a085018261350d565b6129a78161397e565b6129a781613987565b60006114448284612a16565b6020810161075482846129ad565b6040810161353e828561299e565b6114446020830184612a0d565b6060810161355982866129ad565b61356660208301856129ad565b61228e6040830184612a0d565b6080810161358182876129ad565b61358e60208301866129ad565b61359b6040830185612a0d565b6135a86060830184612a0d565b95945050505050565b6020808252810161144481846129b6565b602081016107548284612a04565b608081016135de8287612a0d565b6135eb60208301866129ad565b61359b60408301856129ad565b61010081016136078286612a0d565b61361460208301856129ad565b61228e6040830184613494565b602081016107548284612a45565b602080825281016114448184612a57565b6020808252810161075481612a8f565b6020808252810161075481612aee565b6020808252810161075481612b27565b6020808252810161075481612b60565b6020808252810161075481612bbf565b6020808252810161075481612c1e565b6020808252810161075481612c57565b6020808252810161075481612c90565b6020808252810161075481612cc9565b6020808252810161075481612d02565b6020808252810161075481612d3b565b6020808252810161075481612d9a565b6020808252810161075481612df9565b6020808252810161075481612e32565b6020808252810161075481612e6b565b6020808252810161075481612ea4565b6020808252810161075481612f03565b6020808252810161075481612f62565b6020808252810161075481612f9b565b6020808252810161075481612ffa565b6020808252810161075481613033565b602080825281016107548161306c565b60208082528101610754816130cb565b602080825281016107548161312a565b6020808252810161075481613163565b602080825281016107548161319c565b60208082528101610754816131d5565b602080825281016107548161320e565b6020808252810161075481613247565b60208082528101610754816132a6565b6020808252810161075481613305565b602080825281016107548161333e565b602080825281016107548161339d565b60208082528101610754816133fc565b602080825281016107548161345b565b602081016107548284612a0d565b60a0810161388c8288613504565b6138996020830187613504565b6138a66040830186612a4e565b6138b36060830185612a4e565b6105c26080830184612a4e565b60c081016138ce8289613504565b6138db6020830188613504565b6138e86040830187612a4e565b6138f56060830186612a4e565b6139026080830185612a4e565b61390f60a083018461350d565b979650505050505050565b60405181810167ffffffffffffffff8111828210171561393957600080fd5b604052919050565b60200190565b5190565b90815260200190565b919050565b600061075482613972565b151590565b90565b60050b90565b6001600160a01b031690565b63ffffffff1690565b60ff1690565b6000610754825b600061075482613959565b60005b838110156139ba5781810151838201526020016139a2565b8381111561150a5750506000910152565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690565b6139fc81613959565b81146113ff57600080fd5b6139fc81613964565b6139fc81613969565b6139fc8161396c565b6139fc8161397e565b6139fc8161398756fea365627a7a72315820f3bbc761705c749c1364f6802ccd5fbc53410df4ea458571e26593e8cf6c7c156c6578706572696d656e74616cf564736f6c634300051100400000000000000000000000000000000000000000000000000000000000000000", + "nonce": "0x27d" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0x9bba48eafcd7f2874a0489408a33cdce099f7d5e8b8b8d25328e7039c458e4fa", + "transactionType": "CALL", + "contractName": "Broker", + "contractAddress": "0xb474472410F72c292280Ad6778978b49B8F7e68c", + "function": "transferOwnership(address)", + "arguments": [ + "0x28443b1d87db521320a6517A4F1B6Ead77F8C811" + ], + "transaction": { + "type": "0x00", + "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", + "to": "0xb474472410f72c292280ad6778978b49b8f7e68c", + "gas": "0xa567", + "value": "0x0", + "data": "0xf2fde38b00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811", + "nonce": "0x27e" + }, + "additionalContracts": [], + "isFixedGasLimit": false + }, + { + "hash": "0x4fadf58b85e9e14c012e4c340249c29904eeb249bd376ee97fe7618eb2a1ddb4", "transactionType": "CREATE", "contractName": "SortedOracles", - "contractAddress": "0x6aB692fd745D08d8Ae5c95033F07C89fDAfC1711", + "contractAddress": "0x2e229aa95c67baa6c08073f26ABA8E4083e98489", "function": null, "arguments": [ "false" @@ -55,17 +96,17 @@ "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", "gas": "0x30fb25", "value": "0x0", - "data": "0x60806040523480156200001157600080fd5b5060405162002c3638038062002c36833981810160405260208110156200003757600080fd5b50518060006200004f6001600160e01b03620000bb16565b600080546001600160a01b0319166001600160a01b0383169081178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a35080620000b3576000805460ff60a01b1916600160a01b1790555b5050620000bf565b3390565b612b6780620000cf6000396000f3fe608060405234801561001057600080fd5b50600436106101c45760003560e01c80638e749281116100f9578063ef90e1b011610097578063f414c5e411610071578063f414c5e41461068f578063fc20935d14610697578063fe4b84df146106c3578063ffe736bf146106e0576101c4565b8063ef90e1b0146105fc578063f0ca4adb1461063b578063f2fde38b14610669576101c4565b8063b9292158116100d3578063b929215814610567578063bbc66a941461058d578063dd34ca3b146105b3578063ebc1d6bb146105df576101c4565b80638e749281146104bd5780638f32d59b14610533578063a00a8b2c1461053b576101c4565b806353a57297116101665780636deb6799116101405780636deb67991461042f578063715018a61461045557806380e507441461045d5780638da5cb5b14610499576101c4565b806353a57297146103a557806354255be0146103db5780636dd6ef0c14610409576101c4565b8063158ef93e116101a2578063158ef93e1461032d5780632e86bc0114610349578063370c998e1461036f578063493a353c1461039d576101c4565b806302f55b61146101c9578063040bbd35146102cd578063071b48fc146102f5575b600080fd5b6101ef600480360360208110156101df57600080fd5b50356001600160a01b0316610729565b60405180806020018060200180602001848103845287818151815260200191508051906020019060200280838360005b8381101561023757818101518382015260200161021f565b50505050905001848103835286818151815260200191508051906020019060200280838360005b8381101561027657818101518382015260200161025e565b50505050905001848103825285818151815260200191508051906020019060200280838360005b838110156102b557818101518382015260200161029d565b50505050905001965050505050505060405180910390f35b6102f3600480360360208110156102e357600080fd5b50356001600160a01b03166109b3565b005b61031b6004803603602081101561030b57600080fd5b50356001600160a01b0316610ac9565b60408051918252519081900360200190f35b610335610b7e565b604080519115158252519081900360200190f35b61031b6004803603602081101561035f57600080fd5b50356001600160a01b0316610b9f565b6103356004803603604081101561038557600080fd5b506001600160a01b0381358116916020013516610bb1565b61031b610bd1565b6102f3600480360360608110156103bb57600080fd5b506001600160a01b03813581169160208101359091169060400135610bd7565b6103e3610e7a565b604080519485526020850193909352838301919091526060830152519081900360800190f35b61031b6004803603602081101561041f57600080fd5b50356001600160a01b0316610e86565b61031b6004803603602081101561044557600080fd5b50356001600160a01b0316610f07565b6102f3610f49565b6102f36004803603608081101561047357600080fd5b506001600160a01b03813581169160208101359160408201358116916060013516611004565b6104a1611702565b604080516001600160a01b039092168252519081900360200190f35b6104e3600480360360208110156104d357600080fd5b50356001600160a01b0316611712565b60408051602080825283518183015283519192839290830191858101910280838360005b8381101561051f578181015183820152602001610507565b505050509050019250505060405180910390f35b610335611788565b6104a16004803603604081101561055157600080fd5b506001600160a01b0381351690602001356117ac565b6101ef6004803603602081101561057d57600080fd5b50356001600160a01b03166117e1565b61031b600480360360208110156105a357600080fd5b50356001600160a01b0316611867565b6102f3600480360360408110156105c957600080fd5b506001600160a01b0381351690602001356118e8565b6102f3600480360360208110156105f557600080fd5b5035611a3f565b6106226004803603602081101561061257600080fd5b50356001600160a01b0316611b53565b6040805192835260208301919091528051918290030190f35b6102f36004803603604081101561065157600080fd5b506001600160a01b0381358116916020013516611c2d565b6102f36004803603602081101561067f57600080fd5b50356001600160a01b0316611dd1565b6104a1611e36565b6102f3600480360360408110156106ad57600080fd5b506001600160a01b038135169060200135611e45565b6102f3600480360360208110156106d957600080fd5b5035611f8d565b610706600480360360208110156106f657600080fd5b50356001600160a01b031661204e565b6040805192151583526001600160a01b0390911660208301528051918290030190f35b6001600160a01b03811660009081526001602052604080822081517f6cfa387300000000000000000000000000000000000000000000000000000000815260048101919091529051606092839283927399edce8143ff8aefa1fbb6c2103b349add2b951992636cfa38739260248082019391829003018186803b1580156107af57600080fd5b505af41580156107c3573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052606081101561080a57600080fd5b810190808051604051939291908464010000000082111561082a57600080fd5b90830190602082018581111561083f57600080fd5b825186602082028301116401000000008211171561085c57600080fd5b82525081516020918201928201910280838360005b83811015610889578181015183820152602001610871565b50505050905001604052602001805160405193929190846401000000008211156108b257600080fd5b9083019060208201858111156108c757600080fd5b82518660208202830111640100000000821117156108e457600080fd5b82525081516020918201928201910280838360005b838110156109115781810151838201526020016108f9565b505050509050016040526020018051604051939291908464010000000082111561093a57600080fd5b90830190602082018581111561094f57600080fd5b825186602082028301116401000000008211171561096c57600080fd5b82525081516020918201928201910280838360005b83811015610999578181015183820152602001610981565b505050509050016040525050509250925092509193909250565b6109bb611788565b610a0c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116610a67576040805162461bcd60e51b815260206004820152601e60248201527f427265616b6572426f782061646472657373206d757374206265207365740000604482015290519081900360640190fd5b600780547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383169081179091556040517f21921b3b46ef2c939e85d6a14410c6e3b9ce132b66e944357ff4f789f68e00e290600090a250565b6001600160a01b038116600090815260026020908152604080832081517f59d556a8000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b9519926359d556a89260248082019391829003018186803b158015610b4a57600080fd5b505af4158015610b5e573d6000803e3d6000fd5b505050506040513d6020811015610b7457600080fd5b505190505b919050565b60005474010000000000000000000000000000000000000000900460ff1681565b60066020526000908152604090205481565b600360209081526000928352604080842090915290825290205460ff1681565b60055481565b610bdf611788565b610c30576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03831615801590610c5057506001600160a01b03821615155b8015610c7357506001600160a01b03831660009081526004602052604090205481105b8015610cba57506001600160a01b03838116600090815260046020526040902080549184169183908110610ca357fe5b6000918252602090912001546001600160a01b0316145b610cf55760405162461bcd60e51b81526004018080602001828103825260568152602001806129ed6056913960600191505060405180910390fd5b6001600160a01b038084166000818152600360209081526040808320948716835293815283822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690559181526004909152208054610d5e90600163ffffffff61220416565b81548110610d6857fe5b60009182526020808320909101546001600160a01b03868116845260049092526040909220805491909216919083908110610d9f57fe5b600091825260208083209190910180547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b03948516179055918516815260049091526040902054610df9906001612204565b6001600160a01b0384166000908152600460205260409020610e1b9082612955565b50610e26838361224d565b15610e3557610e3583836123cc565b816001600160a01b0316836001600160a01b03167f6dc84b66cc948d847632b9d829f7cb1cb904fbf2c084554a9bc22ad9d845334060405160405180910390a3505050565b60018060028190919293565b6001600160a01b038116600090815260026020908152604080832081517f6eafa6c3000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b951992636eafa6c39260248082019391829003018186803b158015610b4a57600080fd5b6001600160a01b038116600090815260066020526040812054610f2d5750600554610b79565b506001600160a01b031660009081526006602052604090205490565b610f51611788565b610fa2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b6001600160a01b0384166000908152600360209081526040808320338452909152902054849060ff166110685760405162461bcd60e51b8152600401808060200182810382526027815260200180612a436027913960400191505060405180910390fd5b6001600160a01b038516600090815260016020908152604080832081517f59d556a8000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b9519926359d556a89260248082019391829003018186803b1580156110e957600080fd5b505af41580156110fd573d6000803e3d6000fd5b505050506040513d602081101561111357600080fd5b50516001600160a01b03871660009081526001602090815260409182902082517f95073a79000000000000000000000000000000000000000000000000000000008152600481019190915233602482015291519293507399edce8143ff8aefa1fbb6c2103b349add2b9519926395073a79926044808201939291829003018186803b1580156111a157600080fd5b505af41580156111b5573d6000803e3d6000fd5b505050506040513d60208110156111cb57600080fd5b505115611329576001600160a01b0380871660009081526001602052604080822081517f832a214700000000000000000000000000000000000000000000000000000000815260048101919091523360248201526044810189905287841660648201529286166084840152517399edce8143ff8aefa1fbb6c2103b349add2b95199263832a21479260a4808301939192829003018186803b15801561126f57600080fd5b505af4158015611283573d6000803e3d6000fd5b505050506001600160a01b03861660009081526002602052604080822081517fc1e728e9000000000000000000000000000000000000000000000000000000008152600481019190915233602482015290517399edce8143ff8aefa1fbb6c2103b349add2b95199263c1e728e99260448082019391829003018186803b15801561130c57600080fd5b505af4158015611320573d6000803e3d6000fd5b505050506113df565b6001600160a01b0380871660009081526001602052604080822081517fd4a0927200000000000000000000000000000000000000000000000000000000815260048101919091523360248201526044810189905287841660648201529286166084840152517399edce8143ff8aefa1fbb6c2103b349add2b95199263d4a092729260a4808301939192829003018186803b1580156113c657600080fd5b505af41580156113da573d6000803e3d6000fd5b505050505b6001600160a01b03861660009081526002602090815260409182902082517f0944c5940000000000000000000000000000000000000000000000000000000081526004810182905292517399edce8143ff8aefa1fbb6c2103b349add2b95199363d4a0927293339242928792630944c59492602480840193829003018186803b15801561146b57600080fd5b505af415801561147f573d6000803e3d6000fd5b505050506040513d602081101561149557600080fd5b5051604080517fffffffff0000000000000000000000000000000000000000000000000000000060e088901b16815260048101959095526001600160a01b0393841660248601526044850192909252919091166064830152600060848301819052905160a480840193829003018186803b15801561151257600080fd5b505af4158015611526573d6000803e3d6000fd5b5050604080514281526020810189905281513394506001600160a01b038b1693507f7cebb17173a9ed273d2b7538f64395c0ebf352ff743f1cf8ce66b437a6144213929181900390910190a36001600160a01b038616600090815260016020908152604080832081517f59d556a8000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b9519926359d556a89260248082019391829003018186803b1580156115f357600080fd5b505af4158015611607573d6000803e3d6000fd5b505050506040513d602081101561161d57600080fd5b50519050818114611668576040805182815290516001600160a01b038916917fa9981ebfc3b766a742486e898f54959b050a66006dbce1a4155c1f84a08bcf41919081900360200190a25b6007546001600160a01b0316156116f957600754604080517fab02e6c00000000000000000000000000000000000000000000000000000000081526001600160a01b038a811660048301529151919092169163ab02e6c091602480830192600092919082900301818387803b1580156116e057600080fd5b505af11580156116f4573d6000803e3d6000fd5b505050505b50505050505050565b6000546001600160a01b03165b90565b6001600160a01b03811660009081526004602090815260409182902080548351818402810184019094528084526060939283018282801561177c57602002820191906000526020600020905b81546001600160a01b0316815260019091019060200180831161175e575b50505050509050919050565b600080546001600160a01b031661179d6127a8565b6001600160a01b031614905090565b600460205281600052604060002081815481106117c557fe5b6000918252602090912001546001600160a01b03169150829050565b6001600160a01b03811660009081526002602052604080822081517f6cfa387300000000000000000000000000000000000000000000000000000000815260048101919091529051606092839283927399edce8143ff8aefa1fbb6c2103b349add2b951992636cfa38739260248082019391829003018186803b1580156107af57600080fd5b6001600160a01b038116600090815260016020908152604080832081517f6eafa6c3000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b951992636eafa6c39260248082019391829003018186803b158015610b4a57600080fd5b6001600160a01b038216158015906119ad57506001600160a01b03821660009081526002602090815260409182902082517f6eafa6c3000000000000000000000000000000000000000000000000000000008152600481019190915291517399edce8143ff8aefa1fbb6c2103b349add2b951992636eafa6c3926024808301939192829003018186803b15801561197e57600080fd5b505af4158015611992573d6000803e3d6000fd5b505050506040513d60208110156119a857600080fd5b505181105b6119e85760405162461bcd60e51b81526004018080602001828103825260348152602001806129b96034913960400191505060405180910390fd5b60005b81811015611a3a576000806119ff8561204e565b915091508115611a1857611a1385826123cc565b611a1f565b5050611a3a565b50611a33905081600163ffffffff6127ac16565b90506119eb565b505050565b611a47611788565b611a98576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60008111611ad75760405162461bcd60e51b8152600401808060200182810382526021815260200180612b126021913960400191505060405180910390fd5b600554811415611b185760405162461bcd60e51b8152600401808060200182810382526022815260200180612af06022913960400191505060405180910390fd5b60058190556040805182815290517fc68a9b88effd8a11611ff410efbc83569f0031b7bc70dd455b61344c7f0a042f9181900360200190a150565b6001600160a01b038116600090815260016020908152604080832081517f59d556a80000000000000000000000000000000000000000000000000000000081526004810191909152905183927399edce8143ff8aefa1fbb6c2103b349add2b9519926359d556a89260248083019392829003018186803b158015611bd657600080fd5b505af4158015611bea573d6000803e3d6000fd5b505050506040513d6020811015611c0057600080fd5b5051611c0b84611867565b15611c205769d3c21bcecceda1000000611c23565b60005b915091505b915091565b611c35611788565b611c86576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03821615801590611ca657506001600160a01b03811615155b8015611cd857506001600160a01b0380831660009081526003602090815260408083209385168352929052205460ff16155b611d135760405162461bcd60e51b815260040180806020018281038252605e815260200180612a6a605e913960600191505060405180910390fd5b6001600160a01b03808316600081815260036020908152604080832094861680845294825280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660019081179091558484526004835281842080549182018155845291832090910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001685179055517f828d2be040dede7698182e08dfa8bfbd663c879aee772509c4a2bd961d0ed43f9190a35050565b611dd9611788565b611e2a576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b611e3381612806565b50565b6007546001600160a01b031681565b611e4d611788565b611e9e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60008111611edd5760405162461bcd60e51b8152600401808060200182810382526021815260200180612b126021913960400191505060405180910390fd5b6001600160a01b038216600090815260066020526040902054811415611f345760405162461bcd60e51b8152600401808060200182810382526028815260200180612ac86028913960400191505060405180910390fd5b6001600160a01b0382166000818152600660209081526040918290208490558151928352820183905280517ff8324c8592dfd9991ee3e717351afe0a964605257959e3d99b0eb3d45bff94229281900390910190a15050565b60005474010000000000000000000000000000000000000000900460ff1615611ffd576040805162461bcd60e51b815260206004820152601c60248201527f636f6e747261637420616c726561647920696e697469616c697a656400000000604482015290519081900360640190fd5b600080547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000017905561204533612806565b611e3381611a3f565b6000806001600160a01b03831661206457600080fd5b6001600160a01b038316600090815260026020908152604080832081517fd938ec7b000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b95199263d938ec7b9260248082019391829003018186803b1580156120e557600080fd5b505af41580156120f9573d6000803e3d6000fd5b505050506040513d602081101561210f57600080fd5b50516001600160a01b03808616600090815260026020908152604080832081517f7c6bb862000000000000000000000000000000000000000000000000000000008152600481019190915293851660248501525193945090927399edce8143ff8aefa1fbb6c2103b349add2b951992637c6bb862926044808301939192829003018186803b1580156121a057600080fd5b505af41580156121b4573d6000803e3d6000fd5b505050506040513d60208110156121ca57600080fd5b505190506121d785610f07565b6121e7428363ffffffff61220416565b106121f85750600192509050611c28565b50600092509050915091565b600061224683836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506128be565b9392505050565b6001600160a01b03808316600090815260016020908152604080832081517f95073a79000000000000000000000000000000000000000000000000000000008152600481019190915293851660248501525191927399edce8143ff8aefa1fbb6c2103b349add2b9519926395073a7992604480840193919291829003018186803b1580156122da57600080fd5b505af41580156122ee573d6000803e3d6000fd5b505050506040513d602081101561230457600080fd5b5051801561224657506001600160a01b0380841660009081526002602090815260409182902082517f95073a790000000000000000000000000000000000000000000000000000000081526004810191909152928516602484015290517399edce8143ff8aefa1fbb6c2103b349add2b9519926395073a79926044808301939192829003018186803b15801561239957600080fd5b505af41580156123ad573d6000803e3d6000fd5b505050506040513d60208110156123c357600080fd5b50519392505050565b6123d582610e86565b60011480156123e957506123e9828261224d565b156123f3576127a4565b6001600160a01b038216600090815260016020908152604080832081517f59d556a8000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b9519926359d556a89260248082019391829003018186803b15801561247457600080fd5b505af4158015612488573d6000803e3d6000fd5b505050506040513d602081101561249e57600080fd5b50516001600160a01b0380851660009081526001602052604080822081517fc1e728e900000000000000000000000000000000000000000000000000000000815260048101919091529286166024840152519293507399edce8143ff8aefa1fbb6c2103b349add2b95199263c1e728e9926044808201939291829003018186803b15801561252b57600080fd5b505af415801561253f573d6000803e3d6000fd5b5050506001600160a01b0380851660009081526002602052604080822081517fc1e728e900000000000000000000000000000000000000000000000000000000815260048101919091529286166024840152517399edce8143ff8aefa1fbb6c2103b349add2b9519935063c1e728e9926044808201939291829003018186803b1580156125cb57600080fd5b505af41580156125df573d6000803e3d6000fd5b50506040516001600160a01b038086169350861691507fe21a44017b6fa1658d84e937d56ff408501facdb4ff7427c479ac460d76f789390600090a36001600160a01b038316600090815260016020908152604080832081517f59d556a8000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b9519926359d556a89260248082019391829003018186803b15801561269c57600080fd5b505af41580156126b0573d6000803e3d6000fd5b505050506040513d60208110156126c657600080fd5b505190508181146127a1576040805182815290516001600160a01b038616917fa9981ebfc3b766a742486e898f54959b050a66006dbce1a4155c1f84a08bcf41919081900360200190a26007546001600160a01b0316156127a157600754604080517fab02e6c00000000000000000000000000000000000000000000000000000000081526001600160a01b0387811660048301529151919092169163ab02e6c091602480830192600092919082900301818387803b15801561278857600080fd5b505af115801561279c573d6000803e3d6000fd5b505050505b50505b5050565b3390565b600082820183811015612246576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b6001600160a01b03811661284b5760405162461bcd60e51b81526004018080602001828103825260268152602001806129936026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b6000818484111561294d5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156129125781810151838201526020016128fa565b50505050905090810190601f16801561293f5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b815481835581811115611a3a57600083815260209020611a3a91810190830161170f91905b8082111561298e576000815560010161297a565b509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373746f6b656e2061646472206e756c6c206f7220747279696e6720746f2072656d6f766520746f6f206d616e79207265706f727473746f6b656e2061646472206e756c6c206f72206f7261636c652061646472206e756c6c206f7220696e646578206f6620746f6b656e206f7261636c65206e6f74206d617070656420746f206f7261636c65206164647273656e64657220776173206e6f7420616e206f7261636c6520666f7220746f6b656e2061646472746f6b656e206164647220776173206e756c6c206f72206f7261636c65206164647220776173206e756c6c206f72206f7261636c65206164647220697320616c726561647920616e206f7261636c6520666f7220746f6b656e2061646472746f6b656e207265706f72744578706972795365636f6e6473206861736e2774206368616e6765647265706f72744578706972795365636f6e6473206861736e2774206368616e6765647265706f727420657870697279207365636f6e6473206d757374206265203e2030a265627a7a72315820aa96a627e6a4b0fe97c34bf15e71b7648d6d3eb8970113a3abcd9fbccf78532664736f6c634300051100320000000000000000000000000000000000000000000000000000000000000000", - "nonce": "0x23f" + "data": "0x60806040523480156200001157600080fd5b5060405162002c3638038062002c36833981810160405260208110156200003757600080fd5b50518060006200004f6001600160e01b03620000bb16565b600080546001600160a01b0319166001600160a01b0383169081178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a35080620000b3576000805460ff60a01b1916600160a01b1790555b5050620000bf565b3390565b612b6780620000cf6000396000f3fe608060405234801561001057600080fd5b50600436106101c45760003560e01c80638e749281116100f9578063ef90e1b011610097578063f414c5e411610071578063f414c5e41461068f578063fc20935d14610697578063fe4b84df146106c3578063ffe736bf146106e0576101c4565b8063ef90e1b0146105fc578063f0ca4adb1461063b578063f2fde38b14610669576101c4565b8063b9292158116100d3578063b929215814610567578063bbc66a941461058d578063dd34ca3b146105b3578063ebc1d6bb146105df576101c4565b80638e749281146104bd5780638f32d59b14610533578063a00a8b2c1461053b576101c4565b806353a57297116101665780636deb6799116101405780636deb67991461042f578063715018a61461045557806380e507441461045d5780638da5cb5b14610499576101c4565b806353a57297146103a557806354255be0146103db5780636dd6ef0c14610409576101c4565b8063158ef93e116101a2578063158ef93e1461032d5780632e86bc0114610349578063370c998e1461036f578063493a353c1461039d576101c4565b806302f55b61146101c9578063040bbd35146102cd578063071b48fc146102f5575b600080fd5b6101ef600480360360208110156101df57600080fd5b50356001600160a01b0316610729565b60405180806020018060200180602001848103845287818151815260200191508051906020019060200280838360005b8381101561023757818101518382015260200161021f565b50505050905001848103835286818151815260200191508051906020019060200280838360005b8381101561027657818101518382015260200161025e565b50505050905001848103825285818151815260200191508051906020019060200280838360005b838110156102b557818101518382015260200161029d565b50505050905001965050505050505060405180910390f35b6102f3600480360360208110156102e357600080fd5b50356001600160a01b03166109b3565b005b61031b6004803603602081101561030b57600080fd5b50356001600160a01b0316610ac9565b60408051918252519081900360200190f35b610335610b7e565b604080519115158252519081900360200190f35b61031b6004803603602081101561035f57600080fd5b50356001600160a01b0316610b9f565b6103356004803603604081101561038557600080fd5b506001600160a01b0381358116916020013516610bb1565b61031b610bd1565b6102f3600480360360608110156103bb57600080fd5b506001600160a01b03813581169160208101359091169060400135610bd7565b6103e3610e7a565b604080519485526020850193909352838301919091526060830152519081900360800190f35b61031b6004803603602081101561041f57600080fd5b50356001600160a01b0316610e86565b61031b6004803603602081101561044557600080fd5b50356001600160a01b0316610f07565b6102f3610f49565b6102f36004803603608081101561047357600080fd5b506001600160a01b03813581169160208101359160408201358116916060013516611004565b6104a1611702565b604080516001600160a01b039092168252519081900360200190f35b6104e3600480360360208110156104d357600080fd5b50356001600160a01b0316611712565b60408051602080825283518183015283519192839290830191858101910280838360005b8381101561051f578181015183820152602001610507565b505050509050019250505060405180910390f35b610335611788565b6104a16004803603604081101561055157600080fd5b506001600160a01b0381351690602001356117ac565b6101ef6004803603602081101561057d57600080fd5b50356001600160a01b03166117e1565b61031b600480360360208110156105a357600080fd5b50356001600160a01b0316611867565b6102f3600480360360408110156105c957600080fd5b506001600160a01b0381351690602001356118e8565b6102f3600480360360208110156105f557600080fd5b5035611a3f565b6106226004803603602081101561061257600080fd5b50356001600160a01b0316611b53565b6040805192835260208301919091528051918290030190f35b6102f36004803603604081101561065157600080fd5b506001600160a01b0381358116916020013516611c2d565b6102f36004803603602081101561067f57600080fd5b50356001600160a01b0316611dd1565b6104a1611e36565b6102f3600480360360408110156106ad57600080fd5b506001600160a01b038135169060200135611e45565b6102f3600480360360208110156106d957600080fd5b5035611f8d565b610706600480360360208110156106f657600080fd5b50356001600160a01b031661204e565b6040805192151583526001600160a01b0390911660208301528051918290030190f35b6001600160a01b03811660009081526001602052604080822081517f6cfa387300000000000000000000000000000000000000000000000000000000815260048101919091529051606092839283927399edce8143ff8aefa1fbb6c2103b349add2b951992636cfa38739260248082019391829003018186803b1580156107af57600080fd5b505af41580156107c3573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052606081101561080a57600080fd5b810190808051604051939291908464010000000082111561082a57600080fd5b90830190602082018581111561083f57600080fd5b825186602082028301116401000000008211171561085c57600080fd5b82525081516020918201928201910280838360005b83811015610889578181015183820152602001610871565b50505050905001604052602001805160405193929190846401000000008211156108b257600080fd5b9083019060208201858111156108c757600080fd5b82518660208202830111640100000000821117156108e457600080fd5b82525081516020918201928201910280838360005b838110156109115781810151838201526020016108f9565b505050509050016040526020018051604051939291908464010000000082111561093a57600080fd5b90830190602082018581111561094f57600080fd5b825186602082028301116401000000008211171561096c57600080fd5b82525081516020918201928201910280838360005b83811015610999578181015183820152602001610981565b505050509050016040525050509250925092509193909250565b6109bb611788565b610a0c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116610a67576040805162461bcd60e51b815260206004820152601e60248201527f427265616b6572426f782061646472657373206d757374206265207365740000604482015290519081900360640190fd5b600780547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383169081179091556040517f21921b3b46ef2c939e85d6a14410c6e3b9ce132b66e944357ff4f789f68e00e290600090a250565b6001600160a01b038116600090815260026020908152604080832081517f59d556a8000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b9519926359d556a89260248082019391829003018186803b158015610b4a57600080fd5b505af4158015610b5e573d6000803e3d6000fd5b505050506040513d6020811015610b7457600080fd5b505190505b919050565b60005474010000000000000000000000000000000000000000900460ff1681565b60066020526000908152604090205481565b600360209081526000928352604080842090915290825290205460ff1681565b60055481565b610bdf611788565b610c30576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03831615801590610c5057506001600160a01b03821615155b8015610c7357506001600160a01b03831660009081526004602052604090205481105b8015610cba57506001600160a01b03838116600090815260046020526040902080549184169183908110610ca357fe5b6000918252602090912001546001600160a01b0316145b610cf55760405162461bcd60e51b81526004018080602001828103825260568152602001806129ed6056913960600191505060405180910390fd5b6001600160a01b038084166000818152600360209081526040808320948716835293815283822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690559181526004909152208054610d5e90600163ffffffff61220416565b81548110610d6857fe5b60009182526020808320909101546001600160a01b03868116845260049092526040909220805491909216919083908110610d9f57fe5b600091825260208083209190910180547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b03948516179055918516815260049091526040902054610df9906001612204565b6001600160a01b0384166000908152600460205260409020610e1b9082612955565b50610e26838361224d565b15610e3557610e3583836123cc565b816001600160a01b0316836001600160a01b03167f6dc84b66cc948d847632b9d829f7cb1cb904fbf2c084554a9bc22ad9d845334060405160405180910390a3505050565b60018060028190919293565b6001600160a01b038116600090815260026020908152604080832081517f6eafa6c3000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b951992636eafa6c39260248082019391829003018186803b158015610b4a57600080fd5b6001600160a01b038116600090815260066020526040812054610f2d5750600554610b79565b506001600160a01b031660009081526006602052604090205490565b610f51611788565b610fa2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b6001600160a01b0384166000908152600360209081526040808320338452909152902054849060ff166110685760405162461bcd60e51b8152600401808060200182810382526027815260200180612a436027913960400191505060405180910390fd5b6001600160a01b038516600090815260016020908152604080832081517f59d556a8000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b9519926359d556a89260248082019391829003018186803b1580156110e957600080fd5b505af41580156110fd573d6000803e3d6000fd5b505050506040513d602081101561111357600080fd5b50516001600160a01b03871660009081526001602090815260409182902082517f95073a79000000000000000000000000000000000000000000000000000000008152600481019190915233602482015291519293507399edce8143ff8aefa1fbb6c2103b349add2b9519926395073a79926044808201939291829003018186803b1580156111a157600080fd5b505af41580156111b5573d6000803e3d6000fd5b505050506040513d60208110156111cb57600080fd5b505115611329576001600160a01b0380871660009081526001602052604080822081517f832a214700000000000000000000000000000000000000000000000000000000815260048101919091523360248201526044810189905287841660648201529286166084840152517399edce8143ff8aefa1fbb6c2103b349add2b95199263832a21479260a4808301939192829003018186803b15801561126f57600080fd5b505af4158015611283573d6000803e3d6000fd5b505050506001600160a01b03861660009081526002602052604080822081517fc1e728e9000000000000000000000000000000000000000000000000000000008152600481019190915233602482015290517399edce8143ff8aefa1fbb6c2103b349add2b95199263c1e728e99260448082019391829003018186803b15801561130c57600080fd5b505af4158015611320573d6000803e3d6000fd5b505050506113df565b6001600160a01b0380871660009081526001602052604080822081517fd4a0927200000000000000000000000000000000000000000000000000000000815260048101919091523360248201526044810189905287841660648201529286166084840152517399edce8143ff8aefa1fbb6c2103b349add2b95199263d4a092729260a4808301939192829003018186803b1580156113c657600080fd5b505af41580156113da573d6000803e3d6000fd5b505050505b6001600160a01b03861660009081526002602090815260409182902082517f0944c5940000000000000000000000000000000000000000000000000000000081526004810182905292517399edce8143ff8aefa1fbb6c2103b349add2b95199363d4a0927293339242928792630944c59492602480840193829003018186803b15801561146b57600080fd5b505af415801561147f573d6000803e3d6000fd5b505050506040513d602081101561149557600080fd5b5051604080517fffffffff0000000000000000000000000000000000000000000000000000000060e088901b16815260048101959095526001600160a01b0393841660248601526044850192909252919091166064830152600060848301819052905160a480840193829003018186803b15801561151257600080fd5b505af4158015611526573d6000803e3d6000fd5b5050604080514281526020810189905281513394506001600160a01b038b1693507f7cebb17173a9ed273d2b7538f64395c0ebf352ff743f1cf8ce66b437a6144213929181900390910190a36001600160a01b038616600090815260016020908152604080832081517f59d556a8000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b9519926359d556a89260248082019391829003018186803b1580156115f357600080fd5b505af4158015611607573d6000803e3d6000fd5b505050506040513d602081101561161d57600080fd5b50519050818114611668576040805182815290516001600160a01b038916917fa9981ebfc3b766a742486e898f54959b050a66006dbce1a4155c1f84a08bcf41919081900360200190a25b6007546001600160a01b0316156116f957600754604080517fab02e6c00000000000000000000000000000000000000000000000000000000081526001600160a01b038a811660048301529151919092169163ab02e6c091602480830192600092919082900301818387803b1580156116e057600080fd5b505af11580156116f4573d6000803e3d6000fd5b505050505b50505050505050565b6000546001600160a01b03165b90565b6001600160a01b03811660009081526004602090815260409182902080548351818402810184019094528084526060939283018282801561177c57602002820191906000526020600020905b81546001600160a01b0316815260019091019060200180831161175e575b50505050509050919050565b600080546001600160a01b031661179d6127a8565b6001600160a01b031614905090565b600460205281600052604060002081815481106117c557fe5b6000918252602090912001546001600160a01b03169150829050565b6001600160a01b03811660009081526002602052604080822081517f6cfa387300000000000000000000000000000000000000000000000000000000815260048101919091529051606092839283927399edce8143ff8aefa1fbb6c2103b349add2b951992636cfa38739260248082019391829003018186803b1580156107af57600080fd5b6001600160a01b038116600090815260016020908152604080832081517f6eafa6c3000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b951992636eafa6c39260248082019391829003018186803b158015610b4a57600080fd5b6001600160a01b038216158015906119ad57506001600160a01b03821660009081526002602090815260409182902082517f6eafa6c3000000000000000000000000000000000000000000000000000000008152600481019190915291517399edce8143ff8aefa1fbb6c2103b349add2b951992636eafa6c3926024808301939192829003018186803b15801561197e57600080fd5b505af4158015611992573d6000803e3d6000fd5b505050506040513d60208110156119a857600080fd5b505181105b6119e85760405162461bcd60e51b81526004018080602001828103825260348152602001806129b96034913960400191505060405180910390fd5b60005b81811015611a3a576000806119ff8561204e565b915091508115611a1857611a1385826123cc565b611a1f565b5050611a3a565b50611a33905081600163ffffffff6127ac16565b90506119eb565b505050565b611a47611788565b611a98576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60008111611ad75760405162461bcd60e51b8152600401808060200182810382526021815260200180612b126021913960400191505060405180910390fd5b600554811415611b185760405162461bcd60e51b8152600401808060200182810382526022815260200180612af06022913960400191505060405180910390fd5b60058190556040805182815290517fc68a9b88effd8a11611ff410efbc83569f0031b7bc70dd455b61344c7f0a042f9181900360200190a150565b6001600160a01b038116600090815260016020908152604080832081517f59d556a80000000000000000000000000000000000000000000000000000000081526004810191909152905183927399edce8143ff8aefa1fbb6c2103b349add2b9519926359d556a89260248083019392829003018186803b158015611bd657600080fd5b505af4158015611bea573d6000803e3d6000fd5b505050506040513d6020811015611c0057600080fd5b5051611c0b84611867565b15611c205769d3c21bcecceda1000000611c23565b60005b915091505b915091565b611c35611788565b611c86576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b03821615801590611ca657506001600160a01b03811615155b8015611cd857506001600160a01b0380831660009081526003602090815260408083209385168352929052205460ff16155b611d135760405162461bcd60e51b815260040180806020018281038252605e815260200180612a6a605e913960600191505060405180910390fd5b6001600160a01b03808316600081815260036020908152604080832094861680845294825280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660019081179091558484526004835281842080549182018155845291832090910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001685179055517f828d2be040dede7698182e08dfa8bfbd663c879aee772509c4a2bd961d0ed43f9190a35050565b611dd9611788565b611e2a576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b611e3381612806565b50565b6007546001600160a01b031681565b611e4d611788565b611e9e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60008111611edd5760405162461bcd60e51b8152600401808060200182810382526021815260200180612b126021913960400191505060405180910390fd5b6001600160a01b038216600090815260066020526040902054811415611f345760405162461bcd60e51b8152600401808060200182810382526028815260200180612ac86028913960400191505060405180910390fd5b6001600160a01b0382166000818152600660209081526040918290208490558151928352820183905280517ff8324c8592dfd9991ee3e717351afe0a964605257959e3d99b0eb3d45bff94229281900390910190a15050565b60005474010000000000000000000000000000000000000000900460ff1615611ffd576040805162461bcd60e51b815260206004820152601c60248201527f636f6e747261637420616c726561647920696e697469616c697a656400000000604482015290519081900360640190fd5b600080547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000017905561204533612806565b611e3381611a3f565b6000806001600160a01b03831661206457600080fd5b6001600160a01b038316600090815260026020908152604080832081517fd938ec7b000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b95199263d938ec7b9260248082019391829003018186803b1580156120e557600080fd5b505af41580156120f9573d6000803e3d6000fd5b505050506040513d602081101561210f57600080fd5b50516001600160a01b03808616600090815260026020908152604080832081517f7c6bb862000000000000000000000000000000000000000000000000000000008152600481019190915293851660248501525193945090927399edce8143ff8aefa1fbb6c2103b349add2b951992637c6bb862926044808301939192829003018186803b1580156121a057600080fd5b505af41580156121b4573d6000803e3d6000fd5b505050506040513d60208110156121ca57600080fd5b505190506121d785610f07565b6121e7428363ffffffff61220416565b106121f85750600192509050611c28565b50600092509050915091565b600061224683836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506128be565b9392505050565b6001600160a01b03808316600090815260016020908152604080832081517f95073a79000000000000000000000000000000000000000000000000000000008152600481019190915293851660248501525191927399edce8143ff8aefa1fbb6c2103b349add2b9519926395073a7992604480840193919291829003018186803b1580156122da57600080fd5b505af41580156122ee573d6000803e3d6000fd5b505050506040513d602081101561230457600080fd5b5051801561224657506001600160a01b0380841660009081526002602090815260409182902082517f95073a790000000000000000000000000000000000000000000000000000000081526004810191909152928516602484015290517399edce8143ff8aefa1fbb6c2103b349add2b9519926395073a79926044808301939192829003018186803b15801561239957600080fd5b505af41580156123ad573d6000803e3d6000fd5b505050506040513d60208110156123c357600080fd5b50519392505050565b6123d582610e86565b60011480156123e957506123e9828261224d565b156123f3576127a4565b6001600160a01b038216600090815260016020908152604080832081517f59d556a8000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b9519926359d556a89260248082019391829003018186803b15801561247457600080fd5b505af4158015612488573d6000803e3d6000fd5b505050506040513d602081101561249e57600080fd5b50516001600160a01b0380851660009081526001602052604080822081517fc1e728e900000000000000000000000000000000000000000000000000000000815260048101919091529286166024840152519293507399edce8143ff8aefa1fbb6c2103b349add2b95199263c1e728e9926044808201939291829003018186803b15801561252b57600080fd5b505af415801561253f573d6000803e3d6000fd5b5050506001600160a01b0380851660009081526002602052604080822081517fc1e728e900000000000000000000000000000000000000000000000000000000815260048101919091529286166024840152517399edce8143ff8aefa1fbb6c2103b349add2b9519935063c1e728e9926044808201939291829003018186803b1580156125cb57600080fd5b505af41580156125df573d6000803e3d6000fd5b50506040516001600160a01b038086169350861691507fe21a44017b6fa1658d84e937d56ff408501facdb4ff7427c479ac460d76f789390600090a36001600160a01b038316600090815260016020908152604080832081517f59d556a8000000000000000000000000000000000000000000000000000000008152600481019190915290517399edce8143ff8aefa1fbb6c2103b349add2b9519926359d556a89260248082019391829003018186803b15801561269c57600080fd5b505af41580156126b0573d6000803e3d6000fd5b505050506040513d60208110156126c657600080fd5b505190508181146127a1576040805182815290516001600160a01b038616917fa9981ebfc3b766a742486e898f54959b050a66006dbce1a4155c1f84a08bcf41919081900360200190a26007546001600160a01b0316156127a157600754604080517fab02e6c00000000000000000000000000000000000000000000000000000000081526001600160a01b0387811660048301529151919092169163ab02e6c091602480830192600092919082900301818387803b15801561278857600080fd5b505af115801561279c573d6000803e3d6000fd5b505050505b50505b5050565b3390565b600082820183811015612246576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b6001600160a01b03811661284b5760405162461bcd60e51b81526004018080602001828103825260268152602001806129936026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0392909216919091179055565b6000818484111561294d5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156129125781810151838201526020016128fa565b50505050905090810190601f16801561293f5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b815481835581811115611a3a57600083815260209020611a3a91810190830161170f91905b8082111561298e576000815560010161297a565b509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373746f6b656e2061646472206e756c6c206f7220747279696e6720746f2072656d6f766520746f6f206d616e79207265706f727473746f6b656e2061646472206e756c6c206f72206f7261636c652061646472206e756c6c206f7220696e646578206f6620746f6b656e206f7261636c65206e6f74206d617070656420746f206f7261636c65206164647273656e64657220776173206e6f7420616e206f7261636c6520666f7220746f6b656e2061646472746f6b656e206164647220776173206e756c6c206f72206f7261636c65206164647220776173206e756c6c206f72206f7261636c65206164647220697320616c726561647920616e206f7261636c6520666f7220746f6b656e2061646472746f6b656e207265706f72744578706972795365636f6e6473206861736e2774206368616e6765647265706f72744578706972795365636f6e6473206861736e2774206368616e6765647265706f727420657870697279207365636f6e6473206d757374206265203e2030a265627a7a72315820b9fcb3d22797a15d8cc69e1ff0a8487228f05c28d4ba626a568c55fe62b4f7c564736f6c634300051100320000000000000000000000000000000000000000000000000000000000000000", + "nonce": "0x27f" }, "additionalContracts": [], "isFixedGasLimit": false }, { - "hash": "0xe43742dd45bb3b886933a2d8e88c3eaa7b4c9ca3981ed423f706b7419e39a1ee", + "hash": "0xc715a979d488e58a99a5daf500fbed3bb95e0ce5a8687a8310be8517ad3c20da", "transactionType": "CALL", "contractName": "SortedOracles", - "contractAddress": "0x6aB692fd745D08d8Ae5c95033F07C89fDAfC1711", + "contractAddress": "0x2e229aa95c67baa6c08073f26ABA8E4083e98489", "function": "transferOwnership(address)", "arguments": [ "0x28443b1d87db521320a6517A4F1B6Ead77F8C811" @@ -73,11 +114,11 @@ "transaction": { "type": "0x00", "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "to": "0x6ab692fd745d08d8ae5c95033f07c89fdafc1711", + "to": "0x2e229aa95c67baa6c08073f26aba8e4083e98489", "gas": "0x9af0", "value": "0x0", "data": "0xf2fde38b00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811", - "nonce": "0x240" + "nonce": "0x280" }, "additionalContracts": [], "isFixedGasLimit": false @@ -85,128 +126,196 @@ ], "receipts": [ { - "transactionHash": "0xbe304071d7b24f6a9480ad68a32ef1521f8987daea1acb162a208d41017be192", + "transactionHash": "0xfb2a45b97150c1a180d6df81f4f00e94dc58cd936b1ddd88fddcdec4c52061ae", "transactionIndex": "0x0", - "blockHash": "0x7d3760ece6c5ca2c76c8e332f518c9b3eea3951b46d67eeb9dfac3d591d6893c", - "blockNumber": "0x118cce1", + "blockHash": "0x3557ffcefe92a64f0b6db6585fbc2cc6159cd24c275db3ac7f97f1f1d6b4e1fb", + "blockNumber": "0x1216d2c", "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", "to": null, - "cumulativeGasUsed": "0x36e95e", - "gasUsed": "0x36e95e", - "contractAddress": "0x7B0C742c350d68986027e36bd337328Cb390c3d4", + "cumulativeGasUsed": "0x3800be", + "gasUsed": "0x3800be", + "contractAddress": "0xf0e764Da1E61Bd5421692e5d02bdad9f3B09f825", "logs": [ { - "address": "0x7B0C742c350d68986027e36bd337328Cb390c3d4", + "address": "0xf0e764Da1E61Bd5421692e5d02bdad9f3B09f825", "topics": [ "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", "0x0000000000000000000000000000000000000000000000000000000000000000", "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" ], "data": "0x", - "blockHash": "0x7d3760ece6c5ca2c76c8e332f518c9b3eea3951b46d67eeb9dfac3d591d6893c", - "blockNumber": "0x118cce1", - "transactionHash": "0xbe304071d7b24f6a9480ad68a32ef1521f8987daea1acb162a208d41017be192", + "blockHash": "0x3557ffcefe92a64f0b6db6585fbc2cc6159cd24c275db3ac7f97f1f1d6b4e1fb", + "blockNumber": "0x1216d2c", + "transactionHash": "0xfb2a45b97150c1a180d6df81f4f00e94dc58cd936b1ddd88fddcdec4c52061ae", "transactionIndex": "0x0", "logIndex": "0x0", "removed": false } ], "status": "0x1", - "logsBloom": "0x00000000000000000000000000000080000000000000000020800000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000020000000000000000000800000000000000000000000000000000400000000002000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000004000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0x1dcd6500" + "logsBloom": "0x00000000000000000000000000000004000000000000000020800000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000020000000000000000000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000004000000000000000000000000000000010000000000000000000001000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" }, { - "transactionHash": "0x04fbd963610daa728e6534a19f0829f507b04b745bbd6881cf2ba7d89f8d66bb", + "transactionHash": "0x57a9d0fd0f801d5213e73fec37c8a6fe96c728bc577233a5608eadde1acf78bc", "transactionIndex": "0x1", - "blockHash": "0x7d3760ece6c5ca2c76c8e332f518c9b3eea3951b46d67eeb9dfac3d591d6893c", - "blockNumber": "0x118cce1", + "blockHash": "0x3557ffcefe92a64f0b6db6585fbc2cc6159cd24c275db3ac7f97f1f1d6b4e1fb", + "blockNumber": "0x1216d2c", "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", - "to": "0x7B0C742c350d68986027e36bd337328Cb390c3d4", - "cumulativeGasUsed": "0x375a4b", + "to": "0xf0e764Da1E61Bd5421692e5d02bdad9f3B09f825", + "cumulativeGasUsed": "0x3871ab", "gasUsed": "0x70ed", "contractAddress": null, "logs": [ { - "address": "0x7B0C742c350d68986027e36bd337328Cb390c3d4", + "address": "0xf0e764Da1E61Bd5421692e5d02bdad9f3B09f825", "topics": [ "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", "0x00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811" ], "data": "0x", - "blockHash": "0x7d3760ece6c5ca2c76c8e332f518c9b3eea3951b46d67eeb9dfac3d591d6893c", - "blockNumber": "0x118cce1", - "transactionHash": "0x04fbd963610daa728e6534a19f0829f507b04b745bbd6881cf2ba7d89f8d66bb", + "blockHash": "0x3557ffcefe92a64f0b6db6585fbc2cc6159cd24c275db3ac7f97f1f1d6b4e1fb", + "blockNumber": "0x1216d2c", + "transactionHash": "0x57a9d0fd0f801d5213e73fec37c8a6fe96c728bc577233a5608eadde1acf78bc", "transactionIndex": "0x1", "logIndex": "0x1", "removed": false } ], "status": "0x1", - "logsBloom": "0x00000000000000000000000000000080000000000000000020801000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000001000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000400000000002000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000004000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0x1dcd6500" + "logsBloom": "0x00000000000000000000000000000004000000000000000020801000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000001000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000004000000000000000000000000000000010000000000000000000001000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" }, { - "transactionHash": "0xdb44985e8a120a4e8f50698d4dd541f00856dcf43f932cf420c241eb8b2d0b28", + "transactionHash": "0xa50ae40e0950b44791ec8283a4b1155697a168fb1f700eb7e72e40b82697374b", "transactionIndex": "0x2", - "blockHash": "0x7d3760ece6c5ca2c76c8e332f518c9b3eea3951b46d67eeb9dfac3d591d6893c", - "blockNumber": "0x118cce1", + "blockHash": "0x3557ffcefe92a64f0b6db6585fbc2cc6159cd24c275db3ac7f97f1f1d6b4e1fb", + "blockNumber": "0x1216d2c", "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", "to": null, - "cumulativeGasUsed": "0x5d02b6", - "gasUsed": "0x25a86b", - "contractAddress": "0x6aB692fd745D08d8Ae5c95033F07C89fDAfC1711", + "cumulativeGasUsed": "0x6b1546", + "gasUsed": "0x32a39b", + "contractAddress": "0xb474472410F72c292280Ad6778978b49B8F7e68c", "logs": [ { - "address": "0x6aB692fd745D08d8Ae5c95033F07C89fDAfC1711", + "address": "0xb474472410F72c292280Ad6778978b49B8F7e68c", "topics": [ "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", "0x0000000000000000000000000000000000000000000000000000000000000000", "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" ], "data": "0x", - "blockHash": "0x7d3760ece6c5ca2c76c8e332f518c9b3eea3951b46d67eeb9dfac3d591d6893c", - "blockNumber": "0x118cce1", - "transactionHash": "0xdb44985e8a120a4e8f50698d4dd541f00856dcf43f932cf420c241eb8b2d0b28", + "blockHash": "0x3557ffcefe92a64f0b6db6585fbc2cc6159cd24c275db3ac7f97f1f1d6b4e1fb", + "blockNumber": "0x1216d2c", + "transactionHash": "0xa50ae40e0950b44791ec8283a4b1155697a168fb1f700eb7e72e40b82697374b", "transactionIndex": "0x2", "logIndex": "0x2", "removed": false } ], "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000020800000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000020000000000000000000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000004000000000000008000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000020000004000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0x1dcd6500" + "logsBloom": "0x00000000000000000000000000000000000000000000000020800400000000040000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000020000000000000000000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000020000004000000000000000000000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" }, { - "transactionHash": "0xe43742dd45bb3b886933a2d8e88c3eaa7b4c9ca3981ed423f706b7419e39a1ee", + "transactionHash": "0x9bba48eafcd7f2874a0489408a33cdce099f7d5e8b8b8d25328e7039c458e4fa", "transactionIndex": "0x3", - "blockHash": "0x7d3760ece6c5ca2c76c8e332f518c9b3eea3951b46d67eeb9dfac3d591d6893c", - "blockNumber": "0x118cce1", + "blockHash": "0x3557ffcefe92a64f0b6db6585fbc2cc6159cd24c275db3ac7f97f1f1d6b4e1fb", + "blockNumber": "0x1216d2c", "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", - "to": "0x6aB692fd745D08d8Ae5c95033F07C89fDAfC1711", - "cumulativeGasUsed": "0x5d72e3", - "gasUsed": "0x702d", + "to": "0xb474472410F72c292280Ad6778978b49B8F7e68c", + "cumulativeGasUsed": "0x6b865f", + "gasUsed": "0x7119", "contractAddress": null, "logs": [ { - "address": "0x6aB692fd745D08d8Ae5c95033F07C89fDAfC1711", + "address": "0xb474472410F72c292280Ad6778978b49B8F7e68c", "topics": [ "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", "0x00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811" ], "data": "0x", - "blockHash": "0x7d3760ece6c5ca2c76c8e332f518c9b3eea3951b46d67eeb9dfac3d591d6893c", - "blockNumber": "0x118cce1", - "transactionHash": "0xe43742dd45bb3b886933a2d8e88c3eaa7b4c9ca3981ed423f706b7419e39a1ee", + "blockHash": "0x3557ffcefe92a64f0b6db6585fbc2cc6159cd24c275db3ac7f97f1f1d6b4e1fb", + "blockNumber": "0x1216d2c", + "transactionHash": "0x9bba48eafcd7f2874a0489408a33cdce099f7d5e8b8b8d25328e7039c458e4fa", "transactionIndex": "0x3", "logIndex": "0x3", "removed": false } ], "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000020801000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000001000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000004000000000000008000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000080000004000000000000000000000000000000000000000000000000000000000000", - "effectiveGasPrice": "0x1dcd6500" + "logsBloom": "0x00000000000000000000000000000000000000000000000020801400000000040000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000001000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000080000004000000000000000000000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" + }, + { + "transactionHash": "0x4fadf58b85e9e14c012e4c340249c29904eeb249bd376ee97fe7618eb2a1ddb4", + "transactionIndex": "0x4", + "blockHash": "0x3557ffcefe92a64f0b6db6585fbc2cc6159cd24c275db3ac7f97f1f1d6b4e1fb", + "blockNumber": "0x1216d2c", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": null, + "cumulativeGasUsed": "0x9133de", + "gasUsed": "0x25ad7f", + "contractAddress": "0x2e229aa95c67baa6c08073f26ABA8E4083e98489", + "logs": [ + { + "address": "0x2e229aa95c67baa6c08073f26ABA8E4083e98489", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" + ], + "data": "0x", + "blockHash": "0x3557ffcefe92a64f0b6db6585fbc2cc6159cd24c275db3ac7f97f1f1d6b4e1fb", + "blockNumber": "0x1216d2c", + "transactionHash": "0x4fadf58b85e9e14c012e4c340249c29904eeb249bd376ee97fe7618eb2a1ddb4", + "transactionIndex": "0x4", + "logIndex": "0x4", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000020800000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000001001000000000000000000000000000000000000020000000000000000000800000000000000000200000000000000400000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000004000000000000000000000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" + }, + { + "transactionHash": "0xc715a979d488e58a99a5daf500fbed3bb95e0ce5a8687a8310be8517ad3c20da", + "transactionIndex": "0x5", + "blockHash": "0x3557ffcefe92a64f0b6db6585fbc2cc6159cd24c275db3ac7f97f1f1d6b4e1fb", + "blockNumber": "0x1216d2c", + "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", + "to": "0x2e229aa95c67baa6c08073f26ABA8E4083e98489", + "cumulativeGasUsed": "0x91a40b", + "gasUsed": "0x702d", + "contractAddress": null, + "logs": [ + { + "address": "0x2e229aa95c67baa6c08073f26ABA8E4083e98489", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", + "0x00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811" + ], + "data": "0x", + "blockHash": "0x3557ffcefe92a64f0b6db6585fbc2cc6159cd24c275db3ac7f97f1f1d6b4e1fb", + "blockNumber": "0x1216d2c", + "transactionHash": "0xc715a979d488e58a99a5daf500fbed3bb95e0ce5a8687a8310be8517ad3c20da", + "transactionIndex": "0x5", + "logIndex": "0x5", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000020801000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000001001000000000000020000000000000000000000000000000000000000000000000000000000000200000000000000400000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000004000000000000000000000000000000000000000000000000000000000000", + "type": "0x0", + "effectiveGasPrice": "0xbebc200" } ], "libraries": [ @@ -215,8 +324,8 @@ ], "pending": [], "returns": {}, - "timestamp": 1689767445, + "timestamp": 1692627957, "chain": 62320, "multi": false, - "commit": "b880c12" + "commit": "b396ea6" } \ No newline at end of file diff --git a/script/dev/dev-CreateMockBridgedEUROC.sol b/script/dev/dev-CreateMockBridgedEUROC.sol new file mode 100644 index 00000000..c535b542 --- /dev/null +++ b/script/dev/dev-CreateMockBridgedEUROC.sol @@ -0,0 +1,24 @@ +// SPDX-License-Identifier: GPL-3.0-or-later +pragma solidity ^0.5.13; + +import { Script } from "script/utils/Script.sol"; +import { Chain } from "script/utils/Chain.sol"; +import { console2 } from "forge-std/Script.sol"; + +import { MockERC20 } from "contracts/MockERC20.sol"; + +contract CreateMockBridgedEUROC is Script { + function run() public { + address mockBridgedEUROC; + + vm.startBroadcast(Chain.deployerPrivateKey()); + { + mockBridgedEUROC = address(new MockERC20("mockBridgedEUROC", "BridgedEUROC", 6)); + } + vm.stopBroadcast(); + + console2.log("----------"); + console2.log("MockBridgedEUROC deployed at: ", mockBridgedEUROC); + console2.log("----------"); + } +} diff --git a/script/dev/dev-FundPartialReserve.sol b/script/dev/dev-FundPartialReserve.sol index 899c6c96..f08b90b5 100644 --- a/script/dev/dev-FundPartialReserve.sol +++ b/script/dev/dev-FundPartialReserve.sol @@ -11,12 +11,14 @@ contract FundPartialReserve is Script { function run() public { contracts.loadUpgrade("MU01"); IERC20Metadata bridgedUSDC = IERC20Metadata(contracts.dependency("BridgedUSDC")); + IERC20Metadata bridgedEUROC = IERC20Metadata(contracts.dependency("BridgedEUROC")); address partialReserve = contracts.deployed("PartialReserveProxy"); IERC20Metadata celoToken = IERC20Metadata(contracts.celoRegistry("GoldToken")); vm.startBroadcast(Chain.deployerPrivateKey()); { - bridgedUSDC.transfer(partialReserve, 10_000 ether); + bridgedUSDC.transfer(partialReserve, 10_000_000 * 1e6); + bridgedEUROC.transfer(partialReserve, 10_000_000 * 1e6); celoToken.transfer(partialReserve, 10_000 ether); } vm.stopBroadcast(); diff --git a/script/upgrades/MU03/Config.sol b/script/upgrades/MU03/Config.sol index fbb461b0..5b0fef34 100644 --- a/script/upgrades/MU03/Config.sol +++ b/script/upgrades/MU03/Config.sol @@ -20,6 +20,7 @@ library MU03Config { Config.Pool cUSDUSDC; Config.Pool cEURUSDC; Config.Pool cBRLUSDC; + Config.Pool cEUREUROC; Config.Pool[] pools; Config.RateFeed CELOUSD; Config.RateFeed CELOEUR; @@ -27,25 +28,28 @@ library MU03Config { Config.RateFeed USDCUSD; Config.RateFeed USDCEUR; Config.RateFeed USDCBRL; + Config.RateFeed EUROCEUR; Config.RateFeed[] rateFeeds; } function get(Contracts.Cache storage contracts) internal returns (MU03 memory config) { - config.pools = new Config.Pool[](6); + config.pools = new Config.Pool[](7); config.pools[0] = config.cUSDCelo = cUSDCelo_PoolConfig(contracts); config.pools[1] = config.cEURCelo = cEURCelo_PoolConfig(contracts); config.pools[2] = config.cBRLCelo = cBRLCelo_PoolConfig(contracts); config.pools[3] = config.cUSDUSDC = cUSDUSDC_PoolConfig(contracts); config.pools[4] = config.cEURUSDC = cEURUSDC_PoolConfig(contracts); config.pools[5] = config.cBRLUSDC = cBRLUSDC_PoolConfig(contracts); + config.pools[6] = config.cEUREUROC = cEUREUROC_PoolConfig(contracts); - config.rateFeeds = new Config.RateFeed[](6); + config.rateFeeds = new Config.RateFeed[](7); config.rateFeeds[0] = config.CELOUSD = CELOUSD_RateFeedConfig(contracts); config.rateFeeds[1] = config.CELOEUR = CELOEUR_RateFeedConfig(contracts); config.rateFeeds[2] = config.CELOBRL = CELOBRL_RateFeedConfig(contracts); config.rateFeeds[3] = config.USDCUSD = USDCUSD_RateFeedConfig(contracts); config.rateFeeds[4] = config.USDCEUR = USDCEUR_RateFeedConfig(contracts); config.rateFeeds[5] = config.USDCBRL = USDCBRL_RateFeedConfig(contracts); + config.rateFeeds[6] = config.EUROCEUR = EUROCEUR_RateFeedConfig(contracts); } function cUSDCelo_PoolConfig(Contracts.Cache storage contracts) internal view returns (Config.Pool memory config) { @@ -283,4 +287,42 @@ library MU03Config { }); config.dependentRateFeeds = Arrays.addresses(contracts.dependency("USDCUSDRateFeedAddr")); } + + function cEUREUROC_PoolConfig(Contracts.Cache storage contracts) internal returns (Config.Pool memory config) { + config = Config.Pool({ + asset0: contracts.celoRegistry("StableTokenEUR"), + asset1: contracts.dependency("BridgedEUROC"), + isConstantSum: true, + spread: FixidityLib.newFixedFraction(2, 10000), // 0.0002 + minimumReports: 5, + referenceRateResetFrequency: 5 minutes, + stablePoolResetSize: 12_000_000 * 1e18, // 12 million + referenceRateFeedID: contracts.dependency("EUROCEURRateFeedAddr"), + asset0limits: Config.TradingLimit({ + enabled0: true, + timeStep0: 5 minutes, + limit0: 50_000, + enabled1: true, + timeStep1: 1 days, + limit1: 100_000, + enabledGlobal: false, + limitGlobal: 0 + }), + asset1limits: Config.emptyTradingLimitConfig() + }); + + if (Chain.isBaklava() || Chain.isAlfajores()) { + config.minimumReports = 2; + } + } + + function EUROCEUR_RateFeedConfig(Contracts.Cache storage contracts) internal returns (Config.RateFeed memory config) { + config.rateFeedID = contracts.dependency("EUROCEURRateFeedAddr"); + config.valueDeltaBreaker0 = Config.ValueDeltaBreaker({ + enabled: true, + threshold: FixidityLib.newFixedFraction(5, 1000), // 0.005 + referenceValue: 1e24, // 1€ numerator for 1e24 denominator + cooldown: 1 seconds + }); + } } diff --git a/script/upgrades/MU03/MU03.sol b/script/upgrades/MU03/MU03.sol index 0a118af3..aba0a8f8 100644 --- a/script/upgrades/MU03/MU03.sol +++ b/script/upgrades/MU03/MU03.sol @@ -12,6 +12,7 @@ import { Arrays } from "script/utils/Arrays.sol"; import { FixidityLib } from "mento-core-2.2.0/common/FixidityLib.sol"; import { IBiPoolManager } from "mento-core-2.2.0/interfaces/IBiPoolManager.sol"; import { IPricingModule } from "mento-core-2.2.0/interfaces/IPricingModule.sol"; +import { IReserve } from "mento-core-2.2.0/interfaces/IReserve.sol"; import { Proxy } from "mento-core-2.2.0/common/Proxy.sol"; import { IERC20Metadata } from "mento-core-2.2.0/common/interfaces/IERC20Metadata.sol"; @@ -45,11 +46,14 @@ contract MU03 is IMentoUpgrade, GovernanceScript { address private cBRL; address private celo; address private bridgedUSDC; + address private bridgedEUROC; address private breakerBox; address private medianDeltaBreaker; address private valueDeltaBreaker; - address private biPoolManagerProxyAddress; + address payable private biPoolManagerProxyAddress; + address private brokerProxyAddress; address private sortedOraclesProxy; + address private partialReserveProxy; // Helper mapping to store the exchange IDs for the reference rate feeds mapping(address => bytes32) private referenceRateFeedIDToExchangeId; @@ -81,11 +85,14 @@ contract MU03 is IMentoUpgrade, GovernanceScript { cBRL = contracts.celoRegistry("StableTokenBRL"); celo = contracts.celoRegistry("GoldToken"); bridgedUSDC = contracts.dependency("BridgedUSDC"); + bridgedEUROC = contracts.dependency("BridgedEUROC"); breakerBox = contracts.deployed("BreakerBox"); medianDeltaBreaker = contracts.deployed("MedianDeltaBreaker"); valueDeltaBreaker = contracts.deployed("ValueDeltaBreaker"); - biPoolManagerProxyAddress = contracts.deployed("BiPoolManagerProxy"); + biPoolManagerProxyAddress = address(uint160(contracts.deployed("BiPoolManagerProxy"))); + brokerProxyAddress = contracts.deployed("BrokerProxy"); sortedOraclesProxy = contracts.celoRegistry("SortedOracles"); + partialReserveProxy = contracts.deployed("PartialReserveProxy"); } /** @@ -122,11 +129,14 @@ contract MU03 is IMentoUpgrade, GovernanceScript { require(transactions.length == 0, "buildProposal() should only be called once"); MU03Config.MU03 memory config = MU03Config.get(contracts); - proposal_updateBiPoolManagerImplementation(config); - proposal_updateSortedOraclesImplementation(config); + proposal_addEUROCToPartialReserve(); + proposal_updateBiPoolManagerImplementation(); + proposal_updateBrokerImplementation(); + proposal_updateSortedOraclesImplementation(); + proposal_updateBreakerBoxReferences(); proposal_createExchanges(config); proposal_configureTradingLimits(config); - proposal_scaleDownReserveFraction(config); + proposal_scaleDownReserveFraction(); proposal_configureBreakerBox(config); proposal_configureMedianDeltaBreaker0(config); proposal_configureValueDeltaBreaker0(config); @@ -134,59 +144,143 @@ contract MU03 is IMentoUpgrade, GovernanceScript { return transactions; } + function proposal_addEUROCToPartialReserve() private { + // addCollateralAsset will throw if it's already added + if (IReserve(partialReserveProxy).isCollateralAsset(bridgedEUROC) == false) { + transactions.push( + ICeloGovernance.Transaction( + 0, + partialReserveProxy, + abi.encodeWithSelector(IReserve(0).addCollateralAsset.selector, bridgedEUROC) + ) + ); + } + } + + function proposal_updateBiPoolManagerImplementation() public { + transactions.push( + ICeloGovernance.Transaction( + 0, + biPoolManagerProxyAddress, + abi.encodeWithSelector(Proxy(0)._setImplementation.selector, contracts.deployed("BiPoolManager")) + ) + ); + } + + function proposal_updateBrokerImplementation() public { + transactions.push( + ICeloGovernance.Transaction( + 0, + brokerProxyAddress, + abi.encodeWithSelector(Proxy(0)._setImplementation.selector, contracts.deployed("Broker")) + ) + ); + } + + function proposal_updateSortedOraclesImplementation() public { + transactions.push( + ICeloGovernance.Transaction( + 0, + sortedOraclesProxy, + abi.encodeWithSelector(Proxy(0)._setImplementation.selector, contracts.deployed("SortedOracles")) + ) + ); + } + + function proposal_updateBreakerBoxReferences() public { + // Set new BreakerBox address in BiPoolManager + transactions.push( + ICeloGovernance.Transaction( + 0, + biPoolManagerProxyAddress, + abi.encodeWithSelector(BiPoolManager(0).setBreakerBox.selector, breakerBox) + ) + ); + + // Set new BreakerBox address in SortedOracles + transactions.push( + ICeloGovernance.Transaction( + 0, + sortedOraclesProxy, + abi.encodeWithSelector(SortedOracles(0).setBreakerBox.selector, breakerBox) + ) + ); + } + /** * @notice This function generates the transactions required to create the * BiPoolManager exchanges (cUSD/CELO, cEUR/CELO, cBRL/CELO, cUSD/bridgedUSDC, * cEUR/bridgedUSDC, cBRL/bridgedUSDC) */ function proposal_createExchanges(MU03Config.MU03 memory config) private { - address payable biPoolManagerProxy = contracts.deployed("BiPoolManagerProxy"); - bool biPoolManagerInitialized = BiPoolManagerProxy(biPoolManagerProxy)._getImplementation() != address(0); - if (biPoolManagerInitialized) { - bytes32[] memory existingExchangeIds = IBiPoolManager(contracts.deployed("BiPoolManagerProxy")).getExchangeIds(); - if (existingExchangeIds.length > 0) { - console.log("Destroying existing exchanges: ", existingExchangeIds.length); - for (uint256 i = existingExchangeIds.length; i > 0; i--) { - transactions.push( - ICeloGovernance.Transaction( - 0, - contracts.deployed("BiPoolManagerProxy"), - abi.encodeWithSelector(IBiPoolManager(0).destroyExchange.selector, existingExchangeIds[i - 1], i - 1) - ) - ); - } - } - } - // Get the address of the pricing modules IPricingModule constantProduct = IPricingModule(contracts.deployed("ConstantProductPricingModule")); IPricingModule constantSum = IPricingModule(contracts.deployed("ConstantSumPricingModule")); - for (uint256 i = 0; i < config.pools.length; i++) { - Config.Pool memory poolConfig = config.pools[i]; - IBiPoolManager.PoolExchange memory pool = IBiPoolManager.PoolExchange({ - asset0: poolConfig.asset0, - asset1: poolConfig.asset1, - pricingModule: poolConfig.isConstantSum ? constantSum : constantProduct, - bucket0: 0, - bucket1: 0, - lastBucketUpdate: 0, - config: IBiPoolManager.PoolConfig({ - spread: FixidityLib.wrap(poolConfig.spread.unwrap()), - referenceRateFeedID: poolConfig.referenceRateFeedID, - referenceRateResetFrequency: poolConfig.referenceRateResetFrequency, - minimumReports: poolConfig.minimumReports, - stablePoolResetSize: poolConfig.stablePoolResetSize - }) - }); + // Set PricingModules + bytes32[] memory pricingModuleIdentifiers = Arrays.bytes32s( + keccak256(abi.encodePacked("ConstantSum")), + keccak256(abi.encodePacked("ConstantProduct")) + ); + address[] memory pricingModules = Arrays.addresses(address(constantSum), address(constantProduct)); + + transactions.push( + ICeloGovernance.Transaction( + 0, + biPoolManagerProxyAddress, + abi.encodeWithSelector(BiPoolManager(0).setPricingModules.selector, pricingModuleIdentifiers, pricingModules) + ) + ); + + Config.Pool[] memory poolsToCreate = new Config.Pool[](4); + poolsToCreate[0] = config.cUSDUSDC; + poolsToCreate[1] = config.cEURUSDC; + poolsToCreate[2] = config.cBRLUSDC; + poolsToCreate[3] = config.cEUREUROC; + bool biPoolManagerInitialized = BiPoolManagerProxy(biPoolManagerProxyAddress)._getImplementation() != address(0); + if (biPoolManagerInitialized) { + // Destroy cUSD/brdgedUSDC exchange -> since ConstantSum logic has changed + bytes32 cUSDUSDCExchangeId = getExchangeId( + config.cUSDUSDC.asset0, + config.cUSDUSDC.asset1, + config.cUSDUSDC.isConstantSum + ); transactions.push( ICeloGovernance.Transaction( 0, contracts.deployed("BiPoolManagerProxy"), - abi.encodeWithSelector(IBiPoolManager(0).createExchange.selector, pool) + //it's ok to hardcode the index here since the transaction would fail if index and identifier don't match + abi.encodeWithSelector(IBiPoolManager(0).destroyExchange.selector, cUSDUSDCExchangeId, 3) ) ); + + for (uint256 i = 0; i < poolsToCreate.length; i++) { + Config.Pool memory poolConfig = poolsToCreate[i]; + IBiPoolManager.PoolExchange memory pool = IBiPoolManager.PoolExchange({ + asset0: poolConfig.asset0, + asset1: poolConfig.asset1, + pricingModule: poolConfig.isConstantSum ? constantSum : constantProduct, + bucket0: 0, + bucket1: 0, + lastBucketUpdate: 0, + config: IBiPoolManager.PoolConfig({ + spread: FixidityLib.wrap(poolConfig.spread.unwrap()), + referenceRateFeedID: poolConfig.referenceRateFeedID, + referenceRateResetFrequency: poolConfig.referenceRateResetFrequency, + minimumReports: poolConfig.minimumReports, + stablePoolResetSize: poolConfig.stablePoolResetSize + }) + }); + + transactions.push( + ICeloGovernance.Transaction( + 0, + biPoolManagerProxyAddress, + abi.encodeWithSelector(IBiPoolManager(0).createExchange.selector, pool) + ) + ); + } } } @@ -194,7 +288,6 @@ contract MU03 is IMentoUpgrade, GovernanceScript { * @notice This function creates the transactions to configure the trading limits. */ function proposal_configureTradingLimits(MU03Config.MU03 memory config) public { - address brokerProxyAddress = contracts.deployed("BrokerProxy"); for (uint256 i = 0; i < config.pools.length; i++) { Config.Pool memory poolConfig = config.pools[i]; @@ -224,7 +317,7 @@ contract MU03 is IMentoUpgrade, GovernanceScript { /** * @notice This function creates the transactions to configure the Mento V1 Exchanges. */ - function proposal_scaleDownReserveFraction(MU03Config.MU03 memory config) public { + function proposal_scaleDownReserveFraction() public { address[] memory exchangesV1 = Arrays.addresses( contracts.celoRegistry("Exchange"), contracts.celoRegistry("ExchangeBRL"), @@ -247,26 +340,6 @@ contract MU03 is IMentoUpgrade, GovernanceScript { } } - function proposal_updateBiPoolManagerImplementation(MU03Config.MU03 memory config) public { - transactions.push( - ICeloGovernance.Transaction( - 0, - biPoolManagerProxyAddress, - abi.encodeWithSelector(Proxy(0)._setImplementation.selector, contracts.deployed("BiPoolManager")) - ) - ); - } - - function proposal_updateSortedOraclesImplementation(MU03Config.MU03 memory config) public { - transactions.push( - ICeloGovernance.Transaction( - 0, - sortedOraclesProxy, - abi.encodeWithSelector(Proxy(0)._setImplementation.selector, contracts.deployed("SortedOracles")) - ) - ); - } - function proposal_configureBreakerBox(MU03Config.MU03 memory config) public { // Add the rate feeds to breaker box transactions.push( @@ -281,7 +354,8 @@ contract MU03 is IMentoUpgrade, GovernanceScript { contracts.celoRegistry("StableTokenBRL"), contracts.dependency("USDCUSDRateFeedAddr"), contracts.dependency("USDCEURRateFeedAddr"), - contracts.dependency("USDCBRLRateFeedAddr") + contracts.dependency("USDCBRLRateFeedAddr"), + contracts.dependency("EUROCEURRateFeedAddr") ) ) ) @@ -361,15 +435,6 @@ contract MU03 is IMentoUpgrade, GovernanceScript { ); } } - - // Set BreakerBox address in SortedOracles - transactions.push( - ICeloGovernance.Transaction( - 0, - sortedOraclesProxy, - abi.encodeWithSelector(SortedOracles(0).setBreakerBox.selector, breakerBox) - ) - ); } function proposal_configureMedianDeltaBreaker0(MU03Config.MU03 memory config) public { @@ -377,7 +442,6 @@ contract MU03 is IMentoUpgrade, GovernanceScript { config.CELOUSD.rateFeedID, config.CELOEUR.rateFeedID, config.CELOBRL.rateFeedID, - config.USDCUSD.rateFeedID, config.USDCEUR.rateFeedID, config.USDCBRL.rateFeedID ); @@ -386,7 +450,6 @@ contract MU03 is IMentoUpgrade, GovernanceScript { config.CELOUSD.medianDeltaBreaker0.cooldown, config.CELOEUR.medianDeltaBreaker0.cooldown, config.CELOBRL.medianDeltaBreaker0.cooldown, - config.USDCUSD.medianDeltaBreaker0.cooldown, config.USDCEUR.medianDeltaBreaker0.cooldown, config.USDCBRL.medianDeltaBreaker0.cooldown ); @@ -404,7 +467,6 @@ contract MU03 is IMentoUpgrade, GovernanceScript { config.CELOUSD.medianDeltaBreaker0.threshold.unwrap(), config.CELOEUR.medianDeltaBreaker0.threshold.unwrap(), config.CELOBRL.medianDeltaBreaker0.threshold.unwrap(), - config.USDCUSD.medianDeltaBreaker0.threshold.unwrap(), config.USDCEUR.medianDeltaBreaker0.threshold.unwrap(), config.USDCBRL.medianDeltaBreaker0.threshold.unwrap() ); @@ -437,41 +499,47 @@ contract MU03 is IMentoUpgrade, GovernanceScript { } function proposal_configureValueDeltaBreaker0(MU03Config.MU03 memory config) public { - // Set reference value for cUSD/USDC pool + // Set reference value for USDC/USD, EUROC/EUR rate Feed transactions.push( ICeloGovernance.Transaction( 0, valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setReferenceValues.selector, - Arrays.addresses(config.USDCUSD.rateFeedID), - Arrays.uints(config.USDCUSD.valueDeltaBreaker0.referenceValue) + Arrays.addresses(config.USDCUSD.rateFeedID, config.EUROCEUR.rateFeedID), + Arrays.uints( + config.USDCUSD.valueDeltaBreaker0.referenceValue, + config.EUROCEUR.valueDeltaBreaker0.referenceValue + ) ) ) ); - // Set the cooldown time for cUSD/USDC pool + // Set cooldown time for USDC/USD, EUROC/EUR rate Feeds transactions.push( ICeloGovernance.Transaction( 0, valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setCooldownTimes.selector, - Arrays.addresses(config.USDCUSD.rateFeedID), - Arrays.uints(config.USDCUSD.valueDeltaBreaker0.cooldown) + Arrays.addresses(config.USDCUSD.rateFeedID, config.EUROCEUR.rateFeedID), + Arrays.uints(config.USDCUSD.valueDeltaBreaker0.cooldown, config.EUROCEUR.valueDeltaBreaker0.cooldown) ) ) ); - // Set the rate change threshold for cUSD/USDC pool + /// Set rate change thresholds for USDC/USD, EUROC/EUR rate Feeds transactions.push( ICeloGovernance.Transaction( 0, valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setRateChangeThresholds.selector, - Arrays.addresses(config.USDCUSD.rateFeedID), - Arrays.uints(config.USDCUSD.valueDeltaBreaker0.threshold.unwrap()) + Arrays.addresses(config.USDCUSD.rateFeedID, config.EUROCEUR.rateFeedID), + Arrays.uints( + config.USDCUSD.valueDeltaBreaker0.threshold.unwrap(), + config.EUROCEUR.valueDeltaBreaker0.threshold.unwrap() + ) ) ) ); diff --git a/script/upgrades/MU03/MU03Checks.sol b/script/upgrades/MU03/MU03Checks.sol index 9b90a02f..71eadea6 100644 --- a/script/upgrades/MU03/MU03Checks.sol +++ b/script/upgrades/MU03/MU03Checks.sol @@ -54,18 +54,22 @@ contract MU03Checks is Script, Test { address public cEUR; address public cBRL; address public bridgedUSDC; + address public bridgedEUROC; + address public governance; address public medianDeltaBreaker; address public valueDeltaBreaker; address public biPoolManager; - address payable sortedOraclesProxy; address public sortedOracles; address public constantSum; address public constantProduct; - address payable biPoolManagerProxy; - address public reserve; - address public broker; + address payable public reserve; address public breakerBox; + address public broker; + + address payable public brokerProxy; + address payable public sortedOraclesProxy; + address payable public biPoolManagerProxy; function setUp() public { new PrecompileHandler(); // needed for reserve CELO transfer checks @@ -80,18 +84,20 @@ contract MU03Checks is Script, Test { cUSD = contracts.celoRegistry("StableToken"); cEUR = contracts.celoRegistry("StableTokenEUR"); cBRL = contracts.celoRegistry("StableTokenBRL"); - reserve = contracts.deployed("PartialReserveProxy"); + reserve = address(uint160(contracts.deployed("PartialReserveProxy"))); celoToken = contracts.celoRegistry("GoldToken"); - broker = contracts.celoRegistry("Broker"); governance = contracts.celoRegistry("Governance"); + brokerProxy = address(uint160(contracts.celoRegistry("Broker"))); sortedOraclesProxy = address(uint160(contracts.celoRegistry("SortedOracles"))); // Get Deployment addresses bridgedUSDC = contracts.dependency("BridgedUSDC"); + bridgedEUROC = contracts.dependency("BridgedEUROC"); breakerBox = contracts.deployed("BreakerBox"); medianDeltaBreaker = contracts.deployed("MedianDeltaBreaker"); valueDeltaBreaker = contracts.deployed("ValueDeltaBreaker"); biPoolManager = contracts.deployed("BiPoolManager"); + broker = contracts.deployed("Broker"); constantSum = contracts.deployed("ConstantSumPricingModule"); constantProduct = contracts.deployed("ConstantProductPricingModule"); biPoolManagerProxy = contracts.deployed("BiPoolManagerProxy"); @@ -102,8 +108,10 @@ contract MU03Checks is Script, Test { setUp(); verifyOwner(); + verifyEUROCSetUp(); verifyBiPoolManager(); verifySortedOracles(); + verifyBroker(); verifyExchanges(); verifyCircuitBreaker(); @@ -124,9 +132,20 @@ contract MU03Checks is Script, Test { SortedOracles(sortedOracles).owner() == governance, "SortedOracles ownership not transferred to governance" ); + require(Broker(broker).owner() == governance, "Broker ownership not transferred to governance"); console2.log("Contract ownerships transferred to governance 🤝"); } + function verifyEUROCSetUp() internal view { + Reserve partialReserve = Reserve(reserve); + if (partialReserve.checkIsCollateralAsset(bridgedEUROC)) { + console2.log("EUROC is a collateral asset 🏦"); + } else { + console2.log("EUROC is not a collateral asset 🏦"); + revert("EUROC is not a collateral asset"); + } + } + function verifyBiPoolManager() internal view { BiPoolManagerProxy bpmProxy = BiPoolManagerProxy(biPoolManagerProxy); address bpmProxyImplementation = bpmProxy._getImplementation(); @@ -140,6 +159,12 @@ contract MU03Checks is Script, Test { revert("Deployed BiPoolManager does not match what proxy points to. See logs."); } console2.log("\tBiPoolManagerProxy has a correct implementation address 🫡"); + + // verify that breakerBox address was updated in BiPoolManager + if (BreakerBox(breakerBox) != BiPoolManager(biPoolManagerProxy).breakerBox()) { + revert("BreakerBox address not updated in BiPoolManager"); + } + console2.log("\tBreakerBox address updated in BiPoolManager 🗳️"); } function verifySortedOracles() internal view { @@ -154,6 +179,26 @@ contract MU03Checks is Script, Test { revert("Deployed SortedOracles does not match what proxy points to. See logs."); } console2.log("\tSortedOraclesProxy has a correct implementation address 🫡"); + + // verify that breakerBox address was updated in SortedOracles + if (BreakerBox(breakerBox) != SortedOracles(sortedOraclesProxy).breakerBox()) { + revert("BreakerBox address not updated in SortedOracles"); + } + console2.log("\tBreakerBox address updated in SortedOracles 🗳️"); + } + + function verifyBroker() internal view { + address brokerImplementation = Proxy(brokerProxy)._getImplementation(); + address expectedBroker = broker; + if (brokerImplementation != expectedBroker) { + console2.log( + "The address of Broker from BrokerProxy: %s does not match the deployed address: %s.", + brokerImplementation, + expectedBroker + ); + revert("Deployed Broker does not match what proxy points to. See logs."); + } + console2.log("\tBrokerProxy has a correct implementation address 🫡"); } /* ================================================================ */ @@ -229,14 +274,12 @@ contract MU03Checks is Script, Test { } } // verify asset0 is always a stable asset - require( - pool.asset0 == cUSD || pool.asset0 == cEUR || pool.asset0 == cBRL, - "asset0 is not a stable asset in the exchange" - ); + Reserve partialReserve = Reserve(reserve); + require(partialReserve.isStableAsset(pool.asset0), "asset0 is not a stable asset in the exchange"); // verify asset1 is always a collateral asset require( - pool.asset1 == celoToken || pool.asset1 == bridgedUSDC, - "asset1 is not CELO or bridgedUSDC in the exchange" + partialReserve.isCollateralAsset(pool.asset1), + "asset1 is not CELO, bridgedUSDC or bridgedEUROC in the exchange" ); } console2.log("\tPoolExchange correctly configured 🤘🏼"); @@ -301,7 +344,7 @@ contract MU03Checks is Script, Test { } function verifyTradingLimits(MU03Config.MU03 memory config) internal view { - IBrokerWithCasts _broker = IBrokerWithCasts(address(broker)); + IBrokerWithCasts _broker = IBrokerWithCasts(brokerProxy); bytes32[] memory exchanges = BiPoolManager(biPoolManagerProxy).getExchangeIds(); for (uint256 i = 0; i < exchanges.length; i++) { @@ -412,12 +455,6 @@ contract MU03Checks is Script, Test { } } console2.log("\tBreakers enabled for all rate feeds 🗳️"); - - // verify that breakerBox address was updated in SortedOracles - if (BreakerBox(breakerBox) != SortedOracles(sortedOraclesProxy).breakerBox()) { - revert("BreakerBox address not updated in SortedOracles"); - } - console2.log("\tBreakerBox address updated in SortedOracles 🗳️"); } function verifyMedianDeltaBreaker(MU03Config.MU03 memory config) internal view { @@ -457,26 +494,35 @@ contract MU03Checks is Script, Test { } function verifyValueDeltaBreaker(MU03Config.MU03 memory config) internal view { - // verify that cooldown period, rate change threshold and reference value for cUSD/USDC pool - uint256 cooldown = ValueDeltaBreaker(valueDeltaBreaker).rateFeedCooldownTime(config.USDCUSD.rateFeedID); - uint256 rateChangeThreshold = ValueDeltaBreaker(valueDeltaBreaker).rateChangeThreshold(config.USDCUSD.rateFeedID); - uint256 referenceValue = ValueDeltaBreaker(valueDeltaBreaker).referenceValues(config.USDCUSD.rateFeedID); - - verifyCooldownTime(cooldown, config.USDCUSD.valueDeltaBreaker0.cooldown, config.USDCUSD.rateFeedID, true); - - verifyRateChangeTheshold( - rateChangeThreshold, - config.USDCUSD.valueDeltaBreaker0.threshold.unwrap(), - config.USDCUSD.rateFeedID, - true - ); + // verify that cooldown period, rate change threshold and reference value were set correctly + for (uint256 i = 0; i < config.rateFeeds.length; i++) { + Config.RateFeed memory rateFeed = config.rateFeeds[i]; - if (referenceValue != config.USDCUSD.valueDeltaBreaker0.referenceValue) { - console2.log( - "ValueDeltaBreaker reference value not set correctly for USDC/USD rate feed %s", - config.USDCUSD.rateFeedID - ); - revert("ValueDeltaBreaker reference value not set correctly for USDC/USD rate feed"); + if (rateFeed.valueDeltaBreaker0.enabled) { + uint256 cooldown = ValueDeltaBreaker(valueDeltaBreaker).rateFeedCooldownTime(rateFeed.rateFeedID); + uint256 rateChangeThreshold = ValueDeltaBreaker(valueDeltaBreaker).rateChangeThreshold(rateFeed.rateFeedID); + uint256 referenceValue = ValueDeltaBreaker(valueDeltaBreaker).referenceValues(rateFeed.rateFeedID); + + // verify cooldown period + verifyCooldownTime(cooldown, rateFeed.valueDeltaBreaker0.cooldown, rateFeed.rateFeedID, true); + + // verify rate change threshold + verifyRateChangeTheshold( + rateChangeThreshold, + rateFeed.valueDeltaBreaker0.threshold.unwrap(), + rateFeed.rateFeedID, + true + ); + + // verify reference value + if (referenceValue != rateFeed.valueDeltaBreaker0.referenceValue) { + console2.log( + "ValueDeltaBreaker reference value not set correctly for the rate feed: %s", + rateFeed.rateFeedID + ); + revert("ValueDeltaBreaker reference values not set correctly for all rate feeds"); + } + } } console2.log("\tValueDeltaBreaker cooldown, rate change threshold and reference value set correctly 🔒"); } @@ -490,21 +536,23 @@ contract MU03Checks is Script, Test { console2.log("\n== Doing some test swaps... =="); - swapCeloTocUSD(); - swapcUSDtoCelo(); - swapCeloTocEUR(); - swapcEURtoCELO(); - swapCeloTocBRL(); - swapcBrlToCELO(); + swapCeloTocUSD(config); + swapcUSDtoCelo(config); + swapCeloTocEUR(config); + swapcEURtoCELO(config); + swapCeloTocBRL(config); + swapcBrlToCELO(config); swapBridgedUSDCTocUSD(config); swapcUSDtoBridgedUSDC(config); swapBridgedUSDCTocEUR(config); swapcEURtoBridgedUSDC(config); swapBridgedUSDCtocBRL(config); swapcBRLtoBridgedUSDC(config); + swapBridgedEUROCTocEUR(config); + swapcEURtoBridgedEUROC(config); } - function swapCeloTocUSD() internal { + function swapCeloTocUSD(MU03Config.MU03 memory config) internal { bytes32 exchangeID = BiPoolManager(biPoolManagerProxy).exchangeIds(0); address trader = vm.addr(5); @@ -515,12 +563,19 @@ contract MU03Checks is Script, Test { // Give trader some celo vm.deal(trader, amountIn); - testAndPerformConstantProductSwap(exchangeID, trader, tokenIn, tokenOut, amountIn); + testAndPerformConstantProductSwap( + exchangeID, + trader, + tokenIn, + tokenOut, + amountIn, + config.cUSDCelo.referenceRateFeedID + ); console2.log("\tCELO -> cUSD swap successful 🚀"); } - function swapcUSDtoCelo() internal { + function swapcUSDtoCelo(MU03Config.MU03 memory config) internal { bytes32 exchangeID = BiPoolManager(biPoolManagerProxy).exchangeIds(0); address trader = vm.addr(5); @@ -528,12 +583,19 @@ contract MU03Checks is Script, Test { address tokenOut = celoToken; uint256 amountIn = 1e18; - testAndPerformConstantProductSwap(exchangeID, trader, tokenIn, tokenOut, amountIn); + testAndPerformConstantProductSwap( + exchangeID, + trader, + tokenIn, + tokenOut, + amountIn, + config.cUSDCelo.referenceRateFeedID + ); console2.log("\tcUSD -> CELO swap successful 🚀"); } - function swapCeloTocEUR() internal { + function swapCeloTocEUR(MU03Config.MU03 memory config) internal { bytes32 exchangeID = BiPoolManager(biPoolManagerProxy).exchangeIds(1); address trader = vm.addr(5); @@ -544,12 +606,19 @@ contract MU03Checks is Script, Test { // Give trader some celo vm.deal(trader, amountIn); - testAndPerformConstantProductSwap(exchangeID, trader, tokenIn, tokenOut, amountIn); + testAndPerformConstantProductSwap( + exchangeID, + trader, + tokenIn, + tokenOut, + amountIn, + config.cEURCelo.referenceRateFeedID + ); console2.log("\tCELO -> cEUR swap successful 🚀"); } - function swapcEURtoCELO() internal { + function swapcEURtoCELO(MU03Config.MU03 memory config) internal { bytes32 exchangeID = BiPoolManager(biPoolManagerProxy).exchangeIds(1); address trader = vm.addr(5); @@ -557,12 +626,19 @@ contract MU03Checks is Script, Test { address tokenOut = celoToken; uint256 amountIn = 1e18; - testAndPerformConstantProductSwap(exchangeID, trader, tokenIn, tokenOut, amountIn); + testAndPerformConstantProductSwap( + exchangeID, + trader, + tokenIn, + tokenOut, + amountIn, + config.cEURCelo.referenceRateFeedID + ); console2.log("\tcEUR -> CELO swap successful 🚀"); } - function swapCeloTocBRL() internal { + function swapCeloTocBRL(MU03Config.MU03 memory config) internal { bytes32 exchangeID = BiPoolManager(biPoolManagerProxy).exchangeIds(2); address trader = vm.addr(5); @@ -573,12 +649,19 @@ contract MU03Checks is Script, Test { // Give trader some celo vm.deal(trader, amountIn); - testAndPerformConstantProductSwap(exchangeID, trader, tokenIn, tokenOut, amountIn); + testAndPerformConstantProductSwap( + exchangeID, + trader, + tokenIn, + tokenOut, + amountIn, + config.cBRLCelo.referenceRateFeedID + ); console2.log("\tCELO -> cBRL swap successful 🚀"); } - function swapcBrlToCELO() internal { + function swapcBrlToCELO(MU03Config.MU03 memory config) internal { bytes32 exchangeID = BiPoolManager(biPoolManagerProxy).exchangeIds(2); address trader = vm.addr(5); @@ -586,7 +669,14 @@ contract MU03Checks is Script, Test { address tokenOut = celoToken; uint256 amountIn = 1e18; - testAndPerformConstantProductSwap(exchangeID, trader, tokenIn, tokenOut, amountIn); + testAndPerformConstantProductSwap( + exchangeID, + trader, + tokenIn, + tokenOut, + amountIn, + config.cBRLCelo.referenceRateFeedID + ); console2.log("\tcBRL -> CELO swap successful 🚀"); } @@ -602,15 +692,7 @@ contract MU03Checks is Script, Test { // Mint some USDC to trader deal(bridgedUSDC, trader, amountIn, true); - testAndPerformConstantSumSwap( - exchangeID, - trader, - tokenIn, - tokenOut, - amountIn, - config.cUSDUSDC.referenceRateFeedID, - true - ); + testAndPerformConstantSumSwap(exchangeID, trader, tokenIn, tokenOut, amountIn, config.cUSDUSDC.referenceRateFeedID); console2.log("\tbridgedUSDC -> cUSD swap successful 🚀"); } @@ -626,15 +708,7 @@ contract MU03Checks is Script, Test { // Mint some USDC to the reserve deal(bridgedUSDC, reserve, 1000e18, true); - testAndPerformConstantSumSwap( - exchangeID, - trader, - tokenIn, - tokenOut, - amountIn, - config.cUSDUSDC.referenceRateFeedID, - false - ); + testAndPerformConstantSumSwap(exchangeID, trader, tokenIn, tokenOut, amountIn, config.cUSDUSDC.referenceRateFeedID); console2.log("\tcUSD -> bridgedUSDC swap successful 🚀"); } @@ -650,15 +724,7 @@ contract MU03Checks is Script, Test { // Mint some USDC to trader deal(bridgedUSDC, trader, amountIn, true); - testAndPerformConstantSumSwap( - exchangeID, - trader, - tokenIn, - tokenOut, - amountIn, - config.cEURUSDC.referenceRateFeedID, - true - ); + testAndPerformConstantSumSwap(exchangeID, trader, tokenIn, tokenOut, amountIn, config.cEURUSDC.referenceRateFeedID); console2.log("\tbridgedUSDC -> cEUR swap successful 🚀"); } @@ -671,15 +737,7 @@ contract MU03Checks is Script, Test { address tokenOut = bridgedUSDC; uint256 amountIn = 10e18; - testAndPerformConstantSumSwap( - exchangeID, - trader, - tokenIn, - tokenOut, - amountIn, - config.cEURUSDC.referenceRateFeedID, - false - ); + testAndPerformConstantSumSwap(exchangeID, trader, tokenIn, tokenOut, amountIn, config.cEURUSDC.referenceRateFeedID); console2.log("\tcEUR -> bridgedUSDC swap successful 🚀"); } @@ -695,38 +753,68 @@ contract MU03Checks is Script, Test { // Mint some USDC to trader deal(bridgedUSDC, trader, amountIn, true); + testAndPerformConstantSumSwap(exchangeID, trader, tokenIn, tokenOut, amountIn, config.cBRLUSDC.referenceRateFeedID); + + console2.log("\tbridgedUSDC -> cBRL swap successful 🚀"); + } + + function swapcBRLtoBridgedUSDC(MU03Config.MU03 memory config) internal { + bytes32 exchangeID = BiPoolManager(biPoolManagerProxy).exchangeIds(5); + + address trader = vm.addr(4); + address tokenIn = cBRL; + address tokenOut = bridgedUSDC; + uint256 amountIn = 10e18; + + testAndPerformConstantSumSwap(exchangeID, trader, tokenIn, tokenOut, amountIn, config.cBRLUSDC.referenceRateFeedID); + + console2.log("\tcBRL -> bridgedUSDC swap successful 🚀"); + } + + function swapBridgedEUROCTocEUR(MU03Config.MU03 memory config) internal { + bytes32 exchangeID = BiPoolManager(biPoolManagerProxy).exchangeIds(6); + + address trader = vm.addr(1); + address tokenIn = bridgedEUROC; + address tokenOut = cEUR; + uint256 amountIn = 100e6; + + // Mint some EUROC to trader + deal(bridgedEUROC, trader, amountIn, true); + testAndPerformConstantSumSwap( exchangeID, trader, tokenIn, tokenOut, amountIn, - config.cBRLUSDC.referenceRateFeedID, - true + config.cEUREUROC.referenceRateFeedID ); - console2.log("\tbridgedUSDC -> cBRL swap successful 🚀"); + console2.log("\tbridgedEUROC -> cEUR swap successful 🚀"); } - function swapcBRLtoBridgedUSDC(MU03Config.MU03 memory config) internal { - bytes32 exchangeID = BiPoolManager(biPoolManagerProxy).exchangeIds(5); + function swapcEURtoBridgedEUROC(MU03Config.MU03 memory config) internal { + bytes32 exchangeID = BiPoolManager(biPoolManagerProxy).exchangeIds(6); - address trader = vm.addr(4); - address tokenIn = cBRL; - address tokenOut = bridgedUSDC; + address trader = vm.addr(1); + address tokenIn = cEUR; + address tokenOut = bridgedEUROC; uint256 amountIn = 10e18; + // Mint some USDC to the reserve + deal(bridgedEUROC, reserve, 1000e18, true); + testAndPerformConstantSumSwap( exchangeID, trader, tokenIn, tokenOut, amountIn, - config.cBRLUSDC.referenceRateFeedID, - false + config.cEUREUROC.referenceRateFeedID ); - console2.log("\tcBRL -> bridgedUSDC swap successful 🚀"); + console2.log("\tcEUR -> bridgedEUROC swap successful 🚀"); } // /* ================================================================ */ @@ -741,8 +829,8 @@ contract MU03Checks is Script, Test { ) internal view { if (currentThreshold != expectedThreshold) { if (isValueDeltaBreaker) { - console2.log("ValueDeltaBreaker rate change threshold not set correctly for USDC/USD rate feed %s", rateFeedID); - revert("ValueDeltaBreaker rate change threshold not set correctly for USDC/USD rate feed"); + console2.log("ValueDeltaBreaker rate change threshold not set correctly for rate feed %s", rateFeedID); + revert("ValueDeltaBreaker rate change threshold not set correctly for all rate feeds"); } console2.log("MedianDeltaBreaker rate change threshold not set correctly for rate feed %s", rateFeedID); revert("MedianDeltaBreaker rate change threshold not set correctly for all rate feeds"); @@ -757,8 +845,8 @@ contract MU03Checks is Script, Test { ) internal view { if (currentCoolDown != expectedCoolDown) { if (isValueDeltaBreaker) { - console2.log("ValueDeltaBreaker cooldown not set correctly for USDC/USD rate feed %s", rateFeedID); - revert("ValueDeltaBreaker cooldown not set correctly for USDC/USD rate feed"); + console2.log("ValueDeltaBreaker cooldown not set correctly for rate feed %s", rateFeedID); + revert("ValueDeltaBreaker cooldown not set correctly for all rate feeds"); } console2.log("MedianDeltaBreaker cooldown not set correctly for rate feed %s", rateFeedID); revert("MedianDeltaBreaker cooldown not set correctly for all rate feeds"); @@ -770,28 +858,29 @@ contract MU03Checks is Script, Test { address trader, address tokenIn, address tokenOut, - uint256 amountIn + uint256 amountIn, + address rateFeedID ) internal { - uint256 amountOut = Broker(broker).getAmountOut(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn); + uint256 amountOut = Broker(brokerProxy).getAmountOut(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn); IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeID); + (uint256 numerator, uint256 denominator) = SortedOracles(sortedOraclesProxy).medianRate(rateFeedID); + FixidityLib.Fraction memory rate = FixidityLib.newFixedFraction(numerator, denominator); - FixidityLib.Fraction memory numerator; - FixidityLib.Fraction memory denominator; + FixidityLib.Fraction memory netAmountIn = FixidityLib.newFixed(amountIn).multiply( + FixidityLib.newFixedFraction(9975, 10000) + ); + uint256 estimatedAmountOut; if (tokenIn == pool.asset0) { - numerator = FixidityLib.newFixed(amountIn).multiply(FixidityLib.newFixed(pool.bucket1)); - denominator = FixidityLib.newFixed(pool.bucket0).add(FixidityLib.newFixed(amountIn)); + estimatedAmountOut = netAmountIn.divide(rate).fromFixed(); } else { - numerator = FixidityLib.newFixed(amountIn).multiply(FixidityLib.newFixed(pool.bucket0)); - denominator = FixidityLib.newFixed(pool.bucket1).add(FixidityLib.newFixed(amountIn)); + estimatedAmountOut = netAmountIn.multiply(rate).fromFixed(); } - uint256 estimatedAmountOut = numerator.unwrap().div(denominator.unwrap()); - FixidityLib.Fraction memory maxTolerance = FixidityLib.newFixedFraction(25, 10000); uint256 threshold = FixidityLib.newFixed(estimatedAmountOut).multiply(maxTolerance).fromFixed(); - assertApproxEqAbs(amountOut, estimatedAmountOut, threshold); + assertApproxEqAbs(amountOut, estimatedAmountOut, threshold); doSwapIn(exchangeID, trader, tokenIn, tokenOut, amountIn, amountOut); } @@ -801,30 +890,25 @@ contract MU03Checks is Script, Test { address tokenIn, address tokenOut, uint256 amountIn, - address rateFeedID, - bool isBridgedUsdcToStable + address rateFeedID ) internal { - uint256 amountOut = Broker(broker).getAmountOut(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn); + uint256 amountOut = Broker(brokerProxy).getAmountOut(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn); + IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeID); (uint256 numerator, uint256 denominator) = SortedOracles(sortedOraclesProxy).medianRate(rateFeedID); - uint256 estimatedAmountOut; + FixidityLib.Fraction memory rate = FixidityLib.newFixedFraction(numerator, denominator); - if (isBridgedUsdcToStable) { - estimatedAmountOut = FixidityLib - .newFixed(amountIn.mul(1e12)) - .multiply(FixidityLib.wrap(numerator).divide(FixidityLib.wrap(denominator))) - .fromFixed(); - } else { - estimatedAmountOut = FixidityLib - .newFixed(amountIn) - .multiply(FixidityLib.wrap(denominator).divide(FixidityLib.wrap(numerator))) - .fromFixed(); + uint256 estimatedAmountOut; + if (tokenIn == pool.asset0) { + estimatedAmountOut = FixidityLib.newFixed(amountIn).divide(rate).fromFixed(); estimatedAmountOut = estimatedAmountOut.div(1e12); + } else { + estimatedAmountOut = FixidityLib.newFixed(amountIn.mul(1e12)).multiply(rate).fromFixed(); } FixidityLib.Fraction memory maxTolerance = FixidityLib.newFixedFraction(25, 1000); uint256 threshold = FixidityLib.newFixed(estimatedAmountOut).multiply(maxTolerance).fromFixed(); - assertApproxEqAbs(amountOut, estimatedAmountOut, threshold); + assertApproxEqAbs(amountOut, estimatedAmountOut, threshold); doSwapIn(exchangeID, trader, tokenIn, tokenOut, amountIn, amountOut); } @@ -840,8 +924,8 @@ contract MU03Checks is Script, Test { uint256 beforeSellingTokenIn = IERC20(tokenIn).balanceOf(trader); vm.startPrank(trader); - IERC20(tokenIn).approve(address(broker), amountIn); - Broker(broker).swapIn(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn, amountOut); + IERC20(tokenIn).approve(address(brokerProxy), amountIn); + Broker(brokerProxy).swapIn(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn, amountOut); assertEq(IERC20(tokenOut).balanceOf(trader), beforeBuyingTokenOut + amountOut); assertEq(IERC20(tokenIn).balanceOf(trader), beforeSellingTokenIn - amountIn); vm.stopPrank(); diff --git a/script/upgrades/MU03/deploy/MU03-02-Create-Implementations.sol b/script/upgrades/MU03/deploy/MU03-02-Create-Implementations.sol index 7fc09015..1706e110 100644 --- a/script/upgrades/MU03/deploy/MU03-02-Create-Implementations.sol +++ b/script/upgrades/MU03/deploy/MU03-02-Create-Implementations.sol @@ -6,6 +6,7 @@ import { Chain } from "script/utils/Chain.sol"; import { console2 } from "forge-std/Script.sol"; import { BiPoolManager } from "mento-core-2.2.0/swap/BiPoolManager.sol"; +import { Broker } from "mento-core-2.2.0/swap/Broker.sol"; import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; /* @@ -14,6 +15,7 @@ import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; contract MU03_CreateImplementations is Script { function run() public { address biPoolManager; + address broker; address sortedOracles; address governance = contracts.celoRegistry("Governance"); @@ -23,6 +25,10 @@ contract MU03_CreateImplementations is Script { biPoolManager = address(new BiPoolManager(false)); BiPoolManager(biPoolManager).transferOwnership(governance); + // Deploy Broker implementation + broker = address(new Broker(false)); + Broker(broker).transferOwnership(governance); + // Deploy SortedOracles implementation sortedOracles = address(new SortedOracles(false)); SortedOracles(sortedOracles).transferOwnership(governance); @@ -32,6 +38,8 @@ contract MU03_CreateImplementations is Script { console2.log("----------"); console2.log("BiPoolManager deployed at: ", biPoolManager); console2.log("BiPoolManager(%s) ownership transferred to %s", biPoolManager, governance); + console2.log("Broker deployed at: ", broker); + console2.log("Broker(%s) ownership transferred to %s", broker, governance); console2.log("SortedOracles deployed at: ", sortedOracles); console2.log("SortedOracles(%s) ownership transferred to %s", sortedOracles, governance); console2.log("----------"); diff --git a/script/upgrades/dependencies.json b/script/upgrades/dependencies.json index 48b82d52..e255aef4 100644 --- a/script/upgrades/dependencies.json +++ b/script/upgrades/dependencies.json @@ -1,7 +1,7 @@ { "42220": { "BridgedUSDC": "0xEB466342C4d449BC9f53A865D5Cb90586f405215", - "BridgedEUROC": "", + "BridgedEUROC": "Address not yet accessible", "USDCUSDRateFeedAddr": "0xA1A8003936862E7a15092A91898D69fa8bCE290c", "USDCEURRateFeedAddr": "0x206B25Ea01E188Ee243131aFdE526bA6E131a016", "USDCBRLRateFeedAddr": "0x25F21A1f97607Edf6852339fad709728cffb9a9d", @@ -11,7 +11,7 @@ }, "62320": { "BridgedUSDC": "0xD4079B322c392D6b196f90AA4c439fC2C16d6770", - "BridgedEUROC": "0xD4079B322c392D6b196f90AA4c439fC2C16d6770", + "BridgedEUROC": "0x6f90ac394b1F45290d3023e4Ba0203005cAF2A4B", "USDCUSDRateFeedAddr": "0xA1A8003936862E7a15092A91898D69fa8bCE290c", "USDCEURRateFeedAddr": "0x206B25Ea01E188Ee243131aFdE526bA6E131a016", "USDCBRLRateFeedAddr": "0x25F21A1f97607Edf6852339fad709728cffb9a9d", @@ -21,7 +21,7 @@ }, "44787": { "BridgedUSDC": "0x87D61dA3d668797786D73BC674F053f87111570d", - "BridgedEUROC": "0x87D61dA3d668797786D73BC674F053f87111570d", + "BridgedEUROC": "0x6e673502c5b55F3169657C004e5797fFE5be6653", "USDCUSDRateFeedAddr": "0xA1A8003936862E7a15092A91898D69fa8bCE290c", "USDCEURRateFeedAddr": "0x206B25Ea01E188Ee243131aFdE526bA6E131a016", "USDCBRLRateFeedAddr": "0x25F21A1f97607Edf6852339fad709728cffb9a9d", diff --git a/script/utils/Arrays.sol b/script/utils/Arrays.sol index d2cf1887..73c08f28 100644 --- a/script/utils/Arrays.sol +++ b/script/utils/Arrays.sol @@ -130,13 +130,23 @@ library Arrays { return arr; } - function bytes4s(bytes4 e0, bytes4 e1, bytes4 e2, bytes4 e3, bytes4 e4) internal pure returns (bytes4[] memory arr) { - arr = new bytes4[](5); - arr[0] = bytes4(e0); - arr[1] = bytes4(e1); - arr[2] = bytes4(e2); - arr[3] = bytes4(e3); - arr[4] = bytes4(e4); + function addresses( + address e0, + address e1, + address e2, + address e3, + address e4, + address e5, + address e6 + ) internal pure returns (address[] memory arr) { + arr = new address[](7); + arr[0] = e0; + arr[1] = e1; + arr[2] = e2; + arr[3] = e3; + arr[4] = e4; + arr[5] = e5; + arr[6] = e6; return arr; } From 4438350d142e86e38e734b7625abe234a0686635 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 24 Aug 2023 22:28:00 -0500 Subject: [PATCH 15/64] refactor: check transactions before simulation --- script/utils/GovernanceHelper.sol | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/script/utils/GovernanceHelper.sol b/script/utils/GovernanceHelper.sol index 48344b4d..ee4a296b 100644 --- a/script/utils/GovernanceHelper.sol +++ b/script/utils/GovernanceHelper.sol @@ -49,6 +49,10 @@ contract GovernanceHelper is Script { } function simulateProposal(ICeloGovernance.Transaction[] memory transactions, address governance) internal { + require( + transactions.length > 0, + "Proposal has no transactions. Please check buildProposal() function returns transactions." + ); vm.activeFork(); vm.startPrank(governance); for (uint256 i = 0; i < transactions.length; i++) { From a0cf881bbef685c73cb6525d6372e9a08f5b892d Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 24 Aug 2023 22:47:26 -0500 Subject: [PATCH 16/64] refactor: get reserve proxy address from registry --- script/upgrades/eXOF/eXOF.sol | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index 9da8b1bb..9042801a 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -46,7 +46,6 @@ contract eXOF is IMentoUpgrade, GovernanceScript { ICeloGovernance.Transaction[] private transactions; - address private eXOFToken; address payable private eXOFProxy; address private celo; address private bridgedEUROC; @@ -88,7 +87,6 @@ contract eXOF is IMentoUpgrade, GovernanceScript { */ function setAddresses() public { // Tokens - eXOFToken = contracts.deployed("StableTokenXOF"); eXOFProxy = contracts.deployed("StableTokenXOFProxy"); celo = contracts.celoRegistry("GoldToken"); bridgedEUROC = contracts.dependency("BridgedEUROC"); @@ -140,7 +138,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); proposal_initializeEXOFToken(config); - proposal_addEXOFToCeloRegistry(); //TODO(Bayo): registry was already updated on testnet before this was added. How? + //TODO(Bayo): registry was already updated on testnet before this was added. How? + // proposal_addEXOFToCeloRegistry(); proposal_configureEXOFConstitutionParameters(); proposal_addEXOFToReserves(); proposal_enableGasPaymentsWithEXOF(); @@ -152,6 +151,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { proposal_configureMedianDeltaBreakers(config); proposal_configureValueDeltaBreaker(config); proposal_configureNonrecoverableValueDeltaBreaker(config); + + return transactions; } /** @@ -166,7 +167,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { eXOFProxy, abi.encodeWithSelector( _eXOFProxy._setAndInitializeImplementation.selector, - eXOFToken, + contracts.deployed("StableTokenXOF"), abi.encodeWithSelector( StableTokenXOF(0).initialize.selector, config.stableTokenXOF.name, @@ -216,7 +217,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { console.log("Token already added to the partial reserve, skipping: %s", eXOFProxy); } - address payable mainReserveProxy = contracts.deployed("ReserveProxy"); + address mainReserveProxy = contracts.celoRegistry("Reserve"); if (IReserve(mainReserveProxy).isStableAsset(eXOFProxy) == false) { transactions.push( ICeloGovernance.Transaction( From 93f2fa0b7971c64bd90fe7b19aa9c1e991a0dbe2 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 24 Aug 2023 22:48:00 -0500 Subject: [PATCH 17/64] chore: re add bytes4 array helper --- script/utils/Arrays.sol | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/script/utils/Arrays.sol b/script/utils/Arrays.sol index 73c08f28..9a1073fb 100644 --- a/script/utils/Arrays.sol +++ b/script/utils/Arrays.sol @@ -150,6 +150,16 @@ library Arrays { return arr; } + function bytes4s(bytes4 e0, bytes4 e1, bytes4 e2, bytes4 e3, bytes4 e4) internal pure returns (bytes4[] memory arr) { + arr = new bytes4[](5); + arr[0] = bytes4(e0); + arr[1] = bytes4(e1); + arr[2] = bytes4(e2); + arr[3] = bytes4(e3); + arr[4] = bytes4(e4); + return arr; + } + function bytes32s(bytes32 e0) internal pure returns (bytes32[] memory arr) { arr = new bytes32[](1); arr[0] = e0; From a8e5287b8e28aae8682ab082321e783db253a05e Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Fri, 25 Aug 2023 11:14:52 -0500 Subject: [PATCH 18/64] refactor: remove collateral asset spent set --- script/upgrades/eXOF/eXOF.sol | 27 +-------------------------- 1 file changed, 1 insertion(+), 26 deletions(-) diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index 9042801a..ba9826c7 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -138,12 +138,10 @@ contract eXOF is IMentoUpgrade, GovernanceScript { eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); proposal_initializeEXOFToken(config); - //TODO(Bayo): registry was already updated on testnet before this was added. How? - // proposal_addEXOFToCeloRegistry(); + proposal_addEXOFToCeloRegistry(); proposal_configureEXOFConstitutionParameters(); proposal_addEXOFToReserves(); proposal_enableGasPaymentsWithEXOF(); - proposal_setDailySpendingRatioForCollateralAssets(); proposal_createExchanges(config); proposal_configureTradingLimits(config); @@ -277,29 +275,6 @@ contract eXOF is IMentoUpgrade, GovernanceScript { } } - /** - * @notice This function creates the transaction to set the daily spending ratio for all collateral assets - * including the newly added EuroC. - */ - function proposal_setDailySpendingRatioForCollateralAssets() private { - uint256 dailySpendingRatio = 1e24; - - address[] memory collateralAssets = Arrays.addresses(celo, contracts.dependency("BridgedUSDC"), bridgedEUROC); - uint256[] memory dailySpendingRatios = Arrays.uints(dailySpendingRatio, dailySpendingRatio, dailySpendingRatio); - - transactions.push( - ICeloGovernance.Transaction( - 0, - partialReserveProxy, - abi.encodeWithSelector( - Reserve(0).setDailySpendingRatioForCollateralAssets.selector, - collateralAssets, - dailySpendingRatios - ) - ) - ); - } - /** * @notice Creates the exchanges for the new pools. */ From 419dc23a25b4b933c09cbd0fddfacc79a76de35c Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Fri, 25 Aug 2023 12:28:40 -0500 Subject: [PATCH 19/64] refactor: add reserve, registry & fee tokn checks --- script/upgrades/eXOF/eXOFChecks.sol | 75 ++++++++++++++++++++++++----- script/utils/Arrays.sol | 9 ++++ 2 files changed, 71 insertions(+), 13 deletions(-) diff --git a/script/upgrades/eXOF/eXOFChecks.sol b/script/upgrades/eXOF/eXOFChecks.sol index 45213160..321f1431 100644 --- a/script/upgrades/eXOF/eXOFChecks.sol +++ b/script/upgrades/eXOF/eXOFChecks.sol @@ -15,6 +15,9 @@ import { FixidityLib } from "mento-core-2.2.0/common/FixidityLib.sol"; import { IBiPoolManager } from "mento-core-2.2.0/interfaces/IBiPoolManager.sol"; import { IBroker } from "mento-core-2.2.0/interfaces/IBroker.sol"; import { IERC20Metadata } from "mento-core-2.2.0/common/interfaces/IERC20Metadata.sol"; +import { IRegistry } from "mento-core-2.2.0/common/interfaces/IRegistry.sol"; + +import { IFeeCurrencyWhitelist } from "script/interfaces/IFeeCurrencyWhitelist.sol"; import { BiPoolManagerProxy } from "mento-core-2.2.0/proxies/BiPoolManagerProxy.sol"; import { StableTokenXOFProxy } from "mento-core-2.2.0/legacy/proxies/StableTokenXOFProxy.sol"; @@ -68,6 +71,7 @@ contract eXOFChecks is Script, Test { address public constantSum; address public constantProduct; address payable biPoolManagerProxy; + address public partialReserve; address public reserve; address public broker; address public breakerBox; @@ -84,11 +88,12 @@ contract eXOFChecks is Script, Test { contracts.load("eXOF-02-Create-Nonupgradeable-Contracts", "latest"); // Get proxy addresses - eXOF = address(uint160(contracts.celoRegistry("StableTokenXOF"))); + eXOF = contracts.deployed("StableTokenXOFProxy"); cUSD = contracts.celoRegistry("StableToken"); cEUR = contracts.celoRegistry("StableTokenEUR"); cBRL = contracts.celoRegistry("StableTokenBRL"); - reserve = contracts.deployed("PartialReserveProxy"); + partialReserve = contracts.deployed("PartialReserveProxy"); + reserve = contracts.celoRegistry("Reserve"); celoToken = contracts.celoRegistry("GoldToken"); broker = contracts.celoRegistry("Broker"); governance = contracts.celoRegistry("Governance"); @@ -113,11 +118,16 @@ contract eXOFChecks is Script, Test { console.log("\nStarting eXOF checks: \n"); verifyOwner(); verifyEXOFStableToken(); + verifyEXOFAddedToRegistry(); + verifyEXOFAddedToReserves(); + verifyEXOFAddedToFeeCurrencyWhitelist(); verifyExchanges(); verifyCircuitBreaker(); } function verifyOwner() internal view { + console.log("== Verifying Token Stuff... =="); + address eXOFImplementation = contracts.deployed("StableTokenXOF"); require( StableTokenXOF(eXOFImplementation).owner() == governance, @@ -127,7 +137,7 @@ contract eXOFChecks is Script, Test { ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).owner() == governance, "Nonrecoverable Value Delta Breaker ownership not transferred to governance" ); - console.log("🟢 Contract ownerships transferred to governance \n"); + console.log("🟢 Contract ownerships transferred to governance"); } function verifyEXOFStableToken() internal view { @@ -143,7 +153,46 @@ contract eXOFChecks is Script, Test { ); revert("Deployed StableTokenXOF does not match what proxy points to. See logs."); } - console.log("🟢 StableTokenXOFProxy has the correct implementation address \n"); + console.log("🟢 StableTokenXOFProxy has the correct implementation address"); + } + + function verifyEXOFAddedToRegistry() internal view { + address registryEXOFAddress = IRegistry(REGISTRY_ADDRESS).getAddressForStringOrDie("StableTokenXOF"); + address deployedEXOFAddress = contracts.deployed("StableTokenXOFProxy"); + + if (registryEXOFAddress != deployedEXOFAddress) { + console.log( + "The eXOF address from the registry: %s does not match the deployed address: %s.", + registryEXOFAddress, + deployedEXOFAddress + ); + revert("Deployed eXOF does not match what registry points to. See logs."); + } + + console.log("🟢 eXOF has been added to the registry"); + } + + function verifyEXOFAddedToReserves() internal view { + if (!Reserve(address(uint160(partialReserve))).isStableAsset(eXOF)) { + revert("eXOF has not been added to the partial reserve."); + } + + if (!Reserve(address(uint160(reserve))).isStableAsset(eXOF)) { + revert("eXOF has not been added to the reserve."); + } + + console.log("🟢 eXOF has been added to the reserves"); + } + + function verifyEXOFAddedToFeeCurrencyWhitelist() internal view { + address[] memory feeCurrencyWhitelist = IFeeCurrencyWhitelist(contracts.celoRegistry("FeeCurrencyWhitelist")) + .getWhitelist(); + + if (!Arrays.contains(feeCurrencyWhitelist, eXOF)) { + revert("eXOF has not been added to the fee currency whitelist."); + } + + console.log("🟢 eXOF has been added to the fee currency whitelist"); } /* ================================================================ */ @@ -153,7 +202,7 @@ contract eXOFChecks is Script, Test { function verifyExchanges() internal { eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); - console.log("== Verifying exchanges... =="); + console.log("\n== Verifying exchanges... =="); verifyPoolExchange(config); verifyPoolConfig(config); @@ -225,7 +274,7 @@ contract eXOFChecks is Script, Test { "asset1 is not CELO or bridgedUSDC in the exchange" ); } - console.log("\tPoolExchange correctly configured 🤘🏼"); + console.log("🟢 PoolExchange correctly configured 🤘🏼"); } function verifyPoolConfig(eXOFConfig.eXOF memory config) internal view { @@ -281,7 +330,7 @@ contract eXOFChecks is Script, Test { revert("stablePoolResetSize of pool does not match the expected stablePoolResetSize. See logs."); } } - console.log("\tPool config is correctly configured 🤘🏼"); + console.log("🟢 Pool config is correctly configured 🤘🏼"); } function verifyTradingLimits(eXOFConfig.eXOF memory config) internal view { @@ -321,7 +370,7 @@ contract eXOFChecks is Script, Test { revert("Not all trading limits were configured correctly."); } } - console.log("\tTrading limits set for all exchanges 🔒"); + console.log("🟢 Trading limits set for all exchanges 🔒"); } /* ================================================================ */ @@ -345,7 +394,7 @@ contract eXOFChecks is Script, Test { console.log("The Nonrecoverable ValueDeltaBreaker was not set with trading halted ❌"); revert("Nonrecoverable ValueDeltaBreaker was not set with trading halted"); } - console.log("\t Nonrecoverable ValueDeltaBreaker set with trading mode 3"); + console.log("🟢 Nonrecoverable ValueDeltaBreaker set with trading mode 3"); // verify that rate feed dependencies were configured correctly address EUROCXOFDependency = BreakerBox(breakerBox).rateFeedDependencies(config.EUROXOF.rateFeedID, 0); @@ -353,7 +402,7 @@ contract eXOFChecks is Script, Test { EUROCXOFDependency == config.EUROXOF.dependentRateFeeds[0], "EUROC/XOF rate feed dependency not set correctly" ); - console.log("\tRate feed dependencies configured correctly 🗳️"); + console.log("🟢 Rate feed dependencies configured correctly 🗳️"); } function verifyBreakersAreEnabled(eXOFConfig.eXOF memory config) internal view { @@ -388,7 +437,7 @@ contract eXOFChecks is Script, Test { } } } - console.log("\tBreakers enabled for all rate feeds 🗳️"); + console.log("🟢 Breakers enabled for all rate feeds 🗳️"); } function verifyMedianDeltaBreaker(eXOFConfig.eXOF memory config) internal view { @@ -422,7 +471,7 @@ contract eXOFChecks is Script, Test { } } } - console.log("\tMedianDeltaBreaker cooldown, rate change threshold and smoothing factor set correctly 🔒"); + console.log("🟢 MedianDeltaBreaker cooldown, rate change threshold and smoothing factor set correctly 🔒"); } function verifyValueDeltaBreaker(eXOFConfig.eXOF memory config) internal view { @@ -453,7 +502,7 @@ contract eXOFChecks is Script, Test { } } } - console.log("\tValueDeltaBreaker cooldown, rate change threshold and reference value set correctly 🔒"); + console.log("🟢 ValueDeltaBreaker cooldown, rate change threshold and reference value set correctly 🔒 \n"); } function verifyNonrecoverableValueDeltaBreaker(eXOFConfig.eXOF memory config) internal view { diff --git a/script/utils/Arrays.sol b/script/utils/Arrays.sol index 9a1073fb..ac8062ad 100644 --- a/script/utils/Arrays.sol +++ b/script/utils/Arrays.sol @@ -205,4 +205,13 @@ library Arrays { arr[4] = e4; return arr; } + + function contains(address[] memory self, address value) internal pure returns (bool) { + for (uint i = 0; i < self.length; i++) { + if (self[i] == value) { + return true; + } + } + return false; + } } From b18ca7315c93f7797b6e599b6ac631638a4f7dd4 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Mon, 28 Aug 2023 20:34:01 -0500 Subject: [PATCH 20/64] feat: load contracts without logs --- script/utils/Contracts.sol | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/script/utils/Contracts.sol b/script/utils/Contracts.sol index 3ffaeb1f..28949d1b 100644 --- a/script/utils/Contracts.sol +++ b/script/utils/Contracts.sol @@ -35,6 +35,14 @@ library Contracts { } function load(Cache storage self, string memory script, string memory timestamp) internal { + _load(self, script, timestamp, false); + } + + function loadSilent(Cache storage self, string memory script, string memory timestamp) internal { + _load(self, script, timestamp, true); + } + + function _load(Cache storage self, string memory script, string memory timestamp, bool silent) internal { string memory chainId = Chain.idString(); string memory root = vm.projectRoot(); string memory path = string( @@ -75,7 +83,10 @@ library Contracts { // todo(bogdan): think about best way to handle overrides self.contractAddress[keccak256(bytes(contractName))] = contractAddresses[i]; - console.log("Loaded contract %s at %s", contractName, contractAddresses[i]); + + if (!silent) { + console.log("Loaded contract %s at %s", contractName, contractAddresses[i]); + } } } } From 23355cc45c13bac8183f11dcd0c245486fda2497 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Mon, 28 Aug 2023 21:12:55 -0500 Subject: [PATCH 21/64] refactor: use current median + split checks file --- script/upgrades/eXOF/eXOFChecks.base.sol | 119 ++++ script/upgrades/eXOF/eXOFChecks.sol | 769 +-------------------- script/upgrades/eXOF/eXOFChecks.swap.sol | 243 +++++++ script/upgrades/eXOF/eXOFChecks.verify.sol | 504 ++++++++++++++ 4 files changed, 874 insertions(+), 761 deletions(-) create mode 100644 script/upgrades/eXOF/eXOFChecks.base.sol create mode 100644 script/upgrades/eXOF/eXOFChecks.swap.sol create mode 100644 script/upgrades/eXOF/eXOFChecks.verify.sol diff --git a/script/upgrades/eXOF/eXOFChecks.base.sol b/script/upgrades/eXOF/eXOFChecks.base.sol new file mode 100644 index 00000000..1fc4f3f2 --- /dev/null +++ b/script/upgrades/eXOF/eXOFChecks.base.sol @@ -0,0 +1,119 @@ +// SPDX-License-Identifier: GPL-3.0-or-later +pragma solidity ^0.5.13; +pragma experimental ABIEncoderV2; + +import { console2 as console } from "forge-std/Script.sol"; +import { Test } from "forge-std/Test.sol"; +import { PrecompileHandler } from "celo-foundry/PrecompileHandler.sol"; +import { IERC20 } from "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol"; + +import { Script } from "script/utils/Script.sol"; +import { Chain } from "script/utils/Chain.sol"; +import { Arrays } from "script/utils/Arrays.sol"; + +import { FixidityLib } from "mento-core-2.2.0/common/FixidityLib.sol"; +import { IBiPoolManager } from "mento-core-2.2.0/interfaces/IBiPoolManager.sol"; +import { IBroker } from "mento-core-2.2.0/interfaces/IBroker.sol"; +import { IERC20Metadata } from "mento-core-2.2.0/common/interfaces/IERC20Metadata.sol"; +import { IRegistry } from "mento-core-2.2.0/common/interfaces/IRegistry.sol"; + +import { IFeeCurrencyWhitelist } from "script/interfaces/IFeeCurrencyWhitelist.sol"; + +import { BiPoolManagerProxy } from "mento-core-2.2.0/proxies/BiPoolManagerProxy.sol"; +import { StableTokenXOFProxy } from "mento-core-2.2.0/legacy/proxies/StableTokenXOFProxy.sol"; +import { StableTokenXOF } from "mento-core-2.2.0/legacy/StableTokenXOF.sol"; +import { Broker } from "mento-core-2.2.0/swap/Broker.sol"; +import { BiPoolManager } from "mento-core-2.2.0/swap/BiPoolManager.sol"; +import { Exchange } from "mento-core-2.2.0/legacy/Exchange.sol"; +import { TradingLimits } from "mento-core-2.2.0/libraries/TradingLimits.sol"; +import { BreakerBox } from "mento-core-2.2.0/oracles/BreakerBox.sol"; +import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; +import { Reserve } from "mento-core-2.2.0/swap/Reserve.sol"; +import { MedianDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/MedianDeltaBreaker.sol"; +import { ValueDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/ValueDeltaBreaker.sol"; +import { ConstantSumPricingModule } from "mento-core-2.2.0/swap/ConstantSumPricingModule.sol"; +import { SafeMath } from "celo-foundry/test/SafeMath.sol"; +import { Proxy } from "mento-core-2.2.0/common/Proxy.sol"; + +import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; + +import { eXOFConfig, Config } from "./Config.sol"; + +contract eXOFChecksBase is Script, Test { + using TradingLimits for TradingLimits.Config; + using FixidityLib for FixidityLib.Fraction; + using SafeMath for uint256; + + address public celoToken; + address public cUSD; + address public cEUR; + address public cBRL; + address payable public eXOF; + address public bridgedUSDC; + address public bridgedEUROC; + address public governance; + address public medianDeltaBreaker; + address public valueDeltaBreaker; + address public nonrecoverableValueDeltaBreaker; + address public biPoolManager; + address payable sortedOraclesProxy; + address public sortedOracles; + address public constantSum; + address public constantProduct; + address payable biPoolManagerProxy; + address public partialReserve; + address public reserve; + address public broker; + address public breakerBox; + + function setUp() public { + new PrecompileHandler(); // needed for reserve CELO transfer checks + // Load addresses from deployments + contracts.loadSilent("MU01-00-Create-Proxies", "latest"); + contracts.loadSilent("MU01-01-Create-Nonupgradeable-Contracts", "latest"); + contracts.loadSilent("MU03-01-Create-Nonupgradeable-Contracts", "latest"); + contracts.loadSilent("MU03-02-Create-Implementations", "latest"); + contracts.loadSilent("eXOF-00-Create-Proxies", "latest"); + contracts.loadSilent("eXOF-01-Create-Implementations", "latest"); + contracts.loadSilent("eXOF-02-Create-Nonupgradeable-Contracts", "latest"); + + // Get proxy addresses + eXOF = contracts.deployed("StableTokenXOFProxy"); + cUSD = contracts.celoRegistry("StableToken"); + cEUR = contracts.celoRegistry("StableTokenEUR"); + cBRL = contracts.celoRegistry("StableTokenBRL"); + partialReserve = contracts.deployed("PartialReserveProxy"); + reserve = contracts.celoRegistry("Reserve"); + celoToken = contracts.celoRegistry("GoldToken"); + broker = contracts.celoRegistry("Broker"); + governance = contracts.celoRegistry("Governance"); + sortedOraclesProxy = address(uint160(contracts.celoRegistry("SortedOracles"))); + + // Get Deployment addresses + bridgedUSDC = contracts.dependency("BridgedUSDC"); + bridgedEUROC = contracts.dependency("BridgedEUROC"); + breakerBox = contracts.deployed("BreakerBox"); + medianDeltaBreaker = contracts.deployed("MedianDeltaBreaker"); + valueDeltaBreaker = contracts.deployed("ValueDeltaBreaker"); + nonrecoverableValueDeltaBreaker = contracts.deployed("NonrecoverableValueDeltaBreaker"); + biPoolManager = contracts.deployed("BiPoolManager"); + constantSum = contracts.deployed("ConstantSumPricingModule"); + constantProduct = contracts.deployed("ConstantProductPricingModule"); + biPoolManagerProxy = contracts.deployed("BiPoolManagerProxy"); + sortedOracles = contracts.deployed("SortedOracles"); + } + + /** + * @notice Helper function to get the exchange ID for a pool. + */ + function getExchangeId(address asset0, address asset1, bool isConstantSum) internal view returns (bytes32) { + return + keccak256( + abi.encodePacked( + IERC20Metadata(asset0).symbol(), + IERC20Metadata(asset1).symbol(), + isConstantSum ? "ConstantSum" : "ConstantProduct" + ) + ); + } +} diff --git a/script/upgrades/eXOF/eXOFChecks.sol b/script/upgrades/eXOF/eXOFChecks.sol index 321f1431..3d7daf34 100644 --- a/script/upgrades/eXOF/eXOFChecks.sol +++ b/script/upgrades/eXOF/eXOFChecks.sol @@ -2,774 +2,21 @@ pragma solidity ^0.5.13; pragma experimental ABIEncoderV2; -import { console2 as console } from "forge-std/Script.sol"; import { Test } from "forge-std/Test.sol"; -import { PrecompileHandler } from "celo-foundry/PrecompileHandler.sol"; -import { IERC20 } from "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol"; - import { Script } from "script/utils/Script.sol"; -import { Chain } from "script/utils/Chain.sol"; -import { Arrays } from "script/utils/Arrays.sol"; - -import { FixidityLib } from "mento-core-2.2.0/common/FixidityLib.sol"; -import { IBiPoolManager } from "mento-core-2.2.0/interfaces/IBiPoolManager.sol"; -import { IBroker } from "mento-core-2.2.0/interfaces/IBroker.sol"; -import { IERC20Metadata } from "mento-core-2.2.0/common/interfaces/IERC20Metadata.sol"; -import { IRegistry } from "mento-core-2.2.0/common/interfaces/IRegistry.sol"; - -import { IFeeCurrencyWhitelist } from "script/interfaces/IFeeCurrencyWhitelist.sol"; - -import { BiPoolManagerProxy } from "mento-core-2.2.0/proxies/BiPoolManagerProxy.sol"; -import { StableTokenXOFProxy } from "mento-core-2.2.0/legacy/proxies/StableTokenXOFProxy.sol"; -import { StableTokenXOF } from "mento-core-2.2.0/legacy/StableTokenXOF.sol"; -import { Broker } from "mento-core-2.2.0/swap/Broker.sol"; -import { BiPoolManager } from "mento-core-2.2.0/swap/BiPoolManager.sol"; -import { Exchange } from "mento-core-2.2.0/legacy/Exchange.sol"; -import { TradingLimits } from "mento-core-2.2.0/libraries/TradingLimits.sol"; -import { BreakerBox } from "mento-core-2.2.0/oracles/BreakerBox.sol"; -import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; -import { Reserve } from "mento-core-2.2.0/swap/Reserve.sol"; -import { MedianDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/MedianDeltaBreaker.sol"; -import { ValueDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/ValueDeltaBreaker.sol"; -import { ConstantSumPricingModule } from "mento-core-2.2.0/swap/ConstantSumPricingModule.sol"; -import { SafeMath } from "celo-foundry/test/SafeMath.sol"; -import { Proxy } from "mento-core-2.2.0/common/Proxy.sol"; - -import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; - -import { eXOFConfig, Config } from "./Config.sol"; - -/** - * @title IBrokerWithCasts - * @notice Interface for Broker with tuple -> struct casting - * @dev This is used to access the internal trading limits - * config as a struct as opposed to a tuple. - */ -interface IBrokerWithCasts { - function tradingLimitsConfig(bytes32 id) external view returns (TradingLimits.Config memory); -} - -contract eXOFChecks is Script, Test { - using TradingLimits for TradingLimits.Config; - using FixidityLib for FixidityLib.Fraction; - using SafeMath for uint256; +import { Contracts } from "script/utils/Contracts.sol"; - address public celoToken; - address public cUSD; - address public cEUR; - address public cBRL; - address payable public eXOF; - address public bridgedUSDC; - address public bridgedEUROC; - address public governance; - address public medianDeltaBreaker; - address public valueDeltaBreaker; - address public nonrecoverableValueDeltaBreaker; - address public biPoolManager; - address payable sortedOraclesProxy; - address public sortedOracles; - address public constantSum; - address public constantProduct; - address payable biPoolManagerProxy; - address public partialReserve; - address public reserve; - address public broker; - address public breakerBox; +import { eXOFChecksBase } from "./eXOFChecks.base.sol"; +import { eXOFChecksSwap } from "./eXOFChecks.swap.sol"; +import { eXOFChecksVerify } from "./eXOFChecks.verify.sol"; - function setUp() public { - new PrecompileHandler(); // needed for reserve CELO transfer checks - // Load addresses from deployments - contracts.load("MU01-00-Create-Proxies", "latest"); - contracts.load("MU01-01-Create-Nonupgradeable-Contracts", "latest"); - contracts.load("MU03-01-Create-Nonupgradeable-Contracts", "latest"); - contracts.load("MU03-02-Create-Implementations", "latest"); - contracts.load("eXOF-00-Create-Proxies", "latest"); - contracts.load("eXOF-01-Create-Implementations", "latest"); - contracts.load("eXOF-02-Create-Nonupgradeable-Contracts", "latest"); - - // Get proxy addresses - eXOF = contracts.deployed("StableTokenXOFProxy"); - cUSD = contracts.celoRegistry("StableToken"); - cEUR = contracts.celoRegistry("StableTokenEUR"); - cBRL = contracts.celoRegistry("StableTokenBRL"); - partialReserve = contracts.deployed("PartialReserveProxy"); - reserve = contracts.celoRegistry("Reserve"); - celoToken = contracts.celoRegistry("GoldToken"); - broker = contracts.celoRegistry("Broker"); - governance = contracts.celoRegistry("Governance"); - sortedOraclesProxy = address(uint160(contracts.celoRegistry("SortedOracles"))); - - // Get Deployment addresses - bridgedUSDC = contracts.dependency("BridgedUSDC"); - bridgedEUROC = contracts.dependency("BridgedEUROC"); - breakerBox = contracts.deployed("BreakerBox"); - medianDeltaBreaker = contracts.deployed("MedianDeltaBreaker"); - valueDeltaBreaker = contracts.deployed("ValueDeltaBreaker"); - nonrecoverableValueDeltaBreaker = contracts.deployed("NonrecoverableValueDeltaBreaker"); - biPoolManager = contracts.deployed("BiPoolManager"); - constantSum = contracts.deployed("ConstantSumPricingModule"); - constantProduct = contracts.deployed("ConstantProductPricingModule"); - biPoolManagerProxy = contracts.deployed("BiPoolManagerProxy"); - sortedOracles = contracts.deployed("SortedOracles"); - } +contract eXOFChecks is eXOFChecksBase { + using Contracts for Contracts.Cache; function run() public { setUp(); - console.log("\nStarting eXOF checks: \n"); - verifyOwner(); - verifyEXOFStableToken(); - verifyEXOFAddedToRegistry(); - verifyEXOFAddedToReserves(); - verifyEXOFAddedToFeeCurrencyWhitelist(); - verifyExchanges(); - verifyCircuitBreaker(); - } - - function verifyOwner() internal view { - console.log("== Verifying Token Stuff... =="); - - address eXOFImplementation = contracts.deployed("StableTokenXOF"); - require( - StableTokenXOF(eXOFImplementation).owner() == governance, - "StableTokenXOF ownership not transferred to governance" - ); - require( - ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).owner() == governance, - "Nonrecoverable Value Delta Breaker ownership not transferred to governance" - ); - console.log("🟢 Contract ownerships transferred to governance"); - } - - function verifyEXOFStableToken() internal view { - StableTokenXOFProxy stableTokenXOFProxy = StableTokenXOFProxy(eXOF); - address eXOFDeployedImplementation = contracts.deployed("StableTokenXOF"); - - address eXOFImplementation = stableTokenXOFProxy._getImplementation(); - if (eXOFImplementation != eXOFDeployedImplementation) { - console.log( - "The implementation from StableTokenXOFProxy: %s does not match the deployed address: %s.", - eXOFImplementation, - eXOFDeployedImplementation - ); - revert("Deployed StableTokenXOF does not match what proxy points to. See logs."); - } - console.log("🟢 StableTokenXOFProxy has the correct implementation address"); - } - - function verifyEXOFAddedToRegistry() internal view { - address registryEXOFAddress = IRegistry(REGISTRY_ADDRESS).getAddressForStringOrDie("StableTokenXOF"); - address deployedEXOFAddress = contracts.deployed("StableTokenXOFProxy"); - - if (registryEXOFAddress != deployedEXOFAddress) { - console.log( - "The eXOF address from the registry: %s does not match the deployed address: %s.", - registryEXOFAddress, - deployedEXOFAddress - ); - revert("Deployed eXOF does not match what registry points to. See logs."); - } - - console.log("🟢 eXOF has been added to the registry"); - } - - function verifyEXOFAddedToReserves() internal view { - if (!Reserve(address(uint160(partialReserve))).isStableAsset(eXOF)) { - revert("eXOF has not been added to the partial reserve."); - } - - if (!Reserve(address(uint160(reserve))).isStableAsset(eXOF)) { - revert("eXOF has not been added to the reserve."); - } - - console.log("🟢 eXOF has been added to the reserves"); - } - - function verifyEXOFAddedToFeeCurrencyWhitelist() internal view { - address[] memory feeCurrencyWhitelist = IFeeCurrencyWhitelist(contracts.celoRegistry("FeeCurrencyWhitelist")) - .getWhitelist(); - - if (!Arrays.contains(feeCurrencyWhitelist, eXOF)) { - revert("eXOF has not been added to the fee currency whitelist."); - } - - console.log("🟢 eXOF has been added to the fee currency whitelist"); - } - - /* ================================================================ */ - /* =========================== Exchanges ========================== */ - /* ================================================================ */ - - function verifyExchanges() internal { - eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); - - console.log("\n== Verifying exchanges... =="); - - verifyPoolExchange(config); - verifyPoolConfig(config); - verifyTradingLimits(config); - } - - function verifyPoolExchange(eXOFConfig.eXOF memory config) internal view { - bytes32[] memory exchanges = BiPoolManager(biPoolManagerProxy).getExchangeIds(); - - // check configured pools against the config - require( - exchanges.length == config.pools.length + 7, - "Number of expected pools does not match the number of deployed pools." - ); - - for (uint256 i = 0; i < config.pools.length; i++) { - bytes32 exchangeId = getExchangeId(config.pools[i].asset0, config.pools[i].asset1, config.pools[i].isConstantSum); - - IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeId); - Config.Pool memory poolConfig = config.pools[i]; - - // verify asset0 of the deployed pool against the config - if (pool.asset0 != poolConfig.asset0) { - console.log( - "The asset0 of deployed pool: %s does not match the expected asset0: %s.", - pool.asset0, - poolConfig.asset0 - ); - revert("asset0 of pool does not match the expected asset0. See logs."); - } - - // verify asset1 of the deployed pool against the config - if (pool.asset1 != poolConfig.asset1) { - console.log( - "The asset1 of deployed pool: %s does not match the expected asset1: %s.", - pool.asset1, - poolConfig.asset1 - ); - revert("asset1 of pool does not match the expected asset1. See logs."); - } - - if (poolConfig.isConstantSum) { - if (address(pool.pricingModule) != constantSum) { - console.log( - "The pricing module of deployed pool: %s does not match the expected pricing module: %s.", - address(pool.pricingModule), - constantSum - ); - revert("pricing module of pool does not match the expected pricing module. See logs."); - } - } else { - if (address(pool.pricingModule) != constantProduct) { - console.log( - "The pricing module of deployed pool: %s does not match the expected pricing module: %s.", - address(pool.pricingModule), - constantProduct - ); - revert("pricing module of pool does not match the expected pricing module. See logs."); - } - } - // verify asset0 is always a stable asset - require( - pool.asset0 == cUSD || pool.asset0 == cEUR || pool.asset0 == cBRL || pool.asset0 == eXOF, - "asset0 is not a stable asset in the exchange" - ); - // verify asset1 is always a collateral asset - require( - pool.asset1 == celoToken || pool.asset1 == bridgedUSDC || pool.asset1 == bridgedEUROC, - "asset1 is not CELO or bridgedUSDC in the exchange" - ); - } - console.log("🟢 PoolExchange correctly configured 🤘🏼"); - } - - function verifyPoolConfig(eXOFConfig.eXOF memory config) internal view { - for (uint256 i = 0; i < config.pools.length; i++) { - bytes32 exchangeId = getExchangeId(config.pools[i].asset0, config.pools[i].asset1, config.pools[i].isConstantSum); - IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeId); - Config.Pool memory poolConfig = config.pools[i]; - - if (pool.config.spread.unwrap() != poolConfig.spread.unwrap()) { - console.log( - "The spread of deployed pool: %s does not match the expected spread: %s.", - pool.config.spread.unwrap(), - poolConfig.spread.unwrap() - ); - revert("spread of pool does not match the expected spread. See logs."); - } - - if (pool.config.referenceRateFeedID != poolConfig.referenceRateFeedID) { - console.log( - "The referenceRateFeedID of deployed pool: %s does not match the expected referenceRateFeedID: %s.", - pool.config.referenceRateFeedID, - poolConfig.referenceRateFeedID - ); - revert("referenceRateFeedID of pool does not match the expected referenceRateFeedID. See logs."); - } - - if (pool.config.minimumReports != poolConfig.minimumReports) { - console.log( - "The minimumReports of deployed pool: %s does not match the expected minimumReports: %s.", - pool.config.minimumReports, - poolConfig.minimumReports - ); - revert("minimumReports of pool does not match the expected minimumReports. See logs."); - } - - if (pool.config.referenceRateResetFrequency != poolConfig.referenceRateResetFrequency) { - console.log( - "The referenceRateResetFrequency of deployed pool: %s does not match the expected: %s.", - pool.config.referenceRateResetFrequency, - poolConfig.referenceRateResetFrequency - ); - revert( - "referenceRateResetFrequency of pool does not match the expected referenceRateResetFrequency. See logs." - ); - } - - if (pool.config.stablePoolResetSize != poolConfig.stablePoolResetSize) { - console.log( - "The stablePoolResetSize of deployed pool: %s does not match the expected stablePoolResetSize: %s.", - pool.config.stablePoolResetSize, - poolConfig.stablePoolResetSize - ); - revert("stablePoolResetSize of pool does not match the expected stablePoolResetSize. See logs."); - } - } - console.log("🟢 Pool config is correctly configured 🤘🏼"); - } - - function verifyTradingLimits(eXOFConfig.eXOF memory config) internal view { - IBrokerWithCasts _broker = IBrokerWithCasts(address(broker)); - - for (uint256 i = 0; i < config.pools.length; i++) { - bytes32 exchangeId = getExchangeId(config.pools[i].asset0, config.pools[i].asset1, config.pools[i].isConstantSum); - IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeId); - Config.Pool memory poolConfig = config.pools[i]; - - bytes32 limitId = exchangeId ^ bytes32(uint256(uint160(pool.asset0))); - TradingLimits.Config memory limits = _broker.tradingLimitsConfig(limitId); - - // verify configured trading limits for all pools - if (poolConfig.asset0limits.limit0 != limits.limit0) { - console.log("limit0 for %s, %s was not set ❌", pool.asset0, pool.asset1); - revert("Not all trading limits were configured correctly."); - } - if (poolConfig.asset0limits.limit1 != limits.limit1) { - console.log("limit1 for %s, %s was not set ❌", pool.asset0, pool.asset1); - revert("Not all trading limits were configured correctly."); - } - if (poolConfig.asset0limits.limitGlobal != limits.limitGlobal) { - console.log("limitGlobal for %s, %s was not set ❌", pool.asset0, pool.asset1); - revert("Not all trading limits were configured correctly."); - } - if (poolConfig.asset0limits.timeStep0 != limits.timestep0) { - console.log("timestep0 for %s, %s was not set ❌", pool.asset0, pool.asset1); - revert("Not all trading limits were configured correctly."); - } - if (poolConfig.asset0limits.timeStep1 != limits.timestep1) { - console.log("timestep1 for %s, %s was not set ❌", pool.asset0, pool.asset1); - revert("Not all trading limits were configured correctly."); - } - if (Config.tradingLimitConfigToFlag(poolConfig.asset0limits) != limits.flags) { - console.log("flags for %s, %s was not set ❌", pool.asset0, pool.asset1); - revert("Not all trading limits were configured correctly."); - } - } - console.log("🟢 Trading limits set for all exchanges 🔒"); - } - - /* ================================================================ */ - /* ======================== Circuit Breaker ======================= */ - /* ================================================================ */ - - function verifyCircuitBreaker() internal { - eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); - - console.log("\n== Checking circuit breaker... =="); - - verifyBreakerBox(config); - verifyBreakersAreEnabled(config); - verifyMedianDeltaBreaker(config); - verifyValueDeltaBreaker(config); - } - - function verifyBreakerBox(eXOFConfig.eXOF memory config) internal view { - // verify that breakers were set with trading mode 3 - if (BreakerBox(breakerBox).breakerTradingMode(nonrecoverableValueDeltaBreaker) != 3) { - console.log("The Nonrecoverable ValueDeltaBreaker was not set with trading halted ❌"); - revert("Nonrecoverable ValueDeltaBreaker was not set with trading halted"); - } - console.log("🟢 Nonrecoverable ValueDeltaBreaker set with trading mode 3"); - - // verify that rate feed dependencies were configured correctly - address EUROCXOFDependency = BreakerBox(breakerBox).rateFeedDependencies(config.EUROXOF.rateFeedID, 0); - require( - EUROCXOFDependency == config.EUROXOF.dependentRateFeeds[0], - "EUROC/XOF rate feed dependency not set correctly" - ); - console.log("🟢 Rate feed dependencies configured correctly 🗳️"); - } - - function verifyBreakersAreEnabled(eXOFConfig.eXOF memory config) internal view { - // verify that MedianDeltaBreaker && ValueDeltaBreakers were enabled for rateFeeds - for (uint256 i = 0; i < config.rateFeeds.length; i++) { - Config.RateFeed memory rateFeed = config.rateFeeds[i]; - - if (rateFeed.medianDeltaBreaker0.enabled) { - bool medianDeltaEnabled = BreakerBox(breakerBox).isBreakerEnabled(medianDeltaBreaker, rateFeed.rateFeedID); - if (!medianDeltaEnabled) { - console.log("MedianDeltaBreaker not enabled for rate feed %s", rateFeed.rateFeedID); - revert("MedianDeltaBreaker not enabled for all rate feeds"); - } - - if (rateFeed.valueDeltaBreaker0.enabled) { - bool valueDeltaEnabled = BreakerBox(breakerBox).isBreakerEnabled(valueDeltaBreaker, rateFeed.rateFeedID); - if (!valueDeltaEnabled) { - console.log("ValueDeltaBreaker not enabled for rate feed %s", rateFeed.rateFeedID); - revert("ValueDeltaBreaker not enabled for all rate feeds"); - } - } - - if (rateFeed.valueDeltaBreaker1.enabled) { - bool nonrecoverableValueDeltaEnabled = BreakerBox(breakerBox).isBreakerEnabled( - nonrecoverableValueDeltaBreaker, - rateFeed.rateFeedID - ); - if (!nonrecoverableValueDeltaEnabled) { - console.log("Nonrecoverable ValueDeltaBreaker not enabled for rate feed %s", rateFeed.rateFeedID); - revert("Nonrecoverable ValueDeltaBreaker not enabled for all rate feeds"); - } - } - } - } - console.log("🟢 Breakers enabled for all rate feeds 🗳️"); - } - - function verifyMedianDeltaBreaker(eXOFConfig.eXOF memory config) internal view { - // verify that cooldown period, rate change threshold and smoothing factor were set correctly - for (uint256 i = 0; i < config.rateFeeds.length; i++) { - Config.RateFeed memory rateFeed = config.rateFeeds[i]; - - if (rateFeed.medianDeltaBreaker0.enabled) { - uint256 cooldown = MedianDeltaBreaker(medianDeltaBreaker).rateFeedCooldownTime(rateFeed.rateFeedID); - uint256 rateChangeThreshold = MedianDeltaBreaker(medianDeltaBreaker).rateChangeThreshold(rateFeed.rateFeedID); - uint256 smoothingFactor = MedianDeltaBreaker(medianDeltaBreaker).smoothingFactors(rateFeed.rateFeedID); - - // verify cooldown period - verifyCooldownTime(cooldown, rateFeed.medianDeltaBreaker0.cooldown, rateFeed.rateFeedID, false); - - // verify rate change threshold - verifyRateChangeTheshold( - rateChangeThreshold, - rateFeed.medianDeltaBreaker0.threshold.unwrap(), - rateFeed.rateFeedID, - false - ); - - // verify smoothing factor - if (smoothingFactor != rateFeed.medianDeltaBreaker0.smoothingFactor) { - console.log( - "MedianDeltaBreaker smoothing factor not set correctly for the rate feed: %s", - rateFeed.rateFeedID - ); - revert("MedianDeltaBreaker smoothing factor not set correctly for all rate feeds"); - } - } - } - console.log("🟢 MedianDeltaBreaker cooldown, rate change threshold and smoothing factor set correctly 🔒"); - } - - function verifyValueDeltaBreaker(eXOFConfig.eXOF memory config) internal view { - // verify that cooldown period, rate change threshold and reference value were set correctly - for (uint256 i = 0; i < config.rateFeeds.length; i++) { - Config.RateFeed memory rateFeed = config.rateFeeds[i]; - - if (rateFeed.valueDeltaBreaker0.enabled) { - uint256 cooldown = ValueDeltaBreaker(valueDeltaBreaker).rateFeedCooldownTime(rateFeed.rateFeedID); - uint256 rateChangeThreshold = ValueDeltaBreaker(valueDeltaBreaker).rateChangeThreshold(rateFeed.rateFeedID); - uint256 referenceValue = ValueDeltaBreaker(valueDeltaBreaker).referenceValues(rateFeed.rateFeedID); - - // verify cooldown period - verifyCooldownTime(cooldown, rateFeed.valueDeltaBreaker0.cooldown, rateFeed.rateFeedID, true); - - // verify rate change threshold - verifyRateChangeTheshold( - rateChangeThreshold, - rateFeed.valueDeltaBreaker0.threshold.unwrap(), - rateFeed.rateFeedID, - true - ); - - // verify refernece value - if (referenceValue != rateFeed.valueDeltaBreaker0.referenceValue) { - console.log("ValueDeltaBreaker reference value not set correctly for the rate feed: %s", rateFeed.rateFeedID); - revert("ValueDeltaBreaker reference values not set correctly for all rate feeds"); - } - } - } - console.log("🟢 ValueDeltaBreaker cooldown, rate change threshold and reference value set correctly 🔒 \n"); - } - - function verifyNonrecoverableValueDeltaBreaker(eXOFConfig.eXOF memory config) internal view { - // verify that cooldown period, rate change threshold and reference value were set correctly - for (uint256 i = 0; i < config.rateFeeds.length; i++) { - Config.RateFeed memory rateFeed = config.rateFeeds[i]; - - if (rateFeed.valueDeltaBreaker1.enabled) { - uint256 cooldown = ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).rateFeedCooldownTime(rateFeed.rateFeedID); - uint256 rateChangeThreshold = ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).rateChangeThreshold( - rateFeed.rateFeedID - ); - uint256 referenceValue = ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).referenceValues( - rateFeed.rateFeedID - ); - - // verify cooldown period - verifyCooldownTime(cooldown, rateFeed.valueDeltaBreaker1.cooldown, rateFeed.rateFeedID, true); - - // verify rate change threshold - verifyRateChangeTheshold( - rateChangeThreshold, - rateFeed.valueDeltaBreaker1.threshold.unwrap(), - rateFeed.rateFeedID, - true - ); - - // verify refernece value - if (referenceValue != rateFeed.valueDeltaBreaker1.referenceValue) { - console.log( - "Nonrecoverable ValueDeltaBreaker reference value not set correctly for the rate feed: %s", - rateFeed.rateFeedID - ); - revert("Nonrecoverable ValueDeltaBreaker reference values not set correctly for all rate feeds"); - } - } - } - console.log( - "\tNonrecoverable ValueDeltaBreaker cooldown, rate change threshold and reference value set correctly 🔒" - ); - } - - // /* ================================================================ */ - // /* ============================= Swaps ============================ */ - // /* ================================================================ */ - function doSwaps() internal { - eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); - - console.log("\n== Doing some test swaps... =="); - - swapCeloToEXOF(config); - swapEXOFtoCelo(config); - swapBridgedEUROCtoEXOF(config); - swapEXOFtoBridgedEUROC(config); - } - - function swapCeloToEXOF(eXOFConfig.eXOF memory config) internal { - bytes32 exchangeID = getExchangeId(config.eXOFCelo.asset0, config.eXOFCelo.asset1, config.eXOFCelo.isConstantSum); - - address trader = vm.addr(5); - address tokenIn = celoToken; - address tokenOut = eXOF; - uint256 amountIn = 100e18; - - // Give trader some celo - vm.deal(trader, amountIn); - - testAndPerformConstantProductSwap(exchangeID, trader, tokenIn, tokenOut, amountIn); - - console.log("\tCELO -> eXOF swap successful 🚀"); - } - - function swapEXOFtoCelo(eXOFConfig.eXOF memory config) internal { - bytes32 exchangeID = getExchangeId(config.eXOFCelo.asset0, config.eXOFCelo.asset1, config.eXOFCelo.isConstantSum); - - address trader = vm.addr(5); - address tokenIn = eXOF; - address tokenOut = celoToken; - uint256 amountIn = 100e18; - - testAndPerformConstantProductSwap(exchangeID, trader, tokenIn, tokenOut, amountIn); - - console.log("\teXOF -> CELO swap successful 🚀"); - } - - function swapBridgedEUROCtoEXOF(eXOFConfig.eXOF memory config) internal { - bytes32 exchangeID = getExchangeId( - config.eXOFEUROC.asset0, - config.eXOFEUROC.asset1, - config.eXOFEUROC.isConstantSum - ); - - address trader = vm.addr(4); - address tokenIn = bridgedEUROC; - address tokenOut = eXOF; - uint256 amountIn = 10e6; - - // Mint some EUROC to trader - deal(bridgedUSDC, trader, amountIn, true); - - testAndPerformConstantSumSwap( - exchangeID, - trader, - tokenIn, - tokenOut, - amountIn, - config.eXOFEUROC.referenceRateFeedID, - true - ); - - console.log("\tbridgedEUROC -> eXOF swap successful 🚀"); - } - - function swapEXOFtoBridgedEUROC(eXOFConfig.eXOF memory config) internal { - bytes32 exchangeID = getExchangeId( - config.eXOFEUROC.asset0, - config.eXOFEUROC.asset1, - config.eXOFEUROC.isConstantSum - ); - - address trader = vm.addr(4); - address tokenIn = eXOF; - address tokenOut = bridgedEUROC; - uint256 amountIn = 100e18; - - testAndPerformConstantSumSwap( - exchangeID, - trader, - tokenIn, - tokenOut, - amountIn, - config.eXOFEUROC.referenceRateFeedID, - false - ); - - console.log("\teXOF -> bridgedEUROC swap successful 🚀"); - } - - // /* ================================================================ */ - // /* ============================ Helpers =========================== */ - // /* ================================================================ */ - - function verifyRateChangeTheshold( - uint256 currentThreshold, - uint256 expectedThreshold, - address rateFeedID, - bool isValueDeltaBreaker - ) internal view { - if (currentThreshold != expectedThreshold) { - if (isValueDeltaBreaker) { - console.log("ValueDeltaBreaker rate change threshold not set correctly for USDC/USD rate feed %s", rateFeedID); - revert("ValueDeltaBreaker rate change threshold not set correctly for USDC/USD rate feed"); - } - console.log("MedianDeltaBreaker rate change threshold not set correctly for rate feed %s", rateFeedID); - revert("MedianDeltaBreaker rate change threshold not set correctly for all rate feeds"); - } - } - - function verifyCooldownTime( - uint256 currentCoolDown, - uint256 expectedCoolDown, - address rateFeedID, - bool isValueDeltaBreaker - ) internal view { - if (currentCoolDown != expectedCoolDown) { - if (isValueDeltaBreaker) { - console.log("ValueDeltaBreaker cooldown not set correctly for USDC/USD rate feed %s", rateFeedID); - revert("ValueDeltaBreaker cooldown not set correctly for USDC/USD rate feed"); - } - console.log("MedianDeltaBreaker cooldown not set correctly for rate feed %s", rateFeedID); - revert("MedianDeltaBreaker cooldown not set correctly for all rate feeds"); - } - } - - function testAndPerformConstantProductSwap( - bytes32 exchangeID, - address trader, - address tokenIn, - address tokenOut, - uint256 amountIn - ) internal { - uint256 amountOut = Broker(broker).getAmountOut(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn); - IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeID); - - FixidityLib.Fraction memory numerator; - FixidityLib.Fraction memory denominator; - - if (tokenIn == pool.asset0) { - numerator = FixidityLib.newFixed(amountIn).multiply(FixidityLib.newFixed(pool.bucket1)); - denominator = FixidityLib.newFixed(pool.bucket0).add(FixidityLib.newFixed(amountIn)); - } else { - numerator = FixidityLib.newFixed(amountIn).multiply(FixidityLib.newFixed(pool.bucket0)); - denominator = FixidityLib.newFixed(pool.bucket1).add(FixidityLib.newFixed(amountIn)); - } - - uint256 estimatedAmountOut = numerator.unwrap().div(denominator.unwrap()); - - FixidityLib.Fraction memory maxTolerance = FixidityLib.newFixedFraction(25, 10000); - uint256 threshold = FixidityLib.newFixed(estimatedAmountOut).multiply(maxTolerance).fromFixed(); - assertApproxEqAbs(amountOut, estimatedAmountOut, threshold); - - doSwapIn(exchangeID, trader, tokenIn, tokenOut, amountIn, amountOut); - } - - function testAndPerformConstantSumSwap( - bytes32 exchangeID, - address trader, - address tokenIn, - address tokenOut, - uint256 amountIn, - address rateFeedID, - bool isBridgedUsdcToStable - ) internal { - uint256 amountOut = Broker(broker).getAmountOut(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn); - (uint256 numerator, uint256 denominator) = SortedOracles(sortedOraclesProxy).medianRate(rateFeedID); - uint256 estimatedAmountOut; - - if (isBridgedUsdcToStable) { - estimatedAmountOut = FixidityLib - .newFixed(amountIn.mul(1e12)) - .multiply(FixidityLib.wrap(numerator).divide(FixidityLib.wrap(denominator))) - .fromFixed(); - } else { - estimatedAmountOut = FixidityLib - .newFixed(amountIn) - .multiply(FixidityLib.wrap(denominator).divide(FixidityLib.wrap(numerator))) - .fromFixed(); - estimatedAmountOut = estimatedAmountOut.div(1e12); - } - - FixidityLib.Fraction memory maxTolerance = FixidityLib.newFixedFraction(25, 1000); - uint256 threshold = FixidityLib.newFixed(estimatedAmountOut).multiply(maxTolerance).fromFixed(); - assertApproxEqAbs(amountOut, estimatedAmountOut, threshold); - - doSwapIn(exchangeID, trader, tokenIn, tokenOut, amountIn, amountOut); - } - - function doSwapIn( - bytes32 exchangeID, - address trader, - address tokenIn, - address tokenOut, - uint256 amountIn, - uint256 amountOut - ) internal { - uint256 beforeBuyingTokenOut = IERC20(tokenOut).balanceOf(trader); - uint256 beforeSellingTokenIn = IERC20(tokenIn).balanceOf(trader); - - vm.startPrank(trader); - IERC20(tokenIn).approve(address(broker), amountIn); - Broker(broker).swapIn(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn, amountOut); - assertEq(IERC20(tokenOut).balanceOf(trader), beforeBuyingTokenOut + amountOut); - assertEq(IERC20(tokenIn).balanceOf(trader), beforeSellingTokenIn - amountIn); - vm.stopPrank(); - } - /** - * @notice Helper function to get the exchange ID for a pool. - */ - function getExchangeId(address asset0, address asset1, bool isConstantSum) internal view returns (bytes32) { - return - keccak256( - abi.encodePacked( - IERC20Metadata(asset0).symbol(), - IERC20Metadata(asset1).symbol(), - isConstantSum ? "ConstantSum" : "ConstantProduct" - ) - ); + // new eXOFChecksVerify().run(); + new eXOFChecksSwap().run(); } } diff --git a/script/upgrades/eXOF/eXOFChecks.swap.sol b/script/upgrades/eXOF/eXOFChecks.swap.sol new file mode 100644 index 00000000..ac64e03b --- /dev/null +++ b/script/upgrades/eXOF/eXOFChecks.swap.sol @@ -0,0 +1,243 @@ +// SPDX-License-Identifier: GPL-3.0-or-later +pragma solidity ^0.5.13; +pragma experimental ABIEncoderV2; + +import { console2 as console } from "forge-std/Script.sol"; + +import { PrecompileHandler } from "celo-foundry/PrecompileHandler.sol"; + +import { Contracts } from "script/utils/Contracts.sol"; + +import { IERC20 } from "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol"; + +import { FixidityLib } from "mento-core-2.2.0/common/FixidityLib.sol"; + +import { Broker } from "mento-core-2.2.0/swap/Broker.sol"; +import { IBiPoolManager } from "mento-core-2.2.0/interfaces/IBiPoolManager.sol"; +import { BiPoolManager } from "mento-core-2.2.0/swap/BiPoolManager.sol"; +import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; + +import { eXOFChecksBase } from "./eXOFChecks.base.sol"; +import { eXOFConfig, Config } from "./Config.sol"; + +contract eXOFChecksSwap is eXOFChecksBase { + using FixidityLib for FixidityLib.Fraction; + using Contracts for Contracts.Cache; + + struct DoSwapInArgs { + bytes32 exchangeID; + address trader; + address tokenIn; + address tokenOut; + uint256 amountIn; + uint256 amountOut; + } + + constructor() public { + new PrecompileHandler(); + setUp(); + } + + function run() public { + eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); + + console.log("\n== Starting eXOF test swaps: =="); + + swapCeloToEXOF(config); + swapEXOFtoCelo(config); + swapBridgedEUROCtoEXOF(config); + swapEXOFtoBridgedEUROC(config); + } + + // *** Swap Checks *** // + + function swapCeloToEXOF(eXOFConfig.eXOF memory config) internal { + bytes32 exchangeID = getExchangeId(config.eXOFCelo.asset0, config.eXOFCelo.asset1, config.eXOFCelo.isConstantSum); + address trader = vm.addr(5); + address tokenIn = celoToken; + address tokenOut = eXOF; + uint256 amountIn = 100e18; + + // Give trader some celo + vm.deal(trader, amountIn); + + testAndPerformConstantProductSwap( + exchangeID, + trader, + tokenIn, + tokenOut, + amountIn, + config.eXOFCelo.referenceRateFeedID + ); + + console.log("🟢 CELO -> eXOF swap successful 🚀"); + } + + function swapEXOFtoCelo(eXOFConfig.eXOF memory config) internal { + bytes32 exchangeID = getExchangeId(config.eXOFCelo.asset0, config.eXOFCelo.asset1, config.eXOFCelo.isConstantSum); + address trader = vm.addr(5); + address tokenIn = eXOF; + address tokenOut = celoToken; + uint256 amountIn = 100e18; + + testAndPerformConstantProductSwap( + exchangeID, + trader, + tokenIn, + tokenOut, + amountIn, + config.eXOFCelo.referenceRateFeedID + ); + + console.log("🟢 eXOF -> CELO swap successful 🚀"); + } + + function swapBridgedEUROCtoEXOF(eXOFConfig.eXOF memory config) internal { + bytes32 exchangeID = getExchangeId( + config.eXOFEUROC.asset0, + config.eXOFEUROC.asset1, + config.eXOFEUROC.isConstantSum + ); + + address trader = vm.addr(4); + address tokenIn = bridgedEUROC; + address tokenOut = eXOF; + uint256 amountIn = 10e6; + + // TODO: Mint some EUROC to trader + // Mint some EUROC to trader + deal(bridgedUSDC, trader, amountIn, true); + + testAndPerformConstantSumSwap( + exchangeID, + trader, + tokenIn, + tokenOut, + amountIn, + config.eXOFEUROC.referenceRateFeedID, + true + ); + + console.log("🟢 bridgedEUROC -> eXOF swap successful 🚀"); + } + + function swapEXOFtoBridgedEUROC(eXOFConfig.eXOF memory config) internal { + bytes32 exchangeID = getExchangeId( + config.eXOFEUROC.asset0, + config.eXOFEUROC.asset1, + config.eXOFEUROC.isConstantSum + ); + + address trader = vm.addr(4); + address tokenIn = eXOF; + address tokenOut = bridgedEUROC; + uint256 amountIn = 100e18; + + testAndPerformConstantSumSwap( + exchangeID, + trader, + tokenIn, + tokenOut, + amountIn, + config.eXOFEUROC.referenceRateFeedID, + false + ); + + console.log("\teXOF -> bridgedEUROC swap successful 🚀"); + } + + // *** Helper Functions *** // + + function testAndPerformConstantProductSwap( + bytes32 exchangeID, + address trader, + address tokenIn, + address tokenOut, + uint256 amountIn, + address rateFeedID + ) internal { + uint256 amountOut = Broker(broker).getAmountOut(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn); + IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeID); + + (uint256 numerator, uint256 denominator) = SortedOracles(sortedOraclesProxy).medianRate(rateFeedID); + FixidityLib.Fraction memory rate = FixidityLib.newFixedFraction(numerator, denominator); + + FixidityLib.Fraction memory amountInAfterSpread = FixidityLib.newFixed(amountIn).multiply( + FixidityLib.newFixedFraction(9950, 10000) + ); + + uint256 estimatedAmountOut; + if (tokenIn == pool.asset0) { + estimatedAmountOut = amountInAfterSpread.divide(rate).fromFixed(); + } else { + estimatedAmountOut = amountInAfterSpread.multiply(rate).fromFixed(); + } + + FixidityLib.Fraction memory maxTolerance = FixidityLib.newFixedFraction(25, 1000); + uint256 threshold = FixidityLib.newFixed(estimatedAmountOut).multiply(maxTolerance).fromFixed(); + + assertApproxEq(amountOut, estimatedAmountOut, threshold); + doSwapIn(exchangeID, trader, tokenIn, tokenOut, amountIn, amountOut); + } + + function testAndPerformConstantSumSwap( + bytes32 exchangeID, + address trader, + address tokenIn, + address tokenOut, + uint256 amountIn, + address rateFeedID, + bool isBridgedUsdcToStable + ) internal { + uint256 amountOut = Broker(broker).getAmountOut(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn); + (uint256 numerator, uint256 denominator) = SortedOracles(sortedOraclesProxy).medianRate(rateFeedID); + uint256 estimatedAmountOut; + + if (isBridgedUsdcToStable) { + estimatedAmountOut = FixidityLib + .newFixed(amountIn.mul(1e12)) + .multiply(FixidityLib.wrap(numerator).divide(FixidityLib.wrap(denominator))) + .fromFixed(); + } else { + estimatedAmountOut = FixidityLib + .newFixed(amountIn) + .multiply(FixidityLib.wrap(denominator).divide(FixidityLib.wrap(numerator))) + .fromFixed(); + estimatedAmountOut = estimatedAmountOut.div(1e12); + } + + FixidityLib.Fraction memory maxTolerance = FixidityLib.newFixedFraction(25, 1000); + uint256 threshold = FixidityLib.newFixed(estimatedAmountOut).multiply(maxTolerance).fromFixed(); + assertApproxEq(amountOut, estimatedAmountOut, threshold); + doSwapIn(exchangeID, trader, tokenIn, tokenOut, amountIn, amountOut); + } + + function doSwapIn( + bytes32 exchangeID, + address trader, + address tokenIn, + address tokenOut, + uint256 amountIn, + uint256 amountOut + ) internal { + uint256 beforeBuyingTokenOut = IERC20(tokenOut).balanceOf(trader); + uint256 beforeSellingTokenIn = IERC20(tokenIn).balanceOf(trader); + + vm.startPrank(trader); + IERC20(tokenIn).approve(address(broker), amountIn); + Broker(broker).swapIn(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn, amountOut); + assertEq(IERC20(tokenOut).balanceOf(trader), beforeBuyingTokenOut + amountOut); + assertEq(IERC20(tokenIn).balanceOf(trader), beforeSellingTokenIn - amountIn); + vm.stopPrank(); + } + + function assertApproxEq(uint256 a, uint256 b, uint256 maxDelta) internal view { + uint256 delta = a > b ? a - b : b - a; + + if (delta > maxDelta) { + console.log("Diff(%s) between amounts is greater than %s", delta, maxDelta); + } + + require(delta <= maxDelta, "Values are not approximately equal. See logs for more information."); + } +} diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol new file mode 100644 index 00000000..6c7cac87 --- /dev/null +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -0,0 +1,504 @@ +// SPDX-License-Identifier: GPL-3.0-or-later +pragma solidity ^0.5.13; +pragma experimental ABIEncoderV2; + +import { console2 as console } from "forge-std/Script.sol"; + +import { Arrays } from "script/utils/Arrays.sol"; + +import { IFeeCurrencyWhitelist } from "script/interfaces/IFeeCurrencyWhitelist.sol"; + +import { IRegistry } from "mento-core-2.2.0/common/interfaces/IRegistry.sol"; +import { IBiPoolManager } from "mento-core-2.2.0/interfaces/IBiPoolManager.sol"; +import { IERC20Metadata } from "mento-core-2.2.0/common/interfaces/IERC20Metadata.sol"; + +import { StableTokenXOF } from "mento-core-2.2.0/legacy/StableTokenXOF.sol"; +import { StableTokenXOFProxy } from "mento-core-2.2.0/legacy/proxies/StableTokenXOFProxy.sol"; +import { MedianDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/MedianDeltaBreaker.sol"; +import { ValueDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/ValueDeltaBreaker.sol"; +import { Reserve } from "mento-core-2.2.0/swap/Reserve.sol"; +import { BiPoolManager } from "mento-core-2.2.0/swap/BiPoolManager.sol"; +import { TradingLimits } from "mento-core-2.2.0/libraries/TradingLimits.sol"; +import { BreakerBox } from "mento-core-2.2.0/oracles/BreakerBox.sol"; + +import { eXOFChecksBase } from "./eXOFChecks.base.sol"; +import { eXOFConfig, Config } from "./Config.sol"; + +/** + * @title IBrokerWithCasts + * @notice Interface for Broker with tuple -> struct casting + * @dev This is used to access the internal trading limits + * config as a struct as opposed to a tuple. + */ +interface IBrokerWithCasts { + function tradingLimitsConfig(bytes32 id) external view returns (TradingLimits.Config memory); +} + +contract eXOFChecksVerify is eXOFChecksBase { + using TradingLimits for TradingLimits.Config; + + constructor() public { + setUp(); + } + + function run() public { + console.log("\nStarting eXOF checks:"); + + verifyOwner(); + verifyEXOFStableToken(); + verifyEXOFAddedToRegistry(); + verifyEXOFAddedToReserves(); + verifyEXOFAddedToFeeCurrencyWhitelist(); + verifyExchanges(); + verifyCircuitBreaker(); + } + + function verifyOwner() internal view { + console.log("\n== Verifying Token Stuff =="); + + address eXOFImplementation = contracts.deployed("StableTokenXOF"); + require( + StableTokenXOF(eXOFImplementation).owner() == governance, + "StableTokenXOF ownership not transferred to governance" + ); + require( + ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).owner() == governance, + "Nonrecoverable Value Delta Breaker ownership not transferred to governance" + ); + console.log("🟢 Contract ownerships transferred to governance"); + } + + function verifyEXOFStableToken() internal view { + StableTokenXOFProxy stableTokenXOFProxy = StableTokenXOFProxy(eXOF); + address eXOFDeployedImplementation = contracts.deployed("StableTokenXOF"); + + address eXOFImplementation = stableTokenXOFProxy._getImplementation(); + if (eXOFImplementation != eXOFDeployedImplementation) { + console.log( + "The implementation from StableTokenXOFProxy: %s does not match the deployed address: %s.", + eXOFImplementation, + eXOFDeployedImplementation + ); + revert("Deployed StableTokenXOF does not match what proxy points to. See logs."); + } + console.log("🟢 StableTokenXOFProxy has the correct implementation address"); + } + + function verifyEXOFAddedToRegistry() internal view { + address registryEXOFAddress = IRegistry(REGISTRY_ADDRESS).getAddressForStringOrDie("StableTokenXOF"); + address deployedEXOFAddress = contracts.deployed("StableTokenXOFProxy"); + + if (registryEXOFAddress != deployedEXOFAddress) { + console.log( + "The eXOF address from the registry: %s does not match the deployed address: %s.", + registryEXOFAddress, + deployedEXOFAddress + ); + revert("Deployed eXOF does not match what registry points to. See logs."); + } + + console.log("🟢 eXOF has been added to the registry"); + } + + function verifyEXOFAddedToReserves() internal view { + if (!Reserve(address(uint160(partialReserve))).isStableAsset(eXOF)) { + revert("eXOF has not been added to the partial reserve."); + } + + if (!Reserve(address(uint160(reserve))).isStableAsset(eXOF)) { + revert("eXOF has not been added to the reserve."); + } + + console.log("🟢 eXOF has been added to the reserves"); + } + + function verifyEXOFAddedToFeeCurrencyWhitelist() internal view { + address[] memory feeCurrencyWhitelist = IFeeCurrencyWhitelist(contracts.celoRegistry("FeeCurrencyWhitelist")) + .getWhitelist(); + + if (!Arrays.contains(feeCurrencyWhitelist, eXOF)) { + revert("eXOF has not been added to the fee currency whitelist."); + } + + console.log("🟢 eXOF has been added to the fee currency whitelist"); + } + + function verifyExchanges() internal { + eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); + + console.log("\n== Verifying exchanges =="); + + verifyPoolExchange(config); + verifyPoolConfig(config); + verifyTradingLimits(config); + } + + function verifyPoolExchange(eXOFConfig.eXOF memory config) internal view { + bytes32[] memory exchanges = BiPoolManager(biPoolManagerProxy).getExchangeIds(); + + // check configured pools against the config + require( + exchanges.length == config.pools.length + 7, + "Number of expected pools does not match the number of deployed pools." + ); + + for (uint256 i = 0; i < config.pools.length; i++) { + bytes32 exchangeId = getExchangeId(config.pools[i].asset0, config.pools[i].asset1, config.pools[i].isConstantSum); + + IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeId); + Config.Pool memory poolConfig = config.pools[i]; + + // verify asset0 of the deployed pool against the config + if (pool.asset0 != poolConfig.asset0) { + console.log( + "The asset0 of deployed pool: %s does not match the expected asset0: %s.", + pool.asset0, + poolConfig.asset0 + ); + revert("asset0 of pool does not match the expected asset0. See logs."); + } + + // verify asset1 of the deployed pool against the config + if (pool.asset1 != poolConfig.asset1) { + console.log( + "The asset1 of deployed pool: %s does not match the expected asset1: %s.", + pool.asset1, + poolConfig.asset1 + ); + revert("asset1 of pool does not match the expected asset1. See logs."); + } + + if (poolConfig.isConstantSum) { + if (address(pool.pricingModule) != constantSum) { + console.log( + "The pricing module of deployed pool: %s does not match the expected pricing module: %s.", + address(pool.pricingModule), + constantSum + ); + revert("pricing module of pool does not match the expected pricing module. See logs."); + } + } else { + if (address(pool.pricingModule) != constantProduct) { + console.log( + "The pricing module of deployed pool: %s does not match the expected pricing module: %s.", + address(pool.pricingModule), + constantProduct + ); + revert("pricing module of pool does not match the expected pricing module. See logs."); + } + } + // verify asset0 is always a stable asset + require( + pool.asset0 == cUSD || pool.asset0 == cEUR || pool.asset0 == cBRL || pool.asset0 == eXOF, + "asset0 is not a stable asset in the exchange" + ); + // verify asset1 is always a collateral asset + require( + pool.asset1 == celoToken || pool.asset1 == bridgedUSDC || pool.asset1 == bridgedEUROC, + "asset1 is not CELO or bridgedUSDC in the exchange" + ); + } + console.log("🟢 PoolExchange correctly configured 🤘🏼"); + } + + function verifyPoolConfig(eXOFConfig.eXOF memory config) internal view { + for (uint256 i = 0; i < config.pools.length; i++) { + bytes32 exchangeId = getExchangeId(config.pools[i].asset0, config.pools[i].asset1, config.pools[i].isConstantSum); + IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeId); + Config.Pool memory poolConfig = config.pools[i]; + + if (pool.config.spread.unwrap() != poolConfig.spread.unwrap()) { + console.log( + "The spread of deployed pool: %s does not match the expected spread: %s.", + pool.config.spread.unwrap(), + poolConfig.spread.unwrap() + ); + revert("spread of pool does not match the expected spread. See logs."); + } + + if (pool.config.referenceRateFeedID != poolConfig.referenceRateFeedID) { + console.log( + "The referenceRateFeedID of deployed pool: %s does not match the expected referenceRateFeedID: %s.", + pool.config.referenceRateFeedID, + poolConfig.referenceRateFeedID + ); + revert("referenceRateFeedID of pool does not match the expected referenceRateFeedID. See logs."); + } + + if (pool.config.minimumReports != poolConfig.minimumReports) { + console.log( + "The minimumReports of deployed pool: %s does not match the expected minimumReports: %s.", + pool.config.minimumReports, + poolConfig.minimumReports + ); + revert("minimumReports of pool does not match the expected minimumReports. See logs."); + } + + if (pool.config.referenceRateResetFrequency != poolConfig.referenceRateResetFrequency) { + console.log( + "The referenceRateResetFrequency of deployed pool: %s does not match the expected: %s.", + pool.config.referenceRateResetFrequency, + poolConfig.referenceRateResetFrequency + ); + revert( + "referenceRateResetFrequency of pool does not match the expected referenceRateResetFrequency. See logs." + ); + } + + if (pool.config.stablePoolResetSize != poolConfig.stablePoolResetSize) { + console.log( + "The stablePoolResetSize of deployed pool: %s does not match the expected stablePoolResetSize: %s.", + pool.config.stablePoolResetSize, + poolConfig.stablePoolResetSize + ); + revert("stablePoolResetSize of pool does not match the expected stablePoolResetSize. See logs."); + } + } + console.log("🟢 Pool config is correctly configured 🤘🏼"); + } + + function verifyTradingLimits(eXOFConfig.eXOF memory config) internal view { + IBrokerWithCasts _broker = IBrokerWithCasts(address(broker)); + + for (uint256 i = 0; i < config.pools.length; i++) { + bytes32 exchangeId = getExchangeId(config.pools[i].asset0, config.pools[i].asset1, config.pools[i].isConstantSum); + IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeId); + Config.Pool memory poolConfig = config.pools[i]; + + bytes32 limitId = exchangeId ^ bytes32(uint256(uint160(pool.asset0))); + TradingLimits.Config memory limits = _broker.tradingLimitsConfig(limitId); + + // verify configured trading limits for all pools + if (poolConfig.asset0limits.limit0 != limits.limit0) { + console.log("limit0 for %s, %s was not set ❌", pool.asset0, pool.asset1); + revert("Not all trading limits were configured correctly."); + } + if (poolConfig.asset0limits.limit1 != limits.limit1) { + console.log("limit1 for %s, %s was not set ❌", pool.asset0, pool.asset1); + revert("Not all trading limits were configured correctly."); + } + if (poolConfig.asset0limits.limitGlobal != limits.limitGlobal) { + console.log("limitGlobal for %s, %s was not set ❌", pool.asset0, pool.asset1); + revert("Not all trading limits were configured correctly."); + } + if (poolConfig.asset0limits.timeStep0 != limits.timestep0) { + console.log("timestep0 for %s, %s was not set ❌", pool.asset0, pool.asset1); + revert("Not all trading limits were configured correctly."); + } + if (poolConfig.asset0limits.timeStep1 != limits.timestep1) { + console.log("timestep1 for %s, %s was not set ❌", pool.asset0, pool.asset1); + revert("Not all trading limits were configured correctly."); + } + if (Config.tradingLimitConfigToFlag(poolConfig.asset0limits) != limits.flags) { + console.log("flags for %s, %s was not set ❌", pool.asset0, pool.asset1); + revert("Not all trading limits were configured correctly."); + } + } + console.log("🟢 Trading limits set for all exchanges 🔒"); + } + + /* ================================================================ */ + /* ======================== Circuit Breaker ======================= */ + /* ================================================================ */ + + function verifyCircuitBreaker() internal { + eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); + + console.log("\n== Checking circuit breaker =="); + + verifyBreakerBox(config); + verifyBreakersAreEnabled(config); + verifyMedianDeltaBreaker(config); + verifyValueDeltaBreaker(config); + verifyNonrecoverableValueDeltaBreaker(config); + } + + function verifyBreakerBox(eXOFConfig.eXOF memory config) internal view { + // verify that breakers were set with trading mode 3 + if (BreakerBox(breakerBox).breakerTradingMode(nonrecoverableValueDeltaBreaker) != 3) { + console.log("The Nonrecoverable ValueDeltaBreaker was not set with trading halted ❌"); + revert("Nonrecoverable ValueDeltaBreaker was not set with trading halted"); + } + console.log("🟢 Nonrecoverable ValueDeltaBreaker set with trading mode 3"); + + // verify that rate feed dependencies were configured correctly + address EUROCXOFDependency = BreakerBox(breakerBox).rateFeedDependencies(config.EUROXOF.rateFeedID, 0); + require( + EUROCXOFDependency == config.EUROXOF.dependentRateFeeds[0], + "EUROC/XOF rate feed dependency not set correctly" + ); + console.log("🟢 Rate feed dependencies configured correctly 🗳️"); + } + + function verifyBreakersAreEnabled(eXOFConfig.eXOF memory config) internal view { + // verify that MedianDeltaBreaker && ValueDeltaBreakers were enabled for rateFeeds + for (uint256 i = 0; i < config.rateFeeds.length; i++) { + Config.RateFeed memory rateFeed = config.rateFeeds[i]; + + if (rateFeed.medianDeltaBreaker0.enabled) { + bool medianDeltaEnabled = BreakerBox(breakerBox).isBreakerEnabled(medianDeltaBreaker, rateFeed.rateFeedID); + if (!medianDeltaEnabled) { + console.log("MedianDeltaBreaker not enabled for rate feed %s", rateFeed.rateFeedID); + revert("MedianDeltaBreaker not enabled for all rate feeds"); + } + + if (rateFeed.valueDeltaBreaker0.enabled) { + bool valueDeltaEnabled = BreakerBox(breakerBox).isBreakerEnabled(valueDeltaBreaker, rateFeed.rateFeedID); + if (!valueDeltaEnabled) { + console.log("ValueDeltaBreaker not enabled for rate feed %s", rateFeed.rateFeedID); + revert("ValueDeltaBreaker not enabled for all rate feeds"); + } + } + + if (rateFeed.valueDeltaBreaker1.enabled) { + bool nonrecoverableValueDeltaEnabled = BreakerBox(breakerBox).isBreakerEnabled( + nonrecoverableValueDeltaBreaker, + rateFeed.rateFeedID + ); + if (!nonrecoverableValueDeltaEnabled) { + console.log("Nonrecoverable ValueDeltaBreaker not enabled for rate feed %s", rateFeed.rateFeedID); + revert("Nonrecoverable ValueDeltaBreaker not enabled for all rate feeds"); + } + } + } + } + console.log("🟢 Breakers enabled for all rate feeds 🗳️"); + } + + function verifyMedianDeltaBreaker(eXOFConfig.eXOF memory config) internal view { + // verify that cooldown period, rate change threshold and smoothing factor were set correctly + for (uint256 i = 0; i < config.rateFeeds.length; i++) { + Config.RateFeed memory rateFeed = config.rateFeeds[i]; + + if (rateFeed.medianDeltaBreaker0.enabled) { + uint256 cooldown = MedianDeltaBreaker(medianDeltaBreaker).rateFeedCooldownTime(rateFeed.rateFeedID); + uint256 rateChangeThreshold = MedianDeltaBreaker(medianDeltaBreaker).rateChangeThreshold(rateFeed.rateFeedID); + uint256 smoothingFactor = MedianDeltaBreaker(medianDeltaBreaker).smoothingFactors(rateFeed.rateFeedID); + + // verify cooldown period + verifyCooldownTime(cooldown, rateFeed.medianDeltaBreaker0.cooldown, rateFeed.rateFeedID, false); + + // verify rate change threshold + verifyRateChangeTheshold( + rateChangeThreshold, + rateFeed.medianDeltaBreaker0.threshold.unwrap(), + rateFeed.rateFeedID, + false + ); + + // verify smoothing factor + if (smoothingFactor != rateFeed.medianDeltaBreaker0.smoothingFactor) { + console.log( + "MedianDeltaBreaker smoothing factor not set correctly for the rate feed: %s", + rateFeed.rateFeedID + ); + revert("MedianDeltaBreaker smoothing factor not set correctly for all rate feeds"); + } + } + } + console.log("🟢 MedianDeltaBreaker cooldown, rate change threshold and smoothing factor set correctly 🔒"); + } + + function verifyValueDeltaBreaker(eXOFConfig.eXOF memory config) internal view { + // verify that cooldown period, rate change threshold and reference value were set correctly + for (uint256 i = 0; i < config.rateFeeds.length; i++) { + Config.RateFeed memory rateFeed = config.rateFeeds[i]; + + if (rateFeed.valueDeltaBreaker0.enabled) { + uint256 cooldown = ValueDeltaBreaker(valueDeltaBreaker).rateFeedCooldownTime(rateFeed.rateFeedID); + uint256 rateChangeThreshold = ValueDeltaBreaker(valueDeltaBreaker).rateChangeThreshold(rateFeed.rateFeedID); + uint256 referenceValue = ValueDeltaBreaker(valueDeltaBreaker).referenceValues(rateFeed.rateFeedID); + + // verify cooldown period + verifyCooldownTime(cooldown, rateFeed.valueDeltaBreaker0.cooldown, rateFeed.rateFeedID, true); + + // verify rate change threshold + verifyRateChangeTheshold( + rateChangeThreshold, + rateFeed.valueDeltaBreaker0.threshold.unwrap(), + rateFeed.rateFeedID, + true + ); + + // verify refernece value + if (referenceValue != rateFeed.valueDeltaBreaker0.referenceValue) { + console.log("ValueDeltaBreaker reference value not set correctly for the rate feed: %s", rateFeed.rateFeedID); + revert("ValueDeltaBreaker reference values not set correctly for all rate feeds"); + } + } + } + console.log("🟢 ValueDeltaBreaker cooldown, rate change threshold and reference value set correctly 🔒"); + } + + function verifyNonrecoverableValueDeltaBreaker(eXOFConfig.eXOF memory config) internal view { + // verify that cooldown period, rate change threshold and reference value were set correctly + for (uint256 i = 0; i < config.rateFeeds.length; i++) { + Config.RateFeed memory rateFeed = config.rateFeeds[i]; + + if (rateFeed.valueDeltaBreaker1.enabled) { + uint256 cooldown = ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).rateFeedCooldownTime(rateFeed.rateFeedID); + uint256 rateChangeThreshold = ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).rateChangeThreshold( + rateFeed.rateFeedID + ); + uint256 referenceValue = ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).referenceValues( + rateFeed.rateFeedID + ); + + // verify cooldown period + verifyCooldownTime(cooldown, rateFeed.valueDeltaBreaker1.cooldown, rateFeed.rateFeedID, true); + + // verify rate change threshold + verifyRateChangeTheshold( + rateChangeThreshold, + rateFeed.valueDeltaBreaker1.threshold.unwrap(), + rateFeed.rateFeedID, + true + ); + + // verify refernece value + if (referenceValue != rateFeed.valueDeltaBreaker1.referenceValue) { + console.log( + "Nonrecoverable ValueDeltaBreaker reference value not set correctly for the rate feed: %s", + rateFeed.rateFeedID + ); + revert("Nonrecoverable ValueDeltaBreaker reference values not set correctly for all rate feeds"); + } + } + } + console.log( + "🟢 Nonrecoverable ValueDeltaBreaker cooldown, rate change threshold and reference value set correctly 🔒" + ); + } + + function verifyRateChangeTheshold( + uint256 currentThreshold, + uint256 expectedThreshold, + address rateFeedID, + bool isValueDeltaBreaker + ) internal view { + if (currentThreshold != expectedThreshold) { + if (isValueDeltaBreaker) { + console.log("ValueDeltaBreaker rate change threshold not set correctly for USDC/USD rate feed %s", rateFeedID); + revert("ValueDeltaBreaker rate change threshold not set correctly for USDC/USD rate feed"); + } + console.log("MedianDeltaBreaker rate change threshold not set correctly for rate feed %s", rateFeedID); + revert("MedianDeltaBreaker rate change threshold not set correctly for all rate feeds"); + } + } + + function verifyCooldownTime( + uint256 currentCoolDown, + uint256 expectedCoolDown, + address rateFeedID, + bool isValueDeltaBreaker + ) internal view { + if (currentCoolDown != expectedCoolDown) { + if (isValueDeltaBreaker) { + console.log("ValueDeltaBreaker cooldown not set correctly for USDC/USD rate feed %s", rateFeedID); + revert("ValueDeltaBreaker cooldown not set correctly for USDC/USD rate feed"); + } + console.log("MedianDeltaBreaker cooldown not set correctly for rate feed %s", rateFeedID); + revert("MedianDeltaBreaker cooldown not set correctly for all rate feeds"); + } + } +} From 4a21bd4f5e358de88e770808216102dc5a6de658 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Tue, 29 Aug 2023 11:51:48 -0500 Subject: [PATCH 22/64] =?UTF-8?q?refactor:=20mint=20correct=20token=20for?= =?UTF-8?q?=20test=20=F0=9F=99=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- script/upgrades/eXOF/eXOFChecks.sol | 2 +- script/upgrades/eXOF/eXOFChecks.swap.sol | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/script/upgrades/eXOF/eXOFChecks.sol b/script/upgrades/eXOF/eXOFChecks.sol index 3d7daf34..24267900 100644 --- a/script/upgrades/eXOF/eXOFChecks.sol +++ b/script/upgrades/eXOF/eXOFChecks.sol @@ -16,7 +16,7 @@ contract eXOFChecks is eXOFChecksBase { function run() public { setUp(); - // new eXOFChecksVerify().run(); + new eXOFChecksVerify().run(); new eXOFChecksSwap().run(); } } diff --git a/script/upgrades/eXOF/eXOFChecks.swap.sol b/script/upgrades/eXOF/eXOFChecks.swap.sol index ac64e03b..8e6ea841 100644 --- a/script/upgrades/eXOF/eXOFChecks.swap.sol +++ b/script/upgrades/eXOF/eXOFChecks.swap.sol @@ -104,9 +104,8 @@ contract eXOFChecksSwap is eXOFChecksBase { address tokenOut = eXOF; uint256 amountIn = 10e6; - // TODO: Mint some EUROC to trader // Mint some EUROC to trader - deal(bridgedUSDC, trader, amountIn, true); + deal(tokenIn, trader, amountIn); testAndPerformConstantSumSwap( exchangeID, @@ -143,7 +142,7 @@ contract eXOFChecksSwap is eXOFChecksBase { false ); - console.log("\teXOF -> bridgedEUROC swap successful 🚀"); + console.log("🟢 eXOF -> bridgedEUROC swap successful 🚀"); } // *** Helper Functions *** // From 5fc83da8d89571bfb0ead927be1c2e16f7fe0fe6 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Tue, 29 Aug 2023 12:05:34 -0500 Subject: [PATCH 23/64] Squashed commit of the following: commit f085cf89ac96e9e72ee152c4e52d13ac2458290d Author: philbow61 <80156619+philbow61@users.noreply.github.com> Date: Fri Aug 25 14:33:21 2023 +0200 fix: remove unnecessary Value Delta Breaker transactions (#106) commit c9d0f1a2801e1d80a03c0ecbdef6bb19fe42f01b Author: philbow61 <80156619+philbow61@users.noreply.github.com> Date: Fri Aug 25 14:29:35 2023 +0200 feat: set spending ratio for EUROC (#107) commit bc218a229e3591e1515e0f24e4f446a46d88c523 Author: philbow61 <80156619+philbow61@users.noreply.github.com> Date: Thu Aug 24 10:11:34 2023 +0200 fix: add missing breaker box update in bpm (#105) Co-authored-by: Nelson Taveras commit b396ea6f3fae2e482543928cf74e664632e23485 Author: philbow61 <80156619+philbow61@users.noreply.github.com> Date: Mon Aug 21 15:57:09 2023 +0200 Fix/mu03 exchange destruction (#104) commit 5f7e87c4a349f0a864528cb0ad208f0637389566 Author: philbow61 <80156619+philbow61@users.noreply.github.com> Date: Wed Aug 16 15:43:22 2023 +0200 feat: MU03 Governance Script post audit changes (#102) --- script/upgrades/MU03/MU03.sol | 51 ++++++++++++++++++----------- script/upgrades/MU03/MU03Checks.sol | 5 +++ 2 files changed, 37 insertions(+), 19 deletions(-) diff --git a/script/upgrades/MU03/MU03.sol b/script/upgrades/MU03/MU03.sol index aba0a8f8..f03a2614 100644 --- a/script/upgrades/MU03/MU03.sol +++ b/script/upgrades/MU03/MU03.sol @@ -26,6 +26,7 @@ import { BreakerBox } from "mento-core-2.2.0/oracles/BreakerBox.sol"; import { MedianDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/MedianDeltaBreaker.sol"; import { ValueDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/ValueDeltaBreaker.sol"; import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; +import { Reserve } from "mento-core-2.2.0/swap/Reserve.sol"; import { MU03Config, Config } from "./Config.sol"; import { IMentoUpgrade, ICeloGovernance } from "script/interfaces/IMentoUpgrade.sol"; @@ -53,7 +54,7 @@ contract MU03 is IMentoUpgrade, GovernanceScript { address payable private biPoolManagerProxyAddress; address private brokerProxyAddress; address private sortedOraclesProxy; - address private partialReserveProxy; + address payable private partialReserveProxy; // Helper mapping to store the exchange IDs for the reference rate feeds mapping(address => bytes32) private referenceRateFeedIDToExchangeId; @@ -92,7 +93,7 @@ contract MU03 is IMentoUpgrade, GovernanceScript { biPoolManagerProxyAddress = address(uint160(contracts.deployed("BiPoolManagerProxy"))); brokerProxyAddress = contracts.deployed("BrokerProxy"); sortedOraclesProxy = contracts.celoRegistry("SortedOracles"); - partialReserveProxy = contracts.deployed("PartialReserveProxy"); + partialReserveProxy = address(uint160(contracts.deployed("PartialReserveProxy"))); } /** @@ -146,12 +147,30 @@ contract MU03 is IMentoUpgrade, GovernanceScript { function proposal_addEUROCToPartialReserve() private { // addCollateralAsset will throw if it's already added - if (IReserve(partialReserveProxy).isCollateralAsset(bridgedEUROC) == false) { + if (Reserve(partialReserveProxy).isCollateralAsset(bridgedEUROC) == false) { transactions.push( ICeloGovernance.Transaction( 0, partialReserveProxy, - abi.encodeWithSelector(IReserve(0).addCollateralAsset.selector, bridgedEUROC) + abi.encodeWithSelector(Reserve(0).addCollateralAsset.selector, bridgedEUROC) + ) + ); + } + + // set EUROC daily spending ratio to 100% + if ( + Reserve(partialReserveProxy).getDailySpendingRatioForCollateralAsset(bridgedEUROC) != + FixidityLib.fixed1().unwrap() + ) { + transactions.push( + ICeloGovernance.Transaction( + 0, + partialReserveProxy, + abi.encodeWithSelector( + Reserve(0).setDailySpendingRatioForCollateralAssets.selector, + Arrays.addresses(bridgedEUROC), + Arrays.uints(FixidityLib.fixed1().unwrap()) + ) ) ); } @@ -499,47 +518,41 @@ contract MU03 is IMentoUpgrade, GovernanceScript { } function proposal_configureValueDeltaBreaker0(MU03Config.MU03 memory config) public { - // Set reference value for USDC/USD, EUROC/EUR rate Feed + // Set reference value for EUROC/EUR rate feed transactions.push( ICeloGovernance.Transaction( 0, valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setReferenceValues.selector, - Arrays.addresses(config.USDCUSD.rateFeedID, config.EUROCEUR.rateFeedID), - Arrays.uints( - config.USDCUSD.valueDeltaBreaker0.referenceValue, - config.EUROCEUR.valueDeltaBreaker0.referenceValue - ) + Arrays.addresses(config.EUROCEUR.rateFeedID), + Arrays.uints(config.EUROCEUR.valueDeltaBreaker0.referenceValue) ) ) ); - // Set cooldown time for USDC/USD, EUROC/EUR rate Feeds + // Set cooldown time for EUROC/EUR rate feed transactions.push( ICeloGovernance.Transaction( 0, valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setCooldownTimes.selector, - Arrays.addresses(config.USDCUSD.rateFeedID, config.EUROCEUR.rateFeedID), - Arrays.uints(config.USDCUSD.valueDeltaBreaker0.cooldown, config.EUROCEUR.valueDeltaBreaker0.cooldown) + Arrays.addresses(config.EUROCEUR.rateFeedID), + Arrays.uints(config.EUROCEUR.valueDeltaBreaker0.cooldown) ) ) ); - /// Set rate change thresholds for USDC/USD, EUROC/EUR rate Feeds + /// Set rate change threshold for EUROC/EUR rate feed transactions.push( ICeloGovernance.Transaction( 0, valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setRateChangeThresholds.selector, - Arrays.addresses(config.USDCUSD.rateFeedID, config.EUROCEUR.rateFeedID), - Arrays.uints( - config.USDCUSD.valueDeltaBreaker0.threshold.unwrap(), - config.EUROCEUR.valueDeltaBreaker0.threshold.unwrap() - ) + Arrays.addresses(config.EUROCEUR.rateFeedID), + Arrays.uints(config.EUROCEUR.valueDeltaBreaker0.threshold.unwrap()) ) ) ); diff --git a/script/upgrades/MU03/MU03Checks.sol b/script/upgrades/MU03/MU03Checks.sol index 71eadea6..ace05109 100644 --- a/script/upgrades/MU03/MU03Checks.sol +++ b/script/upgrades/MU03/MU03Checks.sol @@ -144,6 +144,11 @@ contract MU03Checks is Script, Test { console2.log("EUROC is not a collateral asset 🏦"); revert("EUROC is not a collateral asset"); } + if (partialReserve.getDailySpendingRatioForCollateralAsset(bridgedEUROC) != FixidityLib.fixed1().unwrap()) { + revert("EUROC daily spending ratio not set correctly"); + } else { + console2.log("EUROC daily spending ratio set correctly 🏦"); + } } function verifyBiPoolManager() internal view { From d14455d3d3ec5e0e95fb3acab66ccb1a0878733b Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Tue, 29 Aug 2023 12:38:02 -0500 Subject: [PATCH 24/64] docs: add eXOF proposal md file --- script/upgrades/eXOF/eXOF.md | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 script/upgrades/eXOF/eXOF.md diff --git a/script/upgrades/eXOF/eXOF.md b/script/upgrades/eXOF/eXOF.md new file mode 100644 index 00000000..e69de29b From 954746628ebc50efbc7854258df67847501f83aa Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Tue, 29 Aug 2023 12:54:13 -0500 Subject: [PATCH 25/64] chore: remove mento core reference --- lib/mento-core | 1 - 1 file changed, 1 deletion(-) delete mode 160000 lib/mento-core diff --git a/lib/mento-core b/lib/mento-core deleted file mode 160000 index aee81629..00000000 --- a/lib/mento-core +++ /dev/null @@ -1 +0,0 @@ -Subproject commit aee816290ac9395b528094455360e8e130eedb5f From 70d24489a30ae09cb8bde957ce1a87f3b66368dd Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Tue, 29 Aug 2023 16:59:15 -0500 Subject: [PATCH 26/64] docs: add proposal description --- script/upgrades/eXOF/eXOF.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/script/upgrades/eXOF/eXOF.md b/script/upgrades/eXOF/eXOF.md index e69de29b..c943c6ce 100644 --- a/script/upgrades/eXOF/eXOF.md +++ b/script/upgrades/eXOF/eXOF.md @@ -0,0 +1,12 @@ +### eXOF + +Release v2.2.0 and change trading limits. + +Summary: + +- Creates new stable token - eXOF +- Creates new non recoverable valueDeltaBreaker for EUR/XOF rate feed +- Adds eXOF as stable token in reserve contracts +- Enables gas payments with eXOF +- Creates new eXOF/CELO & eXOF/axlEUROC pools +- Configure trading limits & breaker box for new rate feeds From 887ae604521f709535ba8f7b6e2809bed7dc3f7f Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Tue, 29 Aug 2023 18:07:21 -0500 Subject: [PATCH 27/64] refactor: remove unused struct --- script/upgrades/eXOF/eXOF.md | 2 +- script/upgrades/eXOF/eXOFChecks.swap.sol | 9 --------- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/script/upgrades/eXOF/eXOF.md b/script/upgrades/eXOF/eXOF.md index c943c6ce..60c91aab 100644 --- a/script/upgrades/eXOF/eXOF.md +++ b/script/upgrades/eXOF/eXOF.md @@ -1,6 +1,6 @@ ### eXOF -Release v2.2.0 and change trading limits. +eXOF deployment and governance proposal. Summary: diff --git a/script/upgrades/eXOF/eXOFChecks.swap.sol b/script/upgrades/eXOF/eXOFChecks.swap.sol index 8e6ea841..eaacc1db 100644 --- a/script/upgrades/eXOF/eXOFChecks.swap.sol +++ b/script/upgrades/eXOF/eXOFChecks.swap.sol @@ -24,15 +24,6 @@ contract eXOFChecksSwap is eXOFChecksBase { using FixidityLib for FixidityLib.Fraction; using Contracts for Contracts.Cache; - struct DoSwapInArgs { - bytes32 exchangeID; - address trader; - address tokenIn; - address tokenOut; - uint256 amountIn; - uint256 amountOut; - } - constructor() public { new PrecompileHandler(); setUp(); From 0b8b7db3fd2e6e9342766649902772005793291b Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Wed, 30 Aug 2023 11:53:19 -0500 Subject: [PATCH 28/64] chore: add mainnet euroc address --- script/upgrades/dependencies.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/upgrades/dependencies.json b/script/upgrades/dependencies.json index e255aef4..b96676ba 100644 --- a/script/upgrades/dependencies.json +++ b/script/upgrades/dependencies.json @@ -1,7 +1,7 @@ { "42220": { "BridgedUSDC": "0xEB466342C4d449BC9f53A865D5Cb90586f405215", - "BridgedEUROC": "Address not yet accessible", + "BridgedEUROC": "0xEB466342C4d449BC9f53A865D5Cb90586f405215", "USDCUSDRateFeedAddr": "0xA1A8003936862E7a15092A91898D69fa8bCE290c", "USDCEURRateFeedAddr": "0x206B25Ea01E188Ee243131aFdE526bA6E131a016", "USDCBRLRateFeedAddr": "0x25F21A1f97607Edf6852339fad709728cffb9a9d", From ee6cd12c85485fb917790c61c65f18d9ecb1a185 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Wed, 30 Aug 2023 11:57:41 -0500 Subject: [PATCH 29/64] refactor: remove old deployment references --- .../44787/run-1692783898.json | 64 ------- .../44787/run-1692783905.json | 180 ------------------ .../44787/run-1692783955.json | 180 ------------------ .../62320/run-1692821205.json | 64 ------- .../62320/run-1692821211.json | 180 ------------------ .../62320/run-1692821216.json | 180 ------------------ 6 files changed, 848 deletions(-) delete mode 100644 broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783898.json delete mode 100644 broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783905.json delete mode 100644 broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783955.json delete mode 100644 broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821205.json delete mode 100644 broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821211.json delete mode 100644 broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821216.json diff --git a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783898.json b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783898.json deleted file mode 100644 index 937973c6..00000000 --- a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783898.json +++ /dev/null @@ -1,64 +0,0 @@ -{ - "transactions": [ - { - "hash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionType": "CREATE", - "contractName": "NonrecoverableValueDeltaBreaker", - "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "function": null, - "arguments": [ - "0", - "0", - "0xFdd8bD58115FfBf04e47411c1d228eCC45E93075", - "[]", - "[]", - "[]" - ], - "transaction": { - "type": "0x00", - "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "gas": "0x1f2d9a", - "value": "0x0", - "data": "0x60806040523480156200001157600080fd5b506040516200242b3803806200242b833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b5050505090500160405250505085858585858560006200020d620002d660201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620023ea833981519152908290a3506200025e336001600160e01b03620002da16565b62000272846001600160e01b036200036c16565b62000286866001600160e01b036200046c16565b6200029a856001600160e01b03620004a716565b620002af83836001600160e01b036200058516565b620002c483826001600160e01b03620007d316565b505050505050505050505050620009fd565b3390565b6001600160a01b038116620003215760405162461bcd60e51b8152600401808060200182810382526026815260200180620023c46026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620023ea83398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b6200037f6001600160e01b036200097016565b620003d1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b81526004018080602001828103825260218152602001806200240a6021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004bd81620009a160201b620017ea1760201c565b51600255620004fd620004db620009bd602090811b620015a217901c565b6040805160208082019092526002548152919062001804620009e3821b17901c565b6200054f576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005dc576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200060157fe5b60200260200101516001600160a01b031614156200065a576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000664620009ea565b6200068e8383815181106200067557fe5b6020026020010151620009a160201b620017ea1760201c565b9050620006be620006a9620009bd60201b620015a21760201c565b82620009e360201b620018041790919060201c565b62000710576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200072257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200078557fe5b60200260200101518484815181106200079a57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005df565b505050565b80518251146200082a576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200084f57fe5b60200260200101516001600160a01b03161415620008a8576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008b557fe5b602002602001015160016000858481518110620008ce57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200092857fe5b60200260200101518383815181106200093d57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a16001016200082d565b6004546000906001600160a01b0316620009926001600160e01b03620002d616565b6001600160a01b031614905090565b620009ab620009ea565b50604080516020810190915290815290565b620009c7620009ea565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b6119b78062000a0d6000396000f3fe608060405234801561001057600080fd5b506004361061016c5760003560e01c806368b89d58116100cd5780638f32d59b11610081578063e829902e11610066578063e829902e14610521578063f2fde38b146105e3578063fd165f53146106165761016c565b80638f32d59b14610511578063a44235cb146105195761016c565b8063715018a6116100b2578063715018a6146104c2578063753d8c2f146104ca5780638da5cb5b146105095761016c565b806368b89d58146103b95780636cac543a146104005761016c565b80633932bcc3116101245780634afb215e116101095780634afb215e1461033657806353f5d6f1146103695780635ac3ff701461039c5761016c565b80633932bcc3146102d057806339b84ecf146103035761016c565b8063132e8aa711610155578063132e8aa7146102525780631893304f146102835780632e37ff73146102c85761016c565b8063020323dd1461017157806305e0478514610235575b600080fd5b6102336004803603604081101561018757600080fd5b8101906020810181356401000000008111156101a257600080fd5b8201836020820111156101b457600080fd5b803590602001918460208302840111640100000000831117156101d657600080fd5b9193909290916020810190356401000000008111156101f457600080fd5b82018360208201111561020657600080fd5b8035906020019184602083028401116401000000008311171561022857600080fd5b509092509050610649565b005b6102336004803603602081101561024b57600080fd5b5035610715565b61025a61077a565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6102b66004803603602081101561029957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610796565b60408051918252519081900360200190f35b6102b66107a8565b6102b6600480360360208110156102e657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107ae565b6102b66004803603602081101561031957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107c0565b6102336004803603602081101561034c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107fd565b6102b66004803603602081101561037f57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610921565b610233600480360360208110156103b257600080fd5b5035610933565b6103ec600480360360208110156103cf57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610995565b604080519115158252519081900360200190f35b6102336004803603604081101561041657600080fd5b81019060208101813564010000000081111561043157600080fd5b82018360208201111561044357600080fd5b8035906020019184602083028401116401000000008311171561046557600080fd5b91939092909160208101903564010000000081111561048357600080fd5b82018360208201111561049557600080fd5b803590602001918460208302840111640100000000831117156104b757600080fd5b5090925090506109a7565b610233610a6d565b6103ec600480360360608110156104e057600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610b35565b61025a610c47565b6103ec610c63565b6102b6610ca3565b6102336004803603604081101561053757600080fd5b81019060208101813564010000000081111561055257600080fd5b82018360208201111561056457600080fd5b8035906020019184602083028401116401000000008311171561058657600080fd5b9193909290916020810190356401000000008111156105a457600080fd5b8201836020820111156105b657600080fd5b803590602001918460208302840111640100000000831117156105d857600080fd5b509092509050610ca9565b610233600480360360208110156105f957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f0e565b6103ec6004803603602081101561062c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f70565b610651610c63565b6106a2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f8484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061105b92505050565b50505050565b61071d610c63565b61076e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610777816112c7565b50565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b60036020526000908152604090205481565b60005481565b60066020526000908152604090205481565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260016020526040812054806107f55750506000546107f8565b90505b919050565b610805610c63565b610856576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166108a85760405162461bcd60e51b81526004018080602001828103825260218152602001806119626021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60016020526000908152604090205481565b61093b610c63565b61098c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077781611382565b60006109a082610f70565b1592915050565b6109af610c63565b610a00576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113bd92505050565b610a75610c63565b610ac6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610b539061159e565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610b939061159e565b90508015610b9f578091505b6000610bb1610bac6115a2565b61159e565b90506000610bc5828563ffffffff6115c616565b90506000610bf369d3c21bcecceda1000000610be78b8563ffffffff61162916565b9063ffffffff61168216565b90506000610c07848763ffffffff6116c416565b90506000610c2969d3c21bcecceda1000000610be78d8563ffffffff61162916565b9050808a1080610c385750828a115b9b9a5050505050505050505050565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610c87611706565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610cb1610c63565b610d02576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b828114610d56576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b83811015610f07576000858583818110610d6f57fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610df5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b828282818110610e0157fe5b9050602002013560066000878785818110610e1857fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fa62a59cb391b90466127d5c2ae9c7cfb59877763680d974867d6abe0c4fd52cb858583818110610ea057fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff16848484818110610ec957fe5b6040805173ffffffffffffffffffffffffffffffffffffffff90951685526020918202939093013590840152508051918290030190a1600101610d59565b5050505050565b610f16610c63565b610f67576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107778161170a565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610fe357600080fd5b505afa158015610ff7573d6000803e3d6000fd5b505050506040513d604081101561100d57600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526006602052604090205490915080611048576000925050506107f8565b611053818386610b35565b949350505050565b80518251146110b1576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff168382815181106110e157fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415611152576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b61115a611907565b61117683838151811061116957fe5b60200260200101516117ea565b90506111906111836115a2565b829063ffffffff61180416565b6111e1576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111f257fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061126e57fe5b602002602001015184848151811061128257fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110b4565b505050565b6112d0816117ea565b516002556112fb6112df6115a2565b604080516020810190915260025481529063ffffffff61180416565b61134c576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b8051825114611413576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff1683828151811061144357fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114b4576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114c057fe5b6020026020010151600160008584815181106114d857fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061154b57fe5b602002602001015183838151811061155f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611416565b5190565b6115aa611907565b50604080516020810190915269d3c21bcecceda1000000815290565b600082820183811015611620576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b60008261163857506000611623565b8282028284828161164557fe5b04146116205760405162461bcd60e51b81526004018080602001828103825260218152602001806119416021913960400191505060405180910390fd5b600061162083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061180b565b600061162083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506118ad565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661175c5760405162461bcd60e51b815260040180806020018281038252602681526020018061191b6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6117f2611907565b50604080516020810190915290815290565b5190511090565b600081836118975760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561185c578181015183820152602001611844565b50505050905090810190601f1680156118895780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816118a357fe5b0495945050505050565b600081848411156118ff5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561185c578181015183820152602001611844565b505050900390565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a7231582011765acba939a6b32e46cb228259748701b284c59dfd4ac49f1e8f56ca5fb53864736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d7573742062652073657400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000fdd8bd58115ffbf04e47411c1d228ecc45e9307500000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "nonce": "0xde" - }, - "additionalContracts": [], - "isFixedGasLimit": false - }, - { - "hash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", - "transactionType": "CALL", - "contractName": "NonrecoverableValueDeltaBreaker", - "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "function": "transferOwnership(address)", - "arguments": [ - "0xAA963FC97281d9632d96700aB62A4D1340F9a28a" - ], - "transaction": { - "type": "0x00", - "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "to": "0x69d7a21025d45d301a396cceffd2d3a80b7c3a5b", - "gas": "0xa387", - "value": "0x0", - "data": "0xf2fde38b000000000000000000000000aa963fc97281d9632d96700ab62a4d1340f9a28a", - "nonce": "0xdf" - }, - "additionalContracts": [], - "isFixedGasLimit": false - } - ], - "receipts": [], - "libraries": [ - "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x2F0F7686fFFEfc3C266403Ad600035581deaedff", - "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0x29B1B5e05217c751038861aF2C77494EAB10A257" - ], - "pending": [ - "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6" - ], - "returns": {}, - "timestamp": 1692783898, - "chain": 44787, - "multi": false, - "commit": "1071d75" -} \ No newline at end of file diff --git a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783905.json b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783905.json deleted file mode 100644 index f4a44398..00000000 --- a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783905.json +++ /dev/null @@ -1,180 +0,0 @@ -{ - "transactions": [ - { - "hash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionType": "CREATE", - "contractName": "NonrecoverableValueDeltaBreaker", - "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "function": null, - "arguments": [ - "0", - "0", - "0xFdd8bD58115FfBf04e47411c1d228eCC45E93075", - "[]", - "[]", - "[]" - ], - "transaction": { - "type": "0x00", - "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "gas": "0x1f2d9a", - "value": "0x0", - "data": "0x60806040523480156200001157600080fd5b506040516200242b3803806200242b833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b5050505090500160405250505085858585858560006200020d620002d660201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620023ea833981519152908290a3506200025e336001600160e01b03620002da16565b62000272846001600160e01b036200036c16565b62000286866001600160e01b036200046c16565b6200029a856001600160e01b03620004a716565b620002af83836001600160e01b036200058516565b620002c483826001600160e01b03620007d316565b505050505050505050505050620009fd565b3390565b6001600160a01b038116620003215760405162461bcd60e51b8152600401808060200182810382526026815260200180620023c46026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620023ea83398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b6200037f6001600160e01b036200097016565b620003d1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b81526004018080602001828103825260218152602001806200240a6021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004bd81620009a160201b620017ea1760201c565b51600255620004fd620004db620009bd602090811b620015a217901c565b6040805160208082019092526002548152919062001804620009e3821b17901c565b6200054f576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005dc576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200060157fe5b60200260200101516001600160a01b031614156200065a576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000664620009ea565b6200068e8383815181106200067557fe5b6020026020010151620009a160201b620017ea1760201c565b9050620006be620006a9620009bd60201b620015a21760201c565b82620009e360201b620018041790919060201c565b62000710576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200072257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200078557fe5b60200260200101518484815181106200079a57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005df565b505050565b80518251146200082a576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200084f57fe5b60200260200101516001600160a01b03161415620008a8576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008b557fe5b602002602001015160016000858481518110620008ce57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200092857fe5b60200260200101518383815181106200093d57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a16001016200082d565b6004546000906001600160a01b0316620009926001600160e01b03620002d616565b6001600160a01b031614905090565b620009ab620009ea565b50604080516020810190915290815290565b620009c7620009ea565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b6119b78062000a0d6000396000f3fe608060405234801561001057600080fd5b506004361061016c5760003560e01c806368b89d58116100cd5780638f32d59b11610081578063e829902e11610066578063e829902e14610521578063f2fde38b146105e3578063fd165f53146106165761016c565b80638f32d59b14610511578063a44235cb146105195761016c565b8063715018a6116100b2578063715018a6146104c2578063753d8c2f146104ca5780638da5cb5b146105095761016c565b806368b89d58146103b95780636cac543a146104005761016c565b80633932bcc3116101245780634afb215e116101095780634afb215e1461033657806353f5d6f1146103695780635ac3ff701461039c5761016c565b80633932bcc3146102d057806339b84ecf146103035761016c565b8063132e8aa711610155578063132e8aa7146102525780631893304f146102835780632e37ff73146102c85761016c565b8063020323dd1461017157806305e0478514610235575b600080fd5b6102336004803603604081101561018757600080fd5b8101906020810181356401000000008111156101a257600080fd5b8201836020820111156101b457600080fd5b803590602001918460208302840111640100000000831117156101d657600080fd5b9193909290916020810190356401000000008111156101f457600080fd5b82018360208201111561020657600080fd5b8035906020019184602083028401116401000000008311171561022857600080fd5b509092509050610649565b005b6102336004803603602081101561024b57600080fd5b5035610715565b61025a61077a565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6102b66004803603602081101561029957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610796565b60408051918252519081900360200190f35b6102b66107a8565b6102b6600480360360208110156102e657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107ae565b6102b66004803603602081101561031957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107c0565b6102336004803603602081101561034c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107fd565b6102b66004803603602081101561037f57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610921565b610233600480360360208110156103b257600080fd5b5035610933565b6103ec600480360360208110156103cf57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610995565b604080519115158252519081900360200190f35b6102336004803603604081101561041657600080fd5b81019060208101813564010000000081111561043157600080fd5b82018360208201111561044357600080fd5b8035906020019184602083028401116401000000008311171561046557600080fd5b91939092909160208101903564010000000081111561048357600080fd5b82018360208201111561049557600080fd5b803590602001918460208302840111640100000000831117156104b757600080fd5b5090925090506109a7565b610233610a6d565b6103ec600480360360608110156104e057600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610b35565b61025a610c47565b6103ec610c63565b6102b6610ca3565b6102336004803603604081101561053757600080fd5b81019060208101813564010000000081111561055257600080fd5b82018360208201111561056457600080fd5b8035906020019184602083028401116401000000008311171561058657600080fd5b9193909290916020810190356401000000008111156105a457600080fd5b8201836020820111156105b657600080fd5b803590602001918460208302840111640100000000831117156105d857600080fd5b509092509050610ca9565b610233600480360360208110156105f957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f0e565b6103ec6004803603602081101561062c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f70565b610651610c63565b6106a2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f8484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061105b92505050565b50505050565b61071d610c63565b61076e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610777816112c7565b50565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b60036020526000908152604090205481565b60005481565b60066020526000908152604090205481565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260016020526040812054806107f55750506000546107f8565b90505b919050565b610805610c63565b610856576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166108a85760405162461bcd60e51b81526004018080602001828103825260218152602001806119626021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60016020526000908152604090205481565b61093b610c63565b61098c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077781611382565b60006109a082610f70565b1592915050565b6109af610c63565b610a00576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113bd92505050565b610a75610c63565b610ac6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610b539061159e565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610b939061159e565b90508015610b9f578091505b6000610bb1610bac6115a2565b61159e565b90506000610bc5828563ffffffff6115c616565b90506000610bf369d3c21bcecceda1000000610be78b8563ffffffff61162916565b9063ffffffff61168216565b90506000610c07848763ffffffff6116c416565b90506000610c2969d3c21bcecceda1000000610be78d8563ffffffff61162916565b9050808a1080610c385750828a115b9b9a5050505050505050505050565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610c87611706565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610cb1610c63565b610d02576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b828114610d56576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b83811015610f07576000858583818110610d6f57fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610df5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b828282818110610e0157fe5b9050602002013560066000878785818110610e1857fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fa62a59cb391b90466127d5c2ae9c7cfb59877763680d974867d6abe0c4fd52cb858583818110610ea057fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff16848484818110610ec957fe5b6040805173ffffffffffffffffffffffffffffffffffffffff90951685526020918202939093013590840152508051918290030190a1600101610d59565b5050505050565b610f16610c63565b610f67576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107778161170a565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610fe357600080fd5b505afa158015610ff7573d6000803e3d6000fd5b505050506040513d604081101561100d57600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526006602052604090205490915080611048576000925050506107f8565b611053818386610b35565b949350505050565b80518251146110b1576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff168382815181106110e157fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415611152576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b61115a611907565b61117683838151811061116957fe5b60200260200101516117ea565b90506111906111836115a2565b829063ffffffff61180416565b6111e1576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111f257fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061126e57fe5b602002602001015184848151811061128257fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110b4565b505050565b6112d0816117ea565b516002556112fb6112df6115a2565b604080516020810190915260025481529063ffffffff61180416565b61134c576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b8051825114611413576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff1683828151811061144357fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114b4576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114c057fe5b6020026020010151600160008584815181106114d857fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061154b57fe5b602002602001015183838151811061155f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611416565b5190565b6115aa611907565b50604080516020810190915269d3c21bcecceda1000000815290565b600082820183811015611620576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b60008261163857506000611623565b8282028284828161164557fe5b04146116205760405162461bcd60e51b81526004018080602001828103825260218152602001806119416021913960400191505060405180910390fd5b600061162083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061180b565b600061162083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506118ad565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661175c5760405162461bcd60e51b815260040180806020018281038252602681526020018061191b6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6117f2611907565b50604080516020810190915290815290565b5190511090565b600081836118975760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561185c578181015183820152602001611844565b50505050905090810190601f1680156118895780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816118a357fe5b0495945050505050565b600081848411156118ff5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561185c578181015183820152602001611844565b505050900390565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a7231582011765acba939a6b32e46cb228259748701b284c59dfd4ac49f1e8f56ca5fb53864736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d7573742062652073657400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000fdd8bd58115ffbf04e47411c1d228ecc45e9307500000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "nonce": "0xde" - }, - "additionalContracts": [], - "isFixedGasLimit": false - }, - { - "hash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", - "transactionType": "CALL", - "contractName": "NonrecoverableValueDeltaBreaker", - "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "function": "transferOwnership(address)", - "arguments": [ - "0xAA963FC97281d9632d96700aB62A4D1340F9a28a" - ], - "transaction": { - "type": "0x00", - "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "to": "0x69d7a21025d45d301a396cceffd2d3a80b7c3a5b", - "gas": "0xa387", - "value": "0x0", - "data": "0xf2fde38b000000000000000000000000aa963fc97281d9632d96700ab62a4d1340f9a28a", - "nonce": "0xdf" - }, - "additionalContracts": [], - "isFixedGasLimit": false - } - ], - "receipts": [ - { - "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionIndex": "0x0", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", - "to": null, - "cumulativeGasUsed": "0x17e762", - "gasUsed": "0x17e762", - "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "logs": [ - { - "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "topics": [ - "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", - "0x0000000000000000000000000000000000000000000000000000000000000000", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" - ], - "data": "0x", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionIndex": "0x0", - "logIndex": "0x0", - "removed": false - }, - { - "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "topics": [ - "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" - ], - "data": "0x", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionIndex": "0x0", - "logIndex": "0x1", - "removed": false - }, - { - "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "topics": [ - "0x590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f7353" - ], - "data": "0x000000000000000000000000fdd8bd58115ffbf04e47411c1d228ecc45e93075", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionIndex": "0x0", - "logIndex": "0x2", - "removed": false - }, - { - "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "topics": [ - "0x9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a2" - ], - "data": "0x0000000000000000000000000000000000000000000000000000000000000000", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionIndex": "0x0", - "logIndex": "0x3", - "removed": false - }, - { - "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "topics": [ - "0xd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d" - ], - "data": "0x0000000000000000000000000000000000000000000000000000000000000000", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionIndex": "0x0", - "logIndex": "0x4", - "removed": false - } - ], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000022800000000000000000080000000000000000000000010000000000001000000000000000000000000000008000000000000000000000000001000000000000000000000000000000800000020000000000000200000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000800000000000000000000008000000000000000000000000000000000000000000000000000000000000000000080000000000000000004000000000000020000004000000000001000000000000000000000000000000000000000020000000", - "type": "0x0", - "effectiveGasPrice": "0x5d21dba00" - }, - { - "transactionHash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", - "transactionIndex": "0x1", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", - "to": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "cumulativeGasUsed": "0x185733", - "gasUsed": "0x6fd1", - "contractAddress": null, - "logs": [ - { - "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "topics": [ - "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", - "0x000000000000000000000000aa963fc97281d9632d96700ab62a4d1340f9a28a" - ], - "data": "0x", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "transactionHash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", - "transactionIndex": "0x1", - "logIndex": "0x5", - "removed": false - } - ], - "status": "0x1", - "logsBloom": "0x00000000000020000000000000000000000000000000000020800000000000000000080000004000000000000000010000000000000000000000000000000000000000008000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000", - "type": "0x0", - "effectiveGasPrice": "0x5d21dba00" - } - ], - "libraries": [ - "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x2F0F7686fFFEfc3C266403Ad600035581deaedff", - "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0x29B1B5e05217c751038861aF2C77494EAB10A257" - ], - "pending": [], - "returns": {}, - "timestamp": 1692783905, - "chain": 44787, - "multi": false, - "commit": "1071d75" -} \ No newline at end of file diff --git a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783955.json b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783955.json deleted file mode 100644 index ed40e2ac..00000000 --- a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/44787/run-1692783955.json +++ /dev/null @@ -1,180 +0,0 @@ -{ - "transactions": [ - { - "hash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionType": "CREATE", - "contractName": "NonrecoverableValueDeltaBreaker", - "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "function": null, - "arguments": [ - "0", - "0", - "0xFdd8bD58115FfBf04e47411c1d228eCC45E93075", - "[]", - "[]", - "[]" - ], - "transaction": { - "type": "0x00", - "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "gas": "0x1f2d9a", - "value": "0x0", - "data": "0x60806040523480156200001157600080fd5b506040516200242b3803806200242b833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b5050505090500160405250505085858585858560006200020d620002d660201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620023ea833981519152908290a3506200025e336001600160e01b03620002da16565b62000272846001600160e01b036200036c16565b62000286866001600160e01b036200046c16565b6200029a856001600160e01b03620004a716565b620002af83836001600160e01b036200058516565b620002c483826001600160e01b03620007d316565b505050505050505050505050620009fd565b3390565b6001600160a01b038116620003215760405162461bcd60e51b8152600401808060200182810382526026815260200180620023c46026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620023ea83398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b6200037f6001600160e01b036200097016565b620003d1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b81526004018080602001828103825260218152602001806200240a6021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004bd81620009a160201b620017ea1760201c565b51600255620004fd620004db620009bd602090811b620015a217901c565b6040805160208082019092526002548152919062001804620009e3821b17901c565b6200054f576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005dc576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200060157fe5b60200260200101516001600160a01b031614156200065a576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000664620009ea565b6200068e8383815181106200067557fe5b6020026020010151620009a160201b620017ea1760201c565b9050620006be620006a9620009bd60201b620015a21760201c565b82620009e360201b620018041790919060201c565b62000710576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200072257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200078557fe5b60200260200101518484815181106200079a57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005df565b505050565b80518251146200082a576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200084f57fe5b60200260200101516001600160a01b03161415620008a8576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008b557fe5b602002602001015160016000858481518110620008ce57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200092857fe5b60200260200101518383815181106200093d57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a16001016200082d565b6004546000906001600160a01b0316620009926001600160e01b03620002d616565b6001600160a01b031614905090565b620009ab620009ea565b50604080516020810190915290815290565b620009c7620009ea565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b6119b78062000a0d6000396000f3fe608060405234801561001057600080fd5b506004361061016c5760003560e01c806368b89d58116100cd5780638f32d59b11610081578063e829902e11610066578063e829902e14610521578063f2fde38b146105e3578063fd165f53146106165761016c565b80638f32d59b14610511578063a44235cb146105195761016c565b8063715018a6116100b2578063715018a6146104c2578063753d8c2f146104ca5780638da5cb5b146105095761016c565b806368b89d58146103b95780636cac543a146104005761016c565b80633932bcc3116101245780634afb215e116101095780634afb215e1461033657806353f5d6f1146103695780635ac3ff701461039c5761016c565b80633932bcc3146102d057806339b84ecf146103035761016c565b8063132e8aa711610155578063132e8aa7146102525780631893304f146102835780632e37ff73146102c85761016c565b8063020323dd1461017157806305e0478514610235575b600080fd5b6102336004803603604081101561018757600080fd5b8101906020810181356401000000008111156101a257600080fd5b8201836020820111156101b457600080fd5b803590602001918460208302840111640100000000831117156101d657600080fd5b9193909290916020810190356401000000008111156101f457600080fd5b82018360208201111561020657600080fd5b8035906020019184602083028401116401000000008311171561022857600080fd5b509092509050610649565b005b6102336004803603602081101561024b57600080fd5b5035610715565b61025a61077a565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6102b66004803603602081101561029957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610796565b60408051918252519081900360200190f35b6102b66107a8565b6102b6600480360360208110156102e657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107ae565b6102b66004803603602081101561031957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107c0565b6102336004803603602081101561034c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107fd565b6102b66004803603602081101561037f57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610921565b610233600480360360208110156103b257600080fd5b5035610933565b6103ec600480360360208110156103cf57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610995565b604080519115158252519081900360200190f35b6102336004803603604081101561041657600080fd5b81019060208101813564010000000081111561043157600080fd5b82018360208201111561044357600080fd5b8035906020019184602083028401116401000000008311171561046557600080fd5b91939092909160208101903564010000000081111561048357600080fd5b82018360208201111561049557600080fd5b803590602001918460208302840111640100000000831117156104b757600080fd5b5090925090506109a7565b610233610a6d565b6103ec600480360360608110156104e057600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610b35565b61025a610c47565b6103ec610c63565b6102b6610ca3565b6102336004803603604081101561053757600080fd5b81019060208101813564010000000081111561055257600080fd5b82018360208201111561056457600080fd5b8035906020019184602083028401116401000000008311171561058657600080fd5b9193909290916020810190356401000000008111156105a457600080fd5b8201836020820111156105b657600080fd5b803590602001918460208302840111640100000000831117156105d857600080fd5b509092509050610ca9565b610233600480360360208110156105f957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f0e565b6103ec6004803603602081101561062c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f70565b610651610c63565b6106a2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f8484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061105b92505050565b50505050565b61071d610c63565b61076e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610777816112c7565b50565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b60036020526000908152604090205481565b60005481565b60066020526000908152604090205481565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260016020526040812054806107f55750506000546107f8565b90505b919050565b610805610c63565b610856576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166108a85760405162461bcd60e51b81526004018080602001828103825260218152602001806119626021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60016020526000908152604090205481565b61093b610c63565b61098c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077781611382565b60006109a082610f70565b1592915050565b6109af610c63565b610a00576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113bd92505050565b610a75610c63565b610ac6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610b539061159e565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610b939061159e565b90508015610b9f578091505b6000610bb1610bac6115a2565b61159e565b90506000610bc5828563ffffffff6115c616565b90506000610bf369d3c21bcecceda1000000610be78b8563ffffffff61162916565b9063ffffffff61168216565b90506000610c07848763ffffffff6116c416565b90506000610c2969d3c21bcecceda1000000610be78d8563ffffffff61162916565b9050808a1080610c385750828a115b9b9a5050505050505050505050565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610c87611706565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610cb1610c63565b610d02576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b828114610d56576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b83811015610f07576000858583818110610d6f57fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610df5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b828282818110610e0157fe5b9050602002013560066000878785818110610e1857fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fa62a59cb391b90466127d5c2ae9c7cfb59877763680d974867d6abe0c4fd52cb858583818110610ea057fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff16848484818110610ec957fe5b6040805173ffffffffffffffffffffffffffffffffffffffff90951685526020918202939093013590840152508051918290030190a1600101610d59565b5050505050565b610f16610c63565b610f67576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107778161170a565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610fe357600080fd5b505afa158015610ff7573d6000803e3d6000fd5b505050506040513d604081101561100d57600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526006602052604090205490915080611048576000925050506107f8565b611053818386610b35565b949350505050565b80518251146110b1576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff168382815181106110e157fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415611152576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b61115a611907565b61117683838151811061116957fe5b60200260200101516117ea565b90506111906111836115a2565b829063ffffffff61180416565b6111e1576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111f257fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061126e57fe5b602002602001015184848151811061128257fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110b4565b505050565b6112d0816117ea565b516002556112fb6112df6115a2565b604080516020810190915260025481529063ffffffff61180416565b61134c576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b8051825114611413576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff1683828151811061144357fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114b4576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114c057fe5b6020026020010151600160008584815181106114d857fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061154b57fe5b602002602001015183838151811061155f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611416565b5190565b6115aa611907565b50604080516020810190915269d3c21bcecceda1000000815290565b600082820183811015611620576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b60008261163857506000611623565b8282028284828161164557fe5b04146116205760405162461bcd60e51b81526004018080602001828103825260218152602001806119416021913960400191505060405180910390fd5b600061162083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061180b565b600061162083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506118ad565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661175c5760405162461bcd60e51b815260040180806020018281038252602681526020018061191b6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6117f2611907565b50604080516020810190915290815290565b5190511090565b600081836118975760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561185c578181015183820152602001611844565b50505050905090810190601f1680156118895780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816118a357fe5b0495945050505050565b600081848411156118ff5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561185c578181015183820152602001611844565b505050900390565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a7231582011765acba939a6b32e46cb228259748701b284c59dfd4ac49f1e8f56ca5fb53864736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d7573742062652073657400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000fdd8bd58115ffbf04e47411c1d228ecc45e9307500000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "nonce": "0xde" - }, - "additionalContracts": [], - "isFixedGasLimit": false - }, - { - "hash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", - "transactionType": "CALL", - "contractName": "NonrecoverableValueDeltaBreaker", - "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "function": "transferOwnership(address)", - "arguments": [ - "0xAA963FC97281d9632d96700aB62A4D1340F9a28a" - ], - "transaction": { - "type": "0x00", - "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "to": "0x69d7a21025d45d301a396cceffd2d3a80b7c3a5b", - "gas": "0xa387", - "value": "0x0", - "data": "0xf2fde38b000000000000000000000000aa963fc97281d9632d96700ab62a4d1340f9a28a", - "nonce": "0xdf" - }, - "additionalContracts": [], - "isFixedGasLimit": false - } - ], - "receipts": [ - { - "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionIndex": "0x0", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", - "to": null, - "cumulativeGasUsed": "0x17e762", - "gasUsed": "0x17e762", - "contractAddress": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "logs": [ - { - "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "topics": [ - "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", - "0x0000000000000000000000000000000000000000000000000000000000000000", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" - ], - "data": "0x", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionIndex": "0x0", - "logIndex": "0x0", - "removed": false - }, - { - "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "topics": [ - "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" - ], - "data": "0x", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionIndex": "0x0", - "logIndex": "0x1", - "removed": false - }, - { - "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "topics": [ - "0x590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f7353" - ], - "data": "0x000000000000000000000000fdd8bd58115ffbf04e47411c1d228ecc45e93075", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionIndex": "0x0", - "logIndex": "0x2", - "removed": false - }, - { - "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "topics": [ - "0x9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a2" - ], - "data": "0x0000000000000000000000000000000000000000000000000000000000000000", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionIndex": "0x0", - "logIndex": "0x3", - "removed": false - }, - { - "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "topics": [ - "0xd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d" - ], - "data": "0x0000000000000000000000000000000000000000000000000000000000000000", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "transactionHash": "0xae7b6266f181f45dac20be5ca6c0206cb8cbd9f6ccf70a6f6fda9acac756bdb6", - "transactionIndex": "0x0", - "logIndex": "0x4", - "removed": false - } - ], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000022800000000000000000080000000000000000000000010000000000001000000000000000000000000000008000000000000000000000000001000000000000000000000000000000800000020000000000000200000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000800000000000000000000008000000000000000000000000000000000000000000000000000000000000000000080000000000000000004000000000000020000004000000000001000000000000000000000000000000000000000020000000", - "type": "0x0", - "effectiveGasPrice": "0x5d21dba00" - }, - { - "transactionHash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", - "transactionIndex": "0x1", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", - "to": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "cumulativeGasUsed": "0x185733", - "gasUsed": "0x6fd1", - "contractAddress": null, - "logs": [ - { - "address": "0x69D7A21025D45D301a396cCeFfD2D3a80b7c3a5B", - "topics": [ - "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", - "0x000000000000000000000000aa963fc97281d9632d96700ab62a4d1340f9a28a" - ], - "data": "0x", - "blockHash": "0x7d9780620118c967970faec2c79001a43b32a5afb7210f215dc2fa27fb4c3c23", - "blockNumber": "0x1293e7b", - "transactionHash": "0xd9e9581cb6f5766dd1034f8ec32fd35211a32f53b1441f7f5354a68eb6ddfaf6", - "transactionIndex": "0x1", - "logIndex": "0x5", - "removed": false - } - ], - "status": "0x1", - "logsBloom": "0x00000000000020000000000000000000000000000000000020800000000000000000080000004000000000000000010000000000000000000000000000000000000000008000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000", - "type": "0x0", - "effectiveGasPrice": "0x5d21dba00" - } - ], - "libraries": [ - "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x2F0F7686fFFEfc3C266403Ad600035581deaedff", - "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0x29B1B5e05217c751038861aF2C77494EAB10A257" - ], - "pending": [], - "returns": {}, - "timestamp": 1692783955, - "chain": 44787, - "multi": false, - "commit": "1071d75" -} \ No newline at end of file diff --git a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821205.json b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821205.json deleted file mode 100644 index 5b177f77..00000000 --- a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821205.json +++ /dev/null @@ -1,64 +0,0 @@ -{ - "transactions": [ - { - "hash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionType": "CREATE", - "contractName": "NonrecoverableValueDeltaBreaker", - "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "function": null, - "arguments": [ - "0", - "0", - "0x88A187a876290E9843175027902B9f7f1B092c88", - "[]", - "[]", - "[]" - ], - "transaction": { - "type": "0x00", - "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "gas": "0x1f2d9a", - "value": "0x0", - "data": "0x60806040523480156200001157600080fd5b506040516200242b3803806200242b833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b5050505090500160405250505085858585858560006200020d620002d660201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620023ea833981519152908290a3506200025e336001600160e01b03620002da16565b62000272846001600160e01b036200036c16565b62000286866001600160e01b036200046c16565b6200029a856001600160e01b03620004a716565b620002af83836001600160e01b036200058516565b620002c483826001600160e01b03620007d316565b505050505050505050505050620009fd565b3390565b6001600160a01b038116620003215760405162461bcd60e51b8152600401808060200182810382526026815260200180620023c46026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620023ea83398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b6200037f6001600160e01b036200097016565b620003d1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b81526004018080602001828103825260218152602001806200240a6021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004bd81620009a160201b620017ea1760201c565b51600255620004fd620004db620009bd602090811b620015a217901c565b6040805160208082019092526002548152919062001804620009e3821b17901c565b6200054f576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005dc576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200060157fe5b60200260200101516001600160a01b031614156200065a576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000664620009ea565b6200068e8383815181106200067557fe5b6020026020010151620009a160201b620017ea1760201c565b9050620006be620006a9620009bd60201b620015a21760201c565b82620009e360201b620018041790919060201c565b62000710576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200072257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200078557fe5b60200260200101518484815181106200079a57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005df565b505050565b80518251146200082a576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200084f57fe5b60200260200101516001600160a01b03161415620008a8576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008b557fe5b602002602001015160016000858481518110620008ce57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200092857fe5b60200260200101518383815181106200093d57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a16001016200082d565b6004546000906001600160a01b0316620009926001600160e01b03620002d616565b6001600160a01b031614905090565b620009ab620009ea565b50604080516020810190915290815290565b620009c7620009ea565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b6119b78062000a0d6000396000f3fe608060405234801561001057600080fd5b506004361061016c5760003560e01c806368b89d58116100cd5780638f32d59b11610081578063e829902e11610066578063e829902e14610521578063f2fde38b146105e3578063fd165f53146106165761016c565b80638f32d59b14610511578063a44235cb146105195761016c565b8063715018a6116100b2578063715018a6146104c2578063753d8c2f146104ca5780638da5cb5b146105095761016c565b806368b89d58146103b95780636cac543a146104005761016c565b80633932bcc3116101245780634afb215e116101095780634afb215e1461033657806353f5d6f1146103695780635ac3ff701461039c5761016c565b80633932bcc3146102d057806339b84ecf146103035761016c565b8063132e8aa711610155578063132e8aa7146102525780631893304f146102835780632e37ff73146102c85761016c565b8063020323dd1461017157806305e0478514610235575b600080fd5b6102336004803603604081101561018757600080fd5b8101906020810181356401000000008111156101a257600080fd5b8201836020820111156101b457600080fd5b803590602001918460208302840111640100000000831117156101d657600080fd5b9193909290916020810190356401000000008111156101f457600080fd5b82018360208201111561020657600080fd5b8035906020019184602083028401116401000000008311171561022857600080fd5b509092509050610649565b005b6102336004803603602081101561024b57600080fd5b5035610715565b61025a61077a565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6102b66004803603602081101561029957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610796565b60408051918252519081900360200190f35b6102b66107a8565b6102b6600480360360208110156102e657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107ae565b6102b66004803603602081101561031957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107c0565b6102336004803603602081101561034c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107fd565b6102b66004803603602081101561037f57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610921565b610233600480360360208110156103b257600080fd5b5035610933565b6103ec600480360360208110156103cf57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610995565b604080519115158252519081900360200190f35b6102336004803603604081101561041657600080fd5b81019060208101813564010000000081111561043157600080fd5b82018360208201111561044357600080fd5b8035906020019184602083028401116401000000008311171561046557600080fd5b91939092909160208101903564010000000081111561048357600080fd5b82018360208201111561049557600080fd5b803590602001918460208302840111640100000000831117156104b757600080fd5b5090925090506109a7565b610233610a6d565b6103ec600480360360608110156104e057600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610b35565b61025a610c47565b6103ec610c63565b6102b6610ca3565b6102336004803603604081101561053757600080fd5b81019060208101813564010000000081111561055257600080fd5b82018360208201111561056457600080fd5b8035906020019184602083028401116401000000008311171561058657600080fd5b9193909290916020810190356401000000008111156105a457600080fd5b8201836020820111156105b657600080fd5b803590602001918460208302840111640100000000831117156105d857600080fd5b509092509050610ca9565b610233600480360360208110156105f957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f0e565b6103ec6004803603602081101561062c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f70565b610651610c63565b6106a2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f8484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061105b92505050565b50505050565b61071d610c63565b61076e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610777816112c7565b50565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b60036020526000908152604090205481565b60005481565b60066020526000908152604090205481565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260016020526040812054806107f55750506000546107f8565b90505b919050565b610805610c63565b610856576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166108a85760405162461bcd60e51b81526004018080602001828103825260218152602001806119626021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60016020526000908152604090205481565b61093b610c63565b61098c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077781611382565b60006109a082610f70565b1592915050565b6109af610c63565b610a00576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113bd92505050565b610a75610c63565b610ac6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610b539061159e565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610b939061159e565b90508015610b9f578091505b6000610bb1610bac6115a2565b61159e565b90506000610bc5828563ffffffff6115c616565b90506000610bf369d3c21bcecceda1000000610be78b8563ffffffff61162916565b9063ffffffff61168216565b90506000610c07848763ffffffff6116c416565b90506000610c2969d3c21bcecceda1000000610be78d8563ffffffff61162916565b9050808a1080610c385750828a115b9b9a5050505050505050505050565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610c87611706565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610cb1610c63565b610d02576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b828114610d56576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b83811015610f07576000858583818110610d6f57fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610df5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b828282818110610e0157fe5b9050602002013560066000878785818110610e1857fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fa62a59cb391b90466127d5c2ae9c7cfb59877763680d974867d6abe0c4fd52cb858583818110610ea057fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff16848484818110610ec957fe5b6040805173ffffffffffffffffffffffffffffffffffffffff90951685526020918202939093013590840152508051918290030190a1600101610d59565b5050505050565b610f16610c63565b610f67576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107778161170a565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610fe357600080fd5b505afa158015610ff7573d6000803e3d6000fd5b505050506040513d604081101561100d57600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526006602052604090205490915080611048576000925050506107f8565b611053818386610b35565b949350505050565b80518251146110b1576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff168382815181106110e157fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415611152576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b61115a611907565b61117683838151811061116957fe5b60200260200101516117ea565b90506111906111836115a2565b829063ffffffff61180416565b6111e1576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111f257fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061126e57fe5b602002602001015184848151811061128257fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110b4565b505050565b6112d0816117ea565b516002556112fb6112df6115a2565b604080516020810190915260025481529063ffffffff61180416565b61134c576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b8051825114611413576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff1683828151811061144357fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114b4576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114c057fe5b6020026020010151600160008584815181106114d857fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061154b57fe5b602002602001015183838151811061155f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611416565b5190565b6115aa611907565b50604080516020810190915269d3c21bcecceda1000000815290565b600082820183811015611620576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b60008261163857506000611623565b8282028284828161164557fe5b04146116205760405162461bcd60e51b81526004018080602001828103825260218152602001806119416021913960400191505060405180910390fd5b600061162083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061180b565b600061162083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506118ad565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661175c5760405162461bcd60e51b815260040180806020018281038252602681526020018061191b6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6117f2611907565b50604080516020810190915290815290565b5190511090565b600081836118975760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561185c578181015183820152602001611844565b50505050905090810190601f1680156118895780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816118a357fe5b0495945050505050565b600081848411156118ff5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561185c578181015183820152602001611844565b505050900390565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a723158202de52c133daa5165b485b36d57f3f0ee8f32fe21677670bf73fc60225c1d889a64736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d757374206265207365740000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000088a187a876290e9843175027902b9f7f1b092c8800000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "nonce": "0x289" - }, - "additionalContracts": [], - "isFixedGasLimit": false - }, - { - "hash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", - "transactionType": "CALL", - "contractName": "NonrecoverableValueDeltaBreaker", - "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "function": "transferOwnership(address)", - "arguments": [ - "0x28443b1d87db521320a6517A4F1B6Ead77F8C811" - ], - "transaction": { - "type": "0x00", - "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "to": "0xcf49ddc026a66cbd5312a46eada3176d40b245e5", - "gas": "0xa387", - "value": "0x0", - "data": "0xf2fde38b00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811", - "nonce": "0x28a" - }, - "additionalContracts": [], - "isFixedGasLimit": false - } - ], - "receipts": [], - "libraries": [ - "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x3e2cc57f83093Ce1Ee03482c1590E3B5f4225bd7", - "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0x99EDce8143FF8AeFA1fBB6C2103B349Add2B9519" - ], - "pending": [ - "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168" - ], - "returns": {}, - "timestamp": 1692821205, - "chain": 62320, - "multi": false, - "commit": "ac52f84" -} \ No newline at end of file diff --git a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821211.json b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821211.json deleted file mode 100644 index f598a850..00000000 --- a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821211.json +++ /dev/null @@ -1,180 +0,0 @@ -{ - "transactions": [ - { - "hash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionType": "CREATE", - "contractName": "NonrecoverableValueDeltaBreaker", - "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "function": null, - "arguments": [ - "0", - "0", - "0x88A187a876290E9843175027902B9f7f1B092c88", - "[]", - "[]", - "[]" - ], - "transaction": { - "type": "0x00", - "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "gas": "0x1f2d9a", - "value": "0x0", - "data": "0x60806040523480156200001157600080fd5b506040516200242b3803806200242b833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b5050505090500160405250505085858585858560006200020d620002d660201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620023ea833981519152908290a3506200025e336001600160e01b03620002da16565b62000272846001600160e01b036200036c16565b62000286866001600160e01b036200046c16565b6200029a856001600160e01b03620004a716565b620002af83836001600160e01b036200058516565b620002c483826001600160e01b03620007d316565b505050505050505050505050620009fd565b3390565b6001600160a01b038116620003215760405162461bcd60e51b8152600401808060200182810382526026815260200180620023c46026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620023ea83398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b6200037f6001600160e01b036200097016565b620003d1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b81526004018080602001828103825260218152602001806200240a6021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004bd81620009a160201b620017ea1760201c565b51600255620004fd620004db620009bd602090811b620015a217901c565b6040805160208082019092526002548152919062001804620009e3821b17901c565b6200054f576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005dc576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200060157fe5b60200260200101516001600160a01b031614156200065a576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000664620009ea565b6200068e8383815181106200067557fe5b6020026020010151620009a160201b620017ea1760201c565b9050620006be620006a9620009bd60201b620015a21760201c565b82620009e360201b620018041790919060201c565b62000710576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200072257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200078557fe5b60200260200101518484815181106200079a57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005df565b505050565b80518251146200082a576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200084f57fe5b60200260200101516001600160a01b03161415620008a8576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008b557fe5b602002602001015160016000858481518110620008ce57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200092857fe5b60200260200101518383815181106200093d57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a16001016200082d565b6004546000906001600160a01b0316620009926001600160e01b03620002d616565b6001600160a01b031614905090565b620009ab620009ea565b50604080516020810190915290815290565b620009c7620009ea565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b6119b78062000a0d6000396000f3fe608060405234801561001057600080fd5b506004361061016c5760003560e01c806368b89d58116100cd5780638f32d59b11610081578063e829902e11610066578063e829902e14610521578063f2fde38b146105e3578063fd165f53146106165761016c565b80638f32d59b14610511578063a44235cb146105195761016c565b8063715018a6116100b2578063715018a6146104c2578063753d8c2f146104ca5780638da5cb5b146105095761016c565b806368b89d58146103b95780636cac543a146104005761016c565b80633932bcc3116101245780634afb215e116101095780634afb215e1461033657806353f5d6f1146103695780635ac3ff701461039c5761016c565b80633932bcc3146102d057806339b84ecf146103035761016c565b8063132e8aa711610155578063132e8aa7146102525780631893304f146102835780632e37ff73146102c85761016c565b8063020323dd1461017157806305e0478514610235575b600080fd5b6102336004803603604081101561018757600080fd5b8101906020810181356401000000008111156101a257600080fd5b8201836020820111156101b457600080fd5b803590602001918460208302840111640100000000831117156101d657600080fd5b9193909290916020810190356401000000008111156101f457600080fd5b82018360208201111561020657600080fd5b8035906020019184602083028401116401000000008311171561022857600080fd5b509092509050610649565b005b6102336004803603602081101561024b57600080fd5b5035610715565b61025a61077a565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6102b66004803603602081101561029957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610796565b60408051918252519081900360200190f35b6102b66107a8565b6102b6600480360360208110156102e657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107ae565b6102b66004803603602081101561031957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107c0565b6102336004803603602081101561034c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107fd565b6102b66004803603602081101561037f57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610921565b610233600480360360208110156103b257600080fd5b5035610933565b6103ec600480360360208110156103cf57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610995565b604080519115158252519081900360200190f35b6102336004803603604081101561041657600080fd5b81019060208101813564010000000081111561043157600080fd5b82018360208201111561044357600080fd5b8035906020019184602083028401116401000000008311171561046557600080fd5b91939092909160208101903564010000000081111561048357600080fd5b82018360208201111561049557600080fd5b803590602001918460208302840111640100000000831117156104b757600080fd5b5090925090506109a7565b610233610a6d565b6103ec600480360360608110156104e057600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610b35565b61025a610c47565b6103ec610c63565b6102b6610ca3565b6102336004803603604081101561053757600080fd5b81019060208101813564010000000081111561055257600080fd5b82018360208201111561056457600080fd5b8035906020019184602083028401116401000000008311171561058657600080fd5b9193909290916020810190356401000000008111156105a457600080fd5b8201836020820111156105b657600080fd5b803590602001918460208302840111640100000000831117156105d857600080fd5b509092509050610ca9565b610233600480360360208110156105f957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f0e565b6103ec6004803603602081101561062c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f70565b610651610c63565b6106a2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f8484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061105b92505050565b50505050565b61071d610c63565b61076e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610777816112c7565b50565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b60036020526000908152604090205481565b60005481565b60066020526000908152604090205481565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260016020526040812054806107f55750506000546107f8565b90505b919050565b610805610c63565b610856576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166108a85760405162461bcd60e51b81526004018080602001828103825260218152602001806119626021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60016020526000908152604090205481565b61093b610c63565b61098c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077781611382565b60006109a082610f70565b1592915050565b6109af610c63565b610a00576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113bd92505050565b610a75610c63565b610ac6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610b539061159e565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610b939061159e565b90508015610b9f578091505b6000610bb1610bac6115a2565b61159e565b90506000610bc5828563ffffffff6115c616565b90506000610bf369d3c21bcecceda1000000610be78b8563ffffffff61162916565b9063ffffffff61168216565b90506000610c07848763ffffffff6116c416565b90506000610c2969d3c21bcecceda1000000610be78d8563ffffffff61162916565b9050808a1080610c385750828a115b9b9a5050505050505050505050565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610c87611706565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610cb1610c63565b610d02576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b828114610d56576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b83811015610f07576000858583818110610d6f57fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610df5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b828282818110610e0157fe5b9050602002013560066000878785818110610e1857fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fa62a59cb391b90466127d5c2ae9c7cfb59877763680d974867d6abe0c4fd52cb858583818110610ea057fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff16848484818110610ec957fe5b6040805173ffffffffffffffffffffffffffffffffffffffff90951685526020918202939093013590840152508051918290030190a1600101610d59565b5050505050565b610f16610c63565b610f67576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107778161170a565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610fe357600080fd5b505afa158015610ff7573d6000803e3d6000fd5b505050506040513d604081101561100d57600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526006602052604090205490915080611048576000925050506107f8565b611053818386610b35565b949350505050565b80518251146110b1576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff168382815181106110e157fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415611152576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b61115a611907565b61117683838151811061116957fe5b60200260200101516117ea565b90506111906111836115a2565b829063ffffffff61180416565b6111e1576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111f257fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061126e57fe5b602002602001015184848151811061128257fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110b4565b505050565b6112d0816117ea565b516002556112fb6112df6115a2565b604080516020810190915260025481529063ffffffff61180416565b61134c576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b8051825114611413576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff1683828151811061144357fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114b4576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114c057fe5b6020026020010151600160008584815181106114d857fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061154b57fe5b602002602001015183838151811061155f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611416565b5190565b6115aa611907565b50604080516020810190915269d3c21bcecceda1000000815290565b600082820183811015611620576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b60008261163857506000611623565b8282028284828161164557fe5b04146116205760405162461bcd60e51b81526004018080602001828103825260218152602001806119416021913960400191505060405180910390fd5b600061162083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061180b565b600061162083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506118ad565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661175c5760405162461bcd60e51b815260040180806020018281038252602681526020018061191b6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6117f2611907565b50604080516020810190915290815290565b5190511090565b600081836118975760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561185c578181015183820152602001611844565b50505050905090810190601f1680156118895780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816118a357fe5b0495945050505050565b600081848411156118ff5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561185c578181015183820152602001611844565b505050900390565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a723158202de52c133daa5165b485b36d57f3f0ee8f32fe21677670bf73fc60225c1d889a64736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d757374206265207365740000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000088a187a876290e9843175027902b9f7f1b092c8800000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "nonce": "0x289" - }, - "additionalContracts": [], - "isFixedGasLimit": false - }, - { - "hash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", - "transactionType": "CALL", - "contractName": "NonrecoverableValueDeltaBreaker", - "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "function": "transferOwnership(address)", - "arguments": [ - "0x28443b1d87db521320a6517A4F1B6Ead77F8C811" - ], - "transaction": { - "type": "0x00", - "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "to": "0xcf49ddc026a66cbd5312a46eada3176d40b245e5", - "gas": "0xa387", - "value": "0x0", - "data": "0xf2fde38b00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811", - "nonce": "0x28a" - }, - "additionalContracts": [], - "isFixedGasLimit": false - } - ], - "receipts": [ - { - "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionIndex": "0x0", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", - "to": null, - "cumulativeGasUsed": "0x17fbb2", - "gasUsed": "0x17fbb2", - "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "logs": [ - { - "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "topics": [ - "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", - "0x0000000000000000000000000000000000000000000000000000000000000000", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" - ], - "data": "0x", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionIndex": "0x0", - "logIndex": "0x0", - "removed": false - }, - { - "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "topics": [ - "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" - ], - "data": "0x", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionIndex": "0x0", - "logIndex": "0x1", - "removed": false - }, - { - "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "topics": [ - "0x590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f7353" - ], - "data": "0x00000000000000000000000088a187a876290e9843175027902b9f7f1b092c88", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionIndex": "0x0", - "logIndex": "0x2", - "removed": false - }, - { - "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "topics": [ - "0x9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a2" - ], - "data": "0x0000000000000000000000000000000000000000000000000000000000000000", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionIndex": "0x0", - "logIndex": "0x3", - "removed": false - }, - { - "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "topics": [ - "0xd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d" - ], - "data": "0x0000000000000000000000000000000000000000000000000000000000000000", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionIndex": "0x0", - "logIndex": "0x4", - "removed": false - } - ], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000022800000000000000000000000000000000000000000010000000000001040000000000000000000000000000000000000000000000000000001000000000000000000000000000000800000020000000000000200000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000004000000800000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000020000004000000000041000000000000000000000000000000000000000020000000", - "type": "0x0", - "effectiveGasPrice": "0xbebc200" - }, - { - "transactionHash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", - "transactionIndex": "0x1", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", - "to": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "cumulativeGasUsed": "0x186b83", - "gasUsed": "0x6fd1", - "contractAddress": null, - "logs": [ - { - "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "topics": [ - "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", - "0x00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811" - ], - "data": "0x", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "transactionHash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", - "transactionIndex": "0x1", - "logIndex": "0x5", - "removed": false - } - ], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000020801000000000000000000000000000000000000000010000000000000040000000000000000000000000000000000000000000000000000001000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000004000000000040000000000000000000000000000000000000000000000000", - "type": "0x0", - "effectiveGasPrice": "0xbebc200" - } - ], - "libraries": [ - "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x3e2cc57f83093Ce1Ee03482c1590E3B5f4225bd7", - "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0x99EDce8143FF8AeFA1fBB6C2103B349Add2B9519" - ], - "pending": [], - "returns": {}, - "timestamp": 1692821211, - "chain": 62320, - "multi": false, - "commit": "ac52f84" -} \ No newline at end of file diff --git a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821216.json b/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821216.json deleted file mode 100644 index fbfe4e2f..00000000 --- a/broadcast/eXOF-02-Create-Nonupgradeable-Contracts.sol/62320/run-1692821216.json +++ /dev/null @@ -1,180 +0,0 @@ -{ - "transactions": [ - { - "hash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionType": "CREATE", - "contractName": "NonrecoverableValueDeltaBreaker", - "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "function": null, - "arguments": [ - "0", - "0", - "0x88A187a876290E9843175027902B9f7f1B092c88", - "[]", - "[]", - "[]" - ], - "transaction": { - "type": "0x00", - "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "gas": "0x1f2d9a", - "value": "0x0", - "data": "0x60806040523480156200001157600080fd5b506040516200242b3803806200242b833981810160405260c08110156200003757600080fd5b8151602083015160408085015160608601805192519496939591949391820192846401000000008211156200006b57600080fd5b9083019060208201858111156200008157600080fd5b82518660208202830111640100000000821117156200009f57600080fd5b82525081516020918201928201910280838360005b83811015620000ce578181015183820152602001620000b4565b5050505090500160405260200180516040519392919084640100000000821115620000f857600080fd5b9083019060208201858111156200010e57600080fd5b82518660208202830111640100000000821117156200012c57600080fd5b82525081516020918201928201910280838360005b838110156200015b57818101518382015260200162000141565b50505050905001604052602001805160405193929190846401000000008211156200018557600080fd5b9083019060208201858111156200019b57600080fd5b8251866020820283011164010000000082111715620001b957600080fd5b82525081516020918201928201910280838360005b83811015620001e8578181015183820152602001620001ce565b5050505090500160405250505085858585858560006200020d620002d660201b60201c565b600480546001600160a01b0319166001600160a01b03831690811790915560405191925090600090600080516020620023ea833981519152908290a3506200025e336001600160e01b03620002da16565b62000272846001600160e01b036200036c16565b62000286866001600160e01b036200046c16565b6200029a856001600160e01b03620004a716565b620002af83836001600160e01b036200058516565b620002c483826001600160e01b03620007d316565b505050505050505050505050620009fd565b3390565b6001600160a01b038116620003215760405162461bcd60e51b8152600401808060200182810382526026815260200180620023c46026913960400191505060405180910390fd5b6004546040516001600160a01b03808416921690600080516020620023ea83398151915290600090a3600480546001600160a01b0319166001600160a01b0392909216919091179055565b6200037f6001600160e01b036200097016565b620003d1576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6001600160a01b038116620004185760405162461bcd60e51b81526004018080602001828103825260218152602001806200240a6021913960400191505060405180910390fd5b600580546001600160a01b0383166001600160a01b0319909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b620004bd81620009a160201b620017ea1760201c565b51600255620004fd620004db620009bd602090811b620015a217901c565b6040805160208082019092526002548152919062001804620009e3821b17901c565b6200054f576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b8051825114620005dc576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200060157fe5b60200260200101516001600160a01b031614156200065a576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b62000664620009ea565b6200068e8383815181106200067557fe5b6020026020010151620009a160201b620017ea1760201c565b9050620006be620006a9620009bd60201b620015a21760201c565b82620009e360201b620018041790919060201c565b62000710576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106200072257fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a3398483815181106200078557fe5b60200260200101518484815181106200079a57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a150600101620005df565b505050565b80518251146200082a576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b8251811015620007ce5760006001600160a01b03168382815181106200084f57fe5b60200260200101516001600160a01b03161415620008a8576040805162461bcd60e51b81526020600482015260116024820152701c985d194819995959081a5b9d985b1a59607a1b604482015290519081900360640190fd5b818181518110620008b557fe5b602002602001015160016000858481518110620008ce57fe5b60200260200101516001600160a01b03166001600160a01b03168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c8382815181106200092857fe5b60200260200101518383815181106200093d57fe5b602090810291909101810151604080516001600160a01b039094168452918301528051918290030190a16001016200082d565b6004546000906001600160a01b0316620009926001600160e01b03620002d616565b6001600160a01b031614905090565b620009ab620009ea565b50604080516020810190915290815290565b620009c7620009ea565b50604080516020810190915269d3c21bcecceda1000000815290565b5190511090565b6040518060200160405280600081525090565b6119b78062000a0d6000396000f3fe608060405234801561001057600080fd5b506004361061016c5760003560e01c806368b89d58116100cd5780638f32d59b11610081578063e829902e11610066578063e829902e14610521578063f2fde38b146105e3578063fd165f53146106165761016c565b80638f32d59b14610511578063a44235cb146105195761016c565b8063715018a6116100b2578063715018a6146104c2578063753d8c2f146104ca5780638da5cb5b146105095761016c565b806368b89d58146103b95780636cac543a146104005761016c565b80633932bcc3116101245780634afb215e116101095780634afb215e1461033657806353f5d6f1146103695780635ac3ff701461039c5761016c565b80633932bcc3146102d057806339b84ecf146103035761016c565b8063132e8aa711610155578063132e8aa7146102525780631893304f146102835780632e37ff73146102c85761016c565b8063020323dd1461017157806305e0478514610235575b600080fd5b6102336004803603604081101561018757600080fd5b8101906020810181356401000000008111156101a257600080fd5b8201836020820111156101b457600080fd5b803590602001918460208302840111640100000000831117156101d657600080fd5b9193909290916020810190356401000000008111156101f457600080fd5b82018360208201111561020657600080fd5b8035906020019184602083028401116401000000008311171561022857600080fd5b509092509050610649565b005b6102336004803603602081101561024b57600080fd5b5035610715565b61025a61077a565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b6102b66004803603602081101561029957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610796565b60408051918252519081900360200190f35b6102b66107a8565b6102b6600480360360208110156102e657600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107ae565b6102b66004803603602081101561031957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107c0565b6102336004803603602081101561034c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166107fd565b6102b66004803603602081101561037f57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610921565b610233600480360360208110156103b257600080fd5b5035610933565b6103ec600480360360208110156103cf57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610995565b604080519115158252519081900360200190f35b6102336004803603604081101561041657600080fd5b81019060208101813564010000000081111561043157600080fd5b82018360208201111561044357600080fd5b8035906020019184602083028401116401000000008311171561046557600080fd5b91939092909160208101903564010000000081111561048357600080fd5b82018360208201111561049557600080fd5b803590602001918460208302840111640100000000831117156104b757600080fd5b5090925090506109a7565b610233610a6d565b6103ec600480360360608110156104e057600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff16610b35565b61025a610c47565b6103ec610c63565b6102b6610ca3565b6102336004803603604081101561053757600080fd5b81019060208101813564010000000081111561055257600080fd5b82018360208201111561056457600080fd5b8035906020019184602083028401116401000000008311171561058657600080fd5b9193909290916020810190356401000000008111156105a457600080fd5b8201836020820111156105b657600080fd5b803590602001918460208302840111640100000000831117156105d857600080fd5b509092509050610ca9565b610233600480360360208110156105f957600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f0e565b6103ec6004803603602081101561062c57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff16610f70565b610651610c63565b6106a2576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f8484808060200260200160405190810160405280939291908181526020018383602002808284376000920191909152505060408051602080880282810182019093528782529093508792508691829185019084908082843760009201919091525061105b92505050565b50505050565b61071d610c63565b61076e576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b610777816112c7565b50565b60055473ffffffffffffffffffffffffffffffffffffffff1681565b60036020526000908152604090205481565b60005481565b60066020526000908152604090205481565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260016020526040812054806107f55750506000546107f8565b90505b919050565b610805610c63565b610856576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b73ffffffffffffffffffffffffffffffffffffffff81166108a85760405162461bcd60e51b81526004018080602001828103825260218152602001806119626021913960400191505060405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff83167fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915560408051918252517f590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f73539181900360200190a150565b60016020526000908152604090205481565b61093b610c63565b61098c576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61077781611382565b60006109a082610f70565b1592915050565b6109af610c63565b610a00576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b61070f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040805160208088028281018201909352878252909350879250869182918501908490808284376000920191909152506113bd92505050565b610a75610c63565b610ac6576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b60045460405160009173ffffffffffffffffffffffffffffffffffffffff16907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600480547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055565b604080516020810190915260025481526000908190610b539061159e565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600360209081526040808320815192830190915254815291925090610b939061159e565b90508015610b9f578091505b6000610bb1610bac6115a2565b61159e565b90506000610bc5828563ffffffff6115c616565b90506000610bf369d3c21bcecceda1000000610be78b8563ffffffff61162916565b9063ffffffff61168216565b90506000610c07848763ffffffff6116c416565b90506000610c2969d3c21bcecceda1000000610be78d8563ffffffff61162916565b9050808a1080610c385750828a115b9b9a5050505050505050505050565b60045473ffffffffffffffffffffffffffffffffffffffff1690565b60045460009073ffffffffffffffffffffffffffffffffffffffff16610c87611706565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b60025481565b610cb1610c63565b610d02576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b828114610d56576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b83811015610f07576000858583818110610d6f57fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610df5576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b828282818110610e0157fe5b9050602002013560066000878785818110610e1857fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507fa62a59cb391b90466127d5c2ae9c7cfb59877763680d974867d6abe0c4fd52cb858583818110610ea057fe5b9050602002013573ffffffffffffffffffffffffffffffffffffffff16848484818110610ec957fe5b6040805173ffffffffffffffffffffffffffffffffffffffff90951685526020918202939093013590840152508051918290030190a1600101610d59565b5050505050565b610f16610c63565b610f67576040805162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604482015290519081900360640190fd5b6107778161170a565b600554604080517fef90e1b000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301528251600094859492169263ef90e1b0926024808301939192829003018186803b158015610fe357600080fd5b505afa158015610ff7573d6000803e3d6000fd5b505050506040513d604081101561100d57600080fd5b505173ffffffffffffffffffffffffffffffffffffffff841660009081526006602052604090205490915080611048576000925050506107f8565b611053818386610b35565b949350505050565b80518251146110b1576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff168382815181106110e157fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415611152576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b61115a611907565b61117683838151811061116957fe5b60200260200101516117ea565b90506111906111836115a2565b829063ffffffff61180416565b6111e1576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b80600360008685815181106111f257fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082015181600001559050507fb4610b016800a84a54beff5837e8c18d5deb15ebe20fc28f30b55fb7f183a33984838151811061126e57fe5b602002602001015184848151811061128257fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1506001016110b4565b505050565b6112d0816117ea565b516002556112fb6112df6115a2565b604080516020810190915260025481529063ffffffff61180416565b61134c576040805162461bcd60e51b815260206004820152601960248201527f76616c7565206d757374206265206c657373207468616e203100000000000000604482015290519081900360640190fd5b6040805182815290517fd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d9181900360200190a150565b60008190556040805182815290517f9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a29181900360200190a150565b8051825114611413576040805162461bcd60e51b815260206004820152601660248201527f6172726179206c656e677468206d6973736d6174636800000000000000000000604482015290519081900360640190fd5b60005b82518110156112c257600073ffffffffffffffffffffffffffffffffffffffff1683828151811061144357fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156114b4576040805162461bcd60e51b815260206004820152601160248201527f72617465206665656420696e76616c6964000000000000000000000000000000604482015290519081900360640190fd5b8181815181106114c057fe5b6020026020010151600160008584815181106114d857fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055507f1b2e9cb68f822fa2031c648b0d701fdd3f5330d9c60f3e9f0ca3a5c9e2f6285c83828151811061154b57fe5b602002602001015183838151811061155f57fe5b6020908102919091018101516040805173ffffffffffffffffffffffffffffffffffffffff9094168452918301528051918290030190a1600101611416565b5190565b6115aa611907565b50604080516020810190915269d3c21bcecceda1000000815290565b600082820183811015611620576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b90505b92915050565b60008261163857506000611623565b8282028284828161164557fe5b04146116205760405162461bcd60e51b81526004018080602001828103825260218152602001806119416021913960400191505060405180910390fd5b600061162083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061180b565b600061162083836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506118ad565b3390565b73ffffffffffffffffffffffffffffffffffffffff811661175c5760405162461bcd60e51b815260040180806020018281038252602681526020018061191b6026913960400191505060405180910390fd5b60045460405173ffffffffffffffffffffffffffffffffffffffff8084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a3600480547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b6117f2611907565b50604080516020810190915290815290565b5190511090565b600081836118975760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561185c578181015183820152602001611844565b50505050905090810190601f1680156118895780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816118a357fe5b0495945050505050565b600081848411156118ff5760405162461bcd60e51b815260206004820181815283516024840152835190928392604490910191908501908083836000831561185c578181015183820152602001611844565b505050900390565b604051806020016040528060008152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77536f727465644f7261636c65732061646472657373206d75737420626520736574a265627a7a723158202de52c133daa5165b485b36d57f3f0ee8f32fe21677670bf73fc60225c1d889a64736f6c634300051100324f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573738be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0536f727465644f7261636c65732061646472657373206d757374206265207365740000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000088a187a876290e9843175027902b9f7f1b092c8800000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", - "nonce": "0x289" - }, - "additionalContracts": [], - "isFixedGasLimit": false - }, - { - "hash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", - "transactionType": "CALL", - "contractName": "NonrecoverableValueDeltaBreaker", - "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "function": "transferOwnership(address)", - "arguments": [ - "0x28443b1d87db521320a6517A4F1B6Ead77F8C811" - ], - "transaction": { - "type": "0x00", - "from": "0x56fd3f2bee130e9867942d0f463a16fbe49b8d81", - "to": "0xcf49ddc026a66cbd5312a46eada3176d40b245e5", - "gas": "0xa387", - "value": "0x0", - "data": "0xf2fde38b00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811", - "nonce": "0x28a" - }, - "additionalContracts": [], - "isFixedGasLimit": false - } - ], - "receipts": [ - { - "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionIndex": "0x0", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", - "to": null, - "cumulativeGasUsed": "0x17fbb2", - "gasUsed": "0x17fbb2", - "contractAddress": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "logs": [ - { - "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "topics": [ - "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", - "0x0000000000000000000000000000000000000000000000000000000000000000", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" - ], - "data": "0x", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionIndex": "0x0", - "logIndex": "0x0", - "removed": false - }, - { - "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "topics": [ - "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81" - ], - "data": "0x", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionIndex": "0x0", - "logIndex": "0x1", - "removed": false - }, - { - "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "topics": [ - "0x590fd633a008765ce9e65e8081adfba311e99e11b958a5ecb5000ea3355f7353" - ], - "data": "0x00000000000000000000000088a187a876290e9843175027902b9f7f1b092c88", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionIndex": "0x0", - "logIndex": "0x2", - "removed": false - }, - { - "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "topics": [ - "0x9f54ba8283224283655cf1e247079a40dc4c214c156638f09c1c45f59502d7a2" - ], - "data": "0x0000000000000000000000000000000000000000000000000000000000000000", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionIndex": "0x0", - "logIndex": "0x3", - "removed": false - }, - { - "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "topics": [ - "0xd6eda16822202898d222eeb6da8466a309a480c9319d82df117db598af244c0d" - ], - "data": "0x0000000000000000000000000000000000000000000000000000000000000000", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "transactionHash": "0xde668658a1a8bbf4401f7cd2b372aa7f23b69e3c797b85ed12db60efd1c31d76", - "transactionIndex": "0x0", - "logIndex": "0x4", - "removed": false - } - ], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000022800000000000000000000000000000000000000000010000000000001040000000000000000000000000000000000000000000000000000001000000000000000000000000000000800000020000000000000200000800000000000000000000000000000000400000000000000000000000000000000000000000000000000000000004000000800000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000020000004000000000041000000000000000000000000000000000000000020000000", - "type": "0x0", - "effectiveGasPrice": "0xbebc200" - }, - { - "transactionHash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", - "transactionIndex": "0x1", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "from": "0x56fD3F2bEE130e9867942D0F463a16fBE49B8d81", - "to": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "cumulativeGasUsed": "0x186b83", - "gasUsed": "0x6fd1", - "contractAddress": null, - "logs": [ - { - "address": "0xCF49dDc026A66CbD5312a46EADA3176d40B245E5", - "topics": [ - "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", - "0x00000000000000000000000056fd3f2bee130e9867942d0f463a16fbe49b8d81", - "0x00000000000000000000000028443b1d87db521320a6517a4f1b6ead77f8c811" - ], - "data": "0x", - "blockHash": "0x4f9ffceb1921c68818963619b70c697bf12332b2cd50e0acde9edf6dd8b1fa60", - "blockNumber": "0x122015c", - "transactionHash": "0x523a708066be6c24fe2e34d88ea0f12273bc5f80befc9c06ba7126e07e647168", - "transactionIndex": "0x1", - "logIndex": "0x5", - "removed": false - } - ], - "status": "0x1", - "logsBloom": "0x00000000000000000000000000000000000000000000000020801000000000000000000000000000000000000000010000000000000040000000000000000000000000000000000000000000000000000001000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000004000000000040000000000000000000000000000000000000000000000000", - "type": "0x0", - "effectiveGasPrice": "0xbebc200" - } - ], - "libraries": [ - "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressLinkedList.sol:AddressLinkedList:0x3e2cc57f83093Ce1Ee03482c1590E3B5f4225bd7", - "lib/mento-core-2.0.0/contracts/common/linkedlists/AddressSortedLinkedListWithMedian.sol:AddressSortedLinkedListWithMedian:0x99EDce8143FF8AeFA1fBB6C2103B349Add2B9519" - ], - "pending": [], - "returns": {}, - "timestamp": 1692821216, - "chain": 62320, - "multi": false, - "commit": "ac52f84" -} \ No newline at end of file From 232193ed9b6037d5896b5a99e21ede7ad69d4db5 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Wed, 30 Aug 2023 12:00:05 -0500 Subject: [PATCH 30/64] refactor: removed unneeded imports --- script/upgrades/MU03/MU03.sol | 1 - 1 file changed, 1 deletion(-) diff --git a/script/upgrades/MU03/MU03.sol b/script/upgrades/MU03/MU03.sol index f03a2614..56710bea 100644 --- a/script/upgrades/MU03/MU03.sol +++ b/script/upgrades/MU03/MU03.sol @@ -12,7 +12,6 @@ import { Arrays } from "script/utils/Arrays.sol"; import { FixidityLib } from "mento-core-2.2.0/common/FixidityLib.sol"; import { IBiPoolManager } from "mento-core-2.2.0/interfaces/IBiPoolManager.sol"; import { IPricingModule } from "mento-core-2.2.0/interfaces/IPricingModule.sol"; -import { IReserve } from "mento-core-2.2.0/interfaces/IReserve.sol"; import { Proxy } from "mento-core-2.2.0/common/Proxy.sol"; import { IERC20Metadata } from "mento-core-2.2.0/common/interfaces/IERC20Metadata.sol"; From 8c6d0c819ae9193d032db1b6042139e3cd888b8e Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Wed, 30 Aug 2023 12:17:04 -0500 Subject: [PATCH 31/64] refactor: rename rate feed ref for consistency --- script/upgrades/eXOF/Config.sol | 9 ++++---- script/upgrades/eXOF/eXOF.sol | 24 +++++++++++----------- script/upgrades/eXOF/eXOFChecks.verify.sol | 4 ++-- 3 files changed, 19 insertions(+), 18 deletions(-) diff --git a/script/upgrades/eXOF/Config.sol b/script/upgrades/eXOF/Config.sol index 05e7e0e7..5b9c2319 100644 --- a/script/upgrades/eXOF/Config.sol +++ b/script/upgrades/eXOF/Config.sol @@ -13,7 +13,8 @@ import { FixidityLib } from "script/utils/FixidityLib.sol"; * @dev This library contains the configuration required for the eXOF governance proposal. * The following configuration is used: * - 2 pools: eXOFCelo and eXOFEUROC - * - 2 rate feeds: CELOXOF and EUROXOF + * - 2 rate feeds: CELOXOF and EURXOF + * - Configuration params needed to initialize the eXOF stable token */ library eXOFConfig { using FixidityLib for FixidityLib.Fraction; @@ -26,7 +27,7 @@ library eXOFConfig { Config.Pool[] pools; // Rate Feeds Config.RateFeed CELOXOF; - Config.RateFeed EUROXOF; + Config.RateFeed EURXOF; Config.RateFeed[] rateFeeds; Config.StableToken stableTokenXOF; } @@ -41,7 +42,7 @@ library eXOFConfig { config.rateFeeds = new Config.RateFeed[](2); config.rateFeeds[0] = config.CELOXOF = CELOXOF_RateFeedConfig(contracts); - config.rateFeeds[1] = config.EUROXOF = EUROXOF_RateFeedConfig(contracts); + config.rateFeeds[1] = config.EURXOF = EUROXOF_RateFeedConfig(contracts); config.stableTokenXOF = stableTokenXOFConfig(); } @@ -64,7 +65,7 @@ library eXOFConfig { } /** - * @dev Returns the configuration for the EUROXOF rate feed. + * @dev Returns the configuration for the EURXOF rate feed. */ function EUROXOF_RateFeedConfig( Contracts.Cache storage contracts diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index ba9826c7..41a75394 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -507,8 +507,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setCooldownTimes.selector, - Arrays.addresses(config.EUROXOF.rateFeedID), - Arrays.uints(config.EUROXOF.valueDeltaBreaker0.cooldown) + Arrays.addresses(config.EURXOF.rateFeedID), + Arrays.uints(config.EURXOF.valueDeltaBreaker0.cooldown) ) ) ); @@ -519,8 +519,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setRateChangeThresholds.selector, - Arrays.addresses(config.EUROXOF.rateFeedID), - Arrays.uints(config.EUROXOF.valueDeltaBreaker0.threshold.unwrap()) + Arrays.addresses(config.EURXOF.rateFeedID), + Arrays.uints(config.EURXOF.valueDeltaBreaker0.threshold.unwrap()) ) ) ); @@ -531,8 +531,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { valueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setReferenceValues.selector, - Arrays.addresses(config.EUROXOF.rateFeedID), - Arrays.uints(config.EUROXOF.valueDeltaBreaker0.referenceValue) + Arrays.addresses(config.EURXOF.rateFeedID), + Arrays.uints(config.EURXOF.valueDeltaBreaker0.referenceValue) ) ) ); @@ -549,8 +549,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { nonrecoverableValueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setCooldownTimes.selector, - Arrays.addresses(config.EUROXOF.rateFeedID), - Arrays.uints(config.EUROXOF.valueDeltaBreaker1.cooldown) + Arrays.addresses(config.EURXOF.rateFeedID), + Arrays.uints(config.EURXOF.valueDeltaBreaker1.cooldown) ) ) ); @@ -562,8 +562,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { nonrecoverableValueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setRateChangeThresholds.selector, - Arrays.addresses(config.EUROXOF.rateFeedID), - Arrays.uints(config.EUROXOF.valueDeltaBreaker1.threshold.unwrap()) + Arrays.addresses(config.EURXOF.rateFeedID), + Arrays.uints(config.EURXOF.valueDeltaBreaker1.threshold.unwrap()) ) ) ); @@ -575,8 +575,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { nonrecoverableValueDeltaBreaker, abi.encodeWithSelector( ValueDeltaBreaker(0).setReferenceValues.selector, - Arrays.addresses(config.EUROXOF.rateFeedID), - Arrays.uints(config.EUROXOF.valueDeltaBreaker1.referenceValue) + Arrays.addresses(config.EURXOF.rateFeedID), + Arrays.uints(config.EURXOF.valueDeltaBreaker1.referenceValue) ) ) ); diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol index 6c7cac87..7b112859 100644 --- a/script/upgrades/eXOF/eXOFChecks.verify.sol +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -322,9 +322,9 @@ contract eXOFChecksVerify is eXOFChecksBase { console.log("🟢 Nonrecoverable ValueDeltaBreaker set with trading mode 3"); // verify that rate feed dependencies were configured correctly - address EUROCXOFDependency = BreakerBox(breakerBox).rateFeedDependencies(config.EUROXOF.rateFeedID, 0); + address EUROCXOFDependency = BreakerBox(breakerBox).rateFeedDependencies(config.EURXOF.rateFeedID, 0); require( - EUROCXOFDependency == config.EUROXOF.dependentRateFeeds[0], + EUROCXOFDependency == config.EURXOF.dependentRateFeeds[0], "EUROC/XOF rate feed dependency not set correctly" ); console.log("🟢 Rate feed dependencies configured correctly 🗳️"); From 326d41c16cc05ded354df8895e144c905e4334ca Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Wed, 30 Aug 2023 12:18:36 -0500 Subject: [PATCH 32/64] refactor: rename param --- script/upgrades/eXOF/eXOFChecks.swap.sol | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/script/upgrades/eXOF/eXOFChecks.swap.sol b/script/upgrades/eXOF/eXOFChecks.swap.sol index eaacc1db..982a11ae 100644 --- a/script/upgrades/eXOF/eXOFChecks.swap.sol +++ b/script/upgrades/eXOF/eXOFChecks.swap.sol @@ -177,13 +177,13 @@ contract eXOFChecksSwap is eXOFChecksBase { address tokenOut, uint256 amountIn, address rateFeedID, - bool isBridgedUsdcToStable + bool isBridgedStable ) internal { uint256 amountOut = Broker(broker).getAmountOut(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn); (uint256 numerator, uint256 denominator) = SortedOracles(sortedOraclesProxy).medianRate(rateFeedID); uint256 estimatedAmountOut; - if (isBridgedUsdcToStable) { + if (isBridgedStable) { estimatedAmountOut = FixidityLib .newFixed(amountIn.mul(1e12)) .multiply(FixidityLib.wrap(numerator).divide(FixidityLib.wrap(denominator))) From 1b0b5e1686985929afcbf270ce5287ea204f0a90 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Wed, 30 Aug 2023 12:39:24 -0500 Subject: [PATCH 33/64] refactor: add descriptions to stable token props --- script/utils/Config.sol | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/script/utils/Config.sol b/script/utils/Config.sol index bf69460f..63a69c32 100644 --- a/script/utils/Config.sol +++ b/script/utils/Config.sol @@ -249,23 +249,24 @@ library Config { */ address registryAddress; /** - * @dev the inflation rate ... TODO. + * @dev The inflation rate in the StableToken contract used to simulate the effect of economic inflation. */ uint256 inflationRate; /** - * @dev TODO + * @dev The frequency at which the inflation factor in the StableToken contract is updated. */ uint256 inflationFactorUpdatePeriod; /** - * @dev + * @dev The addresses of the initial balance holders for the stable token. */ address[] initialBalanceAddresses; /** - * @dev + * @dev The initial balance values for the addresses in the initialBalanceAddresses array. */ uint256[] initialBalanceValues; /** - * @dev + * @dev The identifer of the exchange in the regristry to be used to swap the token. + * This is deprecated but should be set to the Broker for tokens created post Mc Mento. */ string exchangeIdentifier; } From 65c610b64744221e400f95c7cc781444197be92c Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Wed, 30 Aug 2023 12:46:59 -0500 Subject: [PATCH 34/64] refactor: remove unused imports --- script/upgrades/eXOF/eXOF.sol | 2 -- 1 file changed, 2 deletions(-) diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index 41a75394..08f78733 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -21,7 +21,6 @@ import { IERC20Metadata } from "mento-core-2.2.0/common/interfaces/IERC20Metadat import { BiPoolManagerProxy } from "mento-core-2.2.0/proxies/BiPoolManagerProxy.sol"; import { BrokerProxy } from "mento-core-2.2.0/proxies/BrokerProxy.sol"; import { Broker } from "mento-core-2.2.0/swap/Broker.sol"; -import { BiPoolManager } from "mento-core-2.2.0/swap/BiPoolManager.sol"; import { Exchange } from "mento-core-2.2.0/legacy/Exchange.sol"; import { TradingLimits } from "mento-core-2.2.0/libraries/TradingLimits.sol"; import { BreakerBox } from "mento-core-2.2.0/oracles/BreakerBox.sol"; @@ -30,7 +29,6 @@ import { ValueDeltaBreaker } from "mento-core-2.2.0/oracles/breakers/ValueDeltaB import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; import { StableTokenXOF } from "mento-core-2.2.0/legacy/StableTokenXOF.sol"; import { StableTokenXOFProxy } from "mento-core-2.2.0/legacy/proxies/StableTokenXOFProxy.sol"; -import { Reserve } from "mento-core-2.2.0/swap/Reserve.sol"; import { eXOFConfig, Config } from "./Config.sol"; import { IMentoUpgrade, ICeloGovernance } from "script/interfaces/IMentoUpgrade.sol"; From 53b594df6dc77eb7b3b194f29eab2576d39eeffd Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Wed, 30 Aug 2023 19:54:24 -0500 Subject: [PATCH 35/64] feat: add verification of asset1 trading limit --- script/upgrades/eXOF/eXOFChecks.verify.sol | 67 +++++++++++++--------- 1 file changed, 40 insertions(+), 27 deletions(-) diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol index 7b112859..bc6e909b 100644 --- a/script/upgrades/eXOF/eXOFChecks.verify.sol +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -265,38 +265,51 @@ contract eXOFChecksVerify is eXOFChecksBase { IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeId); Config.Pool memory poolConfig = config.pools[i]; - bytes32 limitId = exchangeId ^ bytes32(uint256(uint160(pool.asset0))); - TradingLimits.Config memory limits = _broker.tradingLimitsConfig(limitId); + bytes32 asset0LimitId = exchangeId ^ bytes32(uint256(uint160(pool.asset0))); + TradingLimits.Config memory asset0ActualLimit = _broker.tradingLimitsConfig(asset0LimitId); - // verify configured trading limits for all pools - if (poolConfig.asset0limits.limit0 != limits.limit0) { - console.log("limit0 for %s, %s was not set ❌", pool.asset0, pool.asset1); - revert("Not all trading limits were configured correctly."); - } - if (poolConfig.asset0limits.limit1 != limits.limit1) { - console.log("limit1 for %s, %s was not set ❌", pool.asset0, pool.asset1); - revert("Not all trading limits were configured correctly."); - } - if (poolConfig.asset0limits.limitGlobal != limits.limitGlobal) { - console.log("limitGlobal for %s, %s was not set ❌", pool.asset0, pool.asset1); - revert("Not all trading limits were configured correctly."); - } - if (poolConfig.asset0limits.timeStep0 != limits.timestep0) { - console.log("timestep0 for %s, %s was not set ❌", pool.asset0, pool.asset1); - revert("Not all trading limits were configured correctly."); - } - if (poolConfig.asset0limits.timeStep1 != limits.timestep1) { - console.log("timestep1 for %s, %s was not set ❌", pool.asset0, pool.asset1); - revert("Not all trading limits were configured correctly."); - } - if (Config.tradingLimitConfigToFlag(poolConfig.asset0limits) != limits.flags) { - console.log("flags for %s, %s was not set ❌", pool.asset0, pool.asset1); - revert("Not all trading limits were configured correctly."); - } + bytes32 asset1LimitId = exchangeId ^ bytes32(uint256(uint160(pool.asset1))); + TradingLimits.Config memory asset1ActualLimit = _broker.tradingLimitsConfig(asset1LimitId); + + checkTradingLimt(poolConfig.asset0limits, asset0ActualLimit); + checkTradingLimt(poolConfig.asset1limits, asset1ActualLimit); } + console.log("🟢 Trading limits set for all exchanges 🔒"); } + function checkTradingLimt( + Config.TradingLimit memory expectedTradingLimit, + TradingLimits.Config memory actualTradingLimit + ) internal view { + if (expectedTradingLimit.limit0 != actualTradingLimit.limit0) { + console.log("limit0 was not set as expected ❌"); + revert("Not all trading limits were configured correctly."); + } + if (expectedTradingLimit.limit1 != actualTradingLimit.limit1) { + console.log("limit1 was not set as expected ❌"); + revert("Not all trading limits were configured correctly."); + } + if (expectedTradingLimit.limitGlobal != actualTradingLimit.limitGlobal) { + console.log("limitGlobal was not set as expected ❌"); + revert("Not all trading limits were configured correctly."); + } + if (expectedTradingLimit.timeStep0 != actualTradingLimit.timestep0) { + console.log("timestep0 was not set as expected ❌"); + revert("Not all trading limits were configured correctly."); + } + if (expectedTradingLimit.timeStep1 != actualTradingLimit.timestep1) { + console.log("timestep1 was not set as expected ❌"); + revert("Not all trading limits were configured correctly."); + } + + uint8 tradingLimitFlags = Config.tradingLimitConfigToFlag(expectedTradingLimit); + if (tradingLimitFlags != actualTradingLimit.flags) { + console.log("flags were not set as expected ❌"); + revert("Not all trading limits were configured correctly."); + } + } + /* ================================================================ */ /* ======================== Circuit Breaker ======================= */ /* ================================================================ */ From cd51f5e4d4c20c7030a371e66c80af97aa16bf40 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 13:18:42 -0500 Subject: [PATCH 36/64] chore: correct mainnet euroc address --- script/upgrades/dependencies.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/upgrades/dependencies.json b/script/upgrades/dependencies.json index b96676ba..a4f66a5f 100644 --- a/script/upgrades/dependencies.json +++ b/script/upgrades/dependencies.json @@ -1,7 +1,7 @@ { "42220": { "BridgedUSDC": "0xEB466342C4d449BC9f53A865D5Cb90586f405215", - "BridgedEUROC": "0xEB466342C4d449BC9f53A865D5Cb90586f405215", + "BridgedEUROC": "0x061cc5a2c863e0c1cb404006d559db18a34c762d", "USDCUSDRateFeedAddr": "0xA1A8003936862E7a15092A91898D69fa8bCE290c", "USDCEURRateFeedAddr": "0x206B25Ea01E188Ee243131aFdE526bA6E131a016", "USDCBRLRateFeedAddr": "0x25F21A1f97607Edf6852339fad709728cffb9a9d", From 9fc66fb4ee66b0fc1a1614089cec8d8773861695 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 13:22:51 -0500 Subject: [PATCH 37/64] refactor: rename getter to EURXOF for consistency --- script/upgrades/eXOF/Config.sol | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/script/upgrades/eXOF/Config.sol b/script/upgrades/eXOF/Config.sol index 5b9c2319..8b81f06a 100644 --- a/script/upgrades/eXOF/Config.sol +++ b/script/upgrades/eXOF/Config.sol @@ -42,7 +42,7 @@ library eXOFConfig { config.rateFeeds = new Config.RateFeed[](2); config.rateFeeds[0] = config.CELOXOF = CELOXOF_RateFeedConfig(contracts); - config.rateFeeds[1] = config.EURXOF = EUROXOF_RateFeedConfig(contracts); + config.rateFeeds[1] = config.EURXOF = EURXOF_RateFeedConfig(contracts); config.stableTokenXOF = stableTokenXOFConfig(); } @@ -67,7 +67,7 @@ library eXOFConfig { /** * @dev Returns the configuration for the EURXOF rate feed. */ - function EUROXOF_RateFeedConfig( + function EURXOF_RateFeedConfig( Contracts.Cache storage contracts ) internal returns (Config.RateFeed memory rateFeedConfig) { rateFeedConfig.rateFeedID = contracts.dependency("EURXOFRateFeedAddr"); From e0968b052f73d6a32d6c1dc0b734e306a3f62d02 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 13:27:53 -0500 Subject: [PATCH 38/64] refactor: remove duplicate adress references --- script/upgrades/eXOF/eXOF.sol | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index 08f78733..22cf4d4d 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -302,7 +302,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { transactions.push( ICeloGovernance.Transaction( 0, - contracts.deployed("BiPoolManagerProxy"), + biPoolManagerProxy, abi.encodeWithSelector(IBiPoolManager(0).createExchange.selector, pool) ) ); @@ -313,7 +313,6 @@ contract eXOF is IMentoUpgrade, GovernanceScript { * @notice This function creates the transactions to configure the trading limits. */ function proposal_configureTradingLimits(eXOFConfig.eXOF memory config) private { - address brokerProxyAddress = contracts.deployed("BrokerProxy"); for (uint256 i = 0; i < config.pools.length; i++) { Config.Pool memory poolConfig = config.pools[i]; @@ -322,7 +321,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { transactions.push( ICeloGovernance.Transaction( 0, - brokerProxyAddress, + brokerProxy, abi.encodeWithSelector( Broker(0).configureTradingLimit.selector, referenceRateFeedIDToExchangeId[poolConfig.referenceRateFeedID], @@ -345,7 +344,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { transactions.push( ICeloGovernance.Transaction( 0, - brokerProxyAddress, + brokerProxy, abi.encodeWithSelector( Broker(0).configureTradingLimit.selector, referenceRateFeedIDToExchangeId[poolConfig.referenceRateFeedID], From 94b42fda8a57e7e923d02339e0d4ea39edc7c487 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 13:44:35 -0500 Subject: [PATCH 39/64] refactor: remove checks for trading limit config --- script/upgrades/eXOF/eXOF.sol | 80 +++++++++++++++++------------------ 1 file changed, 38 insertions(+), 42 deletions(-) diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index 22cf4d4d..b7a57268 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -316,51 +316,47 @@ contract eXOF is IMentoUpgrade, GovernanceScript { for (uint256 i = 0; i < config.pools.length; i++) { Config.Pool memory poolConfig = config.pools[i]; - if (Config.tradingLimitConfigToFlag(poolConfig.asset0limits) > 0) { - // Set the trading limit for asset0 of the pool - transactions.push( - ICeloGovernance.Transaction( - 0, - brokerProxy, - abi.encodeWithSelector( - Broker(0).configureTradingLimit.selector, - referenceRateFeedIDToExchangeId[poolConfig.referenceRateFeedID], - poolConfig.asset0, - TradingLimits.Config({ - timestep0: poolConfig.asset0limits.timeStep0, - timestep1: poolConfig.asset0limits.timeStep1, - limit0: poolConfig.asset0limits.limit0, - limit1: poolConfig.asset0limits.limit1, - limitGlobal: poolConfig.asset0limits.limitGlobal, - flags: Config.tradingLimitConfigToFlag(poolConfig.asset0limits) - }) - ) + // Set the trading limit for asset0 of the pool + transactions.push( + ICeloGovernance.Transaction( + 0, + brokerProxy, + abi.encodeWithSelector( + Broker(0).configureTradingLimit.selector, + referenceRateFeedIDToExchangeId[poolConfig.referenceRateFeedID], + poolConfig.asset0, + TradingLimits.Config({ + timestep0: poolConfig.asset0limits.timeStep0, + timestep1: poolConfig.asset0limits.timeStep1, + limit0: poolConfig.asset0limits.limit0, + limit1: poolConfig.asset0limits.limit1, + limitGlobal: poolConfig.asset0limits.limitGlobal, + flags: Config.tradingLimitConfigToFlag(poolConfig.asset0limits) + }) ) - ); - } + ) + ); - if (Config.tradingLimitConfigToFlag(poolConfig.asset1limits) > 0) { - // Set the trading limit for asset1 of the pool - transactions.push( - ICeloGovernance.Transaction( - 0, - brokerProxy, - abi.encodeWithSelector( - Broker(0).configureTradingLimit.selector, - referenceRateFeedIDToExchangeId[poolConfig.referenceRateFeedID], - poolConfig.asset1, - TradingLimits.Config({ - timestep0: poolConfig.asset1limits.timeStep0, - timestep1: poolConfig.asset1limits.timeStep1, - limit0: poolConfig.asset1limits.limit0, - limit1: poolConfig.asset1limits.limit1, - limitGlobal: poolConfig.asset1limits.limitGlobal, - flags: Config.tradingLimitConfigToFlag(poolConfig.asset1limits) - }) - ) + // Set the trading limit for asset1 of the pool + transactions.push( + ICeloGovernance.Transaction( + 0, + brokerProxy, + abi.encodeWithSelector( + Broker(0).configureTradingLimit.selector, + referenceRateFeedIDToExchangeId[poolConfig.referenceRateFeedID], + poolConfig.asset1, + TradingLimits.Config({ + timestep0: poolConfig.asset1limits.timeStep0, + timestep1: poolConfig.asset1limits.timeStep1, + limit0: poolConfig.asset1limits.limit0, + limit1: poolConfig.asset1limits.limit1, + limitGlobal: poolConfig.asset1limits.limitGlobal, + flags: Config.tradingLimitConfigToFlag(poolConfig.asset1limits) + }) ) - ); - } + ) + ); } } From 81c50be97986a686de2e9cd93d03afd0cd8ffcc2 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 14:23:47 -0500 Subject: [PATCH 40/64] =?UTF-8?q?refactor:=20end=20the=20cycle=20of=20dupl?= =?UTF-8?q?ication=20=F0=9F=99=85=E2=80=8D=E2=99=82=EF=B8=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- script/interfaces/IERC20Lite.sol | 9 +++++++++ script/upgrades/eXOF/eXOF.sol | 4 ++-- script/upgrades/eXOF/eXOFChecks.base.sol | 18 ++---------------- script/utils/Script.sol | 18 +++++++++++++++++- 4 files changed, 30 insertions(+), 19 deletions(-) create mode 100644 script/interfaces/IERC20Lite.sol diff --git a/script/interfaces/IERC20Lite.sol b/script/interfaces/IERC20Lite.sol new file mode 100644 index 00000000..aacee713 --- /dev/null +++ b/script/interfaces/IERC20Lite.sol @@ -0,0 +1,9 @@ +// SPDX-License-Identifier: GPL-3.0-or-later +pragma solidity ^0.5.13; + +interface IERC20Lite { + /** + * @dev Returns the symbol of the token. + */ + function symbol() external view returns (string memory); +} diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index b7a57268..52dc6a5e 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -112,7 +112,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { // Set the exchange ID for the reference rate feed for (uint i = 0; i < config.pools.length; i++) { - referenceRateFeedIDToExchangeId[config.pools[i].referenceRateFeedID] = getExchangeId( + referenceRateFeedIDToExchangeId[config.pools[i].referenceRateFeedID] = getXOFExchangeId( config.pools[i].asset1, config.pools[i].isConstantSum ); @@ -578,7 +578,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { /** * @notice Helper function to get the exchange ID for a pool. */ - function getExchangeId(address asset1, bool isConstantSum) internal view returns (bytes32) { + function getXOFExchangeId(address asset1, bool isConstantSum) internal view returns (bytes32) { return keccak256( abi.encodePacked("eXOF", IERC20Metadata(asset1).symbol(), isConstantSum ? "ConstantSum" : "ConstantProduct") diff --git a/script/upgrades/eXOF/eXOFChecks.base.sol b/script/upgrades/eXOF/eXOFChecks.base.sol index 1fc4f3f2..be82a447 100644 --- a/script/upgrades/eXOF/eXOFChecks.base.sol +++ b/script/upgrades/eXOF/eXOFChecks.base.sol @@ -7,7 +7,7 @@ import { Test } from "forge-std/Test.sol"; import { PrecompileHandler } from "celo-foundry/PrecompileHandler.sol"; import { IERC20 } from "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol"; -import { Script } from "script/utils/Script.sol"; +import { GovernanceScript } from "script/utils/Script.sol"; import { Chain } from "script/utils/Chain.sol"; import { Arrays } from "script/utils/Arrays.sol"; @@ -39,7 +39,7 @@ import { SortedOracles } from "mento-core-2.2.0/oracles/SortedOracles.sol"; import { eXOFConfig, Config } from "./Config.sol"; -contract eXOFChecksBase is Script, Test { +contract eXOFChecksBase is GovernanceScript, Test { using TradingLimits for TradingLimits.Config; using FixidityLib for FixidityLib.Fraction; using SafeMath for uint256; @@ -102,18 +102,4 @@ contract eXOFChecksBase is Script, Test { biPoolManagerProxy = contracts.deployed("BiPoolManagerProxy"); sortedOracles = contracts.deployed("SortedOracles"); } - - /** - * @notice Helper function to get the exchange ID for a pool. - */ - function getExchangeId(address asset0, address asset1, bool isConstantSum) internal view returns (bytes32) { - return - keccak256( - abi.encodePacked( - IERC20Metadata(asset0).symbol(), - IERC20Metadata(asset1).symbol(), - isConstantSum ? "ConstantSum" : "ConstantProduct" - ) - ); - } } diff --git a/script/utils/Script.sol b/script/utils/Script.sol index a5fe0eaf..5d381fc8 100644 --- a/script/utils/Script.sol +++ b/script/utils/Script.sol @@ -9,6 +9,8 @@ import { Contracts } from "./Contracts.sol"; import { GovernanceHelper } from "./GovernanceHelper.sol"; import { Factory } from "./Factory.sol"; +import { IERC20Lite } from "../interfaces/IERC20Lite.sol"; + contract Script is BaseScript { using Contracts for Contracts.Cache; using FixidityLib for FixidityLib.Fraction; @@ -32,4 +34,18 @@ contract Script is BaseScript { } } -contract GovernanceScript is Script, GovernanceHelper {} +contract GovernanceScript is Script, GovernanceHelper { + /** + * @notice Helper function to get the exchange ID for a pool. + */ + function getExchangeId(address asset0, address asset1, bool isConstantSum) internal view returns (bytes32) { + return + keccak256( + abi.encodePacked( + IERC20Lite(asset0).symbol(), + IERC20Lite(asset1).symbol(), + isConstantSum ? "ConstantSum" : "ConstantProduct" + ) + ); + } +} From 7e8e361e6743a1149c8bac45c02dfbb3a093edd6 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 14:36:09 -0500 Subject: [PATCH 41/64] refactor: rename bridged stable param for clarity --- script/upgrades/eXOF/eXOFChecks.swap.sol | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/script/upgrades/eXOF/eXOFChecks.swap.sol b/script/upgrades/eXOF/eXOFChecks.swap.sol index 982a11ae..9b649d52 100644 --- a/script/upgrades/eXOF/eXOFChecks.swap.sol +++ b/script/upgrades/eXOF/eXOFChecks.swap.sol @@ -177,13 +177,13 @@ contract eXOFChecksSwap is eXOFChecksBase { address tokenOut, uint256 amountIn, address rateFeedID, - bool isBridgedStable + bool isInputTokenBridgedStable ) internal { uint256 amountOut = Broker(broker).getAmountOut(biPoolManagerProxy, exchangeID, tokenIn, tokenOut, amountIn); (uint256 numerator, uint256 denominator) = SortedOracles(sortedOraclesProxy).medianRate(rateFeedID); uint256 estimatedAmountOut; - if (isBridgedStable) { + if (isInputTokenBridgedStable) { estimatedAmountOut = FixidityLib .newFixed(amountIn.mul(1e12)) .multiply(FixidityLib.wrap(numerator).divide(FixidityLib.wrap(denominator))) From 58d717c026c6bdd0753495aaa4bb20568cb8ff93 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 14:48:49 -0500 Subject: [PATCH 42/64] refactor: remove unnecessary code --- script/upgrades/eXOF/eXOFChecks.sol | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/script/upgrades/eXOF/eXOFChecks.sol b/script/upgrades/eXOF/eXOFChecks.sol index 24267900..758d1c72 100644 --- a/script/upgrades/eXOF/eXOFChecks.sol +++ b/script/upgrades/eXOF/eXOFChecks.sol @@ -4,18 +4,12 @@ pragma experimental ABIEncoderV2; import { Test } from "forge-std/Test.sol"; import { Script } from "script/utils/Script.sol"; -import { Contracts } from "script/utils/Contracts.sol"; -import { eXOFChecksBase } from "./eXOFChecks.base.sol"; import { eXOFChecksSwap } from "./eXOFChecks.swap.sol"; import { eXOFChecksVerify } from "./eXOFChecks.verify.sol"; -contract eXOFChecks is eXOFChecksBase { - using Contracts for Contracts.Cache; - +contract eXOFChecks { function run() public { - setUp(); - new eXOFChecksVerify().run(); new eXOFChecksSwap().run(); } From a0f0ac67f87b597cded1f0e6c43dea1d57e366e5 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 14:56:15 -0500 Subject: [PATCH 43/64] refactor: update log message --- script/upgrades/eXOF/eXOFChecks.verify.sol | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol index bc6e909b..6bd2a93f 100644 --- a/script/upgrades/eXOF/eXOFChecks.verify.sol +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -44,6 +44,7 @@ contract eXOFChecksVerify is eXOFChecksBase { function run() public { console.log("\nStarting eXOF checks:"); + console.log("\n== Verifying Token Transactions =="); verifyOwner(); verifyEXOFStableToken(); verifyEXOFAddedToRegistry(); @@ -54,8 +55,6 @@ contract eXOFChecksVerify is eXOFChecksBase { } function verifyOwner() internal view { - console.log("\n== Verifying Token Stuff =="); - address eXOFImplementation = contracts.deployed("StableTokenXOF"); require( StableTokenXOF(eXOFImplementation).owner() == governance, From af47400b600fcbd325a7dfb01e646eec2528442f Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 15:09:10 -0500 Subject: [PATCH 44/64] chore: verify xof proxy ownership transfer --- script/upgrades/eXOF/eXOFChecks.verify.sol | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol index 6bd2a93f..e7bd98f4 100644 --- a/script/upgrades/eXOF/eXOFChecks.verify.sol +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -20,6 +20,7 @@ import { Reserve } from "mento-core-2.2.0/swap/Reserve.sol"; import { BiPoolManager } from "mento-core-2.2.0/swap/BiPoolManager.sol"; import { TradingLimits } from "mento-core-2.2.0/libraries/TradingLimits.sol"; import { BreakerBox } from "mento-core-2.2.0/oracles/BreakerBox.sol"; +import { Proxy } from "mento-core-2.2.0/common/Proxy.sol"; import { eXOFChecksBase } from "./eXOFChecks.base.sol"; import { eXOFConfig, Config } from "./Config.sol"; @@ -60,6 +61,9 @@ contract eXOFChecksVerify is eXOFChecksBase { StableTokenXOF(eXOFImplementation).owner() == governance, "StableTokenXOF ownership not transferred to governance" ); + + require(Proxy(eXOF)._getOwner() == governance, "StableTokenXOF Proxy ownership not transferred to governance"); + require( ValueDeltaBreaker(nonrecoverableValueDeltaBreaker).owner() == governance, "Nonrecoverable Value Delta Breaker ownership not transferred to governance" From 547bd646c9d966c641008285fd9e53bfb40787ee Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 15:10:12 -0500 Subject: [PATCH 45/64] chore: fix typo Co-authored-by: Nelson Taveras --- script/utils/Config.sol | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/utils/Config.sol b/script/utils/Config.sol index 63a69c32..a8b8d519 100644 --- a/script/utils/Config.sol +++ b/script/utils/Config.sol @@ -265,7 +265,7 @@ library Config { */ uint256[] initialBalanceValues; /** - * @dev The identifer of the exchange in the regristry to be used to swap the token. + * @dev The identifer of the exchange in the registry to be used to swap the token. * This is deprecated but should be set to the Broker for tokens created post Mc Mento. */ string exchangeIdentifier; From ab77312422169fc612905c08cb53d8c7b7266568 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 15:14:13 -0500 Subject: [PATCH 46/64] chore: add deprecation comment --- script/utils/Config.sol | 2 ++ 1 file changed, 2 insertions(+) diff --git a/script/utils/Config.sol b/script/utils/Config.sol index a8b8d519..9fea3086 100644 --- a/script/utils/Config.sol +++ b/script/utils/Config.sol @@ -258,10 +258,12 @@ library Config { uint256 inflationFactorUpdatePeriod; /** * @dev The addresses of the initial balance holders for the stable token. + * This is deprecated but is being set for consistency. */ address[] initialBalanceAddresses; /** * @dev The initial balance values for the addresses in the initialBalanceAddresses array. + * This is deprecated but is being set for consistency. */ uint256[] initialBalanceValues; /** From c71d1397d3efd3c2739fb8ed5ef37dbcdfbd4f69 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 15:18:54 -0500 Subject: [PATCH 47/64] refactor: add variable for pre existing pool count --- script/upgrades/eXOF/eXOFChecks.verify.sol | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol index e7bd98f4..f779cefa 100644 --- a/script/upgrades/eXOF/eXOFChecks.verify.sol +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -38,6 +38,8 @@ interface IBrokerWithCasts { contract eXOFChecksVerify is eXOFChecksBase { using TradingLimits for TradingLimits.Config; + uint256 constant PRE_EXISTING_POOLS = 7; + constructor() public { setUp(); } @@ -141,7 +143,7 @@ contract eXOFChecksVerify is eXOFChecksBase { // check configured pools against the config require( - exchanges.length == config.pools.length + 7, + exchanges.length == config.pools.length + PRE_EXISTING_POOLS, "Number of expected pools does not match the number of deployed pools." ); From 1fbd21329b5d6065dd7c046ebe4d50675a576ae1 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 15:49:27 -0500 Subject: [PATCH 48/64] chore: add bridgedEuroC to error message Co-authored-by: Nelson Taveras --- script/upgrades/eXOF/eXOFChecks.verify.sol | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol index f779cefa..e78aebad 100644 --- a/script/upgrades/eXOF/eXOFChecks.verify.sol +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -200,7 +200,7 @@ contract eXOFChecksVerify is eXOFChecksBase { // verify asset1 is always a collateral asset require( pool.asset1 == celoToken || pool.asset1 == bridgedUSDC || pool.asset1 == bridgedEUROC, - "asset1 is not CELO or bridgedUSDC in the exchange" + "asset1 is not CELO or bridgedUSDC or bridgedEUROC in the exchange" ); } console.log("🟢 PoolExchange correctly configured 🤘🏼"); From 97f125c15894f9462750c77834c256110cfe5c78 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 16:05:22 -0500 Subject: [PATCH 49/64] chore: fix typo Co-authored-by: Nelson Taveras --- script/upgrades/eXOF/eXOFChecks.verify.sol | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol index e78aebad..e40b3267 100644 --- a/script/upgrades/eXOF/eXOFChecks.verify.sol +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -438,7 +438,7 @@ contract eXOFChecksVerify is eXOFChecksBase { true ); - // verify refernece value + // verify reference value if (referenceValue != rateFeed.valueDeltaBreaker0.referenceValue) { console.log("ValueDeltaBreaker reference value not set correctly for the rate feed: %s", rateFeed.rateFeedID); revert("ValueDeltaBreaker reference values not set correctly for all rate feeds"); From 8ae3c58a7925b78998da70c870151d1f4ad9a64d Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 16:32:28 -0500 Subject: [PATCH 50/64] refactor: rename pool variables for clarity --- script/upgrades/eXOF/eXOFChecks.verify.sol | 34 +++++++++++----------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol index e40b3267..70ea6710 100644 --- a/script/upgrades/eXOF/eXOFChecks.verify.sol +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -209,52 +209,52 @@ contract eXOFChecksVerify is eXOFChecksBase { function verifyPoolConfig(eXOFConfig.eXOF memory config) internal view { for (uint256 i = 0; i < config.pools.length; i++) { bytes32 exchangeId = getExchangeId(config.pools[i].asset0, config.pools[i].asset1, config.pools[i].isConstantSum); - IBiPoolManager.PoolExchange memory pool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeId); - Config.Pool memory poolConfig = config.pools[i]; + IBiPoolManager.PoolExchange memory deployedPool = BiPoolManager(biPoolManagerProxy).getPoolExchange(exchangeId); + Config.Pool memory expectedPoolConfig = config.pools[i]; - if (pool.config.spread.unwrap() != poolConfig.spread.unwrap()) { + if (deployedPool.config.spread.unwrap() != expectedPoolConfig.spread.unwrap()) { console.log( "The spread of deployed pool: %s does not match the expected spread: %s.", - pool.config.spread.unwrap(), - poolConfig.spread.unwrap() + deployedPool.config.spread.unwrap(), + expectedPoolConfig.spread.unwrap() ); revert("spread of pool does not match the expected spread. See logs."); } - if (pool.config.referenceRateFeedID != poolConfig.referenceRateFeedID) { + if (deployedPool.config.referenceRateFeedID != expectedPoolConfig.referenceRateFeedID) { console.log( "The referenceRateFeedID of deployed pool: %s does not match the expected referenceRateFeedID: %s.", - pool.config.referenceRateFeedID, - poolConfig.referenceRateFeedID + deployedPool.config.referenceRateFeedID, + expectedPoolConfig.referenceRateFeedID ); revert("referenceRateFeedID of pool does not match the expected referenceRateFeedID. See logs."); } - if (pool.config.minimumReports != poolConfig.minimumReports) { + if (deployedPool.config.minimumReports != expectedPoolConfig.minimumReports) { console.log( "The minimumReports of deployed pool: %s does not match the expected minimumReports: %s.", - pool.config.minimumReports, - poolConfig.minimumReports + deployedPool.config.minimumReports, + expectedPoolConfig.minimumReports ); revert("minimumReports of pool does not match the expected minimumReports. See logs."); } - if (pool.config.referenceRateResetFrequency != poolConfig.referenceRateResetFrequency) { + if (deployedPool.config.referenceRateResetFrequency != expectedPoolConfig.referenceRateResetFrequency) { console.log( "The referenceRateResetFrequency of deployed pool: %s does not match the expected: %s.", - pool.config.referenceRateResetFrequency, - poolConfig.referenceRateResetFrequency + deployedPool.config.referenceRateResetFrequency, + expectedPoolConfig.referenceRateResetFrequency ); revert( "referenceRateResetFrequency of pool does not match the expected referenceRateResetFrequency. See logs." ); } - if (pool.config.stablePoolResetSize != poolConfig.stablePoolResetSize) { + if (deployedPool.config.stablePoolResetSize != expectedPoolConfig.stablePoolResetSize) { console.log( "The stablePoolResetSize of deployed pool: %s does not match the expected stablePoolResetSize: %s.", - pool.config.stablePoolResetSize, - poolConfig.stablePoolResetSize + deployedPool.config.stablePoolResetSize, + expectedPoolConfig.stablePoolResetSize ); revert("stablePoolResetSize of pool does not match the expected stablePoolResetSize. See logs."); } From 598d2b0f379e81c8c7b36165b791c8bef80b9e0f Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 16:40:05 -0500 Subject: [PATCH 51/64] refactor: remove usdc from error message --- script/upgrades/eXOF/eXOFChecks.verify.sol | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol index 70ea6710..61ea5e6a 100644 --- a/script/upgrades/eXOF/eXOFChecks.verify.sol +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -496,8 +496,8 @@ contract eXOFChecksVerify is eXOFChecksBase { ) internal view { if (currentThreshold != expectedThreshold) { if (isValueDeltaBreaker) { - console.log("ValueDeltaBreaker rate change threshold not set correctly for USDC/USD rate feed %s", rateFeedID); - revert("ValueDeltaBreaker rate change threshold not set correctly for USDC/USD rate feed"); + console.log("ValueDeltaBreaker rate change threshold not set correctly for rate feed with id %s", rateFeedID); + revert("ValueDeltaBreaker rate change threshold not set correctly for rate feed"); } console.log("MedianDeltaBreaker rate change threshold not set correctly for rate feed %s", rateFeedID); revert("MedianDeltaBreaker rate change threshold not set correctly for all rate feeds"); @@ -512,8 +512,8 @@ contract eXOFChecksVerify is eXOFChecksBase { ) internal view { if (currentCoolDown != expectedCoolDown) { if (isValueDeltaBreaker) { - console.log("ValueDeltaBreaker cooldown not set correctly for USDC/USD rate feed %s", rateFeedID); - revert("ValueDeltaBreaker cooldown not set correctly for USDC/USD rate feed"); + console.log("ValueDeltaBreaker cooldown not set correctly for rate feed with id %s", rateFeedID); + revert("ValueDeltaBreaker cooldown not set correctly for rate feed"); } console.log("MedianDeltaBreaker cooldown not set correctly for rate feed %s", rateFeedID); revert("MedianDeltaBreaker cooldown not set correctly for all rate feeds"); From 3765e3b0bdc178deeba92f6b89854ecd0e9ab0e5 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Thu, 31 Aug 2023 16:40:33 -0500 Subject: [PATCH 52/64] chore: fix typo Co-authored-by: Nelson Taveras --- script/upgrades/eXOF/eXOFChecks.verify.sol | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol index 61ea5e6a..2388b292 100644 --- a/script/upgrades/eXOF/eXOFChecks.verify.sol +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -473,7 +473,7 @@ contract eXOFChecksVerify is eXOFChecksBase { true ); - // verify refernece value + // verify reference value if (referenceValue != rateFeed.valueDeltaBreaker1.referenceValue) { console.log( "Nonrecoverable ValueDeltaBreaker reference value not set correctly for the rate feed: %s", From ff39cbc9b96bd8a3de626948b0abf6ec1ba88309 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Fri, 1 Sep 2023 11:39:55 -0500 Subject: [PATCH 53/64] feat: verify constitution params --- script/interfaces/ICeloGovernance.sol | 9 +++++ script/upgrades/eXOF/Config.sol | 14 ++++++- script/upgrades/eXOF/eXOF.sol | 26 +++--------- script/upgrades/eXOF/eXOFChecks.verify.sol | 47 ++++++++++++++++++++-- script/utils/Config.sol | 15 +++++++ 5 files changed, 86 insertions(+), 25 deletions(-) diff --git a/script/interfaces/ICeloGovernance.sol b/script/interfaces/ICeloGovernance.sol index f9c1e4f0..99d77e19 100644 --- a/script/interfaces/ICeloGovernance.sol +++ b/script/interfaces/ICeloGovernance.sol @@ -19,4 +19,13 @@ interface ICeloGovernance { ) external payable returns (uint256); function setConstitution(address destination, bytes4 functionId, uint256 threshold) external; + + /** + * @notice Returns the constitution for a particular destination and function ID. + * @param destination The destination address to get the constitution for. + * @param functionId The function ID to get the constitution for, zero for the destination + * default. + * @return The ratio of yes:no votes needed to exceed in order to pass the proposal. + */ + function getConstitution(address destination, bytes4 functionId) external view returns (uint256); } diff --git a/script/upgrades/eXOF/Config.sol b/script/upgrades/eXOF/Config.sol index 8b81f06a..efbcc7c2 100644 --- a/script/upgrades/eXOF/Config.sol +++ b/script/upgrades/eXOF/Config.sol @@ -176,6 +176,16 @@ library eXOFConfig { * @dev Returns the configuration for the eXOF stable token. */ function stableTokenXOFConfig() internal pure returns (Config.StableToken memory config) { + bytes4[] memory functionSelectors = Arrays.bytes4s( + Config.getSelector("setRegistry(address)"), + Config.getSelector("setInflationParameters(uint256,uint256)"), + Config.getSelector("transfer(address,uint256)"), + Config.getSelector("transferWithComment(address,uint256,string)"), + Config.getSelector("approve(address,uint256)") + ); + + uint256[] memory thresholds = Arrays.uints(0.9 * 1e24, 0.6 * 1e24, 0.6 * 1e24, 0.6 * 1e24, 0.6 * 1e24); + config = Config.StableToken({ name: "ECO CFA", symbol: "eXOF", @@ -185,7 +195,9 @@ library eXOFConfig { inflationFactorUpdatePeriod: 47304000, initialBalanceAddresses: new address[](0), initialBalanceValues: new uint256[](0), - exchangeIdentifier: "Broker" + exchangeIdentifier: "Broker", + constitutionFunctionSelectors: functionSelectors, + constitutionThresholds: thresholds }); } } diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index 52dc6a5e..59cecad9 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -137,7 +137,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { proposal_initializeEXOFToken(config); proposal_addEXOFToCeloRegistry(); - proposal_configureEXOFConstitutionParameters(); + proposal_configureEXOFConstitutionParameters(config.stableTokenXOF); proposal_addEXOFToReserves(); proposal_enableGasPaymentsWithEXOF(); @@ -245,19 +245,10 @@ contract eXOF is IMentoUpgrade, GovernanceScript { * @notice configure eXOF constitution parameters * @dev see cBRl GCP(https://celo.stake.id/#/proposal/49) for reference */ - function proposal_configureEXOFConstitutionParameters() private { - bytes4[] memory functionSelectors = Arrays.bytes4s( - getSelector("setRegistry(address)"), - getSelector("setInflationParameters(uint256,uint256)"), - getSelector("transfer(address,uint256)"), - getSelector("transferWithComment(address,uint256,string)"), - getSelector("approve(address,uint256)") - ); - uint256[] memory thresholds = Arrays.uints(0.9 * 1e24, 0.6 * 1e24, 0.6 * 1e24, 0.6 * 1e24, 0.6 * 1e24); - + function proposal_configureEXOFConstitutionParameters(Config.StableToken memory stableTokenConfig) private { address governanceProxy = contracts.celoRegistry("Governance"); - for (uint256 i = 0; i < functionSelectors.length; i++) { + for (uint256 i = 0; i < stableTokenConfig.constitutionFunctionSelectors.length; i++) { transactions.push( ICeloGovernance.Transaction( 0, @@ -265,8 +256,8 @@ contract eXOF is IMentoUpgrade, GovernanceScript { abi.encodeWithSelector( ICeloGovernance(0).setConstitution.selector, eXOFProxy, - functionSelectors[i], - thresholds[i] + stableTokenConfig.constitutionFunctionSelectors[i], + stableTokenConfig.constitutionThresholds[i] ) ) ); @@ -584,11 +575,4 @@ contract eXOF is IMentoUpgrade, GovernanceScript { abi.encodePacked("eXOF", IERC20Metadata(asset1).symbol(), isConstantSum ? "ConstantSum" : "ConstantProduct") ); } - - /** - * @notice Helper function to get the function selector for a function. - */ - function getSelector(string memory _func) internal pure returns (bytes4) { - return bytes4(keccak256(bytes(_func))); - } } diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol index 2388b292..976f55a0 100644 --- a/script/upgrades/eXOF/eXOFChecks.verify.sol +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -7,6 +7,7 @@ import { console2 as console } from "forge-std/Script.sol"; import { Arrays } from "script/utils/Arrays.sol"; import { IFeeCurrencyWhitelist } from "script/interfaces/IFeeCurrencyWhitelist.sol"; +import { ICeloGovernance } from "script/interfaces/ICeloGovernance.sol"; import { IRegistry } from "mento-core-2.2.0/common/interfaces/IRegistry.sol"; import { IBiPoolManager } from "mento-core-2.2.0/interfaces/IBiPoolManager.sol"; @@ -40,8 +41,11 @@ contract eXOFChecksVerify is eXOFChecksBase { uint256 constant PRE_EXISTING_POOLS = 7; + ICeloGovernance celoGovernance; + constructor() public { setUp(); + celoGovernance = ICeloGovernance(governance); } function run() public { @@ -50,6 +54,7 @@ contract eXOFChecksVerify is eXOFChecksBase { console.log("\n== Verifying Token Transactions =="); verifyOwner(); verifyEXOFStableToken(); + verifyConstitution(); verifyEXOFAddedToRegistry(); verifyEXOFAddedToReserves(); verifyEXOFAddedToFeeCurrencyWhitelist(); @@ -128,10 +133,39 @@ contract eXOFChecksVerify is eXOFChecksBase { console.log("🟢 eXOF has been added to the fee currency whitelist"); } - function verifyExchanges() internal { + function verifyConstitution() internal { eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); + bytes4[] memory functionSelectors = config.stableTokenXOF.constitutionFunctionSelectors; + uint256[] memory expectedThresholdValues = config.stableTokenXOF.constitutionThresholds; + + for (uint256 i = 0; i < functionSelectors.length; i++) { + bytes4 selector = functionSelectors[i]; + uint256 expectedValue = expectedThresholdValues[i]; + + checkConstitutionParam(selector, expectedValue); + } + + console.log("🟢 Constitution params configured correctly"); + } + + function checkConstitutionParam(bytes4 functionSelector, uint256 expectedValue) internal view { + uint256 actualConstitutionValue = celoGovernance.getConstitution(eXOF, functionSelector); + + if (actualConstitutionValue != expectedValue) { + console.log( + "The constitution value for function selector: %s is not set correctly. Expected: %s, Actual: %s", + bytes4ToStr(functionSelector), + expectedValue, + actualConstitutionValue + ); + revert("Constitution value not set correctly. See logs."); + } + } + + function verifyExchanges() internal { console.log("\n== Verifying exchanges =="); + eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); verifyPoolExchange(config); verifyPoolConfig(config); @@ -320,9 +354,8 @@ contract eXOFChecksVerify is eXOFChecksBase { /* ================================================================ */ function verifyCircuitBreaker() internal { - eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); - console.log("\n== Checking circuit breaker =="); + eXOFConfig.eXOF memory config = eXOFConfig.get(contracts); verifyBreakerBox(config); verifyBreakersAreEnabled(config); @@ -519,4 +552,12 @@ contract eXOFChecksVerify is eXOFChecksBase { revert("MedianDeltaBreaker cooldown not set correctly for all rate feeds"); } } + + function bytes4ToStr(bytes4 _bytes) public pure returns (string memory) { + bytes memory bytesArray = new bytes(4); + for (uint256 i; i < 4; i++) { + bytesArray[i] = _bytes[i]; + } + return string(bytesArray); + } } diff --git a/script/utils/Config.sol b/script/utils/Config.sol index 9fea3086..26075ad2 100644 --- a/script/utils/Config.sol +++ b/script/utils/Config.sol @@ -271,6 +271,14 @@ library Config { * This is deprecated but should be set to the Broker for tokens created post Mc Mento. */ string exchangeIdentifier; + /** + * @dev An array of function selectors for the constitution functions. + */ + bytes4[] constitutionFunctionSelectors; + /** + * @dev An array of thresholds for the corresponding constitution functions. + */ + uint256[] constitutionThresholds; } /** @@ -299,4 +307,11 @@ library Config { } return flag; } + + /** + * @notice Helper function to get the function selector for a function. + */ + function getSelector(string memory _func) internal pure returns (bytes4) { + return bytes4(keccak256(bytes(_func))); + } } From 724f67ab60ae309a68f9dc337b021546bfa30be7 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Mon, 4 Sep 2023 10:57:57 -0500 Subject: [PATCH 54/64] refactor: do not add exof to reserve --- script/upgrades/eXOF/eXOF.sol | 17 ++--------------- script/upgrades/eXOF/eXOFChecks.verify.sol | 10 +++------- 2 files changed, 5 insertions(+), 22 deletions(-) diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index 59cecad9..0f6a8654 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -138,7 +138,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { proposal_initializeEXOFToken(config); proposal_addEXOFToCeloRegistry(); proposal_configureEXOFConstitutionParameters(config.stableTokenXOF); - proposal_addEXOFToReserves(); + proposal_addEXOFToReserve(); proposal_enableGasPaymentsWithEXOF(); proposal_createExchanges(config); @@ -200,7 +200,7 @@ contract eXOF is IMentoUpgrade, GovernanceScript { /** * @notice adds eXOF token to the partial and main reserve */ - function proposal_addEXOFToReserves() private { + function proposal_addEXOFToReserve() private { if (IReserve(partialReserveProxy).isStableAsset(eXOFProxy) == false) { transactions.push( ICeloGovernance.Transaction( @@ -212,19 +212,6 @@ contract eXOF is IMentoUpgrade, GovernanceScript { } else { console.log("Token already added to the partial reserve, skipping: %s", eXOFProxy); } - - address mainReserveProxy = contracts.celoRegistry("Reserve"); - if (IReserve(mainReserveProxy).isStableAsset(eXOFProxy) == false) { - transactions.push( - ICeloGovernance.Transaction( - 0, - mainReserveProxy, - abi.encodeWithSelector(IReserve(0).addToken.selector, eXOFProxy) - ) - ); - } else { - console.log("Token already added to the main reserve, skipping: %s", eXOFProxy); - } } /** diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol index 976f55a0..e3293520 100644 --- a/script/upgrades/eXOF/eXOFChecks.verify.sol +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -56,7 +56,7 @@ contract eXOFChecksVerify is eXOFChecksBase { verifyEXOFStableToken(); verifyConstitution(); verifyEXOFAddedToRegistry(); - verifyEXOFAddedToReserves(); + verifyEXOFAddedToReserve(); verifyEXOFAddedToFeeCurrencyWhitelist(); verifyExchanges(); verifyCircuitBreaker(); @@ -110,16 +110,12 @@ contract eXOFChecksVerify is eXOFChecksBase { console.log("🟢 eXOF has been added to the registry"); } - function verifyEXOFAddedToReserves() internal view { + function verifyEXOFAddedToReserve() internal view { if (!Reserve(address(uint160(partialReserve))).isStableAsset(eXOF)) { revert("eXOF has not been added to the partial reserve."); } - if (!Reserve(address(uint160(reserve))).isStableAsset(eXOF)) { - revert("eXOF has not been added to the reserve."); - } - - console.log("🟢 eXOF has been added to the reserves"); + console.log("🟢 eXOF has been added to the reserve"); } function verifyEXOFAddedToFeeCurrencyWhitelist() internal view { From 66f76140bb1790e14f0c4f2908b6e3f26d34a8ef Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Mon, 4 Sep 2023 11:16:35 -0500 Subject: [PATCH 55/64] chore: switch to just compliation build mode --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9452aa86..bfc3856a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -52,4 +52,4 @@ jobs: - name: "Build the contracts" run: | forge --version - forge build --sizes + forge build From 1a272a0b0c32a18608817475924c41b0f1360649 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Mon, 4 Sep 2023 18:52:17 -0500 Subject: [PATCH 56/64] chore: revert size mode change --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bfc3856a..9452aa86 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -52,4 +52,4 @@ jobs: - name: "Build the contracts" run: | forge --version - forge build + forge build --sizes From 513259373ccb22062094a753c2d886a290ebf7d2 Mon Sep 17 00:00:00 2001 From: Bayological <6872903+bayological@users.noreply.github.com> Date: Mon, 4 Sep 2023 18:56:57 -0500 Subject: [PATCH 57/64] refactor: exclude exof checks from size check --- script/upgrades/eXOF/eXOFChecks.sol | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/script/upgrades/eXOF/eXOFChecks.sol b/script/upgrades/eXOF/eXOFChecks.sol index 758d1c72..9ca933d1 100644 --- a/script/upgrades/eXOF/eXOFChecks.sol +++ b/script/upgrades/eXOF/eXOFChecks.sol @@ -1,14 +1,12 @@ // SPDX-License-Identifier: GPL-3.0-or-later pragma solidity ^0.5.13; -pragma experimental ABIEncoderV2; import { Test } from "forge-std/Test.sol"; -import { Script } from "script/utils/Script.sol"; import { eXOFChecksSwap } from "./eXOFChecks.swap.sol"; import { eXOFChecksVerify } from "./eXOFChecks.verify.sol"; -contract eXOFChecks { +contract eXOFChecks is Test { function run() public { new eXOFChecksVerify().run(); new eXOFChecksSwap().run(); From 2b1076652f63fe22a400bd6e8d81e683969c17df Mon Sep 17 00:00:00 2001 From: Nelson Taveras Date: Tue, 5 Sep 2023 11:38:25 +0200 Subject: [PATCH 58/64] chore: remove set smoothing factor tx --- script/upgrades/eXOF/eXOF.sol | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/script/upgrades/eXOF/eXOF.sol b/script/upgrades/eXOF/eXOF.sol index 0f6a8654..29adcdd4 100644 --- a/script/upgrades/eXOF/eXOF.sol +++ b/script/upgrades/eXOF/eXOF.sol @@ -453,18 +453,6 @@ contract eXOF is IMentoUpgrade, GovernanceScript { ) ) ); - // Set ema smoothing factor - transactions.push( - ICeloGovernance.Transaction( - 0, - medianDeltaBreaker, - abi.encodeWithSelector( - MedianDeltaBreaker(0).setSmoothingFactor.selector, - config.CELOXOF.rateFeedID, - config.CELOXOF.medianDeltaBreaker0.smoothingFactor - ) - ) - ); } /** From e98db343abe6d51902a05c12ddd0b1b94bf19d0a Mon Sep 17 00:00:00 2001 From: Nelson Taveras Date: Tue, 5 Sep 2023 11:41:10 +0200 Subject: [PATCH 59/64] chore: line breaks between the different checks groups --- script/upgrades/eXOF/eXOFChecks.verify.sol | 2 ++ 1 file changed, 2 insertions(+) diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol index e3293520..2fba20e9 100644 --- a/script/upgrades/eXOF/eXOFChecks.verify.sol +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -58,7 +58,9 @@ contract eXOFChecksVerify is eXOFChecksBase { verifyEXOFAddedToRegistry(); verifyEXOFAddedToReserve(); verifyEXOFAddedToFeeCurrencyWhitelist(); + verifyExchanges(); + verifyCircuitBreaker(); } From 39ec10c2ffbcf2a3da8fc2c5dfea48fec610bac5 Mon Sep 17 00:00:00 2001 From: Nelson Taveras Date: Tue, 5 Sep 2023 14:31:46 +0200 Subject: [PATCH 60/64] fix: update reference rate for valuedeltabreaker0 Co-authored-by: Nadiem Sissouno <53600650+sissnad@users.noreply.github.com> --- script/upgrades/eXOF/Config.sol | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/upgrades/eXOF/Config.sol b/script/upgrades/eXOF/Config.sol index efbcc7c2..6b762bd2 100644 --- a/script/upgrades/eXOF/Config.sol +++ b/script/upgrades/eXOF/Config.sol @@ -74,7 +74,7 @@ library eXOFConfig { rateFeedConfig.valueDeltaBreaker0 = Config.ValueDeltaBreaker({ enabled: true, threshold: FixidityLib.newFixedFraction(5, 1000), // 0.005 - referenceValue: 656.55 * 10 ** 24, // TODO: verify + referenceValue: 655.957 * 10 ** 24, cooldown: 15 minutes }); From 024d30046dd121ed86d9a4bccc354a272b211f1b Mon Sep 17 00:00:00 2001 From: Nelson Taveras Date: Tue, 5 Sep 2023 14:31:59 +0200 Subject: [PATCH 61/64] fix: update reference rate for valuedeltabreaker1 Co-authored-by: Nadiem Sissouno <53600650+sissnad@users.noreply.github.com> --- script/upgrades/eXOF/Config.sol | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/upgrades/eXOF/Config.sol b/script/upgrades/eXOF/Config.sol index 6b762bd2..d09a851f 100644 --- a/script/upgrades/eXOF/Config.sol +++ b/script/upgrades/eXOF/Config.sol @@ -81,7 +81,7 @@ library eXOFConfig { rateFeedConfig.valueDeltaBreaker1 = Config.ValueDeltaBreaker({ enabled: true, threshold: FixidityLib.newFixedFraction(10, 100), // 0.10 - referenceValue: 656.55 * 10 ** 24, // TODO: verify + referenceValue: 655.957 * 10 ** 24, cooldown: 0 seconds }); rateFeedConfig.dependentRateFeeds = Arrays.addresses(contracts.dependency("EUROCEURRateFeedAddr")); From b5266f5332a597924d5e45e82300b981bb6efcf0 Mon Sep 17 00:00:00 2001 From: Nelson Taveras Date: Tue, 5 Sep 2023 15:02:47 +0200 Subject: [PATCH 62/64] chore: prettier --- script/upgrades/eXOF/Config.sol | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/upgrades/eXOF/Config.sol b/script/upgrades/eXOF/Config.sol index d09a851f..2911c6f1 100644 --- a/script/upgrades/eXOF/Config.sol +++ b/script/upgrades/eXOF/Config.sol @@ -74,7 +74,7 @@ library eXOFConfig { rateFeedConfig.valueDeltaBreaker0 = Config.ValueDeltaBreaker({ enabled: true, threshold: FixidityLib.newFixedFraction(5, 1000), // 0.005 - referenceValue: 655.957 * 10 ** 24, + referenceValue: 655.957 * 10 ** 24, cooldown: 15 minutes }); From 43d6531699733a363529496b401a0d2f34d6ade9 Mon Sep 17 00:00:00 2001 From: Nelson Taveras Date: Tue, 5 Sep 2023 15:12:28 +0200 Subject: [PATCH 63/64] feat: add EUROC/EUR dependency to CELOXOF feed --- script/upgrades/eXOF/Config.sol | 3 ++- script/upgrades/eXOF/eXOFChecks.verify.sol | 7 +++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/script/upgrades/eXOF/Config.sol b/script/upgrades/eXOF/Config.sol index 2911c6f1..be0109aa 100644 --- a/script/upgrades/eXOF/Config.sol +++ b/script/upgrades/eXOF/Config.sol @@ -54,7 +54,7 @@ library eXOFConfig { */ function CELOXOF_RateFeedConfig( Contracts.Cache storage contracts - ) internal view returns (Config.RateFeed memory rateFeedConfig) { + ) internal returns (Config.RateFeed memory rateFeedConfig) { rateFeedConfig.rateFeedID = contracts.deployed("StableTokenXOFProxy"); rateFeedConfig.medianDeltaBreaker0 = Config.MedianDeltaBreaker({ enabled: true, @@ -62,6 +62,7 @@ library eXOFConfig { cooldown: 30 minutes, smoothingFactor: 0 }); + rateFeedConfig.dependentRateFeeds = Arrays.addresses(contracts.dependency("EUROCEURRateFeedAddr")); } /** diff --git a/script/upgrades/eXOF/eXOFChecks.verify.sol b/script/upgrades/eXOF/eXOFChecks.verify.sol index 2fba20e9..d0cd185a 100644 --- a/script/upgrades/eXOF/eXOFChecks.verify.sol +++ b/script/upgrades/eXOF/eXOFChecks.verify.sol @@ -376,6 +376,13 @@ contract eXOFChecksVerify is eXOFChecksBase { EUROCXOFDependency == config.EURXOF.dependentRateFeeds[0], "EUROC/XOF rate feed dependency not set correctly" ); + + address CELOXOFDependency = BreakerBox(breakerBox).rateFeedDependencies(config.CELOXOF.rateFeedID, 0); + require( + CELOXOFDependency == config.CELOXOF.dependentRateFeeds[0], + "CELO/XOF rate feed dependency not set correctly" + ); + console.log("🟢 Rate feed dependencies configured correctly 🗳️"); } From da68e08b850b90e27ad0303cf29543391605ff2b Mon Sep 17 00:00:00 2001 From: Nelson Taveras Date: Tue, 5 Sep 2023 15:16:31 +0200 Subject: [PATCH 64/64] fix: CELOXOF dependency should be EURXOF and not EUROCEUR --- script/upgrades/eXOF/Config.sol | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/upgrades/eXOF/Config.sol b/script/upgrades/eXOF/Config.sol index be0109aa..8f351541 100644 --- a/script/upgrades/eXOF/Config.sol +++ b/script/upgrades/eXOF/Config.sol @@ -62,7 +62,7 @@ library eXOFConfig { cooldown: 30 minutes, smoothingFactor: 0 }); - rateFeedConfig.dependentRateFeeds = Arrays.addresses(contracts.dependency("EUROCEURRateFeedAddr")); + rateFeedConfig.dependentRateFeeds = Arrays.addresses(contracts.dependency("EURXOFRateFeedAddr")); } /**