From 44dac0407e5c3e448486437e2cc892cbed1400e9 Mon Sep 17 00:00:00 2001 From: sakulstra Date: Mon, 6 Nov 2023 19:29:13 +0100 Subject: [PATCH 01/14] feat: update stable debt token implementations --- generator/templates/aip.template.ts | 11 +- ...V2Ethereum_DebtTokenUpdates_20231106.t.sol | 27 ++++ ...V3Arbitrum_DebtTokenUpdates_20231106.t.sol | 27 ++++ ...3Avalanche_DebtTokenUpdates_20231106.t.sol | 31 ++++ ...V3Optimism_DebtTokenUpdates_20231106.t.sol | 27 ++++ ...eV3Polygon_DebtTokenUpdates_20231106.t.sol | 27 ++++ .../DebtTokenUpdates.md | 36 +++++ .../DebtTokenUpdates_20231106.s.sol | 134 ++++++++++++++++++ .../config.json | 59 ++++++++ 9 files changed, 376 insertions(+), 3 deletions(-) create mode 100644 src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.t.sol create mode 100644 src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.t.sol create mode 100644 src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.t.sol create mode 100644 src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.t.sol create mode 100644 src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.t.sol create mode 100644 src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md create mode 100644 src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol create mode 100644 src/20231106_Multi_DebtTokenUpdates/config.json diff --git a/generator/templates/aip.template.ts b/generator/templates/aip.template.ts index 3c1ac00a6..25eff0a65 100644 --- a/generator/templates/aip.template.ts +++ b/generator/templates/aip.template.ts @@ -14,9 +14,14 @@ discussions: ${`"${options.discussion}"` || 'TODO'} ## Specification -${Object.keys(configs).map((pool) => { - return configs[pool].artifacts.filter((artifact) => artifact.aip).map((artifact) => artifact.aip); -})} +${Object.keys(configs) + .map((pool) => { + return configs[pool].artifacts + .filter((artifact) => artifact.aip) + .map((artifact) => artifact.aip); + }) + .filter((a) => a) + .join('\n\n')} ## References diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.t.sol new file mode 100644 index 000000000..702c31ae8 --- /dev/null +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.t.sol @@ -0,0 +1,27 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {AaveV2Ethereum} from 'aave-address-book/AaveV2Ethereum.sol'; + +import 'forge-std/Test.sol'; +import {ProtocolV2TestBase, ReserveConfig} from 'aave-helpers/ProtocolV2TestBase.sol'; +import {AaveV2Ethereum_DebtTokenUpdates_20231106} from './AaveV2Ethereum_DebtTokenUpdates_20231106.sol'; + +/** + * @dev Test for AaveV2Ethereum_DebtTokenUpdates_20231106 + * command: make test-contract filter=AaveV2Ethereum_DebtTokenUpdates_20231106 + */ +contract AaveV2Ethereum_DebtTokenUpdates_20231106_Test is ProtocolV2TestBase { + address internal proposal = address(0); + + function setUp() public { + vm.createSelectFork(vm.rpcUrl('mainnet'), 18514639); + } + + /** + * @dev executes the generic test suite including e2e and config snapshots + */ + function test_defaultProposalExecution() public { + defaultTest('AaveV2Ethereum_DebtTokenUpdates_20231106', AaveV2Ethereum.POOL, address(proposal)); + } +} diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.t.sol new file mode 100644 index 000000000..78dc9ce38 --- /dev/null +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.t.sol @@ -0,0 +1,27 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {AaveV3Arbitrum} from 'aave-address-book/AaveV3Arbitrum.sol'; + +import 'forge-std/Test.sol'; +import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/ProtocolV3TestBase.sol'; +import {AaveV3Arbitrum_DebtTokenUpdates_20231106} from './AaveV3Arbitrum_DebtTokenUpdates_20231106.sol'; + +/** + * @dev Test for AaveV3Arbitrum_DebtTokenUpdates_20231106 + * command: make test-contract filter=AaveV3Arbitrum_DebtTokenUpdates_20231106 + */ +contract AaveV3Arbitrum_DebtTokenUpdates_20231106_Test is ProtocolV3TestBase { + address internal proposal = address(0); + + function setUp() public { + vm.createSelectFork(vm.rpcUrl('arbitrum'), 147772611); + } + + /** + * @dev executes the generic test suite including e2e and config snapshots + */ + function test_defaultProposalExecution() public { + defaultTest('AaveV3Arbitrum_DebtTokenUpdates_20231106', AaveV3Arbitrum.POOL, address(proposal)); + } +} diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.t.sol new file mode 100644 index 000000000..93c600efa --- /dev/null +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.t.sol @@ -0,0 +1,31 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {AaveV3Avalanche} from 'aave-address-book/AaveV3Avalanche.sol'; + +import 'forge-std/Test.sol'; +import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/ProtocolV3TestBase.sol'; +import {AaveV3Avalanche_DebtTokenUpdates_20231106} from './AaveV3Avalanche_DebtTokenUpdates_20231106.sol'; + +/** + * @dev Test for AaveV3Avalanche_DebtTokenUpdates_20231106 + * command: make test-contract filter=AaveV3Avalanche_DebtTokenUpdates_20231106 + */ +contract AaveV3Avalanche_DebtTokenUpdates_20231106_Test is ProtocolV3TestBase { + address internal proposal = address(0); + + function setUp() public { + vm.createSelectFork(vm.rpcUrl('avalanche'), 37419951); + } + + /** + * @dev executes the generic test suite including e2e and config snapshots + */ + function test_defaultProposalExecution() public { + defaultTest( + 'AaveV3Avalanche_DebtTokenUpdates_20231106', + AaveV3Avalanche.POOL, + address(proposal) + ); + } +} diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.t.sol new file mode 100644 index 000000000..b2c70b0a8 --- /dev/null +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.t.sol @@ -0,0 +1,27 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {AaveV3Optimism} from 'aave-address-book/AaveV3Optimism.sol'; + +import 'forge-std/Test.sol'; +import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/ProtocolV3TestBase.sol'; +import {AaveV3Optimism_DebtTokenUpdates_20231106} from './AaveV3Optimism_DebtTokenUpdates_20231106.sol'; + +/** + * @dev Test for AaveV3Optimism_DebtTokenUpdates_20231106 + * command: make test-contract filter=AaveV3Optimism_DebtTokenUpdates_20231106 + */ +contract AaveV3Optimism_DebtTokenUpdates_20231106_Test is ProtocolV3TestBase { + address internal proposal = address(0); + + function setUp() public { + vm.createSelectFork(vm.rpcUrl('optimism'), 111847755); + } + + /** + * @dev executes the generic test suite including e2e and config snapshots + */ + function test_defaultProposalExecution() public { + defaultTest('AaveV3Optimism_DebtTokenUpdates_20231106', AaveV3Optimism.POOL, address(proposal)); + } +} diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.t.sol new file mode 100644 index 000000000..5bab9ee8c --- /dev/null +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.t.sol @@ -0,0 +1,27 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {AaveV3Polygon} from 'aave-address-book/AaveV3Polygon.sol'; + +import 'forge-std/Test.sol'; +import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/ProtocolV3TestBase.sol'; +import {AaveV3Polygon_DebtTokenUpdates_20231106} from './AaveV3Polygon_DebtTokenUpdates_20231106.sol'; + +/** + * @dev Test for AaveV3Polygon_DebtTokenUpdates_20231106 + * command: make test-contract filter=AaveV3Polygon_DebtTokenUpdates_20231106 + */ +contract AaveV3Polygon_DebtTokenUpdates_20231106_Test is ProtocolV3TestBase { + address internal proposal = address(0); + + function setUp() public { + vm.createSelectFork(vm.rpcUrl('polygon'), 49622312); + } + + /** + * @dev executes the generic test suite including e2e and config snapshots + */ + function test_defaultProposalExecution() public { + defaultTest('AaveV3Polygon_DebtTokenUpdates_20231106', AaveV3Polygon.POOL, address(proposal)); + } +} diff --git a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md new file mode 100644 index 000000000..453fb1842 --- /dev/null +++ b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md @@ -0,0 +1,36 @@ +--- +title: "Debt Token Updates" +author: "BGD Labs" +discussions: "https://governance.aave.com/t/aave-v2-v3-security-incident-04-11-2023/15335/26" +--- + +## Simple Summary + +This proposal updates the stable borrow implementations for all tokens that have stable debt across all pools on all networks. +The implementation will effectively stop minting new stable debt tokens. + +## Motivation + +In response to an attack vector reported by a white-hat, some immediate steps where taken to protect the Aave Markets by pausing, freezing and disable stable borrowing on the affected assets. + +Upon further investigation it turned out to be necessary to also prevent new minting of StableDebt. + +## Specification + +On AaveV2Ethereum the proposal will call: + +- `AaveV2Ethereum.POOL_CONFIGURATOR.updateStableDebtToken(underlyingAsset,newSTokenImpl);` + +On AaveV3Arbitrum, AaveV3Optimism, AaveV3Avalanche, AaveV3Polygon the proposal will call: + +- `POOL_CONFIGURATOR.updateStableDebtToken(input);` + +## References + +- Implementation: [AaveV2Ethereum](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.sol), [AaveV3Polygon](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.sol), [AaveV3Avalanche](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.sol), [AaveV3Optimism](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.sol), [AaveV3Arbitrum](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.sol) +- Tests: [AaveV2Ethereum](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.t.sol), [AaveV3Polygon](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.t.sol), [AaveV3Avalanche](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.t.sol), [AaveV3Optimism](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.t.sol), [AaveV3Arbitrum](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.t.sol) +- [Discussion](https://governance.aave.com/t/aave-v2-v3-security-incident-04-11-2023/15335/26) + +## Copyright + +Copyright and related rights waived via [CC0](https://creativecommons.org/publicdomain/zero/1.0/). diff --git a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol new file mode 100644 index 000000000..812141605 --- /dev/null +++ b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol @@ -0,0 +1,134 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {GovV3Helpers, IPayloadsControllerCore, PayloadsControllerUtils} from 'aave-helpers/GovV3Helpers.sol'; +import {EthereumScript, PolygonScript, AvalancheScript, OptimismScript, ArbitrumScript} from 'aave-helpers/ScriptUtils.sol'; +import {AaveV2Ethereum_DebtTokenUpdates_20231106} from './AaveV2Ethereum_DebtTokenUpdates_20231106.sol'; +import {AaveV3Polygon_DebtTokenUpdates_20231106} from './AaveV3Polygon_DebtTokenUpdates_20231106.sol'; +import {AaveV3Avalanche_DebtTokenUpdates_20231106} from './AaveV3Avalanche_DebtTokenUpdates_20231106.sol'; +import {AaveV3Optimism_DebtTokenUpdates_20231106} from './AaveV3Optimism_DebtTokenUpdates_20231106.sol'; +import {AaveV3Arbitrum_DebtTokenUpdates_20231106} from './AaveV3Arbitrum_DebtTokenUpdates_20231106.sol'; + +/** + * @dev Deploy Ethereum + * command: make deploy-ledger contract=src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol:DeployEthereum chain=mainnet + */ +contract DeployEthereum is EthereumScript { + function run() external broadcast { + // compose action + IPayloadsControllerCore.ExecutionAction[] + memory actions = new IPayloadsControllerCore.ExecutionAction[](1); + actions[0] = GovV3Helpers.buildAction(address(payload0)); + + // register action at payloadsController + GovV3Helpers.createPayload(actions); + } +} + +/** + * @dev Deploy Polygon + * command: make deploy-ledger contract=src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol:DeployPolygon chain=polygon + */ +contract DeployPolygon is PolygonScript { + function run() external broadcast { + // compose action + IPayloadsControllerCore.ExecutionAction[] + memory actions = new IPayloadsControllerCore.ExecutionAction[](1); + actions[0] = GovV3Helpers.buildAction(address(payload0)); + + // register action at payloadsController + GovV3Helpers.createPayload(actions); + } +} + +/** + * @dev Deploy Avalanche + * command: make deploy-ledger contract=src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol:DeployAvalanche chain=avalanche + */ +contract DeployAvalanche is AvalancheScript { + function run() external broadcast { + // compose action + IPayloadsControllerCore.ExecutionAction[] + memory actions = new IPayloadsControllerCore.ExecutionAction[](1); + actions[0] = GovV3Helpers.buildAction(address(payload0)); + + // register action at payloadsController + GovV3Helpers.createPayload(actions); + } +} + +/** + * @dev Deploy Optimism + * command: make deploy-ledger contract=src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol:DeployOptimism chain=optimism + */ +contract DeployOptimism is OptimismScript { + function run() external broadcast { + // compose action + IPayloadsControllerCore.ExecutionAction[] + memory actions = new IPayloadsControllerCore.ExecutionAction[](1); + actions[0] = GovV3Helpers.buildAction(address(payload0)); + + // register action at payloadsController + GovV3Helpers.createPayload(actions); + } +} + +/** + * @dev Deploy Arbitrum + * command: make deploy-ledger contract=src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol:DeployArbitrum chain=arbitrum + */ +contract DeployArbitrum is ArbitrumScript { + function run() external broadcast { + // compose action + IPayloadsControllerCore.ExecutionAction[] + memory actions = new IPayloadsControllerCore.ExecutionAction[](1); + actions[0] = GovV3Helpers.buildAction(address(payload0)); + + // register action at payloadsController + GovV3Helpers.createPayload(actions); + } +} + +/** + * @dev Create Proposal + * command: make deploy-ledger contract=src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol:CreateProposal chain=mainnet + */ +contract CreateProposal is EthereumScript { + function run() external { + // create payloads + PayloadsControllerUtils.Payload[] memory payloads = new PayloadsControllerUtils.Payload[](5); + + // compose actions for validation + IPayloadsControllerCore.ExecutionAction[] + memory actionsEthereum = new IPayloadsControllerCore.ExecutionAction[](1); + actionsEthereum[0] = GovV3Helpers.buildAction(address(0)); + payloads[0] = GovV3Helpers.buildMainnetPayload(vm, actionsEthereum); + + IPayloadsControllerCore.ExecutionAction[] + memory actionsPolygon = new IPayloadsControllerCore.ExecutionAction[](1); + actionsPolygon[0] = GovV3Helpers.buildAction(address(0)); + payloads[1] = GovV3Helpers.buildPolygonPayload(vm, actionsPolygon); + + IPayloadsControllerCore.ExecutionAction[] + memory actionsAvalanche = new IPayloadsControllerCore.ExecutionAction[](1); + actionsAvalanche[0] = GovV3Helpers.buildAction(address(0)); + payloads[2] = GovV3Helpers.buildAvalanchePayload(vm, actionsAvalanche); + + IPayloadsControllerCore.ExecutionAction[] + memory actionsOptimism = new IPayloadsControllerCore.ExecutionAction[](1); + actionsOptimism[0] = GovV3Helpers.buildAction(address(0)); + payloads[3] = GovV3Helpers.buildOptimismPayload(vm, actionsOptimism); + + IPayloadsControllerCore.ExecutionAction[] + memory actionsArbitrum = new IPayloadsControllerCore.ExecutionAction[](1); + actionsArbitrum[0] = GovV3Helpers.buildAction(address(0)); + payloads[4] = GovV3Helpers.buildArbitrumPayload(vm, actionsArbitrum); + + // create proposal + vm.startBroadcast(); + GovV3Helpers.createProposal2_5( + payloads, + GovV3Helpers.ipfsHashFile(vm, 'src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md') + ); + } +} diff --git a/src/20231106_Multi_DebtTokenUpdates/config.json b/src/20231106_Multi_DebtTokenUpdates/config.json new file mode 100644 index 000000000..1b7dff265 --- /dev/null +++ b/src/20231106_Multi_DebtTokenUpdates/config.json @@ -0,0 +1,59 @@ +{ + "rootOptions": { + "pools": [ + "AaveV2Ethereum", + "AaveV3Polygon", + "AaveV3Avalanche", + "AaveV3Optimism", + "AaveV3Arbitrum" + ], + "title": "Debt Token Updates", + "shortName": "DebtTokenUpdates", + "date": "20231106", + "author": "BGD Labs", + "discussion": "https://governance.aave.com/t/aave-v2-v3-security-incident-04-11-2023/15335/26", + "snapshot": "" + }, + "poolOptions": { + "AaveV2Ethereum": { + "configs": { + "OTHERS": {} + }, + "features": [ + "OTHERS" + ] + }, + "AaveV3Polygon": { + "configs": { + "OTHERS": {} + }, + "features": [ + "OTHERS" + ] + }, + "AaveV3Avalanche": { + "configs": { + "OTHERS": {} + }, + "features": [ + "OTHERS" + ] + }, + "AaveV3Optimism": { + "configs": { + "OTHERS": {} + }, + "features": [ + "OTHERS" + ] + }, + "AaveV3Arbitrum": { + "configs": { + "OTHERS": {} + }, + "features": [ + "OTHERS" + ] + } + } +} \ No newline at end of file From 1bfe840bd52e51781de50daff2e9adec86c2b753 Mon Sep 17 00:00:00 2001 From: sakulstra Date: Mon, 6 Nov 2023 19:53:25 +0100 Subject: [PATCH 02/14] feat: update token --- ...thereum_DebtTokenUpdates_20231106_after.md | 5 +++++ ...V2Ethereum_DebtTokenUpdates_20231106.t.sol | 9 +++++++-- ...V3Arbitrum_DebtTokenUpdates_20231106.t.sol | 1 - ...3Avalanche_DebtTokenUpdates_20231106.t.sol | 1 - ...V3Optimism_DebtTokenUpdates_20231106.t.sol | 1 - ...eV3Polygon_DebtTokenUpdates_20231106.t.sol | 1 - .../DebtTokenUpdates_20231106.s.sol | 19 ++++++++----------- 7 files changed, 20 insertions(+), 17 deletions(-) create mode 100644 diffs/AaveV2Ethereum_DebtTokenUpdates_20231106_before_AaveV2Ethereum_DebtTokenUpdates_20231106_after.md diff --git a/diffs/AaveV2Ethereum_DebtTokenUpdates_20231106_before_AaveV2Ethereum_DebtTokenUpdates_20231106_after.md b/diffs/AaveV2Ethereum_DebtTokenUpdates_20231106_before_AaveV2Ethereum_DebtTokenUpdates_20231106_after.md new file mode 100644 index 000000000..c15d3e2bc --- /dev/null +++ b/diffs/AaveV2Ethereum_DebtTokenUpdates_20231106_before_AaveV2Ethereum_DebtTokenUpdates_20231106_after.md @@ -0,0 +1,5 @@ +## Raw diff + +```json +{} +``` \ No newline at end of file diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.t.sol index 702c31ae8..a5972782b 100644 --- a/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.t.sol +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.t.sol @@ -5,14 +5,13 @@ import {AaveV2Ethereum} from 'aave-address-book/AaveV2Ethereum.sol'; import 'forge-std/Test.sol'; import {ProtocolV2TestBase, ReserveConfig} from 'aave-helpers/ProtocolV2TestBase.sol'; -import {AaveV2Ethereum_DebtTokenUpdates_20231106} from './AaveV2Ethereum_DebtTokenUpdates_20231106.sol'; /** * @dev Test for AaveV2Ethereum_DebtTokenUpdates_20231106 * command: make test-contract filter=AaveV2Ethereum_DebtTokenUpdates_20231106 */ contract AaveV2Ethereum_DebtTokenUpdates_20231106_Test is ProtocolV2TestBase { - address internal proposal = address(0); + address internal proposal = address(0x37DF9bd44728e513472D5d44793118cBaE975E12); function setUp() public { vm.createSelectFork(vm.rpcUrl('mainnet'), 18514639); @@ -22,6 +21,12 @@ contract AaveV2Ethereum_DebtTokenUpdates_20231106_Test is ProtocolV2TestBase { * @dev executes the generic test suite including e2e and config snapshots */ function test_defaultProposalExecution() public { + _unPause(); defaultTest('AaveV2Ethereum_DebtTokenUpdates_20231106', AaveV2Ethereum.POOL, address(proposal)); } + + function _unPause() internal { + hoax(0xCA76Ebd8617a03126B6FB84F9b1c1A0fB71C2633); + AaveV2Ethereum.POOL_CONFIGURATOR.setPoolPause(false); + } } diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.t.sol index 78dc9ce38..49c0b6755 100644 --- a/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.t.sol +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.t.sol @@ -5,7 +5,6 @@ import {AaveV3Arbitrum} from 'aave-address-book/AaveV3Arbitrum.sol'; import 'forge-std/Test.sol'; import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/ProtocolV3TestBase.sol'; -import {AaveV3Arbitrum_DebtTokenUpdates_20231106} from './AaveV3Arbitrum_DebtTokenUpdates_20231106.sol'; /** * @dev Test for AaveV3Arbitrum_DebtTokenUpdates_20231106 diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.t.sol index 93c600efa..67fe615da 100644 --- a/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.t.sol +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.t.sol @@ -5,7 +5,6 @@ import {AaveV3Avalanche} from 'aave-address-book/AaveV3Avalanche.sol'; import 'forge-std/Test.sol'; import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/ProtocolV3TestBase.sol'; -import {AaveV3Avalanche_DebtTokenUpdates_20231106} from './AaveV3Avalanche_DebtTokenUpdates_20231106.sol'; /** * @dev Test for AaveV3Avalanche_DebtTokenUpdates_20231106 diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.t.sol index b2c70b0a8..29c5ba01d 100644 --- a/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.t.sol +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.t.sol @@ -5,7 +5,6 @@ import {AaveV3Optimism} from 'aave-address-book/AaveV3Optimism.sol'; import 'forge-std/Test.sol'; import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/ProtocolV3TestBase.sol'; -import {AaveV3Optimism_DebtTokenUpdates_20231106} from './AaveV3Optimism_DebtTokenUpdates_20231106.sol'; /** * @dev Test for AaveV3Optimism_DebtTokenUpdates_20231106 diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.t.sol index 5bab9ee8c..db8d46c3b 100644 --- a/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.t.sol +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.t.sol @@ -5,7 +5,6 @@ import {AaveV3Polygon} from 'aave-address-book/AaveV3Polygon.sol'; import 'forge-std/Test.sol'; import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/ProtocolV3TestBase.sol'; -import {AaveV3Polygon_DebtTokenUpdates_20231106} from './AaveV3Polygon_DebtTokenUpdates_20231106.sol'; /** * @dev Test for AaveV3Polygon_DebtTokenUpdates_20231106 diff --git a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol index 812141605..cb1211cb5 100644 --- a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol +++ b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol @@ -3,11 +3,6 @@ pragma solidity ^0.8.0; import {GovV3Helpers, IPayloadsControllerCore, PayloadsControllerUtils} from 'aave-helpers/GovV3Helpers.sol'; import {EthereumScript, PolygonScript, AvalancheScript, OptimismScript, ArbitrumScript} from 'aave-helpers/ScriptUtils.sol'; -import {AaveV2Ethereum_DebtTokenUpdates_20231106} from './AaveV2Ethereum_DebtTokenUpdates_20231106.sol'; -import {AaveV3Polygon_DebtTokenUpdates_20231106} from './AaveV3Polygon_DebtTokenUpdates_20231106.sol'; -import {AaveV3Avalanche_DebtTokenUpdates_20231106} from './AaveV3Avalanche_DebtTokenUpdates_20231106.sol'; -import {AaveV3Optimism_DebtTokenUpdates_20231106} from './AaveV3Optimism_DebtTokenUpdates_20231106.sol'; -import {AaveV3Arbitrum_DebtTokenUpdates_20231106} from './AaveV3Arbitrum_DebtTokenUpdates_20231106.sol'; /** * @dev Deploy Ethereum @@ -18,7 +13,7 @@ contract DeployEthereum is EthereumScript { // compose action IPayloadsControllerCore.ExecutionAction[] memory actions = new IPayloadsControllerCore.ExecutionAction[](1); - actions[0] = GovV3Helpers.buildAction(address(payload0)); + actions[0] = GovV3Helpers.buildAction(address(0x37DF9bd44728e513472D5d44793118cBaE975E12)); // register action at payloadsController GovV3Helpers.createPayload(actions); @@ -34,7 +29,7 @@ contract DeployPolygon is PolygonScript { // compose action IPayloadsControllerCore.ExecutionAction[] memory actions = new IPayloadsControllerCore.ExecutionAction[](1); - actions[0] = GovV3Helpers.buildAction(address(payload0)); + actions[0] = GovV3Helpers.buildAction(address(0)); // register action at payloadsController GovV3Helpers.createPayload(actions); @@ -50,7 +45,7 @@ contract DeployAvalanche is AvalancheScript { // compose action IPayloadsControllerCore.ExecutionAction[] memory actions = new IPayloadsControllerCore.ExecutionAction[](1); - actions[0] = GovV3Helpers.buildAction(address(payload0)); + actions[0] = GovV3Helpers.buildAction(address(0)); // register action at payloadsController GovV3Helpers.createPayload(actions); @@ -66,7 +61,7 @@ contract DeployOptimism is OptimismScript { // compose action IPayloadsControllerCore.ExecutionAction[] memory actions = new IPayloadsControllerCore.ExecutionAction[](1); - actions[0] = GovV3Helpers.buildAction(address(payload0)); + actions[0] = GovV3Helpers.buildAction(address(0)); // register action at payloadsController GovV3Helpers.createPayload(actions); @@ -82,7 +77,7 @@ contract DeployArbitrum is ArbitrumScript { // compose action IPayloadsControllerCore.ExecutionAction[] memory actions = new IPayloadsControllerCore.ExecutionAction[](1); - actions[0] = GovV3Helpers.buildAction(address(payload0)); + actions[0] = GovV3Helpers.buildAction(address(0)); // register action at payloadsController GovV3Helpers.createPayload(actions); @@ -101,7 +96,9 @@ contract CreateProposal is EthereumScript { // compose actions for validation IPayloadsControllerCore.ExecutionAction[] memory actionsEthereum = new IPayloadsControllerCore.ExecutionAction[](1); - actionsEthereum[0] = GovV3Helpers.buildAction(address(0)); + actionsEthereum[0] = GovV3Helpers.buildAction( + address(0x37DF9bd44728e513472D5d44793118cBaE975E12) + ); payloads[0] = GovV3Helpers.buildMainnetPayload(vm, actionsEthereum); IPayloadsControllerCore.ExecutionAction[] From 0dcbf18fa2adda140a5cd5d61dbf1f42eb5a59dd Mon Sep 17 00:00:00 2001 From: sakulstra Date: Mon, 6 Nov 2023 20:34:32 +0100 Subject: [PATCH 03/14] fix: update diffs --- Makefile | 2 +- ...thereum_DebtTokenUpdates_20231106_after.md | 178 +++++++++++++++++- ...V2Ethereum_DebtTokenUpdates_20231106.t.sol | 5 +- 3 files changed, 181 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 92741671d..4385a7311 100644 --- a/Makefile +++ b/Makefile @@ -8,7 +8,7 @@ update:; forge update # Build & test build :; forge build --sizes test :; forge test -vvv -test-contract :; forge test --match-contract ${filter} -vvv +test-contract :; forge test --match-contract ${filter} -vvvv # Deploy deploy-ledger :; forge script ${contract} --rpc-url ${chain} $(if ${dry},--sender 0x25F2226B597E8F9514B3F68F00f494cF4f286491 -vvvv,--broadcast --ledger --mnemonics foo --mnemonic-indexes ${MNEMONIC_INDEX} --sender ${LEDGER_SENDER} --verify -vvvv --slow) diff --git a/diffs/AaveV2Ethereum_DebtTokenUpdates_20231106_before_AaveV2Ethereum_DebtTokenUpdates_20231106_after.md b/diffs/AaveV2Ethereum_DebtTokenUpdates_20231106_before_AaveV2Ethereum_DebtTokenUpdates_20231106_after.md index c15d3e2bc..19b96845d 100644 --- a/diffs/AaveV2Ethereum_DebtTokenUpdates_20231106_before_AaveV2Ethereum_DebtTokenUpdates_20231106_after.md +++ b/diffs/AaveV2Ethereum_DebtTokenUpdates_20231106_before_AaveV2Ethereum_DebtTokenUpdates_20231106_after.md @@ -1,5 +1,181 @@ +## Reserve changes + +### Reserve altered + +#### BAT ([0x0D8775F648430679A709E98d2b0Cb6250d2887EF](https://etherscan.io/address/0x0D8775F648430679A709E98d2b0Cb6250d2887EF)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x917fd53da13EDCCE5c155a7dbC73E1e4DcCd4267](https://etherscan.io/address/0x917fd53da13EDCCE5c155a7dbC73E1e4DcCd4267) | [0x49B6645a9aa05f1Be24893136100467276399470](https://etherscan.io/address/0x49B6645a9aa05f1Be24893136100467276399470) | + + +#### MANA ([0x0F5D2fB29fb7d3CFeE444a200298f468908cC942](https://etherscan.io/address/0x0F5D2fB29fb7d3CFeE444a200298f468908cC942)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x441c5CD55E9e3267D02F7b1b4D245AA1C61891c3](https://etherscan.io/address/0x441c5CD55E9e3267D02F7b1b4D245AA1C61891c3) | [0xe0bf71fF662e8bbeb911ACEa765f4b8be052F59b](https://etherscan.io/address/0xe0bf71fF662e8bbeb911ACEa765f4b8be052F59b) | + + +#### WBTC ([0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599](https://etherscan.io/address/0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x6Ac108C4c3Fe7F4D367513F599Da1B9dF7c43433](https://etherscan.io/address/0x6Ac108C4c3Fe7F4D367513F599Da1B9dF7c43433) | [0x4f279f2046870F77cd9Ce63497f8A2D8689ef804](https://etherscan.io/address/0x4f279f2046870F77cd9Ce63497f8A2D8689ef804) | + + +#### REN ([0x408e41876cCCDC0F92210600ef50372656052a38](https://etherscan.io/address/0x408e41876cCCDC0F92210600ef50372656052a38)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x7b3E7Aea49A5F5d2514B9317d4cF58f828Ac28C2](https://etherscan.io/address/0x7b3E7Aea49A5F5d2514B9317d4cF58f828Ac28C2) | [0x6F4B277366e10F68003A0a65Ef8f118f3D60B67E](https://etherscan.io/address/0x6F4B277366e10F68003A0a65Ef8f118f3D60B67E) | + + +#### LINK ([0x514910771AF9Ca656af840dff83E8264EcF986CA](https://etherscan.io/address/0x514910771AF9Ca656af840dff83E8264EcF986CA)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0xAdc313f17a3e2180f609a45d7B381a45E2e88a9F](https://etherscan.io/address/0xAdc313f17a3e2180f609a45d7B381a45E2e88a9F) | [0x1B80694AF3D4e617c747423f992F532B8baE098b](https://etherscan.io/address/0x1B80694AF3D4e617c747423f992F532B8baE098b) | + + +#### LUSD ([0x5f98805A4E8be255a32880FDeC7F6728C6568bA0](https://etherscan.io/address/0x5f98805A4E8be255a32880FDeC7F6728C6568bA0)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x595c33538215DC4B092F35Afc85d904631263f4F](https://etherscan.io/address/0x595c33538215DC4B092F35Afc85d904631263f4F) | [0x1363602E58e25929A15bE194a3D505Fd6F8BE751](https://etherscan.io/address/0x1363602E58e25929A15bE194a3D505Fd6F8BE751) | + + +#### MKR ([0x9f8F72aA9304c8B593d555F12eF6589cC3A579A2](https://etherscan.io/address/0x9f8F72aA9304c8B593d555F12eF6589cC3A579A2)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x20f9027c5092739C58250CF456642E8e3D4dBEd5](https://etherscan.io/address/0x20f9027c5092739C58250CF456642E8e3D4dBEd5) | [0xC4CFCE0b16199818Ad942a87902C9172ba005022](https://etherscan.io/address/0xC4CFCE0b16199818Ad942a87902C9172ba005022) | + + +#### USDC ([0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48](https://etherscan.io/address/0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x3b2a77058a1Eb4403a90b94585FaB16Bc512E703](https://etherscan.io/address/0x3b2a77058a1Eb4403a90b94585FaB16Bc512E703) | [0x8DFF7Fda82976452b6FB957F549944e7af7A3e6F](https://etherscan.io/address/0x8DFF7Fda82976452b6FB957F549944e7af7A3e6F) | + + +#### WETH ([0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2](https://etherscan.io/address/0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0xA558EA1A875f8b576f0728d32C39f62158e49b92](https://etherscan.io/address/0xA558EA1A875f8b576f0728d32C39f62158e49b92) | [0xEd14b4E51B04d4d0211474a721F77C0817166c2f](https://etherscan.io/address/0xEd14b4E51B04d4d0211474a721F77C0817166c2f) | + + +#### ZRX ([0xE41d2489571d322189246DaFA5ebDe1F4699F498](https://etherscan.io/address/0xE41d2489571d322189246DaFA5ebDe1F4699F498)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x42a87BF47B5eFD11fa9Ddd5321BF9Aa502233b74](https://etherscan.io/address/0x42a87BF47B5eFD11fa9Ddd5321BF9Aa502233b74) | [0xffaCA447191d8196C8Cf96E5912b732063DE4307](https://etherscan.io/address/0xffaCA447191d8196C8Cf96E5912b732063DE4307) | + + +#### ENJ ([0xF629cBd94d3791C9250152BD8dfBDF380E2a3B9c](https://etherscan.io/address/0xF629cBd94d3791C9250152BD8dfBDF380E2a3B9c)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x8286288f3c454b51DfC70bd0d6918220428B0741](https://etherscan.io/address/0x8286288f3c454b51DfC70bd0d6918220428B0741) | [0x0fB427f800C5E39E7d8029e19F515300d4bb22C2](https://etherscan.io/address/0x0fB427f800C5E39E7d8029e19F515300d4bb22C2) | + + +#### USDT ([0xdAC17F958D2ee523a2206206994597C13D831ec7](https://etherscan.io/address/0xdAC17F958D2ee523a2206206994597C13D831ec7)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x9d4578c813D69745092a4F951753ed2B28056279](https://etherscan.io/address/0x9d4578c813D69745092a4F951753ed2B28056279) | [0xC61262D6ad449AC09B4087f46391Dd9A26b5888B](https://etherscan.io/address/0xC61262D6ad449AC09B4087f46391Dd9A26b5888B) | + + +#### KNC ([0xdd974D5C2e2928deA5F71b9825b8b646686BD200](https://etherscan.io/address/0xdd974D5C2e2928deA5F71b9825b8b646686BD200)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0xf818B175353F023E3EC1A098d040778b835897c7](https://etherscan.io/address/0xf818B175353F023E3EC1A098d040778b835897c7) | [0x22a8FD718924ab2f9dd4D0326DD8ab99Ef21D0b3](https://etherscan.io/address/0x22a8FD718924ab2f9dd4D0326DD8ab99Ef21D0b3) | + + ## Raw diff ```json -{} +{ + "reserves": { + "0x0D8775F648430679A709E98d2b0Cb6250d2887EF": { + "stableDebtTokenImpl": { + "from": "0x917fd53da13EDCCE5c155a7dbC73E1e4DcCd4267", + "to": "0x49B6645a9aa05f1Be24893136100467276399470" + } + }, + "0x0F5D2fB29fb7d3CFeE444a200298f468908cC942": { + "stableDebtTokenImpl": { + "from": "0x441c5CD55E9e3267D02F7b1b4D245AA1C61891c3", + "to": "0xe0bf71fF662e8bbeb911ACEa765f4b8be052F59b" + } + }, + "0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599": { + "stableDebtTokenImpl": { + "from": "0x6Ac108C4c3Fe7F4D367513F599Da1B9dF7c43433", + "to": "0x4f279f2046870F77cd9Ce63497f8A2D8689ef804" + } + }, + "0x408e41876cCCDC0F92210600ef50372656052a38": { + "stableDebtTokenImpl": { + "from": "0x7b3E7Aea49A5F5d2514B9317d4cF58f828Ac28C2", + "to": "0x6F4B277366e10F68003A0a65Ef8f118f3D60B67E" + } + }, + "0x514910771AF9Ca656af840dff83E8264EcF986CA": { + "stableDebtTokenImpl": { + "from": "0xAdc313f17a3e2180f609a45d7B381a45E2e88a9F", + "to": "0x1B80694AF3D4e617c747423f992F532B8baE098b" + } + }, + "0x5f98805A4E8be255a32880FDeC7F6728C6568bA0": { + "stableDebtTokenImpl": { + "from": "0x595c33538215DC4B092F35Afc85d904631263f4F", + "to": "0x1363602E58e25929A15bE194a3D505Fd6F8BE751" + } + }, + "0x9f8F72aA9304c8B593d555F12eF6589cC3A579A2": { + "stableDebtTokenImpl": { + "from": "0x20f9027c5092739C58250CF456642E8e3D4dBEd5", + "to": "0xC4CFCE0b16199818Ad942a87902C9172ba005022" + } + }, + "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48": { + "stableDebtTokenImpl": { + "from": "0x3b2a77058a1Eb4403a90b94585FaB16Bc512E703", + "to": "0x8DFF7Fda82976452b6FB957F549944e7af7A3e6F" + } + }, + "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2": { + "stableDebtTokenImpl": { + "from": "0xA558EA1A875f8b576f0728d32C39f62158e49b92", + "to": "0xEd14b4E51B04d4d0211474a721F77C0817166c2f" + } + }, + "0xE41d2489571d322189246DaFA5ebDe1F4699F498": { + "stableDebtTokenImpl": { + "from": "0x42a87BF47B5eFD11fa9Ddd5321BF9Aa502233b74", + "to": "0xffaCA447191d8196C8Cf96E5912b732063DE4307" + } + }, + "0xF629cBd94d3791C9250152BD8dfBDF380E2a3B9c": { + "stableDebtTokenImpl": { + "from": "0x8286288f3c454b51DfC70bd0d6918220428B0741", + "to": "0x0fB427f800C5E39E7d8029e19F515300d4bb22C2" + } + }, + "0xdAC17F958D2ee523a2206206994597C13D831ec7": { + "stableDebtTokenImpl": { + "from": "0x9d4578c813D69745092a4F951753ed2B28056279", + "to": "0xC61262D6ad449AC09B4087f46391Dd9A26b5888B" + } + }, + "0xdd974D5C2e2928deA5F71b9825b8b646686BD200": { + "stableDebtTokenImpl": { + "from": "0xf818B175353F023E3EC1A098d040778b835897c7", + "to": "0x22a8FD718924ab2f9dd4D0326DD8ab99Ef21D0b3" + } + } + } +} ``` \ No newline at end of file diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.t.sol index a5972782b..1e3574e3f 100644 --- a/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.t.sol +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.t.sol @@ -2,7 +2,7 @@ pragma solidity ^0.8.0; import {AaveV2Ethereum} from 'aave-address-book/AaveV2Ethereum.sol'; - +import {GovV3Helpers} from 'aave-helpers/GovV3Helpers.sol'; import 'forge-std/Test.sol'; import {ProtocolV2TestBase, ReserveConfig} from 'aave-helpers/ProtocolV2TestBase.sol'; @@ -14,7 +14,7 @@ contract AaveV2Ethereum_DebtTokenUpdates_20231106_Test is ProtocolV2TestBase { address internal proposal = address(0x37DF9bd44728e513472D5d44793118cBaE975E12); function setUp() public { - vm.createSelectFork(vm.rpcUrl('mainnet'), 18514639); + vm.createSelectFork(vm.rpcUrl('mainnet'), 18515006); } /** @@ -22,6 +22,7 @@ contract AaveV2Ethereum_DebtTokenUpdates_20231106_Test is ProtocolV2TestBase { */ function test_defaultProposalExecution() public { _unPause(); + GovV3Helpers.executePayload(vm, 4); defaultTest('AaveV2Ethereum_DebtTokenUpdates_20231106', AaveV2Ethereum.POOL, address(proposal)); } From 0e34f2924defe8721bf452fe3d175efa649c071a Mon Sep 17 00:00:00 2001 From: sakulstra Date: Mon, 6 Nov 2023 21:03:48 +0100 Subject: [PATCH 04/14] fix: update polygon --- ...Polygon_DebtTokenUpdates_20231106_after.md | 64 +++++++++++++++++++ ...eV3Polygon_DebtTokenUpdates_20231106.t.sol | 4 +- .../DebtTokenUpdates_20231106.s.sol | 6 +- 3 files changed, 70 insertions(+), 4 deletions(-) create mode 100644 diffs/AaveV3Polygon_DebtTokenUpdates_20231106_before_AaveV3Polygon_DebtTokenUpdates_20231106_after.md diff --git a/diffs/AaveV3Polygon_DebtTokenUpdates_20231106_before_AaveV3Polygon_DebtTokenUpdates_20231106_after.md b/diffs/AaveV3Polygon_DebtTokenUpdates_20231106_before_AaveV3Polygon_DebtTokenUpdates_20231106_after.md new file mode 100644 index 000000000..6615ecdf5 --- /dev/null +++ b/diffs/AaveV3Polygon_DebtTokenUpdates_20231106_before_AaveV3Polygon_DebtTokenUpdates_20231106_after.md @@ -0,0 +1,64 @@ +## Reserve changes + +### Reserve altered + +#### USDC ([0x2791Bca1f2de4661ED88A30C99A7a9449Aa84174](https://polygonscan.com/address/0x2791Bca1f2de4661ED88A30C99A7a9449Aa84174)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x50ddd0Cd4266299527d25De9CBb55fE0EB8dAc30](https://polygonscan.com/address/0x50ddd0Cd4266299527d25De9CBb55fE0EB8dAc30) | [0xF4294973B7E6F6C411dD8A388592E7c7D32F2486](https://polygonscan.com/address/0xF4294973B7E6F6C411dD8A388592E7c7D32F2486) | + + +#### DAI ([0x8f3Cf7ad23Cd3CaDbD9735AFf958023239c6A063](https://polygonscan.com/address/0x8f3Cf7ad23Cd3CaDbD9735AFf958023239c6A063)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x50ddd0Cd4266299527d25De9CBb55fE0EB8dAc30](https://polygonscan.com/address/0x50ddd0Cd4266299527d25De9CBb55fE0EB8dAc30) | [0xF4294973B7E6F6C411dD8A388592E7c7D32F2486](https://polygonscan.com/address/0xF4294973B7E6F6C411dD8A388592E7c7D32F2486) | + + +#### EURS ([0xE111178A87A3BFf0c8d18DECBa5798827539Ae99](https://polygonscan.com/address/0xE111178A87A3BFf0c8d18DECBa5798827539Ae99)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x50ddd0Cd4266299527d25De9CBb55fE0EB8dAc30](https://polygonscan.com/address/0x50ddd0Cd4266299527d25De9CBb55fE0EB8dAc30) | [0xF4294973B7E6F6C411dD8A388592E7c7D32F2486](https://polygonscan.com/address/0xF4294973B7E6F6C411dD8A388592E7c7D32F2486) | + + +#### USDT ([0xc2132D05D31c914a87C6611C10748AEb04B58e8F](https://polygonscan.com/address/0xc2132D05D31c914a87C6611C10748AEb04B58e8F)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x50ddd0Cd4266299527d25De9CBb55fE0EB8dAc30](https://polygonscan.com/address/0x50ddd0Cd4266299527d25De9CBb55fE0EB8dAc30) | [0xF4294973B7E6F6C411dD8A388592E7c7D32F2486](https://polygonscan.com/address/0xF4294973B7E6F6C411dD8A388592E7c7D32F2486) | + + +## Raw diff + +```json +{ + "reserves": { + "0x2791Bca1f2de4661ED88A30C99A7a9449Aa84174": { + "stableDebtTokenImpl": { + "from": "0x50ddd0Cd4266299527d25De9CBb55fE0EB8dAc30", + "to": "0xF4294973B7E6F6C411dD8A388592E7c7D32F2486" + } + }, + "0x8f3Cf7ad23Cd3CaDbD9735AFf958023239c6A063": { + "stableDebtTokenImpl": { + "from": "0x50ddd0Cd4266299527d25De9CBb55fE0EB8dAc30", + "to": "0xF4294973B7E6F6C411dD8A388592E7c7D32F2486" + } + }, + "0xE111178A87A3BFf0c8d18DECBa5798827539Ae99": { + "stableDebtTokenImpl": { + "from": "0x50ddd0Cd4266299527d25De9CBb55fE0EB8dAc30", + "to": "0xF4294973B7E6F6C411dD8A388592E7c7D32F2486" + } + }, + "0xc2132D05D31c914a87C6611C10748AEb04B58e8F": { + "stableDebtTokenImpl": { + "from": "0x50ddd0Cd4266299527d25De9CBb55fE0EB8dAc30", + "to": "0xF4294973B7E6F6C411dD8A388592E7c7D32F2486" + } + } + } +} +``` \ No newline at end of file diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.t.sol index db8d46c3b..f1a8b179d 100644 --- a/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.t.sol +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.t.sol @@ -11,10 +11,10 @@ import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/ProtocolV3TestBase * command: make test-contract filter=AaveV3Polygon_DebtTokenUpdates_20231106 */ contract AaveV3Polygon_DebtTokenUpdates_20231106_Test is ProtocolV3TestBase { - address internal proposal = address(0); + address internal proposal = address(0x9CbC0C27Fd72e78b6e297ABb5A54f0faAde59180); function setUp() public { - vm.createSelectFork(vm.rpcUrl('polygon'), 49622312); + vm.createSelectFork(vm.rpcUrl('polygon'), 49625199); } /** diff --git a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol index cb1211cb5..b06888cfb 100644 --- a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol +++ b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol @@ -29,7 +29,7 @@ contract DeployPolygon is PolygonScript { // compose action IPayloadsControllerCore.ExecutionAction[] memory actions = new IPayloadsControllerCore.ExecutionAction[](1); - actions[0] = GovV3Helpers.buildAction(address(0)); + actions[0] = GovV3Helpers.buildAction(address(0x9CbC0C27Fd72e78b6e297ABb5A54f0faAde59180)); // register action at payloadsController GovV3Helpers.createPayload(actions); @@ -103,7 +103,9 @@ contract CreateProposal is EthereumScript { IPayloadsControllerCore.ExecutionAction[] memory actionsPolygon = new IPayloadsControllerCore.ExecutionAction[](1); - actionsPolygon[0] = GovV3Helpers.buildAction(address(0)); + actionsPolygon[0] = GovV3Helpers.buildAction( + address(0x9CbC0C27Fd72e78b6e297ABb5A54f0faAde59180) + ); payloads[1] = GovV3Helpers.buildPolygonPayload(vm, actionsPolygon); IPayloadsControllerCore.ExecutionAction[] From acd5921fc2cf2c7716ee6b7d844840c4c58ab917 Mon Sep 17 00:00:00 2001 From: sakulstra Date: Mon, 6 Nov 2023 21:15:21 +0100 Subject: [PATCH 05/14] fix: arbitrum diff --- ...rbitrum_DebtTokenUpdates_20231106_after.md | 64 +++++++++++++++++++ ...V3Arbitrum_DebtTokenUpdates_20231106.t.sol | 4 +- .../DebtTokenUpdates_20231106.s.sol | 4 +- 3 files changed, 69 insertions(+), 3 deletions(-) create mode 100644 diffs/AaveV3Arbitrum_DebtTokenUpdates_20231106_before_AaveV3Arbitrum_DebtTokenUpdates_20231106_after.md diff --git a/diffs/AaveV3Arbitrum_DebtTokenUpdates_20231106_before_AaveV3Arbitrum_DebtTokenUpdates_20231106_after.md b/diffs/AaveV3Arbitrum_DebtTokenUpdates_20231106_before_AaveV3Arbitrum_DebtTokenUpdates_20231106_after.md new file mode 100644 index 000000000..fc5185076 --- /dev/null +++ b/diffs/AaveV3Arbitrum_DebtTokenUpdates_20231106_before_AaveV3Arbitrum_DebtTokenUpdates_20231106_after.md @@ -0,0 +1,64 @@ +## Reserve changes + +### Reserve altered + +#### EURS ([0xD22a58f79e9481D1a88e00c343885A588b34b68B](https://arbiscan.io/address/0xD22a58f79e9481D1a88e00c343885A588b34b68B)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x0c2C95b24529664fE55D4437D7A31175CFE6c4f7](https://arbiscan.io/address/0x0c2C95b24529664fE55D4437D7A31175CFE6c4f7) | [0xCB7113D3d572613BbFCeCf80d1341cFFE2A92C00](https://arbiscan.io/address/0xCB7113D3d572613BbFCeCf80d1341cFFE2A92C00) | + + +#### DAI ([0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1](https://arbiscan.io/address/0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x0c2C95b24529664fE55D4437D7A31175CFE6c4f7](https://arbiscan.io/address/0x0c2C95b24529664fE55D4437D7A31175CFE6c4f7) | [0xCB7113D3d572613BbFCeCf80d1341cFFE2A92C00](https://arbiscan.io/address/0xCB7113D3d572613BbFCeCf80d1341cFFE2A92C00) | + + +#### USDC ([0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8](https://arbiscan.io/address/0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x0c2C95b24529664fE55D4437D7A31175CFE6c4f7](https://arbiscan.io/address/0x0c2C95b24529664fE55D4437D7A31175CFE6c4f7) | [0xCB7113D3d572613BbFCeCf80d1341cFFE2A92C00](https://arbiscan.io/address/0xCB7113D3d572613BbFCeCf80d1341cFFE2A92C00) | + + +#### USDT ([0xFd086bC7CD5C481DCC9C85ebE478A1C0b69FCbb9](https://arbiscan.io/address/0xFd086bC7CD5C481DCC9C85ebE478A1C0b69FCbb9)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x0c2C95b24529664fE55D4437D7A31175CFE6c4f7](https://arbiscan.io/address/0x0c2C95b24529664fE55D4437D7A31175CFE6c4f7) | [0xCB7113D3d572613BbFCeCf80d1341cFFE2A92C00](https://arbiscan.io/address/0xCB7113D3d572613BbFCeCf80d1341cFFE2A92C00) | + + +## Raw diff + +```json +{ + "reserves": { + "0xD22a58f79e9481D1a88e00c343885A588b34b68B": { + "stableDebtTokenImpl": { + "from": "0x0c2C95b24529664fE55D4437D7A31175CFE6c4f7", + "to": "0xCB7113D3d572613BbFCeCf80d1341cFFE2A92C00" + } + }, + "0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1": { + "stableDebtTokenImpl": { + "from": "0x0c2C95b24529664fE55D4437D7A31175CFE6c4f7", + "to": "0xCB7113D3d572613BbFCeCf80d1341cFFE2A92C00" + } + }, + "0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8": { + "stableDebtTokenImpl": { + "from": "0x0c2C95b24529664fE55D4437D7A31175CFE6c4f7", + "to": "0xCB7113D3d572613BbFCeCf80d1341cFFE2A92C00" + } + }, + "0xFd086bC7CD5C481DCC9C85ebE478A1C0b69FCbb9": { + "stableDebtTokenImpl": { + "from": "0x0c2C95b24529664fE55D4437D7A31175CFE6c4f7", + "to": "0xCB7113D3d572613BbFCeCf80d1341cFFE2A92C00" + } + } + } +} +``` \ No newline at end of file diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.t.sol index 49c0b6755..25ad031df 100644 --- a/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.t.sol +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.t.sol @@ -11,10 +11,10 @@ import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/ProtocolV3TestBase * command: make test-contract filter=AaveV3Arbitrum_DebtTokenUpdates_20231106 */ contract AaveV3Arbitrum_DebtTokenUpdates_20231106_Test is ProtocolV3TestBase { - address internal proposal = address(0); + address internal proposal = address(0x625ac4fA12c13210D62348952D54201934194Fe2); function setUp() public { - vm.createSelectFork(vm.rpcUrl('arbitrum'), 147772611); + vm.createSelectFork(vm.rpcUrl('arbitrum'), 147799320); } /** diff --git a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol index b06888cfb..a5e9b0821 100644 --- a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol +++ b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol @@ -120,7 +120,9 @@ contract CreateProposal is EthereumScript { IPayloadsControllerCore.ExecutionAction[] memory actionsArbitrum = new IPayloadsControllerCore.ExecutionAction[](1); - actionsArbitrum[0] = GovV3Helpers.buildAction(address(0)); + actionsArbitrum[0] = GovV3Helpers.buildAction( + address(0x625ac4fA12c13210D62348952D54201934194Fe2) + ); payloads[4] = GovV3Helpers.buildArbitrumPayload(vm, actionsArbitrum); // create proposal From f081f22820b97c9569d96216bf90fed39b2c583f Mon Sep 17 00:00:00 2001 From: sakulstra Date: Mon, 6 Nov 2023 21:23:07 +0100 Subject: [PATCH 06/14] fix: add optimism --- ...ptimism_DebtTokenUpdates_20231106_after.md | 51 +++++++++++++++++++ ...V3Optimism_DebtTokenUpdates_20231106.t.sol | 4 +- .../DebtTokenUpdates_20231106.s.sol | 4 +- 3 files changed, 56 insertions(+), 3 deletions(-) create mode 100644 diffs/AaveV3Optimism_DebtTokenUpdates_20231106_before_AaveV3Optimism_DebtTokenUpdates_20231106_after.md diff --git a/diffs/AaveV3Optimism_DebtTokenUpdates_20231106_before_AaveV3Optimism_DebtTokenUpdates_20231106_after.md b/diffs/AaveV3Optimism_DebtTokenUpdates_20231106_before_AaveV3Optimism_DebtTokenUpdates_20231106_after.md new file mode 100644 index 000000000..d34fd13a8 --- /dev/null +++ b/diffs/AaveV3Optimism_DebtTokenUpdates_20231106_before_AaveV3Optimism_DebtTokenUpdates_20231106_after.md @@ -0,0 +1,51 @@ +## Reserve changes + +### Reserve altered + +#### USDC ([0x7F5c764cBc14f9669B88837ca1490cCa17c31607](https://explorer.optimism.io/address/0x7F5c764cBc14f9669B88837ca1490cCa17c31607)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x6b4E260b765B3cA1514e618C0215A6B7839fF93e](https://explorer.optimism.io/address/0x6b4E260b765B3cA1514e618C0215A6B7839fF93e) | [0x69713dA5fDfacf77E80C31F9B928Ec0Fc3716384](https://explorer.optimism.io/address/0x69713dA5fDfacf77E80C31F9B928Ec0Fc3716384) | + + +#### USDT ([0x94b008aA00579c1307B0EF2c499aD98a8ce58e58](https://explorer.optimism.io/address/0x94b008aA00579c1307B0EF2c499aD98a8ce58e58)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x6b4E260b765B3cA1514e618C0215A6B7839fF93e](https://explorer.optimism.io/address/0x6b4E260b765B3cA1514e618C0215A6B7839fF93e) | [0x69713dA5fDfacf77E80C31F9B928Ec0Fc3716384](https://explorer.optimism.io/address/0x69713dA5fDfacf77E80C31F9B928Ec0Fc3716384) | + + +#### DAI ([0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1](https://explorer.optimism.io/address/0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x6b4E260b765B3cA1514e618C0215A6B7839fF93e](https://explorer.optimism.io/address/0x6b4E260b765B3cA1514e618C0215A6B7839fF93e) | [0x69713dA5fDfacf77E80C31F9B928Ec0Fc3716384](https://explorer.optimism.io/address/0x69713dA5fDfacf77E80C31F9B928Ec0Fc3716384) | + + +## Raw diff + +```json +{ + "reserves": { + "0x7F5c764cBc14f9669B88837ca1490cCa17c31607": { + "stableDebtTokenImpl": { + "from": "0x6b4E260b765B3cA1514e618C0215A6B7839fF93e", + "to": "0x69713dA5fDfacf77E80C31F9B928Ec0Fc3716384" + } + }, + "0x94b008aA00579c1307B0EF2c499aD98a8ce58e58": { + "stableDebtTokenImpl": { + "from": "0x6b4E260b765B3cA1514e618C0215A6B7839fF93e", + "to": "0x69713dA5fDfacf77E80C31F9B928Ec0Fc3716384" + } + }, + "0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1": { + "stableDebtTokenImpl": { + "from": "0x6b4E260b765B3cA1514e618C0215A6B7839fF93e", + "to": "0x69713dA5fDfacf77E80C31F9B928Ec0Fc3716384" + } + } + } +} +``` \ No newline at end of file diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.t.sol index 29c5ba01d..5c95810a5 100644 --- a/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.t.sol +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.t.sol @@ -11,10 +11,10 @@ import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/ProtocolV3TestBase * command: make test-contract filter=AaveV3Optimism_DebtTokenUpdates_20231106 */ contract AaveV3Optimism_DebtTokenUpdates_20231106_Test is ProtocolV3TestBase { - address internal proposal = address(0); + address internal proposal = address(0x4B02E9A575DFf2783568cE3DFD354736388D813d); function setUp() public { - vm.createSelectFork(vm.rpcUrl('optimism'), 111847755); + vm.createSelectFork(vm.rpcUrl('optimism'), 111851610); } /** diff --git a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol index a5e9b0821..f5c0301a8 100644 --- a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol +++ b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol @@ -115,7 +115,9 @@ contract CreateProposal is EthereumScript { IPayloadsControllerCore.ExecutionAction[] memory actionsOptimism = new IPayloadsControllerCore.ExecutionAction[](1); - actionsOptimism[0] = GovV3Helpers.buildAction(address(0)); + actionsOptimism[0] = GovV3Helpers.buildAction( + address(0x4B02E9A575DFf2783568cE3DFD354736388D813d) + ); payloads[3] = GovV3Helpers.buildOptimismPayload(vm, actionsOptimism); IPayloadsControllerCore.ExecutionAction[] From db75ec1828966bb86ca294acc216ce7401f6b729 Mon Sep 17 00:00:00 2001 From: sakulstra Date: Mon, 6 Nov 2023 21:29:48 +0100 Subject: [PATCH 07/14] fix: update avalanche as well --- ...alanche_DebtTokenUpdates_20231106_after.md | 51 +++++++++++++++++++ ...3Avalanche_DebtTokenUpdates_20231106.t.sol | 4 +- .../DebtTokenUpdates_20231106.s.sol | 4 +- 3 files changed, 56 insertions(+), 3 deletions(-) create mode 100644 diffs/AaveV3Avalanche_DebtTokenUpdates_20231106_before_AaveV3Avalanche_DebtTokenUpdates_20231106_after.md diff --git a/diffs/AaveV3Avalanche_DebtTokenUpdates_20231106_before_AaveV3Avalanche_DebtTokenUpdates_20231106_after.md b/diffs/AaveV3Avalanche_DebtTokenUpdates_20231106_before_AaveV3Avalanche_DebtTokenUpdates_20231106_after.md new file mode 100644 index 000000000..dcccdb604 --- /dev/null +++ b/diffs/AaveV3Avalanche_DebtTokenUpdates_20231106_before_AaveV3Avalanche_DebtTokenUpdates_20231106_after.md @@ -0,0 +1,51 @@ +## Reserve changes + +### Reserve altered + +#### USDt ([0x9702230A8Ea53601f5cD2dc00fDBc13d4dF4A8c7](https://snowtrace.io/address/0x9702230A8Ea53601f5cD2dc00fDBc13d4dF4A8c7)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x893411580e590D62dDBca8a703d61Cc4A8c7b2b9](https://snowtrace.io/address/0x893411580e590D62dDBca8a703d61Cc4A8c7b2b9) | [0xccf12894957E637Bd69693B12F3ba12b539C2D11](https://snowtrace.io/address/0xccf12894957E637Bd69693B12F3ba12b539C2D11) | + + +#### USDC ([0xB97EF9Ef8734C71904D8002F8b6Bc66Dd9c48a6E](https://snowtrace.io/address/0xB97EF9Ef8734C71904D8002F8b6Bc66Dd9c48a6E)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x893411580e590D62dDBca8a703d61Cc4A8c7b2b9](https://snowtrace.io/address/0x893411580e590D62dDBca8a703d61Cc4A8c7b2b9) | [0xccf12894957E637Bd69693B12F3ba12b539C2D11](https://snowtrace.io/address/0xccf12894957E637Bd69693B12F3ba12b539C2D11) | + + +#### DAI.e ([0xd586E7F844cEa2F87f50152665BCbc2C279D8d70](https://snowtrace.io/address/0xd586E7F844cEa2F87f50152665BCbc2C279D8d70)) + +| description | value before | value after | +| --- | --- | --- | +| stableDebtTokenImpl | [0x893411580e590D62dDBca8a703d61Cc4A8c7b2b9](https://snowtrace.io/address/0x893411580e590D62dDBca8a703d61Cc4A8c7b2b9) | [0xccf12894957E637Bd69693B12F3ba12b539C2D11](https://snowtrace.io/address/0xccf12894957E637Bd69693B12F3ba12b539C2D11) | + + +## Raw diff + +```json +{ + "reserves": { + "0x9702230A8Ea53601f5cD2dc00fDBc13d4dF4A8c7": { + "stableDebtTokenImpl": { + "from": "0x893411580e590D62dDBca8a703d61Cc4A8c7b2b9", + "to": "0xccf12894957E637Bd69693B12F3ba12b539C2D11" + } + }, + "0xB97EF9Ef8734C71904D8002F8b6Bc66Dd9c48a6E": { + "stableDebtTokenImpl": { + "from": "0x893411580e590D62dDBca8a703d61Cc4A8c7b2b9", + "to": "0xccf12894957E637Bd69693B12F3ba12b539C2D11" + } + }, + "0xd586E7F844cEa2F87f50152665BCbc2C279D8d70": { + "stableDebtTokenImpl": { + "from": "0x893411580e590D62dDBca8a703d61Cc4A8c7b2b9", + "to": "0xccf12894957E637Bd69693B12F3ba12b539C2D11" + } + } + } +} +``` \ No newline at end of file diff --git a/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.t.sol b/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.t.sol index 67fe615da..de5374411 100644 --- a/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.t.sol +++ b/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.t.sol @@ -11,10 +11,10 @@ import {ProtocolV3TestBase, ReserveConfig} from 'aave-helpers/ProtocolV3TestBase * command: make test-contract filter=AaveV3Avalanche_DebtTokenUpdates_20231106 */ contract AaveV3Avalanche_DebtTokenUpdates_20231106_Test is ProtocolV3TestBase { - address internal proposal = address(0); + address internal proposal = address(0x5c15edC83E044D0956fd3F845c15934aB8034BBA); function setUp() public { - vm.createSelectFork(vm.rpcUrl('avalanche'), 37419951); + vm.createSelectFork(vm.rpcUrl('avalanche'), 37423983); } /** diff --git a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol index f5c0301a8..ad638e9de 100644 --- a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol +++ b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol @@ -110,7 +110,9 @@ contract CreateProposal is EthereumScript { IPayloadsControllerCore.ExecutionAction[] memory actionsAvalanche = new IPayloadsControllerCore.ExecutionAction[](1); - actionsAvalanche[0] = GovV3Helpers.buildAction(address(0)); + actionsAvalanche[0] = GovV3Helpers.buildAction( + address(0x5c15edC83E044D0956fd3F845c15934aB8034BBA) + ); payloads[2] = GovV3Helpers.buildAvalanchePayload(vm, actionsAvalanche); IPayloadsControllerCore.ExecutionAction[] From 5f46e5e95310b78a436b183f76030495616f76f7 Mon Sep 17 00:00:00 2001 From: sakulstra Date: Mon, 6 Nov 2023 21:34:38 +0100 Subject: [PATCH 08/14] fix: adjust script --- .../DebtTokenUpdates_20231106.s.sol | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol index ad638e9de..108ae8e8c 100644 --- a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol +++ b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates_20231106.s.sol @@ -45,7 +45,7 @@ contract DeployAvalanche is AvalancheScript { // compose action IPayloadsControllerCore.ExecutionAction[] memory actions = new IPayloadsControllerCore.ExecutionAction[](1); - actions[0] = GovV3Helpers.buildAction(address(0)); + actions[0] = GovV3Helpers.buildAction(address(0x5c15edC83E044D0956fd3F845c15934aB8034BBA)); // register action at payloadsController GovV3Helpers.createPayload(actions); @@ -61,7 +61,7 @@ contract DeployOptimism is OptimismScript { // compose action IPayloadsControllerCore.ExecutionAction[] memory actions = new IPayloadsControllerCore.ExecutionAction[](1); - actions[0] = GovV3Helpers.buildAction(address(0)); + actions[0] = GovV3Helpers.buildAction(address(0x4B02E9A575DFf2783568cE3DFD354736388D813d)); // register action at payloadsController GovV3Helpers.createPayload(actions); @@ -77,7 +77,7 @@ contract DeployArbitrum is ArbitrumScript { // compose action IPayloadsControllerCore.ExecutionAction[] memory actions = new IPayloadsControllerCore.ExecutionAction[](1); - actions[0] = GovV3Helpers.buildAction(address(0)); + actions[0] = GovV3Helpers.buildAction(address(0x625ac4fA12c13210D62348952D54201934194Fe2)); // register action at payloadsController GovV3Helpers.createPayload(actions); From 22621bbd58fdc573932fc3f87c97582614701798 Mon Sep 17 00:00:00 2001 From: Lukas Date: Mon, 6 Nov 2023 21:36:30 +0100 Subject: [PATCH 09/14] Update src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md Co-authored-by: Ernesto Boado --- src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md index 453fb1842..52a2861db 100644 --- a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md +++ b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md @@ -1,6 +1,6 @@ --- title: "Debt Token Updates" -author: "BGD Labs" +author: "BGD Labs @bgdlabs" discussions: "https://governance.aave.com/t/aave-v2-v3-security-incident-04-11-2023/15335/26" --- From 3bcf386c3c7c071b3bb4ed8e9f41889e5135a0dd Mon Sep 17 00:00:00 2001 From: Lukas Date: Mon, 6 Nov 2023 21:36:37 +0100 Subject: [PATCH 10/14] Update src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md Co-authored-by: Ernesto Boado --- src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md index 52a2861db..0ffd73f3d 100644 --- a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md +++ b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md @@ -1,5 +1,5 @@ --- -title: "Debt Token Updates" +title: "Multichain Stable Debt Token Upgrades" author: "BGD Labs @bgdlabs" discussions: "https://governance.aave.com/t/aave-v2-v3-security-incident-04-11-2023/15335/26" --- From d4bb33a23ceba4cce2e4d66d9929c3001ab85f3f Mon Sep 17 00:00:00 2001 From: sakulstra Date: Mon, 6 Nov 2023 21:40:16 +0100 Subject: [PATCH 11/14] fix: update text --- src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md index 0ffd73f3d..b82d87fde 100644 --- a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md +++ b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md @@ -11,7 +11,7 @@ The implementation will effectively stop minting new stable debt tokens. ## Motivation -In response to an attack vector reported by a white-hat, some immediate steps where taken to protect the Aave Markets by pausing, freezing and disable stable borrowing on the affected assets. +In response to an attack vector reported by a white-hat, some immediate steps where taken to protect the Aave Pools by pausing, freezing and disable stable borrowing on the affected assets. Upon further investigation it turned out to be necessary to also prevent new minting of StableDebt. @@ -25,6 +25,8 @@ On AaveV3Arbitrum, AaveV3Optimism, AaveV3Avalanche, AaveV3Polygon the proposal w - `POOL_CONFIGURATOR.updateStableDebtToken(input);` +The proposal has been tested by BGD Labs and been reviewed by Aave Companies and Certora. + ## References - Implementation: [AaveV2Ethereum](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.sol), [AaveV3Polygon](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.sol), [AaveV3Avalanche](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.sol), [AaveV3Optimism](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.sol), [AaveV3Arbitrum](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.sol) From 38bc83e8ff2a0ed88aa13c3f09fc2fa1a5f06007 Mon Sep 17 00:00:00 2001 From: Lukas Date: Mon, 6 Nov 2023 21:42:58 +0100 Subject: [PATCH 12/14] Update src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md Co-authored-by: Ernesto Boado --- src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md index b82d87fde..7acaf0e13 100644 --- a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md +++ b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md @@ -25,7 +25,7 @@ On AaveV3Arbitrum, AaveV3Optimism, AaveV3Avalanche, AaveV3Polygon the proposal w - `POOL_CONFIGURATOR.updateStableDebtToken(input);` -The proposal has been tested by BGD Labs and been reviewed by Aave Companies and Certora. +The proposal has been tested by BGD Labs and reviewed by Aave Companies and Certora. ## References From 218c6abd0c9e5a9c06b67522545e08f2709a4b59 Mon Sep 17 00:00:00 2001 From: sakulstra Date: Mon, 6 Nov 2023 21:43:37 +0100 Subject: [PATCH 13/14] fix: update text --- src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md index 7acaf0e13..45dc0a1bf 100644 --- a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md +++ b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md @@ -11,7 +11,7 @@ The implementation will effectively stop minting new stable debt tokens. ## Motivation -In response to an attack vector reported by a white-hat, some immediate steps where taken to protect the Aave Pools by pausing, freezing and disable stable borrowing on the affected assets. +In response to an attack vector reported by a white-hat, some immediate steps where taken to protect the Aave Pools by pausing, freezing, and disabling stable borrowing on the affected assets. Upon further investigation it turned out to be necessary to also prevent new minting of StableDebt. From 66088c6cb2b09a7acf0ed971021bb6de9cdd20ac Mon Sep 17 00:00:00 2001 From: eboado Date: Mon, 6 Nov 2023 22:05:58 +0100 Subject: [PATCH 14/14] Added links on stable debt token update --- src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md index 45dc0a1bf..67d6d6376 100644 --- a/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md +++ b/src/20231106_Multi_DebtTokenUpdates/DebtTokenUpdates.md @@ -29,8 +29,9 @@ The proposal has been tested by BGD Labs and reviewed by Aave Companies and Cert ## References -- Implementation: [AaveV2Ethereum](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.sol), [AaveV3Polygon](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.sol), [AaveV3Avalanche](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.sol), [AaveV3Optimism](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.sol), [AaveV3Arbitrum](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.sol) +- Implementation: [AaveV2Ethereum](https://github.com/bgd-labs/stable-rate-patch/blob/main/src/payloads/V2EthSTokenPayload.sol), [AaveV3Polygon](https://github.com/bgd-labs/stable-rate-patch/blob/main/src/payloads/V3PolSTokenPayload.sol), [AaveV3Avalanche](https://github.com/bgd-labs/stable-rate-patch/blob/main/src/payloads/V3AvaxSTokenPayload.sol), [AaveV3Optimism](https://github.com/bgd-labs/stable-rate-patch/blob/main/src/payloads/V3OptSTokenPayload.sol), [AaveV3Arbitrum](https://github.com/bgd-labs/stable-rate-patch/blob/main/src/payloads/V3ArbSTokenPayload.sol) - Tests: [AaveV2Ethereum](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV2Ethereum_DebtTokenUpdates_20231106.t.sol), [AaveV3Polygon](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Polygon_DebtTokenUpdates_20231106.t.sol), [AaveV3Avalanche](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Avalanche_DebtTokenUpdates_20231106.t.sol), [AaveV3Optimism](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Optimism_DebtTokenUpdates_20231106.t.sol), [AaveV3Arbitrum](https://github.com/bgd-labs/aave-proposals-v3/blob/main/src/20231106_Multi_DebtTokenUpdates/AaveV3Arbitrum_DebtTokenUpdates_20231106.t.sol) +- Stable debt token tests: [AaveV2Ethereum](https://github.com/bgd-labs/stable-rate-patch/blob/main/tests/V2EthSToken.t.sol), [AaveV3Polygon](https://github.com/bgd-labs/stable-rate-patch/blob/main/tests/V3PolSToken.t.sol), [AaveV3Avalanche](https://github.com/bgd-labs/stable-rate-patch/blob/main/tests/V3AvaxSToken.t.sol), [AaveV3Optimism](https://github.com/bgd-labs/stable-rate-patch/blob/main/tests/V3OptSToken.t.sol), [AaveV3Arbitrum](https://github.com/bgd-labs/stable-rate-patch/blob/main/tests/V3ArbSToken.t.sol) - [Discussion](https://governance.aave.com/t/aave-v2-v3-security-incident-04-11-2023/15335/26) ## Copyright